From da32de7309151de2cb08b8133621ae5dfc25d519 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 9 May 2021 13:49:47 +0530 Subject: [PATCH 001/183] :sparkles: added integration test github action --- .github/workflows/ci.yml | 23 ++++++ .../handler/grpc_handler_integration_test.go | 73 +++++++++++++++++++ docker.local/b0docker-compose.yml | 2 + 3 files changed, 98 insertions(+) create mode 100644 code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fc4e0edf2..95d652753 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,6 +11,29 @@ env: VALIDATOR_REGISTRY: ${{ secrets.VALIDATOR_REGISTRY }} jobs: + integration-tests: + runs-on: ubuntu-20.04 + steps: + - name: Install Go + uses: actions/setup-go@v2 + with: + go-version: 1.14.x + - uses: actions/checkout@v2 + # In this step, this action saves a list of existing images, + # the cache is created without them in the post run. + # It also restores the cache if it exists. + - uses: satackey/action-docker-layer-caching@v0.0.11 + # Ignore the failure of a step and avoid terminating the job. + continue-on-error: true + - name: Build + run: | + ./docker.local/bin/blobber.init.setup.sh + docker network create --driver=bridge --subnet=198.18.0.0/15 --gateway=198.18.0.255 testnet0 + ./docker.local/bin/build.blobber.sh + cd docker.local/blobber1; ../bin/blobber.start_bls.sh /dev/null & + cd code/go/0chain.net + go test blobbercore/handler/grpc_handler_integration_test.go --args integration + test: runs-on: ubuntu-20.04 steps: diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go new file mode 100644 index 000000000..d92f6f717 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -0,0 +1,73 @@ +package handler + +import ( + "context" + "fmt" + "log" + "os" + "testing" + "time" + + "google.golang.org/grpc" + + "0chain.net/blobbercore/blobbergrpc" +) + +const BlobberAddr = "localhost:7031" +const RetryAttempts = 8 +const RetryTimeout = 3 + +func TestBlobberGRPCService_IntegrationTest(t *testing.T) { + args := make(map[string]bool) + for _, arg := range os.Args { + args[arg] = true + } + + if !args["integration"] { + t.Skip() + } + + ctx := context.Background() + + var conn *grpc.ClientConn + var err error + for i := 0; i < RetryAttempts; i++ { + log.Println("Connection attempt - " + fmt.Sprint(i+1)) + conn, err = grpc.Dial(BlobberAddr, grpc.WithInsecure()) + if err != nil { + log.Println(err) + <-time.After(time.Second * RetryTimeout) + continue + } + + break + } + + if err != nil { + t.Fatal(err) + } + + defer conn.Close() + client := blobbergrpc.NewBlobberClient(conn) + + t.Run("TestGetAllocation", func(t *testing.T) { + getAllocationReq := &blobbergrpc.GetAllocationRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "", + ClientKey: "", + Allocation: "", + }, + Id: "", + } + + getAllocationResp, err := client.GetAllocation(ctx, getAllocationReq) + if err != nil { + t.Fatal(err) + } + + if getAllocationResp.Allocation.ID != getAllocationReq.Id { + t.Fatal("unexpected allocation id from GetAllocation rpc") + } + }) + +} diff --git a/docker.local/b0docker-compose.yml b/docker.local/b0docker-compose.yml index 6030b1930..64672a94c 100644 --- a/docker.local/b0docker-compose.yml +++ b/docker.local/b0docker-compose.yml @@ -7,6 +7,8 @@ services: POSTGRES_HOST: postgres POSTGRES_USER: postgres POSTGRES_HOST_AUTH_METHOD: trust + ports: + - "5432:5432" volumes: - ./blobber${BLOBBER}/data/postgresql:/var/lib/postgresql/data networks: From 6c49f89cefe611bd7435f9cbba520f410a17382c Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 9 May 2021 13:55:54 +0530 Subject: [PATCH 002/183] :wrench: add integration tests to make file --- .github/workflows/ci.yml | 3 +-- Makefile | 5 ++++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 95d652753..86692e52c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -31,8 +31,7 @@ jobs: docker network create --driver=bridge --subnet=198.18.0.0/15 --gateway=198.18.0.255 testnet0 ./docker.local/bin/build.blobber.sh cd docker.local/blobber1; ../bin/blobber.start_bls.sh /dev/null & - cd code/go/0chain.net - go test blobbercore/handler/grpc_handler_integration_test.go --args integration + make integration-tests test: runs-on: ubuntu-20.04 diff --git a/Makefile b/Makefile index b85f580b9..3bcb13025 100644 --- a/Makefile +++ b/Makefile @@ -4,4 +4,7 @@ test: cd code/go/0chain.net; go test ./...; lint: - cd code/go/0chain.net; golangci-lint run; \ No newline at end of file + cd code/go/0chain.net; golangci-lint run; + +integration-tests: + cd code/go/0chain.net; go test ./... --args integration; \ No newline at end of file From 4bbe9d2f4dbee873e70114f663f30c7414ef39fb Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 9 May 2021 14:02:19 +0530 Subject: [PATCH 003/183] :green-heart: debugging integration test github action --- .github/workflows/ci.yml | 2 ++ Makefile | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 86692e52c..8b2cfc6f9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -31,6 +31,8 @@ jobs: docker network create --driver=bridge --subnet=198.18.0.0/15 --gateway=198.18.0.255 testnet0 ./docker.local/bin/build.blobber.sh cd docker.local/blobber1; ../bin/blobber.start_bls.sh /dev/null & + pwd + ls make integration-tests test: diff --git a/Makefile b/Makefile index 3bcb13025..36aa96854 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -.PHONY: test lint +.PHONY: test lint integration-tests test: cd code/go/0chain.net; go test ./...; From b640f2698fd19bc0c37e6d265646e19443f72df7 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 9 May 2021 14:07:56 +0530 Subject: [PATCH 004/183] :green_heart: attempting to fix integration-test github action --- .github/workflows/ci.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8b2cfc6f9..7764bc197 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,14 +25,14 @@ jobs: - uses: satackey/action-docker-layer-caching@v0.0.11 # Ignore the failure of a step and avoid terminating the job. continue-on-error: true - - name: Build + - name: Build environment and run tests run: | ./docker.local/bin/blobber.init.setup.sh docker network create --driver=bridge --subnet=198.18.0.0/15 --gateway=198.18.0.255 testnet0 ./docker.local/bin/build.blobber.sh - cd docker.local/blobber1; ../bin/blobber.start_bls.sh /dev/null & - pwd - ls + cd docker.local/blobber1 + ../bin/blobber.start_bls.sh /dev/null & + cd ../.. make integration-tests test: From c00e6720fc92635b4e7af207fb83de0589265e5a Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 9 May 2021 19:40:54 +0530 Subject: [PATCH 005/183] :white_check_mark: added testdata controller and added working GetAllocation integration tests --- .github/workflows/ci.yml | 2 +- code/go/0chain.net/blobber/main.go | 2 +- .../0chain.net/blobbercore/config/config.go | 4 +- .../handler/grpc_handler_helper_unit_test.go | 96 +++++++++++++++++++ .../handler/grpc_handler_integration_test.go | 56 ++++++++--- 5 files changed, 143 insertions(+), 17 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7764bc197..1aaff8fe8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,7 +25,7 @@ jobs: - uses: satackey/action-docker-layer-caching@v0.0.11 # Ignore the failure of a step and avoid terminating the job. continue-on-error: true - - name: Build environment and run tests + - name: Build test environment and run tests run: | ./docker.local/bin/blobber.init.setup.sh docker network create --driver=bridge --subnet=198.18.0.0/15 --gateway=198.18.0.255 testnet0 diff --git a/code/go/0chain.net/blobber/main.go b/code/go/0chain.net/blobber/main.go index 322c27232..3442a7afb 100644 --- a/code/go/0chain.net/blobber/main.go +++ b/code/go/0chain.net/blobber/main.go @@ -227,7 +227,7 @@ func main() { flag.Parse() config.SetupDefaultConfig() - config.SetupConfig() + config.SetupConfig("./config") config.Configuration.DeploymentMode = byte(*deploymentMode) diff --git a/code/go/0chain.net/blobbercore/config/config.go b/code/go/0chain.net/blobbercore/config/config.go index bf95a8d8f..cca45565e 100644 --- a/code/go/0chain.net/blobbercore/config/config.go +++ b/code/go/0chain.net/blobbercore/config/config.go @@ -44,12 +44,12 @@ func SetupDefaultConfig() { } /*SetupConfig - setup the configuration system */ -func SetupConfig() { +func SetupConfig(configPath string) { replacer := strings.NewReplacer(".", "_") viper.SetEnvKeyReplacer(replacer) viper.AutomaticEnv() viper.SetConfigName("0chain_blobber") - viper.AddConfigPath("./config") + viper.AddConfigPath(configPath) err := viper.ReadInConfig() // Find and read the config file if err != nil { // Handle errors reading the config file panic(fmt.Errorf("fatal error config file: %s", err)) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 66345b7ab..896fb28a9 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -2,6 +2,12 @@ package handler import ( "context" + "database/sql" + "fmt" + "log" + "time" + + "gorm.io/gorm" "0chain.net/blobbercore/allocation" "0chain.net/blobbercore/reference" @@ -56,3 +62,93 @@ func (_m *storageHandlerI) verifyAuthTicket(ctx context.Context, authTokenString return r0, r1 } + +type TestDataController struct { + db *gorm.DB +} + +func NewTestDataController(db *gorm.DB) *TestDataController { + return &TestDataController{db: db} +} + +// ClearDatabase deletes all data from all tables +func (c *TestDataController) ClearDatabase() error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + ctx := context.Background() + tx, err = db.BeginTx(ctx, &sql.TxOptions{}) + if err != nil { + return err + } + + _, err = tx.Exec("truncate allocations cascade") + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} + +func (c *TestDataController) AddGetAllocationTestData() error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + ctx := context.Background() + tx, err = db.BeginTx(ctx, &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) +VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index d92f6f717..4c68e668a 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -5,9 +5,16 @@ import ( "fmt" "log" "os" + "strings" "testing" "time" + "github.com/spf13/viper" + + "gorm.io/driver/postgres" + "gorm.io/gorm" + + "0chain.net/blobbercore/config" "google.golang.org/grpc" "0chain.net/blobbercore/blobbergrpc" @@ -22,7 +29,6 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { for _, arg := range os.Args { args[arg] = true } - if !args["integration"] { t.Skip() } @@ -39,33 +45,57 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { <-time.After(time.Second * RetryTimeout) continue } - break } - if err != nil { t.Fatal(err) } - defer conn.Close() - client := blobbergrpc.NewBlobberClient(conn) + blobberClient := blobbergrpc.NewBlobberClient(conn) + + pwd, err := os.Getwd() + if err != nil { + t.Fatal(err) + } + configDir := strings.Split(pwd, "/code/go")[0] + "/config" + config.SetupDefaultConfig() + config.SetupConfig(configDir) + config.Configuration.DBHost = "localhost" + config.Configuration.DBName = viper.GetString("db.name") + config.Configuration.DBPort = viper.GetString("db.port") + config.Configuration.DBUserName = viper.GetString("db.user") + config.Configuration.DBPassword = viper.GetString("db.password") + db, err := gorm.Open(postgres.Open(fmt.Sprintf( + "host=%v port=%v user=%v dbname=%v password=%v sslmode=disable", + config.Configuration.DBHost, config.Configuration.DBPort, + config.Configuration.DBUserName, config.Configuration.DBName, + config.Configuration.DBPassword)), &gorm.Config{}) + if err != nil { + t.Fatal(err) + } + tdController := NewTestDataController(db) t.Run("TestGetAllocation", func(t *testing.T) { + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetAllocationTestData() + if err != nil { + t.Fatal(err) + } + getAllocationReq := &blobbergrpc.GetAllocationRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "", - ClientKey: "", - Allocation: "", - }, - Id: "", + Context: &blobbergrpc.RequestContext{}, + Id: "exampleTransaction", } - getAllocationResp, err := client.GetAllocation(ctx, getAllocationReq) + getAllocationResp, err := blobberClient.GetAllocation(ctx, getAllocationReq) if err != nil { t.Fatal(err) } - if getAllocationResp.Allocation.ID != getAllocationReq.Id { + if getAllocationResp.Allocation.Tx != getAllocationReq.Id { t.Fatal("unexpected allocation id from GetAllocation rpc") } }) From 5e098a1dcdef0175800e3f2540c305d1d031eb87 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 9 May 2021 23:49:48 +0530 Subject: [PATCH 006/183] :white_check_mark: --- .../handler/grpc_handler_helper_unit_test.go | 87 ++++++++++++++++++- .../handler/grpc_handler_integration_test.go | 34 +++++++- 2 files changed, 114 insertions(+), 7 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 896fb28a9..e73eb168f 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -91,8 +91,7 @@ func (c *TestDataController) ClearDatabase() error { return err } - ctx := context.Background() - tx, err = db.BeginTx(ctx, &sql.TxOptions{}) + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) if err != nil { return err } @@ -102,6 +101,21 @@ func (c *TestDataController) ClearDatabase() error { return err } + _, err = tx.Exec("truncate reference_objects cascade") + if err != nil { + return err + } + + _, err = tx.Exec("truncate commit_meta_txns cascade") + if err != nil { + return err + } + + _, err = tx.Exec("truncate collaborators cascade") + if err != nil { + return err + } + err = tx.Commit() if err != nil { return err @@ -129,8 +143,49 @@ func (c *TestDataController) AddGetAllocationTestData() error { return err } - ctx := context.Background() - tx, err = db.BeginTx(ctx, &sql.TxOptions{}) + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) +VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} + +func (c *TestDataController) AddGetFileMetaDataTestData() error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) if err != nil { return err } @@ -145,6 +200,30 @@ VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKe return err } + _, err = tx.Exec(` +INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash) +VALUES (1234,'exampleId','exampleId:examplePath','exampleId:examplePath','f','filename','examplePath','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO commit_meta_txns (ref_id,txn_id) +VALUES (1234,'someTxn'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO collaborators (ref_id, client_id) +VALUES (1234, 'someClient'); +`) + if err != nil { + return err + } + err = tx.Commit() if err != nil { return err diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 4c68e668a..19df93947 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -29,9 +29,9 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { for _, arg := range os.Args { args[arg] = true } - if !args["integration"] { - t.Skip() - } + //if !args["integration"] { + // t.Skip() + //} ctx := context.Background() @@ -100,4 +100,32 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } }) + t.Run("TestGetFileMetaData", func(t *testing.T) { + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetFileMetaDataTestData() + if err != nil { + t.Fatal(err) + } + + req := &blobbergrpc.GetFileMetaDataRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + }, + Path: "examplePath", + PathHash: "exampleId:examplePath", + Allocation: "exampleTransaction", + } + getFileMetaDataResp, err := blobberClient.GetFileMetaData(ctx, req) + if err != nil { + t.Fatal(err) + } + + if getFileMetaDataResp.MetaData.FileMetaData.Name != "filename" { + t.Fatal("unexpected path from GetFileMetaData rpc") + } + }) + } From 5ca5b5bcef0d38b3aa544fb21654954c3529f3b3 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 10 May 2021 00:06:57 +0530 Subject: [PATCH 007/183] :white_check_mark: add GetFileStats rpc integration test --- .../handler/grpc_handler_helper_unit_test.go | 50 +++++++++++++++++++ .../handler/grpc_handler_integration_test.go | 32 +++++++++++- 2 files changed, 81 insertions(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index e73eb168f..d23a29a68 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -231,3 +231,53 @@ VALUES (1234, 'someClient'); return nil } + +func (c *TestDataController) AddGetFileStatsTestData() error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) +VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash) +VALUES (1234,'exampleId','exampleId:examplePath','exampleId:examplePath','f','filename','examplePath','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 19df93947..8659f6e14 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -124,7 +124,37 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } if getFileMetaDataResp.MetaData.FileMetaData.Name != "filename" { - t.Fatal("unexpected path from GetFileMetaData rpc") + t.Fatal("unexpected file name from GetFileMetaData rpc") + } + }) + + t.Run("TestGetFileStats", func(t *testing.T) { + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetFileStatsTestData() + if err != nil { + t.Fatal(err) + } + + req := &blobbergrpc.GetFileStatsRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: "exampleTransaction", + }, + Path: "examplePath", + PathHash: "exampleId:examplePath", + } + + getFileStatsResp, err := blobberClient.GetFileStats(ctx, req) + if err != nil { + t.Fatal(err) + } + + if getFileStatsResp.MetaData.FileMetaData.Name != "filename" { + t.Fatal("unexpected file name from GetFileStats rpc") } }) From 1a88e6ab05e142c3e96eb47f062838c1164b29c7 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 10 May 2021 02:10:45 +0530 Subject: [PATCH 008/183] :white_check_mark: GetObjectPath integration tests --- .../handler/grpc_handler_helper_unit_test.go | 42 +++++++++++++++++++ .../handler/grpc_handler_integration_test.go | 31 ++++++++++++++ 2 files changed, 73 insertions(+) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index d23a29a68..9defb308a 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -281,3 +281,45 @@ VALUES (1234,'exampleId','exampleId:examplePath','exampleId:examplePath','f','fi return nil } + +func (c *TestDataController) AddGetObjectPathTestData() error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) +VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 8659f6e14..845724f8f 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -158,4 +158,35 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } }) + t.Run("TestGetObjectPath", func(t *testing.T) { + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetObjectPathTestData() + if err != nil { + t.Fatal(err) + } + + req := &blobbergrpc.GetObjectPathRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: "exampleTransaction", + }, + Allocation: "", + Path: "examplePath", + BlockNum: "0", + } + + getObjectPathResp, err := blobberClient.GetObjectPath(ctx, req) + if err != nil { + t.Fatal(err) + } + + if getObjectPathResp.ObjectPath.Path.DirMetaData.Path != "/" { + t.Fatal("unexpected root hash from GetObjectPath rpc") + } + }) + } From 92a753088bcc4ed10ca3eaf8538f573f1e661b9a Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 10 May 2021 02:22:50 +0530 Subject: [PATCH 009/183] :white_check_mark: added list entities integration tests --- .../handler/grpc_handler_helper_unit_test.go | 50 +++++++++++++++++++ .../handler/grpc_handler_integration_test.go | 32 ++++++++++++ 2 files changed, 82 insertions(+) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 9defb308a..4d0f992c9 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -282,6 +282,56 @@ VALUES (1234,'exampleId','exampleId:examplePath','exampleId:examplePath','f','fi return nil } +func (c *TestDataController) AddListEntitiesTestData() error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) +VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash) +VALUES (1234,'exampleId','exampleId:examplePath','exampleId:examplePath','f','filename','examplePath','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} + func (c *TestDataController) AddGetObjectPathTestData() error { var err error var tx *sql.Tx diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 845724f8f..d59e0c94f 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -158,6 +158,38 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } }) + t.Run("TestListEntities", func(t *testing.T) { + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddListEntitiesTestData() + if err != nil { + t.Fatal(err) + } + + req := &blobbergrpc.ListEntitiesRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: "exampleTransaction", + }, + Path: "examplePath", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: "", + } + + listEntitiesResp, err := blobberClient.ListEntities(ctx, req) + if err != nil { + t.Fatal(err) + } + + if listEntitiesResp.MetaData.DirMetaData.Path != "examplePath" { + t.Fatal("unexpected path from ListEntities rpc") + } + }) + t.Run("TestGetObjectPath", func(t *testing.T) { err := tdController.ClearDatabase() if err != nil { From 374535ba1c6dad7ba6effe59debb0bdce178af42 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 10 May 2021 02:41:51 +0530 Subject: [PATCH 010/183] :white_check_mark: added GetReferencePath integration test --- .../handler/grpc_handler_helper_unit_test.go | 42 +++++++++++++++++++ .../handler/grpc_handler_integration_test.go | 30 +++++++++++++ 2 files changed, 72 insertions(+) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 4d0f992c9..fd9540e46 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -373,3 +373,45 @@ VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKe return nil } + +func (c *TestDataController) AddGetReferencePathTestData() error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) +VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index d59e0c94f..93ceed8bc 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -221,4 +221,34 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } }) + t.Run("TestGetReferencePath", func(t *testing.T) { + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetReferencePathTestData() + if err != nil { + t.Fatal(err) + } + + req := &blobbergrpc.GetReferencePathRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: "exampleTransaction", + }, + Paths: "", + Path: "/", + Allocation: "", + } + getReferencePathResp, err := blobberClient.GetReferencePath(ctx, req) + if err != nil { + t.Fatal(err) + } + + if getReferencePathResp.ReferencePath.MetaData.DirMetaData.Path != "/" { + t.Fatal("unexpected path from GetReferencePath rpc") + } + }) + } From 2d399fca09b537df79a6b3d1d3bdcf929823ecc6 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 10 May 2021 02:58:54 +0530 Subject: [PATCH 011/183] :white_check_mark: added GetObjectTree rpc integration tests --- .../handler/grpc_handler_helper_unit_test.go | 50 +++++++++++++++++++ .../handler/grpc_handler_integration_test.go | 35 +++++++++++-- 2 files changed, 82 insertions(+), 3 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index fd9540e46..b070c8eef 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -415,3 +415,53 @@ VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKe return nil } + +func (c *TestDataController) AddGetObjectTreeTestData() error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) +VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash) +VALUES (1234,'exampleId','exampleId:examplePath','exampleId:examplePath','d','root','/','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 93ceed8bc..d897b7f73 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -29,9 +29,9 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { for _, arg := range os.Args { args[arg] = true } - //if !args["integration"] { - // t.Skip() - //} + if !args["integration"] { + t.Skip() + } ctx := context.Background() @@ -251,4 +251,33 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } }) + t.Run("TestGetObjectTree", func(t *testing.T) { + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetObjectTreeTestData() + if err != nil { + t.Fatal(err) + } + + req := &blobbergrpc.GetObjectTreeRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: "exampleTransaction", + }, + Path: "/", + Allocation: "", + } + getObjectTreeResp, err := blobberClient.GetObjectTree(ctx, req) + if err != nil { + t.Fatal(err) + } + + if getObjectTreeResp.ReferencePath.MetaData.DirMetaData.Name != "root" { + t.Fatal("unexpected root name from GetObject") + } + }) + } From bb6e89f0264641c1b9aa3a4edf4dc6deadffa964 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 10 May 2021 17:33:54 +0530 Subject: [PATCH 012/183] :recycle: moved go.mod to parent Directory and updated import paths --- .../0chain.net/blobber/integration_tests.go | 4 +-- code/go/0chain.net/blobber/main.go | 34 +++++++++--------- .../allocation/allocationchange.go | 8 ++--- .../allocation/attributesfilechange.go | 8 ++--- .../blobbercore/allocation/copyfilechange.go | 4 +-- .../allocation/deletefilechange.go | 10 +++--- .../blobbercore/allocation/entity.go | 2 +- .../blobbercore/allocation/newfilechange.go | 10 +++--- .../blobbercore/allocation/protocol.go | 12 +++---- .../allocation/renamefilechange.go | 10 +++--- .../allocation/updatefilechange.go | 12 +++---- .../blobbercore/allocation/workers.go | 14 ++++---- .../blobbercore/challenge/entity.go | 8 ++--- .../blobbercore/challenge/protocol.go | 18 +++++----- .../0chain.net/blobbercore/challenge/stats.go | 4 +-- .../blobbercore/challenge/worker.go | 14 ++++---- .../0chain.net/blobbercore/config/config.go | 2 +- .../blobbercore/constants/context_key.go | 2 +- .../0chain.net/blobbercore/datastore/store.go | 6 ++-- .../0chain.net/blobbercore/errors/errors.go | 2 +- .../blobbercore/filestore/fs_store.go | 10 +++--- .../0chain.net/blobbercore/filestore/store.go | 2 +- .../0chain.net/blobbercore/handler/convert.go | 8 ++--- code/go/0chain.net/blobbercore/handler/dto.go | 8 ++--- .../blobbercore/handler/grpcMiddleware.go | 4 +-- .../blobbercore/handler/grpc_handler.go | 8 ++--- .../handler/grpc_handler_helper_unit_test.go | 4 +-- .../blobbercore/handler/grpc_handler_test.go | 8 ++--- .../handler/grpc_handler_unit_test.go | 10 +++--- .../0chain.net/blobbercore/handler/handler.go | 12 +++---- .../handler/handler_integration_tests.go | 14 ++++---- .../blobbercore/handler/handler_test.go | 35 ++++++++++--------- .../0chain.net/blobbercore/handler/helper.go | 12 +++---- .../handler/object_operation_handler.go | 30 ++++++++-------- .../blobbercore/handler/protocol.go | 8 ++--- .../blobbercore/handler/storage_handler.go | 18 +++++----- .../0chain.net/blobbercore/handler/worker.go | 16 ++++----- .../blobbercore/mocks/PackageHandler.go | 8 ++--- .../blobbercore/readmarker/entity.go | 10 +++--- .../blobbercore/readmarker/protocol.go | 18 +++++----- .../blobbercore/readmarker/worker.go | 10 +++--- .../blobbercore/reference/collaborator.go | 2 +- .../blobbercore/reference/commitmetatxn.go | 2 +- .../blobbercore/reference/objectpath.go | 4 +-- .../0chain.net/blobbercore/reference/ref.go | 6 ++-- .../blobbercore/reference/referencepath.go | 4 +-- .../blobbercore/stats/allocationstats.go | 2 +- .../blobbercore/stats/blobberstats.go | 12 +++---- .../0chain.net/blobbercore/stats/filestats.go | 2 +- .../0chain.net/blobbercore/stats/handler.go | 8 ++--- .../blobbercore/writemarker/entity.go | 6 ++-- .../blobbercore/writemarker/protocol.go | 16 ++++----- .../blobbercore/writemarker/worker.go | 8 ++--- .../0chain.net/conductor/conductrpc/server.go | 2 +- .../0chain.net/conductor/conductrpc/state.go | 2 +- code/go/0chain.net/core/chain/entity.go | 4 +-- code/go/0chain.net/core/common/context.go | 2 +- code/go/0chain.net/core/encryption/keys.go | 4 +-- code/go/0chain.net/core/node/context.go | 2 +- code/go/0chain.net/core/node/self_node.go | 4 +-- code/go/0chain.net/core/transaction/entity.go | 6 ++-- code/go/0chain.net/core/transaction/http.go | 16 +++++---- code/go/0chain.net/core/util/http.go | 8 ++--- .../core/util/merkle_tree_interface.go | 2 +- .../0chain.net/core/util/merkle_tree_test.go | 2 +- code/go/0chain.net/core/util/secure_value.go | 2 +- code/go/0chain.net/validator/main.go | 24 ++++++------- .../0chain.net/validatorcore/config/config.go | 2 +- .../storage/challenge_handler.go | 8 ++--- .../storage/challenge_handler_test.go | 4 +-- .../validatorcore/storage/context.go | 2 +- .../validatorcore/storage/handler.go | 2 +- .../validatorcore/storage/models.go | 12 +++---- .../validatorcore/storage/models_test.go | 10 +++--- .../validatorcore/storage/protocol.go | 12 +++---- .../storage/writemarker/entity.go | 4 +-- .../storage/writemarker/entity_test.go | 8 ++--- code/go/0chain.net/go.mod => go.mod | 2 +- code/go/0chain.net/go.sum => go.sum | 0 79 files changed, 329 insertions(+), 326 deletions(-) rename code/go/0chain.net/go.mod => go.mod (97%) rename code/go/0chain.net/go.sum => go.sum (100%) diff --git a/code/go/0chain.net/blobber/integration_tests.go b/code/go/0chain.net/blobber/integration_tests.go index 381e5f963..5ac88c2fa 100644 --- a/code/go/0chain.net/blobber/integration_tests.go +++ b/code/go/0chain.net/blobber/integration_tests.go @@ -3,9 +3,9 @@ package main import ( - "0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/logging" - crpc "0chain.net/conductor/conductrpc" // integration tests + crpc "github.com/0chain/blobber/code/go/0chain.net/conductor/conductrpc" // integration tests ) // start lock, where the miner is ready to connect to blockchain (BC) diff --git a/code/go/0chain.net/blobber/main.go b/code/go/0chain.net/blobber/main.go index 322c27232..b5d5fee64 100644 --- a/code/go/0chain.net/blobber/main.go +++ b/code/go/0chain.net/blobber/main.go @@ -15,23 +15,23 @@ import ( "strings" "time" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/challenge" - "0chain.net/blobbercore/config" - "0chain.net/blobbercore/datastore" - "0chain.net/blobbercore/filestore" - "0chain.net/blobbercore/handler" - "0chain.net/blobbercore/readmarker" - "0chain.net/blobbercore/writemarker" - "0chain.net/core/build" - "0chain.net/core/chain" - "0chain.net/core/common" - "0chain.net/core/encryption" - "0chain.net/core/logging" - . "0chain.net/core/logging" - "0chain.net/core/node" - "0chain.net/core/transaction" - "0chain.net/core/util" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/challenge" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/handler" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/build" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/transaction" + "github.com/0chain/blobber/code/go/0chain.net/core/util" "github.com/0chain/gosdk/zcncore" "github.com/gorilla/handlers" diff --git a/code/go/0chain.net/blobbercore/allocation/allocationchange.go b/code/go/0chain.net/blobbercore/allocation/allocationchange.go index 3f3a117b6..09c124885 100644 --- a/code/go/0chain.net/blobbercore/allocation/allocationchange.go +++ b/code/go/0chain.net/blobbercore/allocation/allocationchange.go @@ -4,10 +4,10 @@ import ( "context" "errors" - "0chain.net/blobbercore/datastore" - "0chain.net/blobbercore/reference" - "0chain.net/core/common" - "0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" "gorm.io/gorm" diff --git a/code/go/0chain.net/blobbercore/allocation/attributesfilechange.go b/code/go/0chain.net/blobbercore/allocation/attributesfilechange.go index 64bb9807a..6b2860aab 100644 --- a/code/go/0chain.net/blobbercore/allocation/attributesfilechange.go +++ b/code/go/0chain.net/blobbercore/allocation/attributesfilechange.go @@ -5,11 +5,11 @@ import ( "encoding/json" "path/filepath" - "0chain.net/blobbercore/reference" - "0chain.net/blobbercore/stats" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/core/common" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/allocation/copyfilechange.go b/code/go/0chain.net/blobbercore/allocation/copyfilechange.go index 63426ea0a..df52b209b 100644 --- a/code/go/0chain.net/blobbercore/allocation/copyfilechange.go +++ b/code/go/0chain.net/blobbercore/allocation/copyfilechange.go @@ -5,8 +5,8 @@ import ( "encoding/json" "path/filepath" - "0chain.net/blobbercore/reference" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "gorm.io/datatypes" ) diff --git a/code/go/0chain.net/blobbercore/allocation/deletefilechange.go b/code/go/0chain.net/blobbercore/allocation/deletefilechange.go index 83affa99e..114f7f0c7 100644 --- a/code/go/0chain.net/blobbercore/allocation/deletefilechange.go +++ b/code/go/0chain.net/blobbercore/allocation/deletefilechange.go @@ -5,11 +5,11 @@ import ( "encoding/json" "path/filepath" - "0chain.net/blobbercore/datastore" - "0chain.net/blobbercore/filestore" - "0chain.net/blobbercore/reference" - "0chain.net/core/common" - . "0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/allocation/entity.go b/code/go/0chain.net/blobbercore/allocation/entity.go index 62a11125a..68e836ad1 100644 --- a/code/go/0chain.net/blobbercore/allocation/entity.go +++ b/code/go/0chain.net/blobbercore/allocation/entity.go @@ -4,7 +4,7 @@ import ( "errors" "time" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "gorm.io/gorm" "gorm.io/gorm/clause" diff --git a/code/go/0chain.net/blobbercore/allocation/newfilechange.go b/code/go/0chain.net/blobbercore/allocation/newfilechange.go index 280e2cd6d..6be0c2e92 100644 --- a/code/go/0chain.net/blobbercore/allocation/newfilechange.go +++ b/code/go/0chain.net/blobbercore/allocation/newfilechange.go @@ -6,11 +6,11 @@ import ( "path/filepath" "strings" - "0chain.net/blobbercore/filestore" - "0chain.net/blobbercore/reference" - "0chain.net/blobbercore/stats" - "0chain.net/blobbercore/util" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/util" + "github.com/0chain/blobber/code/go/0chain.net/core/common" ) type NewFileChange struct { diff --git a/code/go/0chain.net/blobbercore/allocation/protocol.go b/code/go/0chain.net/blobbercore/allocation/protocol.go index 01c07bf26..aa9f842bb 100644 --- a/code/go/0chain.net/blobbercore/allocation/protocol.go +++ b/code/go/0chain.net/blobbercore/allocation/protocol.go @@ -6,12 +6,12 @@ import ( "errors" "fmt" - "0chain.net/blobbercore/datastore" - "0chain.net/core/chain" - "0chain.net/core/common" - . "0chain.net/core/logging" - "0chain.net/core/node" - "0chain.net/core/transaction" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/transaction" "gorm.io/gorm" ) diff --git a/code/go/0chain.net/blobbercore/allocation/renamefilechange.go b/code/go/0chain.net/blobbercore/allocation/renamefilechange.go index fe04d10f8..b4b7d9e97 100644 --- a/code/go/0chain.net/blobbercore/allocation/renamefilechange.go +++ b/code/go/0chain.net/blobbercore/allocation/renamefilechange.go @@ -5,10 +5,10 @@ import ( "encoding/json" "path/filepath" - "0chain.net/blobbercore/reference" - "0chain.net/blobbercore/stats" - "0chain.net/core/common" - ."0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) @@ -76,7 +76,7 @@ func (rf *RenameFileChange) ProcessChange(ctx context.Context, change *Allocatio } } if idx < 0 { - Logger.Error("error in file rename", zap.Any("change",rf)) + Logger.Error("error in file rename", zap.Any("change", rf)) return nil, common.NewError("file_not_found", "File to rename not found in blobber") } //dirRef.Children[idx] = affectedRef diff --git a/code/go/0chain.net/blobbercore/allocation/updatefilechange.go b/code/go/0chain.net/blobbercore/allocation/updatefilechange.go index 835cd36ce..d06006f12 100644 --- a/code/go/0chain.net/blobbercore/allocation/updatefilechange.go +++ b/code/go/0chain.net/blobbercore/allocation/updatefilechange.go @@ -5,12 +5,12 @@ import ( "encoding/json" "path/filepath" - "0chain.net/blobbercore/filestore" - "0chain.net/blobbercore/stats" - "0chain.net/blobbercore/reference" - "0chain.net/blobbercore/util" - "0chain.net/core/common" - . "0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/util" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/allocation/workers.go b/code/go/0chain.net/blobbercore/allocation/workers.go index bbd0c1c37..be54375c5 100644 --- a/code/go/0chain.net/blobbercore/allocation/workers.go +++ b/code/go/0chain.net/blobbercore/allocation/workers.go @@ -8,16 +8,16 @@ import ( "math/big" "time" - "0chain.net/blobbercore/datastore" - "0chain.net/blobbercore/reference" - "0chain.net/core/chain" - "0chain.net/core/common" - "0chain.net/core/lock" - "0chain.net/core/transaction" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/lock" + "github.com/0chain/blobber/code/go/0chain.net/core/transaction" "gorm.io/gorm" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/challenge/entity.go b/code/go/0chain.net/blobbercore/challenge/entity.go index 283c90f46..04fe275ca 100644 --- a/code/go/0chain.net/blobbercore/challenge/entity.go +++ b/code/go/0chain.net/blobbercore/challenge/entity.go @@ -5,10 +5,10 @@ import ( "encoding/json" "fmt" - "0chain.net/blobbercore/datastore" - "0chain.net/blobbercore/reference" - "0chain.net/core/common" - "0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "gorm.io/datatypes" ) diff --git a/code/go/0chain.net/blobbercore/challenge/protocol.go b/code/go/0chain.net/blobbercore/challenge/protocol.go index 74b86909c..0f2cc5dc5 100644 --- a/code/go/0chain.net/blobbercore/challenge/protocol.go +++ b/code/go/0chain.net/blobbercore/challenge/protocol.go @@ -6,15 +6,15 @@ import ( "math/rand" "time" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/filestore" - "0chain.net/blobbercore/reference" - "0chain.net/blobbercore/writemarker" - "0chain.net/core/chain" - "0chain.net/core/common" - . "0chain.net/core/logging" - "0chain.net/core/transaction" - "0chain.net/core/util" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/transaction" + "github.com/0chain/blobber/code/go/0chain.net/core/util" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/challenge/stats.go b/code/go/0chain.net/blobbercore/challenge/stats.go index 4a0e4e701..924a43fe0 100644 --- a/code/go/0chain.net/blobbercore/challenge/stats.go +++ b/code/go/0chain.net/blobbercore/challenge/stats.go @@ -3,8 +3,8 @@ package challenge import ( "context" - "0chain.net/blobbercore/datastore" - "0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" "gorm.io/gorm" ) diff --git a/code/go/0chain.net/blobbercore/challenge/worker.go b/code/go/0chain.net/blobbercore/challenge/worker.go index 7fca5bc7e..f04289b14 100644 --- a/code/go/0chain.net/blobbercore/challenge/worker.go +++ b/code/go/0chain.net/blobbercore/challenge/worker.go @@ -7,17 +7,17 @@ import ( "errors" "time" - "0chain.net/blobbercore/config" - "0chain.net/blobbercore/datastore" - "0chain.net/core/chain" - "0chain.net/core/lock" - "0chain.net/core/node" - "0chain.net/core/transaction" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + "github.com/0chain/blobber/code/go/0chain.net/core/lock" + "github.com/0chain/blobber/code/go/0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/transaction" "github.com/remeh/sizedwaitgroup" "gorm.io/gorm" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/config/config.go b/code/go/0chain.net/blobbercore/config/config.go index bf95a8d8f..27c4fdc6d 100644 --- a/code/go/0chain.net/blobbercore/config/config.go +++ b/code/go/0chain.net/blobbercore/config/config.go @@ -5,7 +5,7 @@ import ( "strings" "time" - "0chain.net/core/config" + "github.com/0chain/blobber/code/go/0chain.net/core/config" "github.com/spf13/viper" ) diff --git a/code/go/0chain.net/blobbercore/constants/context_key.go b/code/go/0chain.net/blobbercore/constants/context_key.go index 4f194283f..d7be3edc7 100644 --- a/code/go/0chain.net/blobbercore/constants/context_key.go +++ b/code/go/0chain.net/blobbercore/constants/context_key.go @@ -1,6 +1,6 @@ package constants -import "0chain.net/core/common" +import "github.com/0chain/blobber/code/go/0chain.net/core/common" const ( ALLOCATION_CONTEXT_KEY common.ContextKey = "allocation" diff --git a/code/go/0chain.net/blobbercore/datastore/store.go b/code/go/0chain.net/blobbercore/datastore/store.go index 6f4de4f3f..497ee6b55 100644 --- a/code/go/0chain.net/blobbercore/datastore/store.go +++ b/code/go/0chain.net/blobbercore/datastore/store.go @@ -5,13 +5,13 @@ import ( "fmt" "time" - "0chain.net/blobbercore/config" - "0chain.net/blobbercore/errors" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/errors" "gorm.io/driver/postgres" "gorm.io/gorm" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" ) type contextKey int diff --git a/code/go/0chain.net/blobbercore/errors/errors.go b/code/go/0chain.net/blobbercore/errors/errors.go index 9c40236d5..acd03356f 100644 --- a/code/go/0chain.net/blobbercore/errors/errors.go +++ b/code/go/0chain.net/blobbercore/errors/errors.go @@ -1,7 +1,7 @@ package errors import ( - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/common" ) var ( diff --git a/code/go/0chain.net/blobbercore/filestore/fs_store.go b/code/go/0chain.net/blobbercore/filestore/fs_store.go index edb41a286..9e5b20d54 100644 --- a/code/go/0chain.net/blobbercore/filestore/fs_store.go +++ b/code/go/0chain.net/blobbercore/filestore/fs_store.go @@ -13,15 +13,15 @@ import ( "path/filepath" "strings" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" - "0chain.net/core/common" - "0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" - "0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" - "0chain.net/core/util" + "github.com/0chain/blobber/code/go/0chain.net/core/util" "github.com/minio/minio-go" "golang.org/x/crypto/sha3" ) diff --git a/code/go/0chain.net/blobbercore/filestore/store.go b/code/go/0chain.net/blobbercore/filestore/store.go index 3e2b718fa..ce7f49531 100644 --- a/code/go/0chain.net/blobbercore/filestore/store.go +++ b/code/go/0chain.net/blobbercore/filestore/store.go @@ -4,7 +4,7 @@ import ( "encoding/json" "mime/multipart" - "0chain.net/core/util" + "github.com/0chain/blobber/code/go/0chain.net/core/util" ) const CHUNK_SIZE = 64 * 1024 diff --git a/code/go/0chain.net/blobbercore/handler/convert.go b/code/go/0chain.net/blobbercore/handler/convert.go index bc5f699f5..5647ba52e 100644 --- a/code/go/0chain.net/blobbercore/handler/convert.go +++ b/code/go/0chain.net/blobbercore/handler/convert.go @@ -1,10 +1,10 @@ package handler import ( - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/blobbergrpc" - "0chain.net/blobbercore/stats" - "0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" ) func AllocationToGRPCAllocation(alloc *allocation.Allocation) *blobbergrpc.Allocation { diff --git a/code/go/0chain.net/blobbercore/handler/dto.go b/code/go/0chain.net/blobbercore/handler/dto.go index 2edcf2b26..08b74cd24 100644 --- a/code/go/0chain.net/blobbercore/handler/dto.go +++ b/code/go/0chain.net/blobbercore/handler/dto.go @@ -1,10 +1,10 @@ package handler import ( - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/readmarker" - "0chain.net/blobbercore/reference" - "0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" ) type UploadResult struct { diff --git a/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go b/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go index 867b8b271..497160099 100644 --- a/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go +++ b/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go @@ -4,8 +4,8 @@ import ( "context" "time" - "0chain.net/core/common" - "0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/logging" grpc_zap "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap" "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap/ctxzap" grpc_ratelimit "github.com/grpc-ecosystem/go-grpc-middleware/ratelimit" diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index dfb361511..1b61abec9 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -5,17 +5,17 @@ import ( "encoding/json" "strconv" - "0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" - "0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap/ctxzap" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "go.uber.org/zap" - "0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" ) type blobberGRPCService struct { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 66345b7ab..8d5f8ab55 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -3,8 +3,8 @@ package handler import ( "context" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" "github.com/stretchr/testify/mock" ) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go index 4d75cd05f..a53fd86d8 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go @@ -10,10 +10,10 @@ import ( rl "go.uber.org/ratelimit" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/blobbergrpc" - "0chain.net/blobbercore/datastore" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/DATA-DOG/go-sqlmock" "github.com/gorilla/mux" "github.com/stretchr/testify/assert" diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index 79d576b97..e5da18df2 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -5,19 +5,19 @@ import ( "errors" "testing" - "0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" - "0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "0chain.net/blobbercore/mocks" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" "github.com/stretchr/testify/assert" - "0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/stretchr/testify/mock" - "0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" ) func TestBlobberGRPCService_GetAllocation_Success(t *testing.T) { diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 49da5ac50..306d83c47 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -9,13 +9,13 @@ import ( "runtime/pprof" "time" - "0chain.net/blobbercore/config" - "0chain.net/blobbercore/constants" - "0chain.net/blobbercore/datastore" - "0chain.net/blobbercore/stats" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/core/common" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" "github.com/gorilla/mux" diff --git a/code/go/0chain.net/blobbercore/handler/handler_integration_tests.go b/code/go/0chain.net/blobbercore/handler/handler_integration_tests.go index d386f15b1..9f67e0ab5 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_integration_tests.go +++ b/code/go/0chain.net/blobbercore/handler/handler_integration_tests.go @@ -13,17 +13,17 @@ import ( "os" "runtime/pprof" - "0chain.net/blobbercore/config" - "0chain.net/blobbercore/constants" - "0chain.net/blobbercore/datastore" - "0chain.net/blobbercore/stats" - "0chain.net/core/common" - "0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/node" "github.com/gorilla/mux" // integration tests RPC control - crpc "0chain.net/conductor/conductrpc" + crpc "github.com/0chain/blobber/code/go/0chain.net/conductor/conductrpc" ) var storageHandler StorageHandler diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go index 0f613734d..49614a930 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/handler_test.go @@ -1,26 +1,9 @@ package handler import ( - "0chain.net/blobbercore/allocation" - bconfig "0chain.net/blobbercore/config" - "0chain.net/blobbercore/datastore" - "0chain.net/blobbercore/filestore" - "0chain.net/blobbercore/reference" - "0chain.net/core/chain" - "0chain.net/core/common" - "0chain.net/core/config" - "0chain.net/core/encryption" - "0chain.net/core/logging" "bytes" "encoding/json" "errors" - "github.com/0chain/gosdk/core/zcncrypto" - "github.com/0chain/gosdk/zcncore" - "github.com/DATA-DOG/go-sqlmock" - "github.com/gorilla/mux" - "github.com/stretchr/testify/assert" - "go.uber.org/zap" - "gorm.io/gorm" "io" "mime/multipart" "net/http" @@ -29,6 +12,24 @@ import ( "regexp" "testing" "time" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + bconfig "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/config" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/gosdk/core/zcncrypto" + "github.com/0chain/gosdk/zcncore" + "github.com/DATA-DOG/go-sqlmock" + "github.com/gorilla/mux" + "github.com/stretchr/testify/assert" + "go.uber.org/zap" + "gorm.io/gorm" ) func init() { diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index b412aa718..9f79cc9cb 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -3,16 +3,16 @@ package handler import ( "context" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/reference" - "0chain.net/blobbercore/stats" - "0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" "github.com/gorilla/mux" "github.com/grpc-ecosystem/grpc-gateway/v2/runtime" "google.golang.org/grpc" - "0chain.net/blobbercore/blobbergrpc" - "0chain.net/blobbercore/constants" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" ) func setupGRPCHandlerContext(ctx context.Context, r *blobbergrpc.RequestContext) context.Context { diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go index 59e6ddd26..cf0772e4f 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go @@ -10,25 +10,25 @@ import ( "path/filepath" "strconv" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/config" - "0chain.net/blobbercore/constants" - "0chain.net/blobbercore/datastore" - "0chain.net/blobbercore/filestore" - "0chain.net/blobbercore/readmarker" - "0chain.net/blobbercore/reference" - "0chain.net/blobbercore/stats" - "0chain.net/blobbercore/writemarker" - - "0chain.net/core/common" - "0chain.net/core/encryption" - "0chain.net/core/lock" - "0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/lock" + "github.com/0chain/blobber/code/go/0chain.net/core/node" "gorm.io/datatypes" "gorm.io/gorm" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/handler/protocol.go b/code/go/0chain.net/blobbercore/handler/protocol.go index 9a4bfa9e8..a59aa9104 100644 --- a/code/go/0chain.net/blobbercore/handler/protocol.go +++ b/code/go/0chain.net/blobbercore/handler/protocol.go @@ -7,10 +7,10 @@ import ( "sync" "time" - "0chain.net/blobbercore/config" - . "0chain.net/core/logging" - "0chain.net/core/node" - "0chain.net/core/transaction" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/transaction" "github.com/0chain/gosdk/zcncore" "go.uber.org/zap" diff --git a/code/go/0chain.net/blobbercore/handler/storage_handler.go b/code/go/0chain.net/blobbercore/handler/storage_handler.go index 92b924484..81fbfdca1 100644 --- a/code/go/0chain.net/blobbercore/handler/storage_handler.go +++ b/code/go/0chain.net/blobbercore/handler/storage_handler.go @@ -7,20 +7,20 @@ import ( "strconv" "strings" - "0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "github.com/gorilla/mux" - "0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" "go.uber.org/zap" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/constants" - "0chain.net/blobbercore/readmarker" - "0chain.net/blobbercore/reference" - "0chain.net/blobbercore/writemarker" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/common" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" ) const ( diff --git a/code/go/0chain.net/blobbercore/handler/worker.go b/code/go/0chain.net/blobbercore/handler/worker.go index 0716501a0..4a086c402 100644 --- a/code/go/0chain.net/blobbercore/handler/worker.go +++ b/code/go/0chain.net/blobbercore/handler/worker.go @@ -6,16 +6,16 @@ import ( "path/filepath" "time" - "0chain.net/blobbercore/filestore" - "0chain.net/blobbercore/reference" - "0chain.net/blobbercore/stats" - "0chain.net/core/lock" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/core/lock" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/config" - "0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 1d6dba917..e799e2409 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -5,15 +5,15 @@ package mocks import ( context "context" - blobbergrpc "0chain.net/blobbercore/blobbergrpc" + blobbergrpc "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" mock "github.com/stretchr/testify/mock" - reference "0chain.net/blobbercore/reference" + reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - stats "0chain.net/blobbercore/stats" + stats "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" - writemarker "0chain.net/blobbercore/writemarker" + writemarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" ) // PackageHandler is an autogenerated mock type for the PackageHandler type diff --git a/code/go/0chain.net/blobbercore/readmarker/entity.go b/code/go/0chain.net/blobbercore/readmarker/entity.go index be13cd12c..226590940 100644 --- a/code/go/0chain.net/blobbercore/readmarker/entity.go +++ b/code/go/0chain.net/blobbercore/readmarker/entity.go @@ -5,14 +5,14 @@ import ( "encoding/json" "fmt" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/datastore" - "0chain.net/core/common" - "0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "gorm.io/datatypes" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/readmarker/protocol.go b/code/go/0chain.net/blobbercore/readmarker/protocol.go index 1089a7dc9..fb2e08f4f 100644 --- a/code/go/0chain.net/blobbercore/readmarker/protocol.go +++ b/code/go/0chain.net/blobbercore/readmarker/protocol.go @@ -5,17 +5,17 @@ import ( "encoding/json" "time" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/constants" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" - "0chain.net/blobbercore/datastore" - "0chain.net/core/chain" - "0chain.net/core/common" - "0chain.net/core/encryption" - "0chain.net/core/node" - "0chain.net/core/transaction" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/transaction" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/readmarker/worker.go b/code/go/0chain.net/blobbercore/readmarker/worker.go index d700e3400..ffabc4764 100644 --- a/code/go/0chain.net/blobbercore/readmarker/worker.go +++ b/code/go/0chain.net/blobbercore/readmarker/worker.go @@ -5,11 +5,11 @@ import ( "encoding/json" "time" - "0chain.net/blobbercore/config" - "0chain.net/blobbercore/datastore" - "0chain.net/core/chain" - . "0chain.net/core/logging" - "0chain.net/core/transaction" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/transaction" "github.com/remeh/sizedwaitgroup" "go.uber.org/zap" diff --git a/code/go/0chain.net/blobbercore/reference/collaborator.go b/code/go/0chain.net/blobbercore/reference/collaborator.go index 65205ff67..748c6ad56 100644 --- a/code/go/0chain.net/blobbercore/reference/collaborator.go +++ b/code/go/0chain.net/blobbercore/reference/collaborator.go @@ -4,7 +4,7 @@ import ( "context" "time" - "0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" ) type Collaborator struct { diff --git a/code/go/0chain.net/blobbercore/reference/commitmetatxn.go b/code/go/0chain.net/blobbercore/reference/commitmetatxn.go index 6e52caeab..2c63e0d75 100644 --- a/code/go/0chain.net/blobbercore/reference/commitmetatxn.go +++ b/code/go/0chain.net/blobbercore/reference/commitmetatxn.go @@ -4,7 +4,7 @@ import ( "context" "time" - "0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" ) type CommitMetaTxn struct { diff --git a/code/go/0chain.net/blobbercore/reference/objectpath.go b/code/go/0chain.net/blobbercore/reference/objectpath.go index 3c5786dcf..a6fcef50c 100644 --- a/code/go/0chain.net/blobbercore/reference/objectpath.go +++ b/code/go/0chain.net/blobbercore/reference/objectpath.go @@ -4,9 +4,9 @@ import ( "context" "fmt" - "0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/common" ) type ObjectPath struct { diff --git a/code/go/0chain.net/blobbercore/reference/ref.go b/code/go/0chain.net/blobbercore/reference/ref.go index f422f501f..acd21b4e1 100644 --- a/code/go/0chain.net/blobbercore/reference/ref.go +++ b/code/go/0chain.net/blobbercore/reference/ref.go @@ -11,9 +11,9 @@ import ( "strings" "time" - "0chain.net/blobbercore/datastore" - "0chain.net/core/common" - "0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "gorm.io/datatypes" "gorm.io/gorm" diff --git a/code/go/0chain.net/blobbercore/reference/referencepath.go b/code/go/0chain.net/blobbercore/reference/referencepath.go index cc424a25e..cf1e1ab79 100644 --- a/code/go/0chain.net/blobbercore/reference/referencepath.go +++ b/code/go/0chain.net/blobbercore/reference/referencepath.go @@ -4,8 +4,8 @@ import ( "context" "path/filepath" - "0chain.net/blobbercore/datastore" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/core/common" ) func GetReferencePath(ctx context.Context, allocationID string, path string) (*Ref, error) { diff --git a/code/go/0chain.net/blobbercore/stats/allocationstats.go b/code/go/0chain.net/blobbercore/stats/allocationstats.go index fc0f2b6ab..55ddafaab 100644 --- a/code/go/0chain.net/blobbercore/stats/allocationstats.go +++ b/code/go/0chain.net/blobbercore/stats/allocationstats.go @@ -3,7 +3,7 @@ package stats import ( "time" - "0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" ) // Timestamp that implements standard fmt.Stringer interface. diff --git a/code/go/0chain.net/blobbercore/stats/blobberstats.go b/code/go/0chain.net/blobbercore/stats/blobberstats.go index 080088a1b..2b48ab486 100644 --- a/code/go/0chain.net/blobbercore/stats/blobberstats.go +++ b/code/go/0chain.net/blobbercore/stats/blobberstats.go @@ -6,14 +6,14 @@ import ( "encoding/json" "time" - "0chain.net/blobbercore/config" - "0chain.net/blobbercore/datastore" - "0chain.net/blobbercore/filestore" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/core/common" - "0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/node" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" "gorm.io/datatypes" diff --git a/code/go/0chain.net/blobbercore/stats/filestats.go b/code/go/0chain.net/blobbercore/stats/filestats.go index 8ce642387..76ac3d2b0 100644 --- a/code/go/0chain.net/blobbercore/stats/filestats.go +++ b/code/go/0chain.net/blobbercore/stats/filestats.go @@ -3,7 +3,7 @@ package stats import ( "context" - "0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" "gorm.io/gorm" ) diff --git a/code/go/0chain.net/blobbercore/stats/handler.go b/code/go/0chain.net/blobbercore/stats/handler.go index aacd60049..df05e92f2 100644 --- a/code/go/0chain.net/blobbercore/stats/handler.go +++ b/code/go/0chain.net/blobbercore/stats/handler.go @@ -6,10 +6,10 @@ import ( "html/template" "net/http" - "0chain.net/blobbercore/constants" - "0chain.net/blobbercore/datastore" - "0chain.net/core/common" - . "0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/writemarker/entity.go b/code/go/0chain.net/blobbercore/writemarker/entity.go index 64636208e..27b7c5e4f 100644 --- a/code/go/0chain.net/blobbercore/writemarker/entity.go +++ b/code/go/0chain.net/blobbercore/writemarker/entity.go @@ -5,9 +5,9 @@ import ( "encoding/json" "fmt" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/datastore" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/core/common" ) type WriteMarker struct { diff --git a/code/go/0chain.net/blobbercore/writemarker/protocol.go b/code/go/0chain.net/blobbercore/writemarker/protocol.go index c152adde2..d4e3a7e56 100644 --- a/code/go/0chain.net/blobbercore/writemarker/protocol.go +++ b/code/go/0chain.net/blobbercore/writemarker/protocol.go @@ -5,14 +5,14 @@ import ( "encoding/json" "time" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/constants" - "0chain.net/core/chain" - "0chain.net/core/common" - "0chain.net/core/encryption" - . "0chain.net/core/logging" - "0chain.net/core/node" - "0chain.net/core/transaction" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/transaction" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/blobbercore/writemarker/worker.go b/code/go/0chain.net/blobbercore/writemarker/worker.go index 7456d5d49..84a112a13 100644 --- a/code/go/0chain.net/blobbercore/writemarker/worker.go +++ b/code/go/0chain.net/blobbercore/writemarker/worker.go @@ -4,10 +4,10 @@ import ( "context" "time" - "0chain.net/blobbercore/allocation" - "0chain.net/blobbercore/config" - "0chain.net/blobbercore/datastore" - . "0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "github.com/remeh/sizedwaitgroup" "go.uber.org/zap" diff --git a/code/go/0chain.net/conductor/conductrpc/server.go b/code/go/0chain.net/conductor/conductrpc/server.go index 2b0d0de97..01979c52a 100644 --- a/code/go/0chain.net/conductor/conductrpc/server.go +++ b/code/go/0chain.net/conductor/conductrpc/server.go @@ -3,7 +3,7 @@ package conductrpc import ( "errors" - "0chain.net/conductor/config" + "github.com/0chain/blobber/code/go/0chain.net/conductor/config" ) var ErrShutdown = errors.New("server shutdown") diff --git a/code/go/0chain.net/conductor/conductrpc/state.go b/code/go/0chain.net/conductor/conductrpc/state.go index c3ab62d8a..7f723162f 100644 --- a/code/go/0chain.net/conductor/conductrpc/state.go +++ b/code/go/0chain.net/conductor/conductrpc/state.go @@ -1,7 +1,7 @@ package conductrpc import ( - "0chain.net/conductor/config" + "github.com/0chain/blobber/code/go/0chain.net/conductor/config" ) // diff --git a/code/go/0chain.net/core/chain/entity.go b/code/go/0chain.net/core/chain/entity.go index ad2825e86..7360a4f93 100644 --- a/code/go/0chain.net/core/chain/entity.go +++ b/code/go/0chain.net/core/chain/entity.go @@ -3,8 +3,8 @@ package chain import ( "context" - "0chain.net/core/common" - "0chain.net/core/config" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/config" "github.com/spf13/viper" ) diff --git a/code/go/0chain.net/core/common/context.go b/code/go/0chain.net/core/common/context.go index 63eebfb32..8d69fdcba 100644 --- a/code/go/0chain.net/core/common/context.go +++ b/code/go/0chain.net/core/common/context.go @@ -8,7 +8,7 @@ import ( "syscall" "time" - "0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/core/encryption/keys.go b/code/go/0chain.net/core/encryption/keys.go index bda80893a..28b80a843 100644 --- a/code/go/0chain.net/core/encryption/keys.go +++ b/code/go/0chain.net/core/encryption/keys.go @@ -4,8 +4,8 @@ import ( "bufio" "io" - "0chain.net/core/common" - "0chain.net/core/config" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/config" "github.com/0chain/gosdk/core/zcncrypto" ) diff --git a/code/go/0chain.net/core/node/context.go b/code/go/0chain.net/core/node/context.go index 9d41b740b..120c160cd 100644 --- a/code/go/0chain.net/core/node/context.go +++ b/code/go/0chain.net/core/node/context.go @@ -3,7 +3,7 @@ package node import ( "context" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/common" ) const SELF_NODE common.ContextKey = "SELF_NODE" diff --git a/code/go/0chain.net/core/node/self_node.go b/code/go/0chain.net/core/node/self_node.go index 573b9baf3..19afb1369 100644 --- a/code/go/0chain.net/core/node/self_node.go +++ b/code/go/0chain.net/core/node/self_node.go @@ -5,8 +5,8 @@ import ( "encoding/json" "fmt" - "0chain.net/core/common" - "0chain.net/core/config" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/config" "github.com/0chain/gosdk/core/zcncrypto" "golang.org/x/crypto/sha3" ) diff --git a/code/go/0chain.net/core/transaction/entity.go b/code/go/0chain.net/core/transaction/entity.go index 72f8eabe5..5353a0fcf 100644 --- a/code/go/0chain.net/core/transaction/entity.go +++ b/code/go/0chain.net/core/transaction/entity.go @@ -7,9 +7,9 @@ import ( "github.com/0chain/gosdk/zcncore" - "0chain.net/core/chain" - "0chain.net/core/common" - "0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/node" ) //Transaction entity that encapsulates the transaction related data and meta data diff --git a/code/go/0chain.net/core/transaction/http.go b/code/go/0chain.net/core/transaction/http.go index 11bab7fb7..8c8bd925b 100644 --- a/code/go/0chain.net/core/transaction/http.go +++ b/code/go/0chain.net/core/transaction/http.go @@ -15,13 +15,13 @@ import ( //"sync" "time" - "0chain.net/core/chain" - "0chain.net/core/common" - . "0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "github.com/0chain/gosdk/core/util" "github.com/0chain/gosdk/zcncore" - //"0chain.net/core/util" + //"github.com/0chain/blobber/code/go/0chain.net/core/util" "go.uber.org/zap" ) @@ -33,7 +33,7 @@ const REGISTER_CLIENT = "v1/client/put" const ( SLEEP_FOR_TXN_CONFIRMATION = 5 - SC_REST_API_ATTEMPTS = 3 + SC_REST_API_ATTEMPTS = 3 ) var ErrNoTxnDetail = common.NewError("missing_transaction_detail", "No transaction detail was found on any of the sharders") @@ -214,10 +214,12 @@ func MakeSCRestAPICall(scAddress string, relativePath string, params map[string] for counter > 0 { resp, err = netClient.Get(u.String()) - if err != nil { break } + if err != nil { + break + } // if it's not available, retry if there are any retry attempts - if (resp.StatusCode == 503 || resp.StatusCode == 504) { + if resp.StatusCode == 503 || resp.StatusCode == 504 { resp.Body.Close() counter-- } else { diff --git a/code/go/0chain.net/core/util/http.go b/code/go/0chain.net/core/util/http.go index 920af26d7..a1e983f33 100644 --- a/code/go/0chain.net/core/util/http.go +++ b/code/go/0chain.net/core/util/http.go @@ -8,10 +8,10 @@ import ( "sync" "time" - "0chain.net/core/common" - "0chain.net/core/encryption" - . "0chain.net/core/logging" - "0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/node" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/core/util/merkle_tree_interface.go b/code/go/0chain.net/core/util/merkle_tree_interface.go index 83c31f95a..4eeea3ede 100644 --- a/code/go/0chain.net/core/util/merkle_tree_interface.go +++ b/code/go/0chain.net/core/util/merkle_tree_interface.go @@ -1,6 +1,6 @@ package util -import "0chain.net/core/encryption" +import "github.com/0chain/blobber/code/go/0chain.net/core/encryption" /*MerkleTreeI - a merkle tree interface required for constructing and providing verification */ type MerkleTreeI interface { diff --git a/code/go/0chain.net/core/util/merkle_tree_test.go b/code/go/0chain.net/core/util/merkle_tree_test.go index da84b49af..57fe65380 100644 --- a/code/go/0chain.net/core/util/merkle_tree_test.go +++ b/code/go/0chain.net/core/util/merkle_tree_test.go @@ -5,7 +5,7 @@ import ( "math/rand" "testing" - "0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" ) type Txn struct { diff --git a/code/go/0chain.net/core/util/secure_value.go b/code/go/0chain.net/core/util/secure_value.go index 7b730fd32..78c8ff8ae 100644 --- a/code/go/0chain.net/core/util/secure_value.go +++ b/code/go/0chain.net/core/util/secure_value.go @@ -4,7 +4,7 @@ import ( "encoding/hex" "strings" - "0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" ) /*Hashable - anything that can provide it's hash */ diff --git a/code/go/0chain.net/validator/main.go b/code/go/0chain.net/validator/main.go index 684041f31..4d673d13e 100644 --- a/code/go/0chain.net/validator/main.go +++ b/code/go/0chain.net/validator/main.go @@ -10,18 +10,18 @@ import ( "strconv" "time" - "0chain.net/core/build" - "0chain.net/core/chain" - - "0chain.net/core/common" - "0chain.net/core/encryption" - "0chain.net/core/logging" - . "0chain.net/core/logging" - "0chain.net/core/node" - "0chain.net/core/transaction" - "0chain.net/core/util" - "0chain.net/validatorcore/config" - "0chain.net/validatorcore/storage" + "github.com/0chain/blobber/code/go/0chain.net/core/build" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/transaction" + "github.com/0chain/blobber/code/go/0chain.net/core/util" + "github.com/0chain/blobber/code/go/0chain.net/validatorcore/config" + "github.com/0chain/blobber/code/go/0chain.net/validatorcore/storage" "github.com/0chain/gosdk/zcncore" "github.com/gorilla/handlers" diff --git a/code/go/0chain.net/validatorcore/config/config.go b/code/go/0chain.net/validatorcore/config/config.go index 5194a62a4..f6ae4ce8f 100644 --- a/code/go/0chain.net/validatorcore/config/config.go +++ b/code/go/0chain.net/validatorcore/config/config.go @@ -3,7 +3,7 @@ package config import ( "fmt" - "0chain.net/core/config" + "github.com/0chain/blobber/code/go/0chain.net/core/config" "github.com/spf13/viper" ) diff --git a/code/go/0chain.net/validatorcore/storage/challenge_handler.go b/code/go/0chain.net/validatorcore/storage/challenge_handler.go index 528eb6531..ea3a78d01 100644 --- a/code/go/0chain.net/validatorcore/storage/challenge_handler.go +++ b/code/go/0chain.net/validatorcore/storage/challenge_handler.go @@ -8,10 +8,10 @@ import ( "net/http" "time" - "0chain.net/core/cache" - "0chain.net/core/common" - . "0chain.net/core/logging" - "0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/cache" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/node" "go.uber.org/zap" "golang.org/x/crypto/sha3" diff --git a/code/go/0chain.net/validatorcore/storage/challenge_handler_test.go b/code/go/0chain.net/validatorcore/storage/challenge_handler_test.go index 359d0720d..a4034d394 100644 --- a/code/go/0chain.net/validatorcore/storage/challenge_handler_test.go +++ b/code/go/0chain.net/validatorcore/storage/challenge_handler_test.go @@ -6,8 +6,8 @@ import ( "net/http" "testing" - "0chain.net/core/logging" - "0chain.net/validatorcore/storage" + "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/validatorcore/storage" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" diff --git a/code/go/0chain.net/validatorcore/storage/context.go b/code/go/0chain.net/validatorcore/storage/context.go index 79a977074..b39d37370 100644 --- a/code/go/0chain.net/validatorcore/storage/context.go +++ b/code/go/0chain.net/validatorcore/storage/context.go @@ -4,7 +4,7 @@ import ( "context" "net/http" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/common" ) func SetupContext(handler common.JSONResponderF) common.JSONResponderF { diff --git a/code/go/0chain.net/validatorcore/storage/handler.go b/code/go/0chain.net/validatorcore/storage/handler.go index 6f6e01713..bfa73f0ae 100644 --- a/code/go/0chain.net/validatorcore/storage/handler.go +++ b/code/go/0chain.net/validatorcore/storage/handler.go @@ -6,7 +6,7 @@ import ( "os" "runtime/pprof" - "0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/gorilla/mux" ) diff --git a/code/go/0chain.net/validatorcore/storage/models.go b/code/go/0chain.net/validatorcore/storage/models.go index e890fabe5..b64296932 100644 --- a/code/go/0chain.net/validatorcore/storage/models.go +++ b/code/go/0chain.net/validatorcore/storage/models.go @@ -8,15 +8,15 @@ import ( "strconv" "strings" - "0chain.net/core/common" - "0chain.net/core/encryption" - "0chain.net/core/node" - "0chain.net/core/util" - "0chain.net/validatorcore/storage/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/util" + "github.com/0chain/blobber/code/go/0chain.net/validatorcore/storage/writemarker" "github.com/mitchellh/mapstructure" - . "0chain.net/core/logging" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "go.uber.org/zap" ) diff --git a/code/go/0chain.net/validatorcore/storage/models_test.go b/code/go/0chain.net/validatorcore/storage/models_test.go index 6a12fbd88..1fb88e24e 100644 --- a/code/go/0chain.net/validatorcore/storage/models_test.go +++ b/code/go/0chain.net/validatorcore/storage/models_test.go @@ -3,11 +3,11 @@ package storage_test import ( "testing" - "0chain.net/core/common" - "0chain.net/core/config" - "0chain.net/core/logging" - "0chain.net/core/node" - "0chain.net/validatorcore/storage" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/config" + "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/validatorcore/storage" "github.com/0chain/gosdk/core/zcncrypto" "github.com/stretchr/testify/assert" diff --git a/code/go/0chain.net/validatorcore/storage/protocol.go b/code/go/0chain.net/validatorcore/storage/protocol.go index cc3ad9924..f9175988b 100644 --- a/code/go/0chain.net/validatorcore/storage/protocol.go +++ b/code/go/0chain.net/validatorcore/storage/protocol.go @@ -6,12 +6,12 @@ import ( "sync" "time" - "0chain.net/core/chain" - "0chain.net/core/common" - . "0chain.net/core/logging" - "0chain.net/core/node" - "0chain.net/core/transaction" - "0chain.net/validatorcore/config" + "github.com/0chain/blobber/code/go/0chain.net/core/chain" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + . "github.com/0chain/blobber/code/go/0chain.net/core/logging" + "github.com/0chain/blobber/code/go/0chain.net/core/node" + "github.com/0chain/blobber/code/go/0chain.net/core/transaction" + "github.com/0chain/blobber/code/go/0chain.net/validatorcore/config" "github.com/0chain/gosdk/zcncore" "go.uber.org/zap" diff --git a/code/go/0chain.net/validatorcore/storage/writemarker/entity.go b/code/go/0chain.net/validatorcore/storage/writemarker/entity.go index 0b44519f4..b5850d1eb 100644 --- a/code/go/0chain.net/validatorcore/storage/writemarker/entity.go +++ b/code/go/0chain.net/validatorcore/storage/writemarker/entity.go @@ -4,8 +4,8 @@ import ( "encoding/hex" "fmt" - "0chain.net/core/common" - "0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" ) type WriteMarkerEntity struct { diff --git a/code/go/0chain.net/validatorcore/storage/writemarker/entity_test.go b/code/go/0chain.net/validatorcore/storage/writemarker/entity_test.go index bdd4f0283..15b613d76 100644 --- a/code/go/0chain.net/validatorcore/storage/writemarker/entity_test.go +++ b/code/go/0chain.net/validatorcore/storage/writemarker/entity_test.go @@ -4,10 +4,10 @@ import ( "fmt" "testing" - "0chain.net/core/common" - "0chain.net/core/config" - "0chain.net/core/encryption" - "0chain.net/validatorcore/storage/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/config" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/validatorcore/storage/writemarker" "github.com/0chain/gosdk/core/zcncrypto" "github.com/stretchr/testify/assert" diff --git a/code/go/0chain.net/go.mod b/go.mod similarity index 97% rename from code/go/0chain.net/go.mod rename to go.mod index ef3b0dd34..71485072d 100644 --- a/code/go/0chain.net/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module 0chain.net +module github.com/0chain/blobber require ( github.com/0chain/gosdk v1.1.6 diff --git a/code/go/0chain.net/go.sum b/go.sum similarity index 100% rename from code/go/0chain.net/go.sum rename to go.sum From 6c28e3634b36b4b24eac8acdb85c0253e7d499f7 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 10 May 2021 17:40:58 +0530 Subject: [PATCH 013/183] :recycle: fixed test and lint --- .dockerignore | 0 .github/workflows/ci.yml | 0 .gitignore | 0 LICENSE.txt | 0 Makefile | 4 ++-- README.md | 0 bin/postgres-entrypoint.sh | 0 code/go/0chain.net/.vscode/settings.json | 0 code/go/0chain.net/blobber/integration_tests.go | 0 code/go/0chain.net/blobber/main.go | 0 code/go/0chain.net/blobber/stub.go | 0 .../blobbercore/allocation/allocationchange.go | 0 .../blobbercore/allocation/attributesfilechange.go | 0 .../blobbercore/allocation/copyfilechange.go | 0 .../blobbercore/allocation/deletefilechange.go | 0 code/go/0chain.net/blobbercore/allocation/entity.go | 0 .../blobbercore/allocation/newfilechange.go | 0 .../0chain.net/blobbercore/allocation/protocol.go | 0 .../blobbercore/allocation/renamefilechange.go | 0 .../blobbercore/allocation/updatefilechange.go | 0 .../go/0chain.net/blobbercore/allocation/workers.go | 0 .../go/0chain.net/blobbercore/blobbergrpc/README.md | 0 .../blobbercore/blobbergrpc/blobber.pb.go | 0 .../blobbercore/blobbergrpc/blobber.pb.gw.go | 0 .../blobbercore/blobbergrpc/blobber_grpc.pb.go | 0 .../blobbercore/blobbergrpc/proto/blobber.proto | 0 .../blobbergrpc/proto/google/api/annotations.proto | 0 .../blobbergrpc/proto/google/api/http.proto | 0 .../blobbergrpc/proto/google/api/httpbody.proto | 0 code/go/0chain.net/blobbercore/challenge/entity.go | 0 .../go/0chain.net/blobbercore/challenge/protocol.go | 0 code/go/0chain.net/blobbercore/challenge/stats.go | 0 code/go/0chain.net/blobbercore/challenge/worker.go | 0 code/go/0chain.net/blobbercore/config/config.go | 0 .../0chain.net/blobbercore/constants/context_key.go | 0 .../0chain.net/blobbercore/datastore/blob_type.go | 0 .../0chain.net/blobbercore/datastore/mock_store.go | 0 code/go/0chain.net/blobbercore/datastore/model.go | 0 code/go/0chain.net/blobbercore/datastore/store.go | 0 code/go/0chain.net/blobbercore/errors/errors.go | 0 .../go/0chain.net/blobbercore/filestore/fs_store.go | 0 code/go/0chain.net/blobbercore/filestore/store.go | 0 code/go/0chain.net/blobbercore/handler/convert.go | 0 code/go/0chain.net/blobbercore/handler/dto.go | 0 .../blobbercore/handler/grpcMiddleware.go | 0 .../0chain.net/blobbercore/handler/grpc_handler.go | 0 .../handler/grpc_handler_helper_unit_test.go | 0 .../blobbercore/handler/grpc_handler_test.go | 0 .../blobbercore/handler/grpc_handler_unit_test.go | 0 code/go/0chain.net/blobbercore/handler/handler.go | 0 .../handler/handler_integration_tests.go | 0 .../0chain.net/blobbercore/handler/handler_test.go | 0 code/go/0chain.net/blobbercore/handler/helper.go | 0 .../blobbercore/handler/object_operation_handler.go | 0 code/go/0chain.net/blobbercore/handler/protocol.go | 0 .../blobbercore/handler/storage_handler.go | 0 code/go/0chain.net/blobbercore/handler/worker.go | 0 code/go/0chain.net/blobbercore/handler/zcncore.go | 0 .../0chain.net/blobbercore/mocks/PackageHandler.go | 0 .../blobbercore/openapi/blobber.swagger.json | 0 code/go/0chain.net/blobbercore/readmarker/entity.go | 0 .../0chain.net/blobbercore/readmarker/protocol.go | 0 code/go/0chain.net/blobbercore/readmarker/worker.go | 0 .../blobbercore/reference/collaborator.go | 0 .../blobbercore/reference/commitmetatxn.go | 0 .../0chain.net/blobbercore/reference/objectpath.go | 0 code/go/0chain.net/blobbercore/reference/ref.go | 0 .../blobbercore/reference/referencepath.go | 0 .../0chain.net/blobbercore/stats/allocationstats.go | 0 .../go/0chain.net/blobbercore/stats/blobberstats.go | 0 code/go/0chain.net/blobbercore/stats/filestats.go | 0 code/go/0chain.net/blobbercore/stats/handler.go | 0 code/go/0chain.net/blobbercore/util/json.go | 0 .../go/0chain.net/blobbercore/writemarker/entity.go | 0 .../0chain.net/blobbercore/writemarker/protocol.go | 0 .../go/0chain.net/blobbercore/writemarker/worker.go | 0 code/go/0chain.net/conductor/build.go | 0 code/go/0chain.net/conductor/conductrpc/client.go | 0 code/go/0chain.net/conductor/conductrpc/entity.go | 0 code/go/0chain.net/conductor/conductrpc/resolve.go | 0 code/go/0chain.net/conductor/conductrpc/server.go | 0 code/go/0chain.net/conductor/conductrpc/state.go | 0 code/go/0chain.net/conductor/config/byzantine.go | 0 code/go/0chain.net/conductor/config/config.go | 0 code/go/0chain.net/core/build/info.go | 0 code/go/0chain.net/core/cache/cache.go | 0 code/go/0chain.net/core/cache/lfu.go | 0 code/go/0chain.net/core/cache/lru.go | 0 code/go/0chain.net/core/chain/entity.go | 0 code/go/0chain.net/core/common/context.go | 0 code/go/0chain.net/core/common/errors.go | 0 code/go/0chain.net/core/common/handler.go | 0 code/go/0chain.net/core/common/lookup.go | 0 code/go/0chain.net/core/common/rate_limiter.go | 0 code/go/0chain.net/core/common/time.go | 0 code/go/0chain.net/core/common/types.go | 0 code/go/0chain.net/core/common/utils.go | 0 code/go/0chain.net/core/config/config.go | 0 code/go/0chain.net/core/encryption/hash.go | 0 code/go/0chain.net/core/encryption/keys.go | 0 code/go/0chain.net/core/lock/lock.go | 0 code/go/0chain.net/core/logging/logger.go | 0 code/go/0chain.net/core/node/context.go | 0 code/go/0chain.net/core/node/self_node.go | 0 code/go/0chain.net/core/transaction/entity.go | 0 code/go/0chain.net/core/transaction/http.go | 0 code/go/0chain.net/core/transaction/type.go | 0 code/go/0chain.net/core/util/http.go | 0 code/go/0chain.net/core/util/merkle_tree.go | 0 .../0chain.net/core/util/merkle_tree_interface.go | 0 code/go/0chain.net/core/util/merkle_tree_test.go | 0 code/go/0chain.net/core/util/secure_value.go | 0 code/go/0chain.net/validator/main.go | 0 code/go/0chain.net/validatorcore/config/config.go | 0 .../validatorcore/storage/challenge_handler.go | 0 .../validatorcore/storage/challenge_handler_test.go | 0 code/go/0chain.net/validatorcore/storage/context.go | 0 code/go/0chain.net/validatorcore/storage/handler.go | 0 code/go/0chain.net/validatorcore/storage/models.go | 0 .../0chain.net/validatorcore/storage/models_test.go | 0 .../go/0chain.net/validatorcore/storage/protocol.go | 0 .../validatorcore/storage/writemarker/entity.go | 0 .../storage/writemarker/entity_test.go | 0 config/0chain_validator.yaml | 0 docker.aws/DOCKER_VERSION | 0 docker.aws/README.md | 0 docker.aws/build.blobber/.env | 0 docker.aws/build.blobber/Dockerfile | 0 docker.aws/build.blobber/docker-compose.yml | 0 docker.aws/build.validator/.env | 0 docker.aws/build.validator/Dockerfile | 0 docker.aws/build.validator/docker-compose.yml | 0 docker.local/Dockerfile | 0 docker.local/IntegrationTestsBlobberDockerfile | 0 docker.local/ValidatorDockerfile | 0 docker.local/b0docker-compose.yml | 0 docker.local/docker-clean/Dockerfile | 0 docker.local/docker-clean/docker-clean-compose.yml | 0 docker.local/docker-clean/docker-clean.sh | 0 docker.local/docker-compose.yml | 0 docker.local/keys_config/b0bnode1_keys.txt | 0 docker.local/keys_config/b0bnode2_keys.txt | 0 docker.local/keys_config/b0bnode3_keys.txt | 0 docker.local/keys_config/b0bnode4_keys.txt | 0 docker.local/keys_config/b0bnode5_keys.txt | 0 docker.local/keys_config/b0bnode6_keys.txt | 0 docker.local/keys_config/bnode1_keys.txt | 0 docker.local/keys_config/bnode2_keys.txt | 0 docker.local/keys_config/bnode3_keys.txt | 0 docker.local/keys_config/bnode4_keys.txt | 0 docker.local/keys_config/bnode5_keys.txt | 0 docker.local/keys_config/bnode6_keys.txt | 0 docker.local/keys_config/minio_config.txt | 0 docker.local/p0docker-compose.yml | 0 docs/src/0box_flow.plantuml | 0 docs/src/challenge.plantuml | 0 docs/src/download_flow.plantuml | 0 docs/src/out/challenge/challenge.png | Bin docs/src/out/repair/repair.png | Bin docs/src/repair.plantuml | 0 docs/src/upload_flow.plantuml | 0 go.mod | 0 go.sum | 0 https/README.md | 0 https/conf.d/nginx.conf | 0 https/docker-compose.yml | 0 sql/00-create-user.sql | 0 sql/01-create-table.sql | 0 sql/02-grant-priv.sql | 0 sql/03-add-allocation-prices.sql | 0 sql/04-add-on-cloud.sql | 0 sql/05-add-commit-meta-txns-table.sql | 0 sql/06-add-cleaned_up-column-to-allocations.sql | 0 sql/07-terms-belongs-to-allocation-id.sql | 0 sql/08-add-payer-id-to-allocations.sql | 0 sql/09-add-suspend-column-to-read-markers.sql | 0 sql/10-add-time_unit-column-to-allocations.sql | 0 ...er_id-and-auth_tiket-columns-to-read_markers.sql | 0 ...2-add-attributes-column-to-reference_objects.sql | 0 sql/13-add-collaborators-table.sql | 0 test.sh | 0 181 files changed, 2 insertions(+), 2 deletions(-) mode change 100644 => 100755 .dockerignore mode change 100644 => 100755 .github/workflows/ci.yml mode change 100644 => 100755 .gitignore mode change 100644 => 100755 LICENSE.txt mode change 100644 => 100755 Makefile mode change 100644 => 100755 README.md mode change 100644 => 100755 bin/postgres-entrypoint.sh mode change 100644 => 100755 code/go/0chain.net/.vscode/settings.json mode change 100644 => 100755 code/go/0chain.net/blobber/integration_tests.go mode change 100644 => 100755 code/go/0chain.net/blobber/main.go mode change 100644 => 100755 code/go/0chain.net/blobber/stub.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/allocation/allocationchange.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/allocation/attributesfilechange.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/allocation/copyfilechange.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/allocation/deletefilechange.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/allocation/entity.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/allocation/newfilechange.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/allocation/protocol.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/allocation/renamefilechange.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/allocation/updatefilechange.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/allocation/workers.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/blobbergrpc/README.md mode change 100644 => 100755 code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto mode change 100644 => 100755 code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/annotations.proto mode change 100644 => 100755 code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/http.proto mode change 100644 => 100755 code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/httpbody.proto mode change 100644 => 100755 code/go/0chain.net/blobbercore/challenge/entity.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/challenge/protocol.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/challenge/stats.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/challenge/worker.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/config/config.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/constants/context_key.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/datastore/blob_type.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/datastore/mock_store.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/datastore/model.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/datastore/store.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/errors/errors.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/filestore/fs_store.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/filestore/store.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/convert.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/dto.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/grpcMiddleware.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/grpc_handler.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/grpc_handler_test.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/handler.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/handler_integration_tests.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/handler_test.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/helper.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/object_operation_handler.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/protocol.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/storage_handler.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/worker.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/handler/zcncore.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/mocks/PackageHandler.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/openapi/blobber.swagger.json mode change 100644 => 100755 code/go/0chain.net/blobbercore/readmarker/entity.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/readmarker/protocol.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/readmarker/worker.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/reference/collaborator.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/reference/commitmetatxn.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/reference/objectpath.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/reference/ref.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/reference/referencepath.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/stats/allocationstats.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/stats/blobberstats.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/stats/filestats.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/stats/handler.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/util/json.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/writemarker/entity.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/writemarker/protocol.go mode change 100644 => 100755 code/go/0chain.net/blobbercore/writemarker/worker.go mode change 100644 => 100755 code/go/0chain.net/conductor/build.go mode change 100644 => 100755 code/go/0chain.net/conductor/conductrpc/client.go mode change 100644 => 100755 code/go/0chain.net/conductor/conductrpc/entity.go mode change 100644 => 100755 code/go/0chain.net/conductor/conductrpc/resolve.go mode change 100644 => 100755 code/go/0chain.net/conductor/conductrpc/server.go mode change 100644 => 100755 code/go/0chain.net/conductor/conductrpc/state.go mode change 100644 => 100755 code/go/0chain.net/conductor/config/byzantine.go mode change 100644 => 100755 code/go/0chain.net/conductor/config/config.go mode change 100644 => 100755 code/go/0chain.net/core/build/info.go mode change 100644 => 100755 code/go/0chain.net/core/cache/cache.go mode change 100644 => 100755 code/go/0chain.net/core/cache/lfu.go mode change 100644 => 100755 code/go/0chain.net/core/cache/lru.go mode change 100644 => 100755 code/go/0chain.net/core/chain/entity.go mode change 100644 => 100755 code/go/0chain.net/core/common/context.go mode change 100644 => 100755 code/go/0chain.net/core/common/errors.go mode change 100644 => 100755 code/go/0chain.net/core/common/handler.go mode change 100644 => 100755 code/go/0chain.net/core/common/lookup.go mode change 100644 => 100755 code/go/0chain.net/core/common/rate_limiter.go mode change 100644 => 100755 code/go/0chain.net/core/common/time.go mode change 100644 => 100755 code/go/0chain.net/core/common/types.go mode change 100644 => 100755 code/go/0chain.net/core/common/utils.go mode change 100644 => 100755 code/go/0chain.net/core/config/config.go mode change 100644 => 100755 code/go/0chain.net/core/encryption/hash.go mode change 100644 => 100755 code/go/0chain.net/core/encryption/keys.go mode change 100644 => 100755 code/go/0chain.net/core/lock/lock.go mode change 100644 => 100755 code/go/0chain.net/core/logging/logger.go mode change 100644 => 100755 code/go/0chain.net/core/node/context.go mode change 100644 => 100755 code/go/0chain.net/core/node/self_node.go mode change 100644 => 100755 code/go/0chain.net/core/transaction/entity.go mode change 100644 => 100755 code/go/0chain.net/core/transaction/http.go mode change 100644 => 100755 code/go/0chain.net/core/transaction/type.go mode change 100644 => 100755 code/go/0chain.net/core/util/http.go mode change 100644 => 100755 code/go/0chain.net/core/util/merkle_tree.go mode change 100644 => 100755 code/go/0chain.net/core/util/merkle_tree_interface.go mode change 100644 => 100755 code/go/0chain.net/core/util/merkle_tree_test.go mode change 100644 => 100755 code/go/0chain.net/core/util/secure_value.go mode change 100644 => 100755 code/go/0chain.net/validator/main.go mode change 100644 => 100755 code/go/0chain.net/validatorcore/config/config.go mode change 100644 => 100755 code/go/0chain.net/validatorcore/storage/challenge_handler.go mode change 100644 => 100755 code/go/0chain.net/validatorcore/storage/challenge_handler_test.go mode change 100644 => 100755 code/go/0chain.net/validatorcore/storage/context.go mode change 100644 => 100755 code/go/0chain.net/validatorcore/storage/handler.go mode change 100644 => 100755 code/go/0chain.net/validatorcore/storage/models.go mode change 100644 => 100755 code/go/0chain.net/validatorcore/storage/models_test.go mode change 100644 => 100755 code/go/0chain.net/validatorcore/storage/protocol.go mode change 100644 => 100755 code/go/0chain.net/validatorcore/storage/writemarker/entity.go mode change 100644 => 100755 code/go/0chain.net/validatorcore/storage/writemarker/entity_test.go mode change 100644 => 100755 config/0chain_validator.yaml mode change 100644 => 100755 docker.aws/DOCKER_VERSION mode change 100644 => 100755 docker.aws/README.md mode change 100644 => 100755 docker.aws/build.blobber/.env mode change 100644 => 100755 docker.aws/build.blobber/Dockerfile mode change 100644 => 100755 docker.aws/build.blobber/docker-compose.yml mode change 100644 => 100755 docker.aws/build.validator/.env mode change 100644 => 100755 docker.aws/build.validator/Dockerfile mode change 100644 => 100755 docker.aws/build.validator/docker-compose.yml mode change 100644 => 100755 docker.local/Dockerfile mode change 100644 => 100755 docker.local/IntegrationTestsBlobberDockerfile mode change 100644 => 100755 docker.local/ValidatorDockerfile mode change 100644 => 100755 docker.local/b0docker-compose.yml mode change 100644 => 100755 docker.local/docker-clean/Dockerfile mode change 100644 => 100755 docker.local/docker-clean/docker-clean-compose.yml mode change 100644 => 100755 docker.local/docker-clean/docker-clean.sh mode change 100644 => 100755 docker.local/docker-compose.yml mode change 100644 => 100755 docker.local/keys_config/b0bnode1_keys.txt mode change 100644 => 100755 docker.local/keys_config/b0bnode2_keys.txt mode change 100644 => 100755 docker.local/keys_config/b0bnode3_keys.txt mode change 100644 => 100755 docker.local/keys_config/b0bnode4_keys.txt mode change 100644 => 100755 docker.local/keys_config/b0bnode5_keys.txt mode change 100644 => 100755 docker.local/keys_config/b0bnode6_keys.txt mode change 100644 => 100755 docker.local/keys_config/bnode1_keys.txt mode change 100644 => 100755 docker.local/keys_config/bnode2_keys.txt mode change 100644 => 100755 docker.local/keys_config/bnode3_keys.txt mode change 100644 => 100755 docker.local/keys_config/bnode4_keys.txt mode change 100644 => 100755 docker.local/keys_config/bnode5_keys.txt mode change 100644 => 100755 docker.local/keys_config/bnode6_keys.txt mode change 100644 => 100755 docker.local/keys_config/minio_config.txt mode change 100644 => 100755 docker.local/p0docker-compose.yml mode change 100644 => 100755 docs/src/0box_flow.plantuml mode change 100644 => 100755 docs/src/challenge.plantuml mode change 100644 => 100755 docs/src/download_flow.plantuml mode change 100644 => 100755 docs/src/out/challenge/challenge.png mode change 100644 => 100755 docs/src/out/repair/repair.png mode change 100644 => 100755 docs/src/repair.plantuml mode change 100644 => 100755 docs/src/upload_flow.plantuml mode change 100644 => 100755 go.mod mode change 100644 => 100755 go.sum mode change 100644 => 100755 https/README.md mode change 100644 => 100755 https/conf.d/nginx.conf mode change 100644 => 100755 https/docker-compose.yml mode change 100644 => 100755 sql/00-create-user.sql mode change 100644 => 100755 sql/01-create-table.sql mode change 100644 => 100755 sql/02-grant-priv.sql mode change 100644 => 100755 sql/03-add-allocation-prices.sql mode change 100644 => 100755 sql/04-add-on-cloud.sql mode change 100644 => 100755 sql/05-add-commit-meta-txns-table.sql mode change 100644 => 100755 sql/06-add-cleaned_up-column-to-allocations.sql mode change 100644 => 100755 sql/07-terms-belongs-to-allocation-id.sql mode change 100644 => 100755 sql/08-add-payer-id-to-allocations.sql mode change 100644 => 100755 sql/09-add-suspend-column-to-read-markers.sql mode change 100644 => 100755 sql/10-add-time_unit-column-to-allocations.sql mode change 100644 => 100755 sql/11-add-payer_id-and-auth_tiket-columns-to-read_markers.sql mode change 100644 => 100755 sql/12-add-attributes-column-to-reference_objects.sql mode change 100644 => 100755 sql/13-add-collaborators-table.sql mode change 100644 => 100755 test.sh diff --git a/.dockerignore b/.dockerignore old mode 100644 new mode 100755 diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml old mode 100644 new mode 100755 diff --git a/.gitignore b/.gitignore old mode 100644 new mode 100755 diff --git a/LICENSE.txt b/LICENSE.txt old mode 100644 new mode 100755 diff --git a/Makefile b/Makefile old mode 100644 new mode 100755 index b85f580b9..0db3a71d0 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ .PHONY: test lint test: - cd code/go/0chain.net; go test ./...; + go test ./...; lint: - cd code/go/0chain.net; golangci-lint run; \ No newline at end of file + golangci-lint run; \ No newline at end of file diff --git a/README.md b/README.md old mode 100644 new mode 100755 diff --git a/bin/postgres-entrypoint.sh b/bin/postgres-entrypoint.sh old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/.vscode/settings.json b/code/go/0chain.net/.vscode/settings.json old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobber/integration_tests.go b/code/go/0chain.net/blobber/integration_tests.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobber/main.go b/code/go/0chain.net/blobber/main.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobber/stub.go b/code/go/0chain.net/blobber/stub.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/allocation/allocationchange.go b/code/go/0chain.net/blobbercore/allocation/allocationchange.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/allocation/attributesfilechange.go b/code/go/0chain.net/blobbercore/allocation/attributesfilechange.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/allocation/copyfilechange.go b/code/go/0chain.net/blobbercore/allocation/copyfilechange.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/allocation/deletefilechange.go b/code/go/0chain.net/blobbercore/allocation/deletefilechange.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/allocation/entity.go b/code/go/0chain.net/blobbercore/allocation/entity.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/allocation/newfilechange.go b/code/go/0chain.net/blobbercore/allocation/newfilechange.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/allocation/protocol.go b/code/go/0chain.net/blobbercore/allocation/protocol.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/allocation/renamefilechange.go b/code/go/0chain.net/blobbercore/allocation/renamefilechange.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/allocation/updatefilechange.go b/code/go/0chain.net/blobbercore/allocation/updatefilechange.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/allocation/workers.go b/code/go/0chain.net/blobbercore/allocation/workers.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/README.md b/code/go/0chain.net/blobbercore/blobbergrpc/README.md old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/annotations.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/annotations.proto old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/http.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/http.proto old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/httpbody.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/httpbody.proto old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/challenge/entity.go b/code/go/0chain.net/blobbercore/challenge/entity.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/challenge/protocol.go b/code/go/0chain.net/blobbercore/challenge/protocol.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/challenge/stats.go b/code/go/0chain.net/blobbercore/challenge/stats.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/challenge/worker.go b/code/go/0chain.net/blobbercore/challenge/worker.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/config/config.go b/code/go/0chain.net/blobbercore/config/config.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/constants/context_key.go b/code/go/0chain.net/blobbercore/constants/context_key.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/datastore/blob_type.go b/code/go/0chain.net/blobbercore/datastore/blob_type.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/datastore/mock_store.go b/code/go/0chain.net/blobbercore/datastore/mock_store.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/datastore/model.go b/code/go/0chain.net/blobbercore/datastore/model.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/datastore/store.go b/code/go/0chain.net/blobbercore/datastore/store.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/errors/errors.go b/code/go/0chain.net/blobbercore/errors/errors.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/filestore/fs_store.go b/code/go/0chain.net/blobbercore/filestore/fs_store.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/filestore/store.go b/code/go/0chain.net/blobbercore/filestore/store.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/convert.go b/code/go/0chain.net/blobbercore/handler/convert.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/dto.go b/code/go/0chain.net/blobbercore/handler/dto.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go b/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/handler_integration_tests.go b/code/go/0chain.net/blobbercore/handler/handler_integration_tests.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/protocol.go b/code/go/0chain.net/blobbercore/handler/protocol.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/storage_handler.go b/code/go/0chain.net/blobbercore/handler/storage_handler.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/worker.go b/code/go/0chain.net/blobbercore/handler/worker.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/handler/zcncore.go b/code/go/0chain.net/blobbercore/handler/zcncore.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/readmarker/entity.go b/code/go/0chain.net/blobbercore/readmarker/entity.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/readmarker/protocol.go b/code/go/0chain.net/blobbercore/readmarker/protocol.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/readmarker/worker.go b/code/go/0chain.net/blobbercore/readmarker/worker.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/reference/collaborator.go b/code/go/0chain.net/blobbercore/reference/collaborator.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/reference/commitmetatxn.go b/code/go/0chain.net/blobbercore/reference/commitmetatxn.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/reference/objectpath.go b/code/go/0chain.net/blobbercore/reference/objectpath.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/reference/ref.go b/code/go/0chain.net/blobbercore/reference/ref.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/reference/referencepath.go b/code/go/0chain.net/blobbercore/reference/referencepath.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/stats/allocationstats.go b/code/go/0chain.net/blobbercore/stats/allocationstats.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/stats/blobberstats.go b/code/go/0chain.net/blobbercore/stats/blobberstats.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/stats/filestats.go b/code/go/0chain.net/blobbercore/stats/filestats.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/stats/handler.go b/code/go/0chain.net/blobbercore/stats/handler.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/util/json.go b/code/go/0chain.net/blobbercore/util/json.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/writemarker/entity.go b/code/go/0chain.net/blobbercore/writemarker/entity.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/writemarker/protocol.go b/code/go/0chain.net/blobbercore/writemarker/protocol.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/blobbercore/writemarker/worker.go b/code/go/0chain.net/blobbercore/writemarker/worker.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/conductor/build.go b/code/go/0chain.net/conductor/build.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/conductor/conductrpc/client.go b/code/go/0chain.net/conductor/conductrpc/client.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/conductor/conductrpc/entity.go b/code/go/0chain.net/conductor/conductrpc/entity.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/conductor/conductrpc/resolve.go b/code/go/0chain.net/conductor/conductrpc/resolve.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/conductor/conductrpc/server.go b/code/go/0chain.net/conductor/conductrpc/server.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/conductor/conductrpc/state.go b/code/go/0chain.net/conductor/conductrpc/state.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/conductor/config/byzantine.go b/code/go/0chain.net/conductor/config/byzantine.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/conductor/config/config.go b/code/go/0chain.net/conductor/config/config.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/build/info.go b/code/go/0chain.net/core/build/info.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/cache/cache.go b/code/go/0chain.net/core/cache/cache.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/cache/lfu.go b/code/go/0chain.net/core/cache/lfu.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/cache/lru.go b/code/go/0chain.net/core/cache/lru.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/chain/entity.go b/code/go/0chain.net/core/chain/entity.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/common/context.go b/code/go/0chain.net/core/common/context.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/common/errors.go b/code/go/0chain.net/core/common/errors.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/common/handler.go b/code/go/0chain.net/core/common/handler.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/common/lookup.go b/code/go/0chain.net/core/common/lookup.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/common/rate_limiter.go b/code/go/0chain.net/core/common/rate_limiter.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/common/time.go b/code/go/0chain.net/core/common/time.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/common/types.go b/code/go/0chain.net/core/common/types.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/common/utils.go b/code/go/0chain.net/core/common/utils.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/config/config.go b/code/go/0chain.net/core/config/config.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/encryption/hash.go b/code/go/0chain.net/core/encryption/hash.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/encryption/keys.go b/code/go/0chain.net/core/encryption/keys.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/lock/lock.go b/code/go/0chain.net/core/lock/lock.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/logging/logger.go b/code/go/0chain.net/core/logging/logger.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/node/context.go b/code/go/0chain.net/core/node/context.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/node/self_node.go b/code/go/0chain.net/core/node/self_node.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/transaction/entity.go b/code/go/0chain.net/core/transaction/entity.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/transaction/http.go b/code/go/0chain.net/core/transaction/http.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/transaction/type.go b/code/go/0chain.net/core/transaction/type.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/util/http.go b/code/go/0chain.net/core/util/http.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/util/merkle_tree.go b/code/go/0chain.net/core/util/merkle_tree.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/util/merkle_tree_interface.go b/code/go/0chain.net/core/util/merkle_tree_interface.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/util/merkle_tree_test.go b/code/go/0chain.net/core/util/merkle_tree_test.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/core/util/secure_value.go b/code/go/0chain.net/core/util/secure_value.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/validator/main.go b/code/go/0chain.net/validator/main.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/validatorcore/config/config.go b/code/go/0chain.net/validatorcore/config/config.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/validatorcore/storage/challenge_handler.go b/code/go/0chain.net/validatorcore/storage/challenge_handler.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/validatorcore/storage/challenge_handler_test.go b/code/go/0chain.net/validatorcore/storage/challenge_handler_test.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/validatorcore/storage/context.go b/code/go/0chain.net/validatorcore/storage/context.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/validatorcore/storage/handler.go b/code/go/0chain.net/validatorcore/storage/handler.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/validatorcore/storage/models.go b/code/go/0chain.net/validatorcore/storage/models.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/validatorcore/storage/models_test.go b/code/go/0chain.net/validatorcore/storage/models_test.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/validatorcore/storage/protocol.go b/code/go/0chain.net/validatorcore/storage/protocol.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/validatorcore/storage/writemarker/entity.go b/code/go/0chain.net/validatorcore/storage/writemarker/entity.go old mode 100644 new mode 100755 diff --git a/code/go/0chain.net/validatorcore/storage/writemarker/entity_test.go b/code/go/0chain.net/validatorcore/storage/writemarker/entity_test.go old mode 100644 new mode 100755 diff --git a/config/0chain_validator.yaml b/config/0chain_validator.yaml old mode 100644 new mode 100755 diff --git a/docker.aws/DOCKER_VERSION b/docker.aws/DOCKER_VERSION old mode 100644 new mode 100755 diff --git a/docker.aws/README.md b/docker.aws/README.md old mode 100644 new mode 100755 diff --git a/docker.aws/build.blobber/.env b/docker.aws/build.blobber/.env old mode 100644 new mode 100755 diff --git a/docker.aws/build.blobber/Dockerfile b/docker.aws/build.blobber/Dockerfile old mode 100644 new mode 100755 diff --git a/docker.aws/build.blobber/docker-compose.yml b/docker.aws/build.blobber/docker-compose.yml old mode 100644 new mode 100755 diff --git a/docker.aws/build.validator/.env b/docker.aws/build.validator/.env old mode 100644 new mode 100755 diff --git a/docker.aws/build.validator/Dockerfile b/docker.aws/build.validator/Dockerfile old mode 100644 new mode 100755 diff --git a/docker.aws/build.validator/docker-compose.yml b/docker.aws/build.validator/docker-compose.yml old mode 100644 new mode 100755 diff --git a/docker.local/Dockerfile b/docker.local/Dockerfile old mode 100644 new mode 100755 diff --git a/docker.local/IntegrationTestsBlobberDockerfile b/docker.local/IntegrationTestsBlobberDockerfile old mode 100644 new mode 100755 diff --git a/docker.local/ValidatorDockerfile b/docker.local/ValidatorDockerfile old mode 100644 new mode 100755 diff --git a/docker.local/b0docker-compose.yml b/docker.local/b0docker-compose.yml old mode 100644 new mode 100755 diff --git a/docker.local/docker-clean/Dockerfile b/docker.local/docker-clean/Dockerfile old mode 100644 new mode 100755 diff --git a/docker.local/docker-clean/docker-clean-compose.yml b/docker.local/docker-clean/docker-clean-compose.yml old mode 100644 new mode 100755 diff --git a/docker.local/docker-clean/docker-clean.sh b/docker.local/docker-clean/docker-clean.sh old mode 100644 new mode 100755 diff --git a/docker.local/docker-compose.yml b/docker.local/docker-compose.yml old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/b0bnode1_keys.txt b/docker.local/keys_config/b0bnode1_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/b0bnode2_keys.txt b/docker.local/keys_config/b0bnode2_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/b0bnode3_keys.txt b/docker.local/keys_config/b0bnode3_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/b0bnode4_keys.txt b/docker.local/keys_config/b0bnode4_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/b0bnode5_keys.txt b/docker.local/keys_config/b0bnode5_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/b0bnode6_keys.txt b/docker.local/keys_config/b0bnode6_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/bnode1_keys.txt b/docker.local/keys_config/bnode1_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/bnode2_keys.txt b/docker.local/keys_config/bnode2_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/bnode3_keys.txt b/docker.local/keys_config/bnode3_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/bnode4_keys.txt b/docker.local/keys_config/bnode4_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/bnode5_keys.txt b/docker.local/keys_config/bnode5_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/bnode6_keys.txt b/docker.local/keys_config/bnode6_keys.txt old mode 100644 new mode 100755 diff --git a/docker.local/keys_config/minio_config.txt b/docker.local/keys_config/minio_config.txt old mode 100644 new mode 100755 diff --git a/docker.local/p0docker-compose.yml b/docker.local/p0docker-compose.yml old mode 100644 new mode 100755 diff --git a/docs/src/0box_flow.plantuml b/docs/src/0box_flow.plantuml old mode 100644 new mode 100755 diff --git a/docs/src/challenge.plantuml b/docs/src/challenge.plantuml old mode 100644 new mode 100755 diff --git a/docs/src/download_flow.plantuml b/docs/src/download_flow.plantuml old mode 100644 new mode 100755 diff --git a/docs/src/out/challenge/challenge.png b/docs/src/out/challenge/challenge.png old mode 100644 new mode 100755 diff --git a/docs/src/out/repair/repair.png b/docs/src/out/repair/repair.png old mode 100644 new mode 100755 diff --git a/docs/src/repair.plantuml b/docs/src/repair.plantuml old mode 100644 new mode 100755 diff --git a/docs/src/upload_flow.plantuml b/docs/src/upload_flow.plantuml old mode 100644 new mode 100755 diff --git a/go.mod b/go.mod old mode 100644 new mode 100755 diff --git a/go.sum b/go.sum old mode 100644 new mode 100755 diff --git a/https/README.md b/https/README.md old mode 100644 new mode 100755 diff --git a/https/conf.d/nginx.conf b/https/conf.d/nginx.conf old mode 100644 new mode 100755 diff --git a/https/docker-compose.yml b/https/docker-compose.yml old mode 100644 new mode 100755 diff --git a/sql/00-create-user.sql b/sql/00-create-user.sql old mode 100644 new mode 100755 diff --git a/sql/01-create-table.sql b/sql/01-create-table.sql old mode 100644 new mode 100755 diff --git a/sql/02-grant-priv.sql b/sql/02-grant-priv.sql old mode 100644 new mode 100755 diff --git a/sql/03-add-allocation-prices.sql b/sql/03-add-allocation-prices.sql old mode 100644 new mode 100755 diff --git a/sql/04-add-on-cloud.sql b/sql/04-add-on-cloud.sql old mode 100644 new mode 100755 diff --git a/sql/05-add-commit-meta-txns-table.sql b/sql/05-add-commit-meta-txns-table.sql old mode 100644 new mode 100755 diff --git a/sql/06-add-cleaned_up-column-to-allocations.sql b/sql/06-add-cleaned_up-column-to-allocations.sql old mode 100644 new mode 100755 diff --git a/sql/07-terms-belongs-to-allocation-id.sql b/sql/07-terms-belongs-to-allocation-id.sql old mode 100644 new mode 100755 diff --git a/sql/08-add-payer-id-to-allocations.sql b/sql/08-add-payer-id-to-allocations.sql old mode 100644 new mode 100755 diff --git a/sql/09-add-suspend-column-to-read-markers.sql b/sql/09-add-suspend-column-to-read-markers.sql old mode 100644 new mode 100755 diff --git a/sql/10-add-time_unit-column-to-allocations.sql b/sql/10-add-time_unit-column-to-allocations.sql old mode 100644 new mode 100755 diff --git a/sql/11-add-payer_id-and-auth_tiket-columns-to-read_markers.sql b/sql/11-add-payer_id-and-auth_tiket-columns-to-read_markers.sql old mode 100644 new mode 100755 diff --git a/sql/12-add-attributes-column-to-reference_objects.sql b/sql/12-add-attributes-column-to-reference_objects.sql old mode 100644 new mode 100755 diff --git a/sql/13-add-collaborators-table.sql b/sql/13-add-collaborators-table.sql old mode 100644 new mode 100755 diff --git a/test.sh b/test.sh old mode 100644 new mode 100755 From a59c6d419158cac55154b998577fc517b6442878 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 10 May 2021 17:53:36 +0530 Subject: [PATCH 014/183] :green_heart: fixing build github action --- docker.local/Dockerfile | 10 +++++----- docker.local/ValidatorDockerfile | 10 +++++----- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/docker.local/Dockerfile b/docker.local/Dockerfile index bcd2320a4..f9d18464f 100755 --- a/docker.local/Dockerfile +++ b/docker.local/Dockerfile @@ -24,13 +24,13 @@ ENV GO111MODULE=on # Download the dependencies: # Will be cached if we don't change mod/sum files -COPY ./code/go/0chain.net/go.mod ./code/go/0chain.net/go.sum $SRC_DIR/go/0chain.net/ -RUN cd $SRC_DIR/go/0chain.net && go mod download +COPY ./go.mod ./go.sum $SRC_DIR/ +RUN cd $SRC_DIR && go mod download #Add the source code -ADD ./code/go/0chain.net $SRC_DIR/go/0chain.net +ADD ./code/go/0chain.net $SRC_DIR/code/go/0chain.net -WORKDIR $SRC_DIR/go/0chain.net/blobber +WORKDIR $SRC_DIR/code/go/0chain.net/blobber ARG GIT_COMMIT ENV GIT_COMMIT=$GIT_COMMIT @@ -44,4 +44,4 @@ COPY --from=blobber_build /usr/local/lib/libmcl*.so \ /usr/local/lib/ ENV APP_DIR=/blobber WORKDIR $APP_DIR -COPY --from=blobber_build $APP_DIR/go/0chain.net/blobber/blobber $APP_DIR/bin/blobber +COPY --from=blobber_build $APP_DIR/code/go/0chain.net/blobber/blobber $APP_DIR/bin/blobber diff --git a/docker.local/ValidatorDockerfile b/docker.local/ValidatorDockerfile index b9fa07c8a..cd5f594a1 100755 --- a/docker.local/ValidatorDockerfile +++ b/docker.local/ValidatorDockerfile @@ -24,13 +24,13 @@ ENV GO111MODULE=on # Download the dependencies: # Will be cached if we don't change mod/sum files -COPY ./code/go/0chain.net/go.mod ./code/go/0chain.net/go.sum $SRC_DIR/go/0chain.net/ -RUN cd $SRC_DIR/go/0chain.net && go mod download +COPY ./go.mod ./go.sum $SRC_DIR/ +RUN cd $SRC_DIR && go mod download #Add the source code -ADD ./code/go/0chain.net $SRC_DIR/go/0chain.net +ADD . $SRC_DIR -WORKDIR $SRC_DIR/go/0chain.net/validator +WORKDIR $SRC_DIR/code/go/0chain.net/validator RUN go build -v -tags "bn256 development" -ldflags "-X 0chain.net/core/build.BuildTag=$GIT_COMMIT" @@ -42,4 +42,4 @@ COPY --from=validator_build /usr/local/lib/libmcl*.so \ /usr/local/lib/ ENV APP_DIR=/blobber WORKDIR $APP_DIR -COPY --from=validator_build $APP_DIR/go/0chain.net/validator/validator $APP_DIR/bin/validator +COPY --from=validator_build $APP_DIR/code/go/0chain.net/validator/validator $APP_DIR/bin/validator From aa14e96395889f8e48043874c7d2c551bb606f64 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 10 May 2021 18:18:52 +0530 Subject: [PATCH 015/183] Revert ":recycle: fixed test and lint" This reverts commit 6c28e3634b36b4b24eac8acdb85c0253e7d499f7. --- .dockerignore | 0 .github/workflows/ci.yml | 0 .gitignore | 0 LICENSE.txt | 0 Makefile | 4 ++-- README.md | 0 bin/postgres-entrypoint.sh | 0 code/go/0chain.net/.vscode/settings.json | 0 code/go/0chain.net/blobber/integration_tests.go | 0 code/go/0chain.net/blobber/main.go | 0 code/go/0chain.net/blobber/stub.go | 0 .../blobbercore/allocation/allocationchange.go | 0 .../blobbercore/allocation/attributesfilechange.go | 0 .../blobbercore/allocation/copyfilechange.go | 0 .../blobbercore/allocation/deletefilechange.go | 0 code/go/0chain.net/blobbercore/allocation/entity.go | 0 .../blobbercore/allocation/newfilechange.go | 0 .../0chain.net/blobbercore/allocation/protocol.go | 0 .../blobbercore/allocation/renamefilechange.go | 0 .../blobbercore/allocation/updatefilechange.go | 0 .../go/0chain.net/blobbercore/allocation/workers.go | 0 .../go/0chain.net/blobbercore/blobbergrpc/README.md | 0 .../blobbercore/blobbergrpc/blobber.pb.go | 0 .../blobbercore/blobbergrpc/blobber.pb.gw.go | 0 .../blobbercore/blobbergrpc/blobber_grpc.pb.go | 0 .../blobbercore/blobbergrpc/proto/blobber.proto | 0 .../blobbergrpc/proto/google/api/annotations.proto | 0 .../blobbergrpc/proto/google/api/http.proto | 0 .../blobbergrpc/proto/google/api/httpbody.proto | 0 code/go/0chain.net/blobbercore/challenge/entity.go | 0 .../go/0chain.net/blobbercore/challenge/protocol.go | 0 code/go/0chain.net/blobbercore/challenge/stats.go | 0 code/go/0chain.net/blobbercore/challenge/worker.go | 0 code/go/0chain.net/blobbercore/config/config.go | 0 .../0chain.net/blobbercore/constants/context_key.go | 0 .../0chain.net/blobbercore/datastore/blob_type.go | 0 .../0chain.net/blobbercore/datastore/mock_store.go | 0 code/go/0chain.net/blobbercore/datastore/model.go | 0 code/go/0chain.net/blobbercore/datastore/store.go | 0 code/go/0chain.net/blobbercore/errors/errors.go | 0 .../go/0chain.net/blobbercore/filestore/fs_store.go | 0 code/go/0chain.net/blobbercore/filestore/store.go | 0 code/go/0chain.net/blobbercore/handler/convert.go | 0 code/go/0chain.net/blobbercore/handler/dto.go | 0 .../blobbercore/handler/grpcMiddleware.go | 0 .../0chain.net/blobbercore/handler/grpc_handler.go | 0 .../handler/grpc_handler_helper_unit_test.go | 0 .../blobbercore/handler/grpc_handler_test.go | 0 .../blobbercore/handler/grpc_handler_unit_test.go | 0 code/go/0chain.net/blobbercore/handler/handler.go | 0 .../handler/handler_integration_tests.go | 0 .../0chain.net/blobbercore/handler/handler_test.go | 0 code/go/0chain.net/blobbercore/handler/helper.go | 0 .../blobbercore/handler/object_operation_handler.go | 0 code/go/0chain.net/blobbercore/handler/protocol.go | 0 .../blobbercore/handler/storage_handler.go | 0 code/go/0chain.net/blobbercore/handler/worker.go | 0 code/go/0chain.net/blobbercore/handler/zcncore.go | 0 .../0chain.net/blobbercore/mocks/PackageHandler.go | 0 .../blobbercore/openapi/blobber.swagger.json | 0 code/go/0chain.net/blobbercore/readmarker/entity.go | 0 .../0chain.net/blobbercore/readmarker/protocol.go | 0 code/go/0chain.net/blobbercore/readmarker/worker.go | 0 .../blobbercore/reference/collaborator.go | 0 .../blobbercore/reference/commitmetatxn.go | 0 .../0chain.net/blobbercore/reference/objectpath.go | 0 code/go/0chain.net/blobbercore/reference/ref.go | 0 .../blobbercore/reference/referencepath.go | 0 .../0chain.net/blobbercore/stats/allocationstats.go | 0 .../go/0chain.net/blobbercore/stats/blobberstats.go | 0 code/go/0chain.net/blobbercore/stats/filestats.go | 0 code/go/0chain.net/blobbercore/stats/handler.go | 0 code/go/0chain.net/blobbercore/util/json.go | 0 .../go/0chain.net/blobbercore/writemarker/entity.go | 0 .../0chain.net/blobbercore/writemarker/protocol.go | 0 .../go/0chain.net/blobbercore/writemarker/worker.go | 0 code/go/0chain.net/conductor/build.go | 0 code/go/0chain.net/conductor/conductrpc/client.go | 0 code/go/0chain.net/conductor/conductrpc/entity.go | 0 code/go/0chain.net/conductor/conductrpc/resolve.go | 0 code/go/0chain.net/conductor/conductrpc/server.go | 0 code/go/0chain.net/conductor/conductrpc/state.go | 0 code/go/0chain.net/conductor/config/byzantine.go | 0 code/go/0chain.net/conductor/config/config.go | 0 code/go/0chain.net/core/build/info.go | 0 code/go/0chain.net/core/cache/cache.go | 0 code/go/0chain.net/core/cache/lfu.go | 0 code/go/0chain.net/core/cache/lru.go | 0 code/go/0chain.net/core/chain/entity.go | 0 code/go/0chain.net/core/common/context.go | 0 code/go/0chain.net/core/common/errors.go | 0 code/go/0chain.net/core/common/handler.go | 0 code/go/0chain.net/core/common/lookup.go | 0 code/go/0chain.net/core/common/rate_limiter.go | 0 code/go/0chain.net/core/common/time.go | 0 code/go/0chain.net/core/common/types.go | 0 code/go/0chain.net/core/common/utils.go | 0 code/go/0chain.net/core/config/config.go | 0 code/go/0chain.net/core/encryption/hash.go | 0 code/go/0chain.net/core/encryption/keys.go | 0 code/go/0chain.net/core/lock/lock.go | 0 code/go/0chain.net/core/logging/logger.go | 0 code/go/0chain.net/core/node/context.go | 0 code/go/0chain.net/core/node/self_node.go | 0 code/go/0chain.net/core/transaction/entity.go | 0 code/go/0chain.net/core/transaction/http.go | 0 code/go/0chain.net/core/transaction/type.go | 0 code/go/0chain.net/core/util/http.go | 0 code/go/0chain.net/core/util/merkle_tree.go | 0 .../0chain.net/core/util/merkle_tree_interface.go | 0 code/go/0chain.net/core/util/merkle_tree_test.go | 0 code/go/0chain.net/core/util/secure_value.go | 0 code/go/0chain.net/validator/main.go | 0 code/go/0chain.net/validatorcore/config/config.go | 0 .../validatorcore/storage/challenge_handler.go | 0 .../validatorcore/storage/challenge_handler_test.go | 0 code/go/0chain.net/validatorcore/storage/context.go | 0 code/go/0chain.net/validatorcore/storage/handler.go | 0 code/go/0chain.net/validatorcore/storage/models.go | 0 .../0chain.net/validatorcore/storage/models_test.go | 0 .../go/0chain.net/validatorcore/storage/protocol.go | 0 .../validatorcore/storage/writemarker/entity.go | 0 .../storage/writemarker/entity_test.go | 0 config/0chain_validator.yaml | 0 docker.aws/DOCKER_VERSION | 0 docker.aws/README.md | 0 docker.aws/build.blobber/.env | 0 docker.aws/build.blobber/Dockerfile | 0 docker.aws/build.blobber/docker-compose.yml | 0 docker.aws/build.validator/.env | 0 docker.aws/build.validator/Dockerfile | 0 docker.aws/build.validator/docker-compose.yml | 0 docker.local/Dockerfile | 0 docker.local/IntegrationTestsBlobberDockerfile | 0 docker.local/ValidatorDockerfile | 0 docker.local/b0docker-compose.yml | 0 docker.local/docker-clean/Dockerfile | 0 docker.local/docker-clean/docker-clean-compose.yml | 0 docker.local/docker-clean/docker-clean.sh | 0 docker.local/docker-compose.yml | 0 docker.local/keys_config/b0bnode1_keys.txt | 0 docker.local/keys_config/b0bnode2_keys.txt | 0 docker.local/keys_config/b0bnode3_keys.txt | 0 docker.local/keys_config/b0bnode4_keys.txt | 0 docker.local/keys_config/b0bnode5_keys.txt | 0 docker.local/keys_config/b0bnode6_keys.txt | 0 docker.local/keys_config/bnode1_keys.txt | 0 docker.local/keys_config/bnode2_keys.txt | 0 docker.local/keys_config/bnode3_keys.txt | 0 docker.local/keys_config/bnode4_keys.txt | 0 docker.local/keys_config/bnode5_keys.txt | 0 docker.local/keys_config/bnode6_keys.txt | 0 docker.local/keys_config/minio_config.txt | 0 docker.local/p0docker-compose.yml | 0 docs/src/0box_flow.plantuml | 0 docs/src/challenge.plantuml | 0 docs/src/download_flow.plantuml | 0 docs/src/out/challenge/challenge.png | Bin docs/src/out/repair/repair.png | Bin docs/src/repair.plantuml | 0 docs/src/upload_flow.plantuml | 0 go.mod | 0 go.sum | 0 https/README.md | 0 https/conf.d/nginx.conf | 0 https/docker-compose.yml | 0 sql/00-create-user.sql | 0 sql/01-create-table.sql | 0 sql/02-grant-priv.sql | 0 sql/03-add-allocation-prices.sql | 0 sql/04-add-on-cloud.sql | 0 sql/05-add-commit-meta-txns-table.sql | 0 sql/06-add-cleaned_up-column-to-allocations.sql | 0 sql/07-terms-belongs-to-allocation-id.sql | 0 sql/08-add-payer-id-to-allocations.sql | 0 sql/09-add-suspend-column-to-read-markers.sql | 0 sql/10-add-time_unit-column-to-allocations.sql | 0 ...er_id-and-auth_tiket-columns-to-read_markers.sql | 0 ...2-add-attributes-column-to-reference_objects.sql | 0 sql/13-add-collaborators-table.sql | 0 test.sh | 0 181 files changed, 2 insertions(+), 2 deletions(-) mode change 100755 => 100644 .dockerignore mode change 100755 => 100644 .github/workflows/ci.yml mode change 100755 => 100644 .gitignore mode change 100755 => 100644 LICENSE.txt mode change 100755 => 100644 Makefile mode change 100755 => 100644 README.md mode change 100755 => 100644 bin/postgres-entrypoint.sh mode change 100755 => 100644 code/go/0chain.net/.vscode/settings.json mode change 100755 => 100644 code/go/0chain.net/blobber/integration_tests.go mode change 100755 => 100644 code/go/0chain.net/blobber/main.go mode change 100755 => 100644 code/go/0chain.net/blobber/stub.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/allocation/allocationchange.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/allocation/attributesfilechange.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/allocation/copyfilechange.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/allocation/deletefilechange.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/allocation/entity.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/allocation/newfilechange.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/allocation/protocol.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/allocation/renamefilechange.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/allocation/updatefilechange.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/allocation/workers.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/blobbergrpc/README.md mode change 100755 => 100644 code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto mode change 100755 => 100644 code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/annotations.proto mode change 100755 => 100644 code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/http.proto mode change 100755 => 100644 code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/httpbody.proto mode change 100755 => 100644 code/go/0chain.net/blobbercore/challenge/entity.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/challenge/protocol.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/challenge/stats.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/challenge/worker.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/config/config.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/constants/context_key.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/datastore/blob_type.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/datastore/mock_store.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/datastore/model.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/datastore/store.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/errors/errors.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/filestore/fs_store.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/filestore/store.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/convert.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/dto.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/grpcMiddleware.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/grpc_handler.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/grpc_handler_test.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/handler.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/handler_integration_tests.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/handler_test.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/helper.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/object_operation_handler.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/protocol.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/storage_handler.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/worker.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/handler/zcncore.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/mocks/PackageHandler.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/openapi/blobber.swagger.json mode change 100755 => 100644 code/go/0chain.net/blobbercore/readmarker/entity.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/readmarker/protocol.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/readmarker/worker.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/reference/collaborator.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/reference/commitmetatxn.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/reference/objectpath.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/reference/ref.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/reference/referencepath.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/stats/allocationstats.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/stats/blobberstats.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/stats/filestats.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/stats/handler.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/util/json.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/writemarker/entity.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/writemarker/protocol.go mode change 100755 => 100644 code/go/0chain.net/blobbercore/writemarker/worker.go mode change 100755 => 100644 code/go/0chain.net/conductor/build.go mode change 100755 => 100644 code/go/0chain.net/conductor/conductrpc/client.go mode change 100755 => 100644 code/go/0chain.net/conductor/conductrpc/entity.go mode change 100755 => 100644 code/go/0chain.net/conductor/conductrpc/resolve.go mode change 100755 => 100644 code/go/0chain.net/conductor/conductrpc/server.go mode change 100755 => 100644 code/go/0chain.net/conductor/conductrpc/state.go mode change 100755 => 100644 code/go/0chain.net/conductor/config/byzantine.go mode change 100755 => 100644 code/go/0chain.net/conductor/config/config.go mode change 100755 => 100644 code/go/0chain.net/core/build/info.go mode change 100755 => 100644 code/go/0chain.net/core/cache/cache.go mode change 100755 => 100644 code/go/0chain.net/core/cache/lfu.go mode change 100755 => 100644 code/go/0chain.net/core/cache/lru.go mode change 100755 => 100644 code/go/0chain.net/core/chain/entity.go mode change 100755 => 100644 code/go/0chain.net/core/common/context.go mode change 100755 => 100644 code/go/0chain.net/core/common/errors.go mode change 100755 => 100644 code/go/0chain.net/core/common/handler.go mode change 100755 => 100644 code/go/0chain.net/core/common/lookup.go mode change 100755 => 100644 code/go/0chain.net/core/common/rate_limiter.go mode change 100755 => 100644 code/go/0chain.net/core/common/time.go mode change 100755 => 100644 code/go/0chain.net/core/common/types.go mode change 100755 => 100644 code/go/0chain.net/core/common/utils.go mode change 100755 => 100644 code/go/0chain.net/core/config/config.go mode change 100755 => 100644 code/go/0chain.net/core/encryption/hash.go mode change 100755 => 100644 code/go/0chain.net/core/encryption/keys.go mode change 100755 => 100644 code/go/0chain.net/core/lock/lock.go mode change 100755 => 100644 code/go/0chain.net/core/logging/logger.go mode change 100755 => 100644 code/go/0chain.net/core/node/context.go mode change 100755 => 100644 code/go/0chain.net/core/node/self_node.go mode change 100755 => 100644 code/go/0chain.net/core/transaction/entity.go mode change 100755 => 100644 code/go/0chain.net/core/transaction/http.go mode change 100755 => 100644 code/go/0chain.net/core/transaction/type.go mode change 100755 => 100644 code/go/0chain.net/core/util/http.go mode change 100755 => 100644 code/go/0chain.net/core/util/merkle_tree.go mode change 100755 => 100644 code/go/0chain.net/core/util/merkle_tree_interface.go mode change 100755 => 100644 code/go/0chain.net/core/util/merkle_tree_test.go mode change 100755 => 100644 code/go/0chain.net/core/util/secure_value.go mode change 100755 => 100644 code/go/0chain.net/validator/main.go mode change 100755 => 100644 code/go/0chain.net/validatorcore/config/config.go mode change 100755 => 100644 code/go/0chain.net/validatorcore/storage/challenge_handler.go mode change 100755 => 100644 code/go/0chain.net/validatorcore/storage/challenge_handler_test.go mode change 100755 => 100644 code/go/0chain.net/validatorcore/storage/context.go mode change 100755 => 100644 code/go/0chain.net/validatorcore/storage/handler.go mode change 100755 => 100644 code/go/0chain.net/validatorcore/storage/models.go mode change 100755 => 100644 code/go/0chain.net/validatorcore/storage/models_test.go mode change 100755 => 100644 code/go/0chain.net/validatorcore/storage/protocol.go mode change 100755 => 100644 code/go/0chain.net/validatorcore/storage/writemarker/entity.go mode change 100755 => 100644 code/go/0chain.net/validatorcore/storage/writemarker/entity_test.go mode change 100755 => 100644 config/0chain_validator.yaml mode change 100755 => 100644 docker.aws/DOCKER_VERSION mode change 100755 => 100644 docker.aws/README.md mode change 100755 => 100644 docker.aws/build.blobber/.env mode change 100755 => 100644 docker.aws/build.blobber/Dockerfile mode change 100755 => 100644 docker.aws/build.blobber/docker-compose.yml mode change 100755 => 100644 docker.aws/build.validator/.env mode change 100755 => 100644 docker.aws/build.validator/Dockerfile mode change 100755 => 100644 docker.aws/build.validator/docker-compose.yml mode change 100755 => 100644 docker.local/Dockerfile mode change 100755 => 100644 docker.local/IntegrationTestsBlobberDockerfile mode change 100755 => 100644 docker.local/ValidatorDockerfile mode change 100755 => 100644 docker.local/b0docker-compose.yml mode change 100755 => 100644 docker.local/docker-clean/Dockerfile mode change 100755 => 100644 docker.local/docker-clean/docker-clean-compose.yml mode change 100755 => 100644 docker.local/docker-clean/docker-clean.sh mode change 100755 => 100644 docker.local/docker-compose.yml mode change 100755 => 100644 docker.local/keys_config/b0bnode1_keys.txt mode change 100755 => 100644 docker.local/keys_config/b0bnode2_keys.txt mode change 100755 => 100644 docker.local/keys_config/b0bnode3_keys.txt mode change 100755 => 100644 docker.local/keys_config/b0bnode4_keys.txt mode change 100755 => 100644 docker.local/keys_config/b0bnode5_keys.txt mode change 100755 => 100644 docker.local/keys_config/b0bnode6_keys.txt mode change 100755 => 100644 docker.local/keys_config/bnode1_keys.txt mode change 100755 => 100644 docker.local/keys_config/bnode2_keys.txt mode change 100755 => 100644 docker.local/keys_config/bnode3_keys.txt mode change 100755 => 100644 docker.local/keys_config/bnode4_keys.txt mode change 100755 => 100644 docker.local/keys_config/bnode5_keys.txt mode change 100755 => 100644 docker.local/keys_config/bnode6_keys.txt mode change 100755 => 100644 docker.local/keys_config/minio_config.txt mode change 100755 => 100644 docker.local/p0docker-compose.yml mode change 100755 => 100644 docs/src/0box_flow.plantuml mode change 100755 => 100644 docs/src/challenge.plantuml mode change 100755 => 100644 docs/src/download_flow.plantuml mode change 100755 => 100644 docs/src/out/challenge/challenge.png mode change 100755 => 100644 docs/src/out/repair/repair.png mode change 100755 => 100644 docs/src/repair.plantuml mode change 100755 => 100644 docs/src/upload_flow.plantuml mode change 100755 => 100644 go.mod mode change 100755 => 100644 go.sum mode change 100755 => 100644 https/README.md mode change 100755 => 100644 https/conf.d/nginx.conf mode change 100755 => 100644 https/docker-compose.yml mode change 100755 => 100644 sql/00-create-user.sql mode change 100755 => 100644 sql/01-create-table.sql mode change 100755 => 100644 sql/02-grant-priv.sql mode change 100755 => 100644 sql/03-add-allocation-prices.sql mode change 100755 => 100644 sql/04-add-on-cloud.sql mode change 100755 => 100644 sql/05-add-commit-meta-txns-table.sql mode change 100755 => 100644 sql/06-add-cleaned_up-column-to-allocations.sql mode change 100755 => 100644 sql/07-terms-belongs-to-allocation-id.sql mode change 100755 => 100644 sql/08-add-payer-id-to-allocations.sql mode change 100755 => 100644 sql/09-add-suspend-column-to-read-markers.sql mode change 100755 => 100644 sql/10-add-time_unit-column-to-allocations.sql mode change 100755 => 100644 sql/11-add-payer_id-and-auth_tiket-columns-to-read_markers.sql mode change 100755 => 100644 sql/12-add-attributes-column-to-reference_objects.sql mode change 100755 => 100644 sql/13-add-collaborators-table.sql mode change 100755 => 100644 test.sh diff --git a/.dockerignore b/.dockerignore old mode 100755 new mode 100644 diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml old mode 100755 new mode 100644 diff --git a/.gitignore b/.gitignore old mode 100755 new mode 100644 diff --git a/LICENSE.txt b/LICENSE.txt old mode 100755 new mode 100644 diff --git a/Makefile b/Makefile old mode 100755 new mode 100644 index 0db3a71d0..b85f580b9 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ .PHONY: test lint test: - go test ./...; + cd code/go/0chain.net; go test ./...; lint: - golangci-lint run; \ No newline at end of file + cd code/go/0chain.net; golangci-lint run; \ No newline at end of file diff --git a/README.md b/README.md old mode 100755 new mode 100644 diff --git a/bin/postgres-entrypoint.sh b/bin/postgres-entrypoint.sh old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/.vscode/settings.json b/code/go/0chain.net/.vscode/settings.json old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobber/integration_tests.go b/code/go/0chain.net/blobber/integration_tests.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobber/main.go b/code/go/0chain.net/blobber/main.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobber/stub.go b/code/go/0chain.net/blobber/stub.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/allocation/allocationchange.go b/code/go/0chain.net/blobbercore/allocation/allocationchange.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/allocation/attributesfilechange.go b/code/go/0chain.net/blobbercore/allocation/attributesfilechange.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/allocation/copyfilechange.go b/code/go/0chain.net/blobbercore/allocation/copyfilechange.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/allocation/deletefilechange.go b/code/go/0chain.net/blobbercore/allocation/deletefilechange.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/allocation/entity.go b/code/go/0chain.net/blobbercore/allocation/entity.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/allocation/newfilechange.go b/code/go/0chain.net/blobbercore/allocation/newfilechange.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/allocation/protocol.go b/code/go/0chain.net/blobbercore/allocation/protocol.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/allocation/renamefilechange.go b/code/go/0chain.net/blobbercore/allocation/renamefilechange.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/allocation/updatefilechange.go b/code/go/0chain.net/blobbercore/allocation/updatefilechange.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/allocation/workers.go b/code/go/0chain.net/blobbercore/allocation/workers.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/README.md b/code/go/0chain.net/blobbercore/blobbergrpc/README.md old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/annotations.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/annotations.proto old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/http.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/http.proto old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/httpbody.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/google/api/httpbody.proto old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/challenge/entity.go b/code/go/0chain.net/blobbercore/challenge/entity.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/challenge/protocol.go b/code/go/0chain.net/blobbercore/challenge/protocol.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/challenge/stats.go b/code/go/0chain.net/blobbercore/challenge/stats.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/challenge/worker.go b/code/go/0chain.net/blobbercore/challenge/worker.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/config/config.go b/code/go/0chain.net/blobbercore/config/config.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/constants/context_key.go b/code/go/0chain.net/blobbercore/constants/context_key.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/datastore/blob_type.go b/code/go/0chain.net/blobbercore/datastore/blob_type.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/datastore/mock_store.go b/code/go/0chain.net/blobbercore/datastore/mock_store.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/datastore/model.go b/code/go/0chain.net/blobbercore/datastore/model.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/datastore/store.go b/code/go/0chain.net/blobbercore/datastore/store.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/errors/errors.go b/code/go/0chain.net/blobbercore/errors/errors.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/filestore/fs_store.go b/code/go/0chain.net/blobbercore/filestore/fs_store.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/filestore/store.go b/code/go/0chain.net/blobbercore/filestore/store.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/convert.go b/code/go/0chain.net/blobbercore/handler/convert.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/dto.go b/code/go/0chain.net/blobbercore/handler/dto.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go b/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/handler_integration_tests.go b/code/go/0chain.net/blobbercore/handler/handler_integration_tests.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/protocol.go b/code/go/0chain.net/blobbercore/handler/protocol.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/storage_handler.go b/code/go/0chain.net/blobbercore/handler/storage_handler.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/worker.go b/code/go/0chain.net/blobbercore/handler/worker.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/handler/zcncore.go b/code/go/0chain.net/blobbercore/handler/zcncore.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/readmarker/entity.go b/code/go/0chain.net/blobbercore/readmarker/entity.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/readmarker/protocol.go b/code/go/0chain.net/blobbercore/readmarker/protocol.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/readmarker/worker.go b/code/go/0chain.net/blobbercore/readmarker/worker.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/reference/collaborator.go b/code/go/0chain.net/blobbercore/reference/collaborator.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/reference/commitmetatxn.go b/code/go/0chain.net/blobbercore/reference/commitmetatxn.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/reference/objectpath.go b/code/go/0chain.net/blobbercore/reference/objectpath.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/reference/ref.go b/code/go/0chain.net/blobbercore/reference/ref.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/reference/referencepath.go b/code/go/0chain.net/blobbercore/reference/referencepath.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/stats/allocationstats.go b/code/go/0chain.net/blobbercore/stats/allocationstats.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/stats/blobberstats.go b/code/go/0chain.net/blobbercore/stats/blobberstats.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/stats/filestats.go b/code/go/0chain.net/blobbercore/stats/filestats.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/stats/handler.go b/code/go/0chain.net/blobbercore/stats/handler.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/util/json.go b/code/go/0chain.net/blobbercore/util/json.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/writemarker/entity.go b/code/go/0chain.net/blobbercore/writemarker/entity.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/writemarker/protocol.go b/code/go/0chain.net/blobbercore/writemarker/protocol.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/blobbercore/writemarker/worker.go b/code/go/0chain.net/blobbercore/writemarker/worker.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/conductor/build.go b/code/go/0chain.net/conductor/build.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/conductor/conductrpc/client.go b/code/go/0chain.net/conductor/conductrpc/client.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/conductor/conductrpc/entity.go b/code/go/0chain.net/conductor/conductrpc/entity.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/conductor/conductrpc/resolve.go b/code/go/0chain.net/conductor/conductrpc/resolve.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/conductor/conductrpc/server.go b/code/go/0chain.net/conductor/conductrpc/server.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/conductor/conductrpc/state.go b/code/go/0chain.net/conductor/conductrpc/state.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/conductor/config/byzantine.go b/code/go/0chain.net/conductor/config/byzantine.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/conductor/config/config.go b/code/go/0chain.net/conductor/config/config.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/build/info.go b/code/go/0chain.net/core/build/info.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/cache/cache.go b/code/go/0chain.net/core/cache/cache.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/cache/lfu.go b/code/go/0chain.net/core/cache/lfu.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/cache/lru.go b/code/go/0chain.net/core/cache/lru.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/chain/entity.go b/code/go/0chain.net/core/chain/entity.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/common/context.go b/code/go/0chain.net/core/common/context.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/common/errors.go b/code/go/0chain.net/core/common/errors.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/common/handler.go b/code/go/0chain.net/core/common/handler.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/common/lookup.go b/code/go/0chain.net/core/common/lookup.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/common/rate_limiter.go b/code/go/0chain.net/core/common/rate_limiter.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/common/time.go b/code/go/0chain.net/core/common/time.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/common/types.go b/code/go/0chain.net/core/common/types.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/common/utils.go b/code/go/0chain.net/core/common/utils.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/config/config.go b/code/go/0chain.net/core/config/config.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/encryption/hash.go b/code/go/0chain.net/core/encryption/hash.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/encryption/keys.go b/code/go/0chain.net/core/encryption/keys.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/lock/lock.go b/code/go/0chain.net/core/lock/lock.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/logging/logger.go b/code/go/0chain.net/core/logging/logger.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/node/context.go b/code/go/0chain.net/core/node/context.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/node/self_node.go b/code/go/0chain.net/core/node/self_node.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/transaction/entity.go b/code/go/0chain.net/core/transaction/entity.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/transaction/http.go b/code/go/0chain.net/core/transaction/http.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/transaction/type.go b/code/go/0chain.net/core/transaction/type.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/util/http.go b/code/go/0chain.net/core/util/http.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/util/merkle_tree.go b/code/go/0chain.net/core/util/merkle_tree.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/util/merkle_tree_interface.go b/code/go/0chain.net/core/util/merkle_tree_interface.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/util/merkle_tree_test.go b/code/go/0chain.net/core/util/merkle_tree_test.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/core/util/secure_value.go b/code/go/0chain.net/core/util/secure_value.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/validator/main.go b/code/go/0chain.net/validator/main.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/validatorcore/config/config.go b/code/go/0chain.net/validatorcore/config/config.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/validatorcore/storage/challenge_handler.go b/code/go/0chain.net/validatorcore/storage/challenge_handler.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/validatorcore/storage/challenge_handler_test.go b/code/go/0chain.net/validatorcore/storage/challenge_handler_test.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/validatorcore/storage/context.go b/code/go/0chain.net/validatorcore/storage/context.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/validatorcore/storage/handler.go b/code/go/0chain.net/validatorcore/storage/handler.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/validatorcore/storage/models.go b/code/go/0chain.net/validatorcore/storage/models.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/validatorcore/storage/models_test.go b/code/go/0chain.net/validatorcore/storage/models_test.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/validatorcore/storage/protocol.go b/code/go/0chain.net/validatorcore/storage/protocol.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/validatorcore/storage/writemarker/entity.go b/code/go/0chain.net/validatorcore/storage/writemarker/entity.go old mode 100755 new mode 100644 diff --git a/code/go/0chain.net/validatorcore/storage/writemarker/entity_test.go b/code/go/0chain.net/validatorcore/storage/writemarker/entity_test.go old mode 100755 new mode 100644 diff --git a/config/0chain_validator.yaml b/config/0chain_validator.yaml old mode 100755 new mode 100644 diff --git a/docker.aws/DOCKER_VERSION b/docker.aws/DOCKER_VERSION old mode 100755 new mode 100644 diff --git a/docker.aws/README.md b/docker.aws/README.md old mode 100755 new mode 100644 diff --git a/docker.aws/build.blobber/.env b/docker.aws/build.blobber/.env old mode 100755 new mode 100644 diff --git a/docker.aws/build.blobber/Dockerfile b/docker.aws/build.blobber/Dockerfile old mode 100755 new mode 100644 diff --git a/docker.aws/build.blobber/docker-compose.yml b/docker.aws/build.blobber/docker-compose.yml old mode 100755 new mode 100644 diff --git a/docker.aws/build.validator/.env b/docker.aws/build.validator/.env old mode 100755 new mode 100644 diff --git a/docker.aws/build.validator/Dockerfile b/docker.aws/build.validator/Dockerfile old mode 100755 new mode 100644 diff --git a/docker.aws/build.validator/docker-compose.yml b/docker.aws/build.validator/docker-compose.yml old mode 100755 new mode 100644 diff --git a/docker.local/Dockerfile b/docker.local/Dockerfile old mode 100755 new mode 100644 diff --git a/docker.local/IntegrationTestsBlobberDockerfile b/docker.local/IntegrationTestsBlobberDockerfile old mode 100755 new mode 100644 diff --git a/docker.local/ValidatorDockerfile b/docker.local/ValidatorDockerfile old mode 100755 new mode 100644 diff --git a/docker.local/b0docker-compose.yml b/docker.local/b0docker-compose.yml old mode 100755 new mode 100644 diff --git a/docker.local/docker-clean/Dockerfile b/docker.local/docker-clean/Dockerfile old mode 100755 new mode 100644 diff --git a/docker.local/docker-clean/docker-clean-compose.yml b/docker.local/docker-clean/docker-clean-compose.yml old mode 100755 new mode 100644 diff --git a/docker.local/docker-clean/docker-clean.sh b/docker.local/docker-clean/docker-clean.sh old mode 100755 new mode 100644 diff --git a/docker.local/docker-compose.yml b/docker.local/docker-compose.yml old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/b0bnode1_keys.txt b/docker.local/keys_config/b0bnode1_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/b0bnode2_keys.txt b/docker.local/keys_config/b0bnode2_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/b0bnode3_keys.txt b/docker.local/keys_config/b0bnode3_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/b0bnode4_keys.txt b/docker.local/keys_config/b0bnode4_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/b0bnode5_keys.txt b/docker.local/keys_config/b0bnode5_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/b0bnode6_keys.txt b/docker.local/keys_config/b0bnode6_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/bnode1_keys.txt b/docker.local/keys_config/bnode1_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/bnode2_keys.txt b/docker.local/keys_config/bnode2_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/bnode3_keys.txt b/docker.local/keys_config/bnode3_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/bnode4_keys.txt b/docker.local/keys_config/bnode4_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/bnode5_keys.txt b/docker.local/keys_config/bnode5_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/bnode6_keys.txt b/docker.local/keys_config/bnode6_keys.txt old mode 100755 new mode 100644 diff --git a/docker.local/keys_config/minio_config.txt b/docker.local/keys_config/minio_config.txt old mode 100755 new mode 100644 diff --git a/docker.local/p0docker-compose.yml b/docker.local/p0docker-compose.yml old mode 100755 new mode 100644 diff --git a/docs/src/0box_flow.plantuml b/docs/src/0box_flow.plantuml old mode 100755 new mode 100644 diff --git a/docs/src/challenge.plantuml b/docs/src/challenge.plantuml old mode 100755 new mode 100644 diff --git a/docs/src/download_flow.plantuml b/docs/src/download_flow.plantuml old mode 100755 new mode 100644 diff --git a/docs/src/out/challenge/challenge.png b/docs/src/out/challenge/challenge.png old mode 100755 new mode 100644 diff --git a/docs/src/out/repair/repair.png b/docs/src/out/repair/repair.png old mode 100755 new mode 100644 diff --git a/docs/src/repair.plantuml b/docs/src/repair.plantuml old mode 100755 new mode 100644 diff --git a/docs/src/upload_flow.plantuml b/docs/src/upload_flow.plantuml old mode 100755 new mode 100644 diff --git a/go.mod b/go.mod old mode 100755 new mode 100644 diff --git a/go.sum b/go.sum old mode 100755 new mode 100644 diff --git a/https/README.md b/https/README.md old mode 100755 new mode 100644 diff --git a/https/conf.d/nginx.conf b/https/conf.d/nginx.conf old mode 100755 new mode 100644 diff --git a/https/docker-compose.yml b/https/docker-compose.yml old mode 100755 new mode 100644 diff --git a/sql/00-create-user.sql b/sql/00-create-user.sql old mode 100755 new mode 100644 diff --git a/sql/01-create-table.sql b/sql/01-create-table.sql old mode 100755 new mode 100644 diff --git a/sql/02-grant-priv.sql b/sql/02-grant-priv.sql old mode 100755 new mode 100644 diff --git a/sql/03-add-allocation-prices.sql b/sql/03-add-allocation-prices.sql old mode 100755 new mode 100644 diff --git a/sql/04-add-on-cloud.sql b/sql/04-add-on-cloud.sql old mode 100755 new mode 100644 diff --git a/sql/05-add-commit-meta-txns-table.sql b/sql/05-add-commit-meta-txns-table.sql old mode 100755 new mode 100644 diff --git a/sql/06-add-cleaned_up-column-to-allocations.sql b/sql/06-add-cleaned_up-column-to-allocations.sql old mode 100755 new mode 100644 diff --git a/sql/07-terms-belongs-to-allocation-id.sql b/sql/07-terms-belongs-to-allocation-id.sql old mode 100755 new mode 100644 diff --git a/sql/08-add-payer-id-to-allocations.sql b/sql/08-add-payer-id-to-allocations.sql old mode 100755 new mode 100644 diff --git a/sql/09-add-suspend-column-to-read-markers.sql b/sql/09-add-suspend-column-to-read-markers.sql old mode 100755 new mode 100644 diff --git a/sql/10-add-time_unit-column-to-allocations.sql b/sql/10-add-time_unit-column-to-allocations.sql old mode 100755 new mode 100644 diff --git a/sql/11-add-payer_id-and-auth_tiket-columns-to-read_markers.sql b/sql/11-add-payer_id-and-auth_tiket-columns-to-read_markers.sql old mode 100755 new mode 100644 diff --git a/sql/12-add-attributes-column-to-reference_objects.sql b/sql/12-add-attributes-column-to-reference_objects.sql old mode 100755 new mode 100644 diff --git a/sql/13-add-collaborators-table.sql b/sql/13-add-collaborators-table.sql old mode 100755 new mode 100644 diff --git a/test.sh b/test.sh old mode 100755 new mode 100644 From f9767c0a33e702c4d62475a74a7f89988b17f2eb Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 10 May 2021 18:20:39 +0530 Subject: [PATCH 016/183] :recycling: change make test and make lint commands --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index b85f580b9..0db3a71d0 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ .PHONY: test lint test: - cd code/go/0chain.net; go test ./...; + go test ./...; lint: - cd code/go/0chain.net; golangci-lint run; \ No newline at end of file + golangci-lint run; \ No newline at end of file From fda9187210c5d30e5209b06a86a469532f594318 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 12 May 2021 22:46:15 +0530 Subject: [PATCH 017/183] :sparkles: added server reflection for grpc --- code/go/0chain.net/blobber/main.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/code/go/0chain.net/blobber/main.go b/code/go/0chain.net/blobber/main.go index 322c27232..d19ccb938 100644 --- a/code/go/0chain.net/blobber/main.go +++ b/code/go/0chain.net/blobber/main.go @@ -15,6 +15,8 @@ import ( "strings" "time" + "google.golang.org/grpc/reflection" + "0chain.net/blobbercore/allocation" "0chain.net/blobbercore/challenge" "0chain.net/blobbercore/config" @@ -346,6 +348,10 @@ func main() { grpcServer := handler.NewServerWithMiddlewares(rl) handler.RegisterGRPCServices(r, grpcServer) + if config.Development() { + reflection.Register(grpcServer) + } + rHandler := handlers.CORS(originsOk, headersOk, methodsOk)(r) if config.Development() { // No WriteTimeout setup to enable pprof From 491244d07c35f815b68fce00db3745a77e8cc5df Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 12 May 2021 23:25:20 +0530 Subject: [PATCH 018/183] :memo: added docs relating to how to interact with grpc api's --- code/go/0chain.net/blobbercore/blobbergrpc/README.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/README.md b/code/go/0chain.net/blobbercore/blobbergrpc/README.md index 95e391dcc..c856c7db9 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/README.md +++ b/code/go/0chain.net/blobbercore/blobbergrpc/README.md @@ -7,4 +7,10 @@ GRPC API is implemented in `handler/grpc_handler.go`. ## Plugins * [grpc-gateway](https://github.com/grpc-ecosystem/grpc-gateway) -plugin is being used to expose a REST api for grpc incompatible clients. \ No newline at end of file +plugin is being used to expose a REST api for grpc incompatible clients. + +## Interacting with the api +The current grpc implementation supports server reflection in development environment. +You can interact with the api using https://github.com/gusaul/grpcox. + +Make sure the server is running on `--deployment_mode 0` to use server reflection. \ No newline at end of file From 794d0def081dc869e16a7362c5109ec8948cea5e Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Fri, 14 May 2021 18:51:47 +0530 Subject: [PATCH 019/183] :sparkles: pointed get allocation handler to grpc --- code/go/0chain.net/blobber/main.go | 3 +- .../0chain.net/blobbercore/handler/convert.go | 35 +++++++++++++++++++ .../0chain.net/blobbercore/handler/handler.go | 34 +++++++++++++----- 3 files changed, 62 insertions(+), 10 deletions(-) diff --git a/code/go/0chain.net/blobber/main.go b/code/go/0chain.net/blobber/main.go index 322c27232..92eff667f 100644 --- a/code/go/0chain.net/blobber/main.go +++ b/code/go/0chain.net/blobber/main.go @@ -339,11 +339,10 @@ func main() { methodsOk := handlers.AllowedMethods([]string{"GET", "HEAD", "POST", "PUT", "DELETE", "OPTIONS"}) - rl := common.ConfigRateLimits() initHandlers(r) initServer() - grpcServer := handler.NewServerWithMiddlewares(rl) + grpcServer := handler.NewServerWithMiddlewares(common.ConfigRateLimits()) handler.RegisterGRPCServices(r, grpcServer) rHandler := handlers.CORS(originsOk, headersOk, methodsOk)(r) diff --git a/code/go/0chain.net/blobbercore/handler/convert.go b/code/go/0chain.net/blobbercore/handler/convert.go index bc5f699f5..03d96ec43 100644 --- a/code/go/0chain.net/blobbercore/handler/convert.go +++ b/code/go/0chain.net/blobbercore/handler/convert.go @@ -1,10 +1,13 @@ package handler import ( + "time" + "0chain.net/blobbercore/allocation" "0chain.net/blobbercore/blobbergrpc" "0chain.net/blobbercore/stats" "0chain.net/blobbercore/writemarker" + "0chain.net/core/common" ) func AllocationToGRPCAllocation(alloc *allocation.Allocation) *blobbergrpc.Allocation { @@ -39,6 +42,38 @@ func AllocationToGRPCAllocation(alloc *allocation.Allocation) *blobbergrpc.Alloc } } +func GRPCAllocationToAllocation(alloc *blobbergrpc.Allocation) *allocation.Allocation { + terms := make([]*allocation.Terms, 0, len(alloc.Terms)) + for _, t := range alloc.Terms { + terms = append(terms, &allocation.Terms{ + ID: t.ID, + BlobberID: t.BlobberID, + AllocationID: t.AllocationID, + ReadPrice: t.ReadPrice, + WritePrice: t.WritePrice, + }) + } + return &allocation.Allocation{ + ID: alloc.ID, + Tx: alloc.Tx, + TotalSize: alloc.TotalSize, + UsedSize: alloc.UsedSize, + OwnerID: alloc.OwnerID, + OwnerPublicKey: alloc.OwnerPublicKey, + Expiration: common.Timestamp(alloc.Expiration), + AllocationRoot: alloc.AllocationRoot, + BlobberSize: alloc.BlobberSize, + BlobberSizeUsed: alloc.BlobberSizeUsed, + LatestRedeemedWM: alloc.LatestRedeemedWM, + IsRedeemRequired: alloc.IsRedeemRequired, + TimeUnit: time.Duration(alloc.TimeUnit), + CleanedUp: alloc.CleanedUp, + Finalized: alloc.Finalized, + Terms: terms, + PayerID: alloc.PayerID, + } +} + func FileStatsToFileStatsGRPC(fileStats *stats.FileStats) *blobbergrpc.FileStats { if fileStats == nil { return &blobbergrpc.FileStats{} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 49da5ac50..065b70c6c 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -9,6 +9,8 @@ import ( "runtime/pprof" "time" + "0chain.net/blobbercore/blobbergrpc" + "0chain.net/blobbercore/config" "0chain.net/blobbercore/constants" "0chain.net/blobbercore/datastore" @@ -29,6 +31,8 @@ func GetMetaDataStore() *datastore.Store { /*SetupHandlers sets up the necessary API end points */ func SetupHandlers(r *mux.Router) { + svc := newGRPCBlobberService(&storageHandler, &packageHandler{}) + //object operations r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) @@ -42,7 +46,7 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/file/calculatehash/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CalculateHashHandler)))) //object info related apis - r.HandleFunc("/allocation", common.UserRateLimit(common.ToJSONResponse(WithConnection(AllocationHandler)))) + r.HandleFunc("/allocation", common.UserRateLimit(common.ToJSONResponse(WithConnection(AllocationHandler(svc))))).Methods("GET") r.HandleFunc("/v1/file/meta/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileMetaHandler)))) r.HandleFunc("/v1/file/stats/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileStatsHandler)))) r.HandleFunc("/v1/file/list/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ListHandler)))) @@ -113,15 +117,29 @@ func setupHandlerContext(ctx context.Context, r *http.Request) context.Context { return ctx } -func AllocationHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) - - response, err := storageHandler.GetAllocationDetails(ctx, r) - if err != nil { - return nil, err +func setupHandlerGRPCContext(r *http.Request) *blobbergrpc.RequestContext { + var vars = mux.Vars(r) + return &blobbergrpc.RequestContext{ + Client: r.Header.Get(common.ClientHeader), + ClientKey: r.Header.Get(common.ClientKeyHeader), + Allocation: vars["allocation"], } +} - return response, nil +func AllocationHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + reqCtx := setupHandlerGRPCContext(r) + + getAllocationResp, err := svc.GetAllocation(ctx, &blobbergrpc.GetAllocationRequest{ + Context: reqCtx, + Id: r.FormValue("id"), + }) + if err != nil { + return nil, err + } + + return GRPCAllocationToAllocation(getAllocationResp.Allocation), nil + } } func FileMetaHandler(ctx context.Context, r *http.Request) (interface{}, error) { From 9be4c22df0226b16d3017ba7652e1b03845fdf4f Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sat, 15 May 2021 09:49:10 +0530 Subject: [PATCH 020/183] :sparkles: pointed getfilemeta and getfilestats handler to equivalent grpc handler --- .../0chain.net/blobbercore/handler/convert.go | 41 +++++++++++ .../blobbercore/handler/grpc_handler.go | 2 +- .../0chain.net/blobbercore/handler/handler.go | 69 ++++++++++++++----- .../blobbercore/reference/objectpath.go | 64 +++++++++++++++++ 4 files changed, 159 insertions(+), 17 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/convert.go b/code/go/0chain.net/blobbercore/handler/convert.go index 03d96ec43..3445a4984 100644 --- a/code/go/0chain.net/blobbercore/handler/convert.go +++ b/code/go/0chain.net/blobbercore/handler/convert.go @@ -3,6 +3,10 @@ package handler import ( "time" + "0chain.net/blobbercore/reference" + + "0chain.net/blobbercore/datastore" + "0chain.net/blobbercore/allocation" "0chain.net/blobbercore/blobbergrpc" "0chain.net/blobbercore/stats" @@ -105,3 +109,40 @@ func WriteMarkerToWriteMarkerGRPC(wm writemarker.WriteMarker) *blobbergrpc.Write Signature: wm.Signature, } } + +func FileStatsGRPCToFileStats(fileStats *blobbergrpc.FileStats) *stats.FileStats { + if fileStats == nil { + return &stats.FileStats{} + } + + return &stats.FileStats{ + ID: fileStats.ID, + RefID: fileStats.RefID, + NumUpdates: fileStats.NumUpdates, + NumBlockDownloads: fileStats.NumBlockDownloads, + SuccessChallenges: fileStats.SuccessChallenges, + FailedChallenges: fileStats.FailedChallenges, + LastChallengeResponseTxn: fileStats.LastChallengeResponseTxn, + WriteMarkerRedeemTxn: fileStats.WriteMarkerRedeemTxn, + ModelWithTS: datastore.ModelWithTS{ + CreatedAt: time.Unix(0, fileStats.CreatedAt), + UpdatedAt: time.Unix(0, fileStats.UpdatedAt), + }, + } +} + +func CollaboratorToGRPCCollaborator(c reference.Collaborator) *blobbergrpc.Collaborator { + return &blobbergrpc.Collaborator{ + RefId: c.RefID, + ClientId: c.ClientID, + CreatedAt: c.CreatedAt.UnixNano(), + } +} + +func GRPCCollaboratorToCollaborator(c *blobbergrpc.Collaborator) reference.Collaborator { + return reference.Collaborator{ + RefID: c.RefId, + ClientID: c.ClientId, + CreatedAt: time.Unix(0, c.CreatedAt), + } +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index dfb361511..93cc438c7 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -44,7 +44,7 @@ func (b *blobberGRPCService) GetAllocation(ctx context.Context, request *blobber func (b *blobberGRPCService) GetFileMetaData(ctx context.Context, req *blobbergrpc.GetFileMetaDataRequest) (*blobbergrpc.GetFileMetaDataResponse, error) { logger := ctxzap.Extract(ctx) - allocationObj, err := b.storageHandler.verifyAllocation(ctx, req.Allocation, true) + allocationObj, err := b.storageHandler.verifyAllocation(ctx, req.Context.Allocation, true) if err != nil { return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) } diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 065b70c6c..0dad3ae08 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -4,11 +4,14 @@ package handler import ( "context" + "encoding/json" "net/http" "os" "runtime/pprof" "time" + "0chain.net/blobbercore/reference" + "0chain.net/blobbercore/blobbergrpc" "0chain.net/blobbercore/config" @@ -47,8 +50,8 @@ func SetupHandlers(r *mux.Router) { //object info related apis r.HandleFunc("/allocation", common.UserRateLimit(common.ToJSONResponse(WithConnection(AllocationHandler(svc))))).Methods("GET") - r.HandleFunc("/v1/file/meta/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileMetaHandler)))) - r.HandleFunc("/v1/file/stats/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileStatsHandler)))) + r.HandleFunc("/v1/file/meta/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileMetaHandler(svc))))).Methods("GET") + r.HandleFunc("/v1/file/stats/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileStatsHandler(svc))))).Methods("GET") r.HandleFunc("/v1/file/list/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ListHandler)))) r.HandleFunc("/v1/file/objectpath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectPathHandler)))) r.HandleFunc("/v1/file/referencepath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ReferencePathHandler)))) @@ -142,15 +145,31 @@ func AllocationHandler(svc *blobberGRPCService) func(ctx context.Context, r *htt } } -func FileMetaHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) +func FileMetaHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + reqCtx := setupHandlerGRPCContext(r) - response, err := storageHandler.GetFileMeta(ctx, r) - if err != nil { - return nil, err - } + getFileMetaDataResp, err := svc.GetFileMetaData(ctx, &blobbergrpc.GetFileMetaDataRequest{ + Context: reqCtx, + Path: r.FormValue("path"), + PathHash: r.FormValue("path_hash"), + AuthToken: r.FormValue("auth_token"), + Allocation: reqCtx.Allocation, + }) + if err != nil { + return nil, err + } - return response, nil + var collaborators []reference.Collaborator + for _, c := range getFileMetaDataResp.Collaborators { + collaborators = append(collaborators, GRPCCollaboratorToCollaborator(c)) + } + + result := reference.FileRefGRPCToFileRef(getFileMetaDataResp.MetaData).GetListingData(ctx) + result["collaborators"] = collaborators + + return result, nil + } } func CommitMetaTxnHandler(ctx context.Context, r *http.Request) (interface{}, error) { @@ -175,15 +194,33 @@ func CollaboratorHandler(ctx context.Context, r *http.Request) (interface{}, err return response, nil } -func FileStatsHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) +func FileStatsHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + reqCtx := setupHandlerGRPCContext(r) - response, err := storageHandler.GetFileStats(ctx, r) - if err != nil { - return nil, err - } + getFileStatsResponse, err := svc.GetFileStats(ctx, &blobbergrpc.GetFileStatsRequest{ + Context: reqCtx, + Path: r.FormValue("path"), + PathHash: r.FormValue("path_hash"), + Allocation: reqCtx.Allocation, + }) + if err != nil { + return nil, err + } - return response, nil + result := reference.FileRefGRPCToFileRef(getFileStatsResponse.MetaData).GetListingData(ctx) + + statsMap := make(map[string]interface{}) + statsBytes, _ := json.Marshal(FileStatsGRPCToFileStats(getFileStatsResponse.Stats)) + if err = json.Unmarshal(statsBytes, &statsMap); err != nil { + return nil, err + } + for k, v := range statsMap { + result[k] = v + } + + return result, nil + } } /*DownloadHandler is the handler to respond to download requests from clients*/ diff --git a/code/go/0chain.net/blobbercore/reference/objectpath.go b/code/go/0chain.net/blobbercore/reference/objectpath.go index 3c5786dcf..bdca0e7e0 100644 --- a/code/go/0chain.net/blobbercore/reference/objectpath.go +++ b/code/go/0chain.net/blobbercore/reference/objectpath.go @@ -3,6 +3,7 @@ package reference import ( "context" "fmt" + "time" "0chain.net/blobbercore/blobbergrpc" @@ -236,3 +237,66 @@ func convertDirRefToDirMetaDataGRPC(dirref *Ref) *blobbergrpc.DirMetaData { UpdatedAt: dirref.UpdatedAt.UnixNano(), } } + +func FileRefGRPCToFileRef(ref *blobbergrpc.FileRef) *Ref { + switch ref.Type { + case FILE: + return convertFileMetaDataGRPCToFileRef(ref.FileMetaData) + case DIRECTORY: + return convertDirMetaDataGRPCToDirRef(ref.DirMetaData) + } + + return nil +} + +func convertFileMetaDataGRPCToFileRef(metaData *blobbergrpc.FileMetaData) *Ref { + var commitMetaTxnsGRPC []CommitMetaTxn + for _, c := range metaData.CommitMetaTxns { + commitMetaTxnsGRPC = append(commitMetaTxnsGRPC, CommitMetaTxn{ + RefID: c.RefId, + TxnID: c.TxnId, + CreatedAt: time.Unix(0, c.CreatedAt), + }) + } + return &Ref{ + Type: metaData.Type, + LookupHash: metaData.LookupHash, + Name: metaData.Name, + Path: metaData.Path, + Hash: metaData.Hash, + NumBlocks: metaData.NumBlocks, + PathHash: metaData.PathHash, + CustomMeta: metaData.CustomMeta, + ContentHash: metaData.ContentHash, + Size: metaData.Size, + MerkleRoot: metaData.MerkleRoot, + ActualFileSize: metaData.ActualFileSize, + ActualFileHash: metaData.ActualFileHash, + MimeType: metaData.MimeType, + ThumbnailSize: metaData.ThumbnailSize, + ThumbnailHash: metaData.ThumbnailHash, + ActualThumbnailSize: metaData.ActualThumbnailSize, + ActualThumbnailHash: metaData.ActualThumbnailHash, + EncryptedKey: metaData.EncryptedKey, + Attributes: metaData.Attributes, + OnCloud: metaData.OnCloud, + CommitMetaTxns: commitMetaTxnsGRPC, + CreatedAt: time.Unix(0, metaData.CreatedAt), + UpdatedAt: time.Unix(0, metaData.UpdatedAt), + } +} + +func convertDirMetaDataGRPCToDirRef(dirref *blobbergrpc.DirMetaData) *Ref { + return &Ref{ + Type: dirref.Type, + LookupHash: dirref.LookupHash, + Name: dirref.Name, + Path: dirref.Path, + Hash: dirref.Hash, + NumBlocks: dirref.NumBlocks, + PathHash: dirref.PathHash, + Size: dirref.Size, + CreatedAt: time.Unix(0, dirref.CreatedAt), + UpdatedAt: time.Unix(0, dirref.UpdatedAt), + } +} From 6d472dc2f0412156c7725adf4dbf652881cf1ac7 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 16 May 2021 10:22:27 +0530 Subject: [PATCH 021/183] :sparkles: pointed all read http handlers to grpc handler --- .../blobbercore/blobbergrpc/blobber.pb.go | 774 +++++++++--------- .../blobbergrpc/proto/blobber.proto | 5 +- .../0chain.net/blobbercore/handler/convert.go | 76 ++ .../blobbercore/handler/grpc_handler.go | 60 +- .../0chain.net/blobbercore/handler/handler.go | 130 ++- .../0chain.net/blobbercore/handler/helper.go | 6 +- .../blobbercore/openapi/blobber.swagger.json | 18 +- .../blobbercore/reference/objectpath.go | 77 -- .../0chain.net/blobbercore/reference/ref.go | 4 + 9 files changed, 622 insertions(+), 528 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 7f2063828..0d91b561a 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -451,10 +451,11 @@ type ObjectPath struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RootHash string `protobuf:"bytes,1,opt,name=RootHash,proto3" json:"RootHash,omitempty"` - Meta *FileRef `protobuf:"bytes,2,opt,name=Meta,proto3" json:"Meta,omitempty"` - Path *FileRef `protobuf:"bytes,3,opt,name=Path,proto3" json:"Path,omitempty"` - FileBlockNum int64 `protobuf:"varint,4,opt,name=FileBlockNum,proto3" json:"FileBlockNum,omitempty"` + RootHash string `protobuf:"bytes,1,opt,name=RootHash,proto3" json:"RootHash,omitempty"` + Meta *FileRef `protobuf:"bytes,2,opt,name=Meta,proto3" json:"Meta,omitempty"` + Path *FileRef `protobuf:"bytes,3,opt,name=Path,proto3" json:"Path,omitempty"` + PathList []*FileRef `protobuf:"bytes,4,rep,name=PathList,proto3" json:"PathList,omitempty"` + FileBlockNum int64 `protobuf:"varint,5,opt,name=FileBlockNum,proto3" json:"FileBlockNum,omitempty"` } func (x *ObjectPath) Reset() { @@ -510,6 +511,13 @@ func (x *ObjectPath) GetPath() *FileRef { return nil } +func (x *ObjectPath) GetPathList() []*FileRef { + if x != nil { + return x.PathList + } + return nil +} + func (x *ObjectPath) GetFileBlockNum() int64 { if x != nil { return x.FileBlockNum @@ -704,8 +712,9 @@ type ListEntitiesResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` - MetaData *FileRef `protobuf:"bytes,2,opt,name=MetaData,proto3" json:"MetaData,omitempty"` + AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` + MetaData *FileRef `protobuf:"bytes,2,opt,name=MetaData,proto3" json:"MetaData,omitempty"` + Entities []*FileRef `protobuf:"bytes,3,rep,name=Entities,proto3" json:"Entities,omitempty"` } func (x *ListEntitiesResponse) Reset() { @@ -754,6 +763,13 @@ func (x *ListEntitiesResponse) GetMetaData() *FileRef { return nil } +func (x *ListEntitiesResponse) GetEntities() []*FileRef { + if x != nil { + return x.Entities + } + return nil +} + type GetFileStatsRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -1977,17 +1993,16 @@ type DirMetaData struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Type string `protobuf:"bytes,1,opt,name=Type,proto3" json:"Type,omitempty"` - LookupHash string `protobuf:"bytes,2,opt,name=LookupHash,proto3" json:"LookupHash,omitempty"` - Name string `protobuf:"bytes,3,opt,name=Name,proto3" json:"Name,omitempty"` - Path string `protobuf:"bytes,4,opt,name=Path,proto3" json:"Path,omitempty"` - Hash string `protobuf:"bytes,5,opt,name=Hash,proto3" json:"Hash,omitempty"` - NumBlocks int64 `protobuf:"varint,6,opt,name=NumBlocks,proto3" json:"NumBlocks,omitempty"` - PathHash string `protobuf:"bytes,7,opt,name=PathHash,proto3" json:"PathHash,omitempty"` - Size int64 `protobuf:"varint,8,opt,name=Size,proto3" json:"Size,omitempty"` - CreatedAt int64 `protobuf:"varint,9,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` - UpdatedAt int64 `protobuf:"varint,10,opt,name=UpdatedAt,proto3" json:"UpdatedAt,omitempty"` - Children []*FileRef `protobuf:"bytes,11,rep,name=Children,proto3" json:"Children,omitempty"` + Type string `protobuf:"bytes,1,opt,name=Type,proto3" json:"Type,omitempty"` + LookupHash string `protobuf:"bytes,2,opt,name=LookupHash,proto3" json:"LookupHash,omitempty"` + Name string `protobuf:"bytes,3,opt,name=Name,proto3" json:"Name,omitempty"` + Path string `protobuf:"bytes,4,opt,name=Path,proto3" json:"Path,omitempty"` + Hash string `protobuf:"bytes,5,opt,name=Hash,proto3" json:"Hash,omitempty"` + NumBlocks int64 `protobuf:"varint,6,opt,name=NumBlocks,proto3" json:"NumBlocks,omitempty"` + PathHash string `protobuf:"bytes,7,opt,name=PathHash,proto3" json:"PathHash,omitempty"` + Size int64 `protobuf:"varint,8,opt,name=Size,proto3" json:"Size,omitempty"` + CreatedAt int64 `protobuf:"varint,9,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` + UpdatedAt int64 `protobuf:"varint,10,opt,name=UpdatedAt,proto3" json:"UpdatedAt,omitempty"` } func (x *DirMetaData) Reset() { @@ -2092,13 +2107,6 @@ func (x *DirMetaData) GetUpdatedAt() int64 { return 0 } -func (x *DirMetaData) GetChildren() []*FileRef { - if x != nil { - return x.Children - } - return nil -} - var File_blobber_proto protoreflect.FileDescriptor var file_blobber_proto_rawDesc = []byte{ @@ -2174,7 +2182,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, - 0x72, 0x6b, 0x65, 0x72, 0x22, 0xae, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, + 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, @@ -2183,334 +2191,337 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, - 0x6d, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, - 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, - 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, - 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, - 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, - 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, - 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, - 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, - 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, - 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, - 0x75, 0x72, 0x65, 0x22, 0xc3, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, - 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x63, - 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, - 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, - 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, - 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, - 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x77, 0x0a, 0x14, 0x4c, 0x69, 0x73, - 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x22, 0xa4, 0x01, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x63, 0x6f, - 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x52, - 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, - 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, - 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, - 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, - 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, - 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, - 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, - 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, - 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, - 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, - 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, - 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, - 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, - 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, - 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, - 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, - 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, - 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, - 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, - 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, - 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0xc6, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, - 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, - 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, - 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, - 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, - 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, - 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, - 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, - 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, - 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, - 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, - 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, - 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, - 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, - 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, - 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x67, 0x0a, 0x0e, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x63, - 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x63, 0x6c, 0x69, - 0x65, 0x6e, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x6b, 0x65, - 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x4b, - 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0x64, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x63, 0x6f, - 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x52, - 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, - 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, - 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, - 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, - 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, - 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, - 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, - 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, - 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, - 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, - 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, - 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, - 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, - 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, - 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, - 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, - 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, - 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, - 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, - 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, - 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, - 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, - 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, - 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, - 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, - 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, - 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, - 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, - 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, - 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, - 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, - 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, + 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, + 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, + 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, + 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, + 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, + 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, + 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, + 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, + 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, + 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0xc3, 0x01, 0x0a, + 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, + 0x78, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, + 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, + 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, + 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, + 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, + 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, + 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, - 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, - 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, - 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, - 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, - 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, - 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, - 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, - 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, - 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, - 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, - 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, - 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, - 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, - 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, - 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, - 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, - 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, - 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, - 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, - 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, - 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, - 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, - 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, - 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, - 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0xc0, - 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, - 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, - 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, - 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, - 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x43, 0x68, 0x69, 0x6c, - 0x64, 0x72, 0x65, 0x6e, 0x18, 0x0b, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x43, 0x68, 0x69, 0x6c, 0x64, 0x72, 0x65, - 0x6e, 0x32, 0xe8, 0x07, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, - 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, + 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, + 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0xa4, 0x01, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, + 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, + 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, - 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, - 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, - 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, - 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, - 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, + 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, + 0x78, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, + 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, + 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, + 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, + 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, - 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, - 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, - 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, - 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, - 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, - 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, - 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, - 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, + 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, + 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, + 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, + 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, + 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, + 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, + 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, + 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, + 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, + 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, + 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, + 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, + 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0xc6, 0x01, 0x0a, 0x16, + 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, + 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6e, + 0x74, 0x65, 0x78, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, + 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, + 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, + 0x6b, 0x65, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, + 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, + 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, + 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, + 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, + 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, + 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, + 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, + 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, + 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, + 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, + 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x67, 0x0a, 0x0e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x16, + 0x0a, 0x06, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, + 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, + 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x6c, 0x69, 0x65, + 0x6e, 0x74, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x64, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, + 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, + 0x78, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, + 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, + 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, + 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, + 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, + 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, + 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, + 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, + 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, + 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, + 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, + 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, + 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, + 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, + 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, + 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, + 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, + 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, + 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, + 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, + 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, + 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, + 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, + 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, + 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, + 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, + 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, + 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, + 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, + 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, + 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, + 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, + 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, + 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, + 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, + 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, + 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, + 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, + 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, + 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, + 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, + 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, + 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, + 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, + 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, + 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, + 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, + 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, + 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, + 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, + 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, + 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, + 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, + 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, 0x07, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, + 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, + 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, - 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, - 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, - 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, + 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, + 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, + 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, + 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, + 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, + 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, - 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, - 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x0f, 0x5a, 0x0d, - 0x2e, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x0f, 0x5a, 0x0d, 0x2e, 0x2f, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2568,40 +2579,41 @@ var file_blobber_proto_depIdxs = []int32{ 8, // 10: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker 23, // 11: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef 23, // 12: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 18, // 13: blobber.service.v1.ListEntitiesRequest.context:type_name -> blobber.service.v1.RequestContext - 23, // 14: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 18, // 15: blobber.service.v1.GetFileStatsRequest.context:type_name -> blobber.service.v1.RequestContext - 23, // 16: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef - 13, // 17: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 18, // 18: blobber.service.v1.GetFileMetaDataRequest.context:type_name -> blobber.service.v1.RequestContext - 23, // 19: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef - 17, // 20: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 18, // 21: blobber.service.v1.GetAllocationRequest.context:type_name -> blobber.service.v1.RequestContext - 21, // 22: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 22, // 23: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 24, // 24: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 25, // 25: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 16, // 26: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 23, // 27: blobber.service.v1.DirMetaData.Children:type_name -> blobber.service.v1.FileRef - 19, // 28: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 14, // 29: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 11, // 30: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 9, // 31: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 5, // 32: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest - 2, // 33: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest - 0, // 34: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 20, // 35: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 15, // 36: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 12, // 37: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 10, // 38: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 6, // 39: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 3, // 40: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 1, // 41: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 35, // [35:42] is the sub-list for method output_type - 28, // [28:35] is the sub-list for method input_type - 28, // [28:28] is the sub-list for extension type_name - 28, // [28:28] is the sub-list for extension extendee - 0, // [0:28] is the sub-list for field type_name + 23, // 13: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 18, // 14: blobber.service.v1.ListEntitiesRequest.context:type_name -> blobber.service.v1.RequestContext + 23, // 15: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 23, // 16: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 18, // 17: blobber.service.v1.GetFileStatsRequest.context:type_name -> blobber.service.v1.RequestContext + 23, // 18: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 13, // 19: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats + 18, // 20: blobber.service.v1.GetFileMetaDataRequest.context:type_name -> blobber.service.v1.RequestContext + 23, // 21: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 17, // 22: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 18, // 23: blobber.service.v1.GetAllocationRequest.context:type_name -> blobber.service.v1.RequestContext + 21, // 24: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 22, // 25: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 24, // 26: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 25, // 27: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 16, // 28: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 19, // 29: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 14, // 30: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 11, // 31: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 9, // 32: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 5, // 33: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 2, // 34: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest + 0, // 35: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest + 20, // 36: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 15, // 37: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 12, // 38: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 10, // 39: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 6, // 40: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 3, // 41: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 1, // 42: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 36, // [36:43] is the sub-list for method output_type + 29, // [29:36] is the sub-list for method input_type + 29, // [29:29] is the sub-list for extension type_name + 29, // [29:29] is the sub-list for extension extendee + 0, // [0:29] is the sub-list for field type_name } func init() { file_blobber_proto_init() } diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 449b3d8c3..8c046c730 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -85,7 +85,8 @@ message ObjectPath { string RootHash = 1; FileRef Meta = 2; FileRef Path = 3; - int64 FileBlockNum = 4; + repeated FileRef PathList = 4; + int64 FileBlockNum = 5; } message WriteMarker { @@ -110,6 +111,7 @@ message ListEntitiesRequest { message ListEntitiesResponse { string AllocationRoot = 1; FileRef MetaData = 2; + repeated FileRef Entities = 3; } message GetFileStatsRequest { @@ -249,5 +251,4 @@ message DirMetaData { int64 Size = 8; int64 CreatedAt = 9; int64 UpdatedAt = 10; - repeated FileRef Children = 11; } \ No newline at end of file diff --git a/code/go/0chain.net/blobbercore/handler/convert.go b/code/go/0chain.net/blobbercore/handler/convert.go index 3445a4984..a7e6589a9 100644 --- a/code/go/0chain.net/blobbercore/handler/convert.go +++ b/code/go/0chain.net/blobbercore/handler/convert.go @@ -1,6 +1,7 @@ package handler import ( + "context" "time" "0chain.net/blobbercore/reference" @@ -110,6 +111,31 @@ func WriteMarkerToWriteMarkerGRPC(wm writemarker.WriteMarker) *blobbergrpc.Write } } +func WriteMarkerToWriteMarkerGRPC(wm writemarker.WriteMarker) *blobbergrpc.WriteMarker { + return &blobbergrpc.WriteMarker{ + AllocationRoot: wm.AllocationRoot, + PreviousAllocationRoot: wm.PreviousAllocationRoot, + AllocationID: wm.AllocationID, + Size: wm.Size, + BlobberID: wm.BlobberID, + Timestamp: int64(wm.Timestamp), + ClientID: wm.ClientID, + Signature: wm.Signature, + } +} +func WriteMarkerGRPCToWriteMarker(wm *blobbergrpc.WriteMarker) *writemarker.WriteMarker { + return &writemarker.WriteMarker{ + AllocationRoot: wm.AllocationRoot, + PreviousAllocationRoot: wm.PreviousAllocationRoot, + AllocationID: wm.AllocationID, + Size: wm.Size, + BlobberID: wm.BlobberID, + Timestamp: common.Timestamp(wm.Timestamp), + ClientID: wm.ClientID, + Signature: wm.Signature, + } +} + func FileStatsGRPCToFileStats(fileStats *blobbergrpc.FileStats) *stats.FileStats { if fileStats == nil { return &stats.FileStats{} @@ -146,3 +172,53 @@ func GRPCCollaboratorToCollaborator(c *blobbergrpc.Collaborator) reference.Colla CreatedAt: time.Unix(0, c.CreatedAt), } } + +func ReferencePathToReferencePathGRPC(recursionCount *int, refPath *ReferencePath) *blobbergrpc.ReferencePath { + // Accounting for bad reference paths where child path points to parent path and causes this algorithm to never end + *recursionCount += 1 + defer func() { + *recursionCount -= 1 + }() + + if *recursionCount > 150 { + return &blobbergrpc.ReferencePath{ + MetaData: reference.FileRefToFileRefGRPC(reference.ListingDataToRef(refPath.Meta)), + List: nil, + } + } + + var list []*blobbergrpc.ReferencePath + for i := range refPath.List { + list = append(list, ReferencePathToReferencePathGRPC(recursionCount, refPath.List[i])) + } + + return &blobbergrpc.ReferencePath{ + MetaData: reference.FileRefToFileRefGRPC(reference.ListingDataToRef(refPath.Meta)), + List: list, + } +} + +func ReferencePathGRPCToReferencePath(recursionCount *int, refPath *blobbergrpc.ReferencePath) *ReferencePath { + // Accounting for bad reference paths where child path points to parent path and causes this algorithm to never end + *recursionCount += 1 + defer func() { + *recursionCount -= 1 + }() + + if *recursionCount > 150 { + return &ReferencePath{ + Meta: reference.FileRefGRPCToFileRef(refPath.MetaData).GetListingData(context.Background()), + List: nil, + } + } + + var list []*ReferencePath + for i := range refPath.List { + list = append(list, ReferencePathGRPCToReferencePath(recursionCount, refPath.List[i])) + } + + return &ReferencePath{ + Meta: reference.FileRefGRPCToFileRef(refPath.MetaData).GetListingData(context.Background()), + List: list, + } +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 93cc438c7..abb4bb818 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -101,11 +101,7 @@ func (b *blobberGRPCService) GetFileMetaData(ctx context.Context, req *blobbergr var collaboratorsGRPC []*blobbergrpc.Collaborator for _, c := range collaborators { - collaboratorsGRPC = append(collaboratorsGRPC, &blobbergrpc.Collaborator{ - RefId: c.RefID, - ClientId: c.ClientID, - CreatedAt: c.CreatedAt.UnixNano(), - }) + collaboratorsGRPC = append(collaboratorsGRPC, CollaboratorToGRPCCollaborator(c)) } return &blobbergrpc.GetFileMetaDataResponse{ @@ -218,11 +214,11 @@ func (b *blobberGRPCService) ListEntities(ctx context.Context, req *blobbergrpc. entities = append(entities, reference.FileRefToFileRefGRPC(entity)) } refGRPC := reference.FileRefToFileRefGRPC(dirref) - refGRPC.DirMetaData.Children = entities return &blobbergrpc.ListEntitiesResponse{ AllocationRoot: allocationObj.AllocationRoot, MetaData: refGRPC, + Entities: entities, }, nil } @@ -254,7 +250,7 @@ func (b *blobberGRPCService) GetObjectPath(ctx context.Context, req *blobbergrpc return nil, common.NewError("invalid_parameters", "Invalid block number") } - objectPath, err := b.packageHandler.GetObjectPathGRPC(ctx, allocationID, blockNum) + objectPath, err := b.packageHandler.GetObjectPath(ctx, allocationID, blockNum) if err != nil { return nil, err } @@ -272,8 +268,23 @@ func (b *blobberGRPCService) GetObjectPath(ctx context.Context, req *blobbergrpc if latestWM != nil { latestWriteMarketGRPC = WriteMarkerToWriteMarkerGRPC(latestWM.WM) } + + pathList := make([]*blobbergrpc.FileRef, 0) + list, _ := objectPath.Path["list"].([]map[string]interface{}) + if len(list) > 0 { + for _, pl := range list { + pathList = append(pathList, reference.FileRefToFileRefGRPC(reference.ListingDataToRef(pl))) + } + } + return &blobbergrpc.GetObjectPathResponse{ - ObjectPath: objectPath, + ObjectPath: &blobbergrpc.ObjectPath{ + RootHash: objectPath.RootHash, + Meta: reference.FileRefToFileRefGRPC(reference.ListingDataToRef(objectPath.Meta)), + Path: reference.FileRefToFileRefGRPC(reference.ListingDataToRef(objectPath.Path)), + PathList: pathList, + FileBlockNum: objectPath.FileBlockNum, + }, LatestWriteMarker: latestWriteMarketGRPC, }, nil } @@ -313,16 +324,17 @@ func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobberg return nil, err } - refPath := &blobbergrpc.ReferencePath{MetaData: reference.FileRefToFileRefGRPC(rootRef)} - refsToProcess := make([]*blobbergrpc.ReferencePath, 0) + refPath := &ReferencePath{ref: rootRef} + refsToProcess := make([]*ReferencePath, 0) refsToProcess = append(refsToProcess, refPath) for len(refsToProcess) > 0 { refToProcess := refsToProcess[0] - if len(refToProcess.MetaData.DirMetaData.Children) > 0 { - refToProcess.List = make([]*blobbergrpc.ReferencePath, len(refToProcess.MetaData.DirMetaData.Children)) + refToProcess.Meta = refToProcess.ref.GetListingData(ctx) + if len(refToProcess.ref.Children) > 0 { + refToProcess.List = make([]*ReferencePath, len(refToProcess.ref.Children)) } - for idx, child := range refToProcess.MetaData.DirMetaData.Children { - childRefPath := &blobbergrpc.ReferencePath{MetaData: child} + for idx, child := range refToProcess.ref.Children { + childRefPath := &ReferencePath{ref: child} refToProcess.List[idx] = childRefPath refsToProcess = append(refsToProcess, childRefPath) } @@ -338,8 +350,10 @@ func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobberg return nil, common.NewError("latest_write_marker_read_error", "Error reading the latest write marker for allocation."+err.Error()) } } + var refPathResult blobbergrpc.GetReferencePathResponse - refPathResult.ReferencePath = refPath + var recursionCount int + refPathResult.ReferencePath = ReferencePathToReferencePathGRPC(&recursionCount, refPath) if latestWM != nil { refPathResult.LatestWM = WriteMarkerToWriteMarkerGRPC(latestWM.WM) } @@ -370,16 +384,17 @@ func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc return nil, err } - refPath := &blobbergrpc.ReferencePath{MetaData: reference.FileRefToFileRefGRPC(rootRef)} - refsToProcess := make([]*blobbergrpc.ReferencePath, 0) + refPath := &ReferencePath{ref: rootRef} + refsToProcess := make([]*ReferencePath, 0) refsToProcess = append(refsToProcess, refPath) for len(refsToProcess) > 0 { refToProcess := refsToProcess[0] - if len(refToProcess.MetaData.DirMetaData.Children) > 0 { - refToProcess.List = make([]*blobbergrpc.ReferencePath, len(refToProcess.MetaData.DirMetaData.Children)) + refToProcess.Meta = refToProcess.ref.GetListingData(ctx) + if len(refToProcess.ref.Children) > 0 { + refToProcess.List = make([]*ReferencePath, len(refToProcess.ref.Children)) } - for idx, child := range refToProcess.MetaData.DirMetaData.Children { - childRefPath := &blobbergrpc.ReferencePath{MetaData: child} + for idx, child := range refToProcess.ref.Children { + childRefPath := &ReferencePath{ref: child} refToProcess.List[idx] = childRefPath refsToProcess = append(refsToProcess, childRefPath) } @@ -396,7 +411,8 @@ func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc } } var refPathResult blobbergrpc.GetObjectTreeResponse - refPathResult.ReferencePath = refPath + var recursionCount int + refPathResult.ReferencePath = ReferencePathToReferencePathGRPC(&recursionCount, refPath) if latestWM != nil { refPathResult.LatestWM = WriteMarkerToWriteMarkerGRPC(latestWM.WM) } diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 0dad3ae08..9a9ceba8b 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -8,7 +8,6 @@ import ( "net/http" "os" "runtime/pprof" - "time" "0chain.net/blobbercore/reference" @@ -50,12 +49,12 @@ func SetupHandlers(r *mux.Router) { //object info related apis r.HandleFunc("/allocation", common.UserRateLimit(common.ToJSONResponse(WithConnection(AllocationHandler(svc))))).Methods("GET") - r.HandleFunc("/v1/file/meta/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileMetaHandler(svc))))).Methods("GET") - r.HandleFunc("/v1/file/stats/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileStatsHandler(svc))))).Methods("GET") - r.HandleFunc("/v1/file/list/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ListHandler)))) - r.HandleFunc("/v1/file/objectpath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectPathHandler)))) - r.HandleFunc("/v1/file/referencepath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ReferencePathHandler)))) - r.HandleFunc("/v1/file/objecttree/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectTreeHandler)))) + r.HandleFunc("/v1/file/meta/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileMetaHandler(svc))))).Methods("POST") + r.HandleFunc("/v1/file/stats/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileStatsHandler(svc))))).Methods("POST") + r.HandleFunc("/v1/file/list/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ListHandler(svc))))).Methods("GET") + r.HandleFunc("/v1/file/objectpath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectPathHandler(svc))))).Methods("GET") + r.HandleFunc("/v1/file/referencepath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ReferencePathHandler(svc))))).Methods("GET") + r.HandleFunc("/v1/file/objecttree/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectTreeHandler(svc))))).Methods("GET") //admin related r.HandleFunc("/_debug", common.UserRateLimit(common.ToJSONResponse(DumpGoRoutines))) @@ -236,15 +235,32 @@ func DownloadHandler(ctx context.Context, r *http.Request) (interface{}, error) } /*ListHandler is the handler to respond to upload requests fro clients*/ -func ListHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) +func ListHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + reqCtx := setupHandlerGRPCContext(r) - response, err := storageHandler.ListEntities(ctx, r) - if err != nil { - return nil, err - } + listEntitiesResponse, err := svc.ListEntities(ctx, &blobbergrpc.ListEntitiesRequest{ + Context: reqCtx, + Path: r.FormValue("path"), + PathHash: r.FormValue("path_hash"), + AuthToken: r.FormValue("auth_token"), + Allocation: reqCtx.Allocation, + }) + if err != nil { + return nil, err + } - return response, nil + var entities []map[string]interface{} + for i := range listEntitiesResponse.Entities { + entities = append(entities, reference.FileRefGRPCToFileRef(listEntitiesResponse.Entities[i]).GetListingData(ctx)) + } + + return &ListResult{ + AllocationRoot: listEntitiesResponse.AllocationRoot, + Meta: reference.FileRefGRPCToFileRef(listEntitiesResponse.MetaData).GetListingData(ctx), + Entities: entities, + }, nil + } } /*CommitHandler is the handler to respond to upload requests fro clients*/ @@ -259,40 +275,80 @@ func CommitHandler(ctx context.Context, r *http.Request) (interface{}, error) { return response, nil } -func ReferencePathHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx, canceler := context.WithTimeout(ctx, time.Second*10) - defer canceler() +func ReferencePathHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + reqCtx := setupHandlerGRPCContext(r) - ctx = setupHandlerContext(ctx, r) + getReferencePathResponse, err := svc.GetReferencePath(ctx, &blobbergrpc.GetReferencePathRequest{ + Context: reqCtx, + Paths: r.FormValue("paths"), + Path: r.FormValue("path"), + Allocation: reqCtx.Allocation, + }) + if err != nil { + return nil, err + } - response, err := storageHandler.GetReferencePath(ctx, r) - if err != nil { - return nil, err + var recursionCount int + return &ReferencePathResult{ + ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getReferencePathResponse.ReferencePath), + LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWM), + }, nil } - - return response, nil } -func ObjectPathHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) +func ObjectPathHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + reqCtx := setupHandlerGRPCContext(r) - response, err := storageHandler.GetObjectPath(ctx, r) - if err != nil { - return nil, err - } + getObjectPathResponse, err := svc.GetObjectPath(ctx, &blobbergrpc.GetObjectPathRequest{ + Context: reqCtx, + Allocation: reqCtx.Allocation, + Path: r.FormValue("path"), + BlockNum: r.FormValue("block_num"), + }) + if err != nil { + return nil, err + } - return response, nil + path := reference.FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Path).GetListingData(ctx) + var pathList []map[string]interface{} + for _, pl := range getObjectPathResponse.ObjectPath.PathList { + pathList = append(pathList, reference.FileRefGRPCToFileRef(pl).GetListingData(ctx)) + } + path["list"] = pathList + + return &ObjectPathResult{ + ObjectPath: &reference.ObjectPath{ + RootHash: getObjectPathResponse.ObjectPath.RootHash, + Meta: reference.FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Meta).GetListingData(ctx), + Path: path, + FileBlockNum: getObjectPathResponse.ObjectPath.FileBlockNum, + }, + LatestWM: WriteMarkerGRPCToWriteMarker(getObjectPathResponse.LatestWriteMarker), + }, nil + } } -func ObjectTreeHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) +func ObjectTreeHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + reqCtx := setupHandlerGRPCContext(r) - response, err := storageHandler.GetObjectTree(ctx, r) - if err != nil { - return nil, err - } + getObjectTreeResponse, err := svc.GetObjectTree(ctx, &blobbergrpc.GetObjectTreeRequest{ + Context: reqCtx, + Path: r.FormValue("path"), + Allocation: reqCtx.Allocation, + }) + if err != nil { + return nil, err + } - return response, nil + var recursionCount int + return &ReferencePathResult{ + ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getObjectTreeResponse.ReferencePath), + LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), + }, nil + } } func RenameHandler(ctx context.Context, r *http.Request) (interface{}, error) { diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index b412aa718..6f0df6d84 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -48,7 +48,7 @@ type PackageHandler interface { GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) GetWriteMarkerEntity(ctx context.Context, allocation_root string) (*writemarker.WriteMarkerEntity, error) GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) - GetObjectPathGRPC(ctx context.Context, allocationID string, blockNum int64) (*blobbergrpc.ObjectPath, error) + GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) } @@ -67,8 +67,8 @@ func (r *packageHandler) GetRefWithChildren(ctx context.Context, allocationID st return reference.GetRefWithChildren(ctx, allocationID, path) } -func (r *packageHandler) GetObjectPathGRPC(ctx context.Context, allocationID string, blockNum int64) (*blobbergrpc.ObjectPath, error) { - return reference.GetObjectPathGRPC(ctx, allocationID, blockNum) +func (r *packageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { + return reference.GetObjectPath(ctx, allocationID, blockNum) } func (r *packageHandler) GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) { diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 327425609..3d29fe07e 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -595,12 +595,6 @@ "UpdatedAt": { "type": "string", "format": "int64" - }, - "Children": { - "type": "array", - "items": { - "$ref": "#/definitions/v1FileRef" - } } } }, @@ -823,6 +817,12 @@ }, "MetaData": { "$ref": "#/definitions/v1FileRef" + }, + "Entities": { + "type": "array", + "items": { + "$ref": "#/definitions/v1FileRef" + } } } }, @@ -838,6 +838,12 @@ "Path": { "$ref": "#/definitions/v1FileRef" }, + "PathList": { + "type": "array", + "items": { + "$ref": "#/definitions/v1FileRef" + } + }, "FileBlockNum": { "type": "string", "format": "int64" diff --git a/code/go/0chain.net/blobbercore/reference/objectpath.go b/code/go/0chain.net/blobbercore/reference/objectpath.go index bdca0e7e0..1069d5a88 100644 --- a/code/go/0chain.net/blobbercore/reference/objectpath.go +++ b/code/go/0chain.net/blobbercore/reference/objectpath.go @@ -91,83 +91,6 @@ func GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*O return &retObj, nil } -// TODO needs to be refactored, current implementation can probably be heavily simplified -func GetObjectPathGRPC(ctx context.Context, allocationID string, blockNum int64) (*blobbergrpc.ObjectPath, error) { - - rootRef, err := GetRefWithSortedChildren(ctx, allocationID, "/") - if err != nil { - return nil, common.NewError("invalid_dir_struct", "Allocation root corresponds to an invalid directory structure") - } - - if rootRef.NumBlocks < blockNum { - return nil, common.NewError("invalid_block_num", fmt.Sprintf("Invalid block number %d/%d", rootRef.NumBlocks, blockNum)) - } - - if rootRef.NumBlocks == 0 { - children := make([]*blobbergrpc.FileRef, len(rootRef.Children)) - for idx, child := range rootRef.Children { - children[idx] = FileRefToFileRefGRPC(child) - } - path := FileRefToFileRefGRPC(rootRef) - path.DirMetaData.Children = children - return &blobbergrpc.ObjectPath{ - RootHash: rootRef.Hash, - Path: path, - FileBlockNum: 0, - }, nil - } - - found := false - var curRef *Ref - curRef = rootRef - remainingBlocks := blockNum - - result := curRef.GetListingData(ctx) - curResult := result - - for !found { - list := make([]map[string]interface{}, len(curRef.Children)) - for idx, child := range curRef.Children { - list[idx] = child.GetListingData(ctx) - } - curResult["list"] = list - for idx, child := range curRef.Children { - - if child.NumBlocks < remainingBlocks { - remainingBlocks = remainingBlocks - child.NumBlocks - continue - } - if child.Type == FILE { - found = true - curRef = child - break - } - curRef, err = GetRefWithSortedChildren(ctx, allocationID, child.Path) - if err != nil || len(curRef.Hash) == 0 { - return nil, common.NewError("failed_object_path", "Failed to get the object path") - } - curResult = list[idx] - break - } - } - if !found { - return nil, common.NewError("invalid_parameters", "Block num was not found") - } - - var children []*blobbergrpc.FileRef - for _, child := range rootRef.Children { - children = append(children, FileRefToFileRefGRPC(child)) - } - path := FileRefToFileRefGRPC(rootRef) - path.DirMetaData.Children = children - return &blobbergrpc.ObjectPath{ - RootHash: rootRef.Hash, - Meta: FileRefToFileRefGRPC(curRef), - Path: path, - FileBlockNum: remainingBlocks, - }, nil -} - func FileRefToFileRefGRPC(ref *Ref) *blobbergrpc.FileRef { var fileMetaData *blobbergrpc.FileMetaData diff --git a/code/go/0chain.net/blobbercore/reference/ref.go b/code/go/0chain.net/blobbercore/reference/ref.go index f422f501f..36babbc30 100644 --- a/code/go/0chain.net/blobbercore/reference/ref.go +++ b/code/go/0chain.net/blobbercore/reference/ref.go @@ -348,6 +348,10 @@ func (r *Ref) GetListingData(ctx context.Context) map[string]interface{} { return GetListingFieldsMap(*r, DIR_LIST_TAG) } +func ListingDataToRef(map[string]interface{}) *Ref { + return nil +} + func GetListingFieldsMap(refEntity interface{}, tagName string) map[string]interface{} { result := make(map[string]interface{}) t := reflect.TypeOf(refEntity) From cf11e5c2c4b715f3507003316a70d9986ffaafd3 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 16 May 2021 15:53:47 +0530 Subject: [PATCH 022/183] :sparkles: updated grpc handlers to handle client signatures --- .../blobbercore/blobbergrpc/blobber.pb.go | 421 +++++++++--------- .../blobbergrpc/proto/blobber.proto | 1 + .../0chain.net/blobbercore/handler/convert.go | 12 - .../blobbercore/handler/grpc_handler.go | 20 + .../0chain.net/blobbercore/handler/handler.go | 7 +- .../blobbercore/handler/storage_handler.go | 27 +- .../blobbercore/openapi/blobber.swagger.json | 45 ++ 7 files changed, 298 insertions(+), 235 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 0d91b561a..6f79d9b50 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1280,9 +1280,10 @@ type RequestContext struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Client string `protobuf:"bytes,1,opt,name=client,proto3" json:"client,omitempty"` - ClientKey string `protobuf:"bytes,2,opt,name=client_key,json=clientKey,proto3" json:"client_key,omitempty"` - Allocation string `protobuf:"bytes,3,opt,name=allocation,proto3" json:"allocation,omitempty"` + Client string `protobuf:"bytes,1,opt,name=client,proto3" json:"client,omitempty"` + ClientKey string `protobuf:"bytes,2,opt,name=client_key,json=clientKey,proto3" json:"client_key,omitempty"` + Allocation string `protobuf:"bytes,3,opt,name=allocation,proto3" json:"allocation,omitempty"` + ClientSignature string `protobuf:"bytes,4,opt,name=client_signature,json=clientSignature,proto3" json:"client_signature,omitempty"` } func (x *RequestContext) Reset() { @@ -1338,6 +1339,13 @@ func (x *RequestContext) GetAllocation() string { return "" } +func (x *RequestContext) GetClientSignature() string { + if x != nil { + return x.ClientSignature + } + return "" +} + type GetAllocationRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -2315,213 +2323,216 @@ var file_blobber_proto_rawDesc = []byte{ 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x67, 0x0a, 0x0e, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x16, - 0x0a, 0x06, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, - 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, - 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x6c, 0x69, 0x65, - 0x6e, 0x74, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x64, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, - 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, + 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x92, 0x01, 0x0a, + 0x0e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, + 0x16, 0x0a, 0x06, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x06, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x6c, 0x69, 0x65, 0x6e, + 0x74, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x6c, 0x69, + 0x65, 0x6e, 0x74, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x29, 0x0a, 0x10, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, + 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, + 0x65, 0x22, 0x64, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x63, 0x6f, 0x6e, + 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x52, 0x07, + 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, + 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, + 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, + 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, + 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, + 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, + 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, + 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, + 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, + 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, + 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, + 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, + 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, + 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, + 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, + 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, + 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, + 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, + 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, + 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, + 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, + 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, - 0x78, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, - 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, - 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, - 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, - 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, - 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, - 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, - 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, - 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, - 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, - 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, - 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, - 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, - 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, - 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, - 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, - 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, - 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, - 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, - 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, - 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, - 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, - 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, - 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, - 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, - 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, - 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, - 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, - 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, - 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, - 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, - 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, - 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, - 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, - 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, - 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, - 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, - 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, - 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, - 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, - 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, - 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, - 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, - 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, - 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, - 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, - 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, - 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, - 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, - 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, - 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, - 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, - 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, - 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, 0x07, - 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, - 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, + 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, + 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, + 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, + 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, + 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, + 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, + 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, + 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, + 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, + 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, + 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, + 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, + 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, + 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, + 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, + 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, + 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, + 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, + 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, + 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, + 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, + 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, + 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, + 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, + 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, + 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, + 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, + 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, + 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, + 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, + 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, + 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, + 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, + 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, + 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, + 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, + 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, + 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, + 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, + 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, + 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, + 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, - 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, - 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, - 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, - 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, - 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, - 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, - 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, + 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, + 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, + 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, + 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, + 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, + 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, + 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, - 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, + 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, - 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, - 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x0f, 0x5a, 0x0d, 0x2e, 0x2f, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, + 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x7d, 0x42, 0x0f, 0x5a, 0x0d, 0x2e, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, + 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 8c046c730..6ffac5c11 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -168,6 +168,7 @@ message RequestContext { string client = 1; string client_key = 2; string allocation = 3; + string client_signature = 4; } message GetAllocationRequest { diff --git a/code/go/0chain.net/blobbercore/handler/convert.go b/code/go/0chain.net/blobbercore/handler/convert.go index a7e6589a9..1d61525b6 100644 --- a/code/go/0chain.net/blobbercore/handler/convert.go +++ b/code/go/0chain.net/blobbercore/handler/convert.go @@ -111,18 +111,6 @@ func WriteMarkerToWriteMarkerGRPC(wm writemarker.WriteMarker) *blobbergrpc.Write } } -func WriteMarkerToWriteMarkerGRPC(wm writemarker.WriteMarker) *blobbergrpc.WriteMarker { - return &blobbergrpc.WriteMarker{ - AllocationRoot: wm.AllocationRoot, - PreviousAllocationRoot: wm.PreviousAllocationRoot, - AllocationID: wm.AllocationID, - Size: wm.Size, - BlobberID: wm.BlobberID, - Timestamp: int64(wm.Timestamp), - ClientID: wm.ClientID, - Signature: wm.Signature, - } -} func WriteMarkerGRPCToWriteMarker(wm *blobbergrpc.WriteMarker) *writemarker.WriteMarker { return &writemarker.WriteMarker{ AllocationRoot: wm.AllocationRoot, diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index abb4bb818..66465e97f 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -119,6 +119,11 @@ func (b *blobberGRPCService) GetFileStats(ctx context.Context, req *blobbergrpc. } allocationID := allocationObj.ID + valid, err := verifySignatureFromRequest(allocationTx, req.Context.ClientSignature, allocationObj.OwnerPublicKey) + if !valid || err != nil { + return nil, common.NewError("invalid_signature", "Invalid signature") + } + clientID := req.Context.Client if len(clientID) == 0 || allocationObj.OwnerID != clientID { return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") @@ -231,6 +236,11 @@ func (b *blobberGRPCService) GetObjectPath(ctx context.Context, req *blobbergrpc } allocationID := allocationObj.ID + valid, err := verifySignatureFromRequest(allocationTx, req.Context.ClientSignature, allocationObj.OwnerPublicKey) + if !valid || err != nil { + return nil, common.NewError("invalid_signature", "Invalid signature") + } + clientID := req.Context.Client if len(clientID) == 0 || allocationObj.OwnerID != clientID { return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") @@ -299,6 +309,11 @@ func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobberg } allocationID := allocationObj.ID + valid, err := verifySignatureFromRequest(allocationTx, req.Context.ClientSignature, allocationObj.OwnerPublicKey) + if !valid || err != nil { + return nil, common.NewError("invalid_signature", "Invalid signature") + } + clientID := req.Context.Client if len(clientID) == 0 { return nil, common.NewError("invalid_operation", "Please pass clientID in the header") @@ -370,6 +385,11 @@ func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc } allocationID := allocationObj.ID + valid, err := verifySignatureFromRequest(allocationTx, req.Context.ClientSignature, allocationObj.OwnerPublicKey) + if !valid || err != nil { + return nil, common.NewError("invalid_signature", "Invalid signature") + } + clientID := req.Context.Client if len(clientID) == 0 || allocationObj.OwnerID != clientID { return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 9a9ceba8b..6dc0bd1cf 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -122,9 +122,10 @@ func setupHandlerContext(ctx context.Context, r *http.Request) context.Context { func setupHandlerGRPCContext(r *http.Request) *blobbergrpc.RequestContext { var vars = mux.Vars(r) return &blobbergrpc.RequestContext{ - Client: r.Header.Get(common.ClientHeader), - ClientKey: r.Header.Get(common.ClientKeyHeader), - Allocation: vars["allocation"], + Client: r.Header.Get(common.ClientHeader), + ClientKey: r.Header.Get(common.ClientKeyHeader), + Allocation: vars["allocation"], + ClientSignature: r.Header.Get(common.ClientSignatureHeader), } } diff --git a/code/go/0chain.net/blobbercore/handler/storage_handler.go b/code/go/0chain.net/blobbercore/handler/storage_handler.go index 92b924484..d6e94052f 100644 --- a/code/go/0chain.net/blobbercore/handler/storage_handler.go +++ b/code/go/0chain.net/blobbercore/handler/storage_handler.go @@ -8,7 +8,6 @@ import ( "strings" "0chain.net/core/encryption" - "github.com/gorilla/mux" "0chain.net/blobbercore/stats" "go.uber.org/zap" @@ -257,7 +256,8 @@ func (fsh *StorageHandler) AddCollaborator(ctx context.Context, r *http.Request) return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) } - valid, err := verifySignatureFromRequest(r, allocationObj.OwnerPublicKey) + clientSign, _ := ctx.Value(constants.CLIENT_SIGNATURE_HEADER_KEY).(string) + valid, err := verifySignatureFromRequest(allocationTx, clientSign, allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } @@ -343,7 +343,8 @@ func (fsh *StorageHandler) GetFileStats(ctx context.Context, r *http.Request) (i } allocationID := allocationObj.ID - valid, err := verifySignatureFromRequest(r, allocationObj.OwnerPublicKey) + clientSign, _ := ctx.Value(constants.CLIENT_SIGNATURE_HEADER_KEY).(string) + valid, err := verifySignatureFromRequest(allocationTx, clientSign, allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } @@ -480,7 +481,8 @@ func (fsh *StorageHandler) getReferencePath(ctx context.Context, r *http.Request } allocationID := allocationObj.ID - valid, err := verifySignatureFromRequest(r, allocationObj.OwnerPublicKey) + clientSign, _ := ctx.Value(constants.CLIENT_SIGNATURE_HEADER_KEY).(string) + valid, err := verifySignatureFromRequest(allocationTx, clientSign, allocationObj.OwnerPublicKey) if !valid || err != nil { errCh <- common.NewError("invalid_signature", "Invalid signature") return @@ -551,7 +553,8 @@ func (fsh *StorageHandler) GetObjectPath(ctx context.Context, r *http.Request) ( } allocationID := allocationObj.ID - valid, err := verifySignatureFromRequest(r, allocationObj.OwnerPublicKey) + clientSign, _ := ctx.Value(constants.CLIENT_SIGNATURE_HEADER_KEY).(string) + valid, err := verifySignatureFromRequest(allocationTx, clientSign, allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } @@ -609,7 +612,8 @@ func (fsh *StorageHandler) GetObjectTree(ctx context.Context, r *http.Request) ( } allocationID := allocationObj.ID - valid, err := verifySignatureFromRequest(r, allocationObj.OwnerPublicKey) + clientSign, _ := ctx.Value(constants.CLIENT_SIGNATURE_HEADER_KEY).(string) + valid, err := verifySignatureFromRequest(allocationTx, clientSign, allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } @@ -699,19 +703,12 @@ func (fsh *StorageHandler) CalculateHash(ctx context.Context, r *http.Request) ( } // verifySignatureFromRequest verifyes signature passed as common.ClientSignatureHeader header. -func verifySignatureFromRequest(r *http.Request, pbK string) (bool, error) { - sign := r.Header.Get(common.ClientSignatureHeader) +func verifySignatureFromRequest(allocation, sign, pbK string) (bool, error) { if len(sign) < 64 { return false, nil } - vars := mux.Vars(r) - data, ok := vars["allocation"] - if !ok { - return false, common.NewError("invalid_params", "Missing allocation tx") - } - - hash := encryption.Hash(data) + hash := encryption.Hash(allocation) return encryption.Verify(pbK, sign, hash) } diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 3d29fe07e..138688c45 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -52,6 +52,12 @@ "required": false, "type": "string" }, + { + "name": "context.clientSignature", + "in": "query", + "required": false, + "type": "string" + }, { "name": "id", "in": "query", @@ -106,6 +112,12 @@ "required": false, "type": "string" }, + { + "name": "context.clientSignature", + "in": "query", + "required": false, + "type": "string" + }, { "name": "path", "in": "query", @@ -172,6 +184,12 @@ "required": false, "type": "string" }, + { + "name": "context.clientSignature", + "in": "query", + "required": false, + "type": "string" + }, { "name": "path", "in": "query", @@ -238,6 +256,12 @@ "required": false, "type": "string" }, + { + "name": "context.clientSignature", + "in": "query", + "required": false, + "type": "string" + }, { "name": "Path", "in": "query", @@ -298,6 +322,12 @@ "required": false, "type": "string" }, + { + "name": "context.clientSignature", + "in": "query", + "required": false, + "type": "string" + }, { "name": "path", "in": "query", @@ -352,6 +382,12 @@ "required": false, "type": "string" }, + { + "name": "Context.clientSignature", + "in": "query", + "required": false, + "type": "string" + }, { "name": "Paths", "in": "query", @@ -412,6 +448,12 @@ "required": false, "type": "string" }, + { + "name": "context.clientSignature", + "in": "query", + "required": false, + "type": "string" + }, { "name": "path", "in": "query", @@ -875,6 +917,9 @@ }, "allocation": { "type": "string" + }, + "clientSignature": { + "type": "string" } } }, From 4867ea26eac51515e0d1a54f982dd446a207bc09 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 16 May 2021 18:06:04 +0530 Subject: [PATCH 023/183] :green_heart: attempting to fix tests --- .../handler/grpc_handler_helper_unit_test.go | 21 +++ .../handler/grpc_handler_unit_test.go | 134 ++++++++++++------ .../blobbercore/handler/handler_test.go | 32 +++-- .../handler/object_operation_handler.go | 8 +- .../blobbercore/mocks/PackageHandler.go | 12 +- .../blobbercore/reference/objectpath.go | 7 + 6 files changed, 146 insertions(+), 68 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 66345b7ab..9804218be 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -2,6 +2,11 @@ package handler import ( "context" + "testing" + + "0chain.net/blobbercore/config" + coreConfig "0chain.net/core/config" + "github.com/0chain/gosdk/core/zcncrypto" "0chain.net/blobbercore/allocation" "0chain.net/blobbercore/reference" @@ -56,3 +61,19 @@ func (_m *storageHandlerI) verifyAuthTicket(ctx context.Context, authTokenString return r0, r1 } + +func GeneratePubPrivateKey(t *testing.T) (string, string, zcncrypto.SignatureScheme) { + + config.Configuration.Config = &coreConfig.Config{SignatureScheme: "bls0chain"} + signScheme := zcncrypto.NewSignatureScheme(config.Configuration.SignatureScheme) + wallet, err := signScheme.GenerateKeys() + if err != nil { + t.Fatal(err) + } + keyPair := wallet.Keys[0] + + signScheme.SetPrivateKey(keyPair.PrivateKey) + signScheme.SetPublicKey(keyPair.PublicKey) + + return keyPair.PublicKey, keyPair.PrivateKey, signScheme +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index 79d576b97..f2bc457ae 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -3,8 +3,12 @@ package handler import ( "context" "errors" + "math/rand" + "strings" "testing" + "0chain.net/core/encryption" + "0chain.net/blobbercore/stats" "0chain.net/blobbercore/reference" @@ -62,17 +66,17 @@ func TestBlobberGRPCService_GetFileMetaData_Success(t *testing.T) { Context: &blobbergrpc.RequestContext{ Client: "client", ClientKey: "", - Allocation: "", + Allocation: "something", }, Path: "path", PathHash: "path_hash", AuthToken: "testval", - Allocation: "something", + Allocation: "", } mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, true).Return(&allocation.Allocation{ ID: "allocationId", Tx: req.Allocation, }, nil) @@ -104,17 +108,17 @@ func TestBlobberGRPCService_GetFileMetaData_FileNotExist(t *testing.T) { Context: &blobbergrpc.RequestContext{ Client: "client", ClientKey: "", - Allocation: "", + Allocation: "something", }, Path: "path", PathHash: "path_hash", AuthToken: "testval", - Allocation: "something", + Allocation: "", } mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, true).Return(&allocation.Allocation{ ID: "allocationId", Tx: req.Allocation, }, nil) @@ -136,12 +140,29 @@ func TestBlobberGRPCService_GetFileMetaData_FileNotExist(t *testing.T) { } } +func randString(n int) string { + + const hexLetters = "abcdef0123456789" + + var sb strings.Builder + for i := 0; i < n; i++ { + sb.WriteByte(hexLetters[rand.Intn(len(hexLetters))]) + } + return sb.String() +} + func TestBlobberGRPCService_GetFileStats_Success(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + req := &blobbergrpc.GetFileStatsRequest{ Context: &blobbergrpc.RequestContext{ - Client: "owner", - ClientKey: "", - Allocation: "", + Client: "owner", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, }, Path: "path", PathHash: "path_hash", @@ -150,10 +171,11 @@ func TestBlobberGRPCService_GetFileStats_Success(t *testing.T) { mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, true).Return(&allocation.Allocation{ + ID: "allocationId", + Tx: req.Context.Allocation, + OwnerID: "owner", + OwnerPublicKey: pubKey, }, nil) mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ ID: 123, @@ -285,11 +307,17 @@ func TestBlobberGRPCService_ListEntities_InvalidAuthTicket(t *testing.T) { } func TestBlobberGRPCService_GetObjectPath_Success(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + req := &blobbergrpc.GetObjectPathRequest{ Context: &blobbergrpc.RequestContext{ - Client: "owner", - ClientKey: "", - Allocation: "", + Client: "owner", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, }, Allocation: "", Path: "path", @@ -298,12 +326,13 @@ func TestBlobberGRPCService_GetObjectPath_Success(t *testing.T) { mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, false).Return(&allocation.Allocation{ + ID: "allocationId", + Tx: req.Context.Allocation, + OwnerID: "owner", + OwnerPublicKey: pubKey, }, nil) - mockReferencePackage.On("GetObjectPathGRPC", mock.Anything, mock.Anything, mock.Anything).Return(&blobbergrpc.ObjectPath{ + mockReferencePackage.On("GetObjectPath", mock.Anything, mock.Anything, mock.Anything).Return(&reference.ObjectPath{ RootHash: "hash", FileBlockNum: 120, }, nil) @@ -347,11 +376,17 @@ func TestBlobberGRPCService_GetObjectPath_InvalidAllocation(t *testing.T) { } func TestBlobberGRPCService_GetReferencePath_Success(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + req := &blobbergrpc.GetReferencePathRequest{ Context: &blobbergrpc.RequestContext{ - Client: "client", - ClientKey: "", - Allocation: "", + Client: "client", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, }, Paths: `["something"]`, Path: "", @@ -360,10 +395,11 @@ func TestBlobberGRPCService_GetReferencePath_Success(t *testing.T) { mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, false).Return(&allocation.Allocation{ + ID: "allocationId", + Tx: req.Context.Allocation, + OwnerID: "owner", + OwnerPublicKey: pubKey, }, nil) mockReferencePackage.On("GetReferencePathFromPaths", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ Name: "test", @@ -382,11 +418,17 @@ func TestBlobberGRPCService_GetReferencePath_Success(t *testing.T) { } func TestBlobberGRPCService_GetReferencePath_InvalidPaths(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + req := &blobbergrpc.GetReferencePathRequest{ Context: &blobbergrpc.RequestContext{ - Client: "client", - ClientKey: "", - Allocation: "", + Client: "client", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, }, Paths: `["something"]`, Path: "", @@ -395,10 +437,11 @@ func TestBlobberGRPCService_GetReferencePath_InvalidPaths(t *testing.T) { mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, false).Return(&allocation.Allocation{ + ID: "allocationId", + Tx: req.Context.Allocation, + OwnerID: "owner", + OwnerPublicKey: pubKey, }, nil) mockReferencePackage.On("GetReferencePathFromPaths", mock.Anything, mock.Anything, mock.Anything).Return(nil, errors.New("invalid paths")) @@ -413,11 +456,17 @@ func TestBlobberGRPCService_GetReferencePath_InvalidPaths(t *testing.T) { } func TestBlobberGRPCService_GetObjectTree_Success(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + req := &blobbergrpc.GetObjectTreeRequest{ Context: &blobbergrpc.RequestContext{ - Client: "owner", - ClientKey: "", - Allocation: "", + Client: "owner", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, }, Path: "something", Allocation: "", @@ -425,10 +474,11 @@ func TestBlobberGRPCService_GetObjectTree_Success(t *testing.T) { mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, false).Return(&allocation.Allocation{ + ID: "allocationId", + Tx: req.Context.Allocation, + OwnerID: "owner", + OwnerPublicKey: pubKey, }, nil) mockReferencePackage.On("GetObjectTree", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ Name: "test", diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go index 0f613734d..def888b16 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/handler_test.go @@ -1,6 +1,18 @@ package handler import ( + "bytes" + "encoding/json" + "errors" + "io" + "mime/multipart" + "net/http" + "net/http/httptest" + "os" + "regexp" + "testing" + "time" + "0chain.net/blobbercore/allocation" bconfig "0chain.net/blobbercore/config" "0chain.net/blobbercore/datastore" @@ -11,9 +23,6 @@ import ( "0chain.net/core/config" "0chain.net/core/encryption" "0chain.net/core/logging" - "bytes" - "encoding/json" - "errors" "github.com/0chain/gosdk/core/zcncrypto" "github.com/0chain/gosdk/zcncore" "github.com/DATA-DOG/go-sqlmock" @@ -21,14 +30,6 @@ import ( "github.com/stretchr/testify/assert" "go.uber.org/zap" "gorm.io/gorm" - "io" - "mime/multipart" - "net/http" - "net/http/httptest" - "os" - "regexp" - "testing" - "time" ) func init() { @@ -88,12 +89,13 @@ func setup(t *testing.T) { func setupHandlers() (*mux.Router, map[string]string) { router := mux.NewRouter() + svc := newGRPCBlobberService(&storageHandler, &packageHandler{}) opPath := "/v1/file/objectpath/{allocation}" opName := "Object_Path" router.HandleFunc(opPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(ObjectPathHandler), + WithReadOnlyConnection(ObjectPathHandler(svc)), ), ), ).Name(opName) @@ -102,7 +104,7 @@ func setupHandlers() (*mux.Router, map[string]string) { rpName := "Reference_Path" router.HandleFunc(rpPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(ReferencePathHandler), + WithReadOnlyConnection(ReferencePathHandler(svc)), ), ), ).Name(rpName) @@ -111,7 +113,7 @@ func setupHandlers() (*mux.Router, map[string]string) { sName := "Stats" router.HandleFunc(sPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(FileStatsHandler), + WithReadOnlyConnection(FileStatsHandler(svc)), ), ), ).Name(sName) @@ -120,7 +122,7 @@ func setupHandlers() (*mux.Router, map[string]string) { otName := "Object_Tree" router.HandleFunc(otPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(ObjectTreeHandler), + WithReadOnlyConnection(ObjectTreeHandler(svc)), ), ), ).Name(otName) diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go index 59e6ddd26..21cd29b57 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go @@ -595,7 +595,7 @@ func (fsh *StorageHandler) RenameObject(ctx context.Context, r *http.Request) (i clientID := ctx.Value(constants.CLIENT_CONTEXT_KEY).(string) _ = ctx.Value(constants.CLIENT_KEY_CONTEXT_KEY).(string) - valid, err := verifySignatureFromRequest(r, allocationObj.OwnerPublicKey) + valid, err := verifySignatureFromRequest(allocationTx, r.Header.Get(common.ClientSignatureHeader), allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } @@ -683,7 +683,7 @@ func (fsh *StorageHandler) UpdateObjectAttributes(ctx context.Context, "Invalid allocation ID passed: %v", err) } - valid, err := verifySignatureFromRequest(r, alloc.OwnerPublicKey) + valid, err := verifySignatureFromRequest(allocTx, r.Header.Get(common.ClientSignatureHeader), alloc.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } @@ -779,7 +779,7 @@ func (fsh *StorageHandler) CopyObject(ctx context.Context, r *http.Request) (int return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) } - valid, err := verifySignatureFromRequest(r, allocationObj.OwnerPublicKey) + valid, err := verifySignatureFromRequest(allocationTx, r.Header.Get(common.ClientSignatureHeader), allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } @@ -911,7 +911,7 @@ func (fsh *StorageHandler) WriteFile(ctx context.Context, r *http.Request) (*Upl return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) } - valid, err := verifySignatureFromRequest(r, allocationObj.OwnerPublicKey) + valid, err := verifySignatureFromRequest(allocationTx, r.Header.Get(common.ClientSignatureHeader), allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 1d6dba917..9119d6ce1 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -5,8 +5,6 @@ package mocks import ( context "context" - blobbergrpc "0chain.net/blobbercore/blobbergrpc" - mock "github.com/stretchr/testify/mock" reference "0chain.net/blobbercore/reference" @@ -90,16 +88,16 @@ func (_m *PackageHandler) GetFileStats(ctx context.Context, refID int64) (*stats return r0, r1 } -// GetObjectPathGRPC provides a mock function with given fields: ctx, allocationID, blockNum -func (_m *PackageHandler) GetObjectPathGRPC(ctx context.Context, allocationID string, blockNum int64) (*blobbergrpc.ObjectPath, error) { +// GetObjectPath provides a mock function with given fields: ctx, allocationID, blockNum +func (_m *PackageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { ret := _m.Called(ctx, allocationID, blockNum) - var r0 *blobbergrpc.ObjectPath - if rf, ok := ret.Get(0).(func(context.Context, string, int64) *blobbergrpc.ObjectPath); ok { + var r0 *reference.ObjectPath + if rf, ok := ret.Get(0).(func(context.Context, string, int64) *reference.ObjectPath); ok { r0 = rf(ctx, allocationID, blockNum) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*blobbergrpc.ObjectPath) + r0 = ret.Get(0).(*reference.ObjectPath) } } diff --git a/code/go/0chain.net/blobbercore/reference/objectpath.go b/code/go/0chain.net/blobbercore/reference/objectpath.go index 1069d5a88..258d3f291 100644 --- a/code/go/0chain.net/blobbercore/reference/objectpath.go +++ b/code/go/0chain.net/blobbercore/reference/objectpath.go @@ -92,6 +92,9 @@ func GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*O } func FileRefToFileRefGRPC(ref *Ref) *blobbergrpc.FileRef { + if ref == nil { + return nil + } var fileMetaData *blobbergrpc.FileMetaData var dirMetaData *blobbergrpc.DirMetaData @@ -162,6 +165,10 @@ func convertDirRefToDirMetaDataGRPC(dirref *Ref) *blobbergrpc.DirMetaData { } func FileRefGRPCToFileRef(ref *blobbergrpc.FileRef) *Ref { + if ref == nil { + return nil + } + switch ref.Type { case FILE: return convertFileMetaDataGRPCToFileRef(ref.FileMetaData) From db33877dd549533a3eb880418b47d4d77deedc43 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 16 May 2021 22:55:47 +0530 Subject: [PATCH 024/183] :sparkles: implemented listingdatatoref function and fixed some tests --- .../0chain.net/blobbercore/handler/convert.go | 42 ++++++++++++++++--- .../blobbercore/handler/grpc_handler.go | 8 ++-- .../handler/grpc_handler_helper_unit_test.go | 4 +- .../0chain.net/blobbercore/handler/handler.go | 2 +- .../0chain.net/blobbercore/reference/ref.go | 38 ++++++++++++++++- 5 files changed, 79 insertions(+), 15 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/convert.go b/code/go/0chain.net/blobbercore/handler/convert.go index 1d61525b6..7a6abfa4d 100644 --- a/code/go/0chain.net/blobbercore/handler/convert.go +++ b/code/go/0chain.net/blobbercore/handler/convert.go @@ -16,6 +16,10 @@ import ( ) func AllocationToGRPCAllocation(alloc *allocation.Allocation) *blobbergrpc.Allocation { + if alloc == nil { + return nil + } + terms := make([]*blobbergrpc.Term, 0, len(alloc.Terms)) for _, t := range alloc.Terms { terms = append(terms, &blobbergrpc.Term{ @@ -48,6 +52,10 @@ func AllocationToGRPCAllocation(alloc *allocation.Allocation) *blobbergrpc.Alloc } func GRPCAllocationToAllocation(alloc *blobbergrpc.Allocation) *allocation.Allocation { + if alloc == nil { + return nil + } + terms := make([]*allocation.Terms, 0, len(alloc.Terms)) for _, t := range alloc.Terms { terms = append(terms, &allocation.Terms{ @@ -81,7 +89,7 @@ func GRPCAllocationToAllocation(alloc *blobbergrpc.Allocation) *allocation.Alloc func FileStatsToFileStatsGRPC(fileStats *stats.FileStats) *blobbergrpc.FileStats { if fileStats == nil { - return &blobbergrpc.FileStats{} + return nil } return &blobbergrpc.FileStats{ @@ -98,7 +106,11 @@ func FileStatsToFileStatsGRPC(fileStats *stats.FileStats) *blobbergrpc.FileStats } } -func WriteMarkerToWriteMarkerGRPC(wm writemarker.WriteMarker) *blobbergrpc.WriteMarker { +func WriteMarkerToWriteMarkerGRPC(wm *writemarker.WriteMarker) *blobbergrpc.WriteMarker { + if wm == nil { + return nil + } + return &blobbergrpc.WriteMarker{ AllocationRoot: wm.AllocationRoot, PreviousAllocationRoot: wm.PreviousAllocationRoot, @@ -112,6 +124,10 @@ func WriteMarkerToWriteMarkerGRPC(wm writemarker.WriteMarker) *blobbergrpc.Write } func WriteMarkerGRPCToWriteMarker(wm *blobbergrpc.WriteMarker) *writemarker.WriteMarker { + if wm == nil { + return nil + } + return &writemarker.WriteMarker{ AllocationRoot: wm.AllocationRoot, PreviousAllocationRoot: wm.PreviousAllocationRoot, @@ -126,7 +142,7 @@ func WriteMarkerGRPCToWriteMarker(wm *blobbergrpc.WriteMarker) *writemarker.Writ func FileStatsGRPCToFileStats(fileStats *blobbergrpc.FileStats) *stats.FileStats { if fileStats == nil { - return &stats.FileStats{} + return nil } return &stats.FileStats{ @@ -145,7 +161,11 @@ func FileStatsGRPCToFileStats(fileStats *blobbergrpc.FileStats) *stats.FileStats } } -func CollaboratorToGRPCCollaborator(c reference.Collaborator) *blobbergrpc.Collaborator { +func CollaboratorToGRPCCollaborator(c *reference.Collaborator) *blobbergrpc.Collaborator { + if c == nil { + return nil + } + return &blobbergrpc.Collaborator{ RefId: c.RefID, ClientId: c.ClientID, @@ -153,8 +173,12 @@ func CollaboratorToGRPCCollaborator(c reference.Collaborator) *blobbergrpc.Colla } } -func GRPCCollaboratorToCollaborator(c *blobbergrpc.Collaborator) reference.Collaborator { - return reference.Collaborator{ +func GRPCCollaboratorToCollaborator(c *blobbergrpc.Collaborator) *reference.Collaborator { + if c == nil { + return nil + } + + return &reference.Collaborator{ RefID: c.RefId, ClientID: c.ClientId, CreatedAt: time.Unix(0, c.CreatedAt), @@ -162,6 +186,9 @@ func GRPCCollaboratorToCollaborator(c *blobbergrpc.Collaborator) reference.Colla } func ReferencePathToReferencePathGRPC(recursionCount *int, refPath *ReferencePath) *blobbergrpc.ReferencePath { + if refPath == nil { + return nil + } // Accounting for bad reference paths where child path points to parent path and causes this algorithm to never end *recursionCount += 1 defer func() { @@ -187,6 +214,9 @@ func ReferencePathToReferencePathGRPC(recursionCount *int, refPath *ReferencePat } func ReferencePathGRPCToReferencePath(recursionCount *int, refPath *blobbergrpc.ReferencePath) *ReferencePath { + if refPath == nil { + return nil + } // Accounting for bad reference paths where child path points to parent path and causes this algorithm to never end *recursionCount += 1 defer func() { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 66465e97f..63d801716 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -101,7 +101,7 @@ func (b *blobberGRPCService) GetFileMetaData(ctx context.Context, req *blobbergr var collaboratorsGRPC []*blobbergrpc.Collaborator for _, c := range collaborators { - collaboratorsGRPC = append(collaboratorsGRPC, CollaboratorToGRPCCollaborator(c)) + collaboratorsGRPC = append(collaboratorsGRPC, CollaboratorToGRPCCollaborator(&c)) } return &blobbergrpc.GetFileMetaDataResponse{ @@ -276,7 +276,7 @@ func (b *blobberGRPCService) GetObjectPath(ctx context.Context, req *blobbergrpc } var latestWriteMarketGRPC *blobbergrpc.WriteMarker if latestWM != nil { - latestWriteMarketGRPC = WriteMarkerToWriteMarkerGRPC(latestWM.WM) + latestWriteMarketGRPC = WriteMarkerToWriteMarkerGRPC(&latestWM.WM) } pathList := make([]*blobbergrpc.FileRef, 0) @@ -370,7 +370,7 @@ func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobberg var recursionCount int refPathResult.ReferencePath = ReferencePathToReferencePathGRPC(&recursionCount, refPath) if latestWM != nil { - refPathResult.LatestWM = WriteMarkerToWriteMarkerGRPC(latestWM.WM) + refPathResult.LatestWM = WriteMarkerToWriteMarkerGRPC(&latestWM.WM) } return &refPathResult, nil @@ -434,7 +434,7 @@ func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc var recursionCount int refPathResult.ReferencePath = ReferencePathToReferencePathGRPC(&recursionCount, refPath) if latestWM != nil { - refPathResult.LatestWM = WriteMarkerToWriteMarkerGRPC(latestWM.WM) + refPathResult.LatestWM = WriteMarkerToWriteMarkerGRPC(&latestWM.WM) } return &refPathResult, nil } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 9804218be..8160b10d2 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -72,8 +72,8 @@ func GeneratePubPrivateKey(t *testing.T) (string, string, zcncrypto.SignatureSch } keyPair := wallet.Keys[0] - signScheme.SetPrivateKey(keyPair.PrivateKey) - signScheme.SetPublicKey(keyPair.PublicKey) + _ = signScheme.SetPrivateKey(keyPair.PrivateKey) + _ = signScheme.SetPublicKey(keyPair.PublicKey) return keyPair.PublicKey, keyPair.PrivateKey, signScheme } diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 6dc0bd1cf..902f0ca2d 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -162,7 +162,7 @@ func FileMetaHandler(svc *blobberGRPCService) func(ctx context.Context, r *http. var collaborators []reference.Collaborator for _, c := range getFileMetaDataResp.Collaborators { - collaborators = append(collaborators, GRPCCollaboratorToCollaborator(c)) + collaborators = append(collaborators, *GRPCCollaboratorToCollaborator(c)) } result := reference.FileRefGRPCToFileRef(getFileMetaDataResp.MetaData).GetListingData(ctx) diff --git a/code/go/0chain.net/blobbercore/reference/ref.go b/code/go/0chain.net/blobbercore/reference/ref.go index 36babbc30..686d63cbe 100644 --- a/code/go/0chain.net/blobbercore/reference/ref.go +++ b/code/go/0chain.net/blobbercore/reference/ref.go @@ -342,14 +342,48 @@ func (r *Ref) Save(ctx context.Context) error { } func (r *Ref) GetListingData(ctx context.Context) map[string]interface{} { + if r == nil { + return make(map[string]interface{}) + } + if r.Type == FILE { return GetListingFieldsMap(*r, FILE_LIST_TAG) } return GetListingFieldsMap(*r, DIR_LIST_TAG) } -func ListingDataToRef(map[string]interface{}) *Ref { - return nil +func ListingDataToRef(refMap map[string]interface{}) *Ref { + ref := &Ref{} + + refType, _ := refMap["type"].(string) + var tagName string + if refType == FILE { + tagName = FILE_LIST_TAG + } else { + tagName = DIR_LIST_TAG + } + + t := reflect.TypeOf(ref).Elem() + v := reflect.ValueOf(ref).Elem() + + // Iterate over all available fields and read the tag value + for i := 0; i < t.NumField(); i++ { + field := t.Field(i) + + // Get the field tag value + tag := field.Tag.Get(tagName) + // Skip if tag is not defined or ignored + if tag == "" || tag == "-" { + continue + } + + val := refMap[tag] + if val != nil { + v.FieldByName(field.Name).Set(reflect.ValueOf(val)) + } + } + + return ref } func GetListingFieldsMap(refEntity interface{}, tagName string) map[string]interface{} { From 149118e3e88aa9f38bfb80390644c46653810e9f Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 17 May 2021 18:59:14 +0530 Subject: [PATCH 025/183] :sparkles: make sure conversion functions can handle nil and other edgecase values --- code/go/0chain.net/blobbercore/reference/ref.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/code/go/0chain.net/blobbercore/reference/ref.go b/code/go/0chain.net/blobbercore/reference/ref.go index 686d63cbe..d3e5a37de 100644 --- a/code/go/0chain.net/blobbercore/reference/ref.go +++ b/code/go/0chain.net/blobbercore/reference/ref.go @@ -353,6 +353,10 @@ func (r *Ref) GetListingData(ctx context.Context) map[string]interface{} { } func ListingDataToRef(refMap map[string]interface{}) *Ref { + if len(refMap) < 1 { + return nil + } + ref := &Ref{} refType, _ := refMap["type"].(string) From 8fe2a19760f4a9dc70c8c1024f0109577f90702f Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 17 May 2021 19:39:34 +0530 Subject: [PATCH 026/183] :added: grpc response handler functions --- .../0chain.net/blobbercore/handler/handler.go | 139 +++++++++++------- 1 file changed, 85 insertions(+), 54 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 902f0ca2d..c1f1db413 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -9,6 +9,8 @@ import ( "os" "runtime/pprof" + "0chain.net/blobbercore/allocation" + "0chain.net/blobbercore/reference" "0chain.net/blobbercore/blobbergrpc" @@ -141,10 +143,14 @@ func AllocationHandler(svc *blobberGRPCService) func(ctx context.Context, r *htt return nil, err } - return GRPCAllocationToAllocation(getAllocationResp.Allocation), nil + return GetAllocationResponseHandler(getAllocationResp), nil } } +func GetAllocationResponseHandler(resp *blobbergrpc.GetAllocationResponse) *allocation.Allocation { + return GRPCAllocationToAllocation(resp.Allocation) +} + func FileMetaHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { return func(ctx context.Context, r *http.Request) (interface{}, error) { reqCtx := setupHandlerGRPCContext(r) @@ -160,16 +166,19 @@ func FileMetaHandler(svc *blobberGRPCService) func(ctx context.Context, r *http. return nil, err } - var collaborators []reference.Collaborator - for _, c := range getFileMetaDataResp.Collaborators { - collaborators = append(collaborators, *GRPCCollaboratorToCollaborator(c)) - } - - result := reference.FileRefGRPCToFileRef(getFileMetaDataResp.MetaData).GetListingData(ctx) - result["collaborators"] = collaborators + return GetFileMetaDataResponseHandler(getFileMetaDataResp), nil + } +} - return result, nil +func GetFileMetaDataResponseHandler(resp *blobbergrpc.GetFileMetaDataResponse) map[string]interface{} { + var collaborators []reference.Collaborator + for _, c := range resp.Collaborators { + collaborators = append(collaborators, *GRPCCollaboratorToCollaborator(c)) } + + result := reference.FileRefGRPCToFileRef(resp.MetaData).GetListingData(context.Background()) + result["collaborators"] = collaborators + return result } func CommitMetaTxnHandler(ctx context.Context, r *http.Request) (interface{}, error) { @@ -208,19 +217,23 @@ func FileStatsHandler(svc *blobberGRPCService) func(ctx context.Context, r *http return nil, err } - result := reference.FileRefGRPCToFileRef(getFileStatsResponse.MetaData).GetListingData(ctx) + return GetFileStatsResponseHandler(getFileStatsResponse), nil + } +} - statsMap := make(map[string]interface{}) - statsBytes, _ := json.Marshal(FileStatsGRPCToFileStats(getFileStatsResponse.Stats)) - if err = json.Unmarshal(statsBytes, &statsMap); err != nil { - return nil, err - } - for k, v := range statsMap { - result[k] = v - } +func GetFileStatsResponseHandler(resp *blobbergrpc.GetFileStatsResponse) map[string]interface{} { + ctx := context.Background() + result := reference.FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx) + + statsMap := make(map[string]interface{}) + statsBytes, _ := json.Marshal(FileStatsGRPCToFileStats(resp.Stats)) + _ = json.Unmarshal(statsBytes, &statsMap) - return result, nil + for k, v := range statsMap { + result[k] = v } + + return result } /*DownloadHandler is the handler to respond to download requests from clients*/ @@ -251,16 +264,21 @@ func ListHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Requ return nil, err } - var entities []map[string]interface{} - for i := range listEntitiesResponse.Entities { - entities = append(entities, reference.FileRefGRPCToFileRef(listEntitiesResponse.Entities[i]).GetListingData(ctx)) - } + return ListEntitesResponseHandler(listEntitiesResponse), nil + } +} + +func ListEntitesResponseHandler(resp *blobbergrpc.ListEntitiesResponse) *ListResult { + ctx := context.Background() + var entities []map[string]interface{} + for i := range resp.Entities { + entities = append(entities, reference.FileRefGRPCToFileRef(resp.Entities[i]).GetListingData(ctx)) + } - return &ListResult{ - AllocationRoot: listEntitiesResponse.AllocationRoot, - Meta: reference.FileRefGRPCToFileRef(listEntitiesResponse.MetaData).GetListingData(ctx), - Entities: entities, - }, nil + return &ListResult{ + AllocationRoot: resp.AllocationRoot, + Meta: reference.FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx), + Entities: entities, } } @@ -290,11 +308,15 @@ func ReferencePathHandler(svc *blobberGRPCService) func(ctx context.Context, r * return nil, err } - var recursionCount int - return &ReferencePathResult{ - ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getReferencePathResponse.ReferencePath), - LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWM), - }, nil + return GetReferencePathResponseHandler(getReferencePathResponse), nil + } +} + +func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetReferencePathResponse) *ReferencePathResult { + var recursionCount int + return &ReferencePathResult{ + ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getReferencePathResponse.ReferencePath), + LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWM), } } @@ -312,22 +334,27 @@ func ObjectPathHandler(svc *blobberGRPCService) func(ctx context.Context, r *htt return nil, err } - path := reference.FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Path).GetListingData(ctx) - var pathList []map[string]interface{} - for _, pl := range getObjectPathResponse.ObjectPath.PathList { - pathList = append(pathList, reference.FileRefGRPCToFileRef(pl).GetListingData(ctx)) - } - path["list"] = pathList - - return &ObjectPathResult{ - ObjectPath: &reference.ObjectPath{ - RootHash: getObjectPathResponse.ObjectPath.RootHash, - Meta: reference.FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Meta).GetListingData(ctx), - Path: path, - FileBlockNum: getObjectPathResponse.ObjectPath.FileBlockNum, - }, - LatestWM: WriteMarkerGRPCToWriteMarker(getObjectPathResponse.LatestWriteMarker), - }, nil + return GetObjectPathResponseHandler(getObjectPathResponse), nil + } +} + +func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPathResponse) *ObjectPathResult { + ctx := context.Background() + path := reference.FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Path).GetListingData(ctx) + var pathList []map[string]interface{} + for _, pl := range getObjectPathResponse.ObjectPath.PathList { + pathList = append(pathList, reference.FileRefGRPCToFileRef(pl).GetListingData(ctx)) + } + path["list"] = pathList + + return &ObjectPathResult{ + ObjectPath: &reference.ObjectPath{ + RootHash: getObjectPathResponse.ObjectPath.RootHash, + Meta: reference.FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Meta).GetListingData(ctx), + Path: path, + FileBlockNum: getObjectPathResponse.ObjectPath.FileBlockNum, + }, + LatestWM: WriteMarkerGRPCToWriteMarker(getObjectPathResponse.LatestWriteMarker), } } @@ -344,11 +371,15 @@ func ObjectTreeHandler(svc *blobberGRPCService) func(ctx context.Context, r *htt return nil, err } - var recursionCount int - return &ReferencePathResult{ - ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getObjectTreeResponse.ReferencePath), - LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), - }, nil + return GetObjectTreeResponseHandler(getObjectTreeResponse), nil + } +} + +func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTreeResponse) *ReferencePathResult { + var recursionCount int + return &ReferencePathResult{ + ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getObjectTreeResponse.ReferencePath), + LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), } } From fcec8d4d5ec4e1db7a5e38e50bc9569b5d37e84f Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Thu, 20 May 2021 22:51:05 +0530 Subject: [PATCH 027/183] :sparkles: removed redundant request context and moved script folder out of blobbercore package --- clean-up.sh | 3 + .../blobbercore/blobbergrpc/README.md | 9 +- .../blobbercore/blobbergrpc/blobber.pb.go | 1108 +++++++---------- .../blobbergrpc/proto/blobber.proto | 56 +- .../blobbercore/handler/grpc_handler.go | 42 +- .../blobbercore/handler/grpc_handler_test.go | 15 +- .../handler/grpc_handler_unit_test.go | 209 ++-- .../0chain.net/blobbercore/handler/handler.go | 55 +- .../0chain.net/blobbercore/handler/helper.go | 21 +- .../blobbercore/handler/metadata.go | 45 + .../blobbercore/openapi/blobber.swagger.json | 185 --- .../blobbercore/scripts/generate-grpc.sh | 3 - go.sum | 2 + scripts/generate-grpc.sh | 3 + 14 files changed, 708 insertions(+), 1048 deletions(-) create mode 100755 clean-up.sh create mode 100644 code/go/0chain.net/blobbercore/handler/metadata.go delete mode 100755 code/go/0chain.net/blobbercore/scripts/generate-grpc.sh create mode 100755 scripts/generate-grpc.sh diff --git a/clean-up.sh b/clean-up.sh new file mode 100755 index 000000000..ac004c770 --- /dev/null +++ b/clean-up.sh @@ -0,0 +1,3 @@ +#!/bin/sh + +docker stop $(docker ps -a -q) \ No newline at end of file diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/README.md b/code/go/0chain.net/blobbercore/blobbergrpc/README.md index c856c7db9..b46217165 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/README.md +++ b/code/go/0chain.net/blobbercore/blobbergrpc/README.md @@ -1,9 +1,9 @@ # GRPC Migration -Modify the '.proto' file in `blobbergrpc/proto/blobber.proto` and run +Modify the '.proto' file in `code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto` and run `scripts/generate-grpc.sh` to add new api's. -GRPC API is implemented in `handler/grpc_handler.go`. +GRPC API is implemented in `code/go/0chain.net/blobbercore/handler/grpc_handler.go`. ## Plugins * [grpc-gateway](https://github.com/grpc-ecosystem/grpc-gateway) @@ -13,4 +13,7 @@ plugin is being used to expose a REST api for grpc incompatible clients. The current grpc implementation supports server reflection in development environment. You can interact with the api using https://github.com/gusaul/grpcox. -Make sure the server is running on `--deployment_mode 0` to use server reflection. \ No newline at end of file +Make sure the server is running on `--deployment_mode 0` to use server reflection. + +## Dealing with paths +Refer to - https://developers.google.com/protocol-buffers/docs/reference/go-generated \ No newline at end of file diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 6f79d9b50..2d21e6a7b 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -26,9 +26,8 @@ type GetObjectTreeRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Context *RequestContext `protobuf:"bytes,1,opt,name=context,proto3" json:"context,omitempty"` - Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` - Allocation string `protobuf:"bytes,3,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` + Allocation string `protobuf:"bytes,2,opt,name=allocation,proto3" json:"allocation,omitempty"` } func (x *GetObjectTreeRequest) Reset() { @@ -63,13 +62,6 @@ func (*GetObjectTreeRequest) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{0} } -func (x *GetObjectTreeRequest) GetContext() *RequestContext { - if x != nil { - return x.Context - } - return nil -} - func (x *GetObjectTreeRequest) GetPath() string { if x != nil { return x.Path @@ -144,10 +136,9 @@ type GetReferencePathRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Context *RequestContext `protobuf:"bytes,1,opt,name=Context,proto3" json:"Context,omitempty"` - Paths string `protobuf:"bytes,2,opt,name=Paths,proto3" json:"Paths,omitempty"` - Path string `protobuf:"bytes,3,opt,name=Path,proto3" json:"Path,omitempty"` - Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` + Paths string `protobuf:"bytes,1,opt,name=Paths,proto3" json:"Paths,omitempty"` + Path string `protobuf:"bytes,2,opt,name=Path,proto3" json:"Path,omitempty"` + Allocation string `protobuf:"bytes,3,opt,name=allocation,proto3" json:"allocation,omitempty"` } func (x *GetReferencePathRequest) Reset() { @@ -182,13 +173,6 @@ func (*GetReferencePathRequest) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{2} } -func (x *GetReferencePathRequest) GetContext() *RequestContext { - if x != nil { - return x.Context - } - return nil -} - func (x *GetReferencePathRequest) GetPaths() string { if x != nil { return x.Paths @@ -325,10 +309,9 @@ type GetObjectPathRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Context *RequestContext `protobuf:"bytes,1,opt,name=context,proto3" json:"context,omitempty"` - Allocation string `protobuf:"bytes,2,opt,name=allocation,proto3" json:"allocation,omitempty"` - Path string `protobuf:"bytes,3,opt,name=Path,proto3" json:"Path,omitempty"` - BlockNum string `protobuf:"bytes,4,opt,name=BlockNum,proto3" json:"BlockNum,omitempty"` + Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,2,opt,name=Path,proto3" json:"Path,omitempty"` + BlockNum string `protobuf:"bytes,3,opt,name=BlockNum,proto3" json:"BlockNum,omitempty"` } func (x *GetObjectPathRequest) Reset() { @@ -363,13 +346,6 @@ func (*GetObjectPathRequest) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{5} } -func (x *GetObjectPathRequest) GetContext() *RequestContext { - if x != nil { - return x.Context - } - return nil -} - func (x *GetObjectPathRequest) GetAllocation() string { if x != nil { return x.Allocation @@ -633,11 +609,10 @@ type ListEntitiesRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Context *RequestContext `protobuf:"bytes,1,opt,name=context,proto3" json:"context,omitempty"` - Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` - PathHash string `protobuf:"bytes,3,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` - AuthToken string `protobuf:"bytes,4,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` - Allocation string `protobuf:"bytes,5,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + AuthToken string `protobuf:"bytes,3,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` + Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` } func (x *ListEntitiesRequest) Reset() { @@ -672,13 +647,6 @@ func (*ListEntitiesRequest) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{9} } -func (x *ListEntitiesRequest) GetContext() *RequestContext { - if x != nil { - return x.Context - } - return nil -} - func (x *ListEntitiesRequest) GetPath() string { if x != nil { return x.Path @@ -775,10 +743,9 @@ type GetFileStatsRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Context *RequestContext `protobuf:"bytes,1,opt,name=context,proto3" json:"context,omitempty"` - Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` - PathHash string `protobuf:"bytes,3,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` - Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + Allocation string `protobuf:"bytes,3,opt,name=allocation,proto3" json:"allocation,omitempty"` } func (x *GetFileStatsRequest) Reset() { @@ -813,13 +780,6 @@ func (*GetFileStatsRequest) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{11} } -func (x *GetFileStatsRequest) GetContext() *RequestContext { - if x != nil { - return x.Context - } - return nil -} - func (x *GetFileStatsRequest) GetPath() string { if x != nil { return x.Path @@ -1020,11 +980,10 @@ type GetFileMetaDataRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Context *RequestContext `protobuf:"bytes,1,opt,name=context,proto3" json:"context,omitempty"` - Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` - PathHash string `protobuf:"bytes,3,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` - AuthToken string `protobuf:"bytes,4,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` - Allocation string `protobuf:"bytes,5,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + AuthToken string `protobuf:"bytes,3,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` + Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` } func (x *GetFileMetaDataRequest) Reset() { @@ -1059,13 +1018,6 @@ func (*GetFileMetaDataRequest) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{14} } -func (x *GetFileMetaDataRequest) GetContext() *RequestContext { - if x != nil { - return x.Context - } - return nil -} - func (x *GetFileMetaDataRequest) GetPath() string { if x != nil { return x.Path @@ -1275,90 +1227,18 @@ func (x *Collaborator) GetCreatedAt() int64 { return 0 } -type RequestContext struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Client string `protobuf:"bytes,1,opt,name=client,proto3" json:"client,omitempty"` - ClientKey string `protobuf:"bytes,2,opt,name=client_key,json=clientKey,proto3" json:"client_key,omitempty"` - Allocation string `protobuf:"bytes,3,opt,name=allocation,proto3" json:"allocation,omitempty"` - ClientSignature string `protobuf:"bytes,4,opt,name=client_signature,json=clientSignature,proto3" json:"client_signature,omitempty"` -} - -func (x *RequestContext) Reset() { - *x = RequestContext{} - if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RequestContext) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RequestContext) ProtoMessage() {} - -func (x *RequestContext) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[18] - 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 RequestContext.ProtoReflect.Descriptor instead. -func (*RequestContext) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{18} -} - -func (x *RequestContext) GetClient() string { - if x != nil { - return x.Client - } - return "" -} - -func (x *RequestContext) GetClientKey() string { - if x != nil { - return x.ClientKey - } - return "" -} - -func (x *RequestContext) GetAllocation() string { - if x != nil { - return x.Allocation - } - return "" -} - -func (x *RequestContext) GetClientSignature() string { - if x != nil { - return x.ClientSignature - } - return "" -} - type GetAllocationRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Context *RequestContext `protobuf:"bytes,1,opt,name=context,proto3" json:"context,omitempty"` - Id string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` } func (x *GetAllocationRequest) Reset() { *x = GetAllocationRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1371,7 +1251,7 @@ func (x *GetAllocationRequest) String() string { func (*GetAllocationRequest) ProtoMessage() {} func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1384,14 +1264,7 @@ func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationRequest.ProtoReflect.Descriptor instead. func (*GetAllocationRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{19} -} - -func (x *GetAllocationRequest) GetContext() *RequestContext { - if x != nil { - return x.Context - } - return nil + return file_blobber_proto_rawDescGZIP(), []int{18} } func (x *GetAllocationRequest) GetId() string { @@ -1412,7 +1285,7 @@ type GetAllocationResponse struct { func (x *GetAllocationResponse) Reset() { *x = GetAllocationResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1425,7 +1298,7 @@ func (x *GetAllocationResponse) String() string { func (*GetAllocationResponse) ProtoMessage() {} func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1438,7 +1311,7 @@ func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationResponse.ProtoReflect.Descriptor instead. func (*GetAllocationResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{19} } func (x *GetAllocationResponse) GetAllocation() *Allocation { @@ -1475,7 +1348,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1488,7 +1361,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1501,7 +1374,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{20} } func (x *Allocation) GetID() string { @@ -1638,7 +1511,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1651,7 +1524,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1664,7 +1537,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{21} } func (x *Term) GetID() int64 { @@ -1715,7 +1588,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1728,7 +1601,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1741,7 +1614,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{23} + return file_blobber_proto_rawDescGZIP(), []int{22} } func (x *FileRef) GetType() string { @@ -1799,7 +1672,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1812,7 +1685,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1825,7 +1698,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{24} + return file_blobber_proto_rawDescGZIP(), []int{23} } func (x *FileMetaData) GetType() string { @@ -2016,7 +1889,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[25] + mi := &file_blobber_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2029,7 +1902,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[25] + mi := &file_blobber_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2042,7 +1915,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{25} + return file_blobber_proto_rawDescGZIP(), []int{24} } func (x *DirMetaData) GetType() string { @@ -2122,417 +1995,382 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x22, 0x88, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, - 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x63, 0x6f, - 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x52, - 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, - 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, - 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, + 0x6f, 0x22, 0x4a, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, + 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, + 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, + 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, + 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, + 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, + 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, + 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, + 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, + 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, + 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, + 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, + 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, + 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, + 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, + 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, - 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, - 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0xa1, 0x01, 0x0a, - 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x43, 0x6f, 0x6e, 0x74, - 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x52, 0x07, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, - 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, - 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, - 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, - 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, - 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, - 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, - 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, - 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, + 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, + 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, + 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, + 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, + 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, + 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, + 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, + 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, - 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, - 0x4c, 0x69, 0x73, 0x74, 0x22, 0xa4, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, - 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, - 0x78, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, - 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, - 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x04, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, - 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, - 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, - 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, - 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, - 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, - 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, + 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, + 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, + 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, + 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, + 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, + 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, + 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, + 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, + 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, + 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, + 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, + 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, + 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, + 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, + 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, + 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, + 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, + 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, - 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, - 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, - 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, - 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, - 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, - 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, - 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, - 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, - 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0xc3, 0x01, 0x0a, - 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, - 0x78, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, - 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, - 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, - 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, - 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, - 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, - 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, - 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0xa4, 0x01, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, - 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, - 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, - 0x78, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, - 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, - 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, + 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, + 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, + 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, + 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, + 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, + 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, + 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, + 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, + 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, + 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, + 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, + 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, + 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, + 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, + 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, + 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, + 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, + 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, + 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, - 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, - 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, - 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, + 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, + 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, + 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, + 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, + 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, + 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, + 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, + 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, + 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, + 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, + 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, + 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, + 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, + 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, + 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, + 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, + 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, + 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, + 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, + 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, + 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, + 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, + 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, + 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, + 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, + 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, + 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, + 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, + 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, + 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, + 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, + 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, + 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, + 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, + 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, + 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, + 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, - 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, - 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, - 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, - 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, - 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, - 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, - 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, - 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, - 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, - 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, - 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, - 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, - 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, - 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0xc6, 0x01, 0x0a, 0x16, + 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, + 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, + 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, + 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, + 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, + 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, + 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, + 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, + 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, + 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, + 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, + 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, + 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, + 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, + 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, + 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, + 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, + 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, + 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, + 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, + 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, + 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, + 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, + 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, + 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, + 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, + 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, + 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, + 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, + 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, + 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, + 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, + 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, + 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, + 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, + 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, - 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6e, - 0x74, 0x65, 0x78, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, - 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, - 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, - 0x6b, 0x65, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, - 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, - 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, - 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, - 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, - 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, - 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, - 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, - 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, - 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, - 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, - 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x92, 0x01, 0x0a, - 0x0e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, - 0x16, 0x0a, 0x06, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x06, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x6c, 0x69, 0x65, 0x6e, - 0x74, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x6c, 0x69, - 0x65, 0x6e, 0x74, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x29, 0x0a, 0x10, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, - 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x22, 0x64, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x63, 0x6f, 0x6e, - 0x74, 0x65, 0x78, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x62, 0x6c, 0x6f, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, + 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, + 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, + 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, + 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, + 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, + 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, + 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x52, 0x07, - 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, - 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, - 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, - 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, - 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, - 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, - 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, - 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, - 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, - 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, - 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, - 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, - 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, - 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, - 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, - 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, - 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, - 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, - 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, - 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, - 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, - 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, - 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, - 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, - 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, - 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, - 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, - 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, - 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, - 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, - 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, - 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, - 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, - 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, - 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, - 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, - 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, - 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, - 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, - 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, - 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, - 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, - 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, - 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, - 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, - 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, - 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, - 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, - 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, - 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, - 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, - 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, - 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, - 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, - 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, - 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, - 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, - 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, - 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, - 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, - 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, - 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, - 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, - 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, - 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, + 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, + 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, + 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, - 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, - 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, - 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, - 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, - 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, - 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x42, 0x0f, 0x5a, 0x0d, 0x2e, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, - 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, + 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, + 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, + 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, + 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2547,7 +2385,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 26) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 25) var file_blobber_proto_goTypes = []interface{}{ (*GetObjectTreeRequest)(nil), // 0: blobber.service.v1.GetObjectTreeRequest (*GetObjectTreeResponse)(nil), // 1: blobber.service.v1.GetObjectTreeResponse @@ -2567,64 +2405,56 @@ var file_blobber_proto_goTypes = []interface{}{ (*GetFileMetaDataResponse)(nil), // 15: blobber.service.v1.GetFileMetaDataResponse (*CommitMetaTxn)(nil), // 16: blobber.service.v1.CommitMetaTxn (*Collaborator)(nil), // 17: blobber.service.v1.Collaborator - (*RequestContext)(nil), // 18: blobber.service.v1.RequestContext - (*GetAllocationRequest)(nil), // 19: blobber.service.v1.GetAllocationRequest - (*GetAllocationResponse)(nil), // 20: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 21: blobber.service.v1.Allocation - (*Term)(nil), // 22: blobber.service.v1.Term - (*FileRef)(nil), // 23: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 24: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 25: blobber.service.v1.DirMetaData + (*GetAllocationRequest)(nil), // 18: blobber.service.v1.GetAllocationRequest + (*GetAllocationResponse)(nil), // 19: blobber.service.v1.GetAllocationResponse + (*Allocation)(nil), // 20: blobber.service.v1.Allocation + (*Term)(nil), // 21: blobber.service.v1.Term + (*FileRef)(nil), // 22: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 23: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 24: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ - 18, // 0: blobber.service.v1.GetObjectTreeRequest.context:type_name -> blobber.service.v1.RequestContext - 4, // 1: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 8, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 18, // 3: blobber.service.v1.GetReferencePathRequest.Context:type_name -> blobber.service.v1.RequestContext - 4, // 4: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 8, // 5: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 23, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef - 4, // 7: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath - 18, // 8: blobber.service.v1.GetObjectPathRequest.context:type_name -> blobber.service.v1.RequestContext - 7, // 9: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath - 8, // 10: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 23, // 11: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 23, // 12: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 23, // 13: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 18, // 14: blobber.service.v1.ListEntitiesRequest.context:type_name -> blobber.service.v1.RequestContext - 23, // 15: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 23, // 16: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 18, // 17: blobber.service.v1.GetFileStatsRequest.context:type_name -> blobber.service.v1.RequestContext - 23, // 18: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef - 13, // 19: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 18, // 20: blobber.service.v1.GetFileMetaDataRequest.context:type_name -> blobber.service.v1.RequestContext - 23, // 21: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef - 17, // 22: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 18, // 23: blobber.service.v1.GetAllocationRequest.context:type_name -> blobber.service.v1.RequestContext - 21, // 24: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 22, // 25: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 24, // 26: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 25, // 27: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 16, // 28: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 19, // 29: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 14, // 30: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 11, // 31: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 9, // 32: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 5, // 33: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest - 2, // 34: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest - 0, // 35: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 20, // 36: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 15, // 37: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 12, // 38: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 10, // 39: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 6, // 40: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 3, // 41: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 1, // 42: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 36, // [36:43] is the sub-list for method output_type - 29, // [29:36] is the sub-list for method input_type - 29, // [29:29] is the sub-list for extension type_name - 29, // [29:29] is the sub-list for extension extendee - 0, // [0:29] is the sub-list for field type_name + 4, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 8, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 4, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 8, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 22, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 4, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath + 7, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath + 8, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker + 22, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 22, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 22, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 22, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 22, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 22, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 13, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats + 22, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 17, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 20, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 21, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 23, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 24, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 16, // 21: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 18, // 22: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 14, // 23: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 11, // 24: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 9, // 25: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 5, // 26: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 2, // 27: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest + 0, // 28: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest + 19, // 29: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 15, // 30: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 12, // 31: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 10, // 32: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 6, // 33: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 3, // 34: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 1, // 35: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 29, // [29:36] is the sub-list for method output_type + 22, // [22:29] is the sub-list for method input_type + 22, // [22:22] is the sub-list for extension type_name + 22, // [22:22] is the sub-list for extension extendee + 0, // [0:22] is the sub-list for field type_name } func init() { file_blobber_proto_init() } @@ -2850,18 +2680,6 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RequestContext); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_blobber_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetAllocationRequest); i { case 0: return &v.state @@ -2873,7 +2691,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetAllocationResponse); i { case 0: return &v.state @@ -2885,7 +2703,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Allocation); i { case 0: return &v.state @@ -2897,7 +2715,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Term); i { case 0: return &v.state @@ -2909,7 +2727,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileRef); i { case 0: return &v.state @@ -2921,7 +2739,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileMetaData); i { case 0: return &v.state @@ -2933,7 +2751,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -2952,7 +2770,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 26, + NumMessages: 25, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 6ffac5c11..e02cfbd76 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -1,7 +1,7 @@ syntax = "proto3"; package blobber.service.v1; -option go_package = "./blobbergrpc"; +option go_package = "code/go/0chain.net/blobbercore/blobbergrpc"; import "google/api/annotations.proto"; @@ -45,9 +45,8 @@ service Blobber { } message GetObjectTreeRequest { - RequestContext context = 1; - string path = 2; - string allocation = 3; + string path = 1; + string allocation = 2; } message GetObjectTreeResponse { ReferencePath ReferencePath = 1; @@ -55,10 +54,9 @@ message GetObjectTreeResponse { } message GetReferencePathRequest { - RequestContext Context = 1; - string Paths = 2; - string Path = 3; - string allocation = 4; + string Paths = 1; + string Path = 2; + string allocation = 3; } message GetReferencePathResponse { ReferencePath ReferencePath = 1; @@ -71,10 +69,9 @@ message ReferencePath { } message GetObjectPathRequest { - RequestContext context = 1; - string allocation = 2; - string Path = 3; - string BlockNum = 4; + string allocation = 1; + string Path = 2; + string BlockNum = 3; } message GetObjectPathResponse { ObjectPath ObjectPath = 1; @@ -101,11 +98,10 @@ message WriteMarker { } message ListEntitiesRequest { - RequestContext context = 1; - string path = 2; - string path_hash = 3; - string auth_token = 4; - string allocation = 5; + string path = 1; + string path_hash = 2; + string auth_token = 3; + string allocation = 4; } message ListEntitiesResponse { @@ -115,10 +111,9 @@ message ListEntitiesResponse { } message GetFileStatsRequest { - RequestContext context = 1; - string path = 2; - string path_hash = 3; - string allocation = 4; + string path = 1; + string path_hash = 2; + string allocation = 3; } message GetFileStatsResponse { @@ -140,11 +135,10 @@ message FileStats { } message GetFileMetaDataRequest { - RequestContext context = 1; - string path = 2; - string path_hash = 3; - string auth_token = 4; - string allocation = 5; + string path = 1; + string path_hash = 2; + string auth_token = 3; + string allocation = 4; } message GetFileMetaDataResponse { @@ -164,16 +158,8 @@ message Collaborator { int64 CreatedAt = 3; } -message RequestContext { - string client = 1; - string client_key = 2; - string allocation = 3; - string client_signature = 4; -} - message GetAllocationRequest { - RequestContext context = 1; - string id = 2; + string id = 1; } message GetAllocationResponse { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 9f7c49425..ea35ef792 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -32,7 +32,7 @@ func newGRPCBlobberService(sh StorageHandlerI, r PackageHandler) *blobberGRPCSer } func (b *blobberGRPCService) GetAllocation(ctx context.Context, request *blobbergrpc.GetAllocationRequest) (*blobbergrpc.GetAllocationResponse, error) { - ctx = setupGRPCHandlerContext(ctx, request.Context) + ctx = setupGRPCHandlerContext(ctx, GetGRPCMetaDataFromCtx(ctx), "") allocation, err := b.storageHandler.verifyAllocation(ctx, request.Id, false) if err != nil { @@ -44,13 +44,15 @@ func (b *blobberGRPCService) GetAllocation(ctx context.Context, request *blobber func (b *blobberGRPCService) GetFileMetaData(ctx context.Context, req *blobbergrpc.GetFileMetaDataRequest) (*blobbergrpc.GetFileMetaDataResponse, error) { logger := ctxzap.Extract(ctx) - allocationObj, err := b.storageHandler.verifyAllocation(ctx, req.Context.Allocation, true) + md := GetGRPCMetaDataFromCtx(ctx) + + allocationObj, err := b.storageHandler.verifyAllocation(ctx, req.Allocation, true) if err != nil { return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) } allocationID := allocationObj.ID - clientID := req.Context.Client + clientID := md.Client if len(clientID) == 0 { return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") } @@ -111,20 +113,21 @@ func (b *blobberGRPCService) GetFileMetaData(ctx context.Context, req *blobbergr } func (b *blobberGRPCService) GetFileStats(ctx context.Context, req *blobbergrpc.GetFileStatsRequest) (*blobbergrpc.GetFileStatsResponse, error) { - allocationTx := req.Context.Allocation + allocationTx := req.Allocation allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, true) + md := GetGRPCMetaDataFromCtx(ctx) if err != nil { return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) } allocationID := allocationObj.ID - valid, err := verifySignatureFromRequest(allocationTx, req.Context.ClientSignature, allocationObj.OwnerPublicKey) + valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } - clientID := req.Context.Client + clientID := md.Client if len(clientID) == 0 || allocationObj.OwnerID != clientID { return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") } @@ -162,9 +165,10 @@ func (b *blobberGRPCService) GetFileStats(ctx context.Context, req *blobbergrpc. func (b *blobberGRPCService) ListEntities(ctx context.Context, req *blobbergrpc.ListEntitiesRequest) (*blobbergrpc.ListEntitiesResponse, error) { logger := ctxzap.Extract(ctx) + md := GetGRPCMetaDataFromCtx(ctx) - clientID := req.Context.Client - allocationTx := req.Context.Allocation + clientID := md.Client + allocationTx := req.Allocation allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, true) if err != nil { @@ -228,20 +232,21 @@ func (b *blobberGRPCService) ListEntities(ctx context.Context, req *blobbergrpc. } func (b *blobberGRPCService) GetObjectPath(ctx context.Context, req *blobbergrpc.GetObjectPathRequest) (*blobbergrpc.GetObjectPathResponse, error) { - allocationTx := req.Context.Allocation + allocationTx := req.Allocation allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) + md := GetGRPCMetaDataFromCtx(ctx) if err != nil { return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) } allocationID := allocationObj.ID - valid, err := verifySignatureFromRequest(allocationTx, req.Context.ClientSignature, allocationObj.OwnerPublicKey) + valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } - clientID := req.Context.Client + clientID := md.Client if len(clientID) == 0 || allocationObj.OwnerID != clientID { return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") } @@ -300,8 +305,8 @@ func (b *blobberGRPCService) GetObjectPath(ctx context.Context, req *blobbergrpc } func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobbergrpc.GetReferencePathRequest) (*blobbergrpc.GetReferencePathResponse, error) { - - allocationTx := req.Context.Allocation + md := GetGRPCMetaDataFromCtx(ctx) + allocationTx := req.Allocation allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) if err != nil { @@ -309,12 +314,12 @@ func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobberg } allocationID := allocationObj.ID - valid, err := verifySignatureFromRequest(allocationTx, req.Context.ClientSignature, allocationObj.OwnerPublicKey) + valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } - clientID := req.Context.Client + clientID := md.Client if len(clientID) == 0 { return nil, common.NewError("invalid_operation", "Please pass clientID in the header") } @@ -377,20 +382,21 @@ func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobberg } func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc.GetObjectTreeRequest) (*blobbergrpc.GetObjectTreeResponse, error) { - allocationTx := req.Context.Allocation + allocationTx := req.Allocation allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) + md := GetGRPCMetaDataFromCtx(ctx) if err != nil { return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) } allocationID := allocationObj.ID - valid, err := verifySignatureFromRequest(allocationTx, req.Context.ClientSignature, allocationObj.OwnerPublicKey) + valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } - clientID := req.Context.Client + clientID := md.Client if len(clientID) == 0 || allocationObj.OwnerID != clientID { return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go index a53fd86d8..c4830cf67 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go @@ -125,8 +125,7 @@ func Test_GetAllocation(t *testing.T) { }, args: args{ allocationR: &blobbergrpc.GetAllocationRequest{ - Id: alloc.Tx, - Context: &blobbergrpc.RequestContext{}, + Id: alloc.Tx, }, }, expectCommit: true, @@ -157,8 +156,7 @@ func Test_GetAllocation(t *testing.T) { }, args: args{ allocationR: &blobbergrpc.GetAllocationRequest{ - Id: alloc.Tx, - Context: &blobbergrpc.RequestContext{}, + Id: alloc.Tx, }, }, expectCommit: true, @@ -189,8 +187,7 @@ func Test_GetAllocation(t *testing.T) { }, args: args{ allocationR: &blobbergrpc.GetAllocationRequest{ - Id: expiredAlloc.Tx, - Context: &blobbergrpc.RequestContext{}, + Id: expiredAlloc.Tx, }, }, wantCode: codes.Unknown.String(), @@ -206,8 +203,7 @@ func Test_GetAllocation(t *testing.T) { }, args: args{ allocationR: &blobbergrpc.GetAllocationRequest{ - Id: "", - Context: &blobbergrpc.RequestContext{}, + Id: "", }, }, wantCode: codes.Unknown.String(), @@ -223,8 +219,7 @@ func Test_GetAllocation(t *testing.T) { }, args: args{ allocationR: &blobbergrpc.GetAllocationRequest{ - Id: "id", - Context: &blobbergrpc.RequestContext{}, + Id: "id", }, }, wantCode: codes.Unknown.String(), diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index eb9694718..b5ba303c6 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -7,6 +7,10 @@ import ( "strings" "testing" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + + "google.golang.org/grpc/metadata" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" @@ -26,8 +30,7 @@ import ( func TestBlobberGRPCService_GetAllocation_Success(t *testing.T) { req := &blobbergrpc.GetAllocationRequest{ - Context: &blobbergrpc.RequestContext{}, - Id: "something", + Id: "something", } mockStorageHandler := &storageHandlerI{} @@ -44,8 +47,7 @@ func TestBlobberGRPCService_GetAllocation_Success(t *testing.T) { func TestBlobberGRPCService_GetAllocation_invalidAllocation(t *testing.T) { req := &blobbergrpc.GetAllocationRequest{ - Context: &blobbergrpc.RequestContext{}, - Id: "invalid_allocation", + Id: "invalid_allocation", } mockStorageHandler := &storageHandlerI{} @@ -63,20 +65,21 @@ func TestBlobberGRPCService_GetAllocation_invalidAllocation(t *testing.T) { func TestBlobberGRPCService_GetFileMetaData_Success(t *testing.T) { req := &blobbergrpc.GetFileMetaDataRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "client", - ClientKey: "", - Allocation: "something", - }, Path: "path", PathHash: "path_hash", AuthToken: "testval", - Allocation: "", + Allocation: "something", } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: "", + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, true).Return(&allocation.Allocation{ + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ ID: "allocationId", Tx: req.Allocation, }, nil) @@ -95,7 +98,7 @@ func TestBlobberGRPCService_GetFileMetaData_Success(t *testing.T) { mockStorageHandler.On("verifyAuthTicket", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(true, nil) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.GetFileMetaData(context.Background(), req) + resp, err := svc.GetFileMetaData(ctx, req) if err != nil { t.Fatal("unexpected error") } @@ -105,20 +108,21 @@ func TestBlobberGRPCService_GetFileMetaData_Success(t *testing.T) { func TestBlobberGRPCService_GetFileMetaData_FileNotExist(t *testing.T) { req := &blobbergrpc.GetFileMetaDataRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "client", - ClientKey: "", - Allocation: "something", - }, Path: "path", PathHash: "path_hash", AuthToken: "testval", - Allocation: "", + Allocation: "something", } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: "", + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, true).Return(&allocation.Allocation{ + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ ID: "allocationId", Tx: req.Allocation, }, nil) @@ -134,7 +138,7 @@ func TestBlobberGRPCService_GetFileMetaData_FileNotExist(t *testing.T) { mockStorageHandler.On("verifyAuthTicket", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(true, nil) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.GetFileMetaData(context.Background(), req) + _, err := svc.GetFileMetaData(ctx, req) if err == nil { t.Fatal("expected error") } @@ -158,22 +162,22 @@ func TestBlobberGRPCService_GetFileStats_Success(t *testing.T) { clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) req := &blobbergrpc.GetFileStatsRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "owner", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, Path: "path", PathHash: "path_hash", - Allocation: "", + Allocation: allocationTx, } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "owner", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: clientSignature, + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, true).Return(&allocation.Allocation{ + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ ID: "allocationId", - Tx: req.Context.Allocation, + Tx: req.Allocation, OwnerID: "owner", OwnerPublicKey: pubKey, }, nil) @@ -188,7 +192,7 @@ func TestBlobberGRPCService_GetFileStats_Success(t *testing.T) { mockReferencePackage.On("GetWriteMarkerEntity", mock.Anything, mock.Anything).Return(nil, nil) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.GetFileStats(context.Background(), req) + resp, err := svc.GetFileStats(ctx, req) if err != nil { t.Fatal("unexpected error") } @@ -199,16 +203,17 @@ func TestBlobberGRPCService_GetFileStats_Success(t *testing.T) { func TestBlobberGRPCService_GetFileStats_FileNotExist(t *testing.T) { req := &blobbergrpc.GetFileStatsRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "owner", - ClientKey: "", - Allocation: "", - }, Path: "path", PathHash: "path_hash", Allocation: "", } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "owner", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: "", + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ @@ -223,7 +228,7 @@ func TestBlobberGRPCService_GetFileStats_FileNotExist(t *testing.T) { mockReferencePackage.On("GetWriteMarkerEntity", mock.Anything, mock.Anything).Return(nil, nil) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.GetFileStats(context.Background(), req) + _, err := svc.GetFileStats(ctx, req) if err == nil { t.Fatal("expected error") } @@ -231,17 +236,18 @@ func TestBlobberGRPCService_GetFileStats_FileNotExist(t *testing.T) { func TestBlobberGRPCService_ListEntities_Success(t *testing.T) { req := &blobbergrpc.ListEntitiesRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "client", - ClientKey: "", - Allocation: "", - }, Path: "path", PathHash: "path_hash", AuthToken: "something", Allocation: "", } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: "", + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ @@ -261,7 +267,7 @@ func TestBlobberGRPCService_ListEntities_Success(t *testing.T) { }, nil) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.ListEntities(context.Background(), req) + resp, err := svc.ListEntities(ctx, req) if err != nil { t.Fatal("unexpected error") } @@ -271,17 +277,18 @@ func TestBlobberGRPCService_ListEntities_Success(t *testing.T) { func TestBlobberGRPCService_ListEntities_InvalidAuthTicket(t *testing.T) { req := &blobbergrpc.ListEntitiesRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "client", - ClientKey: "", - Allocation: "", - }, Path: "path", PathHash: "path_hash", AuthToken: "something", Allocation: "", } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: "", + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ @@ -300,7 +307,7 @@ func TestBlobberGRPCService_ListEntities_InvalidAuthTicket(t *testing.T) { }, nil) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.ListEntities(context.Background(), req) + _, err := svc.ListEntities(ctx, req) if err == nil { t.Fatal("expected error") } @@ -313,22 +320,22 @@ func TestBlobberGRPCService_GetObjectPath_Success(t *testing.T) { clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) req := &blobbergrpc.GetObjectPathRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "owner", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, - Allocation: "", + Allocation: allocationTx, Path: "path", BlockNum: "120", } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "owner", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: clientSignature, + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, false).Return(&allocation.Allocation{ + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ ID: "allocationId", - Tx: req.Context.Allocation, + Tx: req.Allocation, OwnerID: "owner", OwnerPublicKey: pubKey, }, nil) @@ -338,7 +345,7 @@ func TestBlobberGRPCService_GetObjectPath_Success(t *testing.T) { }, nil) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.GetObjectPath(context.Background(), req) + resp, err := svc.GetObjectPath(ctx, req) if err != nil { t.Fatal("unexpected error") } @@ -350,16 +357,17 @@ func TestBlobberGRPCService_GetObjectPath_Success(t *testing.T) { func TestBlobberGRPCService_GetObjectPath_InvalidAllocation(t *testing.T) { req := &blobbergrpc.GetObjectPathRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "owner", - ClientKey: "", - Allocation: "", - }, Allocation: "", Path: "path", BlockNum: "120", } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "owner", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: "", + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(nil, errors.New("invalid allocation")) @@ -369,7 +377,7 @@ func TestBlobberGRPCService_GetObjectPath_InvalidAllocation(t *testing.T) { }, nil) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.GetObjectPath(context.Background(), req) + _, err := svc.GetObjectPath(ctx, req) if err == nil { t.Fatal("expected error") } @@ -382,22 +390,22 @@ func TestBlobberGRPCService_GetReferencePath_Success(t *testing.T) { clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) req := &blobbergrpc.GetReferencePathRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "client", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, Paths: `["something"]`, Path: "", - Allocation: "", + Allocation: allocationTx, } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: clientSignature, + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, false).Return(&allocation.Allocation{ + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ ID: "allocationId", - Tx: req.Context.Allocation, + Tx: req.Allocation, OwnerID: "owner", OwnerPublicKey: pubKey, }, nil) @@ -408,7 +416,7 @@ func TestBlobberGRPCService_GetReferencePath_Success(t *testing.T) { }, nil) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.GetReferencePath(context.Background(), req) + resp, err := svc.GetReferencePath(ctx, req) if err != nil { t.Fatal("unexpected error") } @@ -424,29 +432,29 @@ func TestBlobberGRPCService_GetReferencePath_InvalidPaths(t *testing.T) { clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) req := &blobbergrpc.GetReferencePathRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "client", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, Paths: `["something"]`, Path: "", - Allocation: "", + Allocation: allocationTx, } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: clientSignature, + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, false).Return(&allocation.Allocation{ + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ ID: "allocationId", - Tx: req.Context.Allocation, + Tx: req.Allocation, OwnerID: "owner", OwnerPublicKey: pubKey, }, nil) mockReferencePackage.On("GetReferencePathFromPaths", mock.Anything, mock.Anything, mock.Anything).Return(nil, errors.New("invalid paths")) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.GetReferencePath(context.Background(), req) + _, err := svc.GetReferencePath(ctx, req) if err == nil { t.Fatal("expected error") } @@ -462,21 +470,21 @@ func TestBlobberGRPCService_GetObjectTree_Success(t *testing.T) { clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) req := &blobbergrpc.GetObjectTreeRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "owner", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, Path: "something", - Allocation: "", + Allocation: allocationTx, } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "owner", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: clientSignature, + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Context.Allocation, false).Return(&allocation.Allocation{ + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ ID: "allocationId", - Tx: req.Context.Allocation, + Tx: req.Allocation, OwnerID: "owner", OwnerPublicKey: pubKey, }, nil) @@ -487,7 +495,7 @@ func TestBlobberGRPCService_GetObjectTree_Success(t *testing.T) { }, nil) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.GetObjectTree(context.Background(), req) + resp, err := svc.GetObjectTree(ctx, req) if err != nil { t.Fatal("unexpected error - " + err.Error()) } @@ -498,15 +506,16 @@ func TestBlobberGRPCService_GetObjectTree_Success(t *testing.T) { func TestBlobberGRPCService_GetObjectTree_NotOwner(t *testing.T) { req := &blobbergrpc.GetObjectTreeRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "hacker", - ClientKey: "", - Allocation: "", - }, Path: "something", Allocation: "", } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "hacker", + common.ClientKeyHeader: "", + common.ClientSignatureHeader: "", + })) + mockStorageHandler := &storageHandlerI{} mockReferencePackage := &mocks.PackageHandler{} mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ @@ -516,7 +525,7 @@ func TestBlobberGRPCService_GetObjectTree_NotOwner(t *testing.T) { }, nil) svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.GetObjectTree(context.Background(), req) + _, err := svc.GetObjectTree(ctx, req) if err == nil { t.Fatal("expected error") } diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index d93741742..ed034728d 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -9,6 +9,8 @@ import ( "os" "runtime/pprof" + "google.golang.org/grpc/metadata" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" @@ -121,23 +123,20 @@ func setupHandlerContext(ctx context.Context, r *http.Request) context.Context { return ctx } -func setupHandlerGRPCContext(r *http.Request) *blobbergrpc.RequestContext { - var vars = mux.Vars(r) - return &blobbergrpc.RequestContext{ - Client: r.Header.Get(common.ClientHeader), - ClientKey: r.Header.Get(common.ClientKeyHeader), - Allocation: vars["allocation"], - ClientSignature: r.Header.Get(common.ClientSignatureHeader), - } +func setupHandlerGRPCContext(ctx context.Context, r *http.Request) context.Context { + return metadata.NewIncomingContext(ctx, metadata.New(map[string]string{ + common.ClientHeader: r.Header.Get(common.ClientHeader), + common.ClientKeyHeader: r.Header.Get(common.ClientKeyHeader), + common.ClientSignatureHeader: r.Header.Get(common.ClientSignatureHeader), + })) } func AllocationHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { return func(ctx context.Context, r *http.Request) (interface{}, error) { - reqCtx := setupHandlerGRPCContext(r) + ctx = setupHandlerGRPCContext(ctx, r) getAllocationResp, err := svc.GetAllocation(ctx, &blobbergrpc.GetAllocationRequest{ - Context: reqCtx, - Id: r.FormValue("id"), + Id: r.FormValue("id"), }) if err != nil { return nil, err @@ -153,14 +152,13 @@ func GetAllocationResponseHandler(resp *blobbergrpc.GetAllocationResponse) *allo func FileMetaHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { return func(ctx context.Context, r *http.Request) (interface{}, error) { - reqCtx := setupHandlerGRPCContext(r) + ctx = setupHandlerGRPCContext(ctx, r) getFileMetaDataResp, err := svc.GetFileMetaData(ctx, &blobbergrpc.GetFileMetaDataRequest{ - Context: reqCtx, Path: r.FormValue("path"), PathHash: r.FormValue("path_hash"), AuthToken: r.FormValue("auth_token"), - Allocation: reqCtx.Allocation, + Allocation: mux.Vars(r)["allocation"], }) if err != nil { return nil, err @@ -205,13 +203,12 @@ func CollaboratorHandler(ctx context.Context, r *http.Request) (interface{}, err func FileStatsHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { return func(ctx context.Context, r *http.Request) (interface{}, error) { - reqCtx := setupHandlerGRPCContext(r) + ctx = setupHandlerGRPCContext(ctx, r) getFileStatsResponse, err := svc.GetFileStats(ctx, &blobbergrpc.GetFileStatsRequest{ - Context: reqCtx, Path: r.FormValue("path"), PathHash: r.FormValue("path_hash"), - Allocation: reqCtx.Allocation, + Allocation: mux.Vars(r)["allocation"], }) if err != nil { return nil, err @@ -251,14 +248,12 @@ func DownloadHandler(ctx context.Context, r *http.Request) (interface{}, error) /*ListHandler is the handler to respond to upload requests fro clients*/ func ListHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { return func(ctx context.Context, r *http.Request) (interface{}, error) { - reqCtx := setupHandlerGRPCContext(r) - + ctx = setupHandlerGRPCContext(ctx, r) listEntitiesResponse, err := svc.ListEntities(ctx, &blobbergrpc.ListEntitiesRequest{ - Context: reqCtx, Path: r.FormValue("path"), PathHash: r.FormValue("path_hash"), AuthToken: r.FormValue("auth_token"), - Allocation: reqCtx.Allocation, + Allocation: mux.Vars(r)["allocation"], }) if err != nil { return nil, err @@ -296,13 +291,11 @@ func CommitHandler(ctx context.Context, r *http.Request) (interface{}, error) { func ReferencePathHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { return func(ctx context.Context, r *http.Request) (interface{}, error) { - reqCtx := setupHandlerGRPCContext(r) - + ctx = setupHandlerGRPCContext(ctx, r) getReferencePathResponse, err := svc.GetReferencePath(ctx, &blobbergrpc.GetReferencePathRequest{ - Context: reqCtx, Paths: r.FormValue("paths"), Path: r.FormValue("path"), - Allocation: reqCtx.Allocation, + Allocation: mux.Vars(r)["allocation"], }) if err != nil { return nil, err @@ -322,11 +315,9 @@ func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetRe func ObjectPathHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { return func(ctx context.Context, r *http.Request) (interface{}, error) { - reqCtx := setupHandlerGRPCContext(r) - + ctx = setupHandlerGRPCContext(ctx, r) getObjectPathResponse, err := svc.GetObjectPath(ctx, &blobbergrpc.GetObjectPathRequest{ - Context: reqCtx, - Allocation: reqCtx.Allocation, + Allocation: mux.Vars(r)["allocation"], Path: r.FormValue("path"), BlockNum: r.FormValue("block_num"), }) @@ -360,12 +351,10 @@ func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPa func ObjectTreeHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { return func(ctx context.Context, r *http.Request) (interface{}, error) { - reqCtx := setupHandlerGRPCContext(r) - + ctx = setupHandlerGRPCContext(ctx, r) getObjectTreeResponse, err := svc.GetObjectTree(ctx, &blobbergrpc.GetObjectTreeRequest{ - Context: reqCtx, Path: r.FormValue("path"), - Allocation: reqCtx.Allocation, + Allocation: mux.Vars(r)["allocation"], }) if err != nil { return nil, err diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index 015463bd0..d129bc7bd 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -12,26 +12,15 @@ import ( "google.golang.org/grpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" ) -func setupGRPCHandlerContext(ctx context.Context, r *blobbergrpc.RequestContext) context.Context { - ctx = context.WithValue(ctx, constants.CLIENT_CONTEXT_KEY, - r.Client) - ctx = context.WithValue(ctx, constants.CLIENT_KEY_CONTEXT_KEY, - r.ClientKey) - ctx = context.WithValue(ctx, constants.ALLOCATION_CONTEXT_KEY, - r.Allocation) - return ctx -} - func RegisterGRPCServices(r *mux.Router, server *grpc.Server) { - packHandler := &packageHandler{} - blobberService := newGRPCBlobberService(&storageHandler, packHandler) - mux := runtime.NewServeMux() + blobberService := newGRPCBlobberService(&storageHandler, &packageHandler{}) + grpcGatewayHandler := runtime.NewServeMux() + blobbergrpc.RegisterBlobberServer(server, blobberService) - _ = blobbergrpc.RegisterBlobberHandlerServer(context.Background(), mux, blobberService) - r.PathPrefix("/").Handler(mux) + _ = blobbergrpc.RegisterBlobberHandlerServer(context.Background(), grpcGatewayHandler, blobberService) + r.PathPrefix("/").Handler(grpcGatewayHandler) } type StorageHandlerI interface { diff --git a/code/go/0chain.net/blobbercore/handler/metadata.go b/code/go/0chain.net/blobbercore/handler/metadata.go new file mode 100644 index 000000000..0ad3cb7fd --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/metadata.go @@ -0,0 +1,45 @@ +package handler + +import ( + "context" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "google.golang.org/grpc/metadata" +) + +type GRPCMetaData struct { + Client string + ClientKey string + ClientSignature string +} + +func GetGRPCMetaDataFromCtx(ctx context.Context) *GRPCMetaData { + metaData := &GRPCMetaData{} + + md, ok := metadata.FromIncomingContext(ctx) + if !ok { + return metaData + } + + getMetaData := func(key string) string { + list := md.Get(key) + if len(list) > 0 { + return list[0] + } + return "" + } + + metaData.Client = getMetaData(common.ClientHeader) + metaData.ClientKey = getMetaData(common.ClientKeyHeader) + metaData.ClientSignature = getMetaData(common.ClientSignatureHeader) + return metaData +} + +func setupGRPCHandlerContext(ctx context.Context, md *GRPCMetaData, alloc string) context.Context { + ctx = context.WithValue(ctx, constants.CLIENT_CONTEXT_KEY, md.Client) + ctx = context.WithValue(ctx, constants.CLIENT_KEY_CONTEXT_KEY, md.ClientKey) + ctx = context.WithValue(ctx, constants.ALLOCATION_CONTEXT_KEY, alloc) + ctx = context.WithValue(ctx, constants.CLIENT_SIGNATURE_HEADER_KEY, md.ClientSignature) + return ctx +} diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 138688c45..bb3789a42 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -34,30 +34,6 @@ } }, "parameters": [ - { - "name": "context.client", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientKey", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.allocation", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientSignature", - "in": "query", - "required": false, - "type": "string" - }, { "name": "id", "in": "query", @@ -94,30 +70,6 @@ "required": true, "type": "string" }, - { - "name": "context.client", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientKey", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.allocation", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientSignature", - "in": "query", - "required": false, - "type": "string" - }, { "name": "path", "in": "query", @@ -166,30 +118,6 @@ "required": true, "type": "string" }, - { - "name": "context.client", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientKey", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.allocation", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientSignature", - "in": "query", - "required": false, - "type": "string" - }, { "name": "path", "in": "query", @@ -238,30 +166,6 @@ "required": true, "type": "string" }, - { - "name": "context.client", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientKey", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.allocation", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientSignature", - "in": "query", - "required": false, - "type": "string" - }, { "name": "Path", "in": "query", @@ -304,30 +208,6 @@ "required": true, "type": "string" }, - { - "name": "context.client", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientKey", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.allocation", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientSignature", - "in": "query", - "required": false, - "type": "string" - }, { "name": "path", "in": "query", @@ -364,30 +244,6 @@ "required": true, "type": "string" }, - { - "name": "Context.client", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "Context.clientKey", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "Context.allocation", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "Context.clientSignature", - "in": "query", - "required": false, - "type": "string" - }, { "name": "Paths", "in": "query", @@ -430,30 +286,6 @@ "required": true, "type": "string" }, - { - "name": "context.client", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientKey", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.allocation", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "context.clientSignature", - "in": "query", - "required": false, - "type": "string" - }, { "name": "path", "in": "query", @@ -906,23 +738,6 @@ } } }, - "v1RequestContext": { - "type": "object", - "properties": { - "client": { - "type": "string" - }, - "clientKey": { - "type": "string" - }, - "allocation": { - "type": "string" - }, - "clientSignature": { - "type": "string" - } - } - }, "v1Term": { "type": "object", "properties": { diff --git a/code/go/0chain.net/blobbercore/scripts/generate-grpc.sh b/code/go/0chain.net/blobbercore/scripts/generate-grpc.sh deleted file mode 100755 index eacae03fb..000000000 --- a/code/go/0chain.net/blobbercore/scripts/generate-grpc.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/usr/bin/env bash - -protoc -I ./blobbergrpc/proto --go-grpc_out=. --go_out=. --grpc-gateway_out=. --openapiv2_out=./openapi ./blobbergrpc/proto/blobber.proto \ No newline at end of file diff --git a/go.sum b/go.sum index a0ecd3327..ab6111004 100644 --- a/go.sum +++ b/go.sum @@ -94,6 +94,7 @@ github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5Kwzbycv github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/gedex/inflector v0.0.0-20170307190818-16278e9db813/go.mod h1:P+oSoE9yhSRvsmYyZsshflcR6ePWYLql6UU1amW13IM= +github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= @@ -756,6 +757,7 @@ google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv google.golang.org/grpc v1.35.0-dev.0.20201218190559-666aea1fb34c/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.0 h1:o1bcQ6imQMIOpdrO3SWf2z5RV72WbDwdXuK0MDlc8As= google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= +google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.0.0 h1:lQ+dE99pFsb8osbJB3oRfE5eW4Hx6a/lZQr8Jh+eoT4= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.0.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= diff --git a/scripts/generate-grpc.sh b/scripts/generate-grpc.sh new file mode 100755 index 000000000..e3a9e679a --- /dev/null +++ b/scripts/generate-grpc.sh @@ -0,0 +1,3 @@ +#!/usr/bin/env bash + +protoc -I ./code/go/0chain.net/blobbercore/blobbergrpc/proto --go-grpc_out=. --go_out=. --grpc-gateway_out=. --openapiv2_out=./code/go/0chain.net/blobbercore/openapi ./code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto \ No newline at end of file From 92538aa43c7da06b10eecd8e8c05d03bfd838624 Mon Sep 17 00:00:00 2001 From: Shravan Shetty <58299697+shravanshetty1@users.noreply.github.com> Date: Thu, 20 May 2021 22:52:55 +0530 Subject: [PATCH 028/183] Delete clean-up.sh --- clean-up.sh | 3 --- 1 file changed, 3 deletions(-) delete mode 100755 clean-up.sh diff --git a/clean-up.sh b/clean-up.sh deleted file mode 100755 index ac004c770..000000000 --- a/clean-up.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh - -docker stop $(docker ps -a -q) \ No newline at end of file From 378d34ef98d017f0315bcc10cf9edf6c788ee628 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Thu, 20 May 2021 22:54:00 +0530 Subject: [PATCH 029/183] :green_heart: fixing github action --- .github/workflows/ci.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2fc27a3d3..6c129a827 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -77,7 +77,6 @@ jobs: git reset --hard - name: Generate Files run: | - cd code/go/0chain.net/blobbercore ./scripts/generate-grpc.sh - name: Fail if any file has changed run: if output=$(git status --porcelain) && [ -z "$output" ]; then exit 0; else git status; exit 1; fi; From 163688e3c97904fe0a93da7d42388bc0f4055e74 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Fri, 21 May 2021 20:21:58 +0530 Subject: [PATCH 030/183] :white_check_mark: updated tests and added table driven tests --- Makefile | 5 +- code/go/0chain.net/blobber/main.go | 3 +- .../handler/grpc_handler_helper_unit_test.go | 23 +- .../handler/grpc_handler_integration_test.go | 455 ++++++++++++++---- .../go/0chain.net/core/common/rate_limiter.go | 10 +- 5 files changed, 380 insertions(+), 116 deletions(-) diff --git a/Makefile b/Makefile index 902f15ace..79477b07b 100644 --- a/Makefile +++ b/Makefile @@ -4,7 +4,4 @@ test: go test ./...; lint: - golangci-lint run; - -integration-tests: - go test ./... --args integration; \ No newline at end of file + golangci-lint run; \ No newline at end of file diff --git a/code/go/0chain.net/blobber/main.go b/code/go/0chain.net/blobber/main.go index 5030ab6b4..cb26ee6eb 100644 --- a/code/go/0chain.net/blobber/main.go +++ b/code/go/0chain.net/blobber/main.go @@ -339,10 +339,11 @@ func main() { methodsOk := handlers.AllowedMethods([]string{"GET", "HEAD", "POST", "PUT", "DELETE", "OPTIONS"}) + common.ConfigRateLimits() initHandlers(r) initServer() - grpcServer := handler.NewServerWithMiddlewares(common.ConfigRateLimits()) + grpcServer := handler.NewServerWithMiddlewares(common.NewGRPCRateLimiter()) handler.RegisterGRPCServices(r, grpcServer) rHandler := handlers.CORS(originsOk, headersOk, methodsOk)(r) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 859407b49..a52ffd827 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -7,9 +7,10 @@ import ( "log" "time" - "gorm.io/gorm" "testing" + "gorm.io/gorm" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" coreConfig "github.com/0chain/blobber/code/go/0chain.net/core/config" "github.com/0chain/gosdk/core/zcncrypto" @@ -237,7 +238,7 @@ VALUES (1234, 'someClient'); return nil } -func (c *TestDataController) AddGetFileStatsTestData() error { +func (c *TestDataController) AddGetFileStatsTestData(allocationTx, pubKey string) error { var err error var tx *sql.Tx defer func() { @@ -265,7 +266,7 @@ func (c *TestDataController) AddGetFileStatsTestData() error { _, err = tx.Exec(` INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubKey + `',` + fmt.Sprint(expTime) + `,'examplePayerId'); `) if err != nil { return err @@ -287,7 +288,7 @@ VALUES (1234,'exampleId','exampleId:examplePath','exampleId:examplePath','f','fi return nil } -func (c *TestDataController) AddListEntitiesTestData() error { +func (c *TestDataController) AddListEntitiesTestData(allocationTx, pubkey string) error { var err error var tx *sql.Tx defer func() { @@ -315,7 +316,7 @@ func (c *TestDataController) AddListEntitiesTestData() error { _, err = tx.Exec(` INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId'); `) if err != nil { return err @@ -337,7 +338,7 @@ VALUES (1234,'exampleId','exampleId:examplePath','exampleId:examplePath','f','fi return nil } -func (c *TestDataController) AddGetObjectPathTestData() error { +func (c *TestDataController) AddGetObjectPathTestData(allocationTx, pubKey string) error { var err error var tx *sql.Tx defer func() { @@ -365,7 +366,7 @@ func (c *TestDataController) AddGetObjectPathTestData() error { _, err = tx.Exec(` INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubKey + `',` + fmt.Sprint(expTime) + `,'examplePayerId'); `) if err != nil { return err @@ -379,7 +380,7 @@ VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKe return nil } -func (c *TestDataController) AddGetReferencePathTestData() error { +func (c *TestDataController) AddGetReferencePathTestData(allocationTx, pubkey string) error { var err error var tx *sql.Tx defer func() { @@ -407,7 +408,7 @@ func (c *TestDataController) AddGetReferencePathTestData() error { _, err = tx.Exec(` INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId'); `) if err != nil { return err @@ -421,7 +422,7 @@ VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKe return nil } -func (c *TestDataController) AddGetObjectTreeTestData() error { +func (c *TestDataController) AddGetObjectTreeTestData(allocationTx, pubkey string) error { var err error var tx *sql.Tx defer func() { @@ -449,7 +450,7 @@ func (c *TestDataController) AddGetObjectTreeTestData() error { _, err = tx.Exec(` INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId'); `) if err != nil { return err diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index d897b7f73..d5fac4bc0 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -9,15 +9,16 @@ import ( "testing" "time" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/spf13/viper" "gorm.io/driver/postgres" "gorm.io/gorm" - "0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" "google.golang.org/grpc" - - "0chain.net/blobbercore/blobbergrpc" ) const BlobberAddr = "localhost:7031" @@ -30,7 +31,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { args[arg] = true } if !args["integration"] { - t.Skip() + //t.Skip() } ctx := context.Background() @@ -85,18 +86,48 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { t.Fatal(err) } - getAllocationReq := &blobbergrpc.GetAllocationRequest{ - Context: &blobbergrpc.RequestContext{}, - Id: "exampleTransaction", + testCases := []struct { + name string + input *blobbergrpc.GetAllocationRequest + expectedTx string + expectingError bool + }{ + { + name: "Success", + input: &blobbergrpc.GetAllocationRequest{ + Context: &blobbergrpc.RequestContext{}, + Id: "exampleTransaction", + }, + expectedTx: "exampleTransaction", + expectingError: false, + }, + { + name: "UnknownAllocation", + input: &blobbergrpc.GetAllocationRequest{ + Context: &blobbergrpc.RequestContext{}, + Id: "exampleTransaction1", + }, + expectedTx: "", + expectingError: true, + }, } - getAllocationResp, err := blobberClient.GetAllocation(ctx, getAllocationReq) - if err != nil { - t.Fatal(err) - } + for _, tc := range testCases { + getAllocationResp, err := blobberClient.GetAllocation(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } - if getAllocationResp.Allocation.Tx != getAllocationReq.Id { - t.Fatal("unexpected allocation id from GetAllocation rpc") + if tc.expectingError { + t.Fatal("expected error") + } + + if getAllocationResp.Allocation.Tx != tc.expectedTx { + t.Fatal("response with wrong allocation transaction") + } } }) @@ -110,174 +141,400 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { t.Fatal(err) } - req := &blobbergrpc.GetFileMetaDataRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", + testCases := []struct { + name string + input *blobbergrpc.GetFileMetaDataRequest + expectedFileName string + expectingError bool + }{ + { + name: "Success", + input: &blobbergrpc.GetFileMetaDataRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + Allocation: "exampleTransaction", + }, + Path: "examplePath", + PathHash: "exampleId:examplePath", + Allocation: "exampleTransaction", + }, + expectedFileName: "filename", + expectingError: false, + }, + { + name: "Unknown file path", + input: &blobbergrpc.GetFileMetaDataRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + Allocation: "exampleTransaction", + }, + Path: "examplePath", + PathHash: "exampleId:examplePath123", + Allocation: "exampleTransaction", + }, + expectedFileName: "", + expectingError: true, }, - Path: "examplePath", - PathHash: "exampleId:examplePath", - Allocation: "exampleTransaction", - } - getFileMetaDataResp, err := blobberClient.GetFileMetaData(ctx, req) - if err != nil { - t.Fatal(err) } - if getFileMetaDataResp.MetaData.FileMetaData.Name != "filename" { - t.Fatal("unexpected file name from GetFileMetaData rpc") + for _, tc := range testCases { + getFileMetaDataResp, err := blobberClient.GetFileMetaData(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getFileMetaDataResp.MetaData.FileMetaData.Name != tc.expectedFileName { + t.Fatal("unexpected file name from GetFileMetaData rpc") + } } }) t.Run("TestGetFileStats", func(t *testing.T) { + + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + err := tdController.ClearDatabase() if err != nil { t.Fatal(err) } - err = tdController.AddGetFileStatsTestData() + err = tdController.AddGetFileStatsTestData(allocationTx, pubKey) if err != nil { t.Fatal(err) } - req := &blobbergrpc.GetFileStatsRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: "exampleTransaction", + testCases := []struct { + name string + input *blobbergrpc.GetFileStatsRequest + expectedFileName string + expectingError bool + }{ + { + name: "Success", + input: &blobbergrpc.GetFileStatsRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, + }, + Path: "examplePath", + PathHash: "exampleId:examplePath", + }, + expectedFileName: "filename", + expectingError: false, + }, + { + name: "Unknown Path", + input: &blobbergrpc.GetFileStatsRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, + }, + Path: "examplePath", + PathHash: "exampleId:examplePath123", + }, + expectedFileName: "", + expectingError: true, }, - Path: "examplePath", - PathHash: "exampleId:examplePath", } - getFileStatsResp, err := blobberClient.GetFileStats(ctx, req) - if err != nil { - t.Fatal(err) - } + for _, tc := range testCases { + getFileStatsResp, err := blobberClient.GetFileStats(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } - if getFileStatsResp.MetaData.FileMetaData.Name != "filename" { - t.Fatal("unexpected file name from GetFileStats rpc") + if tc.expectingError { + t.Fatal("expected error") + } + + if getFileStatsResp.MetaData.FileMetaData.Name != tc.expectedFileName { + t.Fatal("unexpected file name from GetFileStats rpc") + } } + }) t.Run("TestListEntities", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + err := tdController.ClearDatabase() if err != nil { t.Fatal(err) } - err = tdController.AddListEntitiesTestData() + err = tdController.AddListEntitiesTestData(allocationTx, pubKey) if err != nil { t.Fatal(err) } - req := &blobbergrpc.ListEntitiesRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: "exampleTransaction", + testCases := []struct { + name string + input *blobbergrpc.ListEntitiesRequest + expectedPath string + expectingError bool + }{ + { + name: "Success", + input: &blobbergrpc.ListEntitiesRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, + }, + Path: "examplePath", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: "", + }, + expectedPath: "examplePath", + expectingError: false, + }, + { + name: "bad path", + input: &blobbergrpc.ListEntitiesRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, + }, + Path: "examplePath", + PathHash: "exampleId:examplePath123", + AuthToken: "", + Allocation: "", + }, + expectedPath: "", + expectingError: true, }, - Path: "examplePath", - PathHash: "exampleId:examplePath", - AuthToken: "", - Allocation: "", } - listEntitiesResp, err := blobberClient.ListEntities(ctx, req) - if err != nil { - t.Fatal(err) - } + for _, tc := range testCases { + listEntitiesResp, err := blobberClient.ListEntities(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } - if listEntitiesResp.MetaData.DirMetaData.Path != "examplePath" { - t.Fatal("unexpected path from ListEntities rpc") + if tc.expectingError { + t.Fatal("expected error") + } + + if listEntitiesResp.MetaData.DirMetaData.Path != tc.expectedPath { + t.Fatal("unexpected path from ListEntities rpc") + } } + }) t.Run("TestGetObjectPath", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + err := tdController.ClearDatabase() if err != nil { t.Fatal(err) } - err = tdController.AddGetObjectPathTestData() + err = tdController.AddGetObjectPathTestData(allocationTx, pubKey) if err != nil { t.Fatal(err) } - req := &blobbergrpc.GetObjectPathRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: "exampleTransaction", + testCases := []struct { + name string + input *blobbergrpc.GetObjectPathRequest + expectedPath string + expectingError bool + }{ + { + name: "Success", + input: &blobbergrpc.GetObjectPathRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, + }, + Allocation: "", + Path: "examplePath", + BlockNum: "0", + }, + expectedPath: "/", + expectingError: false, }, - Allocation: "", - Path: "examplePath", - BlockNum: "0", } - getObjectPathResp, err := blobberClient.GetObjectPath(ctx, req) - if err != nil { - t.Fatal(err) - } + for _, tc := range testCases { + getObjectPathResp, err := blobberClient.GetObjectPath(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } - if getObjectPathResp.ObjectPath.Path.DirMetaData.Path != "/" { - t.Fatal("unexpected root hash from GetObjectPath rpc") + if tc.expectingError { + t.Fatal("expected error") + } + + if getObjectPathResp.ObjectPath.Path.DirMetaData.Path != tc.expectedPath { + t.Fatal("unexpected root hash from GetObjectPath rpc") + } } }) t.Run("TestGetReferencePath", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + err := tdController.ClearDatabase() if err != nil { t.Fatal(err) } - err = tdController.AddGetReferencePathTestData() + err = tdController.AddGetReferencePathTestData(allocationTx, pubKey) if err != nil { t.Fatal(err) } - req := &blobbergrpc.GetReferencePathRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: "exampleTransaction", + testCases := []struct { + name string + input *blobbergrpc.GetReferencePathRequest + expectedPath string + expectingError bool + }{ + { + name: "Success", + input: &blobbergrpc.GetReferencePathRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, + }, + Paths: "", + Path: "/", + Allocation: "", + }, + expectedPath: "/", + expectingError: false, }, - Paths: "", - Path: "/", - Allocation: "", - } - getReferencePathResp, err := blobberClient.GetReferencePath(ctx, req) - if err != nil { - t.Fatal(err) } - if getReferencePathResp.ReferencePath.MetaData.DirMetaData.Path != "/" { - t.Fatal("unexpected path from GetReferencePath rpc") + for _, tc := range testCases { + getReferencePathResp, err := blobberClient.GetReferencePath(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getReferencePathResp.ReferencePath.MetaData.DirMetaData.Path != tc.expectedPath { + t.Fatal("unexpected path from GetReferencePath rpc") + } } }) t.Run("TestGetObjectTree", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + err := tdController.ClearDatabase() if err != nil { t.Fatal(err) } - err = tdController.AddGetObjectTreeTestData() + err = tdController.AddGetObjectTreeTestData(allocationTx, pubKey) if err != nil { t.Fatal(err) } - req := &blobbergrpc.GetObjectTreeRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: "exampleTransaction", + testCases := []struct { + name string + input *blobbergrpc.GetObjectTreeRequest + expectedFileName string + expectingError bool + }{ + { + name: "Success", + input: &blobbergrpc.GetObjectTreeRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, + }, + Path: "/", + Allocation: "", + }, + expectedFileName: "root", + expectingError: false, + }, + { + name: "bad path", + input: &blobbergrpc.GetObjectTreeRequest{ + Context: &blobbergrpc.RequestContext{ + Client: "exampleOwnerId", + ClientKey: "", + Allocation: allocationTx, + ClientSignature: clientSignature, + }, + Path: "/2", + Allocation: "", + }, + expectedFileName: "root", + expectingError: true, }, - Path: "/", - Allocation: "", - } - getObjectTreeResp, err := blobberClient.GetObjectTree(ctx, req) - if err != nil { - t.Fatal(err) } - if getObjectTreeResp.ReferencePath.MetaData.DirMetaData.Name != "root" { - t.Fatal("unexpected root name from GetObject") + for _, tc := range testCases { + + getObjectTreeResp, err := blobberClient.GetObjectTree(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getObjectTreeResp.ReferencePath.MetaData.DirMetaData.Name != tc.expectedFileName { + t.Fatal("unexpected root name from GetObject") + } } + }) } diff --git a/code/go/0chain.net/core/common/rate_limiter.go b/code/go/0chain.net/core/common/rate_limiter.go index a4cacdda0..6bb04168f 100644 --- a/code/go/0chain.net/core/common/rate_limiter.go +++ b/code/go/0chain.net/core/common/rate_limiter.go @@ -32,7 +32,7 @@ func (rl *ratelimit) init() { const DefaultRequestPerSecond = 100000 //ConfigRateLimits - configure the rate limits -func ConfigRateLimits() *GRPCRateLimiter { +func ConfigRateLimits() { userRl := viper.GetFloat64("handlers.rate_limit") if userRl == 0 { @@ -41,6 +41,14 @@ func ConfigRateLimits() *GRPCRateLimiter { userRateLimit = &ratelimit{RequestsPerSecond: userRl} userRateLimit.init() +} + +func NewGRPCRateLimiter() *GRPCRateLimiter { + userRl := viper.GetFloat64("handlers.rate_limit") + + if userRl == 0 { + userRl = DefaultRequestPerSecond + } return &GRPCRateLimiter{rl.New(int(userRl))} } From fc7383c3289899577b2fc55c9a2848d7d6670dfe Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Fri, 21 May 2021 20:25:05 +0530 Subject: [PATCH 031/183] :green_heart: fix tests --- .../blobbercore/handler/grpc_handler_integration_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index d5fac4bc0..fba4da54b 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -31,7 +31,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { args[arg] = true } if !args["integration"] { - //t.Skip() + t.Skip() } ctx := context.Background() From f2d004ac32e2c4b76317df79ecf0a02216b4c4a0 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Fri, 21 May 2021 22:04:18 +0530 Subject: [PATCH 032/183] :white_check_mark: updated tests to handle metadata --- .../handler/grpc_handler_integration_test.go | 149 +++++++++--------- 1 file changed, 75 insertions(+), 74 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index fba4da54b..88ff120d7 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -9,6 +9,10 @@ import ( "testing" "time" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + + "google.golang.org/grpc/metadata" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "github.com/spf13/viper" @@ -31,11 +35,9 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { args[arg] = true } if !args["integration"] { - t.Skip() + //t.Skip() } - ctx := context.Background() - var conn *grpc.ClientConn var err error for i := 0; i < RetryAttempts; i++ { @@ -95,8 +97,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { { name: "Success", input: &blobbergrpc.GetAllocationRequest{ - Context: &blobbergrpc.RequestContext{}, - Id: "exampleTransaction", + Id: "exampleTransaction", }, expectedTx: "exampleTransaction", expectingError: false, @@ -104,8 +105,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { { name: "UnknownAllocation", input: &blobbergrpc.GetAllocationRequest{ - Context: &blobbergrpc.RequestContext{}, - Id: "exampleTransaction1", + Id: "exampleTransaction1", }, expectedTx: "", expectingError: true, @@ -113,7 +113,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } for _, tc := range testCases { - getAllocationResp, err := blobberClient.GetAllocation(ctx, tc.input) + getAllocationResp, err := blobberClient.GetAllocation(context.Background(), tc.input) if err != nil { if !tc.expectingError { t.Fatal(err) @@ -143,17 +143,17 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { testCases := []struct { name string + context metadata.MD input *blobbergrpc.GetFileMetaDataRequest expectedFileName string expectingError bool }{ { name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + }), input: &blobbergrpc.GetFileMetaDataRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - Allocation: "exampleTransaction", - }, Path: "examplePath", PathHash: "exampleId:examplePath", Allocation: "exampleTransaction", @@ -163,11 +163,10 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { }, { name: "Unknown file path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + }), input: &blobbergrpc.GetFileMetaDataRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - Allocation: "exampleTransaction", - }, Path: "examplePath", PathHash: "exampleId:examplePath123", Allocation: "exampleTransaction", @@ -178,6 +177,8 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) getFileMetaDataResp, err := blobberClient.GetFileMetaData(ctx, tc.input) if err != nil { if !tc.expectingError { @@ -214,36 +215,35 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { testCases := []struct { name string + context metadata.MD input *blobbergrpc.GetFileStatsRequest expectedFileName string expectingError bool }{ { name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), input: &blobbergrpc.GetFileStatsRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, - Path: "examplePath", - PathHash: "exampleId:examplePath", + Path: "examplePath", + PathHash: "exampleId:examplePath", + Allocation: allocationTx, }, expectedFileName: "filename", expectingError: false, }, { name: "Unknown Path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), input: &blobbergrpc.GetFileStatsRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, - Path: "examplePath", - PathHash: "exampleId:examplePath123", + Path: "examplePath", + PathHash: "exampleId:examplePath123", + Allocation: allocationTx, }, expectedFileName: "", expectingError: true, @@ -251,6 +251,8 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) getFileStatsResp, err := blobberClient.GetFileStats(ctx, tc.input) if err != nil { if !tc.expectingError { @@ -287,40 +289,37 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { testCases := []struct { name string + context metadata.MD input *blobbergrpc.ListEntitiesRequest expectedPath string expectingError bool }{ { name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), input: &blobbergrpc.ListEntitiesRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, Path: "examplePath", PathHash: "exampleId:examplePath", AuthToken: "", - Allocation: "", + Allocation: allocationTx, }, expectedPath: "examplePath", expectingError: false, }, { name: "bad path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), input: &blobbergrpc.ListEntitiesRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, Path: "examplePath", PathHash: "exampleId:examplePath123", AuthToken: "", - Allocation: "", + Allocation: allocationTx, }, expectedPath: "", expectingError: true, @@ -328,6 +327,8 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) listEntitiesResp, err := blobberClient.ListEntities(ctx, tc.input) if err != nil { if !tc.expectingError { @@ -364,20 +365,19 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { testCases := []struct { name string + context metadata.MD input *blobbergrpc.GetObjectPathRequest expectedPath string expectingError bool }{ { name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), input: &blobbergrpc.GetObjectPathRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, - Allocation: "", + Allocation: allocationTx, Path: "examplePath", BlockNum: "0", }, @@ -387,6 +387,8 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) getObjectPathResp, err := blobberClient.GetObjectPath(ctx, tc.input) if err != nil { if !tc.expectingError { @@ -422,22 +424,21 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { testCases := []struct { name string + context metadata.MD input *blobbergrpc.GetReferencePathRequest expectedPath string expectingError bool }{ { name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), input: &blobbergrpc.GetReferencePathRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, Paths: "", Path: "/", - Allocation: "", + Allocation: allocationTx, }, expectedPath: "/", expectingError: false, @@ -445,6 +446,8 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) getReferencePathResp, err := blobberClient.GetReferencePath(ctx, tc.input) if err != nil { if !tc.expectingError { @@ -480,34 +483,31 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { testCases := []struct { name string + context metadata.MD input *blobbergrpc.GetObjectTreeRequest expectedFileName string expectingError bool }{ { name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), input: &blobbergrpc.GetObjectTreeRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, Path: "/", - Allocation: "", + Allocation: allocationTx, }, expectedFileName: "root", expectingError: false, }, { name: "bad path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), input: &blobbergrpc.GetObjectTreeRequest{ - Context: &blobbergrpc.RequestContext{ - Client: "exampleOwnerId", - ClientKey: "", - Allocation: allocationTx, - ClientSignature: clientSignature, - }, Path: "/2", Allocation: "", }, @@ -517,7 +517,8 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } for _, tc := range testCases { - + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) getObjectTreeResp, err := blobberClient.GetObjectTree(ctx, tc.input) if err != nil { if !tc.expectingError { From 577a6a0c99faeffe6b37303e63f5064e549ba998 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Fri, 21 May 2021 22:07:26 +0530 Subject: [PATCH 033/183] :green_heart: fix test --- .../blobbercore/handler/grpc_handler_integration_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 88ff120d7..107c1a5e5 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -35,7 +35,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { args[arg] = true } if !args["integration"] { - //t.Skip() + t.Skip() } var conn *grpc.ClientConn From a32fcf20286499ae88c5e657bff08aeb3e16256f Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Fri, 21 May 2021 22:33:20 +0530 Subject: [PATCH 034/183] :white_check_mark: updated tests --- .../blobbercore/handler/grpc_handler_helper_unit_test.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index a52ffd827..bc8e50864 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -11,8 +11,6 @@ import ( "gorm.io/gorm" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" - coreConfig "github.com/0chain/blobber/code/go/0chain.net/core/config" "github.com/0chain/gosdk/core/zcncrypto" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" @@ -474,8 +472,7 @@ VALUES (1234,'exampleId','exampleId:examplePath','exampleId:examplePath','d','ro func GeneratePubPrivateKey(t *testing.T) (string, string, zcncrypto.SignatureScheme) { - config.Configuration.Config = &coreConfig.Config{SignatureScheme: "bls0chain"} - signScheme := zcncrypto.NewSignatureScheme(config.Configuration.SignatureScheme) + signScheme := zcncrypto.NewSignatureScheme("bls0chain") wallet, err := signScheme.GenerateKeys() if err != nil { t.Fatal(err) From 4cc64a6562f89adc64501da0deec4f8033b68550 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sat, 22 May 2021 13:54:03 +0530 Subject: [PATCH 035/183] :art: refactor to remove circular dependencies --- .../dto.go => blobberHTTP/response.go} | 10 +- .../{handler => convert}/convert.go | 160 ++++++++++++++++-- .../blobbercore/convert/responseHandler.go | 91 ++++++++++ .../blobbercore/handler/grpc_handler.go | 60 +++---- .../blobbercore/handler/grpc_handler_test.go | 6 +- .../0chain.net/blobbercore/handler/handler.go | 101 +---------- .../handler/object_operation_handler.go | 22 +-- .../blobbercore/handler/storage_handler.go | 50 +++--- .../blobbercore/reference/objectpath.go | 143 ---------------- .../blobbercore/reference/referencepath.go | 6 + 10 files changed, 331 insertions(+), 318 deletions(-) rename code/go/0chain.net/blobbercore/{handler/dto.go => blobberHTTP/response.go} (91%) rename code/go/0chain.net/blobbercore/{handler => convert}/convert.go (56%) create mode 100644 code/go/0chain.net/blobbercore/convert/responseHandler.go diff --git a/code/go/0chain.net/blobbercore/handler/dto.go b/code/go/0chain.net/blobbercore/blobberHTTP/response.go similarity index 91% rename from code/go/0chain.net/blobbercore/handler/dto.go rename to code/go/0chain.net/blobbercore/blobberHTTP/response.go index 40c05f165..bac290f6c 100644 --- a/code/go/0chain.net/blobbercore/handler/dto.go +++ b/code/go/0chain.net/blobbercore/blobberHTTP/response.go @@ -1,4 +1,4 @@ -package handler +package blobberHTTP import ( "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" @@ -28,14 +28,8 @@ type CommitResult struct { //Result []*UploadResult `json:"result"` } -type ReferencePath struct { - Meta map[string]interface{} `json:"meta_data"` - List []*ReferencePath `json:"list,omitempty"` - ref *reference.Ref -} - type ReferencePathResult struct { - *ReferencePath + *reference.ReferencePath LatestWM *writemarker.WriteMarker `json:"latest_write_marker"` } diff --git a/code/go/0chain.net/blobbercore/handler/convert.go b/code/go/0chain.net/blobbercore/convert/convert.go similarity index 56% rename from code/go/0chain.net/blobbercore/handler/convert.go rename to code/go/0chain.net/blobbercore/convert/convert.go index 800b98552..73e7b1cdc 100644 --- a/code/go/0chain.net/blobbercore/handler/convert.go +++ b/code/go/0chain.net/blobbercore/convert/convert.go @@ -1,4 +1,4 @@ -package handler +package convert import ( "context" @@ -183,7 +183,7 @@ func GRPCCollaboratorToCollaborator(c *blobbergrpc.Collaborator) *reference.Coll } } -func ReferencePathToReferencePathGRPC(recursionCount *int, refPath *ReferencePath) *blobbergrpc.ReferencePath { +func ReferencePathToReferencePathGRPC(recursionCount *int, refPath *reference.ReferencePath) *blobbergrpc.ReferencePath { if refPath == nil { return nil } @@ -195,7 +195,7 @@ func ReferencePathToReferencePathGRPC(recursionCount *int, refPath *ReferencePat if *recursionCount > 150 { return &blobbergrpc.ReferencePath{ - MetaData: reference.FileRefToFileRefGRPC(reference.ListingDataToRef(refPath.Meta)), + MetaData: FileRefToFileRefGRPC(reference.ListingDataToRef(refPath.Meta)), List: nil, } } @@ -206,12 +206,12 @@ func ReferencePathToReferencePathGRPC(recursionCount *int, refPath *ReferencePat } return &blobbergrpc.ReferencePath{ - MetaData: reference.FileRefToFileRefGRPC(reference.ListingDataToRef(refPath.Meta)), + MetaData: FileRefToFileRefGRPC(reference.ListingDataToRef(refPath.Meta)), List: list, } } -func ReferencePathGRPCToReferencePath(recursionCount *int, refPath *blobbergrpc.ReferencePath) *ReferencePath { +func ReferencePathGRPCToReferencePath(recursionCount *int, refPath *blobbergrpc.ReferencePath) *reference.ReferencePath { if refPath == nil { return nil } @@ -222,19 +222,159 @@ func ReferencePathGRPCToReferencePath(recursionCount *int, refPath *blobbergrpc. }() if *recursionCount > 150 { - return &ReferencePath{ - Meta: reference.FileRefGRPCToFileRef(refPath.MetaData).GetListingData(context.Background()), + return &reference.ReferencePath{ + Meta: FileRefGRPCToFileRef(refPath.MetaData).GetListingData(context.Background()), List: nil, } } - var list []*ReferencePath + var list []*reference.ReferencePath for i := range refPath.List { list = append(list, ReferencePathGRPCToReferencePath(recursionCount, refPath.List[i])) } - return &ReferencePath{ - Meta: reference.FileRefGRPCToFileRef(refPath.MetaData).GetListingData(context.Background()), + return &reference.ReferencePath{ + Meta: FileRefGRPCToFileRef(refPath.MetaData).GetListingData(context.Background()), List: list, } } + +func FileRefToFileRefGRPC(ref *reference.Ref) *blobbergrpc.FileRef { + if ref == nil { + return nil + } + + var fileMetaData *blobbergrpc.FileMetaData + var dirMetaData *blobbergrpc.DirMetaData + switch ref.Type { + case reference.FILE: + fileMetaData = convertFileRefToFileMetaDataGRPC(ref) + case reference.DIRECTORY: + dirMetaData = convertDirRefToDirMetaDataGRPC(ref) + } + + return &blobbergrpc.FileRef{ + Type: ref.Type, + FileMetaData: fileMetaData, + DirMetaData: dirMetaData, + } +} + +func convertFileRefToFileMetaDataGRPC(fileref *reference.Ref) *blobbergrpc.FileMetaData { + var commitMetaTxnsGRPC []*blobbergrpc.CommitMetaTxn + for _, c := range fileref.CommitMetaTxns { + commitMetaTxnsGRPC = append(commitMetaTxnsGRPC, &blobbergrpc.CommitMetaTxn{ + RefId: c.RefID, + TxnId: c.TxnID, + CreatedAt: c.CreatedAt.UnixNano(), + }) + } + return &blobbergrpc.FileMetaData{ + Type: fileref.Type, + LookupHash: fileref.LookupHash, + Name: fileref.Name, + Path: fileref.Path, + Hash: fileref.Hash, + NumBlocks: fileref.NumBlocks, + PathHash: fileref.PathHash, + CustomMeta: fileref.CustomMeta, + ContentHash: fileref.ContentHash, + Size: fileref.Size, + MerkleRoot: fileref.MerkleRoot, + ActualFileSize: fileref.ActualFileSize, + ActualFileHash: fileref.ActualFileHash, + MimeType: fileref.MimeType, + ThumbnailSize: fileref.ThumbnailSize, + ThumbnailHash: fileref.ThumbnailHash, + ActualThumbnailSize: fileref.ActualThumbnailSize, + ActualThumbnailHash: fileref.ActualThumbnailHash, + EncryptedKey: fileref.EncryptedKey, + Attributes: fileref.Attributes, + OnCloud: fileref.OnCloud, + CommitMetaTxns: commitMetaTxnsGRPC, + CreatedAt: fileref.CreatedAt.UnixNano(), + UpdatedAt: fileref.UpdatedAt.UnixNano(), + } +} + +func convertDirRefToDirMetaDataGRPC(dirref *reference.Ref) *blobbergrpc.DirMetaData { + return &blobbergrpc.DirMetaData{ + Type: dirref.Type, + LookupHash: dirref.LookupHash, + Name: dirref.Name, + Path: dirref.Path, + Hash: dirref.Hash, + NumBlocks: dirref.NumBlocks, + PathHash: dirref.PathHash, + Size: dirref.Size, + CreatedAt: dirref.CreatedAt.UnixNano(), + UpdatedAt: dirref.UpdatedAt.UnixNano(), + } +} + +func FileRefGRPCToFileRef(ref *blobbergrpc.FileRef) *reference.Ref { + if ref == nil { + return nil + } + + switch ref.Type { + case reference.FILE: + return convertFileMetaDataGRPCToFileRef(ref.FileMetaData) + case reference.DIRECTORY: + return convertDirMetaDataGRPCToDirRef(ref.DirMetaData) + } + + return nil +} + +func convertFileMetaDataGRPCToFileRef(metaData *blobbergrpc.FileMetaData) *reference.Ref { + var commitMetaTxnsGRPC []reference.CommitMetaTxn + for _, c := range metaData.CommitMetaTxns { + commitMetaTxnsGRPC = append(commitMetaTxnsGRPC, reference.CommitMetaTxn{ + RefID: c.RefId, + TxnID: c.TxnId, + CreatedAt: time.Unix(0, c.CreatedAt), + }) + } + return &reference.Ref{ + Type: metaData.Type, + LookupHash: metaData.LookupHash, + Name: metaData.Name, + Path: metaData.Path, + Hash: metaData.Hash, + NumBlocks: metaData.NumBlocks, + PathHash: metaData.PathHash, + CustomMeta: metaData.CustomMeta, + ContentHash: metaData.ContentHash, + Size: metaData.Size, + MerkleRoot: metaData.MerkleRoot, + ActualFileSize: metaData.ActualFileSize, + ActualFileHash: metaData.ActualFileHash, + MimeType: metaData.MimeType, + ThumbnailSize: metaData.ThumbnailSize, + ThumbnailHash: metaData.ThumbnailHash, + ActualThumbnailSize: metaData.ActualThumbnailSize, + ActualThumbnailHash: metaData.ActualThumbnailHash, + EncryptedKey: metaData.EncryptedKey, + Attributes: metaData.Attributes, + OnCloud: metaData.OnCloud, + CommitMetaTxns: commitMetaTxnsGRPC, + CreatedAt: time.Unix(0, metaData.CreatedAt), + UpdatedAt: time.Unix(0, metaData.UpdatedAt), + } +} + +func convertDirMetaDataGRPCToDirRef(dirref *blobbergrpc.DirMetaData) *reference.Ref { + return &reference.Ref{ + Type: dirref.Type, + LookupHash: dirref.LookupHash, + Name: dirref.Name, + Path: dirref.Path, + Hash: dirref.Hash, + NumBlocks: dirref.NumBlocks, + PathHash: dirref.PathHash, + Size: dirref.Size, + CreatedAt: time.Unix(0, dirref.CreatedAt), + UpdatedAt: time.Unix(0, dirref.UpdatedAt), + } +} diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go new file mode 100644 index 000000000..e16a5177e --- /dev/null +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -0,0 +1,91 @@ +package convert + +import ( + "context" + "encoding/json" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberHTTP" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" +) + +func GetAllocationResponseHandler(resp *blobbergrpc.GetAllocationResponse) *allocation.Allocation { + return GRPCAllocationToAllocation(resp.Allocation) +} + +func GetFileMetaDataResponseHandler(resp *blobbergrpc.GetFileMetaDataResponse) map[string]interface{} { + var collaborators []reference.Collaborator + for _, c := range resp.Collaborators { + collaborators = append(collaborators, *GRPCCollaboratorToCollaborator(c)) + } + + result := FileRefGRPCToFileRef(resp.MetaData).GetListingData(context.Background()) + result["collaborators"] = collaborators + return result +} + +func GetFileStatsResponseHandler(resp *blobbergrpc.GetFileStatsResponse) map[string]interface{} { + ctx := context.Background() + result := FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx) + + statsMap := make(map[string]interface{}) + statsBytes, _ := json.Marshal(FileStatsGRPCToFileStats(resp.Stats)) + _ = json.Unmarshal(statsBytes, &statsMap) + + for k, v := range statsMap { + result[k] = v + } + + return result +} + +func ListEntitesResponseHandler(resp *blobbergrpc.ListEntitiesResponse) *blobberHTTP.ListResult { + ctx := context.Background() + var entities []map[string]interface{} + for i := range resp.Entities { + entities = append(entities, FileRefGRPCToFileRef(resp.Entities[i]).GetListingData(ctx)) + } + + return &blobberHTTP.ListResult{ + AllocationRoot: resp.AllocationRoot, + Meta: FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx), + Entities: entities, + } +} + +func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetReferencePathResponse) *blobberHTTP.ReferencePathResult { + var recursionCount int + return &blobberHTTP.ReferencePathResult{ + ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getReferencePathResponse.ReferencePath), + LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWM), + } +} + +func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPathResponse) *blobberHTTP.ObjectPathResult { + ctx := context.Background() + path := FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Path).GetListingData(ctx) + var pathList []map[string]interface{} + for _, pl := range getObjectPathResponse.ObjectPath.PathList { + pathList = append(pathList, FileRefGRPCToFileRef(pl).GetListingData(ctx)) + } + path["list"] = pathList + + return &blobberHTTP.ObjectPathResult{ + ObjectPath: &reference.ObjectPath{ + RootHash: getObjectPathResponse.ObjectPath.RootHash, + Meta: FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Meta).GetListingData(ctx), + Path: path, + FileBlockNum: getObjectPathResponse.ObjectPath.FileBlockNum, + }, + LatestWM: WriteMarkerGRPCToWriteMarker(getObjectPathResponse.LatestWriteMarker), + } +} + +func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTreeResponse) *blobberHTTP.ReferencePathResult { + var recursionCount int + return &blobberHTTP.ReferencePathResult{ + ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getObjectTreeResponse.ReferencePath), + LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), + } +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index ea35ef792..9efb8ad08 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -5,6 +5,8 @@ import ( "encoding/json" "strconv" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" @@ -39,7 +41,7 @@ func (b *blobberGRPCService) GetAllocation(ctx context.Context, request *blobber return nil, err } - return &blobbergrpc.GetAllocationResponse{Allocation: AllocationToGRPCAllocation(allocation)}, nil + return &blobbergrpc.GetAllocationResponse{Allocation: convert.AllocationToGRPCAllocation(allocation)}, nil } func (b *blobberGRPCService) GetFileMetaData(ctx context.Context, req *blobbergrpc.GetFileMetaDataRequest) (*blobbergrpc.GetFileMetaDataResponse, error) { @@ -103,11 +105,11 @@ func (b *blobberGRPCService) GetFileMetaData(ctx context.Context, req *blobbergr var collaboratorsGRPC []*blobbergrpc.Collaborator for _, c := range collaborators { - collaboratorsGRPC = append(collaboratorsGRPC, CollaboratorToGRPCCollaborator(&c)) + collaboratorsGRPC = append(collaboratorsGRPC, convert.CollaboratorToGRPCCollaborator(&c)) } return &blobbergrpc.GetFileMetaDataResponse{ - MetaData: reference.FileRefToFileRefGRPC(fileref), + MetaData: convert.FileRefToFileRefGRPC(fileref), Collaborators: collaboratorsGRPC, }, nil } @@ -158,8 +160,8 @@ func (b *blobberGRPCService) GetFileStats(ctx context.Context, req *blobbergrpc. } return &blobbergrpc.GetFileStatsResponse{ - MetaData: reference.FileRefToFileRefGRPC(fileref), - Stats: FileStatsToFileStatsGRPC(stats), + MetaData: convert.FileRefToFileRefGRPC(fileref), + Stats: convert.FileStatsToFileStatsGRPC(stats), }, nil } @@ -220,9 +222,9 @@ func (b *blobberGRPCService) ListEntities(ctx context.Context, req *blobbergrpc. if clientID != allocationObj.OwnerID { entity.Path = "" } - entities = append(entities, reference.FileRefToFileRefGRPC(entity)) + entities = append(entities, convert.FileRefToFileRefGRPC(entity)) } - refGRPC := reference.FileRefToFileRefGRPC(dirref) + refGRPC := convert.FileRefToFileRefGRPC(dirref) return &blobbergrpc.ListEntitiesResponse{ AllocationRoot: allocationObj.AllocationRoot, @@ -281,22 +283,22 @@ func (b *blobberGRPCService) GetObjectPath(ctx context.Context, req *blobbergrpc } var latestWriteMarketGRPC *blobbergrpc.WriteMarker if latestWM != nil { - latestWriteMarketGRPC = WriteMarkerToWriteMarkerGRPC(&latestWM.WM) + latestWriteMarketGRPC = convert.WriteMarkerToWriteMarkerGRPC(&latestWM.WM) } pathList := make([]*blobbergrpc.FileRef, 0) list, _ := objectPath.Path["list"].([]map[string]interface{}) if len(list) > 0 { for _, pl := range list { - pathList = append(pathList, reference.FileRefToFileRefGRPC(reference.ListingDataToRef(pl))) + pathList = append(pathList, convert.FileRefToFileRefGRPC(reference.ListingDataToRef(pl))) } } return &blobbergrpc.GetObjectPathResponse{ ObjectPath: &blobbergrpc.ObjectPath{ RootHash: objectPath.RootHash, - Meta: reference.FileRefToFileRefGRPC(reference.ListingDataToRef(objectPath.Meta)), - Path: reference.FileRefToFileRefGRPC(reference.ListingDataToRef(objectPath.Path)), + Meta: convert.FileRefToFileRefGRPC(reference.ListingDataToRef(objectPath.Meta)), + Path: convert.FileRefToFileRefGRPC(reference.ListingDataToRef(objectPath.Path)), PathList: pathList, FileBlockNum: objectPath.FileBlockNum, }, @@ -344,17 +346,17 @@ func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobberg return nil, err } - refPath := &ReferencePath{ref: rootRef} - refsToProcess := make([]*ReferencePath, 0) + refPath := &reference.ReferencePath{Ref: rootRef} + refsToProcess := make([]*reference.ReferencePath, 0) refsToProcess = append(refsToProcess, refPath) for len(refsToProcess) > 0 { refToProcess := refsToProcess[0] - refToProcess.Meta = refToProcess.ref.GetListingData(ctx) - if len(refToProcess.ref.Children) > 0 { - refToProcess.List = make([]*ReferencePath, len(refToProcess.ref.Children)) + refToProcess.Meta = refToProcess.Ref.GetListingData(ctx) + if len(refToProcess.Ref.Children) > 0 { + refToProcess.List = make([]*reference.ReferencePath, len(refToProcess.Ref.Children)) } - for idx, child := range refToProcess.ref.Children { - childRefPath := &ReferencePath{ref: child} + for idx, child := range refToProcess.Ref.Children { + childRefPath := &reference.ReferencePath{Ref: child} refToProcess.List[idx] = childRefPath refsToProcess = append(refsToProcess, childRefPath) } @@ -373,9 +375,9 @@ func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobberg var refPathResult blobbergrpc.GetReferencePathResponse var recursionCount int - refPathResult.ReferencePath = ReferencePathToReferencePathGRPC(&recursionCount, refPath) + refPathResult.ReferencePath = convert.ReferencePathToReferencePathGRPC(&recursionCount, refPath) if latestWM != nil { - refPathResult.LatestWM = WriteMarkerToWriteMarkerGRPC(&latestWM.WM) + refPathResult.LatestWM = convert.WriteMarkerToWriteMarkerGRPC(&latestWM.WM) } return &refPathResult, nil @@ -410,17 +412,17 @@ func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc return nil, err } - refPath := &ReferencePath{ref: rootRef} - refsToProcess := make([]*ReferencePath, 0) + refPath := &reference.ReferencePath{Ref: rootRef} + refsToProcess := make([]*reference.ReferencePath, 0) refsToProcess = append(refsToProcess, refPath) for len(refsToProcess) > 0 { refToProcess := refsToProcess[0] - refToProcess.Meta = refToProcess.ref.GetListingData(ctx) - if len(refToProcess.ref.Children) > 0 { - refToProcess.List = make([]*ReferencePath, len(refToProcess.ref.Children)) + refToProcess.Meta = refToProcess.Ref.GetListingData(ctx) + if len(refToProcess.Ref.Children) > 0 { + refToProcess.List = make([]*reference.ReferencePath, len(refToProcess.Ref.Children)) } - for idx, child := range refToProcess.ref.Children { - childRefPath := &ReferencePath{ref: child} + for idx, child := range refToProcess.Ref.Children { + childRefPath := &reference.ReferencePath{Ref: child} refToProcess.List[idx] = childRefPath refsToProcess = append(refsToProcess, childRefPath) } @@ -438,9 +440,9 @@ func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc } var refPathResult blobbergrpc.GetObjectTreeResponse var recursionCount int - refPathResult.ReferencePath = ReferencePathToReferencePathGRPC(&recursionCount, refPath) + refPathResult.ReferencePath = convert.ReferencePathToReferencePathGRPC(&recursionCount, refPath) if latestWM != nil { - refPathResult.LatestWM = WriteMarkerToWriteMarkerGRPC(&latestWM.WM) + refPathResult.LatestWM = convert.WriteMarkerToWriteMarkerGRPC(&latestWM.WM) } return &refPathResult, nil } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go index c4830cf67..0eb542802 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go @@ -8,6 +8,8 @@ import ( "testing" "time" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" + rl "go.uber.org/ratelimit" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" @@ -130,7 +132,7 @@ func Test_GetAllocation(t *testing.T) { }, expectCommit: true, wantCode: codes.OK.String(), - wantAlloc: AllocationToGRPCAllocation(alloc), + wantAlloc: convert.AllocationToGRPCAllocation(alloc), }, { name: "Commiting_Transaction_ERR", @@ -161,7 +163,7 @@ func Test_GetAllocation(t *testing.T) { }, expectCommit: true, wantCode: codes.OK.String(), - wantAlloc: AllocationToGRPCAllocation(alloc), + wantAlloc: convert.AllocationToGRPCAllocation(alloc), }, { name: "Expired_Allocation_ERR", diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index ed034728d..5d001aafc 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -4,16 +4,13 @@ package handler import ( "context" - "encoding/json" "net/http" "os" "runtime/pprof" - "google.golang.org/grpc/metadata" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "google.golang.org/grpc/metadata" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" @@ -142,14 +139,10 @@ func AllocationHandler(svc *blobberGRPCService) func(ctx context.Context, r *htt return nil, err } - return GetAllocationResponseHandler(getAllocationResp), nil + return convert.GetAllocationResponseHandler(getAllocationResp), nil } } -func GetAllocationResponseHandler(resp *blobbergrpc.GetAllocationResponse) *allocation.Allocation { - return GRPCAllocationToAllocation(resp.Allocation) -} - func FileMetaHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { return func(ctx context.Context, r *http.Request) (interface{}, error) { ctx = setupHandlerGRPCContext(ctx, r) @@ -164,21 +157,10 @@ func FileMetaHandler(svc *blobberGRPCService) func(ctx context.Context, r *http. return nil, err } - return GetFileMetaDataResponseHandler(getFileMetaDataResp), nil + return convert.GetFileMetaDataResponseHandler(getFileMetaDataResp), nil } } -func GetFileMetaDataResponseHandler(resp *blobbergrpc.GetFileMetaDataResponse) map[string]interface{} { - var collaborators []reference.Collaborator - for _, c := range resp.Collaborators { - collaborators = append(collaborators, *GRPCCollaboratorToCollaborator(c)) - } - - result := reference.FileRefGRPCToFileRef(resp.MetaData).GetListingData(context.Background()) - result["collaborators"] = collaborators - return result -} - func CommitMetaTxnHandler(ctx context.Context, r *http.Request) (interface{}, error) { ctx = setupHandlerContext(ctx, r) @@ -214,25 +196,10 @@ func FileStatsHandler(svc *blobberGRPCService) func(ctx context.Context, r *http return nil, err } - return GetFileStatsResponseHandler(getFileStatsResponse), nil + return convert.GetFileStatsResponseHandler(getFileStatsResponse), nil } } -func GetFileStatsResponseHandler(resp *blobbergrpc.GetFileStatsResponse) map[string]interface{} { - ctx := context.Background() - result := reference.FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx) - - statsMap := make(map[string]interface{}) - statsBytes, _ := json.Marshal(FileStatsGRPCToFileStats(resp.Stats)) - _ = json.Unmarshal(statsBytes, &statsMap) - - for k, v := range statsMap { - result[k] = v - } - - return result -} - /*DownloadHandler is the handler to respond to download requests from clients*/ func DownloadHandler(ctx context.Context, r *http.Request) (interface{}, error) { ctx = setupHandlerContext(ctx, r) @@ -259,21 +226,7 @@ func ListHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Requ return nil, err } - return ListEntitesResponseHandler(listEntitiesResponse), nil - } -} - -func ListEntitesResponseHandler(resp *blobbergrpc.ListEntitiesResponse) *ListResult { - ctx := context.Background() - var entities []map[string]interface{} - for i := range resp.Entities { - entities = append(entities, reference.FileRefGRPCToFileRef(resp.Entities[i]).GetListingData(ctx)) - } - - return &ListResult{ - AllocationRoot: resp.AllocationRoot, - Meta: reference.FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx), - Entities: entities, + return convert.ListEntitesResponseHandler(listEntitiesResponse), nil } } @@ -301,15 +254,7 @@ func ReferencePathHandler(svc *blobberGRPCService) func(ctx context.Context, r * return nil, err } - return GetReferencePathResponseHandler(getReferencePathResponse), nil - } -} - -func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetReferencePathResponse) *ReferencePathResult { - var recursionCount int - return &ReferencePathResult{ - ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getReferencePathResponse.ReferencePath), - LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWM), + return convert.GetReferencePathResponseHandler(getReferencePathResponse), nil } } @@ -325,27 +270,7 @@ func ObjectPathHandler(svc *blobberGRPCService) func(ctx context.Context, r *htt return nil, err } - return GetObjectPathResponseHandler(getObjectPathResponse), nil - } -} - -func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPathResponse) *ObjectPathResult { - ctx := context.Background() - path := reference.FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Path).GetListingData(ctx) - var pathList []map[string]interface{} - for _, pl := range getObjectPathResponse.ObjectPath.PathList { - pathList = append(pathList, reference.FileRefGRPCToFileRef(pl).GetListingData(ctx)) - } - path["list"] = pathList - - return &ObjectPathResult{ - ObjectPath: &reference.ObjectPath{ - RootHash: getObjectPathResponse.ObjectPath.RootHash, - Meta: reference.FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Meta).GetListingData(ctx), - Path: path, - FileBlockNum: getObjectPathResponse.ObjectPath.FileBlockNum, - }, - LatestWM: WriteMarkerGRPCToWriteMarker(getObjectPathResponse.LatestWriteMarker), + return convert.GetObjectPathResponseHandler(getObjectPathResponse), nil } } @@ -360,15 +285,7 @@ func ObjectTreeHandler(svc *blobberGRPCService) func(ctx context.Context, r *htt return nil, err } - return GetObjectTreeResponseHandler(getObjectTreeResponse), nil - } -} - -func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTreeResponse) *ReferencePathResult { - var recursionCount int - return &ReferencePathResult{ - ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getObjectTreeResponse.ReferencePath), - LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), + return convert.GetObjectTreeResponseHandler(getObjectTreeResponse), nil } } diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go index a9b55b720..7ccc89fe3 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go @@ -6,6 +6,8 @@ import ( "encoding/json" "errors" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberHTTP" + "net/http" "path/filepath" "strconv" @@ -342,7 +344,7 @@ func (fsh *StorageHandler) DownloadFile(ctx context.Context, r *http.Request) ( if latestRM != nil && latestRM.ReadCounter+(numBlocks) != readMarker.ReadCounter { - var response = &DownloadResponse{ + var response = &blobberHTTP.DownloadResponse{ Success: false, LatestRM: latestRM, Path: fileref.Path, @@ -398,7 +400,7 @@ func (fsh *StorageHandler) DownloadFile(ctx context.Context, r *http.Request) ( "couldn't save latest read marker: %v", err) } - var response = &DownloadResponse{} + var response = &blobberHTTP.DownloadResponse{} response.Success = true response.LatestRM = readMarker response.Data = respData @@ -409,7 +411,7 @@ func (fsh *StorageHandler) DownloadFile(ctx context.Context, r *http.Request) ( return respData, nil } -func (fsh *StorageHandler) CommitWrite(ctx context.Context, r *http.Request) (*CommitResult, error) { +func (fsh *StorageHandler) CommitWrite(ctx context.Context, r *http.Request) (*blobberHTTP.CommitResult, error) { if r.Method == "GET" { return nil, common.NewError("invalid_method", "Invalid method used for the upload URL. Use POST instead") @@ -488,7 +490,7 @@ func (fsh *StorageHandler) CommitWrite(ctx context.Context, r *http.Request) (*C err) } - var result CommitResult + var result blobberHTTP.CommitResult var latestWM *writemarker.WriteMarkerEntity if len(allocationObj.AllocationRoot) == 0 { latestWM = nil @@ -654,7 +656,7 @@ func (fsh *StorageHandler) RenameObject(ctx context.Context, r *http.Request) (i return nil, common.NewError("connection_write_error", "Error writing the connection meta data") } - result := &UploadResult{} + result := &blobberHTTP.UploadResult{} result.Filename = new_name result.Hash = objectRef.Hash result.MerkleRoot = objectRef.MerkleRoot @@ -853,7 +855,7 @@ func (fsh *StorageHandler) CopyObject(ctx context.Context, r *http.Request) (int return nil, common.NewError("connection_write_error", "Error writing the connection meta data") } - result := &UploadResult{} + result := &blobberHTTP.UploadResult{} result.Filename = objectRef.Name result.Hash = objectRef.Hash result.MerkleRoot = objectRef.MerkleRoot @@ -862,7 +864,7 @@ func (fsh *StorageHandler) CopyObject(ctx context.Context, r *http.Request) (int return result, nil } -func (fsh *StorageHandler) DeleteFile(ctx context.Context, r *http.Request, connectionObj *allocation.AllocationChangeCollector) (*UploadResult, error) { +func (fsh *StorageHandler) DeleteFile(ctx context.Context, r *http.Request, connectionObj *allocation.AllocationChangeCollector) (*blobberHTTP.UploadResult, error) { path := r.FormValue("path") if len(path) == 0 { return nil, common.NewError("invalid_parameters", "Invalid path") @@ -884,7 +886,7 @@ func (fsh *StorageHandler) DeleteFile(ctx context.Context, r *http.Request, conn connectionObj.Size += allocationChange.Size connectionObj.AddChange(allocationChange, dfc) - result := &UploadResult{} + result := &blobberHTTP.UploadResult{} result.Filename = fileRef.Name result.Hash = fileRef.Hash result.MerkleRoot = fileRef.MerkleRoot @@ -897,7 +899,7 @@ func (fsh *StorageHandler) DeleteFile(ctx context.Context, r *http.Request, conn } //WriteFile stores the file into the blobber files system from the HTTP request -func (fsh *StorageHandler) WriteFile(ctx context.Context, r *http.Request) (*UploadResult, error) { +func (fsh *StorageHandler) WriteFile(ctx context.Context, r *http.Request) (*blobberHTTP.UploadResult, error) { if r.Method == "GET" { return nil, common.NewError("invalid_method", "Invalid method used for the upload URL. Use multi-part form POST / PUT / DELETE instead") @@ -941,7 +943,7 @@ func (fsh *StorageHandler) WriteFile(ctx context.Context, r *http.Request) (*Upl mutex.Lock() defer mutex.Unlock() - result := &UploadResult{} + result := &blobberHTTP.UploadResult{} mode := allocation.INSERT_OPERATION if r.Method == "PUT" { mode = allocation.UPDATE_OPERATION diff --git a/code/go/0chain.net/blobbercore/handler/storage_handler.go b/code/go/0chain.net/blobbercore/handler/storage_handler.go index 58c7f778a..20c593ba0 100644 --- a/code/go/0chain.net/blobbercore/handler/storage_handler.go +++ b/code/go/0chain.net/blobbercore/handler/storage_handler.go @@ -7,6 +7,8 @@ import ( "strconv" "strings" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberHTTP" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" @@ -388,7 +390,7 @@ func (fsh *StorageHandler) GetFileStats(ctx context.Context, r *http.Request) (i return result, nil } -func (fsh *StorageHandler) ListEntities(ctx context.Context, r *http.Request) (*ListResult, error) { +func (fsh *StorageHandler) ListEntities(ctx context.Context, r *http.Request) (*blobberHTTP.ListResult, error) { if r.Method == "POST" { return nil, common.NewError("invalid_method", "Invalid method used. Use GET instead") @@ -433,7 +435,7 @@ func (fsh *StorageHandler) ListEntities(ctx context.Context, r *http.Request) (* return nil, common.NewError("invalid_parameters", "Invalid path. "+err.Error()) } - var result ListResult + var result blobberHTTP.ListResult result.AllocationRoot = allocationObj.AllocationRoot result.Meta = dirref.GetListingData(ctx) if clientID != allocationObj.OwnerID { @@ -450,8 +452,8 @@ func (fsh *StorageHandler) ListEntities(ctx context.Context, r *http.Request) (* return &result, nil } -func (fsh *StorageHandler) GetReferencePath(ctx context.Context, r *http.Request) (*ReferencePathResult, error) { - resCh := make(chan *ReferencePathResult) +func (fsh *StorageHandler) GetReferencePath(ctx context.Context, r *http.Request) (*blobberHTTP.ReferencePathResult, error) { + resCh := make(chan *blobberHTTP.ReferencePathResult) errCh := make(chan error) go fsh.getReferencePath(ctx, r, resCh, errCh) @@ -467,7 +469,7 @@ func (fsh *StorageHandler) GetReferencePath(ctx context.Context, r *http.Request } } -func (fsh *StorageHandler) getReferencePath(ctx context.Context, r *http.Request, resCh chan<- *ReferencePathResult, errCh chan<- error) { +func (fsh *StorageHandler) getReferencePath(ctx context.Context, r *http.Request, resCh chan<- *blobberHTTP.ReferencePathResult, errCh chan<- error) { if r.Method == "POST" { errCh <- common.NewError("invalid_method", "Invalid method used. Use GET instead") return @@ -506,17 +508,17 @@ func (fsh *StorageHandler) getReferencePath(ctx context.Context, r *http.Request return } - refPath := &ReferencePath{ref: rootRef} - refsToProcess := make([]*ReferencePath, 0) + refPath := &reference.ReferencePath{Ref: rootRef} + refsToProcess := make([]*reference.ReferencePath, 0) refsToProcess = append(refsToProcess, refPath) for len(refsToProcess) > 0 { refToProcess := refsToProcess[0] - refToProcess.Meta = refToProcess.ref.GetListingData(ctx) - if len(refToProcess.ref.Children) > 0 { - refToProcess.List = make([]*ReferencePath, len(refToProcess.ref.Children)) + refToProcess.Meta = refToProcess.Ref.GetListingData(ctx) + if len(refToProcess.Ref.Children) > 0 { + refToProcess.List = make([]*reference.ReferencePath, len(refToProcess.Ref.Children)) } - for idx, child := range refToProcess.ref.Children { - childRefPath := &ReferencePath{ref: child} + for idx, child := range refToProcess.Ref.Children { + childRefPath := &reference.ReferencePath{Ref: child} refToProcess.List[idx] = childRefPath refsToProcess = append(refsToProcess, childRefPath) } @@ -533,7 +535,7 @@ func (fsh *StorageHandler) getReferencePath(ctx context.Context, r *http.Request return } } - var refPathResult ReferencePathResult + var refPathResult blobberHTTP.ReferencePathResult refPathResult.ReferencePath = refPath if latestWM != nil { refPathResult.LatestWM = &latestWM.WM @@ -542,7 +544,7 @@ func (fsh *StorageHandler) getReferencePath(ctx context.Context, r *http.Request resCh <- &refPathResult } -func (fsh *StorageHandler) GetObjectPath(ctx context.Context, r *http.Request) (*ObjectPathResult, error) { +func (fsh *StorageHandler) GetObjectPath(ctx context.Context, r *http.Request) (*blobberHTTP.ObjectPathResult, error) { if r.Method == "POST" { return nil, common.NewError("invalid_method", "Invalid method used. Use GET instead") } @@ -592,7 +594,7 @@ func (fsh *StorageHandler) GetObjectPath(ctx context.Context, r *http.Request) ( return nil, common.NewError("latest_write_marker_read_error", "Error reading the latest write marker for allocation."+err.Error()) } } - var objPathResult ObjectPathResult + var objPathResult blobberHTTP.ObjectPathResult objPathResult.ObjectPath = objectPath if latestWM != nil { objPathResult.LatestWM = &latestWM.WM @@ -600,7 +602,7 @@ func (fsh *StorageHandler) GetObjectPath(ctx context.Context, r *http.Request) ( return &objPathResult, nil } -func (fsh *StorageHandler) GetObjectTree(ctx context.Context, r *http.Request) (*ReferencePathResult, error) { +func (fsh *StorageHandler) GetObjectTree(ctx context.Context, r *http.Request) (*blobberHTTP.ReferencePathResult, error) { if r.Method == "POST" { return nil, common.NewError("invalid_method", "Invalid method used. Use GET instead") } @@ -632,17 +634,17 @@ func (fsh *StorageHandler) GetObjectTree(ctx context.Context, r *http.Request) ( return nil, err } - refPath := &ReferencePath{ref: rootRef} - refsToProcess := make([]*ReferencePath, 0) + refPath := &reference.ReferencePath{Ref: rootRef} + refsToProcess := make([]*reference.ReferencePath, 0) refsToProcess = append(refsToProcess, refPath) for len(refsToProcess) > 0 { refToProcess := refsToProcess[0] - refToProcess.Meta = refToProcess.ref.GetListingData(ctx) - if len(refToProcess.ref.Children) > 0 { - refToProcess.List = make([]*ReferencePath, len(refToProcess.ref.Children)) + refToProcess.Meta = refToProcess.Ref.GetListingData(ctx) + if len(refToProcess.Ref.Children) > 0 { + refToProcess.List = make([]*reference.ReferencePath, len(refToProcess.Ref.Children)) } - for idx, child := range refToProcess.ref.Children { - childRefPath := &ReferencePath{ref: child} + for idx, child := range refToProcess.Ref.Children { + childRefPath := &reference.ReferencePath{Ref: child} refToProcess.List[idx] = childRefPath refsToProcess = append(refsToProcess, childRefPath) } @@ -658,7 +660,7 @@ func (fsh *StorageHandler) GetObjectTree(ctx context.Context, r *http.Request) ( return nil, common.NewError("latest_write_marker_read_error", "Error reading the latest write marker for allocation."+err.Error()) } } - var refPathResult ReferencePathResult + var refPathResult blobberHTTP.ReferencePathResult refPathResult.ReferencePath = refPath if latestWM != nil { refPathResult.LatestWM = &latestWM.WM diff --git a/code/go/0chain.net/blobbercore/reference/objectpath.go b/code/go/0chain.net/blobbercore/reference/objectpath.go index 6870f014b..3712b86e7 100644 --- a/code/go/0chain.net/blobbercore/reference/objectpath.go +++ b/code/go/0chain.net/blobbercore/reference/objectpath.go @@ -3,9 +3,6 @@ package reference import ( "context" "fmt" - "time" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/core/common" ) @@ -90,143 +87,3 @@ func GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*O return &retObj, nil } - -func FileRefToFileRefGRPC(ref *Ref) *blobbergrpc.FileRef { - if ref == nil { - return nil - } - - var fileMetaData *blobbergrpc.FileMetaData - var dirMetaData *blobbergrpc.DirMetaData - switch ref.Type { - case FILE: - fileMetaData = convertFileRefToFileMetaDataGRPC(ref) - case DIRECTORY: - dirMetaData = convertDirRefToDirMetaDataGRPC(ref) - } - - return &blobbergrpc.FileRef{ - Type: ref.Type, - FileMetaData: fileMetaData, - DirMetaData: dirMetaData, - } -} - -func convertFileRefToFileMetaDataGRPC(fileref *Ref) *blobbergrpc.FileMetaData { - var commitMetaTxnsGRPC []*blobbergrpc.CommitMetaTxn - for _, c := range fileref.CommitMetaTxns { - commitMetaTxnsGRPC = append(commitMetaTxnsGRPC, &blobbergrpc.CommitMetaTxn{ - RefId: c.RefID, - TxnId: c.TxnID, - CreatedAt: c.CreatedAt.UnixNano(), - }) - } - return &blobbergrpc.FileMetaData{ - Type: fileref.Type, - LookupHash: fileref.LookupHash, - Name: fileref.Name, - Path: fileref.Path, - Hash: fileref.Hash, - NumBlocks: fileref.NumBlocks, - PathHash: fileref.PathHash, - CustomMeta: fileref.CustomMeta, - ContentHash: fileref.ContentHash, - Size: fileref.Size, - MerkleRoot: fileref.MerkleRoot, - ActualFileSize: fileref.ActualFileSize, - ActualFileHash: fileref.ActualFileHash, - MimeType: fileref.MimeType, - ThumbnailSize: fileref.ThumbnailSize, - ThumbnailHash: fileref.ThumbnailHash, - ActualThumbnailSize: fileref.ActualThumbnailSize, - ActualThumbnailHash: fileref.ActualThumbnailHash, - EncryptedKey: fileref.EncryptedKey, - Attributes: fileref.Attributes, - OnCloud: fileref.OnCloud, - CommitMetaTxns: commitMetaTxnsGRPC, - CreatedAt: fileref.CreatedAt.UnixNano(), - UpdatedAt: fileref.UpdatedAt.UnixNano(), - } -} - -func convertDirRefToDirMetaDataGRPC(dirref *Ref) *blobbergrpc.DirMetaData { - return &blobbergrpc.DirMetaData{ - Type: dirref.Type, - LookupHash: dirref.LookupHash, - Name: dirref.Name, - Path: dirref.Path, - Hash: dirref.Hash, - NumBlocks: dirref.NumBlocks, - PathHash: dirref.PathHash, - Size: dirref.Size, - CreatedAt: dirref.CreatedAt.UnixNano(), - UpdatedAt: dirref.UpdatedAt.UnixNano(), - } -} - -func FileRefGRPCToFileRef(ref *blobbergrpc.FileRef) *Ref { - if ref == nil { - return nil - } - - switch ref.Type { - case FILE: - return convertFileMetaDataGRPCToFileRef(ref.FileMetaData) - case DIRECTORY: - return convertDirMetaDataGRPCToDirRef(ref.DirMetaData) - } - - return nil -} - -func convertFileMetaDataGRPCToFileRef(metaData *blobbergrpc.FileMetaData) *Ref { - var commitMetaTxnsGRPC []CommitMetaTxn - for _, c := range metaData.CommitMetaTxns { - commitMetaTxnsGRPC = append(commitMetaTxnsGRPC, CommitMetaTxn{ - RefID: c.RefId, - TxnID: c.TxnId, - CreatedAt: time.Unix(0, c.CreatedAt), - }) - } - return &Ref{ - Type: metaData.Type, - LookupHash: metaData.LookupHash, - Name: metaData.Name, - Path: metaData.Path, - Hash: metaData.Hash, - NumBlocks: metaData.NumBlocks, - PathHash: metaData.PathHash, - CustomMeta: metaData.CustomMeta, - ContentHash: metaData.ContentHash, - Size: metaData.Size, - MerkleRoot: metaData.MerkleRoot, - ActualFileSize: metaData.ActualFileSize, - ActualFileHash: metaData.ActualFileHash, - MimeType: metaData.MimeType, - ThumbnailSize: metaData.ThumbnailSize, - ThumbnailHash: metaData.ThumbnailHash, - ActualThumbnailSize: metaData.ActualThumbnailSize, - ActualThumbnailHash: metaData.ActualThumbnailHash, - EncryptedKey: metaData.EncryptedKey, - Attributes: metaData.Attributes, - OnCloud: metaData.OnCloud, - CommitMetaTxns: commitMetaTxnsGRPC, - CreatedAt: time.Unix(0, metaData.CreatedAt), - UpdatedAt: time.Unix(0, metaData.UpdatedAt), - } -} - -func convertDirMetaDataGRPCToDirRef(dirref *blobbergrpc.DirMetaData) *Ref { - return &Ref{ - Type: dirref.Type, - LookupHash: dirref.LookupHash, - Name: dirref.Name, - Path: dirref.Path, - Hash: dirref.Hash, - NumBlocks: dirref.NumBlocks, - PathHash: dirref.PathHash, - Size: dirref.Size, - CreatedAt: time.Unix(0, dirref.CreatedAt), - UpdatedAt: time.Unix(0, dirref.UpdatedAt), - } -} diff --git a/code/go/0chain.net/blobbercore/reference/referencepath.go b/code/go/0chain.net/blobbercore/reference/referencepath.go index cf1e1ab79..4103d8dc0 100644 --- a/code/go/0chain.net/blobbercore/reference/referencepath.go +++ b/code/go/0chain.net/blobbercore/reference/referencepath.go @@ -8,6 +8,12 @@ import ( "github.com/0chain/blobber/code/go/0chain.net/core/common" ) +type ReferencePath struct { + Meta map[string]interface{} `json:"meta_data"` + List []*ReferencePath `json:"list,omitempty"` + Ref *Ref +} + func GetReferencePath(ctx context.Context, allocationID string, path string) (*Ref, error) { return GetReferencePathFromPaths(ctx, allocationID, []string{path}) } From 1f7d3c36885121946d8d7afa6eab5135bb838385 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sat, 22 May 2021 21:47:52 +0530 Subject: [PATCH 036/183] added integration test to make file to fix github action --- Makefile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 79477b07b..ef5d2f84d 100644 --- a/Makefile +++ b/Makefile @@ -4,4 +4,7 @@ test: go test ./...; lint: - golangci-lint run; \ No newline at end of file + golangci-lint run; + +integration-tests: + go test ./... -args integration; \ No newline at end of file From caf3733c0bea8a9d50d88e51fa96b7a76ae39dab Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 23 May 2021 11:51:25 +0530 Subject: [PATCH 037/183] :art: simplified test implementation --- .../handler/grpc_handler_helper_unit_test.go | 22 +++++++++++++++++++ .../handler/grpc_handler_integration_test.go | 20 +++-------------- 2 files changed, 25 insertions(+), 17 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index bc8e50864..0b286f5e1 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -5,8 +5,13 @@ import ( "database/sql" "fmt" "log" + "os" + "strings" "time" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/spf13/viper" + "testing" "gorm.io/gorm" @@ -484,3 +489,20 @@ func GeneratePubPrivateKey(t *testing.T) (string, string, zcncrypto.SignatureSch return keyPair.PublicKey, keyPair.PrivateKey, signScheme } + +func setupIntegrationTestConfig(t *testing.T) { + + pwd, err := os.Getwd() + if err != nil { + t.Fatal(err) + } + configDir := strings.Split(pwd, "/code/go")[0] + "/config" + config.SetupDefaultConfig() + config.SetupConfig(configDir) + + config.Configuration.DBHost = "localhost" + config.Configuration.DBName = viper.GetString("db.name") + config.Configuration.DBPort = viper.GetString("db.port") + config.Configuration.DBUserName = viper.GetString("db.user") + config.Configuration.DBPassword = viper.GetString("db.password") +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 107c1a5e5..bde386249 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -5,7 +5,6 @@ import ( "fmt" "log" "os" - "strings" "testing" "time" @@ -15,8 +14,6 @@ import ( "github.com/0chain/blobber/code/go/0chain.net/core/encryption" - "github.com/spf13/viper" - "gorm.io/driver/postgres" "gorm.io/gorm" @@ -25,7 +22,7 @@ import ( "google.golang.org/grpc" ) -const BlobberAddr = "localhost:7031" +const BlobberTestAddr = "localhost:7031" const RetryAttempts = 8 const RetryTimeout = 3 @@ -42,7 +39,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { var err error for i := 0; i < RetryAttempts; i++ { log.Println("Connection attempt - " + fmt.Sprint(i+1)) - conn, err = grpc.Dial(BlobberAddr, grpc.WithInsecure()) + conn, err = grpc.Dial(BlobberTestAddr, grpc.WithInsecure()) if err != nil { log.Println(err) <-time.After(time.Second * RetryTimeout) @@ -56,18 +53,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { defer conn.Close() blobberClient := blobbergrpc.NewBlobberClient(conn) - pwd, err := os.Getwd() - if err != nil { - t.Fatal(err) - } - configDir := strings.Split(pwd, "/code/go")[0] + "/config" - config.SetupDefaultConfig() - config.SetupConfig(configDir) - config.Configuration.DBHost = "localhost" - config.Configuration.DBName = viper.GetString("db.name") - config.Configuration.DBPort = viper.GetString("db.port") - config.Configuration.DBUserName = viper.GetString("db.user") - config.Configuration.DBPassword = viper.GetString("db.password") + setupIntegrationTestConfig(t) db, err := gorm.Open(postgres.Open(fmt.Sprintf( "host=%v port=%v user=%v dbname=%v password=%v sslmode=disable", config.Configuration.DBHost, config.Configuration.DBPort, From 02da8de06f6723dd6fcb92af493fbbd5262cb670 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 23 May 2021 11:53:56 +0530 Subject: [PATCH 038/183] :green_heart: remove uneeded github actions --- .github/workflows/ci.yml | 33 +-------------------------------- 1 file changed, 1 insertion(+), 32 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5b23a7f6a..d67c9f1ce 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,7 @@ env: VALIDATOR_REGISTRY: ${{ secrets.VALIDATOR_REGISTRY }} jobs: - integration-tests: + build-and-test: runs-on: ubuntu-20.04 steps: - name: Install Go @@ -34,37 +34,6 @@ jobs: ../bin/blobber.start_bls.sh /dev/null & cd ../.. make integration-tests - - build: - runs-on: ubuntu-20.04 - steps: - - name: Install Go - uses: actions/setup-go@v2 - with: - go-version: 1.14.x - - uses: actions/checkout@v2 - # In this step, this action saves a list of existing images, - # the cache is created without them in the post run. - # It also restores the cache if it exists. - - uses: satackey/action-docker-layer-caching@v0.0.11 - # Ignore the failure of a step and avoid terminating the job. - continue-on-error: true - - name: Build - run: | - docker network create --driver=bridge --subnet=198.18.0.0/15 --gateway=198.18.0.255 testnet0 - ./docker.local/bin/build.blobber.sh - - test: - runs-on: ubuntu-20.04 - steps: - - name: Install Go - uses: actions/setup-go@v2 - with: - go-version: 1.14.x - - uses: actions/checkout@v2 - - name: Test - run: make test - lint: runs-on: ubuntu-20.04 steps: From 71e06a30c9647800c2e23a7476f9ab76fa54c009 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 23 May 2021 11:56:03 +0530 Subject: [PATCH 039/183] :green_heart: renamed github action to test --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d67c9f1ce..2e913f0ba 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,7 @@ env: VALIDATOR_REGISTRY: ${{ secrets.VALIDATOR_REGISTRY }} jobs: - build-and-test: + test: runs-on: ubuntu-20.04 steps: - name: Install Go From 0505a3ea9b7fd7c6bacf069a45a5fe52dce924f6 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 23 May 2021 19:13:13 +0530 Subject: [PATCH 040/183] :sparkles: added grpc equivalent of commit api --- .../blobbercore/blobbergrpc/blobber.pb.go | 1251 ++++++++++------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 117 ++ .../blobbergrpc/blobber_grpc.pb.go | 36 + .../blobbergrpc/proto/blobber.proto | 19 + .../blobbercore/convert/responseHandler.go | 9 + .../handler/grpc_commit_handler.go | 187 +++ .../0chain.net/blobbercore/handler/handler.go | 22 +- .../blobbercore/openapi/blobber.swagger.json | 59 + 8 files changed, 1162 insertions(+), 538 deletions(-) create mode 100644 code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 2d21e6a7b..476bb94ec 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -21,6 +21,140 @@ const ( _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) +type CommitRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` + ConnectionId string `protobuf:"bytes,2,opt,name=connection_id,json=connectionId,proto3" json:"connection_id,omitempty"` + WriteMarker string `protobuf:"bytes,3,opt,name=write_marker,json=writeMarker,proto3" json:"write_marker,omitempty"` +} + +func (x *CommitRequest) Reset() { + *x = CommitRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitRequest) ProtoMessage() {} + +func (x *CommitRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_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 CommitRequest.ProtoReflect.Descriptor instead. +func (*CommitRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{0} +} + +func (x *CommitRequest) GetAllocation() string { + if x != nil { + return x.Allocation + } + return "" +} + +func (x *CommitRequest) GetConnectionId() string { + if x != nil { + return x.ConnectionId + } + return "" +} + +func (x *CommitRequest) GetWriteMarker() string { + if x != nil { + return x.WriteMarker + } + return "" +} + +type CommitResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + AllocationRoot string `protobuf:"bytes,1,opt,name=allocation_root,json=allocationRoot,proto3" json:"allocation_root,omitempty"` + WriteMarker *WriteMarker `protobuf:"bytes,2,opt,name=write_marker,json=writeMarker,proto3" json:"write_marker,omitempty"` + ErrorMessage string `protobuf:"bytes,3,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"` + Success bool `protobuf:"varint,4,opt,name=success,proto3" json:"success,omitempty"` +} + +func (x *CommitResponse) Reset() { + *x = CommitResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitResponse) ProtoMessage() {} + +func (x *CommitResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[1] + 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 CommitResponse.ProtoReflect.Descriptor instead. +func (*CommitResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{1} +} + +func (x *CommitResponse) GetAllocationRoot() string { + if x != nil { + return x.AllocationRoot + } + return "" +} + +func (x *CommitResponse) GetWriteMarker() *WriteMarker { + if x != nil { + return x.WriteMarker + } + return nil +} + +func (x *CommitResponse) GetErrorMessage() string { + if x != nil { + return x.ErrorMessage + } + return "" +} + +func (x *CommitResponse) GetSuccess() bool { + if x != nil { + return x.Success + } + return false +} + type GetObjectTreeRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -33,7 +167,7 @@ type GetObjectTreeRequest struct { func (x *GetObjectTreeRequest) Reset() { *x = GetObjectTreeRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[0] + mi := &file_blobber_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -46,7 +180,7 @@ func (x *GetObjectTreeRequest) String() string { func (*GetObjectTreeRequest) ProtoMessage() {} func (x *GetObjectTreeRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[0] + mi := &file_blobber_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -59,7 +193,7 @@ func (x *GetObjectTreeRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectTreeRequest.ProtoReflect.Descriptor instead. func (*GetObjectTreeRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{0} + return file_blobber_proto_rawDescGZIP(), []int{2} } func (x *GetObjectTreeRequest) GetPath() string { @@ -88,7 +222,7 @@ type GetObjectTreeResponse struct { func (x *GetObjectTreeResponse) Reset() { *x = GetObjectTreeResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[1] + mi := &file_blobber_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -101,7 +235,7 @@ func (x *GetObjectTreeResponse) String() string { func (*GetObjectTreeResponse) ProtoMessage() {} func (x *GetObjectTreeResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[1] + mi := &file_blobber_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -114,7 +248,7 @@ func (x *GetObjectTreeResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectTreeResponse.ProtoReflect.Descriptor instead. func (*GetObjectTreeResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{1} + return file_blobber_proto_rawDescGZIP(), []int{3} } func (x *GetObjectTreeResponse) GetReferencePath() *ReferencePath { @@ -144,7 +278,7 @@ type GetReferencePathRequest struct { func (x *GetReferencePathRequest) Reset() { *x = GetReferencePathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[2] + mi := &file_blobber_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -157,7 +291,7 @@ func (x *GetReferencePathRequest) String() string { func (*GetReferencePathRequest) ProtoMessage() {} func (x *GetReferencePathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[2] + mi := &file_blobber_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -170,7 +304,7 @@ func (x *GetReferencePathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReferencePathRequest.ProtoReflect.Descriptor instead. func (*GetReferencePathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{2} + return file_blobber_proto_rawDescGZIP(), []int{4} } func (x *GetReferencePathRequest) GetPaths() string { @@ -206,7 +340,7 @@ type GetReferencePathResponse struct { func (x *GetReferencePathResponse) Reset() { *x = GetReferencePathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[3] + mi := &file_blobber_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -219,7 +353,7 @@ func (x *GetReferencePathResponse) String() string { func (*GetReferencePathResponse) ProtoMessage() {} func (x *GetReferencePathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[3] + mi := &file_blobber_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -232,7 +366,7 @@ func (x *GetReferencePathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReferencePathResponse.ProtoReflect.Descriptor instead. func (*GetReferencePathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{3} + return file_blobber_proto_rawDescGZIP(), []int{5} } func (x *GetReferencePathResponse) GetReferencePath() *ReferencePath { @@ -261,7 +395,7 @@ type ReferencePath struct { func (x *ReferencePath) Reset() { *x = ReferencePath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -274,7 +408,7 @@ func (x *ReferencePath) String() string { func (*ReferencePath) ProtoMessage() {} func (x *ReferencePath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -287,7 +421,7 @@ func (x *ReferencePath) ProtoReflect() protoreflect.Message { // Deprecated: Use ReferencePath.ProtoReflect.Descriptor instead. func (*ReferencePath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{4} + return file_blobber_proto_rawDescGZIP(), []int{6} } func (x *ReferencePath) GetMetaData() *FileRef { @@ -317,7 +451,7 @@ type GetObjectPathRequest struct { func (x *GetObjectPathRequest) Reset() { *x = GetObjectPathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -330,7 +464,7 @@ func (x *GetObjectPathRequest) String() string { func (*GetObjectPathRequest) ProtoMessage() {} func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -343,7 +477,7 @@ func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathRequest.ProtoReflect.Descriptor instead. func (*GetObjectPathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{5} + return file_blobber_proto_rawDescGZIP(), []int{7} } func (x *GetObjectPathRequest) GetAllocation() string { @@ -379,7 +513,7 @@ type GetObjectPathResponse struct { func (x *GetObjectPathResponse) Reset() { *x = GetObjectPathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -392,7 +526,7 @@ func (x *GetObjectPathResponse) String() string { func (*GetObjectPathResponse) ProtoMessage() {} func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -405,7 +539,7 @@ func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathResponse.ProtoReflect.Descriptor instead. func (*GetObjectPathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{6} + return file_blobber_proto_rawDescGZIP(), []int{8} } func (x *GetObjectPathResponse) GetObjectPath() *ObjectPath { @@ -437,7 +571,7 @@ type ObjectPath struct { func (x *ObjectPath) Reset() { *x = ObjectPath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -450,7 +584,7 @@ func (x *ObjectPath) String() string { func (*ObjectPath) ProtoMessage() {} func (x *ObjectPath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -463,7 +597,7 @@ func (x *ObjectPath) ProtoReflect() protoreflect.Message { // Deprecated: Use ObjectPath.ProtoReflect.Descriptor instead. func (*ObjectPath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{7} + return file_blobber_proto_rawDescGZIP(), []int{9} } func (x *ObjectPath) GetRootHash() string { @@ -519,7 +653,7 @@ type WriteMarker struct { func (x *WriteMarker) Reset() { *x = WriteMarker{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -532,7 +666,7 @@ func (x *WriteMarker) String() string { func (*WriteMarker) ProtoMessage() {} func (x *WriteMarker) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -545,7 +679,7 @@ func (x *WriteMarker) ProtoReflect() protoreflect.Message { // Deprecated: Use WriteMarker.ProtoReflect.Descriptor instead. func (*WriteMarker) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{8} + return file_blobber_proto_rawDescGZIP(), []int{10} } func (x *WriteMarker) GetAllocationRoot() string { @@ -618,7 +752,7 @@ type ListEntitiesRequest struct { func (x *ListEntitiesRequest) Reset() { *x = ListEntitiesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -631,7 +765,7 @@ func (x *ListEntitiesRequest) String() string { func (*ListEntitiesRequest) ProtoMessage() {} func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -644,7 +778,7 @@ func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ListEntitiesRequest.ProtoReflect.Descriptor instead. func (*ListEntitiesRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{9} + return file_blobber_proto_rawDescGZIP(), []int{11} } func (x *ListEntitiesRequest) GetPath() string { @@ -688,7 +822,7 @@ type ListEntitiesResponse struct { func (x *ListEntitiesResponse) Reset() { *x = ListEntitiesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[10] + mi := &file_blobber_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -701,7 +835,7 @@ func (x *ListEntitiesResponse) String() string { func (*ListEntitiesResponse) ProtoMessage() {} func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[10] + mi := &file_blobber_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -714,7 +848,7 @@ func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ListEntitiesResponse.ProtoReflect.Descriptor instead. func (*ListEntitiesResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{10} + return file_blobber_proto_rawDescGZIP(), []int{12} } func (x *ListEntitiesResponse) GetAllocationRoot() string { @@ -751,7 +885,7 @@ type GetFileStatsRequest struct { func (x *GetFileStatsRequest) Reset() { *x = GetFileStatsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -764,7 +898,7 @@ func (x *GetFileStatsRequest) String() string { func (*GetFileStatsRequest) ProtoMessage() {} func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -777,7 +911,7 @@ func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileStatsRequest.ProtoReflect.Descriptor instead. func (*GetFileStatsRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{11} + return file_blobber_proto_rawDescGZIP(), []int{13} } func (x *GetFileStatsRequest) GetPath() string { @@ -813,7 +947,7 @@ type GetFileStatsResponse struct { func (x *GetFileStatsResponse) Reset() { *x = GetFileStatsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -826,7 +960,7 @@ func (x *GetFileStatsResponse) String() string { func (*GetFileStatsResponse) ProtoMessage() {} func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -839,7 +973,7 @@ func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileStatsResponse.ProtoReflect.Descriptor instead. func (*GetFileStatsResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{12} + return file_blobber_proto_rawDescGZIP(), []int{14} } func (x *GetFileStatsResponse) GetMetaData() *FileRef { @@ -876,7 +1010,7 @@ type FileStats struct { func (x *FileStats) Reset() { *x = FileStats{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -889,7 +1023,7 @@ func (x *FileStats) String() string { func (*FileStats) ProtoMessage() {} func (x *FileStats) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -902,7 +1036,7 @@ func (x *FileStats) ProtoReflect() protoreflect.Message { // Deprecated: Use FileStats.ProtoReflect.Descriptor instead. func (*FileStats) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{13} + return file_blobber_proto_rawDescGZIP(), []int{15} } func (x *FileStats) GetID() int64 { @@ -989,7 +1123,7 @@ type GetFileMetaDataRequest struct { func (x *GetFileMetaDataRequest) Reset() { *x = GetFileMetaDataRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[14] + mi := &file_blobber_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1002,7 +1136,7 @@ func (x *GetFileMetaDataRequest) String() string { func (*GetFileMetaDataRequest) ProtoMessage() {} func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[14] + mi := &file_blobber_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1015,7 +1149,7 @@ func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileMetaDataRequest.ProtoReflect.Descriptor instead. func (*GetFileMetaDataRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{14} + return file_blobber_proto_rawDescGZIP(), []int{16} } func (x *GetFileMetaDataRequest) GetPath() string { @@ -1058,7 +1192,7 @@ type GetFileMetaDataResponse struct { func (x *GetFileMetaDataResponse) Reset() { *x = GetFileMetaDataResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[15] + mi := &file_blobber_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1071,7 +1205,7 @@ func (x *GetFileMetaDataResponse) String() string { func (*GetFileMetaDataResponse) ProtoMessage() {} func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[15] + mi := &file_blobber_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1084,7 +1218,7 @@ func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileMetaDataResponse.ProtoReflect.Descriptor instead. func (*GetFileMetaDataResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{15} + return file_blobber_proto_rawDescGZIP(), []int{17} } func (x *GetFileMetaDataResponse) GetMetaData() *FileRef { @@ -1114,7 +1248,7 @@ type CommitMetaTxn struct { func (x *CommitMetaTxn) Reset() { *x = CommitMetaTxn{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[16] + mi := &file_blobber_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1127,7 +1261,7 @@ func (x *CommitMetaTxn) String() string { func (*CommitMetaTxn) ProtoMessage() {} func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[16] + mi := &file_blobber_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1140,7 +1274,7 @@ func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { // Deprecated: Use CommitMetaTxn.ProtoReflect.Descriptor instead. func (*CommitMetaTxn) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{16} + return file_blobber_proto_rawDescGZIP(), []int{18} } func (x *CommitMetaTxn) GetRefId() int64 { @@ -1177,7 +1311,7 @@ type Collaborator struct { func (x *Collaborator) Reset() { *x = Collaborator{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[17] + mi := &file_blobber_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1190,7 +1324,7 @@ func (x *Collaborator) String() string { func (*Collaborator) ProtoMessage() {} func (x *Collaborator) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[17] + mi := &file_blobber_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1203,7 +1337,7 @@ func (x *Collaborator) ProtoReflect() protoreflect.Message { // Deprecated: Use Collaborator.ProtoReflect.Descriptor instead. func (*Collaborator) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{17} + return file_blobber_proto_rawDescGZIP(), []int{19} } func (x *Collaborator) GetRefId() int64 { @@ -1238,7 +1372,7 @@ type GetAllocationRequest struct { func (x *GetAllocationRequest) Reset() { *x = GetAllocationRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[18] + mi := &file_blobber_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1251,7 +1385,7 @@ func (x *GetAllocationRequest) String() string { func (*GetAllocationRequest) ProtoMessage() {} func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[18] + mi := &file_blobber_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1264,7 +1398,7 @@ func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationRequest.ProtoReflect.Descriptor instead. func (*GetAllocationRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{18} + return file_blobber_proto_rawDescGZIP(), []int{20} } func (x *GetAllocationRequest) GetId() string { @@ -1285,7 +1419,7 @@ type GetAllocationResponse struct { func (x *GetAllocationResponse) Reset() { *x = GetAllocationResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1298,7 +1432,7 @@ func (x *GetAllocationResponse) String() string { func (*GetAllocationResponse) ProtoMessage() {} func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1311,7 +1445,7 @@ func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationResponse.ProtoReflect.Descriptor instead. func (*GetAllocationResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{19} + return file_blobber_proto_rawDescGZIP(), []int{21} } func (x *GetAllocationResponse) GetAllocation() *Allocation { @@ -1348,7 +1482,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1361,7 +1495,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1374,7 +1508,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{22} } func (x *Allocation) GetID() string { @@ -1511,7 +1645,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1524,7 +1658,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1537,7 +1671,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{23} } func (x *Term) GetID() int64 { @@ -1588,7 +1722,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1601,7 +1735,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1614,7 +1748,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{24} } func (x *FileRef) GetType() string { @@ -1672,7 +1806,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1685,7 +1819,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1698,7 +1832,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{23} + return file_blobber_proto_rawDescGZIP(), []int{25} } func (x *FileMetaData) GetType() string { @@ -1889,7 +2023,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1902,7 +2036,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1915,7 +2049,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{24} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *DirMetaData) GetType() string { @@ -1995,29 +2129,32 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x22, 0x4a, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, - 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, - 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, - 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, - 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, - 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, - 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, - 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, - 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x6f, 0x22, 0x77, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, + 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x21, 0x0a, 0x0c, 0x77, 0x72, 0x69, 0x74, 0x65, + 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x77, + 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xbc, 0x01, 0x0a, 0x0e, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x27, 0x0a, + 0x0f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x6f, 0x6f, 0x74, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x42, 0x0a, 0x0c, 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, + 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x0b, 0x77, + 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x23, 0x0a, 0x0d, 0x65, 0x72, + 0x72, 0x6f, 0x72, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0c, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, + 0x18, 0x0a, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x22, 0x4a, 0x0a, 0x14, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, @@ -2026,351 +2163,376 @@ var file_blobber_proto_rawDesc = []byte{ 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, - 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, - 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, - 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, - 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, - 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, - 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, - 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, - 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, + 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, + 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, + 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, + 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, + 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, + 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, - 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, - 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, - 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, - 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, - 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, - 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, - 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, - 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, - 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, - 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, - 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, - 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, - 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, - 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, - 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, - 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, - 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, - 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, - 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, - 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, - 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, - 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, - 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, - 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, - 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, - 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, - 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, - 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, - 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, - 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, - 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, - 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, - 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, - 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, - 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, - 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, - 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, - 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, - 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, - 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, - 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, - 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, - 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, - 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, - 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, - 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, - 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, - 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, - 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, + 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, + 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, + 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, + 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, + 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, + 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, + 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, + 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, + 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, + 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, + 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, + 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, + 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, + 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, + 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, + 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, + 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, + 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, + 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, + 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, + 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, + 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, + 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, + 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, + 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, + 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, + 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, + 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, + 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, + 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, + 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, + 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, + 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, + 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, + 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, + 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, + 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, + 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, + 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, + 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, + 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, + 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, + 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, + 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, + 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, + 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, + 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, + 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, + 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, + 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, + 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, + 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, + 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, + 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, + 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, + 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, + 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, + 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, + 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, + 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, + 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, + 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, + 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, + 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, + 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, + 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, + 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, + 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, + 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, + 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, + 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, + 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, + 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, + 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, - 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, - 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, - 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, - 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, - 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, - 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, - 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, - 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, - 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, - 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, - 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, - 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, - 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, - 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, + 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, + 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, + 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, + 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, + 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, + 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, + 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, + 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, + 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, + 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, + 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, + 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, + 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, + 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, + 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, + 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, + 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, + 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, + 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, + 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, + 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, + 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, + 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, + 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, + 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, + 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, + 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, + 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, + 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, + 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, + 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, + 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, + 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, + 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, + 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, + 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, + 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, + 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, + 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, + 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, + 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, + 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, + 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, + 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, + 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, + 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, + 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, + 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, + 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, + 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, + 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, + 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, + 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, + 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, + 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, + 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x32, 0xe5, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, + 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, + 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, + 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, + 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, + 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, + 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, + 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, + 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, + 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, + 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, - 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, + 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, + 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, + 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, + 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, + 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, + 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, + 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, + 0x7b, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x2a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x24, 0x12, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, + 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x2c, 0x5a, 0x2a, + 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, + 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x33, } var ( @@ -2385,76 +2547,81 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 25) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 27) var file_blobber_proto_goTypes = []interface{}{ - (*GetObjectTreeRequest)(nil), // 0: blobber.service.v1.GetObjectTreeRequest - (*GetObjectTreeResponse)(nil), // 1: blobber.service.v1.GetObjectTreeResponse - (*GetReferencePathRequest)(nil), // 2: blobber.service.v1.GetReferencePathRequest - (*GetReferencePathResponse)(nil), // 3: blobber.service.v1.GetReferencePathResponse - (*ReferencePath)(nil), // 4: blobber.service.v1.ReferencePath - (*GetObjectPathRequest)(nil), // 5: blobber.service.v1.GetObjectPathRequest - (*GetObjectPathResponse)(nil), // 6: blobber.service.v1.GetObjectPathResponse - (*ObjectPath)(nil), // 7: blobber.service.v1.ObjectPath - (*WriteMarker)(nil), // 8: blobber.service.v1.WriteMarker - (*ListEntitiesRequest)(nil), // 9: blobber.service.v1.ListEntitiesRequest - (*ListEntitiesResponse)(nil), // 10: blobber.service.v1.ListEntitiesResponse - (*GetFileStatsRequest)(nil), // 11: blobber.service.v1.GetFileStatsRequest - (*GetFileStatsResponse)(nil), // 12: blobber.service.v1.GetFileStatsResponse - (*FileStats)(nil), // 13: blobber.service.v1.FileStats - (*GetFileMetaDataRequest)(nil), // 14: blobber.service.v1.GetFileMetaDataRequest - (*GetFileMetaDataResponse)(nil), // 15: blobber.service.v1.GetFileMetaDataResponse - (*CommitMetaTxn)(nil), // 16: blobber.service.v1.CommitMetaTxn - (*Collaborator)(nil), // 17: blobber.service.v1.Collaborator - (*GetAllocationRequest)(nil), // 18: blobber.service.v1.GetAllocationRequest - (*GetAllocationResponse)(nil), // 19: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 20: blobber.service.v1.Allocation - (*Term)(nil), // 21: blobber.service.v1.Term - (*FileRef)(nil), // 22: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 23: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 24: blobber.service.v1.DirMetaData + (*CommitRequest)(nil), // 0: blobber.service.v1.CommitRequest + (*CommitResponse)(nil), // 1: blobber.service.v1.CommitResponse + (*GetObjectTreeRequest)(nil), // 2: blobber.service.v1.GetObjectTreeRequest + (*GetObjectTreeResponse)(nil), // 3: blobber.service.v1.GetObjectTreeResponse + (*GetReferencePathRequest)(nil), // 4: blobber.service.v1.GetReferencePathRequest + (*GetReferencePathResponse)(nil), // 5: blobber.service.v1.GetReferencePathResponse + (*ReferencePath)(nil), // 6: blobber.service.v1.ReferencePath + (*GetObjectPathRequest)(nil), // 7: blobber.service.v1.GetObjectPathRequest + (*GetObjectPathResponse)(nil), // 8: blobber.service.v1.GetObjectPathResponse + (*ObjectPath)(nil), // 9: blobber.service.v1.ObjectPath + (*WriteMarker)(nil), // 10: blobber.service.v1.WriteMarker + (*ListEntitiesRequest)(nil), // 11: blobber.service.v1.ListEntitiesRequest + (*ListEntitiesResponse)(nil), // 12: blobber.service.v1.ListEntitiesResponse + (*GetFileStatsRequest)(nil), // 13: blobber.service.v1.GetFileStatsRequest + (*GetFileStatsResponse)(nil), // 14: blobber.service.v1.GetFileStatsResponse + (*FileStats)(nil), // 15: blobber.service.v1.FileStats + (*GetFileMetaDataRequest)(nil), // 16: blobber.service.v1.GetFileMetaDataRequest + (*GetFileMetaDataResponse)(nil), // 17: blobber.service.v1.GetFileMetaDataResponse + (*CommitMetaTxn)(nil), // 18: blobber.service.v1.CommitMetaTxn + (*Collaborator)(nil), // 19: blobber.service.v1.Collaborator + (*GetAllocationRequest)(nil), // 20: blobber.service.v1.GetAllocationRequest + (*GetAllocationResponse)(nil), // 21: blobber.service.v1.GetAllocationResponse + (*Allocation)(nil), // 22: blobber.service.v1.Allocation + (*Term)(nil), // 23: blobber.service.v1.Term + (*FileRef)(nil), // 24: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 25: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 26: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ - 4, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 8, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 4, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 8, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 22, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef - 4, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath - 7, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath - 8, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 22, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 22, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 22, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 22, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 22, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 22, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef - 13, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 22, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef - 17, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 20, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 21, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 23, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 24, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 16, // 21: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 18, // 22: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 14, // 23: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 11, // 24: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 9, // 25: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 5, // 26: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest - 2, // 27: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest - 0, // 28: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 19, // 29: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 15, // 30: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 12, // 31: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 10, // 32: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 6, // 33: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 3, // 34: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 1, // 35: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 29, // [29:36] is the sub-list for method output_type - 22, // [22:29] is the sub-list for method input_type - 22, // [22:22] is the sub-list for extension type_name - 22, // [22:22] is the sub-list for extension extendee - 0, // [0:22] is the sub-list for field type_name + 10, // 0: blobber.service.v1.CommitResponse.write_marker:type_name -> blobber.service.v1.WriteMarker + 6, // 1: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 10, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 6, // 3: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 10, // 4: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 24, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 6, // 6: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath + 9, // 7: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath + 10, // 8: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker + 24, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 24, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 24, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 24, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 24, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 15, // 15: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats + 24, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 19, // 17: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 22, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 23, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 25, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 26, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 18, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 20, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 16, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 13, // 25: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 11, // 26: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 7, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 4, // 28: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest + 2, // 29: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest + 0, // 30: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest + 21, // 31: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 17, // 32: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 14, // 33: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 12, // 34: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 8, // 35: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 5, // 36: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 3, // 37: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 1, // 38: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 31, // [31:39] is the sub-list for method output_type + 23, // [23:31] is the sub-list for method input_type + 23, // [23:23] is the sub-list for extension type_name + 23, // [23:23] is the sub-list for extension extendee + 0, // [0:23] is the sub-list for field type_name } func init() { file_blobber_proto_init() } @@ -2464,7 +2631,7 @@ func file_blobber_proto_init() { } if !protoimpl.UnsafeEnabled { file_blobber_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectTreeRequest); i { + switch v := v.(*CommitRequest); i { case 0: return &v.state case 1: @@ -2476,7 +2643,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectTreeResponse); i { + switch v := v.(*CommitResponse); i { case 0: return &v.state case 1: @@ -2488,7 +2655,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetReferencePathRequest); i { + switch v := v.(*GetObjectTreeRequest); i { case 0: return &v.state case 1: @@ -2500,7 +2667,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetReferencePathResponse); i { + switch v := v.(*GetObjectTreeResponse); i { case 0: return &v.state case 1: @@ -2512,7 +2679,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReferencePath); i { + switch v := v.(*GetReferencePathRequest); i { case 0: return &v.state case 1: @@ -2524,7 +2691,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathRequest); i { + switch v := v.(*GetReferencePathResponse); i { case 0: return &v.state case 1: @@ -2536,7 +2703,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathResponse); i { + switch v := v.(*ReferencePath); i { case 0: return &v.state case 1: @@ -2548,7 +2715,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ObjectPath); i { + switch v := v.(*GetObjectPathRequest); i { case 0: return &v.state case 1: @@ -2560,7 +2727,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*WriteMarker); i { + switch v := v.(*GetObjectPathResponse); i { case 0: return &v.state case 1: @@ -2572,7 +2739,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesRequest); i { + switch v := v.(*ObjectPath); i { case 0: return &v.state case 1: @@ -2584,7 +2751,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesResponse); i { + switch v := v.(*WriteMarker); i { case 0: return &v.state case 1: @@ -2596,7 +2763,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsRequest); i { + switch v := v.(*ListEntitiesRequest); i { case 0: return &v.state case 1: @@ -2608,7 +2775,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsResponse); i { + switch v := v.(*ListEntitiesResponse); i { case 0: return &v.state case 1: @@ -2620,7 +2787,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileStats); i { + switch v := v.(*GetFileStatsRequest); i { case 0: return &v.state case 1: @@ -2632,7 +2799,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataRequest); i { + switch v := v.(*GetFileStatsResponse); i { case 0: return &v.state case 1: @@ -2644,7 +2811,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataResponse); i { + switch v := v.(*FileStats); i { case 0: return &v.state case 1: @@ -2656,7 +2823,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CommitMetaTxn); i { + switch v := v.(*GetFileMetaDataRequest); i { case 0: return &v.state case 1: @@ -2668,7 +2835,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Collaborator); i { + switch v := v.(*GetFileMetaDataResponse); i { case 0: return &v.state case 1: @@ -2680,7 +2847,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationRequest); i { + switch v := v.(*CommitMetaTxn); i { case 0: return &v.state case 1: @@ -2692,7 +2859,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationResponse); i { + switch v := v.(*Collaborator); i { case 0: return &v.state case 1: @@ -2704,7 +2871,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*GetAllocationRequest); i { case 0: return &v.state case 1: @@ -2716,7 +2883,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*GetAllocationResponse); i { case 0: return &v.state case 1: @@ -2728,7 +2895,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -2740,7 +2907,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -2752,6 +2919,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -2770,7 +2961,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 25, + NumMessages: 27, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 50dc6d47f..34894ee95 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -487,6 +487,76 @@ func local_request_Blobber_GetObjectTree_0(ctx context.Context, marshaler runtim } +var ( + filter_Blobber_Commit_0 = &utilities.DoubleArray{Encoding: map[string]int{"allocation": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}} +) + +func request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitRequest + var metadata runtime.ServerMetadata + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Blobber_Commit_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.Commit(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitRequest + var metadata runtime.ServerMetadata + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Blobber_Commit_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.Commit(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterBlobberHandlerServer registers the http handlers for service Blobber to "mux". // UnaryRPC :call BlobberServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -654,6 +724,29 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) + mux.Handle("GET", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/Commit") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_Commit_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_Commit_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -835,6 +928,26 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) + mux.Handle("GET", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/Commit") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_Commit_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_Commit_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -852,6 +965,8 @@ var ( pattern_Blobber_GetReferencePath_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "referencepath", "allocation"}, "")) pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) + + pattern_Blobber_Commit_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "connection", "commit", "allocation"}, "")) ) var ( @@ -868,4 +983,6 @@ var ( forward_Blobber_GetReferencePath_0 = runtime.ForwardResponseMessage forward_Blobber_GetObjectTree_0 = runtime.ForwardResponseMessage + + forward_Blobber_Commit_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index e73fdcaf5..5d548f813 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -24,6 +24,7 @@ type BlobberClient interface { GetObjectPath(ctx context.Context, in *GetObjectPathRequest, opts ...grpc.CallOption) (*GetObjectPathResponse, error) GetReferencePath(ctx context.Context, in *GetReferencePathRequest, opts ...grpc.CallOption) (*GetReferencePathResponse, error) GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) + Commit(ctx context.Context, in *CommitRequest, opts ...grpc.CallOption) (*CommitResponse, error) } type blobberClient struct { @@ -97,6 +98,15 @@ func (c *blobberClient) GetObjectTree(ctx context.Context, in *GetObjectTreeRequ return out, nil } +func (c *blobberClient) Commit(ctx context.Context, in *CommitRequest, opts ...grpc.CallOption) (*CommitResponse, error) { + out := new(CommitResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/Commit", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -108,6 +118,7 @@ type BlobberServer interface { GetObjectPath(context.Context, *GetObjectPathRequest) (*GetObjectPathResponse, error) GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) + Commit(context.Context, *CommitRequest) (*CommitResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -136,6 +147,9 @@ func (UnimplementedBlobberServer) GetReferencePath(context.Context, *GetReferenc func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetObjectTree not implemented") } +func (UnimplementedBlobberServer) Commit(context.Context, *CommitRequest) (*CommitResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Commit not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -275,6 +289,24 @@ func _Blobber_GetObjectTree_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } +func _Blobber_Commit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CommitRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).Commit(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/Commit", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).Commit(ctx, req.(*CommitRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Blobber_serviceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), @@ -307,6 +339,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "GetObjectTree", Handler: _Blobber_GetObjectTree_Handler, }, + { + MethodName: "Commit", + Handler: _Blobber_Commit_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index e02cfbd76..304cc7a39 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -42,6 +42,25 @@ service Blobber { get: "/v2/file/objecttree/{allocation}" }; } + rpc Commit(CommitRequest) returns (CommitResponse) { + option (google.api.http) = { + get: "/v2/connection/commit/{allocation}" + }; + } +} + +message CommitRequest { + string allocation = 1; + string connection_id = 2; + string write_marker = 3; +} + + +message CommitResponse { + string allocation_root = 1; + WriteMarker write_marker = 2; + string error_message = 3; + bool success = 4; } message GetObjectTreeRequest { diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index e16a5177e..2294628d7 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -89,3 +89,12 @@ func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTr LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), } } + +func CommitWriteResponseHandler(resp *blobbergrpc.CommitResponse) *blobberHTTP.CommitResult { + return &blobberHTTP.CommitResult{ + AllocationRoot: resp.AllocationRoot, + WriteMarker: WriteMarkerGRPCToWriteMarker(resp.WriteMarker), + Success: resp.Success, + ErrorMessage: resp.ErrorMessage, + } +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go new file mode 100644 index 000000000..dbe4f1e06 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go @@ -0,0 +1,187 @@ +package handler + +import ( + "context" + "encoding/hex" + "encoding/json" + "strconv" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/0chain/blobber/code/go/0chain.net/core/lock" + "gorm.io/gorm" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" +) + +// TODO parse request from gateway as form data instead of json +func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.CommitRequest) (*blobbergrpc.CommitResponse, error) { + md := GetGRPCMetaDataFromCtx(ctx) + + allocationTx := req.Allocation + clientID := md.Client + clientKey := md.ClientKey + clientKeyBytes, _ := hex.DecodeString(clientKey) + + allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) + } + + allocationID := allocationObj.ID + + connectionID := req.ConnectionId + if len(connectionID) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid connection id passed") + } + + mutex := lock.GetMutex(allocationObj.TableName(), allocationID) + mutex.Lock() + defer mutex.Unlock() + + connectionObj, err := allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) + if err != nil { + return nil, common.NewErrorf("invalid_parameters", + "Invalid connection id. Connection id was not found: %v", err) + } + if len(connectionObj.Changes) == 0 { + return nil, common.NewError("invalid_parameters", + "Invalid connection id. Connection does not have any changes.") + } + + var isACollaborator bool + for _, change := range connectionObj.Changes { + if change.Operation == allocation.UPDATE_OPERATION { + updateFileChange := new(allocation.UpdateFileChange) + if err := updateFileChange.Unmarshal(change.Input); err != nil { + return nil, err + } + fileRef, err := reference.GetReference(ctx, allocationID, updateFileChange.Path) + if err != nil { + return nil, err + } + isACollaborator = reference.IsACollaborator(ctx, fileRef.ID, clientID) + break + } + } + + if len(clientID) == 0 || len(clientKey) == 0 { + return nil, common.NewError("invalid_params", "Please provide clientID and clientKey") + } + + if (allocationObj.OwnerID != clientID || encryption.Hash(clientKeyBytes) != clientID) && !isACollaborator { + return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + + if allocationObj.BlobberSizeUsed+connectionObj.Size > allocationObj.BlobberSize { + return nil, common.NewError("max_allocation_size", + "Max size reached for the allocation with this blobber") + } + + writeMarkerString := req.WriteMarker + writeMarker := writemarker.WriteMarker{} + err = json.Unmarshal([]byte(writeMarkerString), &writeMarker) + if err != nil { + return nil, common.NewErrorf("invalid_parameters", + "Invalid parameters. Error parsing the writemarker for commit: %v", + err) + } + + var result blobbergrpc.CommitResponse + var latestWM *writemarker.WriteMarkerEntity + if len(allocationObj.AllocationRoot) == 0 { + latestWM = nil + } else { + latestWM, err = writemarker.GetWriteMarkerEntity(ctx, + allocationObj.AllocationRoot) + if err != nil { + return nil, common.NewErrorf("latest_write_marker_read_error", + "Error reading the latest write marker for allocation: %v", err) + } + } + + writemarkerObj := &writemarker.WriteMarkerEntity{} + writemarkerObj.WM = writeMarker + + err = writemarkerObj.VerifyMarker(ctx, allocationObj, connectionObj) + if err != nil { + result.AllocationRoot = allocationObj.AllocationRoot + result.ErrorMessage = "Verification of write marker failed: " + err.Error() + result.Success = false + if latestWM != nil { + result.WriteMarker = convert.WriteMarkerToWriteMarkerGRPC(&latestWM.WM) + } + return &result, common.NewError("write_marker_verification_failed", result.ErrorMessage) + } + + var clientIDForWriteRedeem = writeMarker.ClientID + if isACollaborator { + clientIDForWriteRedeem = allocationObj.OwnerID + } + + if err = writePreRedeem(ctx, allocationObj, &writeMarker, clientIDForWriteRedeem); err != nil { + return nil, err + } + + err = connectionObj.ApplyChanges(ctx, writeMarker.AllocationRoot) + if err != nil { + return nil, err + } + rootRef, err := reference.GetReference(ctx, allocationID, "/") + if err != nil { + return nil, err + } + allocationRoot := encryption.Hash(rootRef.Hash + ":" + strconv.FormatInt(int64(writeMarker.Timestamp), 10)) + + if allocationRoot != writeMarker.AllocationRoot { + result.AllocationRoot = allocationObj.AllocationRoot + if latestWM != nil { + result.WriteMarker = convert.WriteMarkerToWriteMarkerGRPC(&latestWM.WM) + } + result.Success = false + result.ErrorMessage = "Allocation root in the write marker does not match the calculated allocation root. Expected hash: " + allocationRoot + return &result, common.NewError("allocation_root_mismatch", result.ErrorMessage) + } + writemarkerObj.ConnectionID = connectionObj.ConnectionID + writemarkerObj.ClientPublicKey = clientKey + err = writemarkerObj.Save(ctx) + if err != nil { + return nil, common.NewError("write_marker_error", "Error persisting the write marker") + } + + db := datastore.GetStore().GetTransaction(ctx) + allocationUpdates := make(map[string]interface{}) + allocationUpdates["blobber_size_used"] = gorm.Expr("blobber_size_used + ?", connectionObj.Size) + allocationUpdates["used_size"] = gorm.Expr("used_size + ?", connectionObj.Size) + allocationUpdates["allocation_root"] = allocationRoot + allocationUpdates["is_redeem_required"] = true + + err = db.Model(allocationObj).Updates(allocationUpdates).Error + if err != nil { + return nil, common.NewError("allocation_write_error", "Error persisting the allocation object") + } + err = connectionObj.CommitToFileStore(ctx) + if err != nil { + return nil, common.NewError("file_store_error", "Error committing to file store. "+err.Error()) + } + + // TODO maybe delete 'changes' field altogether, its not being used anywhere - its not even being sent as json back as response + //result.Changes = connectionObj.Changes + + connectionObj.DeleteChanges(ctx) //nolint:errcheck // never returns an error anyway + + db.Model(connectionObj).Updates(allocation.AllocationChangeCollector{Status: allocation.CommittedConnection}) + + result.AllocationRoot = allocationObj.AllocationRoot + result.WriteMarker = convert.WriteMarkerToWriteMarkerGRPC(&writeMarker) + result.Success = true + result.ErrorMessage = "" + + return &result, nil +} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 5d001aafc..7eb14db93 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -43,7 +43,7 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) - r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler)))) + r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler(svc))))).Methods("POST") r.HandleFunc("/v1/file/commitmetatxn/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitMetaTxnHandler)))) r.HandleFunc("/v1/file/collaborator/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CollaboratorHandler)))) r.HandleFunc("/v1/file/calculatehash/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CalculateHashHandler)))) @@ -231,15 +231,21 @@ func ListHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Requ } /*CommitHandler is the handler to respond to upload requests fro clients*/ -func CommitHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) +func CommitHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerGRPCContext(ctx, r) - response, err := storageHandler.CommitWrite(ctx, r) - if err != nil { - return nil, err - } + response, err := svc.Commit(ctx, &blobbergrpc.CommitRequest{ + Allocation: mux.Vars(r)["allocation"], + ConnectionId: r.FormValue("connection_id"), + WriteMarker: r.FormValue("write_marker"), + }) + if err != nil { + return nil, err + } - return response, nil + return convert.CommitWriteResponseHandler(response), nil + } } func ReferencePathHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index bb3789a42..8444ac4e7 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -46,6 +46,48 @@ ] } }, + "/v2/connection/commit/{allocation}": { + "get": { + "operationId": "Blobber_Commit", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1CommitResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "connectionId", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "writeMarker", + "in": "query", + "required": false, + "type": "string" + } + ], + "tags": [ + "Blobber" + ] + } + }, "/v2/file/list/{allocation}": { "get": { "operationId": "Blobber_ListEntities", @@ -433,6 +475,23 @@ } } }, + "v1CommitResponse": { + "type": "object", + "properties": { + "allocationRoot": { + "type": "string" + }, + "writeMarker": { + "$ref": "#/definitions/v1WriteMarker" + }, + "errorMessage": { + "type": "string" + }, + "success": { + "type": "boolean" + } + } + }, "v1DirMetaData": { "type": "object", "properties": { From 85e46a95eb61a4e48cb3fd20444e8dce2e13dc53 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 09:19:05 +0530 Subject: [PATCH 041/183] update attributes grpc added --- .../allocation/allocationchange.go | 20 + .../blobbercore/blobberHTTP/response.go | 5 + .../blobbercore/blobbergrpc/blobber.pb.go | 688 +++++++++++------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 115 +++ .../blobbergrpc/blobber_grpc.pb.go | 46 +- .../blobbergrpc/proto/blobber.proto | 22 +- .../blobbercore/convert/responseHandler.go | 8 + .../0chain.net/blobbercore/handler/handler.go | 47 +- .../0chain.net/blobbercore/handler/helper.go | 13 + .../handler/object_operation_grpc_handler.go | 111 +++ .../object_operation_grpc_handler_test.go | 1 + .../blobbercore/openapi/blobber.swagger.json | 67 ++ 12 files changed, 868 insertions(+), 275 deletions(-) create mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go create mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go diff --git a/code/go/0chain.net/blobbercore/allocation/allocationchange.go b/code/go/0chain.net/blobbercore/allocation/allocationchange.go index 09c124885..abcaf682f 100644 --- a/code/go/0chain.net/blobbercore/allocation/allocationchange.go +++ b/code/go/0chain.net/blobbercore/allocation/allocationchange.go @@ -39,6 +39,18 @@ type AllocationChangeProcessor interface { Unmarshal(string) error } +type IAllocationChangeCollector interface { + TableName() string + AddChange(allocationChange *AllocationChange, changeProcessor AllocationChangeProcessor) + Save(ctx context.Context) error + ComputeProperties() + ApplyChanges(ctx context.Context, allocationRoot string) error + CommitToFileStore(ctx context.Context) error + DeleteChanges(ctx context.Context) + GetAllocationID() string + GetConnectionID() string +} + type AllocationChangeCollector struct { ConnectionID string `gorm:"column:connection_id;primary_key"` AllocationID string `gorm:"column:allocation_id"` @@ -170,3 +182,11 @@ func (a *AllocationChangeCollector) DeleteChanges(ctx context.Context) { } } } + +func (a *AllocationChangeCollector) GetAllocationID() string { + return a.AllocationID +} + +func (a *AllocationChangeCollector) GetConnectionID() string { + return a.ConnectionID +} diff --git a/code/go/0chain.net/blobbercore/blobberHTTP/response.go b/code/go/0chain.net/blobbercore/blobberHTTP/response.go index bac290f6c..d6c72baf9 100644 --- a/code/go/0chain.net/blobbercore/blobberHTTP/response.go +++ b/code/go/0chain.net/blobbercore/blobberHTTP/response.go @@ -5,6 +5,7 @@ import ( "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/common" ) type UploadResult struct { @@ -51,3 +52,7 @@ type DownloadResponse struct { Path string `json:"-"` LatestRM *readmarker.ReadMarker `json:"latest_rm"` } + +type UpdateObjectAttributesResponse struct { + WhoPaysForReads common.WhoPays `json:"who_pays_for_reads,omitempty"` +} diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 2d21e6a7b..47a86f3ca 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.6.1 +// protoc v3.17.0 // source: blobber.proto package blobbergrpc @@ -1321,6 +1321,132 @@ func (x *GetAllocationResponse) GetAllocation() *Allocation { return nil } +type UpdateObjectAttributesRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,3,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + ConnectionId string `protobuf:"bytes,4,opt,name=connection_id,json=connectionId,proto3" json:"connection_id,omitempty"` + Attributes string `protobuf:"bytes,5,opt,name=attributes,proto3" json:"attributes,omitempty"` +} + +func (x *UpdateObjectAttributesRequest) Reset() { + *x = UpdateObjectAttributesRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *UpdateObjectAttributesRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*UpdateObjectAttributesRequest) ProtoMessage() {} + +func (x *UpdateObjectAttributesRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[20] + 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 UpdateObjectAttributesRequest.ProtoReflect.Descriptor instead. +func (*UpdateObjectAttributesRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{20} +} + +func (x *UpdateObjectAttributesRequest) GetAllocation() string { + if x != nil { + return x.Allocation + } + return "" +} + +func (x *UpdateObjectAttributesRequest) GetPath() string { + if x != nil { + return x.Path + } + return "" +} + +func (x *UpdateObjectAttributesRequest) GetPathHash() string { + if x != nil { + return x.PathHash + } + return "" +} + +func (x *UpdateObjectAttributesRequest) GetConnectionId() string { + if x != nil { + return x.ConnectionId + } + return "" +} + +func (x *UpdateObjectAttributesRequest) GetAttributes() string { + if x != nil { + return x.Attributes + } + return "" +} + +type UpdateObjectAttributesResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + WhoPaysForReads int64 `protobuf:"varint,1,opt,name=who_pays_for_reads,json=whoPaysForReads,proto3" json:"who_pays_for_reads,omitempty"` +} + +func (x *UpdateObjectAttributesResponse) Reset() { + *x = UpdateObjectAttributesResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *UpdateObjectAttributesResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*UpdateObjectAttributesResponse) ProtoMessage() {} + +func (x *UpdateObjectAttributesResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[21] + 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 UpdateObjectAttributesResponse.ProtoReflect.Descriptor instead. +func (*UpdateObjectAttributesResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{21} +} + +func (x *UpdateObjectAttributesResponse) GetWhoPaysForReads() int64 { + if x != nil { + return x.WhoPaysForReads + } + return 0 +} + type Allocation struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -1348,7 +1474,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1361,7 +1487,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1374,7 +1500,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{22} } func (x *Allocation) GetID() string { @@ -1511,7 +1637,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1524,7 +1650,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1537,7 +1663,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{23} } func (x *Term) GetID() int64 { @@ -1588,7 +1714,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1601,7 +1727,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1614,7 +1740,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{24} } func (x *FileRef) GetType() string { @@ -1672,7 +1798,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1685,7 +1811,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1698,7 +1824,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{23} + return file_blobber_proto_rawDescGZIP(), []int{25} } func (x *FileMetaData) GetType() string { @@ -1889,7 +2015,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1902,7 +2028,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1915,7 +2041,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{24} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *DirMetaData) GetType() string { @@ -2181,196 +2307,224 @@ var file_blobber_proto_rawDesc = []byte{ 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, - 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, - 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, - 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, - 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, - 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, - 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, - 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, - 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, - 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, - 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, - 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, - 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, - 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, - 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, - 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb5, 0x01, 0x0a, 0x1d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, + 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, + 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x1e, 0x0a, + 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x22, 0x4d, 0x0a, + 0x1e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, + 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x2b, 0x0a, 0x12, 0x77, 0x68, 0x6f, 0x5f, 0x70, 0x61, 0x79, 0x73, 0x5f, 0x66, 0x6f, 0x72, 0x5f, + 0x72, 0x65, 0x61, 0x64, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x77, 0x68, 0x6f, + 0x50, 0x61, 0x79, 0x73, 0x46, 0x6f, 0x72, 0x52, 0x65, 0x61, 0x64, 0x73, 0x22, 0xb6, 0x04, 0x0a, + 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, + 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, + 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, + 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, + 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, + 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, + 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, + 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, + 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, + 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, + 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, + 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, + 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, + 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, + 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, + 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, + 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, + 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, + 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, + 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, + 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, + 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, + 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, + 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, + 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, + 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, + 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, + 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, + 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, + 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, + 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, + 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, + 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, + 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, + 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, + 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, + 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, + 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, + 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, + 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, + 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, + 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, + 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, + 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, + 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, + 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, + 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, + 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, + 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, + 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, + 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, + 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, + 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, + 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, + 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, + 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, + 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, + 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, + 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, + 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, + 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, + 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, + 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x32, 0x97, 0x09, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, + 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, + 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, + 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, + 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, + 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, + 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, + 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, + 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, + 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, - 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, - 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, - 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, + 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, + 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, + 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, + 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, - 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, + 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, + 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, + 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, + 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, + 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, + 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0xac, + 0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, + 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, + 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, + 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, + 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, + 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, } var ( @@ -2385,56 +2539,58 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 25) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 27) var file_blobber_proto_goTypes = []interface{}{ - (*GetObjectTreeRequest)(nil), // 0: blobber.service.v1.GetObjectTreeRequest - (*GetObjectTreeResponse)(nil), // 1: blobber.service.v1.GetObjectTreeResponse - (*GetReferencePathRequest)(nil), // 2: blobber.service.v1.GetReferencePathRequest - (*GetReferencePathResponse)(nil), // 3: blobber.service.v1.GetReferencePathResponse - (*ReferencePath)(nil), // 4: blobber.service.v1.ReferencePath - (*GetObjectPathRequest)(nil), // 5: blobber.service.v1.GetObjectPathRequest - (*GetObjectPathResponse)(nil), // 6: blobber.service.v1.GetObjectPathResponse - (*ObjectPath)(nil), // 7: blobber.service.v1.ObjectPath - (*WriteMarker)(nil), // 8: blobber.service.v1.WriteMarker - (*ListEntitiesRequest)(nil), // 9: blobber.service.v1.ListEntitiesRequest - (*ListEntitiesResponse)(nil), // 10: blobber.service.v1.ListEntitiesResponse - (*GetFileStatsRequest)(nil), // 11: blobber.service.v1.GetFileStatsRequest - (*GetFileStatsResponse)(nil), // 12: blobber.service.v1.GetFileStatsResponse - (*FileStats)(nil), // 13: blobber.service.v1.FileStats - (*GetFileMetaDataRequest)(nil), // 14: blobber.service.v1.GetFileMetaDataRequest - (*GetFileMetaDataResponse)(nil), // 15: blobber.service.v1.GetFileMetaDataResponse - (*CommitMetaTxn)(nil), // 16: blobber.service.v1.CommitMetaTxn - (*Collaborator)(nil), // 17: blobber.service.v1.Collaborator - (*GetAllocationRequest)(nil), // 18: blobber.service.v1.GetAllocationRequest - (*GetAllocationResponse)(nil), // 19: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 20: blobber.service.v1.Allocation - (*Term)(nil), // 21: blobber.service.v1.Term - (*FileRef)(nil), // 22: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 23: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 24: blobber.service.v1.DirMetaData + (*GetObjectTreeRequest)(nil), // 0: blobber.service.v1.GetObjectTreeRequest + (*GetObjectTreeResponse)(nil), // 1: blobber.service.v1.GetObjectTreeResponse + (*GetReferencePathRequest)(nil), // 2: blobber.service.v1.GetReferencePathRequest + (*GetReferencePathResponse)(nil), // 3: blobber.service.v1.GetReferencePathResponse + (*ReferencePath)(nil), // 4: blobber.service.v1.ReferencePath + (*GetObjectPathRequest)(nil), // 5: blobber.service.v1.GetObjectPathRequest + (*GetObjectPathResponse)(nil), // 6: blobber.service.v1.GetObjectPathResponse + (*ObjectPath)(nil), // 7: blobber.service.v1.ObjectPath + (*WriteMarker)(nil), // 8: blobber.service.v1.WriteMarker + (*ListEntitiesRequest)(nil), // 9: blobber.service.v1.ListEntitiesRequest + (*ListEntitiesResponse)(nil), // 10: blobber.service.v1.ListEntitiesResponse + (*GetFileStatsRequest)(nil), // 11: blobber.service.v1.GetFileStatsRequest + (*GetFileStatsResponse)(nil), // 12: blobber.service.v1.GetFileStatsResponse + (*FileStats)(nil), // 13: blobber.service.v1.FileStats + (*GetFileMetaDataRequest)(nil), // 14: blobber.service.v1.GetFileMetaDataRequest + (*GetFileMetaDataResponse)(nil), // 15: blobber.service.v1.GetFileMetaDataResponse + (*CommitMetaTxn)(nil), // 16: blobber.service.v1.CommitMetaTxn + (*Collaborator)(nil), // 17: blobber.service.v1.Collaborator + (*GetAllocationRequest)(nil), // 18: blobber.service.v1.GetAllocationRequest + (*GetAllocationResponse)(nil), // 19: blobber.service.v1.GetAllocationResponse + (*UpdateObjectAttributesRequest)(nil), // 20: blobber.service.v1.UpdateObjectAttributesRequest + (*UpdateObjectAttributesResponse)(nil), // 21: blobber.service.v1.UpdateObjectAttributesResponse + (*Allocation)(nil), // 22: blobber.service.v1.Allocation + (*Term)(nil), // 23: blobber.service.v1.Term + (*FileRef)(nil), // 24: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 25: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 26: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 4, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 8, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 4, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 8, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 22, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 4, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 7, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 8, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 22, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 22, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 22, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 22, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 22, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 22, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 24, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 24, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 24, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 24, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 13, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 22, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 17, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 20, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 21, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 23, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 24, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 22, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 23, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 25, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 26, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 16, // 21: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 18, // 22: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 14, // 23: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -2443,15 +2599,17 @@ var file_blobber_proto_depIdxs = []int32{ 5, // 26: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest 2, // 27: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest 0, // 28: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 19, // 29: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 15, // 30: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 12, // 31: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 10, // 32: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 6, // 33: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 3, // 34: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 1, // 35: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 29, // [29:36] is the sub-list for method output_type - 22, // [22:29] is the sub-list for method input_type + 20, // 29: blobber.service.v1.Blobber.UpdateObjectAttributes:input_type -> blobber.service.v1.UpdateObjectAttributesRequest + 19, // 30: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 15, // 31: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 12, // 32: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 10, // 33: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 6, // 34: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 3, // 35: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 1, // 36: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 21, // 37: blobber.service.v1.Blobber.UpdateObjectAttributes:output_type -> blobber.service.v1.UpdateObjectAttributesResponse + 30, // [30:38] is the sub-list for method output_type + 22, // [22:30] is the sub-list for method input_type 22, // [22:22] is the sub-list for extension type_name 22, // [22:22] is the sub-list for extension extendee 0, // [0:22] is the sub-list for field type_name @@ -2704,7 +2862,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*UpdateObjectAttributesRequest); i { case 0: return &v.state case 1: @@ -2716,7 +2874,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*UpdateObjectAttributesResponse); i { case 0: return &v.state case 1: @@ -2728,7 +2886,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -2740,7 +2898,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -2752,6 +2910,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -2770,7 +2952,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 25, + NumMessages: 27, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 50dc6d47f..1e2be71b8 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -487,6 +487,74 @@ func local_request_Blobber_GetObjectTree_0(ctx context.Context, marshaler runtim } +func request_Blobber_UpdateObjectAttributes_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UpdateObjectAttributesRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := client.UpdateObjectAttributes(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_UpdateObjectAttributes_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UpdateObjectAttributesRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := server.UpdateObjectAttributes(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterBlobberHandlerServer registers the http handlers for service Blobber to "mux". // UnaryRPC :call BlobberServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -654,6 +722,29 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) + mux.Handle("POST", pattern_Blobber_UpdateObjectAttributes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/UpdateObjectAttributes") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_UpdateObjectAttributes_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_UpdateObjectAttributes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -835,6 +926,26 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) + mux.Handle("POST", pattern_Blobber_UpdateObjectAttributes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/UpdateObjectAttributes") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_UpdateObjectAttributes_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_UpdateObjectAttributes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -852,6 +963,8 @@ var ( pattern_Blobber_GetReferencePath_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "referencepath", "allocation"}, "")) pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) + + pattern_Blobber_UpdateObjectAttributes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "attributes", "allocation"}, "")) ) var ( @@ -868,4 +981,6 @@ var ( forward_Blobber_GetReferencePath_0 = runtime.ForwardResponseMessage forward_Blobber_GetObjectTree_0 = runtime.ForwardResponseMessage + + forward_Blobber_UpdateObjectAttributes_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index e73fdcaf5..ba2de938e 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -11,6 +11,7 @@ import ( // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 // BlobberClient is the client API for Blobber service. @@ -24,6 +25,7 @@ type BlobberClient interface { GetObjectPath(ctx context.Context, in *GetObjectPathRequest, opts ...grpc.CallOption) (*GetObjectPathResponse, error) GetReferencePath(ctx context.Context, in *GetReferencePathRequest, opts ...grpc.CallOption) (*GetReferencePathResponse, error) GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) + UpdateObjectAttributes(ctx context.Context, in *UpdateObjectAttributesRequest, opts ...grpc.CallOption) (*UpdateObjectAttributesResponse, error) } type blobberClient struct { @@ -97,6 +99,15 @@ func (c *blobberClient) GetObjectTree(ctx context.Context, in *GetObjectTreeRequ return out, nil } +func (c *blobberClient) UpdateObjectAttributes(ctx context.Context, in *UpdateObjectAttributesRequest, opts ...grpc.CallOption) (*UpdateObjectAttributesResponse, error) { + out := new(UpdateObjectAttributesResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/UpdateObjectAttributes", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -108,6 +119,7 @@ type BlobberServer interface { GetObjectPath(context.Context, *GetObjectPathRequest) (*GetObjectPathResponse, error) GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) + UpdateObjectAttributes(context.Context, *UpdateObjectAttributesRequest) (*UpdateObjectAttributesResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -136,6 +148,9 @@ func (UnimplementedBlobberServer) GetReferencePath(context.Context, *GetReferenc func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetObjectTree not implemented") } +func (UnimplementedBlobberServer) UpdateObjectAttributes(context.Context, *UpdateObjectAttributesRequest) (*UpdateObjectAttributesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateObjectAttributes not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -145,8 +160,8 @@ type UnsafeBlobberServer interface { mustEmbedUnimplementedBlobberServer() } -func RegisterBlobberServer(s *grpc.Server, srv BlobberServer) { - s.RegisterService(&_Blobber_serviceDesc, srv) +func RegisterBlobberServer(s grpc.ServiceRegistrar, srv BlobberServer) { + s.RegisterService(&Blobber_ServiceDesc, srv) } func _Blobber_GetAllocation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { @@ -275,7 +290,28 @@ func _Blobber_GetObjectTree_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } -var _Blobber_serviceDesc = grpc.ServiceDesc{ +func _Blobber_UpdateObjectAttributes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(UpdateObjectAttributesRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).UpdateObjectAttributes(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/UpdateObjectAttributes", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).UpdateObjectAttributes(ctx, req.(*UpdateObjectAttributesRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Blobber_ServiceDesc is the grpc.ServiceDesc for Blobber service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Blobber_ServiceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), Methods: []grpc.MethodDesc{ @@ -307,6 +343,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "GetObjectTree", Handler: _Blobber_GetObjectTree_Handler, }, + { + MethodName: "UpdateObjectAttributes", + Handler: _Blobber_UpdateObjectAttributes_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index e02cfbd76..da61a28d3 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -42,6 +42,13 @@ service Blobber { get: "/v2/file/objecttree/{allocation}" }; } + + rpc UpdateObjectAttributes(UpdateObjectAttributesRequest) returns (UpdateObjectAttributesResponse) { + option (google.api.http) = { + post: "/v2/file/attributes/{allocation}" + body: "*" + }; + } } message GetObjectTreeRequest { @@ -103,7 +110,6 @@ message ListEntitiesRequest { string auth_token = 3; string allocation = 4; } - message ListEntitiesResponse { string AllocationRoot = 1; FileRef MetaData = 2; @@ -115,7 +121,6 @@ message GetFileStatsRequest { string path_hash = 2; string allocation = 3; } - message GetFileStatsResponse { FileRef MetaData = 1; FileStats Stats = 2; @@ -140,7 +145,6 @@ message GetFileMetaDataRequest { string auth_token = 3; string allocation = 4; } - message GetFileMetaDataResponse { FileRef MetaData = 1; repeated Collaborator Collaborators = 2; @@ -161,11 +165,21 @@ message Collaborator { message GetAllocationRequest { string id = 1; } - message GetAllocationResponse { Allocation allocation = 1; } +message UpdateObjectAttributesRequest { + string allocation = 1; + string path = 2; + string path_hash = 3; + string connection_id = 4; + string attributes = 5; +} +message UpdateObjectAttributesResponse { + int64 who_pays_for_reads = 1; +} + message Allocation { string ID = 1; string Tx = 2; diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index e16a5177e..543b2de2e 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -3,6 +3,7 @@ package convert import ( "context" "encoding/json" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberHTTP" @@ -89,3 +90,10 @@ func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTr LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), } } + +func UpdateObjectAttributesResponseHandler( + updateAttributesResponse *blobbergrpc.UpdateObjectAttributesResponse) *blobberHTTP.UpdateObjectAttributesResponse { + return &blobberHTTP.UpdateObjectAttributesResponse{ + WhoPaysForReads: common.WhoPays(updateAttributesResponse.WhoPaysForReads), + } +} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 5d001aafc..17caa9004 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -41,7 +41,8 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) - r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) + r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse( + WithConnection(UpdateAttributesHandler(svc))))).Methods(http.MethodPost) r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler)))) r.HandleFunc("/v1/file/commitmetatxn/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitMetaTxnHandler)))) @@ -49,13 +50,20 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/file/calculatehash/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CalculateHashHandler)))) //object info related apis - r.HandleFunc("/allocation", common.UserRateLimit(common.ToJSONResponse(WithConnection(AllocationHandler(svc))))).Methods("GET") - r.HandleFunc("/v1/file/meta/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileMetaHandler(svc))))).Methods("POST") - r.HandleFunc("/v1/file/stats/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileStatsHandler(svc))))).Methods("POST") - r.HandleFunc("/v1/file/list/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ListHandler(svc))))).Methods("GET") - r.HandleFunc("/v1/file/objectpath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectPathHandler(svc))))).Methods("GET") - r.HandleFunc("/v1/file/referencepath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ReferencePathHandler(svc))))).Methods("GET") - r.HandleFunc("/v1/file/objecttree/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectTreeHandler(svc))))).Methods("GET") + r.HandleFunc("/allocation", common.UserRateLimit(common.ToJSONResponse( + WithConnection(AllocationHandler(svc))))).Methods(http.MethodGet) + r.HandleFunc("/v1/file/meta/{allocation}", common.UserRateLimit(common.ToJSONResponse( + WithReadOnlyConnection(FileMetaHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/file/stats/{allocation}", common.UserRateLimit(common.ToJSONResponse( + WithReadOnlyConnection(FileStatsHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/file/list/{allocation}", common.UserRateLimit(common.ToJSONResponse( + WithReadOnlyConnection(ListHandler(svc))))).Methods(http.MethodGet) + r.HandleFunc("/v1/file/objectpath/{allocation}", common.UserRateLimit(common.ToJSONResponse( + WithReadOnlyConnection(ObjectPathHandler(svc))))).Methods(http.MethodGet) + r.HandleFunc("/v1/file/referencepath/{allocation}", common.UserRateLimit(common.ToJSONResponse( + WithReadOnlyConnection(ReferencePathHandler(svc))))).Methods(http.MethodGet) + r.HandleFunc("/v1/file/objecttree/{allocation}", common.UserRateLimit(common.ToJSONResponse( + WithReadOnlyConnection(ObjectTreeHandler(svc))))).Methods(http.MethodGet) //admin related r.HandleFunc("/_debug", common.UserRateLimit(common.ToJSONResponse(DumpGoRoutines))) @@ -320,14 +328,23 @@ func UploadHandler(ctx context.Context, r *http.Request) (interface{}, error) { return response, nil } -func UpdateAttributesHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) - response, err := storageHandler.UpdateObjectAttributes(ctx, r) - if err != nil { - return nil, err - } +func UpdateAttributesHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerGRPCContext(ctx, r) - return response, nil + updateAttrResp, err := svc.UpdateObjectAttributes(ctx, &blobbergrpc.UpdateObjectAttributesRequest{ + Path: r.FormValue("path"), + PathHash: r.FormValue("path_hash"), + Allocation: mux.Vars(r)["allocation"], + ConnectionId: r.FormValue("connection_id"), + Attributes: r.FormValue("attributes"), + }) + if err != nil { + return nil, err + } + + return convert.UpdateObjectAttributesResponseHandler(updateAttrResp), nil + } } func CalculateHashHandler(ctx context.Context, r *http.Request) (interface{}, error) { diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index d129bc7bd..b79dba7a1 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -30,6 +30,7 @@ type StorageHandlerI interface { // PackageHandler is an interface for all static functions that may need to be mocked type PackageHandler interface { + GetReferenceLookup(ctx context.Context, allocationID string, path string) string GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) @@ -40,6 +41,8 @@ type PackageHandler interface { GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) + GetAllocationChanges(ctx context.Context, connectionID string, + allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) } type packageHandler struct{} @@ -68,6 +71,10 @@ func (r *packageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_ro return writemarker.GetWriteMarkerEntity(ctx, allocation_root) } +func (r *packageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { + return reference.GetReferenceLookup(allocationID, path) +} + func (r *packageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { return reference.GetReferenceFromLookupHash(ctx, allocationID, path_hash) } @@ -83,3 +90,9 @@ func (r *packageHandler) GetCollaborators(ctx context.Context, refID int64) ([]r func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { return reference.IsACollaborator(ctx, refID, clientID) } + +func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, + allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { + + return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go new file mode 100644 index 000000000..fa132b405 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -0,0 +1,111 @@ +package handler + +import ( + "context" + "encoding/json" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/lock" + "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap/ctxzap" + "go.uber.org/zap" +) + +func (b *blobberGRPCService) UpdateObjectAttributes(ctx context.Context, r *blobbergrpc.UpdateObjectAttributesRequest) ( + response *blobbergrpc.UpdateObjectAttributesResponse, err error) { + + logger := ctxzap.Extract(ctx) + + allocationTx := r.Allocation + allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) + } + + md := GetGRPCMetaDataFromCtx(ctx) + valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) + if !valid || err != nil { + return nil, common.NewError("invalid_signature", "Invalid signature") + } + + // runtime type check + _ = ctx.Value(constants.CLIENT_KEY_CONTEXT_KEY).(string) + + clientID := md.Client + if len(clientID) == 0 || allocationObj.OwnerID != clientID { + return nil, common.NewError( + "invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + + var attributes = r.Attributes // new attributes as string + if attributes == "" { + return nil, common.NewError("update_object_attributes", + "missing new attributes, pass at least {} for empty attributes") + } + + var attrs = new(reference.Attributes) + if err = json.Unmarshal([]byte(attributes), attrs); err != nil { + return nil, common.NewErrorf("update_object_attributes", + "decoding given attributes: %v", err) + } + + pathHash := r.PathHash + path := r.Path + if len(pathHash) == 0 { + if len(path) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid path") + } + pathHash = b.packageHandler.GetReferenceLookup(ctx, allocationObj.ID, path) + } + + var connID = r.ConnectionId + if connID == "" { + return nil, common.NewErrorf("update_object_attributes", + "invalid connection id passed: %s", connID) + } + + var conn allocation.IAllocationChangeCollector + conn, err = b.packageHandler.GetAllocationChanges(ctx, connID, allocationObj.ID, clientID) + if err != nil { + return nil, common.NewErrorf("update_object_attributes", + "reading metadata for connection: %v", err) + } + + var mutex = lock.GetMutex(conn.TableName(), connID) + + mutex.Lock() + defer mutex.Unlock() + + var ref *reference.Ref + ref, err = b.packageHandler.GetReferenceFromLookupHash(ctx, allocationObj.ID, pathHash) + if err != nil { + return nil, common.NewErrorf("update_object_attributes", + "invalid file path: %v", err) + } + + var change = new(allocation.AllocationChange) + change.ConnectionID = conn.GetConnectionID() + change.Operation = allocation.UPDATE_ATTRS_OPERATION + + var uafc = &allocation.AttributesChange{ + ConnectionID: conn.GetConnectionID(), + AllocationID: conn.GetAllocationID(), + Path: ref.Path, + Attributes: attrs, + } + + conn.AddChange(change, uafc) + + err = conn.Save(ctx) + if err != nil { + logger.Error("update_object_attributes: "+ + "error in writing the connection meta data", zap.Error(err)) + return nil, common.NewError("update_object_attributes", + "error writing the connection meta data") + } + + // return new attributes as result + return &blobbergrpc.UpdateObjectAttributesResponse{WhoPaysForReads: int64(attrs.WhoPaysForReads)}, nil +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go new file mode 100644 index 000000000..abeebd162 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -0,0 +1 @@ +package handler diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index bb3789a42..179e42425 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -46,6 +46,44 @@ ] } }, + "/v2/file/attributes/{allocation}": { + "post": { + "operationId": "Blobber_UpdateObjectAttributes", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1UpdateObjectAttributesResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1UpdateObjectAttributesRequest" + } + } + ], + "tags": [ + "Blobber" + ] + } + }, "/v2/file/list/{allocation}": { "get": { "operationId": "Blobber_ListEntities", @@ -761,6 +799,35 @@ } } }, + "v1UpdateObjectAttributesRequest": { + "type": "object", + "properties": { + "allocation": { + "type": "string" + }, + "path": { + "type": "string" + }, + "pathHash": { + "type": "string" + }, + "connectionId": { + "type": "string" + }, + "attributes": { + "type": "string" + } + } + }, + "v1UpdateObjectAttributesResponse": { + "type": "object", + "properties": { + "whoPaysForReads": { + "type": "string", + "format": "int64" + } + } + }, "v1WriteMarker": { "type": "object", "properties": { From c3599c4a3accc248c75e4676bf4f99ec0c4c6615 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 11:26:48 +0530 Subject: [PATCH 042/183] update attributes grpc tests added --- .../0chain.net/blobbercore/handler/handler.go | 21 +-- .../blobbercore/handler/handler_test.go | 2 +- .../0chain.net/blobbercore/handler/helper.go | 2 +- .../handler/object_operation_grpc_handler.go | 5 +- .../object_operation_grpc_handler_test.go | 138 ++++++++++++++++++ .../blobbercore/mocks/PackageHandler.go | 41 +++++- 6 files changed, 189 insertions(+), 20 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 17caa9004..d1fb9e16f 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -50,20 +50,13 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/file/calculatehash/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CalculateHashHandler)))) //object info related apis - r.HandleFunc("/allocation", common.UserRateLimit(common.ToJSONResponse( - WithConnection(AllocationHandler(svc))))).Methods(http.MethodGet) - r.HandleFunc("/v1/file/meta/{allocation}", common.UserRateLimit(common.ToJSONResponse( - WithReadOnlyConnection(FileMetaHandler(svc))))).Methods(http.MethodPost) - r.HandleFunc("/v1/file/stats/{allocation}", common.UserRateLimit(common.ToJSONResponse( - WithReadOnlyConnection(FileStatsHandler(svc))))).Methods(http.MethodPost) - r.HandleFunc("/v1/file/list/{allocation}", common.UserRateLimit(common.ToJSONResponse( - WithReadOnlyConnection(ListHandler(svc))))).Methods(http.MethodGet) - r.HandleFunc("/v1/file/objectpath/{allocation}", common.UserRateLimit(common.ToJSONResponse( - WithReadOnlyConnection(ObjectPathHandler(svc))))).Methods(http.MethodGet) - r.HandleFunc("/v1/file/referencepath/{allocation}", common.UserRateLimit(common.ToJSONResponse( - WithReadOnlyConnection(ReferencePathHandler(svc))))).Methods(http.MethodGet) - r.HandleFunc("/v1/file/objecttree/{allocation}", common.UserRateLimit(common.ToJSONResponse( - WithReadOnlyConnection(ObjectTreeHandler(svc))))).Methods(http.MethodGet) + r.HandleFunc("/allocation", common.UserRateLimit(common.ToJSONResponse(WithConnection(AllocationHandler(svc))))).Methods(http.MethodGet) + r.HandleFunc("/v1/file/meta/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileMetaHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/file/stats/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileStatsHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/file/list/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ListHandler(svc))))).Methods(http.MethodGet) + r.HandleFunc("/v1/file/objectpath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectPathHandler(svc))))).Methods(http.MethodGet) + r.HandleFunc("/v1/file/referencepath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ReferencePathHandler(svc))))).Methods(http.MethodGet) + r.HandleFunc("/v1/file/objecttree/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectTreeHandler(svc))))).Methods(http.MethodGet) //admin related r.HandleFunc("/_debug", common.UserRateLimit(common.ToJSONResponse(DumpGoRoutines))) diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go index 0942083ee..bf111a5c6 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/handler_test.go @@ -158,7 +158,7 @@ func setupHandlers() (*mux.Router, map[string]string) { aName := "Attributes" router.HandleFunc(aPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(UpdateAttributesHandler), + WithReadOnlyConnection(UpdateAttributesHandler(svc)), ), ), ).Name(aName) diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index b79dba7a1..41454c91d 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -40,9 +40,9 @@ type PackageHandler interface { GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) - GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) + GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) } type packageHandler struct{} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index fa132b405..66493bf76 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -5,7 +5,6 @@ import ( "encoding/json" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/0chain/blobber/code/go/0chain.net/core/lock" @@ -30,8 +29,8 @@ func (b *blobberGRPCService) UpdateObjectAttributes(ctx context.Context, r *blob return nil, common.NewError("invalid_signature", "Invalid signature") } - // runtime type check - _ = ctx.Value(constants.CLIENT_KEY_CONTEXT_KEY).(string) + //// runtime type check + //_ = ctx.Value(constants.CLIENT_KEY_CONTEXT_KEY).(string) //why this removed? clientID := md.Client if len(clientID) == 0 || allocationObj.OwnerID != clientID { diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go index abeebd162..c7e9edcb1 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -1 +1,139 @@ package handler + +import ( + "context" + "errors" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/mock" + "google.golang.org/grpc/metadata" + "testing" +) + +func Test_blobberGRPCService_UpdateObjectAttributes(t *testing.T) { + type fields struct { + storageHandler StorageHandlerI + packageHandler PackageHandler + UnimplementedBlobberServer blobbergrpc.UnimplementedBlobberServer + } + type args struct { + ctx context.Context + r *blobbergrpc.UpdateObjectAttributesRequest + } + + allocationTx := randString(32) + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + req := &blobbergrpc.UpdateObjectAttributesRequest{ + Allocation: allocationTx, + Attributes: `{"who_pays_for_reads" : 1}`, + Path: `path`, + ConnectionId: `connection_id`, + } + + reqInvalid := &blobbergrpc.UpdateObjectAttributesRequest{ + Allocation: `invalid_id`, + Attributes: `{"who_pays_for_reads" : 1}`, + Path: `path`, + ConnectionId: `connection_id`, + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "client_key", + common.ClientSignatureHeader: clientSignature, + })) + + resOk := &blobbergrpc.UpdateObjectAttributesResponse{WhoPaysForReads: int64(1)} + + mockStorageHandler := &storageHandlerI{} + alloc := &allocation.Allocation{ + Tx: req.Allocation, + ID: `allocation_id`, + OwnerID: `client`, + OwnerPublicKey: pubKey, + } + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). + Return(alloc, nil) + mockStorageHandler.On("verifyAllocation", mock.Anything, reqInvalid.Allocation, false). + Return(nil, errors.New("some error")) + + mockAllocCollector := &mocks.IAllocationChangeCollector{} + mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) + mockAllocCollector.On(`GetAllocationID`).Return(req.Allocation) + mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() + mockAllocCollector.On(`Save`, mock.Anything).Return(nil) + mockAllocCollector.On(`TableName`).Return(`allocation_connections`) + + mockReferencePackage := &mocks.PackageHandler{} + mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, + req.ConnectionId, alloc.ID, `client`).Return(mockAllocCollector, nil) + + pathHash := req.Allocation + `:` + req.Path + mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). + Return(pathHash) + + mockReferencePackage.On(`GetReferenceFromLookupHash`, mock.Anything, alloc.ID, pathHash). + Return( + &reference.Ref{ + Name: "test", + Type: reference.FILE, + }, nil) + + tests := []struct { + name string + fields fields + args args + wantResponse *blobbergrpc.UpdateObjectAttributesResponse + wantErr bool + }{ + { + name: `OK`, + fields: fields{ + storageHandler: mockStorageHandler, + packageHandler: mockReferencePackage, + }, + args: args{ + ctx: ctx, + r: req, + }, + wantResponse: resOk, + wantErr: false, + }, + { + name: `Invalid_Allocation`, + fields: fields{ + storageHandler: mockStorageHandler, + packageHandler: mockReferencePackage, + }, + args: args{ + ctx: ctx, + r: reqInvalid, + }, + wantResponse: nil, + wantErr: true, + }, + } + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + b := &blobberGRPCService{ + storageHandler: tt.fields.storageHandler, + packageHandler: tt.fields.packageHandler, + UnimplementedBlobberServer: tt.fields.UnimplementedBlobberServer, + } + gotResponse, err := b.UpdateObjectAttributes(tt.args.ctx, tt.args.r) + if (err != nil) != tt.wantErr { + t.Errorf("UpdateObjectAttributes() error = %v, wantErr %v", err, tt.wantErr) + return + } + if !assert.Equal(t, gotResponse, tt.wantResponse) { + t.Errorf("UpdateObjectAttributes() gotResponse = %v, want %v", gotResponse, tt.wantResponse) + } + }) + } +} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 73c3dd36f..2c3d4c11c 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -1,10 +1,12 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. +// Code generated by mockery 2.7.5. DO NOT EDIT. package mocks import ( context "context" + allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + mock "github.com/stretchr/testify/mock" reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" @@ -19,6 +21,29 @@ type PackageHandler struct { mock.Mock } +// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID +func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { + ret := _m.Called(ctx, connectionID, allocationID, clientID) + + var r0 allocation.IAllocationChangeCollector + if rf, ok := ret.Get(0).(func(context.Context, string, string, string) allocation.IAllocationChangeCollector); ok { + r0 = rf(ctx, connectionID, allocationID, clientID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(allocation.IAllocationChangeCollector) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { + r1 = rf(ctx, connectionID, allocationID, clientID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // GetCollaborators provides a mock function with given fields: ctx, refID func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { ret := _m.Called(ctx, refID) @@ -180,6 +205,20 @@ func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, alloca return r0, r1 } +// GetReferenceLookup provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { + ret := _m.Called(ctx, allocationID, path) + + var r0 string + if rf, ok := ret.Get(0).(func(context.Context, string, string) string); ok { + r0 = rf(ctx, allocationID, path) + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + // GetReferencePathFromPaths provides a mock function with given fields: ctx, allocationID, paths func (_m *PackageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { ret := _m.Called(ctx, allocationID, paths) From b7e96791a3308966bc57cbcfdee1a138477848be Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 11:51:38 +0530 Subject: [PATCH 043/183] tests updated to simpler test methods --- .../object_operation_grpc_handler_test.go | 112 ++++++------------ 1 file changed, 37 insertions(+), 75 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go index c7e9edcb1..152e88ebe 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -15,17 +15,7 @@ import ( "testing" ) -func Test_blobberGRPCService_UpdateObjectAttributes(t *testing.T) { - type fields struct { - storageHandler StorageHandlerI - packageHandler PackageHandler - UnimplementedBlobberServer blobbergrpc.UnimplementedBlobberServer - } - type args struct { - ctx context.Context - r *blobbergrpc.UpdateObjectAttributesRequest - } - +func TestBlobberGRPCService_UpdateObjectAttributes_Success(t *testing.T) { allocationTx := randString(32) pubKey, _, signScheme := GeneratePubPrivateKey(t) clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) @@ -36,13 +26,6 @@ func Test_blobberGRPCService_UpdateObjectAttributes(t *testing.T) { ConnectionId: `connection_id`, } - reqInvalid := &blobbergrpc.UpdateObjectAttributesRequest{ - Allocation: `invalid_id`, - Attributes: `{"who_pays_for_reads" : 1}`, - Path: `path`, - ConnectionId: `connection_id`, - } - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ common.ClientHeader: "client", common.ClientKeyHeader: "client_key", @@ -60,8 +43,6 @@ func Test_blobberGRPCService_UpdateObjectAttributes(t *testing.T) { } mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). Return(alloc, nil) - mockStorageHandler.On("verifyAllocation", mock.Anything, reqInvalid.Allocation, false). - Return(nil, errors.New("some error")) mockAllocCollector := &mocks.IAllocationChangeCollector{} mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) @@ -78,62 +59,43 @@ func Test_blobberGRPCService_UpdateObjectAttributes(t *testing.T) { mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). Return(pathHash) - mockReferencePackage.On(`GetReferenceFromLookupHash`, mock.Anything, alloc.ID, pathHash). - Return( - &reference.Ref{ - Name: "test", - Type: reference.FILE, - }, nil) + mockReferencePackage.On(`GetReferenceFromLookupHash`, mock.Anything, alloc.ID, pathHash).Return( + &reference.Ref{ + Name: "test", + Type: reference.FILE, + }, nil) + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + gotResponse, err := svc.UpdateObjectAttributes(ctx, req) + if err != nil { + t.Fatal("unexpected error - " + err.Error()) + } + + assert.Equal(t, gotResponse, resOk) +} + +func TestBlobberGRPCService_UpdateObjectAttributes_InvalidAllocation(t *testing.T) { + req := &blobbergrpc.UpdateObjectAttributesRequest{ + Allocation: `invalid_allocation`, + } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "client_key", + common.ClientSignatureHeader: "clientSignature", + })) + + mockStorageHandler := &storageHandlerI{} + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). + Return(nil, errors.New("some error")) + + mockReferencePackage := &mocks.PackageHandler{} - tests := []struct { - name string - fields fields - args args - wantResponse *blobbergrpc.UpdateObjectAttributesResponse - wantErr bool - }{ - { - name: `OK`, - fields: fields{ - storageHandler: mockStorageHandler, - packageHandler: mockReferencePackage, - }, - args: args{ - ctx: ctx, - r: req, - }, - wantResponse: resOk, - wantErr: false, - }, - { - name: `Invalid_Allocation`, - fields: fields{ - storageHandler: mockStorageHandler, - packageHandler: mockReferencePackage, - }, - args: args{ - ctx: ctx, - r: reqInvalid, - }, - wantResponse: nil, - wantErr: true, - }, + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + _, err := svc.UpdateObjectAttributes(ctx, req) + if err == nil { + t.Fatal("expected error") } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - b := &blobberGRPCService{ - storageHandler: tt.fields.storageHandler, - packageHandler: tt.fields.packageHandler, - UnimplementedBlobberServer: tt.fields.UnimplementedBlobberServer, - } - gotResponse, err := b.UpdateObjectAttributes(tt.args.ctx, tt.args.r) - if (err != nil) != tt.wantErr { - t.Errorf("UpdateObjectAttributes() error = %v, wantErr %v", err, tt.wantErr) - return - } - if !assert.Equal(t, gotResponse, tt.wantResponse) { - t.Errorf("UpdateObjectAttributes() gotResponse = %v, want %v", gotResponse, tt.wantResponse) - } - }) + if err.Error() != "invalid_parameters: Invalid allocation id passed.some error" { + t.Fatal(`unexpected error - `, err) } } From f478722a6133a60d04180bf563e0428601566e2e Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 11:52:04 +0530 Subject: [PATCH 044/183] mock files --- .../mocks/IAllocationChangeCollector.go | 115 ++++++++++++++++++ 1 file changed, 115 insertions(+) create mode 100644 code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go diff --git a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go b/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go new file mode 100644 index 000000000..287798e42 --- /dev/null +++ b/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go @@ -0,0 +1,115 @@ +// Code generated by mockery 2.7.5. DO NOT EDIT. + +package mocks + +import ( + context "context" + + allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + + mock "github.com/stretchr/testify/mock" +) + +// IAllocationChangeCollector is an autogenerated mock type for the IAllocationChangeCollector type +type IAllocationChangeCollector struct { + mock.Mock +} + +// AddChange provides a mock function with given fields: allocationChange, changeProcessor +func (_m *IAllocationChangeCollector) AddChange(allocationChange *allocation.AllocationChange, changeProcessor allocation.AllocationChangeProcessor) { + _m.Called(allocationChange, changeProcessor) +} + +// ApplyChanges provides a mock function with given fields: ctx, allocationRoot +func (_m *IAllocationChangeCollector) ApplyChanges(ctx context.Context, allocationRoot string) error { + ret := _m.Called(ctx, allocationRoot) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, string) error); ok { + r0 = rf(ctx, allocationRoot) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// CommitToFileStore provides a mock function with given fields: ctx +func (_m *IAllocationChangeCollector) CommitToFileStore(ctx context.Context) error { + ret := _m.Called(ctx) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context) error); ok { + r0 = rf(ctx) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// ComputeProperties provides a mock function with given fields: +func (_m *IAllocationChangeCollector) ComputeProperties() { + _m.Called() +} + +// DeleteChanges provides a mock function with given fields: ctx +func (_m *IAllocationChangeCollector) DeleteChanges(ctx context.Context) { + _m.Called(ctx) +} + +// GetAllocationID provides a mock function with given fields: +func (_m *IAllocationChangeCollector) GetAllocationID() string { + ret := _m.Called() + + var r0 string + if rf, ok := ret.Get(0).(func() string); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + +// GetConnectionID provides a mock function with given fields: +func (_m *IAllocationChangeCollector) GetConnectionID() string { + ret := _m.Called() + + var r0 string + if rf, ok := ret.Get(0).(func() string); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + +// Save provides a mock function with given fields: ctx +func (_m *IAllocationChangeCollector) Save(ctx context.Context) error { + ret := _m.Called(ctx) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context) error); ok { + r0 = rf(ctx) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// TableName provides a mock function with given fields: +func (_m *IAllocationChangeCollector) TableName() string { + ret := _m.Called() + + var r0 string + if rf, ok := ret.Get(0).(func() string); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} From 21e7c0c11d8c4875dc597f2cbdbe51f689b8d834 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 12:19:34 +0530 Subject: [PATCH 045/183] common changes added to grpc --- .../allocation/allocationchange.go | 35 +++++++++++++++++++ .../handler/object_operation_grpc_handler.go | 1 + ...operation_grpc_handler_integration_test.go | 1 + .../object_operation_grpc_handler_test.go | 1 + 4 files changed, 38 insertions(+) create mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go create mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go diff --git a/code/go/0chain.net/blobbercore/allocation/allocationchange.go b/code/go/0chain.net/blobbercore/allocation/allocationchange.go index 09c124885..967be49be 100644 --- a/code/go/0chain.net/blobbercore/allocation/allocationchange.go +++ b/code/go/0chain.net/blobbercore/allocation/allocationchange.go @@ -39,6 +39,21 @@ type AllocationChangeProcessor interface { Unmarshal(string) error } +type IAllocationChangeCollector interface { + TableName() string + AddChange(allocationChange *AllocationChange, changeProcessor AllocationChangeProcessor) + Save(ctx context.Context) error + ComputeProperties() + ApplyChanges(ctx context.Context, allocationRoot string) error + CommitToFileStore(ctx context.Context) error + DeleteChanges(ctx context.Context) + GetAllocationID() string + GetConnectionID() string + GetClientID() string + GetSize() int64 + SetSize(size int64) +} + type AllocationChangeCollector struct { ConnectionID string `gorm:"column:connection_id;primary_key"` AllocationID string `gorm:"column:allocation_id"` @@ -170,3 +185,23 @@ func (a *AllocationChangeCollector) DeleteChanges(ctx context.Context) { } } } + +func (cc *AllocationChangeCollector) GetAllocationID() string { + return cc.AllocationID +} + +func (cc *AllocationChangeCollector) GetConnectionID() string { + return cc.ConnectionID +} + +func (cc *AllocationChangeCollector) GetClientID() string { + return cc.ClientID +} + +func (cc *AllocationChangeCollector) GetSize() int64 { + return cc.Size +} + +func (cc *AllocationChangeCollector) SetSize(size int64) { + cc.Size = size +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go new file mode 100644 index 000000000..abeebd162 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -0,0 +1 @@ +package handler diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go new file mode 100644 index 000000000..abeebd162 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go @@ -0,0 +1 @@ +package handler diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go new file mode 100644 index 000000000..abeebd162 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -0,0 +1 @@ +package handler From 3846f168aeccf030aaf8a908da20847e6e47bf25 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 12:23:50 +0530 Subject: [PATCH 046/183] mock files --- .../mocks/IAllocationChangeCollector.go | 148 ++++++++++++++++++ 1 file changed, 148 insertions(+) create mode 100644 code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go diff --git a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go b/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go new file mode 100644 index 000000000..37556727b --- /dev/null +++ b/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go @@ -0,0 +1,148 @@ +// Code generated by mockery 2.7.5. DO NOT EDIT. + +package mocks + +import ( + context "context" + + allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + + mock "github.com/stretchr/testify/mock" +) + +// IAllocationChangeCollector is an autogenerated mock type for the IAllocationChangeCollector type +type IAllocationChangeCollector struct { + mock.Mock +} + +// AddChange provides a mock function with given fields: allocationChange, changeProcessor +func (_m *IAllocationChangeCollector) AddChange(allocationChange *allocation.AllocationChange, changeProcessor allocation.AllocationChangeProcessor) { + _m.Called(allocationChange, changeProcessor) +} + +// ApplyChanges provides a mock function with given fields: ctx, allocationRoot +func (_m *IAllocationChangeCollector) ApplyChanges(ctx context.Context, allocationRoot string) error { + ret := _m.Called(ctx, allocationRoot) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, string) error); ok { + r0 = rf(ctx, allocationRoot) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// CommitToFileStore provides a mock function with given fields: ctx +func (_m *IAllocationChangeCollector) CommitToFileStore(ctx context.Context) error { + ret := _m.Called(ctx) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context) error); ok { + r0 = rf(ctx) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// ComputeProperties provides a mock function with given fields: +func (_m *IAllocationChangeCollector) ComputeProperties() { + _m.Called() +} + +// DeleteChanges provides a mock function with given fields: ctx +func (_m *IAllocationChangeCollector) DeleteChanges(ctx context.Context) { + _m.Called(ctx) +} + +// GetAllocationID provides a mock function with given fields: +func (_m *IAllocationChangeCollector) GetAllocationID() string { + ret := _m.Called() + + var r0 string + if rf, ok := ret.Get(0).(func() string); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + +// GetClientID provides a mock function with given fields: +func (_m *IAllocationChangeCollector) GetClientID() string { + ret := _m.Called() + + var r0 string + if rf, ok := ret.Get(0).(func() string); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + +// GetConnectionID provides a mock function with given fields: +func (_m *IAllocationChangeCollector) GetConnectionID() string { + ret := _m.Called() + + var r0 string + if rf, ok := ret.Get(0).(func() string); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + +// GetSize provides a mock function with given fields: +func (_m *IAllocationChangeCollector) GetSize() int64 { + ret := _m.Called() + + var r0 int64 + if rf, ok := ret.Get(0).(func() int64); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(int64) + } + + return r0 +} + +// Save provides a mock function with given fields: ctx +func (_m *IAllocationChangeCollector) Save(ctx context.Context) error { + ret := _m.Called(ctx) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context) error); ok { + r0 = rf(ctx) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// SetSize provides a mock function with given fields: size +func (_m *IAllocationChangeCollector) SetSize(size int64) { + _m.Called(size) +} + +// TableName provides a mock function with given fields: +func (_m *IAllocationChangeCollector) TableName() string { + ret := _m.Called() + + var r0 string + if rf, ok := ret.Get(0).(func() string); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} From 6d282610199bcbec9eccd455381e21a3c93f7fd0 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 14:06:47 +0530 Subject: [PATCH 047/183] copy object handler grpc added --- .../blobbercore/blobbergrpc/blobber.pb.go | 696 ++++++++++++------ .../blobbercore/blobbergrpc/blobber.pb.gw.go | 115 +++ .../blobbergrpc/blobber_grpc.pb.go | 46 +- .../blobbergrpc/proto/blobber.proto | 25 + .../blobbercore/convert/responseHandler.go | 11 + .../0chain.net/blobbercore/handler/handler.go | 26 +- .../blobbercore/handler/handler_test.go | 2 +- .../0chain.net/blobbercore/handler/helper.go | 19 + .../handler/object_operation_grpc_handler.go | 113 +++ .../blobbercore/openapi/blobber.swagger.json | 86 +++ 10 files changed, 893 insertions(+), 246 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 2d21e6a7b..7b2865d7e 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.6.1 +// protoc v3.17.0 // source: blobber.proto package blobbergrpc @@ -1321,6 +1321,174 @@ func (x *GetAllocationResponse) GetAllocation() *Allocation { return nil } +type CopyObjectRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,3,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + ConnectionId string `protobuf:"bytes,4,opt,name=connection_id,json=connectionId,proto3" json:"connection_id,omitempty"` + Dest string `protobuf:"bytes,5,opt,name=dest,proto3" json:"dest,omitempty"` +} + +func (x *CopyObjectRequest) Reset() { + *x = CopyObjectRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CopyObjectRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CopyObjectRequest) ProtoMessage() {} + +func (x *CopyObjectRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[20] + 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 CopyObjectRequest.ProtoReflect.Descriptor instead. +func (*CopyObjectRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{20} +} + +func (x *CopyObjectRequest) GetAllocation() string { + if x != nil { + return x.Allocation + } + return "" +} + +func (x *CopyObjectRequest) GetPath() string { + if x != nil { + return x.Path + } + return "" +} + +func (x *CopyObjectRequest) GetPathHash() string { + if x != nil { + return x.PathHash + } + return "" +} + +func (x *CopyObjectRequest) GetConnectionId() string { + if x != nil { + return x.ConnectionId + } + return "" +} + +func (x *CopyObjectRequest) GetDest() string { + if x != nil { + return x.Dest + } + return "" +} + +type CopyObjectResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Filename string `protobuf:"bytes,1,opt,name=filename,proto3" json:"filename,omitempty"` + Size int64 `protobuf:"varint,2,opt,name=size,proto3" json:"size,omitempty"` + ContentHash string `protobuf:"bytes,3,opt,name=content_hash,json=contentHash,proto3" json:"content_hash,omitempty"` + MerkleRoot string `protobuf:"bytes,4,opt,name=merkle_root,json=merkleRoot,proto3" json:"merkle_root,omitempty"` + //UploadLength indicates the size of the entire upload in bytes. The value MUST be a non-negative integer. + UploadLength int64 `protobuf:"varint,5,opt,name=upload_length,json=uploadLength,proto3" json:"upload_length,omitempty"` + //Upload-Offset indicates a byte offset within a resource. The value MUST be a non-negative integer. + UploadOffset int64 `protobuf:"varint,6,opt,name=upload_offset,json=uploadOffset,proto3" json:"upload_offset,omitempty"` +} + +func (x *CopyObjectResponse) Reset() { + *x = CopyObjectResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CopyObjectResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CopyObjectResponse) ProtoMessage() {} + +func (x *CopyObjectResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[21] + 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 CopyObjectResponse.ProtoReflect.Descriptor instead. +func (*CopyObjectResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{21} +} + +func (x *CopyObjectResponse) GetFilename() string { + if x != nil { + return x.Filename + } + return "" +} + +func (x *CopyObjectResponse) GetSize() int64 { + if x != nil { + return x.Size + } + return 0 +} + +func (x *CopyObjectResponse) GetContentHash() string { + if x != nil { + return x.ContentHash + } + return "" +} + +func (x *CopyObjectResponse) GetMerkleRoot() string { + if x != nil { + return x.MerkleRoot + } + return "" +} + +func (x *CopyObjectResponse) GetUploadLength() int64 { + if x != nil { + return x.UploadLength + } + return 0 +} + +func (x *CopyObjectResponse) GetUploadOffset() int64 { + if x != nil { + return x.UploadOffset + } + return 0 +} + type Allocation struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -1348,7 +1516,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1361,7 +1529,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1374,7 +1542,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{22} } func (x *Allocation) GetID() string { @@ -1511,7 +1679,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1524,7 +1692,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1537,7 +1705,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{23} } func (x *Term) GetID() int64 { @@ -1588,7 +1756,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1601,7 +1769,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1614,7 +1782,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{24} } func (x *FileRef) GetType() string { @@ -1672,7 +1840,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1685,7 +1853,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1698,7 +1866,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{23} + return file_blobber_proto_rawDescGZIP(), []int{25} } func (x *FileMetaData) GetType() string { @@ -1889,7 +2057,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1902,7 +2070,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1915,7 +2083,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{24} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *DirMetaData) GetType() string { @@ -2181,196 +2349,228 @@ var file_blobber_proto_rawDesc = []byte{ 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, - 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, - 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, - 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, - 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, - 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, - 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, - 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, - 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, - 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, - 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, - 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, - 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, - 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x11, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, + 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, + 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, + 0x64, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x65, 0x73, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x64, 0x65, 0x73, 0x74, 0x22, 0xd2, 0x01, 0x0a, 0x12, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, + 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, + 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x1f, 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, + 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, + 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, + 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, + 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, + 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, + 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, + 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, + 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, + 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, + 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, + 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, + 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, + 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, + 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, + 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, + 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, + 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, + 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, + 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, + 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, + 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, + 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, + 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, + 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, + 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, + 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, + 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, + 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, + 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, + 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, + 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, + 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, + 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, + 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, + 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, + 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, + 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, + 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, + 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, + 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, - 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, - 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, - 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, - 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, - 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, + 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, + 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, + 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, + 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, + 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, + 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, + 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, + 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, + 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, + 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, + 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x32, 0xed, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, + 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, - 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, + 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, + 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, + 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, + 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, + 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, + 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, + 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, + 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, + 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, + 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, + 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, + 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x82, 0x01, 0x0a, + 0x0a, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, + 0x79, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, + 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, + 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, + 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2385,7 +2585,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 25) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 27) var file_blobber_proto_goTypes = []interface{}{ (*GetObjectTreeRequest)(nil), // 0: blobber.service.v1.GetObjectTreeRequest (*GetObjectTreeResponse)(nil), // 1: blobber.service.v1.GetObjectTreeResponse @@ -2407,34 +2607,36 @@ var file_blobber_proto_goTypes = []interface{}{ (*Collaborator)(nil), // 17: blobber.service.v1.Collaborator (*GetAllocationRequest)(nil), // 18: blobber.service.v1.GetAllocationRequest (*GetAllocationResponse)(nil), // 19: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 20: blobber.service.v1.Allocation - (*Term)(nil), // 21: blobber.service.v1.Term - (*FileRef)(nil), // 22: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 23: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 24: blobber.service.v1.DirMetaData + (*CopyObjectRequest)(nil), // 20: blobber.service.v1.CopyObjectRequest + (*CopyObjectResponse)(nil), // 21: blobber.service.v1.CopyObjectResponse + (*Allocation)(nil), // 22: blobber.service.v1.Allocation + (*Term)(nil), // 23: blobber.service.v1.Term + (*FileRef)(nil), // 24: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 25: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 26: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 4, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 8, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 4, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 8, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 22, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 4, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 7, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 8, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 22, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 22, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 22, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 22, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 22, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 22, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 24, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 24, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 24, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 24, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 13, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 22, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 17, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 20, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 21, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 23, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 24, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 22, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 23, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 25, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 26, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 16, // 21: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 18, // 22: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 14, // 23: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -2443,15 +2645,17 @@ var file_blobber_proto_depIdxs = []int32{ 5, // 26: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest 2, // 27: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest 0, // 28: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 19, // 29: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 15, // 30: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 12, // 31: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 10, // 32: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 6, // 33: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 3, // 34: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 1, // 35: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 29, // [29:36] is the sub-list for method output_type - 22, // [22:29] is the sub-list for method input_type + 20, // 29: blobber.service.v1.Blobber.CopyObject:input_type -> blobber.service.v1.CopyObjectRequest + 19, // 30: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 15, // 31: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 12, // 32: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 10, // 33: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 6, // 34: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 3, // 35: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 1, // 36: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 21, // 37: blobber.service.v1.Blobber.CopyObject:output_type -> blobber.service.v1.CopyObjectResponse + 30, // [30:38] is the sub-list for method output_type + 22, // [22:30] is the sub-list for method input_type 22, // [22:22] is the sub-list for extension type_name 22, // [22:22] is the sub-list for extension extendee 0, // [0:22] is the sub-list for field type_name @@ -2704,7 +2908,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*CopyObjectRequest); i { case 0: return &v.state case 1: @@ -2716,7 +2920,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*CopyObjectResponse); i { case 0: return &v.state case 1: @@ -2728,7 +2932,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -2740,7 +2944,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -2752,6 +2956,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -2770,7 +2998,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 25, + NumMessages: 27, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 50dc6d47f..7cb1fbdd5 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -487,6 +487,74 @@ func local_request_Blobber_GetObjectTree_0(ctx context.Context, marshaler runtim } +func request_Blobber_CopyObject_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CopyObjectRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := client.CopyObject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_CopyObject_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CopyObjectRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := server.CopyObject(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterBlobberHandlerServer registers the http handlers for service Blobber to "mux". // UnaryRPC :call BlobberServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -654,6 +722,29 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) + mux.Handle("POST", pattern_Blobber_CopyObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CopyObject") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_CopyObject_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_CopyObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -835,6 +926,26 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) + mux.Handle("POST", pattern_Blobber_CopyObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CopyObject") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_CopyObject_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_CopyObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -852,6 +963,8 @@ var ( pattern_Blobber_GetReferencePath_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "referencepath", "allocation"}, "")) pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) + + pattern_Blobber_CopyObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v1", "file", "copy", "allocation"}, "")) ) var ( @@ -868,4 +981,6 @@ var ( forward_Blobber_GetReferencePath_0 = runtime.ForwardResponseMessage forward_Blobber_GetObjectTree_0 = runtime.ForwardResponseMessage + + forward_Blobber_CopyObject_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index e73fdcaf5..ed1da3f3b 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -11,6 +11,7 @@ import ( // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 // BlobberClient is the client API for Blobber service. @@ -24,6 +25,7 @@ type BlobberClient interface { GetObjectPath(ctx context.Context, in *GetObjectPathRequest, opts ...grpc.CallOption) (*GetObjectPathResponse, error) GetReferencePath(ctx context.Context, in *GetReferencePathRequest, opts ...grpc.CallOption) (*GetReferencePathResponse, error) GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) + CopyObject(ctx context.Context, in *CopyObjectRequest, opts ...grpc.CallOption) (*CopyObjectResponse, error) } type blobberClient struct { @@ -97,6 +99,15 @@ func (c *blobberClient) GetObjectTree(ctx context.Context, in *GetObjectTreeRequ return out, nil } +func (c *blobberClient) CopyObject(ctx context.Context, in *CopyObjectRequest, opts ...grpc.CallOption) (*CopyObjectResponse, error) { + out := new(CopyObjectResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/CopyObject", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -108,6 +119,7 @@ type BlobberServer interface { GetObjectPath(context.Context, *GetObjectPathRequest) (*GetObjectPathResponse, error) GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) + CopyObject(context.Context, *CopyObjectRequest) (*CopyObjectResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -136,6 +148,9 @@ func (UnimplementedBlobberServer) GetReferencePath(context.Context, *GetReferenc func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetObjectTree not implemented") } +func (UnimplementedBlobberServer) CopyObject(context.Context, *CopyObjectRequest) (*CopyObjectResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CopyObject not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -145,8 +160,8 @@ type UnsafeBlobberServer interface { mustEmbedUnimplementedBlobberServer() } -func RegisterBlobberServer(s *grpc.Server, srv BlobberServer) { - s.RegisterService(&_Blobber_serviceDesc, srv) +func RegisterBlobberServer(s grpc.ServiceRegistrar, srv BlobberServer) { + s.RegisterService(&Blobber_ServiceDesc, srv) } func _Blobber_GetAllocation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { @@ -275,7 +290,28 @@ func _Blobber_GetObjectTree_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } -var _Blobber_serviceDesc = grpc.ServiceDesc{ +func _Blobber_CopyObject_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CopyObjectRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).CopyObject(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/CopyObject", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).CopyObject(ctx, req.(*CopyObjectRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Blobber_ServiceDesc is the grpc.ServiceDesc for Blobber service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Blobber_ServiceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), Methods: []grpc.MethodDesc{ @@ -307,6 +343,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "GetObjectTree", Handler: _Blobber_GetObjectTree_Handler, }, + { + MethodName: "CopyObject", + Handler: _Blobber_CopyObject_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index e02cfbd76..2c3d9799a 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -42,6 +42,13 @@ service Blobber { get: "/v2/file/objecttree/{allocation}" }; } + + rpc CopyObject(CopyObjectRequest) returns (CopyObjectResponse) { + option (google.api.http) = { + post: "/v1/file/copy/{allocation}" + body: "*" + }; + } } message GetObjectTreeRequest { @@ -166,6 +173,24 @@ message GetAllocationResponse { Allocation allocation = 1; } +message CopyObjectRequest { + string allocation = 1; + string path = 2; + string path_hash = 3; + string connection_id = 4; + string dest = 5; +} +message CopyObjectResponse { + string filename = 1; + int64 size = 2; + string content_hash = 3; + string merkle_root = 4; + //UploadLength indicates the size of the entire upload in bytes. The value MUST be a non-negative integer. + int64 upload_length = 5; + //Upload-Offset indicates a byte offset within a resource. The value MUST be a non-negative integer. + int64 upload_offset = 6; +} + message Allocation { string ID = 1; string Tx = 2; diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index e16a5177e..ce993db29 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -89,3 +89,14 @@ func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTr LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), } } + +func CopyObjectResponseHandler(copyObjectResponse *blobbergrpc.CopyObjectResponse) *blobberHTTP.UploadResult { + return &blobberHTTP.UploadResult{ + Filename: copyObjectResponse.Filename, + Size: copyObjectResponse.Size, + Hash: copyObjectResponse.ContentHash, + MerkleRoot: copyObjectResponse.MerkleRoot, + UploadLength: copyObjectResponse.UploadLength, + UploadOffset: copyObjectResponse.UploadOffset, + } +} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 5d001aafc..39065dea8 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -40,7 +40,8 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) - r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) + r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common. + ToJSONResponse(WithConnection(CopyHandler(svc))))).Methods(http.MethodPost) r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler)))) @@ -299,14 +300,23 @@ func RenameHandler(ctx context.Context, r *http.Request) (interface{}, error) { return response, nil } -func CopyHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) - response, err := storageHandler.CopyObject(ctx, r) - if err != nil { - return nil, err - } +func CopyHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerGRPCContext(ctx, r) - return response, nil + copyObjResponse, err := svc.CopyObject(ctx, &blobbergrpc.CopyObjectRequest{ + Allocation: mux.Vars(r)["allocation"], + Path: r.FormValue("path"), + PathHash: r.FormValue("path_hash"), + ConnectionId: r.FormValue("connection_id"), + Dest: r.FormValue("dest"), + }) + if err != nil { + return nil, err + } + + return convert.CopyObjectResponseHandler(copyObjResponse), nil + } } /*UploadHandler is the handler to respond to upload requests fro clients*/ diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go index 0942083ee..9ab8dc4ac 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/handler_test.go @@ -149,7 +149,7 @@ func setupHandlers() (*mux.Router, map[string]string) { cName := "Copy" router.HandleFunc(cPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(CopyHandler), + WithReadOnlyConnection(CopyHandler(svc)), ), ), ).Name(cName) diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index d129bc7bd..a86587ba0 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -30,6 +30,8 @@ type StorageHandlerI interface { // PackageHandler is an interface for all static functions that may need to be mocked type PackageHandler interface { + GetReference(ctx context.Context, allocationID string, newPath string) (*reference.Ref, error) + GetReferenceLookup(ctx context.Context, allocationID string, path string) string GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) @@ -39,6 +41,8 @@ type PackageHandler interface { GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) + GetAllocationChanges(ctx context.Context, connectionID string, + allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) } @@ -68,6 +72,15 @@ func (r *packageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_ro return writemarker.GetWriteMarkerEntity(ctx, allocation_root) } +func (r *packageHandler) GetReference(ctx context.Context, allocationID string, newPath string) ( + *reference.Ref, error) { + return reference.GetReference(ctx, allocationID, newPath) +} + +func (r *packageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { + return reference.GetReferenceLookup(allocationID, path) +} + func (r *packageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { return reference.GetReferenceFromLookupHash(ctx, allocationID, path_hash) } @@ -83,3 +96,9 @@ func (r *packageHandler) GetCollaborators(ctx context.Context, refID int64) ([]r func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { return reference.IsACollaborator(ctx, refID, clientID) } + +func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, + allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { + + return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index abeebd162..28b752b9d 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -1 +1,114 @@ package handler + +import ( + "context" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/lock" + "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap/ctxzap" + "go.uber.org/zap" + "path/filepath" +) + +func (b *blobberGRPCService) CopyObject(ctx context.Context, r *blobbergrpc.CopyObjectRequest) ( + *blobbergrpc.CopyObjectResponse, error) { + + logger := ctxzap.Extract(ctx) + + allocationTx := r.Allocation + allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) + } + + md := GetGRPCMetaDataFromCtx(ctx) + valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) + if !valid || err != nil { + return nil, common.NewError("invalid_signature", "Invalid signature") + } + + clientID := md.Client + allocationID := allocationObj.ID + + if len(clientID) == 0 { + return nil, common.NewError("invalid_operation", "Invalid client") + } + + if len(clientID) == 0 || allocationObj.OwnerID != clientID { //already checked clientId ? + return nil, common. + NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + + if len(r.Dest) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid destination for operation") + } + + pathHash := r.PathHash + path := r.Path + if len(pathHash) == 0 { + if len(path) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid path") + } + pathHash = b.packageHandler.GetReferenceLookup(ctx, allocationObj.ID, path) + } + + connectionID := r.ConnectionId + if len(connectionID) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid connection id passed") + } + + connectionObj, err := b.packageHandler.GetAllocationChanges(ctx, connectionID, allocationID, clientID) + if err != nil { + return nil, common.NewError("meta_error", "Error reading metadata for connection") + } + + mutex := lock.GetMutex(connectionObj.TableName(), connectionID) + mutex.Lock() + defer mutex.Unlock() + + objectRef, err := b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, pathHash) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid file path. "+err.Error()) + } + + newPath := filepath.Join(r.Dest, objectRef.Name) + destRef, _ := b.packageHandler.GetReference(ctx, allocationID, newPath) + if destRef != nil { + return nil, common.NewError( + "invalid_parameters", "Invalid destination path. Object Already exists.") + } + + destRef, err = b.packageHandler.GetReference(ctx, allocationID, r.Dest) + if err != nil || destRef.Type != reference.DIRECTORY { + return nil, common.NewError( + "invalid_parameters", "Invalid destination path. Should be a valid directory.") + } + + allocationChange := &allocation.AllocationChange{} + allocationChange.ConnectionID = connectionObj.GetConnectionID() + allocationChange.Size = objectRef.Size + allocationChange.Operation = allocation.COPY_OPERATION + + dfc := &allocation.CopyFileChange{ConnectionID: connectionObj.GetConnectionID(), + AllocationID: connectionObj.GetAllocationID(), DestPath: r.Dest} + dfc.SrcPath = objectRef.Path + + connectionObj.SetSize(connectionObj.GetSize() + allocationChange.Size) + connectionObj.AddChange(allocationChange, dfc) + + err = connectionObj.Save(ctx) + if err != nil { + logger.Error("Error in writing the connection meta data", zap.Error(err)) + return nil, common.NewError("connection_write_error", "Error writing the connection meta data") + } + + result := &blobbergrpc.CopyObjectResponse{} + result.Filename = objectRef.Name + result.ContentHash = objectRef.Hash + result.MerkleRoot = objectRef.MerkleRoot + result.Size = objectRef.Size + + return result, nil +} diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index bb3789a42..c1e68d0e1 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -16,6 +16,44 @@ "application/json" ], "paths": { + "/v1/file/copy/{allocation}": { + "post": { + "operationId": "Blobber_CopyObject", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1CopyObjectResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1CopyObjectRequest" + } + } + ], + "tags": [ + "Blobber" + ] + } + }, "/v2/allocation": { "get": { "operationId": "Blobber_GetAllocation", @@ -433,6 +471,54 @@ } } }, + "v1CopyObjectRequest": { + "type": "object", + "properties": { + "allocation": { + "type": "string" + }, + "path": { + "type": "string" + }, + "pathHash": { + "type": "string" + }, + "connectionId": { + "type": "string" + }, + "dest": { + "type": "string" + } + } + }, + "v1CopyObjectResponse": { + "type": "object", + "properties": { + "filename": { + "type": "string" + }, + "size": { + "type": "string", + "format": "int64" + }, + "contentHash": { + "type": "string" + }, + "merkleRoot": { + "type": "string" + }, + "uploadLength": { + "type": "string", + "format": "int64", + "description": "UploadLength indicates the size of the entire upload in bytes. The value MUST be a non-negative integer." + }, + "uploadOffset": { + "type": "string", + "format": "int64", + "description": "Upload-Offset indicates a byte offset within a resource. The value MUST be a non-negative integer." + } + } + }, "v1DirMetaData": { "type": "object", "properties": { From 2e165d5fd514a5131b7b8dc3de22fbf3a2df62eb Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 14:06:57 +0530 Subject: [PATCH 048/183] copy object handler grpc tests added --- .../object_operation_grpc_handler_test.go | 121 ++++++++++++++++++ .../blobbercore/mocks/PackageHandler.go | 64 ++++++++- 2 files changed, 184 insertions(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go index abeebd162..e5662f9ca 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -1 +1,122 @@ package handler + +import ( + "context" + "errors" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/mock" + "google.golang.org/grpc/metadata" + "path/filepath" + "testing" +) + +func TestBlobberGRPCService_CopyObject_Success(t *testing.T) { + allocationTx := randString(32) + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + req := &blobbergrpc.CopyObjectRequest{ + Allocation: allocationTx, + Path: "path", + ConnectionId: "connection_id", + Dest: "dest", + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "client_key", + common.ClientSignatureHeader: clientSignature, + })) + + mockStorageHandler := &storageHandlerI{} + alloc := &allocation.Allocation{ + Tx: req.Allocation, + ID: req.Allocation, + OwnerID: `client`, + OwnerPublicKey: pubKey, + } + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). + Return(alloc, nil) + + mockAllocCollector := &mocks.IAllocationChangeCollector{} + mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) + mockAllocCollector.On(`GetAllocationID`).Return(req.Allocation) + mockAllocCollector.On(`SetSize`, mock.Anything).Return() + mockAllocCollector.On(`GetSize`).Return(int64(1)) + mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() + mockAllocCollector.On(`Save`, mock.Anything).Return(nil) + mockAllocCollector.On(`TableName`).Return(`allocation_connections`) + + mockReferencePackage := &mocks.PackageHandler{} + mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, + req.ConnectionId, alloc.ID, alloc.OwnerID).Return(mockAllocCollector, nil) + + pathHash := req.Allocation + `:` + req.Path + mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). + Return(pathHash) + + objectRef := &reference.Ref{ + Name: "test", + ContentHash: `hash`, + MerkleRoot: `root`, + Size: 1, + } + + mockReferencePackage.On(`GetReferenceFromLookupHash`, mock.Anything, alloc.ID, pathHash). + Return(objectRef, nil) + newPath := filepath.Join(req.Dest, objectRef.Name) + mockReferencePackage.On(`GetReference`, mock.Anything, alloc.ID, newPath). + Return(nil, nil) + mockReferencePackage.On(`GetReference`, mock.Anything, alloc.ID, req.Dest). + Return(&reference.Ref{Type: `d`}, nil) + + resOk := &blobbergrpc.CopyObjectResponse{ + Filename: objectRef.Name, + Size: objectRef.Size, + ContentHash: objectRef.Hash, + MerkleRoot: objectRef.MerkleRoot, + UploadLength: 0, + UploadOffset: 0, + } + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + gotResponse, err := svc.CopyObject(ctx, req) + if err != nil { + t.Fatal("unexpected error - " + err.Error()) + } + + assert.Equal(t, gotResponse, resOk) +} + +func TestBlobberGRPCService_CopyObject_InvalidAllocation(t *testing.T) { + req := &blobbergrpc.CopyObjectRequest{ + Allocation: `invalid_allocation`, + } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "client_key", + common.ClientSignatureHeader: "clientSignature", + })) + + mockStorageHandler := &storageHandlerI{} + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). + Return(nil, errors.New("some error")) + + mockReferencePackage := &mocks.PackageHandler{} + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + + _, err := svc.CopyObject(ctx, req) + if err == nil { + t.Fatal("expected error") + } + if err.Error() != "invalid_parameters: Invalid allocation id passed.some error" { + t.Fatal(`unexpected error - `, err) + } +} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 73c3dd36f..4275abc64 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -1,10 +1,12 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. +// Code generated by mockery 2.7.5. DO NOT EDIT. package mocks import ( context "context" + allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + mock "github.com/stretchr/testify/mock" reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" @@ -19,6 +21,29 @@ type PackageHandler struct { mock.Mock } +// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID +func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { + ret := _m.Called(ctx, connectionID, allocationID, clientID) + + var r0 allocation.IAllocationChangeCollector + if rf, ok := ret.Get(0).(func(context.Context, string, string, string) allocation.IAllocationChangeCollector); ok { + r0 = rf(ctx, connectionID, allocationID, clientID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(allocation.IAllocationChangeCollector) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { + r1 = rf(ctx, connectionID, allocationID, clientID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // GetCollaborators provides a mock function with given fields: ctx, refID func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { ret := _m.Called(ctx, refID) @@ -157,6 +182,29 @@ func (_m *PackageHandler) GetRefWithChildren(ctx context.Context, allocationID s return r0, r1 } +// GetReference provides a mock function with given fields: ctx, allocationID, newPath +func (_m *PackageHandler) GetReference(ctx context.Context, allocationID string, newPath string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, newPath) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, newPath) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, newPath) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // GetReferenceFromLookupHash provides a mock function with given fields: ctx, allocationID, path_hash func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { ret := _m.Called(ctx, allocationID, path_hash) @@ -180,6 +228,20 @@ func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, alloca return r0, r1 } +// GetReferenceLookup provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { + ret := _m.Called(ctx, allocationID, path) + + var r0 string + if rf, ok := ret.Get(0).(func(context.Context, string, string) string); ok { + r0 = rf(ctx, allocationID, path) + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + // GetReferencePathFromPaths provides a mock function with given fields: ctx, allocationID, paths func (_m *PackageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { ret := _m.Called(ctx, allocationID, paths) From 5f4ee7e72e72f17771798f1a2df2012c12f64873 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 14:46:34 +0530 Subject: [PATCH 049/183] rename object handler grpc added --- .../blobbercore/blobbergrpc/blobber.pb.go | 337 +++++++++++++++--- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 115 ++++++ .../blobbergrpc/blobber_grpc.pb.go | 46 ++- .../blobbergrpc/proto/blobber.proto | 24 ++ .../blobbercore/convert/responseHandler.go | 11 + .../0chain.net/blobbercore/handler/handler.go | 26 +- .../blobbercore/handler/handler_test.go | 2 +- .../0chain.net/blobbercore/handler/helper.go | 13 + .../handler/object_operation_grpc_handler.go | 98 +++++ .../blobbercore/openapi/blobber.swagger.json | 86 +++++ 10 files changed, 692 insertions(+), 66 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 2d21e6a7b..972d362a3 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.6.1 +// protoc v3.17.0 // source: blobber.proto package blobbergrpc @@ -1321,6 +1321,174 @@ func (x *GetAllocationResponse) GetAllocation() *Allocation { return nil } +type RenameObjectRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,3,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + ConnectionId string `protobuf:"bytes,4,opt,name=connection_id,json=connectionId,proto3" json:"connection_id,omitempty"` + NewName string `protobuf:"bytes,5,opt,name=new_name,json=newName,proto3" json:"new_name,omitempty"` +} + +func (x *RenameObjectRequest) Reset() { + *x = RenameObjectRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RenameObjectRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RenameObjectRequest) ProtoMessage() {} + +func (x *RenameObjectRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[20] + 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 RenameObjectRequest.ProtoReflect.Descriptor instead. +func (*RenameObjectRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{20} +} + +func (x *RenameObjectRequest) GetAllocation() string { + if x != nil { + return x.Allocation + } + return "" +} + +func (x *RenameObjectRequest) GetPath() string { + if x != nil { + return x.Path + } + return "" +} + +func (x *RenameObjectRequest) GetPathHash() string { + if x != nil { + return x.PathHash + } + return "" +} + +func (x *RenameObjectRequest) GetConnectionId() string { + if x != nil { + return x.ConnectionId + } + return "" +} + +func (x *RenameObjectRequest) GetNewName() string { + if x != nil { + return x.NewName + } + return "" +} + +type RenameObjectResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Filename string `protobuf:"bytes,1,opt,name=filename,proto3" json:"filename,omitempty"` + Size int64 `protobuf:"varint,2,opt,name=size,proto3" json:"size,omitempty"` + ContentHash string `protobuf:"bytes,3,opt,name=content_hash,json=contentHash,proto3" json:"content_hash,omitempty"` + MerkleRoot string `protobuf:"bytes,4,opt,name=merkle_root,json=merkleRoot,proto3" json:"merkle_root,omitempty"` + //UploadLength indicates the size of the entire upload in bytes. The value MUST be a non-negative integer. + UploadLength int64 `protobuf:"varint,5,opt,name=upload_length,json=uploadLength,proto3" json:"upload_length,omitempty"` + //Upload-Offset indicates a byte offset within a resource. The value MUST be a non-negative integer. + UploadOffset int64 `protobuf:"varint,6,opt,name=upload_offset,json=uploadOffset,proto3" json:"upload_offset,omitempty"` +} + +func (x *RenameObjectResponse) Reset() { + *x = RenameObjectResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RenameObjectResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RenameObjectResponse) ProtoMessage() {} + +func (x *RenameObjectResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[21] + 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 RenameObjectResponse.ProtoReflect.Descriptor instead. +func (*RenameObjectResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{21} +} + +func (x *RenameObjectResponse) GetFilename() string { + if x != nil { + return x.Filename + } + return "" +} + +func (x *RenameObjectResponse) GetSize() int64 { + if x != nil { + return x.Size + } + return 0 +} + +func (x *RenameObjectResponse) GetContentHash() string { + if x != nil { + return x.ContentHash + } + return "" +} + +func (x *RenameObjectResponse) GetMerkleRoot() string { + if x != nil { + return x.MerkleRoot + } + return "" +} + +func (x *RenameObjectResponse) GetUploadLength() int64 { + if x != nil { + return x.UploadLength + } + return 0 +} + +func (x *RenameObjectResponse) GetUploadOffset() int64 { + if x != nil { + return x.UploadOffset + } + return 0 +} + type Allocation struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -1348,7 +1516,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1361,7 +1529,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1374,7 +1542,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{22} } func (x *Allocation) GetID() string { @@ -1511,7 +1679,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1524,7 +1692,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1537,7 +1705,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{23} } func (x *Term) GetID() int64 { @@ -1588,7 +1756,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1601,7 +1769,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1614,7 +1782,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{24} } func (x *FileRef) GetType() string { @@ -1672,7 +1840,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1685,7 +1853,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1698,7 +1866,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{23} + return file_blobber_proto_rawDescGZIP(), []int{25} } func (x *FileMetaData) GetType() string { @@ -1889,7 +2057,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1902,7 +2070,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1915,7 +2083,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{24} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *DirMetaData) GetType() string { @@ -2181,7 +2349,31 @@ var file_blobber_proto_rawDesc = []byte{ 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa6, 0x01, 0x0a, 0x13, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, + 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, + 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, + 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, + 0x6e, 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6e, 0x65, 0x77, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e, 0x65, 0x77, 0x4e, 0x61, 0x6d, 0x65, 0x22, 0xd4, + 0x01, 0x0a, 0x14, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, + 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, + 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x65, + 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, + 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x65, + 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x75, + 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, + 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, + 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, + 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, @@ -2304,7 +2496,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, + 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xf5, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, @@ -2367,10 +2559,19 @@ var file_blobber_proto_rawDesc = []byte{ 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, - 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8a, 0x01, 0x0a, 0x0c, 0x52, 0x65, 0x6e, 0x61, + 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, + 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, + 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, + 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, + 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2385,7 +2586,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 25) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 27) var file_blobber_proto_goTypes = []interface{}{ (*GetObjectTreeRequest)(nil), // 0: blobber.service.v1.GetObjectTreeRequest (*GetObjectTreeResponse)(nil), // 1: blobber.service.v1.GetObjectTreeResponse @@ -2407,34 +2608,36 @@ var file_blobber_proto_goTypes = []interface{}{ (*Collaborator)(nil), // 17: blobber.service.v1.Collaborator (*GetAllocationRequest)(nil), // 18: blobber.service.v1.GetAllocationRequest (*GetAllocationResponse)(nil), // 19: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 20: blobber.service.v1.Allocation - (*Term)(nil), // 21: blobber.service.v1.Term - (*FileRef)(nil), // 22: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 23: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 24: blobber.service.v1.DirMetaData + (*RenameObjectRequest)(nil), // 20: blobber.service.v1.RenameObjectRequest + (*RenameObjectResponse)(nil), // 21: blobber.service.v1.RenameObjectResponse + (*Allocation)(nil), // 22: blobber.service.v1.Allocation + (*Term)(nil), // 23: blobber.service.v1.Term + (*FileRef)(nil), // 24: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 25: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 26: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 4, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 8, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 4, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 8, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 22, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 4, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 7, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 8, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 22, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 22, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 22, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 22, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 22, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 22, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 24, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 24, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 24, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 24, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 13, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 22, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 17, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 20, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 21, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 23, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 24, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 22, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 23, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 25, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 26, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 16, // 21: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 18, // 22: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 14, // 23: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -2443,15 +2646,17 @@ var file_blobber_proto_depIdxs = []int32{ 5, // 26: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest 2, // 27: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest 0, // 28: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 19, // 29: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 15, // 30: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 12, // 31: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 10, // 32: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 6, // 33: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 3, // 34: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 1, // 35: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 29, // [29:36] is the sub-list for method output_type - 22, // [22:29] is the sub-list for method input_type + 20, // 29: blobber.service.v1.Blobber.RenameObject:input_type -> blobber.service.v1.RenameObjectRequest + 19, // 30: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 15, // 31: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 12, // 32: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 10, // 33: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 6, // 34: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 3, // 35: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 1, // 36: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 21, // 37: blobber.service.v1.Blobber.RenameObject:output_type -> blobber.service.v1.RenameObjectResponse + 30, // [30:38] is the sub-list for method output_type + 22, // [22:30] is the sub-list for method input_type 22, // [22:22] is the sub-list for extension type_name 22, // [22:22] is the sub-list for extension extendee 0, // [0:22] is the sub-list for field type_name @@ -2704,7 +2909,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*RenameObjectRequest); i { case 0: return &v.state case 1: @@ -2716,7 +2921,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*RenameObjectResponse); i { case 0: return &v.state case 1: @@ -2728,7 +2933,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -2740,7 +2945,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -2752,6 +2957,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -2770,7 +2999,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 25, + NumMessages: 27, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 50dc6d47f..8516e3e02 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -487,6 +487,74 @@ func local_request_Blobber_GetObjectTree_0(ctx context.Context, marshaler runtim } +func request_Blobber_RenameObject_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RenameObjectRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := client.RenameObject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_RenameObject_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RenameObjectRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := server.RenameObject(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterBlobberHandlerServer registers the http handlers for service Blobber to "mux". // UnaryRPC :call BlobberServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -654,6 +722,29 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) + mux.Handle("POST", pattern_Blobber_RenameObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/RenameObject") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_RenameObject_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_RenameObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -835,6 +926,26 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) + mux.Handle("POST", pattern_Blobber_RenameObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/RenameObject") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_RenameObject_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_RenameObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -852,6 +963,8 @@ var ( pattern_Blobber_GetReferencePath_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "referencepath", "allocation"}, "")) pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) + + pattern_Blobber_RenameObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v1", "file", "rename", "allocation"}, "")) ) var ( @@ -868,4 +981,6 @@ var ( forward_Blobber_GetReferencePath_0 = runtime.ForwardResponseMessage forward_Blobber_GetObjectTree_0 = runtime.ForwardResponseMessage + + forward_Blobber_RenameObject_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index e73fdcaf5..126b9e98c 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -11,6 +11,7 @@ import ( // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 // BlobberClient is the client API for Blobber service. @@ -24,6 +25,7 @@ type BlobberClient interface { GetObjectPath(ctx context.Context, in *GetObjectPathRequest, opts ...grpc.CallOption) (*GetObjectPathResponse, error) GetReferencePath(ctx context.Context, in *GetReferencePathRequest, opts ...grpc.CallOption) (*GetReferencePathResponse, error) GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) + RenameObject(ctx context.Context, in *RenameObjectRequest, opts ...grpc.CallOption) (*RenameObjectResponse, error) } type blobberClient struct { @@ -97,6 +99,15 @@ func (c *blobberClient) GetObjectTree(ctx context.Context, in *GetObjectTreeRequ return out, nil } +func (c *blobberClient) RenameObject(ctx context.Context, in *RenameObjectRequest, opts ...grpc.CallOption) (*RenameObjectResponse, error) { + out := new(RenameObjectResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/RenameObject", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -108,6 +119,7 @@ type BlobberServer interface { GetObjectPath(context.Context, *GetObjectPathRequest) (*GetObjectPathResponse, error) GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) + RenameObject(context.Context, *RenameObjectRequest) (*RenameObjectResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -136,6 +148,9 @@ func (UnimplementedBlobberServer) GetReferencePath(context.Context, *GetReferenc func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetObjectTree not implemented") } +func (UnimplementedBlobberServer) RenameObject(context.Context, *RenameObjectRequest) (*RenameObjectResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RenameObject not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -145,8 +160,8 @@ type UnsafeBlobberServer interface { mustEmbedUnimplementedBlobberServer() } -func RegisterBlobberServer(s *grpc.Server, srv BlobberServer) { - s.RegisterService(&_Blobber_serviceDesc, srv) +func RegisterBlobberServer(s grpc.ServiceRegistrar, srv BlobberServer) { + s.RegisterService(&Blobber_ServiceDesc, srv) } func _Blobber_GetAllocation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { @@ -275,7 +290,28 @@ func _Blobber_GetObjectTree_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } -var _Blobber_serviceDesc = grpc.ServiceDesc{ +func _Blobber_RenameObject_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(RenameObjectRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).RenameObject(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/RenameObject", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).RenameObject(ctx, req.(*RenameObjectRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Blobber_ServiceDesc is the grpc.ServiceDesc for Blobber service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Blobber_ServiceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), Methods: []grpc.MethodDesc{ @@ -307,6 +343,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "GetObjectTree", Handler: _Blobber_GetObjectTree_Handler, }, + { + MethodName: "RenameObject", + Handler: _Blobber_RenameObject_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index e02cfbd76..ca00811e0 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -42,6 +42,12 @@ service Blobber { get: "/v2/file/objecttree/{allocation}" }; } + rpc RenameObject(RenameObjectRequest) returns (RenameObjectResponse) { + option (google.api.http) = { + post: "/v1/file/rename/{allocation}" + body: "*" + }; + } } message GetObjectTreeRequest { @@ -166,6 +172,24 @@ message GetAllocationResponse { Allocation allocation = 1; } +message RenameObjectRequest { + string allocation = 1; + string path = 2; + string path_hash = 3; + string connection_id = 4; + string new_name = 5; +} +message RenameObjectResponse { + string filename = 1; + int64 size = 2; + string content_hash = 3; + string merkle_root = 4; + //UploadLength indicates the size of the entire upload in bytes. The value MUST be a non-negative integer. + int64 upload_length = 5; + //Upload-Offset indicates a byte offset within a resource. The value MUST be a non-negative integer. + int64 upload_offset = 6; +} + message Allocation { string ID = 1; string Tx = 2; diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index e16a5177e..87ab4b79c 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -89,3 +89,14 @@ func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTr LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), } } + +func RenameObjectResponseHandler(renameObjectResponse *blobbergrpc.RenameObjectResponse) *blobberHTTP.UploadResult { + return &blobberHTTP.UploadResult{ + Filename: renameObjectResponse.Filename, + Size: renameObjectResponse.Size, + Hash: renameObjectResponse.ContentHash, + MerkleRoot: renameObjectResponse.MerkleRoot, + UploadLength: renameObjectResponse.UploadLength, + UploadOffset: renameObjectResponse.UploadOffset, + } +} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 5d001aafc..ba50a0d59 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -39,7 +39,8 @@ func SetupHandlers(r *mux.Router) { //object operations r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) - r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) + r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common. + ToJSONResponse(WithConnection(RenameHandler(svc))))).Methods(http.MethodPost) r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) @@ -289,14 +290,23 @@ func ObjectTreeHandler(svc *blobberGRPCService) func(ctx context.Context, r *htt } } -func RenameHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) - response, err := storageHandler.RenameObject(ctx, r) - if err != nil { - return nil, err - } +func RenameHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerGRPCContext(ctx, r) - return response, nil + renameObjResponse, err := svc.RenameObject(ctx, &blobbergrpc.RenameObjectRequest{ + Allocation: mux.Vars(r)["allocation"], + Path: r.FormValue("path"), + PathHash: r.FormValue("path_hash"), + ConnectionId: r.FormValue("connection_id"), + NewName: r.FormValue("new_name"), + }) + if err != nil { + return nil, err + } + + return convert.RenameObjectResponseHandler(renameObjResponse), nil + } } func CopyHandler(ctx context.Context, r *http.Request) (interface{}, error) { diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go index 0942083ee..400844ad4 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/handler_test.go @@ -140,7 +140,7 @@ func setupHandlers() (*mux.Router, map[string]string) { rName := "Rename" router.HandleFunc(rPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(RenameHandler), + WithReadOnlyConnection(RenameHandler(svc)), ), ), ).Name(rName) diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index d129bc7bd..41454c91d 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -30,6 +30,7 @@ type StorageHandlerI interface { // PackageHandler is an interface for all static functions that may need to be mocked type PackageHandler interface { + GetReferenceLookup(ctx context.Context, allocationID string, path string) string GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) @@ -39,6 +40,8 @@ type PackageHandler interface { GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) + GetAllocationChanges(ctx context.Context, connectionID string, + allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) } @@ -68,6 +71,10 @@ func (r *packageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_ro return writemarker.GetWriteMarkerEntity(ctx, allocation_root) } +func (r *packageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { + return reference.GetReferenceLookup(allocationID, path) +} + func (r *packageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { return reference.GetReferenceFromLookupHash(ctx, allocationID, path_hash) } @@ -83,3 +90,9 @@ func (r *packageHandler) GetCollaborators(ctx context.Context, refID int64) ([]r func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { return reference.IsACollaborator(ctx, refID, clientID) } + +func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, + allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { + + return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index abeebd162..ddbb09acd 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -1 +1,99 @@ package handler + +import ( + "context" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/lock" + "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap/ctxzap" + "go.uber.org/zap" +) + +func (b *blobberGRPCService) RenameObject(ctx context.Context, r *blobbergrpc.RenameObjectRequest) ( + *blobbergrpc.RenameObjectResponse, error) { + + logger := ctxzap.Extract(ctx) + + allocationTx := r.Allocation + allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) + } + + md := GetGRPCMetaDataFromCtx(ctx) + valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) + if !valid || err != nil { + return nil, common.NewError("invalid_signature", "Invalid signature") + } + + allocationID := allocationObj.ID + clientID := md.Client + + if len(clientID) == 0 { + return nil, common.NewError("invalid_operation", "Invalid client") + } + + if len(clientID) == 0 || allocationObj.OwnerID != clientID { + return nil, common. + NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + + newName := r.NewName + if len(newName) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid name") + } + + pathHash := r.PathHash + path := r.Path + if len(pathHash) == 0 { + if len(path) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid path") + } + pathHash = b.packageHandler.GetReferenceLookup(ctx, allocationObj.ID, path) + } + + connectionID := r.ConnectionId + if len(connectionID) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid connection id passed") + } + + connectionObj, err := b.packageHandler.GetAllocationChanges(ctx, connectionID, allocationID, clientID) + if err != nil { + return nil, common.NewError("meta_error", "Error reading metadata for connection") + } + + mutex := lock.GetMutex(connectionObj.TableName(), connectionID) + mutex.Lock() + defer mutex.Unlock() + + objectRef, err := b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, pathHash) + + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid file path. "+err.Error()) + } + + allocationChange := &allocation.AllocationChange{} + allocationChange.ConnectionID = connectionObj.GetConnectionID() + allocationChange.Size = 0 + allocationChange.Operation = allocation.RENAME_OPERATION + dfc := &allocation.RenameFileChange{ConnectionID: connectionObj.GetConnectionID(), + AllocationID: connectionObj.GetAllocationID(), Path: objectRef.Path} + dfc.NewName = newName + connectionObj.SetSize(connectionObj.GetSize() + allocationChange.Size) + connectionObj.AddChange(allocationChange, dfc) + + err = connectionObj.Save(ctx) + if err != nil { + logger.Error("Error in writing the connection meta data", zap.Error(err)) + return nil, common.NewError("connection_write_error", "Error writing the connection meta data") + } + + result := &blobbergrpc.RenameObjectResponse{} + result.Filename = newName + result.ContentHash = objectRef.Hash + result.MerkleRoot = objectRef.MerkleRoot + result.Size = objectRef.Size + + return result, nil +} diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index bb3789a42..cbc38e476 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -16,6 +16,44 @@ "application/json" ], "paths": { + "/v1/file/rename/{allocation}": { + "post": { + "operationId": "Blobber_RenameObject", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1RenameObjectResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1RenameObjectRequest" + } + } + ], + "tags": [ + "Blobber" + ] + } + }, "/v2/allocation": { "get": { "operationId": "Blobber_GetAllocation", @@ -738,6 +776,54 @@ } } }, + "v1RenameObjectRequest": { + "type": "object", + "properties": { + "allocation": { + "type": "string" + }, + "path": { + "type": "string" + }, + "pathHash": { + "type": "string" + }, + "connectionId": { + "type": "string" + }, + "newName": { + "type": "string" + } + } + }, + "v1RenameObjectResponse": { + "type": "object", + "properties": { + "filename": { + "type": "string" + }, + "size": { + "type": "string", + "format": "int64" + }, + "contentHash": { + "type": "string" + }, + "merkleRoot": { + "type": "string" + }, + "uploadLength": { + "type": "string", + "format": "int64", + "description": "UploadLength indicates the size of the entire upload in bytes. The value MUST be a non-negative integer." + }, + "uploadOffset": { + "type": "string", + "format": "int64", + "description": "Upload-Offset indicates a byte offset within a resource. The value MUST be a non-negative integer." + } + } + }, "v1Term": { "type": "object", "properties": { From 77dda14188a645e70cc31ee2c795bd0f6df1ee8c Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 14:46:49 +0530 Subject: [PATCH 050/183] rename object handler grpc tests added --- .../object_operation_grpc_handler_test.go | 111 ++++++++++++++++++ .../blobbercore/mocks/PackageHandler.go | 41 ++++++- 2 files changed, 151 insertions(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go index abeebd162..8254d47f2 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -1 +1,112 @@ package handler + +import ( + "context" + "errors" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/mock" + "google.golang.org/grpc/metadata" + "testing" +) + +func TestBlobberGRPCService_RenameObject_Success(t *testing.T) { + allocationTx := randString(32) + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + req := &blobbergrpc.RenameObjectRequest{ + Allocation: allocationTx, + Path: `path`, + ConnectionId: `connection_id`, + NewName: `new_name`, + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "client_key", + common.ClientSignatureHeader: clientSignature, + })) + + mockStorageHandler := &storageHandlerI{} + alloc := &allocation.Allocation{ + Tx: req.Allocation, + ID: `allocation_id`, + OwnerID: `client`, + OwnerPublicKey: pubKey, + } + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). + Return(alloc, nil) + + mockAllocCollector := &mocks.IAllocationChangeCollector{} + mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) + mockAllocCollector.On(`GetAllocationID`).Return(req.Allocation) + mockAllocCollector.On(`SetSize`, mock.Anything).Return() + mockAllocCollector.On(`GetSize`).Return(int64(1)) + mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() + mockAllocCollector.On(`Save`, mock.Anything).Return(nil) + mockAllocCollector.On(`TableName`).Return(`allocation_connections`) + + mockReferencePackage := &mocks.PackageHandler{} + mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, + req.ConnectionId, alloc.ID, `client`).Return(mockAllocCollector, nil) + + pathHash := req.Allocation + `:` + req.Path + mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). + Return(pathHash) + objectRef := &reference.Ref{ + Name: "test", + ContentHash: `hash`, + MerkleRoot: `root`, + Size: 1, + } + mockReferencePackage.On(`GetReferenceFromLookupHash`, mock.Anything, alloc.ID, pathHash). + Return(objectRef, nil) + + resOk := &blobbergrpc.RenameObjectResponse{ + Filename: req.NewName, + Size: objectRef.Size, + ContentHash: objectRef.Hash, + MerkleRoot: objectRef.MerkleRoot, + UploadLength: 0, + UploadOffset: 0, + } + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + gotResponse, err := svc.RenameObject(ctx, req) + if err != nil { + t.Fatal("unexpected error - " + err.Error()) + } + + assert.Equal(t, gotResponse, resOk) +} + +func TestBlobberGRPCService_RenameObject_InvalidAllocation(t *testing.T) { + req := &blobbergrpc.RenameObjectRequest{ + Allocation: `invalid_allocation`, + } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "client_key", + common.ClientSignatureHeader: "clientSignature", + })) + + mockStorageHandler := &storageHandlerI{} + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). + Return(nil, errors.New("some error")) + + mockReferencePackage := &mocks.PackageHandler{} + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + _, err := svc.RenameObject(ctx, req) + if err == nil { + t.Fatal("expected error") + } + if err.Error() != "invalid_parameters: Invalid allocation id passed.some error" { + t.Fatal(`unexpected error - `, err) + } +} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 73c3dd36f..2c3d4c11c 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -1,10 +1,12 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. +// Code generated by mockery 2.7.5. DO NOT EDIT. package mocks import ( context "context" + allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + mock "github.com/stretchr/testify/mock" reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" @@ -19,6 +21,29 @@ type PackageHandler struct { mock.Mock } +// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID +func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { + ret := _m.Called(ctx, connectionID, allocationID, clientID) + + var r0 allocation.IAllocationChangeCollector + if rf, ok := ret.Get(0).(func(context.Context, string, string, string) allocation.IAllocationChangeCollector); ok { + r0 = rf(ctx, connectionID, allocationID, clientID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(allocation.IAllocationChangeCollector) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { + r1 = rf(ctx, connectionID, allocationID, clientID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // GetCollaborators provides a mock function with given fields: ctx, refID func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { ret := _m.Called(ctx, refID) @@ -180,6 +205,20 @@ func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, alloca return r0, r1 } +// GetReferenceLookup provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { + ret := _m.Called(ctx, allocationID, path) + + var r0 string + if rf, ok := ret.Get(0).(func(context.Context, string, string) string); ok { + r0 = rf(ctx, allocationID, path) + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + // GetReferencePathFromPaths provides a mock function with given fields: ctx, allocationID, paths func (_m *PackageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { ret := _m.Called(ctx, allocationID, paths) From 89921d3702da092e87d6abe3748d5e711c9556bc Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 15:52:07 +0530 Subject: [PATCH 051/183] download file handler grpc added --- .../blobbercore/blobbergrpc/blobber.pb.go | 2101 ++++++++++------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 115 + .../blobbergrpc/blobber_grpc.pb.go | 46 +- .../blobbergrpc/proto/blobber.proto | 119 +- .../0chain.net/blobbercore/convert/convert.go | 41 + .../blobbercore/convert/responseHandler.go | 10 + .../0chain.net/blobbercore/handler/handler.go | 25 +- .../0chain.net/blobbercore/handler/helper.go | 33 + .../handler/object_operation_grpc_handler.go | 238 ++ .../blobbercore/handler/storage_handler.go | 6 + .../blobbercore/openapi/blobber.swagger.json | 133 ++ 11 files changed, 1973 insertions(+), 894 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 2d21e6a7b..47a5f11fb 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.6.1 +// protoc v3.17.0 // source: blobber.proto package blobbergrpc @@ -249,61 +249,6 @@ func (x *GetReferencePathResponse) GetLatestWM() *WriteMarker { return nil } -type ReferencePath struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - List []*ReferencePath `protobuf:"bytes,2,rep,name=List,proto3" json:"List,omitempty"` -} - -func (x *ReferencePath) Reset() { - *x = ReferencePath{} - if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *ReferencePath) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ReferencePath) ProtoMessage() {} - -func (x *ReferencePath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[4] - 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 ReferencePath.ProtoReflect.Descriptor instead. -func (*ReferencePath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{4} -} - -func (x *ReferencePath) GetMetaData() *FileRef { - if x != nil { - return x.MetaData - } - return nil -} - -func (x *ReferencePath) GetList() []*ReferencePath { - if x != nil { - return x.List - } - return nil -} - type GetObjectPathRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -317,7 +262,7 @@ type GetObjectPathRequest struct { func (x *GetObjectPathRequest) Reset() { *x = GetObjectPathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -330,7 +275,7 @@ func (x *GetObjectPathRequest) String() string { func (*GetObjectPathRequest) ProtoMessage() {} func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -343,7 +288,7 @@ func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathRequest.ProtoReflect.Descriptor instead. func (*GetObjectPathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{5} + return file_blobber_proto_rawDescGZIP(), []int{4} } func (x *GetObjectPathRequest) GetAllocation() string { @@ -379,7 +324,7 @@ type GetObjectPathResponse struct { func (x *GetObjectPathResponse) Reset() { *x = GetObjectPathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -392,7 +337,7 @@ func (x *GetObjectPathResponse) String() string { func (*GetObjectPathResponse) ProtoMessage() {} func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -405,7 +350,7 @@ func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathResponse.ProtoReflect.Descriptor instead. func (*GetObjectPathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{6} + return file_blobber_proto_rawDescGZIP(), []int{5} } func (x *GetObjectPathResponse) GetObjectPath() *ObjectPath { @@ -422,35 +367,34 @@ func (x *GetObjectPathResponse) GetLatestWriteMarker() *WriteMarker { return nil } -type ObjectPath struct { +type ListEntitiesRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RootHash string `protobuf:"bytes,1,opt,name=RootHash,proto3" json:"RootHash,omitempty"` - Meta *FileRef `protobuf:"bytes,2,opt,name=Meta,proto3" json:"Meta,omitempty"` - Path *FileRef `protobuf:"bytes,3,opt,name=Path,proto3" json:"Path,omitempty"` - PathList []*FileRef `protobuf:"bytes,4,rep,name=PathList,proto3" json:"PathList,omitempty"` - FileBlockNum int64 `protobuf:"varint,5,opt,name=FileBlockNum,proto3" json:"FileBlockNum,omitempty"` + Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + AuthToken string `protobuf:"bytes,3,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` + Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` } -func (x *ObjectPath) Reset() { - *x = ObjectPath{} +func (x *ListEntitiesRequest) Reset() { + *x = ListEntitiesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *ObjectPath) String() string { +func (x *ListEntitiesRequest) String() string { return protoimpl.X.MessageStringOf(x) } -func (*ObjectPath) ProtoMessage() {} +func (*ListEntitiesRequest) ProtoMessage() {} -func (x *ObjectPath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[7] +func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -461,78 +405,66 @@ func (x *ObjectPath) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use ObjectPath.ProtoReflect.Descriptor instead. -func (*ObjectPath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{7} +// Deprecated: Use ListEntitiesRequest.ProtoReflect.Descriptor instead. +func (*ListEntitiesRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{6} } -func (x *ObjectPath) GetRootHash() string { +func (x *ListEntitiesRequest) GetPath() string { if x != nil { - return x.RootHash + return x.Path } return "" } -func (x *ObjectPath) GetMeta() *FileRef { - if x != nil { - return x.Meta - } - return nil -} - -func (x *ObjectPath) GetPath() *FileRef { +func (x *ListEntitiesRequest) GetPathHash() string { if x != nil { - return x.Path + return x.PathHash } - return nil + return "" } -func (x *ObjectPath) GetPathList() []*FileRef { +func (x *ListEntitiesRequest) GetAuthToken() string { if x != nil { - return x.PathList + return x.AuthToken } - return nil + return "" } -func (x *ObjectPath) GetFileBlockNum() int64 { +func (x *ListEntitiesRequest) GetAllocation() string { if x != nil { - return x.FileBlockNum + return x.Allocation } - return 0 + return "" } -type WriteMarker struct { +type ListEntitiesResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` - PreviousAllocationRoot string `protobuf:"bytes,2,opt,name=PreviousAllocationRoot,proto3" json:"PreviousAllocationRoot,omitempty"` - AllocationID string `protobuf:"bytes,3,opt,name=AllocationID,proto3" json:"AllocationID,omitempty"` - Size int64 `protobuf:"varint,4,opt,name=Size,proto3" json:"Size,omitempty"` - BlobberID string `protobuf:"bytes,5,opt,name=BlobberID,proto3" json:"BlobberID,omitempty"` - Timestamp int64 `protobuf:"varint,6,opt,name=Timestamp,proto3" json:"Timestamp,omitempty"` - ClientID string `protobuf:"bytes,7,opt,name=ClientID,proto3" json:"ClientID,omitempty"` - Signature string `protobuf:"bytes,8,opt,name=Signature,proto3" json:"Signature,omitempty"` + AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` + MetaData *FileRef `protobuf:"bytes,2,opt,name=MetaData,proto3" json:"MetaData,omitempty"` + Entities []*FileRef `protobuf:"bytes,3,rep,name=Entities,proto3" json:"Entities,omitempty"` } -func (x *WriteMarker) Reset() { - *x = WriteMarker{} +func (x *ListEntitiesResponse) Reset() { + *x = ListEntitiesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *WriteMarker) String() string { +func (x *ListEntitiesResponse) String() string { return protoimpl.X.MessageStringOf(x) } -func (*WriteMarker) ProtoMessage() {} +func (*ListEntitiesResponse) ProtoMessage() {} -func (x *WriteMarker) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[8] +func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -543,95 +475,59 @@ func (x *WriteMarker) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use WriteMarker.ProtoReflect.Descriptor instead. -func (*WriteMarker) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{8} +// Deprecated: Use ListEntitiesResponse.ProtoReflect.Descriptor instead. +func (*ListEntitiesResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{7} } -func (x *WriteMarker) GetAllocationRoot() string { +func (x *ListEntitiesResponse) GetAllocationRoot() string { if x != nil { return x.AllocationRoot } return "" } -func (x *WriteMarker) GetPreviousAllocationRoot() string { - if x != nil { - return x.PreviousAllocationRoot - } - return "" -} - -func (x *WriteMarker) GetAllocationID() string { - if x != nil { - return x.AllocationID - } - return "" -} - -func (x *WriteMarker) GetSize() int64 { - if x != nil { - return x.Size - } - return 0 -} - -func (x *WriteMarker) GetBlobberID() string { - if x != nil { - return x.BlobberID - } - return "" -} - -func (x *WriteMarker) GetTimestamp() int64 { - if x != nil { - return x.Timestamp - } - return 0 -} - -func (x *WriteMarker) GetClientID() string { +func (x *ListEntitiesResponse) GetMetaData() *FileRef { if x != nil { - return x.ClientID + return x.MetaData } - return "" + return nil } -func (x *WriteMarker) GetSignature() string { +func (x *ListEntitiesResponse) GetEntities() []*FileRef { if x != nil { - return x.Signature + return x.Entities } - return "" + return nil } -type ListEntitiesRequest struct { +type GetFileStatsRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` - AuthToken string `protobuf:"bytes,3,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` - Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` + Allocation string `protobuf:"bytes,3,opt,name=allocation,proto3" json:"allocation,omitempty"` } -func (x *ListEntitiesRequest) Reset() { - *x = ListEntitiesRequest{} +func (x *GetFileStatsRequest) Reset() { + *x = GetFileStatsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *ListEntitiesRequest) String() string { +func (x *GetFileStatsRequest) String() string { return protoimpl.X.MessageStringOf(x) } -func (*ListEntitiesRequest) ProtoMessage() {} +func (*GetFileStatsRequest) ProtoMessage() {} -func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[9] +func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -642,51 +538,100 @@ func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use ListEntitiesRequest.ProtoReflect.Descriptor instead. -func (*ListEntitiesRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{9} +// Deprecated: Use GetFileStatsRequest.ProtoReflect.Descriptor instead. +func (*GetFileStatsRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{8} } -func (x *ListEntitiesRequest) GetPath() string { +func (x *GetFileStatsRequest) GetPath() string { if x != nil { return x.Path } return "" } -func (x *ListEntitiesRequest) GetPathHash() string { +func (x *GetFileStatsRequest) GetPathHash() string { if x != nil { return x.PathHash } return "" } -func (x *ListEntitiesRequest) GetAuthToken() string { - if x != nil { - return x.AuthToken - } - return "" -} - -func (x *ListEntitiesRequest) GetAllocation() string { +func (x *GetFileStatsRequest) GetAllocation() string { if x != nil { return x.Allocation } return "" } -type ListEntitiesResponse struct { +type GetFileStatsResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` - MetaData *FileRef `protobuf:"bytes,2,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - Entities []*FileRef `protobuf:"bytes,3,rep,name=Entities,proto3" json:"Entities,omitempty"` + MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` + Stats *FileStats `protobuf:"bytes,2,opt,name=Stats,proto3" json:"Stats,omitempty"` } -func (x *ListEntitiesResponse) Reset() { - *x = ListEntitiesResponse{} +func (x *GetFileStatsResponse) Reset() { + *x = GetFileStatsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetFileStatsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetFileStatsResponse) ProtoMessage() {} + +func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[9] + 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 GetFileStatsResponse.ProtoReflect.Descriptor instead. +func (*GetFileStatsResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{9} +} + +func (x *GetFileStatsResponse) GetMetaData() *FileRef { + if x != nil { + return x.MetaData + } + return nil +} + +func (x *GetFileStatsResponse) GetStats() *FileStats { + if x != nil { + return x.Stats + } + return nil +} + +type GetFileMetaDataRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + AuthToken string `protobuf:"bytes,3,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` + Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` +} + +func (x *GetFileMetaDataRequest) Reset() { + *x = GetFileMetaDataRequest{} if protoimpl.UnsafeEnabled { mi := &file_blobber_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -694,13 +639,13 @@ func (x *ListEntitiesResponse) Reset() { } } -func (x *ListEntitiesResponse) String() string { +func (x *GetFileMetaDataRequest) String() string { return protoimpl.X.MessageStringOf(x) } -func (*ListEntitiesResponse) ProtoMessage() {} +func (*GetFileMetaDataRequest) ProtoMessage() {} -func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { +func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { mi := &file_blobber_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -712,59 +657,404 @@ func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use ListEntitiesResponse.ProtoReflect.Descriptor instead. -func (*ListEntitiesResponse) Descriptor() ([]byte, []int) { +// Deprecated: Use GetFileMetaDataRequest.ProtoReflect.Descriptor instead. +func (*GetFileMetaDataRequest) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{10} } -func (x *ListEntitiesResponse) GetAllocationRoot() string { +func (x *GetFileMetaDataRequest) GetPath() string { if x != nil { - return x.AllocationRoot + return x.Path } return "" } -func (x *ListEntitiesResponse) GetMetaData() *FileRef { +func (x *GetFileMetaDataRequest) GetPathHash() string { + if x != nil { + return x.PathHash + } + return "" +} + +func (x *GetFileMetaDataRequest) GetAuthToken() string { + if x != nil { + return x.AuthToken + } + return "" +} + +func (x *GetFileMetaDataRequest) GetAllocation() string { + if x != nil { + return x.Allocation + } + return "" +} + +type GetFileMetaDataResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` + Collaborators []*Collaborator `protobuf:"bytes,2,rep,name=Collaborators,proto3" json:"Collaborators,omitempty"` +} + +func (x *GetFileMetaDataResponse) Reset() { + *x = GetFileMetaDataResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetFileMetaDataResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetFileMetaDataResponse) ProtoMessage() {} + +func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[11] + 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 GetFileMetaDataResponse.ProtoReflect.Descriptor instead. +func (*GetFileMetaDataResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{11} +} + +func (x *GetFileMetaDataResponse) GetMetaData() *FileRef { if x != nil { return x.MetaData } return nil } -func (x *ListEntitiesResponse) GetEntities() []*FileRef { +func (x *GetFileMetaDataResponse) GetCollaborators() []*Collaborator { if x != nil { - return x.Entities + return x.Collaborators } return nil } -type GetFileStatsRequest struct { +type GetAllocationRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` - PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` - Allocation string `protobuf:"bytes,3,opt,name=allocation,proto3" json:"allocation,omitempty"` + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` } -func (x *GetFileStatsRequest) Reset() { - *x = GetFileStatsRequest{} +func (x *GetAllocationRequest) Reset() { + *x = GetAllocationRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetAllocationRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetAllocationRequest) ProtoMessage() {} + +func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[12] + 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 GetAllocationRequest.ProtoReflect.Descriptor instead. +func (*GetAllocationRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{12} +} + +func (x *GetAllocationRequest) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +type GetAllocationResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Allocation *Allocation `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` +} + +func (x *GetAllocationResponse) Reset() { + *x = GetAllocationResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetAllocationResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetAllocationResponse) ProtoMessage() {} + +func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[13] + 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 GetAllocationResponse.ProtoReflect.Descriptor instead. +func (*GetAllocationResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{13} +} + +func (x *GetAllocationResponse) GetAllocation() *Allocation { + if x != nil { + return x.Allocation + } + return nil +} + +type DownloadFileRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,3,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + RxPay string `protobuf:"bytes,4,opt,name=rx_pay,json=rxPay,proto3" json:"rx_pay,omitempty"` + BlockNum string `protobuf:"bytes,5,opt,name=block_num,json=blockNum,proto3" json:"block_num,omitempty"` + NumBlocks string `protobuf:"bytes,6,opt,name=num_blocks,json=numBlocks,proto3" json:"num_blocks,omitempty"` + ReadMarker string `protobuf:"bytes,7,opt,name=read_marker,json=readMarker,proto3" json:"read_marker,omitempty"` + AuthToken string `protobuf:"bytes,8,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` + Content string `protobuf:"bytes,9,opt,name=content,proto3" json:"content,omitempty"` +} + +func (x *DownloadFileRequest) Reset() { + *x = DownloadFileRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *DownloadFileRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*DownloadFileRequest) ProtoMessage() {} + +func (x *DownloadFileRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[14] + 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 DownloadFileRequest.ProtoReflect.Descriptor instead. +func (*DownloadFileRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{14} +} + +func (x *DownloadFileRequest) GetAllocation() string { + if x != nil { + return x.Allocation + } + return "" +} + +func (x *DownloadFileRequest) GetPath() string { + if x != nil { + return x.Path + } + return "" +} + +func (x *DownloadFileRequest) GetPathHash() string { + if x != nil { + return x.PathHash + } + return "" +} + +func (x *DownloadFileRequest) GetRxPay() string { + if x != nil { + return x.RxPay + } + return "" +} + +func (x *DownloadFileRequest) GetBlockNum() string { + if x != nil { + return x.BlockNum + } + return "" +} + +func (x *DownloadFileRequest) GetNumBlocks() string { + if x != nil { + return x.NumBlocks + } + return "" +} + +func (x *DownloadFileRequest) GetReadMarker() string { + if x != nil { + return x.ReadMarker + } + return "" +} + +func (x *DownloadFileRequest) GetAuthToken() string { + if x != nil { + return x.AuthToken + } + return "" +} + +func (x *DownloadFileRequest) GetContent() string { + if x != nil { + return x.Content + } + return "" +} + +type DownloadFileResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"` + Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` + AllocationId string `protobuf:"bytes,3,opt,name=allocation_id,json=allocationId,proto3" json:"allocation_id,omitempty"` + Path string `protobuf:"bytes,4,opt,name=path,proto3" json:"path,omitempty"` + LatestRm *ReadMaker `protobuf:"bytes,5,opt,name=latest_rm,json=latestRm,proto3" json:"latest_rm,omitempty"` +} + +func (x *DownloadFileResponse) Reset() { + *x = DownloadFileResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *DownloadFileResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*DownloadFileResponse) ProtoMessage() {} + +func (x *DownloadFileResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[15] + 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 DownloadFileResponse.ProtoReflect.Descriptor instead. +func (*DownloadFileResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{15} +} + +func (x *DownloadFileResponse) GetSuccess() bool { + if x != nil { + return x.Success + } + return false +} + +func (x *DownloadFileResponse) GetData() []byte { + if x != nil { + return x.Data + } + return nil +} + +func (x *DownloadFileResponse) GetAllocationId() string { + if x != nil { + return x.AllocationId + } + return "" +} + +func (x *DownloadFileResponse) GetPath() string { + if x != nil { + return x.Path + } + return "" +} + +func (x *DownloadFileResponse) GetLatestRm() *ReadMaker { + if x != nil { + return x.LatestRm + } + return nil +} + +type ReferencePath struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` + List []*ReferencePath `protobuf:"bytes,2,rep,name=List,proto3" json:"List,omitempty"` +} + +func (x *ReferencePath) Reset() { + *x = ReferencePath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *GetFileStatsRequest) String() string { +func (x *ReferencePath) String() string { return protoimpl.X.MessageStringOf(x) } -func (*GetFileStatsRequest) ProtoMessage() {} +func (*ReferencePath) ProtoMessage() {} -func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[11] +func (x *ReferencePath) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -775,58 +1065,54 @@ func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use GetFileStatsRequest.ProtoReflect.Descriptor instead. -func (*GetFileStatsRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{11} -} - -func (x *GetFileStatsRequest) GetPath() string { - if x != nil { - return x.Path - } - return "" +// Deprecated: Use ReferencePath.ProtoReflect.Descriptor instead. +func (*ReferencePath) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{16} } -func (x *GetFileStatsRequest) GetPathHash() string { +func (x *ReferencePath) GetMetaData() *FileRef { if x != nil { - return x.PathHash + return x.MetaData } - return "" + return nil } -func (x *GetFileStatsRequest) GetAllocation() string { +func (x *ReferencePath) GetList() []*ReferencePath { if x != nil { - return x.Allocation + return x.List } - return "" + return nil } -type GetFileStatsResponse struct { +type ObjectPath struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - Stats *FileStats `protobuf:"bytes,2,opt,name=Stats,proto3" json:"Stats,omitempty"` + RootHash string `protobuf:"bytes,1,opt,name=RootHash,proto3" json:"RootHash,omitempty"` + Meta *FileRef `protobuf:"bytes,2,opt,name=Meta,proto3" json:"Meta,omitempty"` + Path *FileRef `protobuf:"bytes,3,opt,name=Path,proto3" json:"Path,omitempty"` + PathList []*FileRef `protobuf:"bytes,4,rep,name=PathList,proto3" json:"PathList,omitempty"` + FileBlockNum int64 `protobuf:"varint,5,opt,name=FileBlockNum,proto3" json:"FileBlockNum,omitempty"` } -func (x *GetFileStatsResponse) Reset() { - *x = GetFileStatsResponse{} +func (x *ObjectPath) Reset() { + *x = ObjectPath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *GetFileStatsResponse) String() string { +func (x *ObjectPath) String() string { return protoimpl.X.MessageStringOf(x) } -func (*GetFileStatsResponse) ProtoMessage() {} +func (*ObjectPath) ProtoMessage() {} -func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[12] +func (x *ObjectPath) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -837,25 +1123,46 @@ func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use GetFileStatsResponse.ProtoReflect.Descriptor instead. -func (*GetFileStatsResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{12} +// Deprecated: Use ObjectPath.ProtoReflect.Descriptor instead. +func (*ObjectPath) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{17} } -func (x *GetFileStatsResponse) GetMetaData() *FileRef { +func (x *ObjectPath) GetRootHash() string { if x != nil { - return x.MetaData + return x.RootHash + } + return "" +} + +func (x *ObjectPath) GetMeta() *FileRef { + if x != nil { + return x.Meta } return nil } -func (x *GetFileStatsResponse) GetStats() *FileStats { +func (x *ObjectPath) GetPath() *FileRef { if x != nil { - return x.Stats + return x.Path + } + return nil +} + +func (x *ObjectPath) GetPathList() []*FileRef { + if x != nil { + return x.PathList } return nil } +func (x *ObjectPath) GetFileBlockNum() int64 { + if x != nil { + return x.FileBlockNum + } + return 0 +} + type FileStats struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -876,7 +1183,7 @@ type FileStats struct { func (x *FileStats) Reset() { *x = FileStats{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -889,7 +1196,7 @@ func (x *FileStats) String() string { func (*FileStats) ProtoMessage() {} func (x *FileStats) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -902,7 +1209,7 @@ func (x *FileStats) ProtoReflect() protoreflect.Message { // Deprecated: Use FileStats.ProtoReflect.Descriptor instead. func (*FileStats) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{13} + return file_blobber_proto_rawDescGZIP(), []int{18} } func (x *FileStats) GetID() int64 { @@ -975,34 +1282,33 @@ func (x *FileStats) GetUpdatedAt() int64 { return 0 } -type GetFileMetaDataRequest struct { +type CommitMetaTxn struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` - PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` - AuthToken string `protobuf:"bytes,3,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` - Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` + RefId int64 `protobuf:"varint,1,opt,name=RefId,proto3" json:"RefId,omitempty"` + TxnId string `protobuf:"bytes,2,opt,name=TxnId,proto3" json:"TxnId,omitempty"` + CreatedAt int64 `protobuf:"varint,3,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` } -func (x *GetFileMetaDataRequest) Reset() { - *x = GetFileMetaDataRequest{} +func (x *CommitMetaTxn) Reset() { + *x = CommitMetaTxn{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[14] + mi := &file_blobber_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *GetFileMetaDataRequest) String() string { +func (x *CommitMetaTxn) String() string { return protoimpl.X.MessageStringOf(x) } -func (*GetFileMetaDataRequest) ProtoMessage() {} +func (*CommitMetaTxn) ProtoMessage() {} -func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[14] +func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1013,65 +1319,59 @@ func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use GetFileMetaDataRequest.ProtoReflect.Descriptor instead. -func (*GetFileMetaDataRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{14} -} - -func (x *GetFileMetaDataRequest) GetPath() string { - if x != nil { - return x.Path - } - return "" +// Deprecated: Use CommitMetaTxn.ProtoReflect.Descriptor instead. +func (*CommitMetaTxn) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{19} } -func (x *GetFileMetaDataRequest) GetPathHash() string { +func (x *CommitMetaTxn) GetRefId() int64 { if x != nil { - return x.PathHash + return x.RefId } - return "" + return 0 } -func (x *GetFileMetaDataRequest) GetAuthToken() string { +func (x *CommitMetaTxn) GetTxnId() string { if x != nil { - return x.AuthToken + return x.TxnId } return "" } -func (x *GetFileMetaDataRequest) GetAllocation() string { +func (x *CommitMetaTxn) GetCreatedAt() int64 { if x != nil { - return x.Allocation + return x.CreatedAt } - return "" + return 0 } -type GetFileMetaDataResponse struct { +type Collaborator struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - Collaborators []*Collaborator `protobuf:"bytes,2,rep,name=Collaborators,proto3" json:"Collaborators,omitempty"` + RefId int64 `protobuf:"varint,1,opt,name=RefId,proto3" json:"RefId,omitempty"` + ClientId string `protobuf:"bytes,2,opt,name=ClientId,proto3" json:"ClientId,omitempty"` + CreatedAt int64 `protobuf:"varint,3,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` } -func (x *GetFileMetaDataResponse) Reset() { - *x = GetFileMetaDataResponse{} +func (x *Collaborator) Reset() { + *x = Collaborator{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[15] + mi := &file_blobber_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *GetFileMetaDataResponse) String() string { +func (x *Collaborator) String() string { return protoimpl.X.MessageStringOf(x) } -func (*GetFileMetaDataResponse) ProtoMessage() {} +func (*Collaborator) ProtoMessage() {} -func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[15] +func (x *Collaborator) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1082,52 +1382,64 @@ func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use GetFileMetaDataResponse.ProtoReflect.Descriptor instead. -func (*GetFileMetaDataResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{15} +// Deprecated: Use Collaborator.ProtoReflect.Descriptor instead. +func (*Collaborator) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{20} } -func (x *GetFileMetaDataResponse) GetMetaData() *FileRef { +func (x *Collaborator) GetRefId() int64 { if x != nil { - return x.MetaData + return x.RefId } - return nil + return 0 } -func (x *GetFileMetaDataResponse) GetCollaborators() []*Collaborator { +func (x *Collaborator) GetClientId() string { if x != nil { - return x.Collaborators + return x.ClientId } - return nil + return "" } -type CommitMetaTxn struct { +func (x *Collaborator) GetCreatedAt() int64 { + if x != nil { + return x.CreatedAt + } + return 0 +} + +type WriteMarker struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RefId int64 `protobuf:"varint,1,opt,name=RefId,proto3" json:"RefId,omitempty"` - TxnId string `protobuf:"bytes,2,opt,name=TxnId,proto3" json:"TxnId,omitempty"` - CreatedAt int64 `protobuf:"varint,3,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` + AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` + PreviousAllocationRoot string `protobuf:"bytes,2,opt,name=PreviousAllocationRoot,proto3" json:"PreviousAllocationRoot,omitempty"` + AllocationID string `protobuf:"bytes,3,opt,name=AllocationID,proto3" json:"AllocationID,omitempty"` + Size int64 `protobuf:"varint,4,opt,name=Size,proto3" json:"Size,omitempty"` + BlobberID string `protobuf:"bytes,5,opt,name=BlobberID,proto3" json:"BlobberID,omitempty"` + Timestamp int64 `protobuf:"varint,6,opt,name=Timestamp,proto3" json:"Timestamp,omitempty"` + ClientID string `protobuf:"bytes,7,opt,name=ClientID,proto3" json:"ClientID,omitempty"` + Signature string `protobuf:"bytes,8,opt,name=Signature,proto3" json:"Signature,omitempty"` } -func (x *CommitMetaTxn) Reset() { - *x = CommitMetaTxn{} +func (x *WriteMarker) Reset() { + *x = WriteMarker{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[16] + mi := &file_blobber_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *CommitMetaTxn) String() string { +func (x *WriteMarker) String() string { return protoimpl.X.MessageStringOf(x) } -func (*CommitMetaTxn) ProtoMessage() {} +func (*WriteMarker) ProtoMessage() {} -func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[16] +func (x *WriteMarker) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1135,62 +1447,105 @@ func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { } return ms } - return mi.MessageOf(x) + return mi.MessageOf(x) +} + +// Deprecated: Use WriteMarker.ProtoReflect.Descriptor instead. +func (*WriteMarker) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{21} +} + +func (x *WriteMarker) GetAllocationRoot() string { + if x != nil { + return x.AllocationRoot + } + return "" +} + +func (x *WriteMarker) GetPreviousAllocationRoot() string { + if x != nil { + return x.PreviousAllocationRoot + } + return "" +} + +func (x *WriteMarker) GetAllocationID() string { + if x != nil { + return x.AllocationID + } + return "" +} + +func (x *WriteMarker) GetSize() int64 { + if x != nil { + return x.Size + } + return 0 } -// Deprecated: Use CommitMetaTxn.ProtoReflect.Descriptor instead. -func (*CommitMetaTxn) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{16} +func (x *WriteMarker) GetBlobberID() string { + if x != nil { + return x.BlobberID + } + return "" } -func (x *CommitMetaTxn) GetRefId() int64 { +func (x *WriteMarker) GetTimestamp() int64 { if x != nil { - return x.RefId + return x.Timestamp } return 0 } -func (x *CommitMetaTxn) GetTxnId() string { +func (x *WriteMarker) GetClientID() string { if x != nil { - return x.TxnId + return x.ClientID } return "" } -func (x *CommitMetaTxn) GetCreatedAt() int64 { +func (x *WriteMarker) GetSignature() string { if x != nil { - return x.CreatedAt + return x.Signature } - return 0 + return "" } -type Collaborator struct { +type ReadMaker struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RefId int64 `protobuf:"varint,1,opt,name=RefId,proto3" json:"RefId,omitempty"` - ClientId string `protobuf:"bytes,2,opt,name=ClientId,proto3" json:"ClientId,omitempty"` - CreatedAt int64 `protobuf:"varint,3,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` -} - -func (x *Collaborator) Reset() { - *x = Collaborator{} + ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` + ClientPublicKey string `protobuf:"bytes,2,opt,name=client_public_key,json=clientPublicKey,proto3" json:"client_public_key,omitempty"` + BlobberId string `protobuf:"bytes,3,opt,name=blobber_id,json=blobberId,proto3" json:"blobber_id,omitempty"` + AllocationId string `protobuf:"bytes,4,opt,name=allocation_id,json=allocationId,proto3" json:"allocation_id,omitempty"` + OwnerId string `protobuf:"bytes,5,opt,name=owner_id,json=ownerId,proto3" json:"owner_id,omitempty"` + Timestamp int64 `protobuf:"varint,6,opt,name=timestamp,proto3" json:"timestamp,omitempty"` + Counter int64 `protobuf:"varint,7,opt,name=counter,proto3" json:"counter,omitempty"` + Signature string `protobuf:"bytes,8,opt,name=signature,proto3" json:"signature,omitempty"` + Suspend int64 `protobuf:"varint,9,opt,name=suspend,proto3" json:"suspend,omitempty"` + PayerId string `protobuf:"bytes,10,opt,name=payer_id,json=payerId,proto3" json:"payer_id,omitempty"` + AuthTicket []byte `protobuf:"bytes,11,opt,name=auth_ticket,json=authTicket,proto3" json:"auth_ticket,omitempty"` +} + +func (x *ReadMaker) Reset() { + *x = ReadMaker{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[17] + mi := &file_blobber_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *Collaborator) String() string { +func (x *ReadMaker) String() string { return protoimpl.X.MessageStringOf(x) } -func (*Collaborator) ProtoMessage() {} +func (*ReadMaker) ProtoMessage() {} -func (x *Collaborator) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[17] +func (x *ReadMaker) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1201,122 +1556,84 @@ func (x *Collaborator) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use Collaborator.ProtoReflect.Descriptor instead. -func (*Collaborator) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{17} +// Deprecated: Use ReadMaker.ProtoReflect.Descriptor instead. +func (*ReadMaker) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{22} } -func (x *Collaborator) GetRefId() int64 { +func (x *ReadMaker) GetClientId() string { if x != nil { - return x.RefId + return x.ClientId } - return 0 + return "" } -func (x *Collaborator) GetClientId() string { +func (x *ReadMaker) GetClientPublicKey() string { if x != nil { - return x.ClientId + return x.ClientPublicKey } return "" } -func (x *Collaborator) GetCreatedAt() int64 { +func (x *ReadMaker) GetBlobberId() string { if x != nil { - return x.CreatedAt + return x.BlobberId } - return 0 -} - -type GetAllocationRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + return "" } -func (x *GetAllocationRequest) Reset() { - *x = GetAllocationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) +func (x *ReadMaker) GetAllocationId() string { + if x != nil { + return x.AllocationId } + return "" } -func (x *GetAllocationRequest) String() string { - return protoimpl.X.MessageStringOf(x) +func (x *ReadMaker) GetOwnerId() string { + if x != nil { + return x.OwnerId + } + return "" } -func (*GetAllocationRequest) ProtoMessage() {} - -func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms +func (x *ReadMaker) GetTimestamp() int64 { + if x != nil { + return x.Timestamp } - return mi.MessageOf(x) + return 0 } -// Deprecated: Use GetAllocationRequest.ProtoReflect.Descriptor instead. -func (*GetAllocationRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{18} +func (x *ReadMaker) GetCounter() int64 { + if x != nil { + return x.Counter + } + return 0 } -func (x *GetAllocationRequest) GetId() string { +func (x *ReadMaker) GetSignature() string { if x != nil { - return x.Id + return x.Signature } return "" } -type GetAllocationResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Allocation *Allocation `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` -} - -func (x *GetAllocationResponse) Reset() { - *x = GetAllocationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) +func (x *ReadMaker) GetSuspend() int64 { + if x != nil { + return x.Suspend } + return 0 } -func (x *GetAllocationResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetAllocationResponse) ProtoMessage() {} - -func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms +func (x *ReadMaker) GetPayerId() string { + if x != nil { + return x.PayerId } - return mi.MessageOf(x) -} - -// Deprecated: Use GetAllocationResponse.ProtoReflect.Descriptor instead. -func (*GetAllocationResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{19} + return "" } -func (x *GetAllocationResponse) GetAllocation() *Allocation { +func (x *ReadMaker) GetAuthTicket() []byte { if x != nil { - return x.Allocation + return x.AuthTicket } return nil } @@ -1348,7 +1665,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1361,7 +1678,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1374,7 +1691,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{23} } func (x *Allocation) GetID() string { @@ -1511,7 +1828,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1524,7 +1841,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1537,7 +1854,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{24} } func (x *Term) GetID() int64 { @@ -1588,7 +1905,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1601,7 +1918,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1614,7 +1931,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{25} } func (x *FileRef) GetType() string { @@ -1672,7 +1989,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1685,7 +2002,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1698,7 +2015,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{23} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *FileMetaData) GetType() string { @@ -1889,7 +2206,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1902,7 +2219,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1915,7 +2232,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{24} + return file_blobber_proto_rawDescGZIP(), []int{27} } func (x *DirMetaData) GetType() string { @@ -2026,351 +2343,411 @@ var file_blobber_proto_rawDesc = []byte{ 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, - 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, - 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, - 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, - 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, - 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, - 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, - 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, - 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, - 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, + 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, + 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, + 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, + 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, + 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, + 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, + 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, + 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, + 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, + 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, + 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, - 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, - 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, - 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, - 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, - 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, - 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, - 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, - 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, - 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, - 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, - 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, - 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, - 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, - 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, - 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, - 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, + 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, - 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, - 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, - 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, - 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, - 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, - 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, - 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, - 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, - 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, - 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, - 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, - 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, - 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, - 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, - 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, - 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, - 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, - 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, - 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, - 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, + 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, + 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, + 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, + 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, + 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, - 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, - 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, - 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, - 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, - 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, - 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, - 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, - 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, - 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, - 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, - 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, - 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, - 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, - 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, - 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, - 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, - 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, - 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, - 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, - 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, - 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, + 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, + 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, + 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, + 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, + 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, + 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, + 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, + 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, + 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, - 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, + 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x93, 0x02, 0x0a, 0x13, 0x44, 0x6f, + 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, + 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x15, 0x0a, 0x06, 0x72, 0x78, 0x5f, 0x70, 0x61, 0x79, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x05, 0x72, 0x78, 0x50, 0x61, 0x79, 0x12, 0x1b, 0x0a, 0x09, 0x62, 0x6c, 0x6f, + 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x6c, + 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x12, 0x1d, 0x0a, 0x0a, 0x6e, 0x75, 0x6d, 0x5f, 0x62, 0x6c, + 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x6e, 0x75, 0x6d, 0x42, + 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1f, 0x0a, 0x0b, 0x72, 0x65, 0x61, 0x64, 0x5f, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x72, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x72, 0x65, 0x61, 0x64, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, + 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, + 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, + 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x22, + 0xb9, 0x01, 0x0a, 0x14, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x63, 0x63, + 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, + 0x73, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, + 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, + 0x3a, 0x0a, 0x09, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x72, 0x6d, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x6b, 0x65, + 0x72, 0x52, 0x08, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x6d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, - 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0xe7, 0x01, 0x0a, + 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, + 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, + 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, + 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, + 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, + 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, + 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, + 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, + 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, + 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, + 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, + 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, + 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, + 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, + 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, + 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, + 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, + 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, + 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, + 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, + 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, + 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x59, + 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, + 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, + 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, + 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, + 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, + 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, + 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, + 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, + 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, + 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, + 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0xdf, 0x02, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, + 0x4d, 0x61, 0x6b, 0x65, 0x72, 0x12, 0x1b, 0x0a, 0x09, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, + 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, + 0x49, 0x64, 0x12, 0x2a, 0x0a, 0x11, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x70, 0x75, 0x62, + 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x63, + 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1d, + 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x64, 0x12, 0x23, 0x0a, + 0x0d, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1c, 0x0a, + 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x18, 0x0a, 0x07, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x65, 0x72, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, + 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, + 0x75, 0x72, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x73, 0x70, 0x65, 0x6e, 0x64, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x73, 0x75, 0x73, 0x70, 0x65, 0x6e, 0x64, 0x12, 0x19, 0x0a, + 0x08, 0x70, 0x61, 0x79, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x07, 0x70, 0x61, 0x79, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x75, 0x74, 0x68, + 0x5f, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x61, + 0x75, 0x74, 0x68, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, + 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, + 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, + 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, + 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, + 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, + 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, + 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, + 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, + 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, + 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, + 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, + 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, + 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, + 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, + 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, + 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, + 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, + 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, + 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, + 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, + 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, + 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, + 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, + 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, + 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, + 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, + 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, + 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, + 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, + 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, + 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, + 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, + 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, + 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, + 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, + 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, + 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, + 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, + 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, + 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, + 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, + 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, + 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, + 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, + 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, + 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, + 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, + 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, + 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, + 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, + 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x32, 0xf7, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, + 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, - 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, - 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, - 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, + 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, + 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, + 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, + 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, + 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, + 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, + 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, - 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, + 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, + 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8c, 0x01, 0x0a, 0x0c, + 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x27, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, + 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x64, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, + 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, + 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2385,76 +2762,82 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 25) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 28) var file_blobber_proto_goTypes = []interface{}{ (*GetObjectTreeRequest)(nil), // 0: blobber.service.v1.GetObjectTreeRequest (*GetObjectTreeResponse)(nil), // 1: blobber.service.v1.GetObjectTreeResponse (*GetReferencePathRequest)(nil), // 2: blobber.service.v1.GetReferencePathRequest (*GetReferencePathResponse)(nil), // 3: blobber.service.v1.GetReferencePathResponse - (*ReferencePath)(nil), // 4: blobber.service.v1.ReferencePath - (*GetObjectPathRequest)(nil), // 5: blobber.service.v1.GetObjectPathRequest - (*GetObjectPathResponse)(nil), // 6: blobber.service.v1.GetObjectPathResponse - (*ObjectPath)(nil), // 7: blobber.service.v1.ObjectPath - (*WriteMarker)(nil), // 8: blobber.service.v1.WriteMarker - (*ListEntitiesRequest)(nil), // 9: blobber.service.v1.ListEntitiesRequest - (*ListEntitiesResponse)(nil), // 10: blobber.service.v1.ListEntitiesResponse - (*GetFileStatsRequest)(nil), // 11: blobber.service.v1.GetFileStatsRequest - (*GetFileStatsResponse)(nil), // 12: blobber.service.v1.GetFileStatsResponse - (*FileStats)(nil), // 13: blobber.service.v1.FileStats - (*GetFileMetaDataRequest)(nil), // 14: blobber.service.v1.GetFileMetaDataRequest - (*GetFileMetaDataResponse)(nil), // 15: blobber.service.v1.GetFileMetaDataResponse - (*CommitMetaTxn)(nil), // 16: blobber.service.v1.CommitMetaTxn - (*Collaborator)(nil), // 17: blobber.service.v1.Collaborator - (*GetAllocationRequest)(nil), // 18: blobber.service.v1.GetAllocationRequest - (*GetAllocationResponse)(nil), // 19: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 20: blobber.service.v1.Allocation - (*Term)(nil), // 21: blobber.service.v1.Term - (*FileRef)(nil), // 22: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 23: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 24: blobber.service.v1.DirMetaData + (*GetObjectPathRequest)(nil), // 4: blobber.service.v1.GetObjectPathRequest + (*GetObjectPathResponse)(nil), // 5: blobber.service.v1.GetObjectPathResponse + (*ListEntitiesRequest)(nil), // 6: blobber.service.v1.ListEntitiesRequest + (*ListEntitiesResponse)(nil), // 7: blobber.service.v1.ListEntitiesResponse + (*GetFileStatsRequest)(nil), // 8: blobber.service.v1.GetFileStatsRequest + (*GetFileStatsResponse)(nil), // 9: blobber.service.v1.GetFileStatsResponse + (*GetFileMetaDataRequest)(nil), // 10: blobber.service.v1.GetFileMetaDataRequest + (*GetFileMetaDataResponse)(nil), // 11: blobber.service.v1.GetFileMetaDataResponse + (*GetAllocationRequest)(nil), // 12: blobber.service.v1.GetAllocationRequest + (*GetAllocationResponse)(nil), // 13: blobber.service.v1.GetAllocationResponse + (*DownloadFileRequest)(nil), // 14: blobber.service.v1.DownloadFileRequest + (*DownloadFileResponse)(nil), // 15: blobber.service.v1.DownloadFileResponse + (*ReferencePath)(nil), // 16: blobber.service.v1.ReferencePath + (*ObjectPath)(nil), // 17: blobber.service.v1.ObjectPath + (*FileStats)(nil), // 18: blobber.service.v1.FileStats + (*CommitMetaTxn)(nil), // 19: blobber.service.v1.CommitMetaTxn + (*Collaborator)(nil), // 20: blobber.service.v1.Collaborator + (*WriteMarker)(nil), // 21: blobber.service.v1.WriteMarker + (*ReadMaker)(nil), // 22: blobber.service.v1.ReadMaker + (*Allocation)(nil), // 23: blobber.service.v1.Allocation + (*Term)(nil), // 24: blobber.service.v1.Term + (*FileRef)(nil), // 25: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 26: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 27: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ - 4, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 8, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 4, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 8, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 22, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef - 4, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath - 7, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath - 8, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 22, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 22, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 22, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 22, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 22, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 22, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef - 13, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 22, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef - 17, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 20, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 21, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 23, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 24, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 16, // 21: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 18, // 22: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 14, // 23: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 11, // 24: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 9, // 25: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 5, // 26: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest - 2, // 27: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest - 0, // 28: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 19, // 29: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 15, // 30: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 12, // 31: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 10, // 32: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 6, // 33: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 3, // 34: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 1, // 35: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 29, // [29:36] is the sub-list for method output_type - 22, // [22:29] is the sub-list for method input_type - 22, // [22:22] is the sub-list for extension type_name - 22, // [22:22] is the sub-list for extension extendee - 0, // [0:22] is the sub-list for field type_name + 16, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 21, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 16, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 21, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 17, // 4: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath + 21, // 5: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker + 25, // 6: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 25, // 7: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 25, // 8: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 18, // 9: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats + 25, // 10: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 20, // 11: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 23, // 12: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 22, // 13: blobber.service.v1.DownloadFileResponse.latest_rm:type_name -> blobber.service.v1.ReadMaker + 25, // 14: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 16, // 15: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath + 25, // 16: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 25, // 17: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 25, // 18: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 24, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 26, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 27, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 19, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 12, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 10, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 8, // 25: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 6, // 26: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 4, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 2, // 28: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest + 0, // 29: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest + 14, // 30: blobber.service.v1.Blobber.DownloadFile:input_type -> blobber.service.v1.DownloadFileRequest + 13, // 31: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 11, // 32: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 9, // 33: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 7, // 34: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 5, // 35: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 3, // 36: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 1, // 37: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 15, // 38: blobber.service.v1.Blobber.DownloadFile:output_type -> blobber.service.v1.DownloadFileResponse + 31, // [31:39] is the sub-list for method output_type + 23, // [23:31] is the sub-list for method input_type + 23, // [23:23] is the sub-list for extension type_name + 23, // [23:23] is the sub-list for extension extendee + 0, // [0:23] is the sub-list for field type_name } func init() { file_blobber_proto_init() } @@ -2512,7 +2895,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReferencePath); i { + switch v := v.(*GetObjectPathRequest); i { case 0: return &v.state case 1: @@ -2524,7 +2907,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathRequest); i { + switch v := v.(*GetObjectPathResponse); i { case 0: return &v.state case 1: @@ -2536,7 +2919,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathResponse); i { + switch v := v.(*ListEntitiesRequest); i { case 0: return &v.state case 1: @@ -2548,7 +2931,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ObjectPath); i { + switch v := v.(*ListEntitiesResponse); i { case 0: return &v.state case 1: @@ -2560,7 +2943,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*WriteMarker); i { + switch v := v.(*GetFileStatsRequest); i { case 0: return &v.state case 1: @@ -2572,7 +2955,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesRequest); i { + switch v := v.(*GetFileStatsResponse); i { case 0: return &v.state case 1: @@ -2584,7 +2967,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesResponse); i { + switch v := v.(*GetFileMetaDataRequest); i { case 0: return &v.state case 1: @@ -2596,7 +2979,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsRequest); i { + switch v := v.(*GetFileMetaDataResponse); i { case 0: return &v.state case 1: @@ -2608,7 +2991,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsResponse); i { + switch v := v.(*GetAllocationRequest); i { case 0: return &v.state case 1: @@ -2620,7 +3003,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileStats); i { + switch v := v.(*GetAllocationResponse); i { case 0: return &v.state case 1: @@ -2632,7 +3015,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataRequest); i { + switch v := v.(*DownloadFileRequest); i { case 0: return &v.state case 1: @@ -2644,7 +3027,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataResponse); i { + switch v := v.(*DownloadFileResponse); i { case 0: return &v.state case 1: @@ -2656,7 +3039,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CommitMetaTxn); i { + switch v := v.(*ReferencePath); i { case 0: return &v.state case 1: @@ -2668,7 +3051,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Collaborator); i { + switch v := v.(*ObjectPath); i { case 0: return &v.state case 1: @@ -2680,7 +3063,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationRequest); i { + switch v := v.(*FileStats); i { case 0: return &v.state case 1: @@ -2692,7 +3075,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationResponse); i { + switch v := v.(*CommitMetaTxn); i { case 0: return &v.state case 1: @@ -2704,7 +3087,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*Collaborator); i { case 0: return &v.state case 1: @@ -2716,7 +3099,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*WriteMarker); i { case 0: return &v.state case 1: @@ -2728,7 +3111,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*ReadMaker); i { case 0: return &v.state case 1: @@ -2740,7 +3123,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -2752,6 +3135,42 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Term); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -2770,7 +3189,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 25, + NumMessages: 28, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 50dc6d47f..54adaa1cd 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -487,6 +487,74 @@ func local_request_Blobber_GetObjectTree_0(ctx context.Context, marshaler runtim } +func request_Blobber_DownloadFile_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DownloadFileRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := client.DownloadFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_DownloadFile_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DownloadFileRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := server.DownloadFile(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterBlobberHandlerServer registers the http handlers for service Blobber to "mux". // UnaryRPC :call BlobberServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -654,6 +722,29 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) + mux.Handle("POST", pattern_Blobber_DownloadFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/DownloadFile") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_DownloadFile_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_DownloadFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -835,6 +926,26 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) + mux.Handle("POST", pattern_Blobber_DownloadFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/DownloadFile") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_DownloadFile_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_DownloadFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -852,6 +963,8 @@ var ( pattern_Blobber_GetReferencePath_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "referencepath", "allocation"}, "")) pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) + + pattern_Blobber_DownloadFile_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v1", "file", "download", "allocation"}, "")) ) var ( @@ -868,4 +981,6 @@ var ( forward_Blobber_GetReferencePath_0 = runtime.ForwardResponseMessage forward_Blobber_GetObjectTree_0 = runtime.ForwardResponseMessage + + forward_Blobber_DownloadFile_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index e73fdcaf5..79e62293f 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -11,6 +11,7 @@ import ( // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 // BlobberClient is the client API for Blobber service. @@ -24,6 +25,7 @@ type BlobberClient interface { GetObjectPath(ctx context.Context, in *GetObjectPathRequest, opts ...grpc.CallOption) (*GetObjectPathResponse, error) GetReferencePath(ctx context.Context, in *GetReferencePathRequest, opts ...grpc.CallOption) (*GetReferencePathResponse, error) GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) + DownloadFile(ctx context.Context, in *DownloadFileRequest, opts ...grpc.CallOption) (*DownloadFileResponse, error) } type blobberClient struct { @@ -97,6 +99,15 @@ func (c *blobberClient) GetObjectTree(ctx context.Context, in *GetObjectTreeRequ return out, nil } +func (c *blobberClient) DownloadFile(ctx context.Context, in *DownloadFileRequest, opts ...grpc.CallOption) (*DownloadFileResponse, error) { + out := new(DownloadFileResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/DownloadFile", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -108,6 +119,7 @@ type BlobberServer interface { GetObjectPath(context.Context, *GetObjectPathRequest) (*GetObjectPathResponse, error) GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) + DownloadFile(context.Context, *DownloadFileRequest) (*DownloadFileResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -136,6 +148,9 @@ func (UnimplementedBlobberServer) GetReferencePath(context.Context, *GetReferenc func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetObjectTree not implemented") } +func (UnimplementedBlobberServer) DownloadFile(context.Context, *DownloadFileRequest) (*DownloadFileResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DownloadFile not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -145,8 +160,8 @@ type UnsafeBlobberServer interface { mustEmbedUnimplementedBlobberServer() } -func RegisterBlobberServer(s *grpc.Server, srv BlobberServer) { - s.RegisterService(&_Blobber_serviceDesc, srv) +func RegisterBlobberServer(s grpc.ServiceRegistrar, srv BlobberServer) { + s.RegisterService(&Blobber_ServiceDesc, srv) } func _Blobber_GetAllocation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { @@ -275,7 +290,28 @@ func _Blobber_GetObjectTree_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } -var _Blobber_serviceDesc = grpc.ServiceDesc{ +func _Blobber_DownloadFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(DownloadFileRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).DownloadFile(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/DownloadFile", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).DownloadFile(ctx, req.(*DownloadFileRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Blobber_ServiceDesc is the grpc.ServiceDesc for Blobber service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Blobber_ServiceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), Methods: []grpc.MethodDesc{ @@ -307,6 +343,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "GetObjectTree", Handler: _Blobber_GetObjectTree_Handler, }, + { + MethodName: "DownloadFile", + Handler: _Blobber_DownloadFile_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index e02cfbd76..a87982c58 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -42,6 +42,12 @@ service Blobber { get: "/v2/file/objecttree/{allocation}" }; } + rpc DownloadFile(DownloadFileRequest) returns (DownloadFileResponse) { + option (google.api.http) = { + post: "/v1/file/download/{allocation}" + body: "*" + }; + } } message GetObjectTreeRequest { @@ -63,11 +69,6 @@ message GetReferencePathResponse { WriteMarker LatestWM = 2; } -message ReferencePath { - FileRef MetaData = 1; - repeated ReferencePath List = 2; -} - message GetObjectPathRequest { string allocation = 1; string Path = 2; @@ -78,32 +79,12 @@ message GetObjectPathResponse { WriteMarker LatestWriteMarker = 2; } -message ObjectPath { - string RootHash = 1; - FileRef Meta = 2; - FileRef Path = 3; - repeated FileRef PathList = 4; - int64 FileBlockNum = 5; -} - -message WriteMarker { - string AllocationRoot = 1; - string PreviousAllocationRoot = 2; - string AllocationID = 3; - int64 Size = 4; - string BlobberID = 5; - int64 Timestamp = 6; - string ClientID = 7; - string Signature = 8; -} - message ListEntitiesRequest { string path = 1; string path_hash = 2; string auth_token = 3; string allocation = 4; } - message ListEntitiesResponse { string AllocationRoot = 1; FileRef MetaData = 2; @@ -115,12 +96,61 @@ message GetFileStatsRequest { string path_hash = 2; string allocation = 3; } - message GetFileStatsResponse { FileRef MetaData = 1; FileStats Stats = 2; } +message GetFileMetaDataRequest { + string path = 1; + string path_hash = 2; + string auth_token = 3; + string allocation = 4; +} +message GetFileMetaDataResponse { + FileRef MetaData = 1; + repeated Collaborator Collaborators = 2; +} + +message GetAllocationRequest { + string id = 1; +} +message GetAllocationResponse { + Allocation allocation = 1; +} + +message DownloadFileRequest { + string allocation = 1; + string path = 2; + string path_hash = 3; + string rx_pay = 4; + string block_num = 5; + string num_blocks = 6; + string read_marker = 7; + string auth_token = 8; + string content = 9; +} +message DownloadFileResponse { + bool success = 1; + bytes data = 2; + string allocation_id = 3; + string path = 4; + ReadMaker latest_rm = 5; +} + +message ReferencePath { + FileRef MetaData = 1; + repeated ReferencePath List = 2; +} + +message ObjectPath { + string RootHash = 1; + FileRef Meta = 2; + FileRef Path = 3; + repeated FileRef PathList = 4; + int64 FileBlockNum = 5; +} + message FileStats { int64 ID = 1; int64 RefID = 2; @@ -134,18 +164,6 @@ message FileStats { int64 UpdatedAt = 10; } -message GetFileMetaDataRequest { - string path = 1; - string path_hash = 2; - string auth_token = 3; - string allocation = 4; -} - -message GetFileMetaDataResponse { - FileRef MetaData = 1; - repeated Collaborator Collaborators = 2; -} - message CommitMetaTxn { int64 RefId = 1; string TxnId = 2; @@ -158,12 +176,29 @@ message Collaborator { int64 CreatedAt = 3; } -message GetAllocationRequest { - string id = 1; +message WriteMarker { + string AllocationRoot = 1; + string PreviousAllocationRoot = 2; + string AllocationID = 3; + int64 Size = 4; + string BlobberID = 5; + int64 Timestamp = 6; + string ClientID = 7; + string Signature = 8; } -message GetAllocationResponse { - Allocation allocation = 1; +message ReadMaker { + string client_id = 1; + string client_public_key = 2; + string blobber_id = 3; + string allocation_id = 4; + string owner_id = 5; + int64 timestamp = 6; + int64 counter = 7; + string signature = 8; + int64 suspend = 9; + string payer_id = 10; + bytes auth_ticket = 11; } message Allocation { diff --git a/code/go/0chain.net/blobbercore/convert/convert.go b/code/go/0chain.net/blobbercore/convert/convert.go index 73e7b1cdc..308ef6c87 100644 --- a/code/go/0chain.net/blobbercore/convert/convert.go +++ b/code/go/0chain.net/blobbercore/convert/convert.go @@ -2,6 +2,7 @@ package convert import ( "context" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" "time" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" @@ -138,6 +139,46 @@ func WriteMarkerGRPCToWriteMarker(wm *blobbergrpc.WriteMarker) *writemarker.Writ } } +func ReadMarkerToReadMarkerGRPC(rm *readmarker.ReadMarker) *blobbergrpc.ReadMaker { + if rm == nil { + return nil + } + + return &blobbergrpc.ReadMaker{ + ClientId: rm.ClientID, + ClientPublicKey: rm.ClientPublicKey, + BlobberId: rm.BlobberID, + AllocationId: rm.AllocationID, + OwnerId: rm.OwnerID, + Timestamp: int64(rm.Timestamp), + Counter: rm.ReadCounter, + Signature: rm.Signature, + Suspend: rm.Suspend, + PayerId: rm.PayerID, + AuthTicket: rm.AuthTicket, + } +} + +func ReadMakerGRPCToReadMaker(rm *blobbergrpc.ReadMaker) *readmarker.ReadMarker { + if rm == nil { + return nil + } + + return &readmarker.ReadMarker{ + ClientID: rm.ClientId, + ClientPublicKey: rm.ClientPublicKey, + BlobberID: rm.BlobberId, + AllocationID: rm.AllocationId, + OwnerID: rm.OwnerId, + Timestamp: common.Timestamp(rm.Timestamp), + ReadCounter: rm.Counter, + Signature: rm.Signature, + Suspend: rm.Suspend, + PayerID: rm.PayerId, + AuthTicket: rm.AuthTicket, + } +} + func FileStatsGRPCToFileStats(fileStats *blobbergrpc.FileStats) *stats.FileStats { if fileStats == nil { return nil diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index e16a5177e..840ffaf63 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -89,3 +89,13 @@ func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTr LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), } } + +func DownloadFileResponseHandler(downloadFileResponse *blobbergrpc.DownloadFileResponse) *blobberHTTP.DownloadResponse { + return &blobberHTTP.DownloadResponse{ + Success: downloadFileResponse.Success, + Data: downloadFileResponse.Data, + AllocationID: downloadFileResponse.AllocationId, + Path: downloadFileResponse.Path, + LatestRM: ReadMakerGRPCToReadMaker(downloadFileResponse.LatestRm), + } +} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 5d001aafc..26b5c0dfc 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -38,7 +38,8 @@ func SetupHandlers(r *mux.Router) { //object operations r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) - r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) + r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common. + ToByteStream(WithConnection(DownloadHandler(svc))))).Methods(http.MethodPost) r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) @@ -201,15 +202,23 @@ func FileStatsHandler(svc *blobberGRPCService) func(ctx context.Context, r *http } /*DownloadHandler is the handler to respond to download requests from clients*/ -func DownloadHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) +func DownloadHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerGRPCContext(ctx, r) - response, err := storageHandler.DownloadFile(ctx, r) - if err != nil { - return nil, err - } + downloadFileResponse, err := svc.DownloadFile(ctx, &blobbergrpc.DownloadFileRequest{ + Path: r.FormValue("path"), + PathHash: r.FormValue("path_hash"), + AuthToken: r.FormValue("auth_token"), + Allocation: mux.Vars(r)["allocation"], + }) + if err != nil { + return nil, err + } - return response, nil + //handle if there are two response type from handler + return convert.DownloadFileResponseHandler(downloadFileResponse), nil + } } /*ListHandler is the handler to respond to upload requests fro clients*/ diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index d129bc7bd..6878e4454 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -2,6 +2,8 @@ package handler import ( "context" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" @@ -24,12 +26,15 @@ func RegisterGRPCServices(r *mux.Router, server *grpc.Server) { } type StorageHandlerI interface { + readPreRedeem(ctx context.Context, alloc *allocation.Allocation, + numBlocks, pendNumBlocks int64, payerID string) (err error) verifyAllocation(ctx context.Context, tx string, readonly bool) (alloc *allocation.Allocation, err error) verifyAuthTicket(ctx context.Context, authTokenString string, allocationObj *allocation.Allocation, refRequested *reference.Ref, clientID string) (bool, error) } // PackageHandler is an interface for all static functions that may need to be mocked type PackageHandler interface { + GetReferenceLookup(ctx context.Context, allocationID string, path string) string GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) @@ -39,6 +44,12 @@ type PackageHandler interface { GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) + // write readmeker interface separately and add these two methods + GetLatestReadMarkerEntity(ctx context.Context, clientID string) (*readmarker.ReadMarkerEntity, error) + SaveLatestReadMarker(ctx context.Context, rm *readmarker.ReadMarker, isCreate bool) error + // write FileStat related methods in a different interface + GetFileStore() filestore.FileStore + FileBlockDownloaded(ctx context.Context, refID int64) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) } @@ -68,6 +79,10 @@ func (r *packageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_ro return writemarker.GetWriteMarkerEntity(ctx, allocation_root) } +func (r *packageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { + return reference.GetReferenceLookup(allocationID, path) +} + func (r *packageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { return reference.GetReferenceFromLookupHash(ctx, allocationID, path_hash) } @@ -83,3 +98,21 @@ func (r *packageHandler) GetCollaborators(ctx context.Context, refID int64) ([]r func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { return reference.IsACollaborator(ctx, refID, clientID) } + +func (r *packageHandler) GetLatestReadMarkerEntity(ctx context.Context, clientID string) ( + *readmarker.ReadMarkerEntity, error) { + + return readmarker.GetLatestReadMarkerEntity(ctx, clientID) +} + +func (r *packageHandler) SaveLatestReadMarker(ctx context.Context, rm *readmarker.ReadMarker, isCreate bool) error { + return readmarker.SaveLatestReadMarker(ctx, rm, isCreate) +} + +func (r *packageHandler) GetFileStore() filestore.FileStore { + return filestore.GetFileStore() +} + +func (r *packageHandler) FileBlockDownloaded(ctx context.Context, refID int64) { + stats.FileBlockDownloaded(ctx, refID) +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index abeebd162..0908819c4 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -1 +1,239 @@ package handler + +import ( + "context" + "encoding/json" + "errors" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "gorm.io/datatypes" + "gorm.io/gorm" + "strconv" +) + +func (b *blobberGRPCService) DownloadFile(ctx context.Context, r *blobbergrpc.DownloadFileRequest) ( + *blobbergrpc.DownloadFileResponse, error) { + + allocationTx := r.Allocation + allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) + } + + md := GetGRPCMetaDataFromCtx(ctx) + valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) + if !valid || err != nil { + return nil, common.NewError("invalid_signature", "Invalid signature") + } + var allocationID = allocationObj.ID + + clientID := md.Client + if len(clientID) == 0 || allocationObj.OwnerID != clientID { + return nil, common.NewError( + "invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + + rxPay := r.RxPay == "true" + pathHash := r.PathHash + path := r.Path + if len(pathHash) == 0 { + if len(path) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid path") + } + pathHash = b.packageHandler.GetReferenceLookup(ctx, allocationObj.ID, path) + } + + var blockNumStr = r.BlockNum + if len(blockNumStr) == 0 { + return nil, common.NewError("download_file", "no block number") + } + + var blockNum int64 + blockNum, err = strconv.ParseInt(blockNumStr, 10, 64) + if err != nil || blockNum < 0 { + return nil, common.NewError("download_file", "invalid block number") + } + + // we can add r.NumBlocks as int64 if len() validation is not required + var numBlocksStr = r.NumBlocks + if len(numBlocksStr) == 0 { + numBlocksStr = "1" + } + + var numBlocks int64 + numBlocks, err = strconv.ParseInt(numBlocksStr, 10, 64) + if err != nil || numBlocks < 0 { + return nil, common.NewError("download_file", + "invalid number of blocks") + } + + var ( + readMarkerString = r.ReadMarker + readMarker = &readmarker.ReadMarker{} + ) + err = json.Unmarshal([]byte(readMarkerString), readMarker) + if err != nil { + return nil, common.NewErrorf("download_file", "invalid parameters, "+ + "error parsing the readmarker for download: %v", err) + } + + var rmObj = &readmarker.ReadMarkerEntity{} + rmObj.LatestRM = readMarker + + if err = rmObj.VerifyMarker(ctx, allocationObj); err != nil { + return nil, common.NewErrorf("download_file", "invalid read marker, "+ + "failed to verify the read marker: %v", err) + } + + var fileref *reference.Ref + fileref, err = b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, pathHash) + if err != nil { + return nil, common.NewErrorf("download_file", + "invalid file path: %v", err) + } + if fileref.Type != reference.FILE { + return nil, common.NewErrorf("download_file", + "path is not a file: %v", err) + } + + var ( + authTokenString = r.AuthToken + clientIDForReadRedeem = clientID // default payer is client + isACollaborator = b.packageHandler.IsACollaborator(ctx, fileref.ID, clientID) + ) + // Owner will pay for collaborator + if isACollaborator { + clientIDForReadRedeem = allocationObj.OwnerID + } + + if (allocationObj.OwnerID != clientID && + allocationObj.PayerID != clientID && + !isACollaborator) || len(authTokenString) > 0 { + + var authTicketVerified bool + authTicketVerified, err = b.storageHandler.verifyAuthTicket(ctx, r.AuthToken, allocationObj, + fileref, clientID) + if err != nil { + return nil, common.NewErrorf("download_file", + "verifying auth ticket: %v", err) + } + + if !authTicketVerified { + return nil, common.NewErrorf("download_file", + "could not verify the auth ticket") + } + + var authToken = &readmarker.AuthTicket{} + err = json.Unmarshal([]byte(authTokenString), &authToken) + if err != nil { + return nil, common.NewErrorf("download_file", + "error parsing the auth ticket for download: %v", err) + } + + var attrs *reference.Attributes + if attrs, err = fileref.GetAttributes(); err != nil { + return nil, common.NewErrorf("download_file", + "error getting file attributes: %v", err) + } + + // if --rx_pay used 3rd_party pays + if rxPay { + clientIDForReadRedeem = clientID + } else if attrs.WhoPaysForReads == common.WhoPaysOwner { + clientIDForReadRedeem = allocationObj.OwnerID // owner pays + } + readMarker.AuthTicket = datatypes.JSON(authTokenString) + } + + var ( + rme *readmarker.ReadMarkerEntity + latestRM *readmarker.ReadMarker + pendNumBlocks int64 + ) + rme, err = b.packageHandler.GetLatestReadMarkerEntity(ctx, clientID) + if err != nil && !errors.Is(err, gorm.ErrRecordNotFound) { + return nil, common.NewErrorf("download_file", + "couldn't get read marker from DB: %v", err) + } + + if rme != nil { + latestRM = rme.LatestRM + if pendNumBlocks, err = rme.PendNumBlocks(); err != nil { + return nil, common.NewErrorf("download_file", + "couldn't get number of blocks pending redeeming: %v", err) + } + } + + if latestRM != nil && + latestRM.ReadCounter+(numBlocks) != readMarker.ReadCounter { + + var response = &blobbergrpc.DownloadFileResponse{ + Success: false, + LatestRm: convert.ReadMarkerToReadMarkerGRPC(latestRM), + Path: fileref.Path, + AllocationId: fileref.AllocationID, + } + return response, nil + } + + // check out read pool tokens if read_price > 0 + err = b.storageHandler.readPreRedeem(ctx, allocationObj, numBlocks, pendNumBlocks, + clientIDForReadRedeem) + if err != nil { + return nil, common.NewErrorf("download_file", + "pre-redeeming read marker: %v", err) + } + // reading allowed + + var ( + downloadMode = r.Content + respData []byte + ) + if len(downloadMode) > 0 && downloadMode == DOWNLOAD_CONTENT_THUMB { + var fileData = &filestore.FileInputData{} + fileData.Name = fileref.Name + fileData.Path = fileref.Path + fileData.Hash = fileref.ThumbnailHash + fileData.OnCloud = fileref.OnCloud + respData, err = b.packageHandler.GetFileStore().GetFileBlock(allocationID, + fileData, blockNum, numBlocks) + if err != nil { + return nil, common.NewErrorf("download_file", + "couldn't get thumbnail block: %v", err) + } + } else { + var fileData = &filestore.FileInputData{} + fileData.Name = fileref.Name + fileData.Path = fileref.Path + fileData.Hash = fileref.ContentHash + fileData.OnCloud = fileref.OnCloud + respData, err = b.packageHandler.GetFileStore().GetFileBlock(allocationID, + fileData, blockNum, numBlocks) + if err != nil { + return nil, common.NewErrorf("download_file", + "couldn't get file block: %v", err) + } + } + + readMarker.PayerID = clientIDForReadRedeem + err = b.packageHandler.SaveLatestReadMarker(ctx, readMarker, latestRM == nil) + if err != nil { + return nil, common.NewErrorf("download_file", + "couldn't save latest read marker: %v", err) + } + + var response = &blobbergrpc.DownloadFileResponse{} + response.Success = true + response.LatestRm = convert.ReadMarkerToReadMarkerGRPC(readMarker) + response.Data = respData + response.Path = fileref.Path + response.AllocationId = fileref.AllocationID + + b.packageHandler.FileBlockDownloaded(ctx, fileref.ID) + //originally here is respData, need to clarify + return response, nil +} diff --git a/code/go/0chain.net/blobbercore/handler/storage_handler.go b/code/go/0chain.net/blobbercore/handler/storage_handler.go index 20c593ba0..a90f9a9fa 100644 --- a/code/go/0chain.net/blobbercore/handler/storage_handler.go +++ b/code/go/0chain.net/blobbercore/handler/storage_handler.go @@ -81,6 +81,12 @@ func (fsh *StorageHandler) verifyAuthTicket(ctx context.Context, authTokenString return true, nil } +func (fsh *StorageHandler) readPreRedeem( + ctx context.Context, alloc *allocation.Allocation, numBlocks, pendNumBlocks int64, payerID string) (err error) { + + return readPreRedeem(ctx, alloc, numBlocks, pendNumBlocks, payerID) +} + func (fsh *StorageHandler) GetAllocationDetails(ctx context.Context, r *http.Request) (interface{}, error) { if r.Method != "GET" { return nil, common.NewError("invalid_method", "Invalid method used. Use GET instead") diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index bb3789a42..8b868a1fd 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -16,6 +16,44 @@ "application/json" ], "paths": { + "/v1/file/download/{allocation}": { + "post": { + "operationId": "Blobber_DownloadFile", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1DownloadFileResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1DownloadFileRequest" + } + } + ], + "tags": [ + "Blobber" + ] + } + }, "/v2/allocation": { "get": { "operationId": "Blobber_GetAllocation", @@ -472,6 +510,59 @@ } } }, + "v1DownloadFileRequest": { + "type": "object", + "properties": { + "allocation": { + "type": "string" + }, + "path": { + "type": "string" + }, + "pathHash": { + "type": "string" + }, + "rxPay": { + "type": "string" + }, + "blockNum": { + "type": "string" + }, + "numBlocks": { + "type": "string" + }, + "readMarker": { + "type": "string" + }, + "authToken": { + "type": "string" + }, + "content": { + "type": "string" + } + } + }, + "v1DownloadFileResponse": { + "type": "object", + "properties": { + "success": { + "type": "boolean" + }, + "data": { + "type": "string", + "format": "byte" + }, + "allocationId": { + "type": "string" + }, + "path": { + "type": "string" + }, + "latestRm": { + "$ref": "#/definitions/v1ReadMaker" + } + } + }, "v1FileMetaData": { "type": "object", "properties": { @@ -724,6 +815,48 @@ } } }, + "v1ReadMaker": { + "type": "object", + "properties": { + "clientId": { + "type": "string" + }, + "clientPublicKey": { + "type": "string" + }, + "blobberId": { + "type": "string" + }, + "allocationId": { + "type": "string" + }, + "ownerId": { + "type": "string" + }, + "timestamp": { + "type": "string", + "format": "int64" + }, + "counter": { + "type": "string", + "format": "int64" + }, + "signature": { + "type": "string" + }, + "suspend": { + "type": "string", + "format": "int64" + }, + "payerId": { + "type": "string" + }, + "authTicket": { + "type": "string", + "format": "byte" + } + } + }, "v1ReferencePath": { "type": "object", "properties": { From d0a4a7e512549aa9bdf6d60ffa36d2359c3956d2 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 22:35:25 +0530 Subject: [PATCH 052/183] read maker entity interface implemented --- .../0chain.net/blobbercore/handler/helper.go | 9 +++++++-- .../handler/object_operation_grpc_handler.go | 7 +++---- .../blobbercore/readmarker/entity.go | 4 ++++ .../blobbercore/readmarker/readmaker.go | 18 ++++++++++++++++++ 4 files changed, 32 insertions(+), 6 deletions(-) create mode 100644 code/go/0chain.net/blobbercore/readmarker/readmaker.go diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index 6878e4454..13cc86081 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -45,7 +45,8 @@ type PackageHandler interface { GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) // write readmeker interface separately and add these two methods - GetLatestReadMarkerEntity(ctx context.Context, clientID string) (*readmarker.ReadMarkerEntity, error) + GetNewReadMaker(rm *readmarker.ReadMarker) readmarker.ReadMakerI + GetLatestReadMarkerEntity(ctx context.Context, clientID string) (readmarker.ReadMakerI, error) SaveLatestReadMarker(ctx context.Context, rm *readmarker.ReadMarker, isCreate bool) error // write FileStat related methods in a different interface GetFileStore() filestore.FileStore @@ -100,7 +101,7 @@ func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clien } func (r *packageHandler) GetLatestReadMarkerEntity(ctx context.Context, clientID string) ( - *readmarker.ReadMarkerEntity, error) { + readmarker.ReadMakerI, error) { return readmarker.GetLatestReadMarkerEntity(ctx, clientID) } @@ -116,3 +117,7 @@ func (r *packageHandler) GetFileStore() filestore.FileStore { func (r *packageHandler) FileBlockDownloaded(ctx context.Context, refID int64) { stats.FileBlockDownloaded(ctx, refID) } + +func (r *packageHandler) GetNewReadMaker(rm *readmarker.ReadMarker) readmarker.ReadMakerI { + return readmarker.NewReadMakerEntity(rm) +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index 0908819c4..9ad6e9beb 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -81,8 +81,7 @@ func (b *blobberGRPCService) DownloadFile(ctx context.Context, r *blobbergrpc.Do "error parsing the readmarker for download: %v", err) } - var rmObj = &readmarker.ReadMarkerEntity{} - rmObj.LatestRM = readMarker + var rmObj = b.packageHandler.GetNewReadMaker(readMarker) if err = rmObj.VerifyMarker(ctx, allocationObj); err != nil { return nil, common.NewErrorf("download_file", "invalid read marker, "+ @@ -150,7 +149,7 @@ func (b *blobberGRPCService) DownloadFile(ctx context.Context, r *blobbergrpc.Do } var ( - rme *readmarker.ReadMarkerEntity + rme readmarker.ReadMakerI latestRM *readmarker.ReadMarker pendNumBlocks int64 ) @@ -161,7 +160,7 @@ func (b *blobberGRPCService) DownloadFile(ctx context.Context, r *blobbergrpc.Do } if rme != nil { - latestRM = rme.LatestRM + latestRM = rme.GetLatestRM() if pendNumBlocks, err = rme.PendNumBlocks(); err != nil { return nil, common.NewErrorf("download_file", "couldn't get number of blocks pending redeeming: %v", err) diff --git a/code/go/0chain.net/blobbercore/readmarker/entity.go b/code/go/0chain.net/blobbercore/readmarker/entity.go index 226590940..18f7f506d 100644 --- a/code/go/0chain.net/blobbercore/readmarker/entity.go +++ b/code/go/0chain.net/blobbercore/readmarker/entity.go @@ -204,3 +204,7 @@ func (rm *ReadMarkerEntity) UpdateStatus(ctx context.Context, return } + +func (rm *ReadMarkerEntity) GetLatestRM() *ReadMarker { + return rm.LatestRM +} diff --git a/code/go/0chain.net/blobbercore/readmarker/readmaker.go b/code/go/0chain.net/blobbercore/readmarker/readmaker.go new file mode 100644 index 000000000..a641a3720 --- /dev/null +++ b/code/go/0chain.net/blobbercore/readmarker/readmaker.go @@ -0,0 +1,18 @@ +package readmarker + +import ( + "context" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" +) + +type ReadMakerI interface { + VerifyMarker(ctx context.Context, sa *allocation.Allocation) error + GetLatestRM() *ReadMarker + PendNumBlocks() (pendNumBlocks int64, err error) +} + +func NewReadMakerEntity(rm *ReadMarker) ReadMakerI { + return &ReadMarkerEntity{ + LatestRM: rm, + } +} From aaeaddca58ae9ee947da39f910463635c3749f14 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 26 May 2021 22:36:20 +0530 Subject: [PATCH 053/183] download file handler grpc tests added --- .../handler/grpc_handler_helper_unit_test.go | 13 + .../object_operation_grpc_handler_test.go | 130 +++++++++ .../0chain.net/blobbercore/mocks/FileStore.go | 275 ++++++++++++++++++ .../blobbercore/mocks/PackageHandler.go | 94 +++++- .../blobbercore/mocks/ReadMakerI.go | 69 +++++ 5 files changed, 580 insertions(+), 1 deletion(-) create mode 100644 code/go/0chain.net/blobbercore/mocks/FileStore.go create mode 100644 code/go/0chain.net/blobbercore/mocks/ReadMakerI.go diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 0b286f5e1..42a93f010 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -28,6 +28,19 @@ type storageHandlerI struct { mock.Mock } +func (_m *storageHandlerI) readPreRedeem(ctx context.Context, alloc *allocation.Allocation, numBlocks, pendNumBlocks int64, payerID string) (err error) { + ret := _m.Called(ctx, alloc, numBlocks, pendNumBlocks, payerID) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *allocation.Allocation, int64, int64, string) error); ok { + r0 = rf(ctx, alloc, numBlocks, pendNumBlocks, payerID) + } else { + r0 = ret.Error(0) + } + + return r0 +} + // verifyAllocation provides a mock function with given fields: ctx, tx, readonly func (_m *storageHandlerI) verifyAllocation(ctx context.Context, tx string, readonly bool) (*allocation.Allocation, error) { ret := _m.Called(ctx, tx, readonly) diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go index abeebd162..dac353f78 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -1 +1,131 @@ package handler + +import ( + "context" + "errors" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/mock" + "google.golang.org/grpc/metadata" + "testing" +) + +func TestBlobberGRPCService_DownloadFile_Success(t *testing.T) { + allocationTx := randString(32) + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + req := &blobbergrpc.DownloadFileRequest{ + Allocation: allocationTx, + Path: `path`, + RxPay: "false", + NumBlocks: "5", + BlockNum: "5", + ReadMarker: `{}`, + AuthToken: "", + Content: "", + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "client_key", + common.ClientSignatureHeader: clientSignature, + })) + + alloc := &allocation.Allocation{ + Tx: req.Allocation, + ID: `allocation_id`, + OwnerID: `client`, + OwnerPublicKey: pubKey, + } + + mockReadMaker := &mocks.ReadMakerI{} + mockReadMaker.On(`VerifyMarker`, mock.Anything, alloc).Return(nil) + var pentBlocksNum = int64(10) + var latestRm = &readmarker.ReadMarker{} + mockReadMaker.On(`PendNumBlocks`).Return(pentBlocksNum, nil) + mockReadMaker.On(`GetLatestRM`).Return(latestRm, nil) + + mockStorageHandler := &storageHandlerI{} + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). + Return(alloc, nil) + mockStorageHandler.On(`readPreRedeem`, mock.Anything, alloc, 5, pentBlocksNum, alloc.OwnerID).Return( + nil) + + mockFileStore := &mocks.FileStore{} + mockFileStore.On(`GetFileBlock`, req.Allocation, mock.Anything, req.BlockNum, req.NumBlocks).Return( + []byte{}, nil) + + mockReferencePackage := &mocks.PackageHandler{} + pathHash := req.Allocation + `:` + req.Path + mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). + Return(pathHash) + + objectRef := &reference.Ref{ + Name: "test", + ID: 123, + ContentHash: `hash`, + MerkleRoot: `root`, + Size: 1, + Type: reference.FILE, + } + + mockReferencePackage.On(`GetReferenceFromLookupHash`, mock.Anything, alloc.ID, pathHash). + Return(objectRef, nil) + mockReferencePackage.On(`IsACollaborator`, mock.Anything, objectRef.ID, alloc.OwnerID). + Return(true) + mockReferencePackage.On(`GetLatestReadMarkerEntity`, mock.Anything, alloc.OwnerID). + Return(mockReadMaker, nil) + mockReferencePackage.On(`GetFileStore`). + Return(mockFileStore) + mockReferencePackage.On(`SaveLatestReadMarker`, mock.Anything, mock.Anything, false). + Return(nil) + mockReferencePackage.On(`FileBlockDownloaded`, mock.Anything, objectRef.ID). + Return() + mockReferencePackage.On(`GetNewReadMaker`, mock.Anything).Return(mockReadMaker) + + resOk := &blobbergrpc.DownloadFileResponse{ + Success: false, + LatestRm: convert.ReadMarkerToReadMarkerGRPC(latestRm), + } + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + gotResponse, err := svc.DownloadFile(ctx, req) + if err != nil { + t.Fatal("unexpected error - " + err.Error()) + } + + assert.Equal(t, gotResponse, resOk) +} + +func TestBlobberGRPCService_DownloadFile_InvalidAllocation(t *testing.T) { + req := &blobbergrpc.DownloadFileRequest{ + Allocation: `invalid_allocation`, + } + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "client_key", + common.ClientSignatureHeader: "clientSignature", + })) + + mockStorageHandler := &storageHandlerI{} + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). + Return(nil, errors.New("some error")) + + mockReferencePackage := &mocks.PackageHandler{} + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + _, err := svc.DownloadFile(ctx, req) + if err == nil { + t.Fatal("expected error") + } + if err.Error() != "invalid_parameters: Invalid allocation id passed.some error" { + t.Fatal(`unexpected error - `, err) + } +} diff --git a/code/go/0chain.net/blobbercore/mocks/FileStore.go b/code/go/0chain.net/blobbercore/mocks/FileStore.go new file mode 100644 index 000000000..49207775b --- /dev/null +++ b/code/go/0chain.net/blobbercore/mocks/FileStore.go @@ -0,0 +1,275 @@ +// Code generated by mockery 2.7.5. DO NOT EDIT. + +package mocks + +import ( + json "encoding/json" + + filestore "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + + mock "github.com/stretchr/testify/mock" + + multipart "mime/multipart" + + util "github.com/0chain/blobber/code/go/0chain.net/core/util" +) + +// FileStore is an autogenerated mock type for the FileStore type +type FileStore struct { + mock.Mock +} + +// CommitWrite provides a mock function with given fields: allocationID, fileData, connectionID +func (_m *FileStore) CommitWrite(allocationID string, fileData *filestore.FileInputData, connectionID string) (bool, error) { + ret := _m.Called(allocationID, fileData, connectionID) + + var r0 bool + if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, string) bool); ok { + r0 = rf(allocationID, fileData, connectionID) + } else { + r0 = ret.Get(0).(bool) + } + + var r1 error + if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, string) error); ok { + r1 = rf(allocationID, fileData, connectionID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// DeleteFile provides a mock function with given fields: allocationID, contentHash +func (_m *FileStore) DeleteFile(allocationID string, contentHash string) error { + ret := _m.Called(allocationID, contentHash) + + var r0 error + if rf, ok := ret.Get(0).(func(string, string) error); ok { + r0 = rf(allocationID, contentHash) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// DeleteTempFile provides a mock function with given fields: allocationID, fileData, connectionID +func (_m *FileStore) DeleteTempFile(allocationID string, fileData *filestore.FileInputData, connectionID string) error { + ret := _m.Called(allocationID, fileData, connectionID) + + var r0 error + if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, string) error); ok { + r0 = rf(allocationID, fileData, connectionID) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// DownloadFromCloud provides a mock function with given fields: fileHash, filePath +func (_m *FileStore) DownloadFromCloud(fileHash string, filePath string) error { + ret := _m.Called(fileHash, filePath) + + var r0 error + if rf, ok := ret.Get(0).(func(string, string) error); ok { + r0 = rf(fileHash, filePath) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// GetFileBlock provides a mock function with given fields: allocationID, fileData, blockNum, numBlocks +func (_m *FileStore) GetFileBlock(allocationID string, fileData *filestore.FileInputData, blockNum int64, numBlocks int64) ([]byte, error) { + ret := _m.Called(allocationID, fileData, blockNum, numBlocks) + + var r0 []byte + if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, int64, int64) []byte); ok { + r0 = rf(allocationID, fileData, blockNum, numBlocks) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]byte) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, int64, int64) error); ok { + r1 = rf(allocationID, fileData, blockNum, numBlocks) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetFileBlockForChallenge provides a mock function with given fields: allocationID, fileData, blockoffset +func (_m *FileStore) GetFileBlockForChallenge(allocationID string, fileData *filestore.FileInputData, blockoffset int) (json.RawMessage, util.MerkleTreeI, error) { + ret := _m.Called(allocationID, fileData, blockoffset) + + var r0 json.RawMessage + if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, int) json.RawMessage); ok { + r0 = rf(allocationID, fileData, blockoffset) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(json.RawMessage) + } + } + + var r1 util.MerkleTreeI + if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, int) util.MerkleTreeI); ok { + r1 = rf(allocationID, fileData, blockoffset) + } else { + if ret.Get(1) != nil { + r1 = ret.Get(1).(util.MerkleTreeI) + } + } + + var r2 error + if rf, ok := ret.Get(2).(func(string, *filestore.FileInputData, int) error); ok { + r2 = rf(allocationID, fileData, blockoffset) + } else { + r2 = ret.Error(2) + } + + return r0, r1, r2 +} + +// GetTempPathSize provides a mock function with given fields: allocationID +func (_m *FileStore) GetTempPathSize(allocationID string) (int64, error) { + ret := _m.Called(allocationID) + + var r0 int64 + if rf, ok := ret.Get(0).(func(string) int64); ok { + r0 = rf(allocationID) + } else { + r0 = ret.Get(0).(int64) + } + + var r1 error + if rf, ok := ret.Get(1).(func(string) error); ok { + r1 = rf(allocationID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetTotalDiskSizeUsed provides a mock function with given fields: +func (_m *FileStore) GetTotalDiskSizeUsed() (int64, error) { + ret := _m.Called() + + var r0 int64 + if rf, ok := ret.Get(0).(func() int64); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(int64) + } + + var r1 error + if rf, ok := ret.Get(1).(func() error); ok { + r1 = rf() + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetlDiskSizeUsed provides a mock function with given fields: allocationID +func (_m *FileStore) GetlDiskSizeUsed(allocationID string) (int64, error) { + ret := _m.Called(allocationID) + + var r0 int64 + if rf, ok := ret.Get(0).(func(string) int64); ok { + r0 = rf(allocationID) + } else { + r0 = ret.Get(0).(int64) + } + + var r1 error + if rf, ok := ret.Get(1).(func(string) error); ok { + r1 = rf(allocationID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// IterateObjects provides a mock function with given fields: allocationID, handler +func (_m *FileStore) IterateObjects(allocationID string, handler filestore.FileObjectHandler) error { + ret := _m.Called(allocationID, handler) + + var r0 error + if rf, ok := ret.Get(0).(func(string, filestore.FileObjectHandler) error); ok { + r0 = rf(allocationID, handler) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// SetupAllocation provides a mock function with given fields: allocationID, skipCreate +func (_m *FileStore) SetupAllocation(allocationID string, skipCreate bool) (*filestore.StoreAllocation, error) { + ret := _m.Called(allocationID, skipCreate) + + var r0 *filestore.StoreAllocation + if rf, ok := ret.Get(0).(func(string, bool) *filestore.StoreAllocation); ok { + r0 = rf(allocationID, skipCreate) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*filestore.StoreAllocation) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(string, bool) error); ok { + r1 = rf(allocationID, skipCreate) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// UploadToCloud provides a mock function with given fields: fileHash, filePath +func (_m *FileStore) UploadToCloud(fileHash string, filePath string) error { + ret := _m.Called(fileHash, filePath) + + var r0 error + if rf, ok := ret.Get(0).(func(string, string) error); ok { + r0 = rf(fileHash, filePath) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// WriteFile provides a mock function with given fields: allocationID, fileData, infile, connectionID +func (_m *FileStore) WriteFile(allocationID string, fileData *filestore.FileInputData, infile multipart.File, connectionID string) (*filestore.FileOutputData, error) { + ret := _m.Called(allocationID, fileData, infile, connectionID) + + var r0 *filestore.FileOutputData + if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, multipart.File, string) *filestore.FileOutputData); ok { + r0 = rf(allocationID, fileData, infile, connectionID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*filestore.FileOutputData) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, multipart.File, string) error); ok { + r1 = rf(allocationID, fileData, infile, connectionID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 73c3dd36f..9644d5125 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -1,12 +1,16 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. +// Code generated by mockery 2.7.5. DO NOT EDIT. package mocks import ( context "context" + filestore "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + mock "github.com/stretchr/testify/mock" + readmarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" stats "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" @@ -19,6 +23,11 @@ type PackageHandler struct { mock.Mock } +// FileBlockDownloaded provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) FileBlockDownloaded(ctx context.Context, refID int64) { + _m.Called(ctx, refID) +} + // GetCollaborators provides a mock function with given fields: ctx, refID func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { ret := _m.Called(ctx, refID) @@ -88,6 +97,61 @@ func (_m *PackageHandler) GetFileStats(ctx context.Context, refID int64) (*stats return r0, r1 } +// GetFileStore provides a mock function with given fields: +func (_m *PackageHandler) GetFileStore() filestore.FileStore { + ret := _m.Called() + + var r0 filestore.FileStore + if rf, ok := ret.Get(0).(func() filestore.FileStore); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(filestore.FileStore) + } + } + + return r0 +} + +// GetLatestReadMarkerEntity provides a mock function with given fields: ctx, clientID +func (_m *PackageHandler) GetLatestReadMarkerEntity(ctx context.Context, clientID string) (readmarker.ReadMakerI, error) { + ret := _m.Called(ctx, clientID) + + var r0 readmarker.ReadMakerI + if rf, ok := ret.Get(0).(func(context.Context, string) readmarker.ReadMakerI); ok { + r0 = rf(ctx, clientID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(readmarker.ReadMakerI) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string) error); ok { + r1 = rf(ctx, clientID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetNewReadMaker provides a mock function with given fields: rm +func (_m *PackageHandler) GetNewReadMaker(rm *readmarker.ReadMarker) readmarker.ReadMakerI { + ret := _m.Called(rm) + + var r0 readmarker.ReadMakerI + if rf, ok := ret.Get(0).(func(*readmarker.ReadMarker) readmarker.ReadMakerI); ok { + r0 = rf(rm) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(readmarker.ReadMakerI) + } + } + + return r0 +} + // GetObjectPath provides a mock function with given fields: ctx, allocationID, blockNum func (_m *PackageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { ret := _m.Called(ctx, allocationID, blockNum) @@ -180,6 +244,20 @@ func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, alloca return r0, r1 } +// GetReferenceLookup provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { + ret := _m.Called(ctx, allocationID, path) + + var r0 string + if rf, ok := ret.Get(0).(func(context.Context, string, string) string); ok { + r0 = rf(ctx, allocationID, path) + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + // GetReferencePathFromPaths provides a mock function with given fields: ctx, allocationID, paths func (_m *PackageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { ret := _m.Called(ctx, allocationID, paths) @@ -239,3 +317,17 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } + +// SaveLatestReadMarker provides a mock function with given fields: ctx, rm, isCreate +func (_m *PackageHandler) SaveLatestReadMarker(ctx context.Context, rm *readmarker.ReadMarker, isCreate bool) error { + ret := _m.Called(ctx, rm, isCreate) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *readmarker.ReadMarker, bool) error); ok { + r0 = rf(ctx, rm, isCreate) + } else { + r0 = ret.Error(0) + } + + return r0 +} diff --git a/code/go/0chain.net/blobbercore/mocks/ReadMakerI.go b/code/go/0chain.net/blobbercore/mocks/ReadMakerI.go new file mode 100644 index 000000000..cccb06a89 --- /dev/null +++ b/code/go/0chain.net/blobbercore/mocks/ReadMakerI.go @@ -0,0 +1,69 @@ +// Code generated by mockery 2.7.5. DO NOT EDIT. + +package mocks + +import ( + context "context" + + allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + + mock "github.com/stretchr/testify/mock" + + readmarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" +) + +// ReadMakerI is an autogenerated mock type for the ReadMakerI type +type ReadMakerI struct { + mock.Mock +} + +// GetLatestRM provides a mock function with given fields: +func (_m *ReadMakerI) GetLatestRM() *readmarker.ReadMarker { + ret := _m.Called() + + var r0 *readmarker.ReadMarker + if rf, ok := ret.Get(0).(func() *readmarker.ReadMarker); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*readmarker.ReadMarker) + } + } + + return r0 +} + +// PendNumBlocks provides a mock function with given fields: +func (_m *ReadMakerI) PendNumBlocks() (int64, error) { + ret := _m.Called() + + var r0 int64 + if rf, ok := ret.Get(0).(func() int64); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(int64) + } + + var r1 error + if rf, ok := ret.Get(1).(func() error); ok { + r1 = rf() + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// VerifyMarker provides a mock function with given fields: ctx, sa +func (_m *ReadMakerI) VerifyMarker(ctx context.Context, sa *allocation.Allocation) error { + ret := _m.Called(ctx, sa) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *allocation.Allocation) error); ok { + r0 = rf(ctx, sa) + } else { + r0 = ret.Error(0) + } + + return r0 +} From cd7af0f2559bedfe7c4e61743307416a3ed06a20 Mon Sep 17 00:00:00 2001 From: Vivek V Date: Thu, 27 May 2021 17:03:37 +0530 Subject: [PATCH 054/183] refs #165, added .proto config for CalculateHashHandler --- .../blobbercore/blobbergrpc/blobber.pb.go | 1226 ++++++++++------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 115 ++ .../blobbergrpc/blobber_grpc.pb.go | 36 + .../blobbergrpc/proto/blobber.proto | 18 + .../blobbercore/openapi/blobber.swagger.json | 69 +- 5 files changed, 930 insertions(+), 534 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 2d21e6a7b..fe7db6557 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.6.1 +// protoc v3.17.1 // source: blobber.proto package blobbergrpc @@ -10,6 +10,7 @@ import ( _ "google.golang.org/genproto/googleapis/api/annotations" protoreflect "google.golang.org/protobuf/reflect/protoreflect" protoimpl "google.golang.org/protobuf/runtime/protoimpl" + anypb "google.golang.org/protobuf/types/known/anypb" reflect "reflect" sync "sync" ) @@ -21,6 +22,116 @@ const ( _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) +type CalculateHashRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,3,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` +} + +func (x *CalculateHashRequest) Reset() { + *x = CalculateHashRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CalculateHashRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CalculateHashRequest) ProtoMessage() {} + +func (x *CalculateHashRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_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 CalculateHashRequest.ProtoReflect.Descriptor instead. +func (*CalculateHashRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{0} +} + +func (x *CalculateHashRequest) GetAllocation() string { + if x != nil { + return x.Allocation + } + return "" +} + +func (x *CalculateHashRequest) GetPath() string { + if x != nil { + return x.Path + } + return "" +} + +func (x *CalculateHashRequest) GetPathHash() string { + if x != nil { + return x.PathHash + } + return "" +} + +type CalculateHashResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Message *anypb.Any `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` +} + +func (x *CalculateHashResponse) Reset() { + *x = CalculateHashResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CalculateHashResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CalculateHashResponse) ProtoMessage() {} + +func (x *CalculateHashResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[1] + 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 CalculateHashResponse.ProtoReflect.Descriptor instead. +func (*CalculateHashResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{1} +} + +func (x *CalculateHashResponse) GetMessage() *anypb.Any { + if x != nil { + return x.Message + } + return nil +} + type GetObjectTreeRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -33,7 +144,7 @@ type GetObjectTreeRequest struct { func (x *GetObjectTreeRequest) Reset() { *x = GetObjectTreeRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[0] + mi := &file_blobber_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -46,7 +157,7 @@ func (x *GetObjectTreeRequest) String() string { func (*GetObjectTreeRequest) ProtoMessage() {} func (x *GetObjectTreeRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[0] + mi := &file_blobber_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -59,7 +170,7 @@ func (x *GetObjectTreeRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectTreeRequest.ProtoReflect.Descriptor instead. func (*GetObjectTreeRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{0} + return file_blobber_proto_rawDescGZIP(), []int{2} } func (x *GetObjectTreeRequest) GetPath() string { @@ -88,7 +199,7 @@ type GetObjectTreeResponse struct { func (x *GetObjectTreeResponse) Reset() { *x = GetObjectTreeResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[1] + mi := &file_blobber_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -101,7 +212,7 @@ func (x *GetObjectTreeResponse) String() string { func (*GetObjectTreeResponse) ProtoMessage() {} func (x *GetObjectTreeResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[1] + mi := &file_blobber_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -114,7 +225,7 @@ func (x *GetObjectTreeResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectTreeResponse.ProtoReflect.Descriptor instead. func (*GetObjectTreeResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{1} + return file_blobber_proto_rawDescGZIP(), []int{3} } func (x *GetObjectTreeResponse) GetReferencePath() *ReferencePath { @@ -144,7 +255,7 @@ type GetReferencePathRequest struct { func (x *GetReferencePathRequest) Reset() { *x = GetReferencePathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[2] + mi := &file_blobber_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -157,7 +268,7 @@ func (x *GetReferencePathRequest) String() string { func (*GetReferencePathRequest) ProtoMessage() {} func (x *GetReferencePathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[2] + mi := &file_blobber_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -170,7 +281,7 @@ func (x *GetReferencePathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReferencePathRequest.ProtoReflect.Descriptor instead. func (*GetReferencePathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{2} + return file_blobber_proto_rawDescGZIP(), []int{4} } func (x *GetReferencePathRequest) GetPaths() string { @@ -206,7 +317,7 @@ type GetReferencePathResponse struct { func (x *GetReferencePathResponse) Reset() { *x = GetReferencePathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[3] + mi := &file_blobber_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -219,7 +330,7 @@ func (x *GetReferencePathResponse) String() string { func (*GetReferencePathResponse) ProtoMessage() {} func (x *GetReferencePathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[3] + mi := &file_blobber_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -232,7 +343,7 @@ func (x *GetReferencePathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReferencePathResponse.ProtoReflect.Descriptor instead. func (*GetReferencePathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{3} + return file_blobber_proto_rawDescGZIP(), []int{5} } func (x *GetReferencePathResponse) GetReferencePath() *ReferencePath { @@ -261,7 +372,7 @@ type ReferencePath struct { func (x *ReferencePath) Reset() { *x = ReferencePath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -274,7 +385,7 @@ func (x *ReferencePath) String() string { func (*ReferencePath) ProtoMessage() {} func (x *ReferencePath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -287,7 +398,7 @@ func (x *ReferencePath) ProtoReflect() protoreflect.Message { // Deprecated: Use ReferencePath.ProtoReflect.Descriptor instead. func (*ReferencePath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{4} + return file_blobber_proto_rawDescGZIP(), []int{6} } func (x *ReferencePath) GetMetaData() *FileRef { @@ -317,7 +428,7 @@ type GetObjectPathRequest struct { func (x *GetObjectPathRequest) Reset() { *x = GetObjectPathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -330,7 +441,7 @@ func (x *GetObjectPathRequest) String() string { func (*GetObjectPathRequest) ProtoMessage() {} func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -343,7 +454,7 @@ func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathRequest.ProtoReflect.Descriptor instead. func (*GetObjectPathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{5} + return file_blobber_proto_rawDescGZIP(), []int{7} } func (x *GetObjectPathRequest) GetAllocation() string { @@ -379,7 +490,7 @@ type GetObjectPathResponse struct { func (x *GetObjectPathResponse) Reset() { *x = GetObjectPathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -392,7 +503,7 @@ func (x *GetObjectPathResponse) String() string { func (*GetObjectPathResponse) ProtoMessage() {} func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -405,7 +516,7 @@ func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathResponse.ProtoReflect.Descriptor instead. func (*GetObjectPathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{6} + return file_blobber_proto_rawDescGZIP(), []int{8} } func (x *GetObjectPathResponse) GetObjectPath() *ObjectPath { @@ -437,7 +548,7 @@ type ObjectPath struct { func (x *ObjectPath) Reset() { *x = ObjectPath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -450,7 +561,7 @@ func (x *ObjectPath) String() string { func (*ObjectPath) ProtoMessage() {} func (x *ObjectPath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -463,7 +574,7 @@ func (x *ObjectPath) ProtoReflect() protoreflect.Message { // Deprecated: Use ObjectPath.ProtoReflect.Descriptor instead. func (*ObjectPath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{7} + return file_blobber_proto_rawDescGZIP(), []int{9} } func (x *ObjectPath) GetRootHash() string { @@ -519,7 +630,7 @@ type WriteMarker struct { func (x *WriteMarker) Reset() { *x = WriteMarker{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -532,7 +643,7 @@ func (x *WriteMarker) String() string { func (*WriteMarker) ProtoMessage() {} func (x *WriteMarker) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -545,7 +656,7 @@ func (x *WriteMarker) ProtoReflect() protoreflect.Message { // Deprecated: Use WriteMarker.ProtoReflect.Descriptor instead. func (*WriteMarker) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{8} + return file_blobber_proto_rawDescGZIP(), []int{10} } func (x *WriteMarker) GetAllocationRoot() string { @@ -618,7 +729,7 @@ type ListEntitiesRequest struct { func (x *ListEntitiesRequest) Reset() { *x = ListEntitiesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -631,7 +742,7 @@ func (x *ListEntitiesRequest) String() string { func (*ListEntitiesRequest) ProtoMessage() {} func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -644,7 +755,7 @@ func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ListEntitiesRequest.ProtoReflect.Descriptor instead. func (*ListEntitiesRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{9} + return file_blobber_proto_rawDescGZIP(), []int{11} } func (x *ListEntitiesRequest) GetPath() string { @@ -688,7 +799,7 @@ type ListEntitiesResponse struct { func (x *ListEntitiesResponse) Reset() { *x = ListEntitiesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[10] + mi := &file_blobber_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -701,7 +812,7 @@ func (x *ListEntitiesResponse) String() string { func (*ListEntitiesResponse) ProtoMessage() {} func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[10] + mi := &file_blobber_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -714,7 +825,7 @@ func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ListEntitiesResponse.ProtoReflect.Descriptor instead. func (*ListEntitiesResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{10} + return file_blobber_proto_rawDescGZIP(), []int{12} } func (x *ListEntitiesResponse) GetAllocationRoot() string { @@ -751,7 +862,7 @@ type GetFileStatsRequest struct { func (x *GetFileStatsRequest) Reset() { *x = GetFileStatsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -764,7 +875,7 @@ func (x *GetFileStatsRequest) String() string { func (*GetFileStatsRequest) ProtoMessage() {} func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -777,7 +888,7 @@ func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileStatsRequest.ProtoReflect.Descriptor instead. func (*GetFileStatsRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{11} + return file_blobber_proto_rawDescGZIP(), []int{13} } func (x *GetFileStatsRequest) GetPath() string { @@ -813,7 +924,7 @@ type GetFileStatsResponse struct { func (x *GetFileStatsResponse) Reset() { *x = GetFileStatsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -826,7 +937,7 @@ func (x *GetFileStatsResponse) String() string { func (*GetFileStatsResponse) ProtoMessage() {} func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -839,7 +950,7 @@ func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileStatsResponse.ProtoReflect.Descriptor instead. func (*GetFileStatsResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{12} + return file_blobber_proto_rawDescGZIP(), []int{14} } func (x *GetFileStatsResponse) GetMetaData() *FileRef { @@ -876,7 +987,7 @@ type FileStats struct { func (x *FileStats) Reset() { *x = FileStats{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -889,7 +1000,7 @@ func (x *FileStats) String() string { func (*FileStats) ProtoMessage() {} func (x *FileStats) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -902,7 +1013,7 @@ func (x *FileStats) ProtoReflect() protoreflect.Message { // Deprecated: Use FileStats.ProtoReflect.Descriptor instead. func (*FileStats) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{13} + return file_blobber_proto_rawDescGZIP(), []int{15} } func (x *FileStats) GetID() int64 { @@ -989,7 +1100,7 @@ type GetFileMetaDataRequest struct { func (x *GetFileMetaDataRequest) Reset() { *x = GetFileMetaDataRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[14] + mi := &file_blobber_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1002,7 +1113,7 @@ func (x *GetFileMetaDataRequest) String() string { func (*GetFileMetaDataRequest) ProtoMessage() {} func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[14] + mi := &file_blobber_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1015,7 +1126,7 @@ func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileMetaDataRequest.ProtoReflect.Descriptor instead. func (*GetFileMetaDataRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{14} + return file_blobber_proto_rawDescGZIP(), []int{16} } func (x *GetFileMetaDataRequest) GetPath() string { @@ -1058,7 +1169,7 @@ type GetFileMetaDataResponse struct { func (x *GetFileMetaDataResponse) Reset() { *x = GetFileMetaDataResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[15] + mi := &file_blobber_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1071,7 +1182,7 @@ func (x *GetFileMetaDataResponse) String() string { func (*GetFileMetaDataResponse) ProtoMessage() {} func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[15] + mi := &file_blobber_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1084,7 +1195,7 @@ func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileMetaDataResponse.ProtoReflect.Descriptor instead. func (*GetFileMetaDataResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{15} + return file_blobber_proto_rawDescGZIP(), []int{17} } func (x *GetFileMetaDataResponse) GetMetaData() *FileRef { @@ -1114,7 +1225,7 @@ type CommitMetaTxn struct { func (x *CommitMetaTxn) Reset() { *x = CommitMetaTxn{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[16] + mi := &file_blobber_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1127,7 +1238,7 @@ func (x *CommitMetaTxn) String() string { func (*CommitMetaTxn) ProtoMessage() {} func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[16] + mi := &file_blobber_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1140,7 +1251,7 @@ func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { // Deprecated: Use CommitMetaTxn.ProtoReflect.Descriptor instead. func (*CommitMetaTxn) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{16} + return file_blobber_proto_rawDescGZIP(), []int{18} } func (x *CommitMetaTxn) GetRefId() int64 { @@ -1177,7 +1288,7 @@ type Collaborator struct { func (x *Collaborator) Reset() { *x = Collaborator{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[17] + mi := &file_blobber_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1190,7 +1301,7 @@ func (x *Collaborator) String() string { func (*Collaborator) ProtoMessage() {} func (x *Collaborator) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[17] + mi := &file_blobber_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1203,7 +1314,7 @@ func (x *Collaborator) ProtoReflect() protoreflect.Message { // Deprecated: Use Collaborator.ProtoReflect.Descriptor instead. func (*Collaborator) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{17} + return file_blobber_proto_rawDescGZIP(), []int{19} } func (x *Collaborator) GetRefId() int64 { @@ -1238,7 +1349,7 @@ type GetAllocationRequest struct { func (x *GetAllocationRequest) Reset() { *x = GetAllocationRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[18] + mi := &file_blobber_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1251,7 +1362,7 @@ func (x *GetAllocationRequest) String() string { func (*GetAllocationRequest) ProtoMessage() {} func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[18] + mi := &file_blobber_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1264,7 +1375,7 @@ func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationRequest.ProtoReflect.Descriptor instead. func (*GetAllocationRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{18} + return file_blobber_proto_rawDescGZIP(), []int{20} } func (x *GetAllocationRequest) GetId() string { @@ -1285,7 +1396,7 @@ type GetAllocationResponse struct { func (x *GetAllocationResponse) Reset() { *x = GetAllocationResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1298,7 +1409,7 @@ func (x *GetAllocationResponse) String() string { func (*GetAllocationResponse) ProtoMessage() {} func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1311,7 +1422,7 @@ func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationResponse.ProtoReflect.Descriptor instead. func (*GetAllocationResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{19} + return file_blobber_proto_rawDescGZIP(), []int{21} } func (x *GetAllocationResponse) GetAllocation() *Allocation { @@ -1348,7 +1459,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1361,7 +1472,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1374,7 +1485,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{22} } func (x *Allocation) GetID() string { @@ -1511,7 +1622,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1524,7 +1635,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1537,7 +1648,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{23} } func (x *Term) GetID() int64 { @@ -1588,7 +1699,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1601,7 +1712,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1614,7 +1725,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{24} } func (x *FileRef) GetType() string { @@ -1672,7 +1783,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1685,7 +1796,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1698,7 +1809,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{23} + return file_blobber_proto_rawDescGZIP(), []int{25} } func (x *FileMetaData) GetType() string { @@ -1889,7 +2000,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1902,7 +2013,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1915,7 +2026,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{24} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *DirMetaData) GetType() string { @@ -1995,382 +2106,405 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x22, 0x4a, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, - 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, - 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, - 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, - 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, - 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, - 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, - 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, - 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, + 0x6f, 0x1a, 0x19, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, + 0x75, 0x66, 0x2f, 0x61, 0x6e, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x67, 0x0a, 0x14, + 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, + 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, + 0x68, 0x48, 0x61, 0x73, 0x68, 0x22, 0x47, 0x0a, 0x15, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, + 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2e, + 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, + 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0x4a, + 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, + 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, + 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, + 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, + 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, + 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, + 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, + 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, + 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, + 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, + 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, - 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, - 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, - 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, + 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, + 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, + 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, + 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, + 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, + 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, - 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, - 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, - 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, - 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, - 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, - 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, - 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, - 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, - 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, - 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, - 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, - 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, - 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, - 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, - 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, - 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, - 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, - 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, - 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, - 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, - 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, - 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, + 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, + 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, + 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, - 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, - 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, - 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, - 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, - 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, - 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, - 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, - 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, - 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, - 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, - 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, - 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, - 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, - 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, - 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, - 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, - 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, - 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, - 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, - 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, + 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, + 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, + 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, + 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, + 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, + 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, + 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, + 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, + 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, + 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, + 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, + 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, + 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, + 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, + 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, + 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, + 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, + 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, + 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, + 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, - 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, - 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, - 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, - 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, - 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, - 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, - 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, - 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, - 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, - 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, - 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, - 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, - 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, - 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, - 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, - 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, - 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, - 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, - 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, - 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, - 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, - 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, - 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, + 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, + 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, + 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, + 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, + 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, + 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, + 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, + 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, + 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, + 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, + 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, + 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, + 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, + 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, + 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, + 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, + 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, + 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, + 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, + 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, + 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, + 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, + 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, + 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, + 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, + 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, + 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, + 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, + 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, + 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, + 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, + 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, + 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, + 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, + 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, + 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, + 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, + 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, + 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, + 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, + 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, + 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, + 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, + 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, + 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, + 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, + 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, + 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, + 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, + 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, + 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, + 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, + 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, + 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, + 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, + 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, + 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, - 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, - 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, - 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, + 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, + 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, + 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, + 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, + 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, + 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, + 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, + 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, + 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, + 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, + 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, + 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, + 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, + 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, + 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, + 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, + 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, + 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, + 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, + 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, + 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, + 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, + 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, + 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, + 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, + 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xff, 0x08, 0x0a, 0x07, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, + 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, + 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, + 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, - 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, + 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, + 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, + 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, + 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, + 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, + 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, + 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, } var ( @@ -2385,76 +2519,82 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 25) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 27) var file_blobber_proto_goTypes = []interface{}{ - (*GetObjectTreeRequest)(nil), // 0: blobber.service.v1.GetObjectTreeRequest - (*GetObjectTreeResponse)(nil), // 1: blobber.service.v1.GetObjectTreeResponse - (*GetReferencePathRequest)(nil), // 2: blobber.service.v1.GetReferencePathRequest - (*GetReferencePathResponse)(nil), // 3: blobber.service.v1.GetReferencePathResponse - (*ReferencePath)(nil), // 4: blobber.service.v1.ReferencePath - (*GetObjectPathRequest)(nil), // 5: blobber.service.v1.GetObjectPathRequest - (*GetObjectPathResponse)(nil), // 6: blobber.service.v1.GetObjectPathResponse - (*ObjectPath)(nil), // 7: blobber.service.v1.ObjectPath - (*WriteMarker)(nil), // 8: blobber.service.v1.WriteMarker - (*ListEntitiesRequest)(nil), // 9: blobber.service.v1.ListEntitiesRequest - (*ListEntitiesResponse)(nil), // 10: blobber.service.v1.ListEntitiesResponse - (*GetFileStatsRequest)(nil), // 11: blobber.service.v1.GetFileStatsRequest - (*GetFileStatsResponse)(nil), // 12: blobber.service.v1.GetFileStatsResponse - (*FileStats)(nil), // 13: blobber.service.v1.FileStats - (*GetFileMetaDataRequest)(nil), // 14: blobber.service.v1.GetFileMetaDataRequest - (*GetFileMetaDataResponse)(nil), // 15: blobber.service.v1.GetFileMetaDataResponse - (*CommitMetaTxn)(nil), // 16: blobber.service.v1.CommitMetaTxn - (*Collaborator)(nil), // 17: blobber.service.v1.Collaborator - (*GetAllocationRequest)(nil), // 18: blobber.service.v1.GetAllocationRequest - (*GetAllocationResponse)(nil), // 19: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 20: blobber.service.v1.Allocation - (*Term)(nil), // 21: blobber.service.v1.Term - (*FileRef)(nil), // 22: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 23: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 24: blobber.service.v1.DirMetaData + (*CalculateHashRequest)(nil), // 0: blobber.service.v1.CalculateHashRequest + (*CalculateHashResponse)(nil), // 1: blobber.service.v1.CalculateHashResponse + (*GetObjectTreeRequest)(nil), // 2: blobber.service.v1.GetObjectTreeRequest + (*GetObjectTreeResponse)(nil), // 3: blobber.service.v1.GetObjectTreeResponse + (*GetReferencePathRequest)(nil), // 4: blobber.service.v1.GetReferencePathRequest + (*GetReferencePathResponse)(nil), // 5: blobber.service.v1.GetReferencePathResponse + (*ReferencePath)(nil), // 6: blobber.service.v1.ReferencePath + (*GetObjectPathRequest)(nil), // 7: blobber.service.v1.GetObjectPathRequest + (*GetObjectPathResponse)(nil), // 8: blobber.service.v1.GetObjectPathResponse + (*ObjectPath)(nil), // 9: blobber.service.v1.ObjectPath + (*WriteMarker)(nil), // 10: blobber.service.v1.WriteMarker + (*ListEntitiesRequest)(nil), // 11: blobber.service.v1.ListEntitiesRequest + (*ListEntitiesResponse)(nil), // 12: blobber.service.v1.ListEntitiesResponse + (*GetFileStatsRequest)(nil), // 13: blobber.service.v1.GetFileStatsRequest + (*GetFileStatsResponse)(nil), // 14: blobber.service.v1.GetFileStatsResponse + (*FileStats)(nil), // 15: blobber.service.v1.FileStats + (*GetFileMetaDataRequest)(nil), // 16: blobber.service.v1.GetFileMetaDataRequest + (*GetFileMetaDataResponse)(nil), // 17: blobber.service.v1.GetFileMetaDataResponse + (*CommitMetaTxn)(nil), // 18: blobber.service.v1.CommitMetaTxn + (*Collaborator)(nil), // 19: blobber.service.v1.Collaborator + (*GetAllocationRequest)(nil), // 20: blobber.service.v1.GetAllocationRequest + (*GetAllocationResponse)(nil), // 21: blobber.service.v1.GetAllocationResponse + (*Allocation)(nil), // 22: blobber.service.v1.Allocation + (*Term)(nil), // 23: blobber.service.v1.Term + (*FileRef)(nil), // 24: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 25: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 26: blobber.service.v1.DirMetaData + (*anypb.Any)(nil), // 27: google.protobuf.Any } var file_blobber_proto_depIdxs = []int32{ - 4, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 8, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 4, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 8, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 22, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef - 4, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath - 7, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath - 8, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 22, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 22, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 22, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 22, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 22, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 22, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef - 13, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 22, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef - 17, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 20, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 21, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 23, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 24, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 16, // 21: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 18, // 22: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 14, // 23: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 11, // 24: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 9, // 25: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 5, // 26: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest - 2, // 27: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest - 0, // 28: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 19, // 29: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 15, // 30: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 12, // 31: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 10, // 32: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 6, // 33: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 3, // 34: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 1, // 35: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 29, // [29:36] is the sub-list for method output_type - 22, // [22:29] is the sub-list for method input_type - 22, // [22:22] is the sub-list for extension type_name - 22, // [22:22] is the sub-list for extension extendee - 0, // [0:22] is the sub-list for field type_name + 27, // 0: blobber.service.v1.CalculateHashResponse.message:type_name -> google.protobuf.Any + 6, // 1: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 10, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 6, // 3: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 10, // 4: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 24, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 6, // 6: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath + 9, // 7: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath + 10, // 8: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker + 24, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 24, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 24, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 24, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 24, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 15, // 15: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats + 24, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 19, // 17: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 22, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 23, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 25, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 26, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 18, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 20, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 16, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 13, // 25: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 11, // 26: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 7, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 4, // 28: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest + 2, // 29: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest + 0, // 30: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest + 21, // 31: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 17, // 32: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 14, // 33: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 12, // 34: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 8, // 35: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 5, // 36: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 3, // 37: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 1, // 38: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 31, // [31:39] is the sub-list for method output_type + 23, // [23:31] is the sub-list for method input_type + 23, // [23:23] is the sub-list for extension type_name + 23, // [23:23] is the sub-list for extension extendee + 0, // [0:23] is the sub-list for field type_name } func init() { file_blobber_proto_init() } @@ -2464,7 +2604,7 @@ func file_blobber_proto_init() { } if !protoimpl.UnsafeEnabled { file_blobber_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectTreeRequest); i { + switch v := v.(*CalculateHashRequest); i { case 0: return &v.state case 1: @@ -2476,7 +2616,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectTreeResponse); i { + switch v := v.(*CalculateHashResponse); i { case 0: return &v.state case 1: @@ -2488,7 +2628,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetReferencePathRequest); i { + switch v := v.(*GetObjectTreeRequest); i { case 0: return &v.state case 1: @@ -2500,7 +2640,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetReferencePathResponse); i { + switch v := v.(*GetObjectTreeResponse); i { case 0: return &v.state case 1: @@ -2512,7 +2652,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReferencePath); i { + switch v := v.(*GetReferencePathRequest); i { case 0: return &v.state case 1: @@ -2524,7 +2664,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathRequest); i { + switch v := v.(*GetReferencePathResponse); i { case 0: return &v.state case 1: @@ -2536,7 +2676,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathResponse); i { + switch v := v.(*ReferencePath); i { case 0: return &v.state case 1: @@ -2548,7 +2688,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ObjectPath); i { + switch v := v.(*GetObjectPathRequest); i { case 0: return &v.state case 1: @@ -2560,7 +2700,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*WriteMarker); i { + switch v := v.(*GetObjectPathResponse); i { case 0: return &v.state case 1: @@ -2572,7 +2712,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesRequest); i { + switch v := v.(*ObjectPath); i { case 0: return &v.state case 1: @@ -2584,7 +2724,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesResponse); i { + switch v := v.(*WriteMarker); i { case 0: return &v.state case 1: @@ -2596,7 +2736,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsRequest); i { + switch v := v.(*ListEntitiesRequest); i { case 0: return &v.state case 1: @@ -2608,7 +2748,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsResponse); i { + switch v := v.(*ListEntitiesResponse); i { case 0: return &v.state case 1: @@ -2620,7 +2760,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileStats); i { + switch v := v.(*GetFileStatsRequest); i { case 0: return &v.state case 1: @@ -2632,7 +2772,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataRequest); i { + switch v := v.(*GetFileStatsResponse); i { case 0: return &v.state case 1: @@ -2644,7 +2784,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataResponse); i { + switch v := v.(*FileStats); i { case 0: return &v.state case 1: @@ -2656,7 +2796,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CommitMetaTxn); i { + switch v := v.(*GetFileMetaDataRequest); i { case 0: return &v.state case 1: @@ -2668,7 +2808,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Collaborator); i { + switch v := v.(*GetFileMetaDataResponse); i { case 0: return &v.state case 1: @@ -2680,7 +2820,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationRequest); i { + switch v := v.(*CommitMetaTxn); i { case 0: return &v.state case 1: @@ -2692,7 +2832,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationResponse); i { + switch v := v.(*Collaborator); i { case 0: return &v.state case 1: @@ -2704,7 +2844,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*GetAllocationRequest); i { case 0: return &v.state case 1: @@ -2716,7 +2856,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*GetAllocationResponse); i { case 0: return &v.state case 1: @@ -2728,7 +2868,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -2740,7 +2880,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -2752,6 +2892,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -2770,7 +2934,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 25, + NumMessages: 27, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 50dc6d47f..716d36ce7 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -487,6 +487,74 @@ func local_request_Blobber_GetObjectTree_0(ctx context.Context, marshaler runtim } +func request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CalculateHashRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := client.CalculateHash(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CalculateHashRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := server.CalculateHash(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterBlobberHandlerServer registers the http handlers for service Blobber to "mux". // UnaryRPC :call BlobberServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -654,6 +722,29 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) + mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_CalculateHash_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -835,6 +926,26 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) + mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_CalculateHash_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -852,6 +963,8 @@ var ( pattern_Blobber_GetReferencePath_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "referencepath", "allocation"}, "")) pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) + + pattern_Blobber_CalculateHash_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v1", "file", "calculatehash", "allocation"}, "")) ) var ( @@ -868,4 +981,6 @@ var ( forward_Blobber_GetReferencePath_0 = runtime.ForwardResponseMessage forward_Blobber_GetObjectTree_0 = runtime.ForwardResponseMessage + + forward_Blobber_CalculateHash_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index e73fdcaf5..78899bbdc 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -24,6 +24,7 @@ type BlobberClient interface { GetObjectPath(ctx context.Context, in *GetObjectPathRequest, opts ...grpc.CallOption) (*GetObjectPathResponse, error) GetReferencePath(ctx context.Context, in *GetReferencePathRequest, opts ...grpc.CallOption) (*GetReferencePathResponse, error) GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) + CalculateHash(ctx context.Context, in *CalculateHashRequest, opts ...grpc.CallOption) (*CalculateHashResponse, error) } type blobberClient struct { @@ -97,6 +98,15 @@ func (c *blobberClient) GetObjectTree(ctx context.Context, in *GetObjectTreeRequ return out, nil } +func (c *blobberClient) CalculateHash(ctx context.Context, in *CalculateHashRequest, opts ...grpc.CallOption) (*CalculateHashResponse, error) { + out := new(CalculateHashResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/CalculateHash", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -108,6 +118,7 @@ type BlobberServer interface { GetObjectPath(context.Context, *GetObjectPathRequest) (*GetObjectPathResponse, error) GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) + CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -136,6 +147,9 @@ func (UnimplementedBlobberServer) GetReferencePath(context.Context, *GetReferenc func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetObjectTree not implemented") } +func (UnimplementedBlobberServer) CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CalculateHash not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -275,6 +289,24 @@ func _Blobber_GetObjectTree_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } +func _Blobber_CalculateHash_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CalculateHashRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).CalculateHash(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/CalculateHash", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).CalculateHash(ctx, req.(*CalculateHashRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Blobber_serviceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), @@ -307,6 +339,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "GetObjectTree", Handler: _Blobber_GetObjectTree_Handler, }, + { + MethodName: "CalculateHash", + Handler: _Blobber_CalculateHash_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index e02cfbd76..314191e39 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -4,6 +4,7 @@ package blobber.service.v1; option go_package = "code/go/0chain.net/blobbercore/blobbergrpc"; import "google/api/annotations.proto"; +import "google/protobuf/any.proto"; service Blobber { @@ -42,6 +43,23 @@ service Blobber { get: "/v2/file/objecttree/{allocation}" }; } + + rpc CalculateHash(CalculateHashRequest) returns (CalculateHashResponse) { + option (google.api.http) = { + post: "/v1/file/calculatehash/{allocation}" + body: "*" + }; + } +} + +message CalculateHashRequest { + string allocation = 1; + string path = 2; + string path_hash = 3; +} + +message CalculateHashResponse { + google.protobuf.Any message = 1; } message GetObjectTreeRequest { diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index bb3789a42..2118de8f3 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -16,6 +16,44 @@ "application/json" ], "paths": { + "/v1/file/calculatehash/{allocation}": { + "post": { + "operationId": "Blobber_CalculateHash", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1CalculateHashResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1CalculateHashRequest" + } + } + ], + "tags": [ + "Blobber" + ] + } + }, "/v2/allocation": { "get": { "operationId": "Blobber_GetAllocation", @@ -310,13 +348,16 @@ "type": "object", "properties": { "typeUrl": { - "type": "string" + "type": "string", + "description": "A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n URL, or have them precompiled into a binary to avoid any\n lookup. Therefore, binary compatibility needs to be preserved\n on changes to types. (Use versioned type names to manage\n breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics." }, "value": { "type": "string", - "format": "byte" + "format": "byte", + "description": "Must be a valid serialized protocol buffer of the above specified type." } - } + }, + "description": "`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n Foo foo = ...;\n Any any;\n any.PackFrom(foo);\n ...\n if (any.UnpackTo(\u0026foo)) {\n ...\n }\n\nExample 2: Pack and unpack a message in Java.\n\n Foo foo = ...;\n Any any = Any.pack(foo);\n ...\n if (any.is(Foo.class)) {\n foo = any.unpack(Foo.class);\n }\n\n Example 3: Pack and unpack a message in Python.\n\n foo = Foo(...)\n any = Any()\n any.Pack(foo)\n ...\n if any.Is(Foo.DESCRIPTOR):\n any.Unpack(foo)\n ...\n\n Example 4: Pack and unpack a message in Go\n\n foo := \u0026pb.Foo{...}\n any, err := anypb.New(foo)\n if err != nil {\n ...\n }\n ...\n foo := \u0026pb.Foo{}\n if err := any.UnmarshalTo(foo); err != nil {\n ...\n }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\n\nJSON\n====\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n package google.profile;\n message Person {\n string first_name = 1;\n string last_name = 2;\n }\n\n {\n \"@type\": \"type.googleapis.com/google.profile.Person\",\n \"firstName\": \u003cstring\u003e,\n \"lastName\": \u003cstring\u003e\n }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n {\n \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n \"value\": \"1.212s\"\n }" }, "rpcStatus": { "type": "object", @@ -401,6 +442,28 @@ } } }, + "v1CalculateHashRequest": { + "type": "object", + "properties": { + "allocation": { + "type": "string" + }, + "path": { + "type": "string" + }, + "pathHash": { + "type": "string" + } + } + }, + "v1CalculateHashResponse": { + "type": "object", + "properties": { + "message": { + "$ref": "#/definitions/protobufAny" + } + } + }, "v1Collaborator": { "type": "object", "properties": { From 10c15ed68e59e354f20a74ed0ca7e69a9c31aa30 Mon Sep 17 00:00:00 2001 From: Vivek V Date: Thu, 27 May 2021 17:59:24 +0530 Subject: [PATCH 055/183] refs #165, updated .proto config, added CalculateHashHandler skeleton --- .../blobbercore/blobbergrpc/blobber.pb.go | 851 +++++++++--------- .../blobbergrpc/proto/blobber.proto | 3 +- .../0chain.net/blobbercore/handler/handler.go | 22 +- .../blobbercore/openapi/blobber.swagger.json | 11 +- 4 files changed, 441 insertions(+), 446 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index fe7db6557..8db971375 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -10,7 +10,6 @@ import ( _ "google.golang.org/genproto/googleapis/api/annotations" protoreflect "google.golang.org/protobuf/reflect/protoreflect" protoimpl "google.golang.org/protobuf/runtime/protoimpl" - anypb "google.golang.org/protobuf/types/known/anypb" reflect "reflect" sync "sync" ) @@ -90,7 +89,7 @@ type CalculateHashResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Message *anypb.Any `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` + Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` } func (x *CalculateHashResponse) Reset() { @@ -125,11 +124,11 @@ func (*CalculateHashResponse) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{1} } -func (x *CalculateHashResponse) GetMessage() *anypb.Any { +func (x *CalculateHashResponse) GetMessage() string { if x != nil { return x.Message } - return nil + return "" } type GetObjectTreeRequest struct { @@ -2106,262 +2105,310 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x1a, 0x19, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2f, 0x61, 0x6e, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x67, 0x0a, 0x14, - 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, - 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, - 0x68, 0x48, 0x61, 0x73, 0x68, 0x22, 0x47, 0x0a, 0x15, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2e, - 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0x4a, - 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, - 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, - 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, - 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, - 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x6f, 0x22, 0x67, 0x0a, 0x14, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, + 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, + 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, + 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x22, 0x31, 0x0a, 0x15, 0x43, 0x61, + 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0x4a, 0x0a, + 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, 0x65, + 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, + 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, + 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, + 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, 0x74, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, + 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e, + 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa0, + 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, + 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, + 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, + 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, + 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, + 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, + 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, + 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, + 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, + 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, + 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, - 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, - 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, - 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, - 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, - 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, - 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, - 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, - 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, - 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, - 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, - 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, - 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, - 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, - 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, - 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, - 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, - 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, - 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, + 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, + 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, + 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, + 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, - 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, - 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, - 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, - 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, - 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, - 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, - 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, - 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, - 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, - 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, - 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, - 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, - 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, - 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, - 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, - 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, + 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, + 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, + 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, + 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, 0x02, + 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, - 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, - 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, - 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, - 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, - 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, - 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, - 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, - 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, - 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, - 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, - 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, - 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, - 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, - 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, - 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, - 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, - 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, - 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, - 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, - 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, - 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, - 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, - 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, - 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, - 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, - 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, - 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, - 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, - 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, - 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, - 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, - 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, - 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, - 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, - 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, - 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, - 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, - 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, - 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, - 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, - 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, - 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, - 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, - 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, - 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, - 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, - 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, - 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, - 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, - 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, - 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, - 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, - 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, - 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, - 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, - 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, - 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, - 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, - 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, - 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, - 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, - 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, - 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, - 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, - 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, + 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, + 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, + 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, + 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, + 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, + 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, 0x13, + 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, + 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, + 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, + 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, + 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, + 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, + 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, + 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, + 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, + 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, + 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, + 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, + 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, + 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, + 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, + 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, + 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, + 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, + 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, + 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, + 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, + 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, + 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, + 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, + 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, + 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, + 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, + 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, + 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, 0x01, + 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, + 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, + 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, + 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, + 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, + 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, + 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, + 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, + 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, + 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, + 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, + 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, + 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, + 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, + 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, + 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, + 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, + 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, + 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, + 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, + 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, + 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, + 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, + 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, + 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, + 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, + 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, + 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, + 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, + 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, + 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, + 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, + 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, + 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, + 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, + 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, + 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, + 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, + 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, + 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, + 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, + 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, + 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, + 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, + 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, + 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, + 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, + 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, + 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, + 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, + 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, + 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, + 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, + 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, + 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, + 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, + 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, + 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, + 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, + 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, + 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, + 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, + 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, + 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, + 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, + 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, + 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, + 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, + 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, + 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, + 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, + 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, + 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, + 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, + 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, + 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, + 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, @@ -2372,139 +2419,87 @@ var file_blobber_proto_rawDesc = []byte{ 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, - 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, - 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, - 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, - 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, - 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, - 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, - 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, - 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, - 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, - 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, - 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, - 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, - 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, - 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, - 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, - 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, - 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, - 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, - 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, - 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, - 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, - 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, - 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, - 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, - 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, - 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, - 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xff, 0x08, 0x0a, 0x07, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xff, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, + 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, + 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, + 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, + 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, + 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, + 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, + 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, + 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, - 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, - 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, - 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, - 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, - 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, + 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, - 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, - 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, + 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, + 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, + 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, - 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, - 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, - 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, - 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, - 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, - 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x33, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, + 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, + 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, + 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, + 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2548,53 +2543,51 @@ var file_blobber_proto_goTypes = []interface{}{ (*FileRef)(nil), // 24: blobber.service.v1.FileRef (*FileMetaData)(nil), // 25: blobber.service.v1.FileMetaData (*DirMetaData)(nil), // 26: blobber.service.v1.DirMetaData - (*anypb.Any)(nil), // 27: google.protobuf.Any } var file_blobber_proto_depIdxs = []int32{ - 27, // 0: blobber.service.v1.CalculateHashResponse.message:type_name -> google.protobuf.Any - 6, // 1: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 10, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 6, // 3: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 10, // 4: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 24, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef - 6, // 6: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath - 9, // 7: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath - 10, // 8: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 24, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 24, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 24, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 24, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 24, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 24, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef - 15, // 15: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 24, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef - 19, // 17: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 22, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 23, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 25, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 26, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 18, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 20, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 16, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 13, // 25: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 11, // 26: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 7, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest - 4, // 28: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest - 2, // 29: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 0, // 30: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest - 21, // 31: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 17, // 32: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 14, // 33: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 12, // 34: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 8, // 35: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 5, // 36: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 3, // 37: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 1, // 38: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 31, // [31:39] is the sub-list for method output_type - 23, // [23:31] is the sub-list for method input_type - 23, // [23:23] is the sub-list for extension type_name - 23, // [23:23] is the sub-list for extension extendee - 0, // [0:23] is the sub-list for field type_name + 6, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 10, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 6, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 10, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 24, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 6, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath + 9, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath + 10, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker + 24, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 24, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 24, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 24, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 24, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 15, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats + 24, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 19, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 22, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 23, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 25, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 26, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 18, // 21: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 20, // 22: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 16, // 23: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 13, // 24: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 11, // 25: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 7, // 26: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 4, // 27: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest + 2, // 28: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest + 0, // 29: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest + 21, // 30: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 17, // 31: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 14, // 32: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 12, // 33: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 8, // 34: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 5, // 35: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 3, // 36: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 1, // 37: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 30, // [30:38] is the sub-list for method output_type + 22, // [22:30] is the sub-list for method input_type + 22, // [22:22] is the sub-list for extension type_name + 22, // [22:22] is the sub-list for extension extendee + 0, // [0:22] is the sub-list for field type_name } func init() { file_blobber_proto_init() } diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 314191e39..2a5c26009 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -4,7 +4,6 @@ package blobber.service.v1; option go_package = "code/go/0chain.net/blobbercore/blobbergrpc"; import "google/api/annotations.proto"; -import "google/protobuf/any.proto"; service Blobber { @@ -59,7 +58,7 @@ message CalculateHashRequest { } message CalculateHashResponse { - google.protobuf.Any message = 1; + string message = 1; } message GetObjectTreeRequest { diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 5d001aafc..6ba20ac5a 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -46,7 +46,7 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler)))) r.HandleFunc("/v1/file/commitmetatxn/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitMetaTxnHandler)))) r.HandleFunc("/v1/file/collaborator/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CollaboratorHandler)))) - r.HandleFunc("/v1/file/calculatehash/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CalculateHashHandler)))) + r.HandleFunc("/v1/file/calculatehash/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CalculateHashHandler(svc))))).Methods(http.MethodPost) //object info related apis r.HandleFunc("/allocation", common.UserRateLimit(common.ToJSONResponse(WithConnection(AllocationHandler(svc))))).Methods("GET") @@ -330,15 +330,21 @@ func UpdateAttributesHandler(ctx context.Context, r *http.Request) (interface{}, return response, nil } -func CalculateHashHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) +func CalculateHashHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerGRPCContext(ctx, r) - response, err := storageHandler.CalculateHash(ctx, r) - if err != nil { - return nil, err - } + response, err := svc.CalculateHash(ctx, &blobbergrpc.CalculateHashRequest{ + Allocation: mux.Vars(r)["allocation"], + Path: r.FormValue("path"), + PathHash: r.FormValue("path_hash"), + }) + if err != nil { + return nil, err + } - return response, nil + return response, nil + } } //nolint:gosimple // need more time to verify diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 2118de8f3..e29703715 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -348,16 +348,13 @@ "type": "object", "properties": { "typeUrl": { - "type": "string", - "description": "A URL/resource name that uniquely identifies the type of the serialized\nprotocol buffer message. This string must contain at least\none \"/\" character. The last segment of the URL's path must represent\nthe fully qualified name of the type (as in\n`path/google.protobuf.Duration`). The name should be in a canonical form\n(e.g., leading \".\" is not accepted).\n\nIn practice, teams usually precompile into the binary all types that they\nexpect it to use in the context of Any. However, for URLs which use the\nscheme `http`, `https`, or no scheme, one can optionally set up a type\nserver that maps type URLs to message definitions as follows:\n\n* If no scheme is provided, `https` is assumed.\n* An HTTP GET on the URL must yield a [google.protobuf.Type][]\n value in binary format, or produce an error.\n* Applications are allowed to cache lookup results based on the\n URL, or have them precompiled into a binary to avoid any\n lookup. Therefore, binary compatibility needs to be preserved\n on changes to types. (Use versioned type names to manage\n breaking changes.)\n\nNote: this functionality is not currently available in the official\nprotobuf release, and it is not used for type URLs beginning with\ntype.googleapis.com.\n\nSchemes other than `http`, `https` (or the empty scheme) might be\nused with implementation specific semantics." + "type": "string" }, "value": { "type": "string", - "format": "byte", - "description": "Must be a valid serialized protocol buffer of the above specified type." + "format": "byte" } - }, - "description": "`Any` contains an arbitrary serialized protocol buffer message along with a\nURL that describes the type of the serialized message.\n\nProtobuf library provides support to pack/unpack Any values in the form\nof utility functions or additional generated methods of the Any type.\n\nExample 1: Pack and unpack a message in C++.\n\n Foo foo = ...;\n Any any;\n any.PackFrom(foo);\n ...\n if (any.UnpackTo(\u0026foo)) {\n ...\n }\n\nExample 2: Pack and unpack a message in Java.\n\n Foo foo = ...;\n Any any = Any.pack(foo);\n ...\n if (any.is(Foo.class)) {\n foo = any.unpack(Foo.class);\n }\n\n Example 3: Pack and unpack a message in Python.\n\n foo = Foo(...)\n any = Any()\n any.Pack(foo)\n ...\n if any.Is(Foo.DESCRIPTOR):\n any.Unpack(foo)\n ...\n\n Example 4: Pack and unpack a message in Go\n\n foo := \u0026pb.Foo{...}\n any, err := anypb.New(foo)\n if err != nil {\n ...\n }\n ...\n foo := \u0026pb.Foo{}\n if err := any.UnmarshalTo(foo); err != nil {\n ...\n }\n\nThe pack methods provided by protobuf library will by default use\n'type.googleapis.com/full.type.name' as the type URL and the unpack\nmethods only use the fully qualified type name after the last '/'\nin the type URL, for example \"foo.bar.com/x/y.z\" will yield type\nname \"y.z\".\n\n\nJSON\n====\nThe JSON representation of an `Any` value uses the regular\nrepresentation of the deserialized, embedded message, with an\nadditional field `@type` which contains the type URL. Example:\n\n package google.profile;\n message Person {\n string first_name = 1;\n string last_name = 2;\n }\n\n {\n \"@type\": \"type.googleapis.com/google.profile.Person\",\n \"firstName\": \u003cstring\u003e,\n \"lastName\": \u003cstring\u003e\n }\n\nIf the embedded message type is well-known and has a custom JSON\nrepresentation, that representation will be embedded adding a field\n`value` which holds the custom JSON in addition to the `@type`\nfield. Example (for message [google.protobuf.Duration][]):\n\n {\n \"@type\": \"type.googleapis.com/google.protobuf.Duration\",\n \"value\": \"1.212s\"\n }" + } }, "rpcStatus": { "type": "object", @@ -460,7 +457,7 @@ "type": "object", "properties": { "message": { - "$ref": "#/definitions/protobufAny" + "type": "string" } } }, From df20081062eb489afa995432d6ec26e7d13fff6b Mon Sep 17 00:00:00 2001 From: Vivek V Date: Thu, 27 May 2021 18:43:35 +0530 Subject: [PATCH 056/183] refs #165, migrated CalculateHashHandler to GRPC --- .../blobbercore/blobbergrpc/blobber.pb.go | 770 +++++++++--------- .../blobbergrpc/proto/blobber.proto | 3 +- .../blobbercore/handler/grpc_handler.go | 42 + .../0chain.net/blobbercore/handler/handler.go | 1 + .../blobbercore/handler/storage_handler.go | 2 +- .../blobbercore/openapi/blobber.swagger.json | 3 + 6 files changed, 439 insertions(+), 382 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 8db971375..0aa038f8d 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -28,7 +28,8 @@ type CalculateHashRequest struct { Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` - PathHash string `protobuf:"bytes,3,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + Paths string `protobuf:"bytes,3,opt,name=paths,proto3" json:"paths,omitempty"` + PathHash string `protobuf:"bytes,4,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` } func (x *CalculateHashRequest) Reset() { @@ -77,6 +78,13 @@ func (x *CalculateHashRequest) GetPath() string { return "" } +func (x *CalculateHashRequest) GetPaths() string { + if x != nil { + return x.Paths + } + return "" +} + func (x *CalculateHashRequest) GetPathHash() string { if x != nil { return x.PathHash @@ -2105,401 +2113,403 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x22, 0x67, 0x0a, 0x14, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, + 0x6f, 0x22, 0x7d, 0x0a, 0x14, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, - 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x22, 0x31, 0x0a, 0x15, 0x43, 0x61, - 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0x4a, 0x0a, - 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, + 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x14, 0x0a, + 0x05, 0x70, 0x61, 0x74, 0x68, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70, 0x61, + 0x74, 0x68, 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x22, 0x31, 0x0a, 0x15, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, + 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, + 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, + 0x61, 0x67, 0x65, 0x22, 0x4a, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, + 0x9d, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, + 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, + 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, + 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, + 0x63, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, + 0x74, 0x68, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, + 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, + 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, + 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, + 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, + 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, + 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, + 0x22, 0xa6, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, + 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, - 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, 0x74, - 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e, - 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa0, - 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, - 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, - 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, - 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, - 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, - 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, - 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, - 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, - 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, - 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, 0x47, - 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, - 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, - 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, - 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, - 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, - 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, - 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, + 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, + 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, + 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, - 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, - 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, 0x02, - 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, - 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, - 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, - 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, - 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, - 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, - 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, - 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, 0x13, - 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, + 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, + 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, + 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, + 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, + 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x4e, 0x75, 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, + 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, + 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, + 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, + 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, + 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, + 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, + 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, + 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, + 0x65, 0x22, 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, + 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, + 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, + 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, + 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, + 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, + 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, + 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, + 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, - 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, - 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, - 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, - 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, - 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, + 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, - 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, - 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, - 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, - 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, - 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, - 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, - 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, - 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, - 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, - 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, - 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, - 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, - 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, - 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, - 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, - 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, - 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, - 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, - 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, - 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, 0x01, - 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, - 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, - 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, - 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, - 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, - 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, - 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, - 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, - 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, - 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, - 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, - 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, - 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, - 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, - 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, - 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, - 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, - 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, - 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, - 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, - 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, - 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, - 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, - 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, - 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, - 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, - 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, - 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, - 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, - 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, - 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, - 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, - 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, - 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, - 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, - 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, - 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, - 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, - 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, - 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, - 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, - 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, - 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, - 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, - 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, - 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, - 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, - 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, - 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, - 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, - 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, - 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, - 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, - 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, - 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, - 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, - 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, - 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, - 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, - 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, - 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, - 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, - 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, - 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, - 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, - 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, - 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, - 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, - 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, - 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, - 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, - 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, - 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xff, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, + 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, + 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, + 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, + 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, + 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, + 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, + 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, + 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, + 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, + 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, + 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, + 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, + 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, + 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, + 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, + 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, + 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, + 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, + 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, + 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, + 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, + 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, + 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, + 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, + 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, + 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, + 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, + 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, + 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, + 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, + 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, + 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, + 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, + 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, + 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, + 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, + 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, + 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, + 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, + 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, + 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, + 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, + 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, + 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, + 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, + 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, + 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, + 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, + 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, + 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, + 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, + 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, + 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, + 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, + 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, + 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, + 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, + 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, + 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, + 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, + 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, + 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, + 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, + 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, + 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, + 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, + 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, + 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, + 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, + 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, + 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, + 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, + 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, + 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, + 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, + 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, + 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, + 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, + 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, + 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, + 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, + 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xff, + 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, + 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, - 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, - 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, - 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, - 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, - 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, - 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, - 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, - 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, - 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, + 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, + 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, + 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, + 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, - 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, - 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, - 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, - 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, + 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, - 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, - 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, - 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, - 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, - 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, + 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, + 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, + 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 2a5c26009..e8f0418d2 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -54,7 +54,8 @@ service Blobber { message CalculateHashRequest { string allocation = 1; string path = 2; - string path_hash = 3; + string paths = 3; + string path_hash = 4; } message CalculateHashResponse { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 9efb8ad08..9800ae8d8 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -446,3 +446,45 @@ func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc } return &refPathResult, nil } + +func (b *blobberGRPCService) CalculateHash(ctx context.Context, req *blobbergrpc.CalculateHashRequest) (*blobbergrpc.CalculateHashResponse, error) { + allocationTx := req.Allocation + allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) + } + + md := GetGRPCMetaDataFromCtx(ctx) + allocationID := allocationObj.ID + + clientID := md.Client + if len(clientID) == 0 || allocationObj.OwnerID != clientID { + return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + + var paths []string + pathsString := req.Paths + if len(pathsString) == 0 { + path := req.Path + if len(path) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid path") + } + paths = append(paths, path) + } else { + err = json.Unmarshal([]byte(pathsString), &paths) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid path array json") + } + } + + rootRef, err := b.packageHandler.GetReferencePathFromPaths(ctx, allocationID, paths) + if err != nil { + return nil, err + } + + if _, err := rootRef.CalculateHash(ctx, true); err != nil { + return nil, err + } + + return &blobbergrpc.CalculateHashResponse{Message: "Hash recalculated for the given paths"}, nil +} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 6ba20ac5a..6dc04e910 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -336,6 +336,7 @@ func CalculateHashHandler(svc *blobberGRPCService) func(ctx context.Context, r * response, err := svc.CalculateHash(ctx, &blobbergrpc.CalculateHashRequest{ Allocation: mux.Vars(r)["allocation"], + Paths: r.FormValue("paths"), Path: r.FormValue("path"), PathHash: r.FormValue("path_hash"), }) diff --git a/code/go/0chain.net/blobbercore/handler/storage_handler.go b/code/go/0chain.net/blobbercore/handler/storage_handler.go index 20c593ba0..c9a813d5d 100644 --- a/code/go/0chain.net/blobbercore/handler/storage_handler.go +++ b/code/go/0chain.net/blobbercore/handler/storage_handler.go @@ -704,7 +704,7 @@ func (fsh *StorageHandler) CalculateHash(ctx context.Context, r *http.Request) ( return result, nil } -// verifySignatureFromRequest verifyes signature passed as common.ClientSignatureHeader header. +// verifySignatureFromRequest verifies signature passed as common.ClientSignatureHeader header. func verifySignatureFromRequest(allocation, sign, pbK string) (bool, error) { if len(sign) < 64 { return false, nil diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index e29703715..b043a1b09 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -448,6 +448,9 @@ "path": { "type": "string" }, + "paths": { + "type": "string" + }, "pathHash": { "type": "string" } From 66a3af21cc2f9f0ec8379d2a0a4ff70f0e565fdd Mon Sep 17 00:00:00 2001 From: Vivek V Date: Thu, 27 May 2021 18:55:11 +0530 Subject: [PATCH 057/183] refs #165, updated .proto config --- .../blobbercore/blobbergrpc/blobber.pb.go | 772 +++++++++--------- .../blobbergrpc/proto/blobber.proto | 1 - .../0chain.net/blobbercore/handler/handler.go | 1 - .../blobbercore/openapi/blobber.swagger.json | 3 - 4 files changed, 381 insertions(+), 396 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 0aa038f8d..483f13460 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -29,7 +29,6 @@ type CalculateHashRequest struct { Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` Paths string `protobuf:"bytes,3,opt,name=paths,proto3" json:"paths,omitempty"` - PathHash string `protobuf:"bytes,4,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` } func (x *CalculateHashRequest) Reset() { @@ -85,13 +84,6 @@ func (x *CalculateHashRequest) GetPaths() string { return "" } -func (x *CalculateHashRequest) GetPathHash() string { - if x != nil { - return x.PathHash - } - return "" -} - type CalculateHashResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -2113,403 +2105,401 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x22, 0x7d, 0x0a, 0x14, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, + 0x6f, 0x22, 0x60, 0x0a, 0x14, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x61, 0x74, 0x68, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70, 0x61, - 0x74, 0x68, 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, - 0x22, 0x31, 0x0a, 0x15, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, - 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, - 0x61, 0x67, 0x65, 0x22, 0x4a, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, - 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, - 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0x9d, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, - 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, - 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, - 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, - 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, - 0x63, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, - 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, - 0x74, 0x68, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, - 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, - 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, - 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, - 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, - 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, - 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, - 0x22, 0xa6, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, - 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, - 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, - 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, - 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, + 0x74, 0x68, 0x73, 0x22, 0x31, 0x0a, 0x15, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, + 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, + 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, + 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0x4a, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, + 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, + 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, + 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, + 0x57, 0x4d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, + 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, + 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, + 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, + 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, + 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, + 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, + 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, + 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, + 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, + 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, + 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, + 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, + 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, + 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, + 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, + 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, + 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, + 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, + 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, + 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, + 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, + 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, + 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, + 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, + 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, + 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, + 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, + 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, + 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, + 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, + 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, + 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, + 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, + 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, + 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, + 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, + 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, - 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, - 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, - 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, - 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, - 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, - 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, - 0x4e, 0x75, 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, - 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, - 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, - 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, - 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, - 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, - 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, - 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, - 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x22, 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, - 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, - 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, - 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, - 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, - 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, - 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, - 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, - 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, - 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, + 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, + 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, + 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, + 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, + 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, + 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, + 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, + 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, + 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, + 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, + 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, + 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, + 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, + 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, + 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, + 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, + 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, + 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, - 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, - 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, - 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, - 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, - 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, - 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, - 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, - 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, - 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, - 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, - 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, - 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, - 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, - 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, - 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, - 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, - 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, - 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, - 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, - 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, - 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, - 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, - 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, - 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, - 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, - 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, - 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, - 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, - 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, - 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, - 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, - 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, - 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, - 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, - 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, - 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, - 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, - 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, - 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, - 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, - 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, - 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, - 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, - 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, - 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, - 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, - 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, - 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, - 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, - 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, - 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, - 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, - 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, - 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, - 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, - 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, - 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, - 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, - 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, - 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, - 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, - 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, - 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, - 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, - 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, - 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, - 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, - 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, - 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, - 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, - 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, - 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, - 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, - 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, - 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, - 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, - 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, - 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, - 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xff, - 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, - 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, - 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, + 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, + 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, + 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, + 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, + 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, + 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, + 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, + 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, + 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, + 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, + 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, + 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, + 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, + 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, + 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, + 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, + 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, + 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, + 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, + 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, + 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, + 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, + 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, + 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, + 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, + 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, + 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, + 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, + 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, + 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, + 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, + 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, + 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, + 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, + 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, + 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, + 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, + 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, + 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, + 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, + 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, + 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, + 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, + 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, + 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, + 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, + 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, + 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, + 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, + 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, + 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, + 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, + 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, + 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, + 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x32, 0xff, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, + 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, - 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, - 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, - 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, - 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, + 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, + 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, + 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, + 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, + 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, + 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, + 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, + 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, + 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, + 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, + 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, + 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, - 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, - 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, - 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, - 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, - 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, - 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, - 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, - 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, - 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x94, 0x01, 0x0a, + 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, + 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, + 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x31, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, + 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, + 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, + 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, + 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index e8f0418d2..65201c867 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -55,7 +55,6 @@ message CalculateHashRequest { string allocation = 1; string path = 2; string paths = 3; - string path_hash = 4; } message CalculateHashResponse { diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 6dc04e910..e41621130 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -338,7 +338,6 @@ func CalculateHashHandler(svc *blobberGRPCService) func(ctx context.Context, r * Allocation: mux.Vars(r)["allocation"], Paths: r.FormValue("paths"), Path: r.FormValue("path"), - PathHash: r.FormValue("path_hash"), }) if err != nil { return nil, err diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index b043a1b09..1d37eedb2 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -450,9 +450,6 @@ }, "paths": { "type": "string" - }, - "pathHash": { - "type": "string" } } }, From b46fba056c01d3907a8734e5854af442a0d58a35 Mon Sep 17 00:00:00 2001 From: Vivek V Date: Thu, 27 May 2021 19:36:22 +0530 Subject: [PATCH 058/183] :white_check_mark: refs #165, added tests --- .../handler/grpc_handler_unit_test.go | 63 +++++++++++++++++++ 1 file changed, 63 insertions(+) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index b5ba303c6..99f8d860e 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -529,5 +529,68 @@ func TestBlobberGRPCService_GetObjectTree_NotOwner(t *testing.T) { if err == nil { t.Fatal("expected error") } +} + +func TestBlobberGRPCService_CalculateHashSuccess(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + req := &blobbergrpc.CalculateHashRequest{ + Allocation: allocationTx, + Path: "some-path", + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "owner", + common.ClientSignatureHeader: clientSignature, + })) + + mockStorageHandler := new(storageHandlerI) + mockReferencePackage := new(mocks.PackageHandler) + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ + ID: "allocationId", + Tx: req.Allocation, + OwnerID: "owner", + OwnerPublicKey: pubKey, + }, nil) + mockReferencePackage.On("GetReferencePathFromPaths", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ + Name: "test", + Type: reference.DIRECTORY, + }, nil) + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + resp, err := svc.CalculateHash(ctx, req) + if err != nil { + t.Fatal("unexpected error: ", err) + } + + assert.Equal(t, resp.GetMessage(), "Hash recalculated for the given paths") +} + +func TestBlobberGRPCService_CalculateHashNotOwner(t *testing.T) { + req := &blobbergrpc.CalculateHashRequest{ + Allocation: "", + Path: "some-path", + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "hacker", + common.ClientSignatureHeader: "", + })) + + mockStorageHandler := new(storageHandlerI) + mockReferencePackage := new(mocks.PackageHandler) + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ + ID: "allocationId", + Tx: req.Allocation, + OwnerID: "owner", + }, nil) + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + _, err := svc.CalculateHash(ctx, req) + if err == nil { + t.Fatal("expected error: ", err) + } } From 3e17121da7f44cf8d7c20297fc51097fc1198857 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Fri, 28 May 2021 02:49:47 +0530 Subject: [PATCH 059/183] :memo: updated the grpc developer docs --- README.md | 6 +++- .../blobbercore/blobbergrpc/README.md | 31 ++++++++++++++++--- 2 files changed, 32 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 08f70ce00..5cc9ffcf3 100644 --- a/README.md +++ b/README.md @@ -323,4 +323,8 @@ delete_local_copy: true delete_cloud_copy: true -``` \ No newline at end of file +``` + +### Documentation + +GRPC related documentation can be found [here](./code/go/0chain.net/blobbercore/blobbergrpc/README.md). \ No newline at end of file diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/README.md b/code/go/0chain.net/blobbercore/blobbergrpc/README.md index b46217165..0e1ac4f0c 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/README.md +++ b/code/go/0chain.net/blobbercore/blobbergrpc/README.md @@ -1,4 +1,18 @@ -# GRPC Migration +# GRPC Endpoints + +## Installation + +``` +go install \ +github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-grpc-gateway \ +github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2 \ +google.golang.org/protobuf/cmd/protoc-gen-go \ +google.golang.org/grpc/cmd/protoc-gen-go-grpc +``` + +Run this command to install all the grpc related binaries required to generate files using grpc. + +## Development Modify the '.proto' file in `code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto` and run `scripts/generate-grpc.sh` to add new api's. @@ -6,14 +20,23 @@ Modify the '.proto' file in `code/go/0chain.net/blobbercore/blobbergrpc/proto/bl GRPC API is implemented in `code/go/0chain.net/blobbercore/handler/grpc_handler.go`. ## Plugins + * [grpc-gateway](https://github.com/grpc-ecosystem/grpc-gateway) plugin is being used to expose a REST api for grpc incompatible clients. -## Interacting with the api +## Testing + The current grpc implementation supports server reflection in development environment. You can interact with the api using https://github.com/gusaul/grpcox. Make sure the server is running on `--deployment_mode 0` to use server reflection. -## Dealing with paths -Refer to - https://developers.google.com/protocol-buffers/docs/reference/go-generated \ No newline at end of file +You can use https://github.com/vektra/mockery to generate mocks for tests. + +## Documentation + +Basic documentation can be found here - https://grpc.io/docs/languages/go/basics/ + +Advanced documentation can be found here - https://github.com/grpc/grpc-go/tree/master/Documentation + + From f0fed3cc6c82a3f84133ce99ec7d67208c7bcb73 Mon Sep 17 00:00:00 2001 From: Vivek V Date: Fri, 28 May 2021 17:19:53 +0530 Subject: [PATCH 060/183] :construction_worker: Updated the generated-files-integrity section of github actions workflow, to print the git diff in case of failure --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2e913f0ba..a9f22ed90 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -72,7 +72,7 @@ jobs: run: | ./scripts/generate-grpc.sh - name: Fail if any file has changed - run: if output=$(git status --porcelain) && [ -z "$output" ]; then exit 0; else git status; exit 1; fi; + run: if output=$(git status --porcelain) && [ -z "$output" ]; then exit 0; else git status; git diff; exit 1; fi; dockerize_blobber: runs-on: ubuntu-20.04 From 3c2c22bd1d6661d35a0ad463224e593796b12451 Mon Sep 17 00:00:00 2001 From: Vivek V Date: Fri, 28 May 2021 17:47:04 +0530 Subject: [PATCH 061/183] :green_heart: Fixed protoc version mismatch issue --- code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 483f13460..96219b6f2 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.17.1 +// protoc v3.6.1 // source: blobber.proto package blobbergrpc From 557240c11cb7b3eb6d0f4385aa640d1b5f2a034d Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sat, 29 May 2021 17:41:54 +0530 Subject: [PATCH 062/183] :white_check_mark: added unit tests --- .../handler/grpc_commit_handler.go | 54 ++-- .../handler/grpc_commit_handler_unit_test.go | 237 ++++++++++++++++++ .../handler/grpc_handler_helper_unit_test.go | 85 ++++++- .../handler/grpc_handler_integration_test.go | 105 ++++++++ .../0chain.net/blobbercore/handler/helper.go | 25 ++ .../blobbercore/mocks/PackageHandler.go | 90 +++++++ go.mod | 1 + 7 files changed, 571 insertions(+), 26 deletions(-) create mode 100644 code/go/0chain.net/blobbercore/handler/grpc_commit_handler_unit_test.go diff --git a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go index dbe4f1e06..e6046a88b 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go @@ -6,23 +6,23 @@ import ( "encoding/json" "strconv" + "gorm.io/gorm" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "github.com/0chain/blobber/code/go/0chain.net/core/lock" - "gorm.io/gorm" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" ) -// TODO parse request from gateway as form data instead of json func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.CommitRequest) (*blobbergrpc.CommitResponse, error) { md := GetGRPCMetaDataFromCtx(ctx) + ctx = setupGRPCHandlerContext(ctx, md, req.Allocation) allocationTx := req.Allocation clientID := md.Client @@ -45,7 +45,7 @@ func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.Commit mutex.Lock() defer mutex.Unlock() - connectionObj, err := allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) + connectionObj, err := b.packageHandler.GetAllocationChanges(ctx, connectionID, allocationID, clientID) if err != nil { return nil, common.NewErrorf("invalid_parameters", "Invalid connection id. Connection id was not found: %v", err) @@ -98,7 +98,7 @@ func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.Commit if len(allocationObj.AllocationRoot) == 0 { latestWM = nil } else { - latestWM, err = writemarker.GetWriteMarkerEntity(ctx, + latestWM, err = b.packageHandler.GetWriteMarkerEntity(ctx, allocationObj.AllocationRoot) if err != nil { return nil, common.NewErrorf("latest_write_marker_read_error", @@ -109,7 +109,7 @@ func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.Commit writemarkerObj := &writemarker.WriteMarkerEntity{} writemarkerObj.WM = writeMarker - err = writemarkerObj.VerifyMarker(ctx, allocationObj, connectionObj) + err = b.packageHandler.VerifyMarker(writemarkerObj, ctx, allocationObj, connectionObj) if err != nil { result.AllocationRoot = allocationObj.AllocationRoot result.ErrorMessage = "Verification of write marker failed: " + err.Error() @@ -129,11 +129,11 @@ func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.Commit return nil, err } - err = connectionObj.ApplyChanges(ctx, writeMarker.AllocationRoot) + err = b.packageHandler.ApplyChanges(connectionObj, ctx, writeMarker.AllocationRoot) if err != nil { return nil, err } - rootRef, err := reference.GetReference(ctx, allocationID, "/") + rootRef, err := b.packageHandler.GetReference(ctx, allocationID, "/") if err != nil { return nil, err } @@ -150,9 +150,24 @@ func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.Commit } writemarkerObj.ConnectionID = connectionObj.ConnectionID writemarkerObj.ClientPublicKey = clientKey - err = writemarkerObj.Save(ctx) + + err = b.packageHandler.UpdateAllocationAndCommitChanges(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) if err != nil { - return nil, common.NewError("write_marker_error", "Error persisting the write marker") + return nil, err + } + + result.AllocationRoot = allocationObj.AllocationRoot + result.WriteMarker = convert.WriteMarkerToWriteMarkerGRPC(&writeMarker) + result.Success = true + result.ErrorMessage = "" + + return &result, nil +} + +func UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { + err := writemarkerObj.Save(ctx) + if err != nil { + return common.NewError("write_marker_error", "Error persisting the write marker") } db := datastore.GetStore().GetTransaction(ctx) @@ -164,24 +179,15 @@ func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.Commit err = db.Model(allocationObj).Updates(allocationUpdates).Error if err != nil { - return nil, common.NewError("allocation_write_error", "Error persisting the allocation object") + return common.NewError("allocation_write_error", "Error persisting the allocation object") } err = connectionObj.CommitToFileStore(ctx) if err != nil { - return nil, common.NewError("file_store_error", "Error committing to file store. "+err.Error()) + return common.NewError("file_store_error", "Error committing to file store. "+err.Error()) } - // TODO maybe delete 'changes' field altogether, its not being used anywhere - its not even being sent as json back as response - //result.Changes = connectionObj.Changes - connectionObj.DeleteChanges(ctx) //nolint:errcheck // never returns an error anyway db.Model(connectionObj).Updates(allocation.AllocationChangeCollector{Status: allocation.CommittedConnection}) - - result.AllocationRoot = allocationObj.AllocationRoot - result.WriteMarker = convert.WriteMarkerToWriteMarkerGRPC(&writeMarker) - result.Success = true - result.ErrorMessage = "" - - return &result, nil + return nil } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler_unit_test.go new file mode 100644 index 000000000..9e9ce4ce0 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler_unit_test.go @@ -0,0 +1,237 @@ +package handler + +import ( + "context" + "encoding/hex" + "fmt" + "strconv" + "testing" + "time" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/magiconair/properties/assert" + "github.com/stretchr/testify/mock" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_Commit(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + pubKeyBytes, err := hex.DecodeString(pubKey) + if err != nil { + t.Fatal(err) + } + + timestamp := time.Now().UnixNano() + rootRefHash := "someHash" + clientId := encryption.Hash(pubKeyBytes) + connectionId := "connection_id" + allocationId := "allocationId" + req := &blobbergrpc.CommitRequest{ + Allocation: allocationTx, + ConnectionId: connectionId, + WriteMarker: `{"allocation_id":"` + allocationId + `","timestamp":` + fmt.Sprint(timestamp) + `,"allocation_root":"` + encryption.Hash(rootRefHash+":"+strconv.FormatInt(int64(timestamp), 10)) + `"}`, + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientKeyHeader: pubKey, + common.ClientSignatureHeader: clientSignature, + })) + + testcases := []struct { + description string + getAllocationChangesReturn func() (*allocation.AllocationChangeCollector, error) + verifyMarkerReturn func() error + applyChangesReturn func() error + getReferenceReturn func() (*reference.Ref, error) + verifyAllocationReturn func() (*allocation.Allocation, error) + getWriteMarkerEntityReturn func() (*writemarker.WriteMarkerEntity, error) + updateAllocationAndCommitChangesReturn func() error + expectedError bool + }{ + { + description: "success", + expectedError: false, + getAllocationChangesReturn: func() (*allocation.AllocationChangeCollector, error) { + return &allocation.AllocationChangeCollector{ + ConnectionID: connectionId, + AllocationID: allocationId, + ClientID: "", + Size: 0, + Changes: []*allocation.AllocationChange{&allocation.AllocationChange{ + ChangeID: 1, + Size: 0, + Operation: "insert", + ConnectionID: connectionId, + Input: "", + ModelWithTS: datastore.ModelWithTS{}, + }}, + AllocationChanges: nil, + Status: 0, + ModelWithTS: datastore.ModelWithTS{}, + }, nil + }, + verifyMarkerReturn: func() error { + return nil + }, + applyChangesReturn: func() error { + return nil + }, + getReferenceReturn: func() (*reference.Ref, error) { + return &reference.Ref{ + Hash: rootRefHash, + }, nil + }, + verifyAllocationReturn: func() (*allocation.Allocation, error) { + return &allocation.Allocation{ + ID: allocationId, + Tx: req.Allocation, + OwnerID: clientId, + OwnerPublicKey: pubKey, + }, nil + }, + getWriteMarkerEntityReturn: func() (*writemarker.WriteMarkerEntity, error) { + return nil, nil + }, + updateAllocationAndCommitChangesReturn: func() error { + return nil + }, + }, + { + description: "could not commit", + expectedError: true, + getAllocationChangesReturn: func() (*allocation.AllocationChangeCollector, error) { + return &allocation.AllocationChangeCollector{ + ConnectionID: connectionId, + AllocationID: allocationId, + ClientID: "", + Size: 0, + Changes: []*allocation.AllocationChange{&allocation.AllocationChange{ + ChangeID: 1, + Size: 0, + Operation: "insert", + ConnectionID: connectionId, + Input: "", + ModelWithTS: datastore.ModelWithTS{}, + }}, + AllocationChanges: nil, + Status: 0, + ModelWithTS: datastore.ModelWithTS{}, + }, nil + }, + verifyMarkerReturn: func() error { + return nil + }, + applyChangesReturn: func() error { + return nil + }, + getReferenceReturn: func() (*reference.Ref, error) { + return &reference.Ref{ + Hash: rootRefHash, + }, nil + }, + verifyAllocationReturn: func() (*allocation.Allocation, error) { + return &allocation.Allocation{ + ID: allocationId, + Tx: req.Allocation, + OwnerID: clientId, + OwnerPublicKey: pubKey, + }, nil + }, + getWriteMarkerEntityReturn: func() (*writemarker.WriteMarkerEntity, error) { + return nil, nil + }, + updateAllocationAndCommitChangesReturn: func() error { + return fmt.Errorf("some error") + }, + }, + { + description: "invalid marker", + expectedError: true, + getAllocationChangesReturn: func() (*allocation.AllocationChangeCollector, error) { + return &allocation.AllocationChangeCollector{ + ConnectionID: connectionId, + AllocationID: allocationId, + ClientID: "", + Size: 0, + Changes: []*allocation.AllocationChange{&allocation.AllocationChange{ + ChangeID: 1, + Size: 0, + Operation: "insert", + ConnectionID: connectionId, + Input: "", + ModelWithTS: datastore.ModelWithTS{}, + }}, + AllocationChanges: nil, + Status: 0, + ModelWithTS: datastore.ModelWithTS{}, + }, nil + }, + verifyMarkerReturn: func() error { + return fmt.Errorf("invalid marker") + }, + applyChangesReturn: func() error { + return nil + }, + getReferenceReturn: func() (*reference.Ref, error) { + return &reference.Ref{ + Hash: rootRefHash, + }, nil + }, + verifyAllocationReturn: func() (*allocation.Allocation, error) { + return &allocation.Allocation{ + ID: allocationId, + Tx: req.Allocation, + OwnerID: clientId, + OwnerPublicKey: pubKey, + }, nil + }, + getWriteMarkerEntityReturn: func() (*writemarker.WriteMarkerEntity, error) { + return nil, nil + }, + updateAllocationAndCommitChangesReturn: func() error { + return nil + }, + }, + } + + for _, tc := range testcases { + + mockStorageHandler := &storageHandlerI{} + mockPackageHandler := &mocks.PackageHandler{} + + mockPackageHandler.On("GetAllocationChanges", mock.Anything, connectionId, allocationId, mock.Anything).Return(tc.getAllocationChangesReturn()) + + mockPackageHandler.On("VerifyMarker", mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(tc.verifyMarkerReturn()) + mockPackageHandler.On("ApplyChanges", mock.Anything, mock.Anything, mock.Anything).Return(tc.applyChangesReturn()) + mockPackageHandler.On("GetReference", mock.Anything, mock.Anything, mock.Anything).Return(tc.getReferenceReturn()) + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(tc.verifyAllocationReturn()) + mockPackageHandler.On("GetWriteMarkerEntity", mock.Anything, mock.Anything).Return(tc.getWriteMarkerEntityReturn()) + mockPackageHandler.On("UpdateAllocationAndCommitChanges", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(tc.updateAllocationAndCommitChangesReturn()) + + svc := newGRPCBlobberService(mockStorageHandler, mockPackageHandler) + resp, err := svc.Commit(ctx, req) + if err != nil { + if tc.expectedError { + continue + } else { + t.Fatal("unexpected error - " + err.Error()) + } + } + + assert.Equal(t, resp.WriteMarker.AllocationID, allocationId) + } +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 0b286f5e1..88cf51744 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -9,6 +9,8 @@ import ( "strings" "time" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" "github.com/spf13/viper" @@ -125,6 +127,21 @@ func (c *TestDataController) ClearDatabase() error { return err } + _, err = tx.Exec("truncate allocation_changes cascade") + if err != nil { + return err + } + + _, err = tx.Exec("truncate allocation_connections cascade") + if err != nil { + return err + } + + _, err = tx.Exec("truncate write_markers cascade") + if err != nil { + return err + } + err = tx.Commit() if err != nil { return err @@ -485,8 +502,6 @@ func GeneratePubPrivateKey(t *testing.T) (string, string, zcncrypto.SignatureSch keyPair := wallet.Keys[0] _ = signScheme.SetPrivateKey(keyPair.PrivateKey) - _ = signScheme.SetPublicKey(keyPair.PublicKey) - return keyPair.PublicKey, keyPair.PrivateKey, signScheme } @@ -506,3 +521,69 @@ func setupIntegrationTestConfig(t *testing.T) { config.Configuration.DBUserName = viper.GetString("db.user") config.Configuration.DBPassword = viper.GetString("db.password") } + +func (c *TestDataController) AddCommitTestData(allocationTx, pubkey, clientId, wmSig string, now common.Timestamp) error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/root'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO allocation_connections (connection_id, allocation_id, client_id, size, status) +VALUES ('connection_id' ,'exampleId','` + clientId + `', 1337, 1); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO allocation_changes (id, connection_id, operation, size, input) +VALUES (1 ,'connection_id','rename', 1200, '{"new_name":"new_name"}'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO write_markers(prev_allocation_root, allocation_root, status, allocation_id, size, client_id, signature, blobber_id, timestamp, connection_id, client_key) +VALUES ('/root', '/root', 2,'exampleId', 1337, '` + clientId + `','` + wmSig + `','blobber_id', ` + fmt.Sprint(now) + `, 'connection_id', '` + pubkey + `'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index bde386249..efcfd0a71 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -2,12 +2,16 @@ package handler import ( "context" + "encoding/hex" + "encoding/json" "fmt" "log" "os" "testing" "time" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "google.golang.org/grpc/metadata" @@ -524,4 +528,105 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { }) + t.Run("TestCommit", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().UnixNano()) + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + wm := writemarker.WriteMarker{ + AllocationRoot: "/root", + PreviousAllocationRoot: "/root", + AllocationID: "exampleId", + Size: 1337, + BlobberID: encryption.Hash(blobberPubKeyBytes), + Timestamp: now, + ClientID: clientId, + } + + wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + if err != nil { + t.Fatal(err) + } + + wmRaw, err := json.Marshal(wm) + if err != nil { + t.Fatal(err) + } + + err = tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CommitRequest + expectedAllocation string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CommitRequest{ + Allocation: allocationTx, + ConnectionId: "connection_id", + WriteMarker: string(wmRaw), + }, + expectedAllocation: "exampleId", + expectingError: false, + }, + { + name: "invalid write_marker", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CommitRequest{ + Allocation: allocationTx, + ConnectionId: "invalid", + WriteMarker: "invalid", + }, + expectedAllocation: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getCommiteResp, err := blobberClient.Commit(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getCommiteResp.WriteMarker.AllocationID != tc.expectedAllocation { + t.Fatal("unexpected root name from GetObject") + } + } + }) + } diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index d129bc7bd..eea3de31f 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -40,10 +40,35 @@ type PackageHandler interface { GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) + GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) + VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx context.Context, sa *allocation.Allocation, co *allocation.AllocationChangeCollector) error + ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error + GetReference(ctx context.Context, allocationID string, path string) (*reference.Ref, error) + UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error } type packageHandler struct{} +func (r *packageHandler) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { + return UpdateAllocationAndCommitChanges(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) +} + +func (r *packageHandler) GetReference(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { + return reference.GetReference(ctx, allocationID, path) +} + +func (r *packageHandler) ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error { + return connectionObj.ApplyChanges(ctx, allocationRoot) +} + +func (r *packageHandler) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx context.Context, sa *allocation.Allocation, co *allocation.AllocationChangeCollector) error { + return wm.VerifyMarker(ctx, sa, co) +} + +func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { + return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) +} + func (r *packageHandler) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { return reference.GetObjectTree(ctx, allocationID, path) } diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 73c3dd36f..e7ad4bde3 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -5,6 +5,8 @@ package mocks import ( context "context" + allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + mock "github.com/stretchr/testify/mock" reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" @@ -19,6 +21,43 @@ type PackageHandler struct { mock.Mock } +// ApplyChanges provides a mock function with given fields: connectionObj, ctx, allocationRoot +func (_m *PackageHandler) ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error { + ret := _m.Called(connectionObj, ctx, allocationRoot) + + var r0 error + if rf, ok := ret.Get(0).(func(*allocation.AllocationChangeCollector, context.Context, string) error); ok { + r0 = rf(connectionObj, ctx, allocationRoot) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID +func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { + ret := _m.Called(ctx, connectionID, allocationID, clientID) + + var r0 *allocation.AllocationChangeCollector + if rf, ok := ret.Get(0).(func(context.Context, string, string, string) *allocation.AllocationChangeCollector); ok { + r0 = rf(ctx, connectionID, allocationID, clientID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*allocation.AllocationChangeCollector) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { + r1 = rf(ctx, connectionID, allocationID, clientID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // GetCollaborators provides a mock function with given fields: ctx, refID func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { ret := _m.Called(ctx, refID) @@ -157,6 +196,29 @@ func (_m *PackageHandler) GetRefWithChildren(ctx context.Context, allocationID s return r0, r1 } +// GetReference provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetReference(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, path) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, path) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, path) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // GetReferenceFromLookupHash provides a mock function with given fields: ctx, allocationID, path_hash func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { ret := _m.Called(ctx, allocationID, path_hash) @@ -239,3 +301,31 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } + +// UpdateAllocationAndCommitChanges provides a mock function with given fields: ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot +func (_m *PackageHandler) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { + ret := _m.Called(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *writemarker.WriteMarkerEntity, *allocation.AllocationChangeCollector, *allocation.Allocation, string) error); ok { + r0 = rf(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// VerifyMarker provides a mock function with given fields: wm, ctx, sa, co +func (_m *PackageHandler) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx context.Context, sa *allocation.Allocation, co *allocation.AllocationChangeCollector) error { + ret := _m.Called(wm, ctx, sa, co) + + var r0 error + if rf, ok := ret.Get(0).(func(*writemarker.WriteMarkerEntity, context.Context, *allocation.Allocation, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(wm, ctx, sa, co) + } else { + r0 = ret.Error(0) + } + + return r0 +} diff --git a/go.mod b/go.mod index 71485072d..4850314b4 100644 --- a/go.mod +++ b/go.mod @@ -11,6 +11,7 @@ require ( github.com/grpc-ecosystem/grpc-gateway/v2 v2.3.0 github.com/jackc/pgproto3/v2 v2.0.4 // indirect github.com/koding/cache v0.0.0-20161222233015-e8a81b0b3f20 + github.com/magiconair/properties v1.8.1 github.com/minio/minio-go v6.0.14+incompatible github.com/mitchellh/mapstructure v1.3.1 github.com/patrickmn/go-cache v2.1.0+incompatible // indirect From 09492764f523dea8acc528616b15b2b7a06d1072 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 15:21:29 +0530 Subject: [PATCH 063/183] upload file handler grpc added --- .../blobbercore/blobbergrpc/blobber.pb.go | 723 ++++++++++++------ .../blobbergrpc/blobber_grpc.pb.go | 46 +- .../blobbergrpc/proto/blobber.proto | 22 + .../blobbercore/convert/responseHandler.go | 11 + .../blobbercore/filestore/fs_store.go | 103 +++ .../0chain.net/blobbercore/filestore/store.go | 2 + .../0chain.net/blobbercore/handler/handler.go | 54 +- .../blobbercore/handler/handler_test.go | 2 +- .../0chain.net/blobbercore/handler/helper.go | 20 + .../handler/object_operation_grpc_handler.go | 220 ++++++ .../blobbercore/openapi/blobber.swagger.json | 28 + 11 files changed, 986 insertions(+), 245 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 2d21e6a7b..211a72a35 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.6.1 +// protoc v3.17.0 // source: blobber.proto package blobbergrpc @@ -1321,6 +1321,198 @@ func (x *GetAllocationResponse) GetAllocation() *Allocation { return nil } +type UploadFileRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` + ConnectionId string `protobuf:"bytes,3,opt,name=connection_id,json=connectionId,proto3" json:"connection_id,omitempty"` + Method string `protobuf:"bytes,4,opt,name=method,proto3" json:"method,omitempty"` + UploadMeta string `protobuf:"bytes,5,opt,name=upload_meta,json=uploadMeta,proto3" json:"upload_meta,omitempty"` + UpdateMeta string `protobuf:"bytes,6,opt,name=update_meta,json=updateMeta,proto3" json:"update_meta,omitempty"` + UploadFile []byte `protobuf:"bytes,7,opt,name=upload_file,json=uploadFile,proto3" json:"upload_file,omitempty"` + UploadThumbnailFile []byte `protobuf:"bytes,8,opt,name=upload_thumbnail_file,json=uploadThumbnailFile,proto3" json:"upload_thumbnail_file,omitempty"` +} + +func (x *UploadFileRequest) Reset() { + *x = UploadFileRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *UploadFileRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*UploadFileRequest) ProtoMessage() {} + +func (x *UploadFileRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[20] + 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 UploadFileRequest.ProtoReflect.Descriptor instead. +func (*UploadFileRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{20} +} + +func (x *UploadFileRequest) GetAllocation() string { + if x != nil { + return x.Allocation + } + return "" +} + +func (x *UploadFileRequest) GetPath() string { + if x != nil { + return x.Path + } + return "" +} + +func (x *UploadFileRequest) GetConnectionId() string { + if x != nil { + return x.ConnectionId + } + return "" +} + +func (x *UploadFileRequest) GetMethod() string { + if x != nil { + return x.Method + } + return "" +} + +func (x *UploadFileRequest) GetUploadMeta() string { + if x != nil { + return x.UploadMeta + } + return "" +} + +func (x *UploadFileRequest) GetUpdateMeta() string { + if x != nil { + return x.UpdateMeta + } + return "" +} + +func (x *UploadFileRequest) GetUploadFile() []byte { + if x != nil { + return x.UploadFile + } + return nil +} + +func (x *UploadFileRequest) GetUploadThumbnailFile() []byte { + if x != nil { + return x.UploadThumbnailFile + } + return nil +} + +type UploadFileResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Filename string `protobuf:"bytes,1,opt,name=filename,proto3" json:"filename,omitempty"` + Size int64 `protobuf:"varint,2,opt,name=size,proto3" json:"size,omitempty"` + ContentHash string `protobuf:"bytes,3,opt,name=content_hash,json=contentHash,proto3" json:"content_hash,omitempty"` + MerkleRoot string `protobuf:"bytes,4,opt,name=merkle_root,json=merkleRoot,proto3" json:"merkle_root,omitempty"` + //UploadLength indicates the size of the entire upload in bytes. The value MUST be a non-negative integer. + UploadLength int64 `protobuf:"varint,5,opt,name=upload_length,json=uploadLength,proto3" json:"upload_length,omitempty"` + //Upload-Offset indicates a byte offset within a resource. The value MUST be a non-negative integer. + UploadOffset int64 `protobuf:"varint,6,opt,name=upload_offset,json=uploadOffset,proto3" json:"upload_offset,omitempty"` +} + +func (x *UploadFileResponse) Reset() { + *x = UploadFileResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *UploadFileResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*UploadFileResponse) ProtoMessage() {} + +func (x *UploadFileResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[21] + 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 UploadFileResponse.ProtoReflect.Descriptor instead. +func (*UploadFileResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{21} +} + +func (x *UploadFileResponse) GetFilename() string { + if x != nil { + return x.Filename + } + return "" +} + +func (x *UploadFileResponse) GetSize() int64 { + if x != nil { + return x.Size + } + return 0 +} + +func (x *UploadFileResponse) GetContentHash() string { + if x != nil { + return x.ContentHash + } + return "" +} + +func (x *UploadFileResponse) GetMerkleRoot() string { + if x != nil { + return x.MerkleRoot + } + return "" +} + +func (x *UploadFileResponse) GetUploadLength() int64 { + if x != nil { + return x.UploadLength + } + return 0 +} + +func (x *UploadFileResponse) GetUploadOffset() int64 { + if x != nil { + return x.UploadOffset + } + return 0 +} + type Allocation struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -1348,7 +1540,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1361,7 +1553,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1374,7 +1566,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{22} } func (x *Allocation) GetID() string { @@ -1511,7 +1703,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1524,7 +1716,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1537,7 +1729,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{23} } func (x *Term) GetID() int64 { @@ -1588,7 +1780,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1601,7 +1793,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1614,7 +1806,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{24} } func (x *FileRef) GetType() string { @@ -1672,7 +1864,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1685,7 +1877,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1698,7 +1890,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{23} + return file_blobber_proto_rawDescGZIP(), []int{25} } func (x *FileMetaData) GetType() string { @@ -1889,7 +2081,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1902,7 +2094,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1915,7 +2107,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{24} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *DirMetaData) GetType() string { @@ -2181,196 +2373,233 @@ var file_blobber_proto_rawDesc = []byte{ 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, - 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, - 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, - 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, - 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, - 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, - 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, - 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, - 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, - 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, - 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, - 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, - 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, - 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9b, 0x02, 0x0a, 0x11, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, + 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, + 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x12, 0x1f, 0x0a, 0x0b, + 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x1f, 0x0a, + 0x0b, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x06, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x1f, + 0x0a, 0x0b, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x07, 0x20, + 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, + 0x32, 0x0a, 0x15, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x74, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x13, + 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x46, + 0x69, 0x6c, 0x65, 0x22, 0xd2, 0x01, 0x0a, 0x12, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, + 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, + 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x69, + 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x6f, + 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, 0x0a, + 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x23, + 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, 0x6e, + 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, 0x66, + 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, + 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, + 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, + 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, + 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, + 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, + 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, + 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, + 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, + 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, + 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, + 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, + 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, + 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, + 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, + 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, + 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, + 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, + 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, + 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, + 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, + 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, + 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, + 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, + 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, + 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, + 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, + 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, + 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, + 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, + 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, + 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, + 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, + 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, + 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, + 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, + 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, + 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, + 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, + 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, + 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, + 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, + 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, + 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, + 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, + 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, + 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, + 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, + 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, + 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, + 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, + 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, + 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, + 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, + 0xc6, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, + 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, - 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, - 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, - 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, - 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, - 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, + 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, + 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, + 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, + 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, + 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, + 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, + 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, + 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, - 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x5c, 0x0a, 0x09, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, + 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, + 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2385,7 +2614,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 25) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 27) var file_blobber_proto_goTypes = []interface{}{ (*GetObjectTreeRequest)(nil), // 0: blobber.service.v1.GetObjectTreeRequest (*GetObjectTreeResponse)(nil), // 1: blobber.service.v1.GetObjectTreeResponse @@ -2407,34 +2636,36 @@ var file_blobber_proto_goTypes = []interface{}{ (*Collaborator)(nil), // 17: blobber.service.v1.Collaborator (*GetAllocationRequest)(nil), // 18: blobber.service.v1.GetAllocationRequest (*GetAllocationResponse)(nil), // 19: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 20: blobber.service.v1.Allocation - (*Term)(nil), // 21: blobber.service.v1.Term - (*FileRef)(nil), // 22: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 23: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 24: blobber.service.v1.DirMetaData + (*UploadFileRequest)(nil), // 20: blobber.service.v1.UploadFileRequest + (*UploadFileResponse)(nil), // 21: blobber.service.v1.UploadFileResponse + (*Allocation)(nil), // 22: blobber.service.v1.Allocation + (*Term)(nil), // 23: blobber.service.v1.Term + (*FileRef)(nil), // 24: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 25: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 26: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 4, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 8, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 4, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 8, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 22, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 4, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 7, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 8, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 22, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 22, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 22, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 22, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 22, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 22, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 24, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 24, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 24, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 24, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 13, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 22, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 17, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 20, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 21, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 23, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 24, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 22, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 23, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 25, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 26, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 16, // 21: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 18, // 22: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 14, // 23: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -2443,15 +2674,17 @@ var file_blobber_proto_depIdxs = []int32{ 5, // 26: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest 2, // 27: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest 0, // 28: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 19, // 29: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 15, // 30: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 12, // 31: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 10, // 32: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 6, // 33: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 3, // 34: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 1, // 35: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 29, // [29:36] is the sub-list for method output_type - 22, // [22:29] is the sub-list for method input_type + 20, // 29: blobber.service.v1.Blobber.WriteFile:input_type -> blobber.service.v1.UploadFileRequest + 19, // 30: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 15, // 31: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 12, // 32: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 10, // 33: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 6, // 34: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 3, // 35: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 1, // 36: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 21, // 37: blobber.service.v1.Blobber.WriteFile:output_type -> blobber.service.v1.UploadFileResponse + 30, // [30:38] is the sub-list for method output_type + 22, // [22:30] is the sub-list for method input_type 22, // [22:22] is the sub-list for extension type_name 22, // [22:22] is the sub-list for extension extendee 0, // [0:22] is the sub-list for field type_name @@ -2704,7 +2937,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*UploadFileRequest); i { case 0: return &v.state case 1: @@ -2716,7 +2949,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*UploadFileResponse); i { case 0: return &v.state case 1: @@ -2728,7 +2961,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -2740,7 +2973,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -2752,6 +2985,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -2770,7 +3027,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 25, + NumMessages: 27, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index e73fdcaf5..530381bb5 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -11,6 +11,7 @@ import ( // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 // BlobberClient is the client API for Blobber service. @@ -24,6 +25,7 @@ type BlobberClient interface { GetObjectPath(ctx context.Context, in *GetObjectPathRequest, opts ...grpc.CallOption) (*GetObjectPathResponse, error) GetReferencePath(ctx context.Context, in *GetReferencePathRequest, opts ...grpc.CallOption) (*GetReferencePathResponse, error) GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) + WriteFile(ctx context.Context, in *UploadFileRequest, opts ...grpc.CallOption) (*UploadFileResponse, error) } type blobberClient struct { @@ -97,6 +99,15 @@ func (c *blobberClient) GetObjectTree(ctx context.Context, in *GetObjectTreeRequ return out, nil } +func (c *blobberClient) WriteFile(ctx context.Context, in *UploadFileRequest, opts ...grpc.CallOption) (*UploadFileResponse, error) { + out := new(UploadFileResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/WriteFile", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -108,6 +119,7 @@ type BlobberServer interface { GetObjectPath(context.Context, *GetObjectPathRequest) (*GetObjectPathResponse, error) GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) + WriteFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -136,6 +148,9 @@ func (UnimplementedBlobberServer) GetReferencePath(context.Context, *GetReferenc func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetObjectTree not implemented") } +func (UnimplementedBlobberServer) WriteFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method WriteFile not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -145,8 +160,8 @@ type UnsafeBlobberServer interface { mustEmbedUnimplementedBlobberServer() } -func RegisterBlobberServer(s *grpc.Server, srv BlobberServer) { - s.RegisterService(&_Blobber_serviceDesc, srv) +func RegisterBlobberServer(s grpc.ServiceRegistrar, srv BlobberServer) { + s.RegisterService(&Blobber_ServiceDesc, srv) } func _Blobber_GetAllocation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { @@ -275,7 +290,28 @@ func _Blobber_GetObjectTree_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } -var _Blobber_serviceDesc = grpc.ServiceDesc{ +func _Blobber_WriteFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(UploadFileRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).WriteFile(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/WriteFile", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).WriteFile(ctx, req.(*UploadFileRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Blobber_ServiceDesc is the grpc.ServiceDesc for Blobber service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Blobber_ServiceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), Methods: []grpc.MethodDesc{ @@ -307,6 +343,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "GetObjectTree", Handler: _Blobber_GetObjectTree_Handler, }, + { + MethodName: "WriteFile", + Handler: _Blobber_WriteFile_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index e02cfbd76..d46c1ab16 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -42,6 +42,7 @@ service Blobber { get: "/v2/file/objecttree/{allocation}" }; } + rpc WriteFile(UploadFileRequest) returns (UploadFileResponse) {} } message GetObjectTreeRequest { @@ -166,6 +167,27 @@ message GetAllocationResponse { Allocation allocation = 1; } +message UploadFileRequest { + string allocation = 1; + string path = 2; + string connection_id = 3; + string method = 4; + string upload_meta = 5; + string update_meta = 6; + bytes upload_file = 7; + bytes upload_thumbnail_file = 8; +} +message UploadFileResponse { + string filename = 1; + int64 size = 2; + string content_hash = 3; + string merkle_root = 4; + //UploadLength indicates the size of the entire upload in bytes. The value MUST be a non-negative integer. + int64 upload_length = 5; + //Upload-Offset indicates a byte offset within a resource. The value MUST be a non-negative integer. + int64 upload_offset = 6; +} + message Allocation { string ID = 1; string Tx = 2; diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index e16a5177e..ac05a186b 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -89,3 +89,14 @@ func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTr LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), } } + +func UploadFileResponseHandler(renameObjectResponse *blobbergrpc.UploadFileResponse) *blobberHTTP.UploadResult { + return &blobberHTTP.UploadResult{ + Filename: renameObjectResponse.Filename, + Size: renameObjectResponse.Size, + Hash: renameObjectResponse.ContentHash, + MerkleRoot: renameObjectResponse.MerkleRoot, + UploadLength: renameObjectResponse.UploadLength, + UploadOffset: renameObjectResponse.UploadOffset, + } +} diff --git a/code/go/0chain.net/blobbercore/filestore/fs_store.go b/code/go/0chain.net/blobbercore/filestore/fs_store.go index 84b30b7d1..d8ee762bd 100644 --- a/code/go/0chain.net/blobbercore/filestore/fs_store.go +++ b/code/go/0chain.net/blobbercore/filestore/fs_store.go @@ -578,6 +578,109 @@ func (fs *FileFSStore) WriteFile(allocationID string, fileData *FileInputData, return fileRef, nil } +func (fs *FileFSStore) WriteFileGRPC(allocationID string, fileData *FileInputData, + fileReader io.Reader, connectionID string) (*FileOutputData, error) { + + allocation, err := fs.SetupAllocation(allocationID, false) + if err != nil { + return nil, common.NewError("filestore_setup_error", "Error setting the fs store. "+err.Error()) + } + + tempFilePath := fs.generateTempPath(allocation, fileData, connectionID) + dest, err := NewChunkWriter(tempFilePath) + if err != nil { + return nil, common.NewError("file_creation_error", err.Error()) + } + defer dest.Close() + + fileRef := &FileOutputData{} + //var fileReader io.Reader = infile + + if fileData.IsResumable { + h := sha1.New() + offset, err := dest.WriteChunk(context.TODO(), fileData.UploadOffset, io.TeeReader(fileReader, h)) + + if err != nil { + return nil, common.NewError("file_write_error", err.Error()) + } + + fileRef.ContentHash = hex.EncodeToString(h.Sum(nil)) + fileRef.Size = dest.Size() + fileRef.Name = fileData.Name + fileRef.Path = fileData.Path + fileRef.UploadOffset = fileData.UploadOffset + offset + fileRef.UploadLength = fileData.UploadLength + + if !fileData.IsFinal { + //skip to compute hash until the last chunk is uploaded + return fileRef, nil + } + + fileReader = dest + } + + h := sha1.New() + bytesBuffer := bytes.NewBuffer(nil) + multiHashWriter := io.MultiWriter(h, bytesBuffer) + tReader := io.TeeReader(fileReader, multiHashWriter) + merkleHashes := make([]hash.Hash, 1024) + merkleLeaves := make([]util.Hashable, 1024) + for idx := range merkleHashes { + merkleHashes[idx] = sha3.New256() + } + fileSize := int64(0) + for { + var written int64 + + if fileData.IsResumable { + //all chunks have been written, only read bytes from local file , and compute hash + written, err = io.CopyN(ioutil.Discard, tReader, CHUNK_SIZE) + } else { + written, err = io.CopyN(dest, tReader, CHUNK_SIZE) + } + + if err != io.EOF && err != nil { + return nil, common.NewError("file_write_error", err.Error()) + } + fileSize += written + dataBytes := bytesBuffer.Bytes() + merkleChunkSize := 64 + for i := 0; i < len(dataBytes); i += merkleChunkSize { + end := i + merkleChunkSize + if end > len(dataBytes) { + end = len(dataBytes) + } + offset := i / merkleChunkSize + merkleHashes[offset].Write(dataBytes[i:end]) + } + + bytesBuffer.Reset() + if err != nil && err == io.EOF { + break + } + } + for idx := range merkleHashes { + merkleLeaves[idx] = util.NewStringHashable(hex.EncodeToString(merkleHashes[idx].Sum(nil))) + } + + var mt util.MerkleTreeI = &util.MerkleTree{} + mt.ComputeTree(merkleLeaves) + + //only update hash for whole file when it is not a resumable upload or is final chunk. + if !fileData.IsResumable || fileData.IsFinal { + fileRef.ContentHash = hex.EncodeToString(h.Sum(nil)) + } + + fileRef.Size = fileSize + fileRef.Name = fileData.Name + fileRef.Path = fileData.Path + fileRef.MerkleRoot = mt.GetRoot() + fileRef.UploadOffset = fileSize + fileRef.UploadLength = fileData.UploadLength + + return fileRef, nil +} + func (fs *FileFSStore) IterateObjects(allocationID string, handler FileObjectHandler) error { allocation, err := fs.SetupAllocation(allocationID, true) if err != nil { diff --git a/code/go/0chain.net/blobbercore/filestore/store.go b/code/go/0chain.net/blobbercore/filestore/store.go index 4d98a5136..ab6898143 100644 --- a/code/go/0chain.net/blobbercore/filestore/store.go +++ b/code/go/0chain.net/blobbercore/filestore/store.go @@ -2,6 +2,7 @@ package filestore import ( "encoding/json" + "io" "mime/multipart" "github.com/0chain/blobber/code/go/0chain.net/core/util" @@ -55,6 +56,7 @@ type FileStore interface { UploadToCloud(fileHash, filePath string) error DownloadFromCloud(fileHash, filePath string) error SetupAllocation(allocationID string, skipCreate bool) (*StoreAllocation, error) + WriteFileGRPC(allocationID string, fileData *FileInputData, fileReader io.Reader, connectionID string) (*FileOutputData, error) } var fsStore FileStore diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 5d001aafc..004396d14 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -3,7 +3,9 @@ package handler import ( + "bytes" "context" + "io" "net/http" "os" "runtime/pprof" @@ -37,7 +39,8 @@ func SetupHandlers(r *mux.Router) { svc := newGRPCBlobberService(&storageHandler, &packageHandler{}) //object operations - r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) + r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common. + ToJSONResponse(WithConnection(UploadHandler(svc))))) r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) @@ -310,14 +313,49 @@ func CopyHandler(ctx context.Context, r *http.Request) (interface{}, error) { } /*UploadHandler is the handler to respond to upload requests fro clients*/ -func UploadHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) - response, err := storageHandler.WriteFile(ctx, r) - if err != nil { - return nil, err - } +func UploadHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerGRPCContext(ctx, r) - return response, nil + req := &blobbergrpc.UploadFileRequest{ + Allocation: mux.Vars(r)["allocation"], + Path: r.FormValue("path"), + ConnectionId: r.FormValue("connection_id"), + Method: r.Method, + UploadMeta: r.FormValue("uploadMeta"), + UpdateMeta: r.FormValue("updateMeta"), + UploadFile: nil, + UploadThumbnailFile: nil, + } + + //set original file as []bytes + origFile, _, err := r.FormFile("uploadFile") + if err != nil { + return nil, common.NewError("invalid_parameters", "Error Reading multi parts for file."+err.Error()) + } + buf := bytes.NewBuffer(nil) + if _, err := io.Copy(buf, origFile); err != nil { + return nil, err + } + req.UploadFile = buf.Bytes() + + //set thumbnail file as []bytes + thumbFile, thumbHeader, _ := r.FormFile("uploadThumbnailFile") + if thumbHeader != nil { + buf := bytes.NewBuffer(nil) + if _, err := io.Copy(buf, thumbFile); err != nil { + return nil, err + } + req.UploadFile = buf.Bytes() + } + + uploadFileResponse, err := svc.WriteFile(ctx, req) + if err != nil { + return nil, err + } + + return convert.UploadFileResponseHandler(uploadFileResponse), nil + } } func UpdateAttributesHandler(ctx context.Context, r *http.Request) (interface{}, error) { diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go index 0942083ee..e3af458ea 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/handler_test.go @@ -167,7 +167,7 @@ func setupHandlers() (*mux.Router, map[string]string) { uName := "Upload" router.HandleFunc(uPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(UploadHandler), + WithReadOnlyConnection(UploadHandler(svc)), ), ), ).Name(uName) diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index d129bc7bd..f69e4ea9c 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -2,6 +2,7 @@ package handler import ( "context" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" @@ -30,6 +31,7 @@ type StorageHandlerI interface { // PackageHandler is an interface for all static functions that may need to be mocked type PackageHandler interface { + GetReference(ctx context.Context, allocationID string, newPath string) (*reference.Ref, error) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) @@ -39,6 +41,9 @@ type PackageHandler interface { GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) + GetAllocationChanges(ctx context.Context, connectionID string, + allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) + GetFileStore() filestore.FileStore GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) } @@ -68,6 +73,11 @@ func (r *packageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_ro return writemarker.GetWriteMarkerEntity(ctx, allocation_root) } +func (r *packageHandler) GetReference(ctx context.Context, allocationID string, newPath string) ( + *reference.Ref, error) { + return reference.GetReference(ctx, allocationID, newPath) +} + func (r *packageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { return reference.GetReferenceFromLookupHash(ctx, allocationID, path_hash) } @@ -83,3 +93,13 @@ func (r *packageHandler) GetCollaborators(ctx context.Context, refID int64) ([]r func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { return reference.IsACollaborator(ctx, refID, clientID) } + +func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, + allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { + + return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) +} + +func (r *packageHandler) GetFileStore() filestore.FileStore { + return filestore.GetFileStore() +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index abeebd162..5600df442 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -1 +1,221 @@ package handler + +import ( + "bytes" + "context" + "encoding/json" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/lock" + "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap/ctxzap" + "go.uber.org/zap" +) + +func (b *blobberGRPCService) WriteFile(ctx context.Context, r *blobbergrpc.UploadFileRequest) ( + *blobbergrpc.UploadFileResponse, error) { + + logger := ctxzap.Extract(ctx) + if r.Method == "GET" { + return nil, common.NewError("invalid_method", + "Invalid method used for the upload URL. Use multi-part form POST / PUT / DELETE instead") + } + + allocationTx := r.Allocation + allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) + } + + md := GetGRPCMetaDataFromCtx(ctx) + valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) + if !valid || err != nil { + return nil, common.NewError("invalid_signature", "Invalid signature") + } + allocationID := allocationObj.ID + + clientID := md.Client + if len(clientID) == 0 { + return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner or the payer of the allocation") + } + + connectionID := r.ConnectionId + if len(connectionID) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid connection id passed") + } + + connectionObj, err := b.packageHandler.GetAllocationChanges(ctx, connectionID, allocationID, clientID) + if err != nil { + return nil, common.NewError("meta_error", "Error reading metadata for connection") + } + + mutex := lock.GetMutex(connectionObj.TableName(), connectionID) + mutex.Lock() + defer mutex.Unlock() + + mode := allocation.INSERT_OPERATION + if r.Method == "PUT" { + mode = allocation.UPDATE_OPERATION + } else if r.Method == "DELETE" { + mode = allocation.DELETE_OPERATION + } + + result := &blobbergrpc.UploadFileResponse{} + if mode == allocation.DELETE_OPERATION { + if allocationObj.OwnerID != clientID && allocationObj.PayerID != clientID { + return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner or the payer of the allocation") + } + result, err = b.DeleteFile(ctx, r, connectionObj) + if err != nil { + return nil, err + } + } else if mode == allocation.INSERT_OPERATION || mode == allocation.UPDATE_OPERATION { + var formData allocation.UpdateFileChange + uploadMetaString := r.UploadMeta + if mode == allocation.UPDATE_OPERATION { + uploadMetaString = r.UpdateMeta + } + err = json.Unmarshal([]byte(uploadMetaString), &formData) + if err != nil { + return nil, common.NewError("invalid_parameters", + "Invalid parameters. Error parsing the meta data for upload."+err.Error()) + } + exisitingFileRef, _ := b.packageHandler.GetReference(ctx, allocationID, formData.Path) + existingFileRefSize := int64(0) + exisitingFileOnCloud := false + if mode == allocation.INSERT_OPERATION { + if allocationObj.OwnerID != clientID && allocationObj.PayerID != clientID { + return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner or the payer of the allocation") + } + + if exisitingFileRef != nil { + return nil, common.NewError("duplicate_file", "File at path already exists") + } + } else if mode == allocation.UPDATE_OPERATION { + if exisitingFileRef == nil { + return nil, common.NewError("invalid_file_update", "File at path does not exist for update") + } + + if allocationObj.OwnerID != clientID && + allocationObj.PayerID != clientID && + !reference.IsACollaborator(ctx, exisitingFileRef.ID, clientID) { + return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner, collaborator or the payer of the allocation") + } + } + + if exisitingFileRef != nil { + existingFileRefSize = exisitingFileRef.Size + exisitingFileOnCloud = exisitingFileRef.OnCloud + } + + //Files read from grpc bytes. Need to consider about file size and client side implementation for this + //This is a grpc equivalent implementation for http multi-part form file. Need a proper review on this + grpcOrgFile := bytes.NewReader(r.UploadFile) + thumb := r.UploadThumbnailFile + thumbnailPresent := thumb != nil + + fileInputData := &filestore.FileInputData{Name: formData.Filename, Path: formData.Path, OnCloud: exisitingFileOnCloud} + fileOutputData, err := b.packageHandler.GetFileStore().WriteFileGRPC(allocationID, fileInputData, grpcOrgFile, connectionObj.GetConnectionID()) + if err != nil { + return nil, common.NewError("upload_error", "Failed to upload the file. "+err.Error()) + } + + result.Filename = formData.Filename + result.ContentHash = fileOutputData.ContentHash + result.MerkleRoot = fileOutputData.MerkleRoot + result.Size = fileOutputData.Size + + if len(formData.Hash) > 0 && formData.Hash != fileOutputData.ContentHash { + return nil, common.NewError("content_hash_mismatch", "Content hash provided in the meta data does not match the file content") + } + if len(formData.MerkleRoot) > 0 && formData.MerkleRoot != fileOutputData.MerkleRoot { + return nil, common.NewError("content_merkle_root_mismatch", "Merkle root provided in the meta data does not match the file content") + } + if fileOutputData.Size > config.Configuration.MaxFileSize { + return nil, common.NewError("file_size_limit_exceeded", "Size for the given file is larger than the max limit") + } + + formData.Hash = fileOutputData.ContentHash + formData.MerkleRoot = fileOutputData.MerkleRoot + formData.AllocationID = allocationID + formData.Size = fileOutputData.Size + + allocationSize := fileOutputData.Size + if thumbnailPresent { + thumbFile := bytes.NewReader(thumb) + thumbInputData := &filestore.FileInputData{Name: formData.ThumbnailFilename, Path: formData.Path} + thumbOutputData, err := b.packageHandler.GetFileStore().WriteFileGRPC(allocationID, thumbInputData, thumbFile, connectionObj.GetConnectionID()) + if err != nil { + return nil, common.NewError("upload_error", "Failed to upload the thumbnail. "+err.Error()) + } + if len(formData.ThumbnailHash) > 0 && formData.ThumbnailHash != thumbOutputData.ContentHash { + return nil, common.NewError("content_hash_mismatch", "Content hash provided in the meta data does not match the thumbnail content") + } + formData.ThumbnailHash = thumbOutputData.ContentHash + formData.ThumbnailSize = thumbOutputData.Size + formData.ThumbnailFilename = thumbInputData.Name + } + + if allocationObj.BlobberSizeUsed+(allocationSize-existingFileRefSize) > allocationObj.BlobberSize { + return nil, common.NewError("max_allocation_size", "Max size reached for the allocation with this blobber") + } + + allocationChange := &allocation.AllocationChange{} + allocationChange.ConnectionID = connectionObj.GetConnectionID() + allocationChange.Size = allocationSize - existingFileRefSize + allocationChange.Operation = mode + + connectionObj.SetSize(connectionObj.GetSize() + allocationChange.Size) + if mode == allocation.INSERT_OPERATION { + connectionObj.AddChange(allocationChange, &formData.NewFileChange) + } else if mode == allocation.UPDATE_OPERATION { + connectionObj.AddChange(allocationChange, &formData) + } + } + + err = connectionObj.Save(ctx) + if err != nil { + logger.Error("Error in writing the connection meta data", zap.Error(err)) + return nil, common.NewError("connection_write_error", "Error writing the connection meta data") + } + + return result, nil +} + +func (b *blobberGRPCService) DeleteFile(ctx context.Context, r *blobbergrpc.UploadFileRequest, + connectionObj allocation.IAllocationChangeCollector) (*blobbergrpc.UploadFileResponse, error) { + + path := r.Path + if len(path) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid path") + } + + fileRef, _ := b.packageHandler.GetReference(ctx, connectionObj.GetAllocationID(), path) + if fileRef != nil { + deleteSize := fileRef.Size + + allocationChange := &allocation.AllocationChange{} + allocationChange.ConnectionID = connectionObj.GetConnectionID() + allocationChange.Size = 0 - deleteSize + allocationChange.Operation = allocation.DELETE_OPERATION + dfc := &allocation.DeleteFileChange{ConnectionID: connectionObj.GetConnectionID(), + AllocationID: connectionObj.GetAllocationID(), Name: fileRef.Name, + Hash: fileRef.Hash, Path: fileRef.Path, Size: deleteSize} + + connectionObj.SetSize(connectionObj.GetSize() + allocationChange.Size) + connectionObj.AddChange(allocationChange, dfc) + + result := &blobbergrpc.UploadFileResponse{} + result.Filename = fileRef.Name + result.ContentHash = fileRef.Hash + result.MerkleRoot = fileRef.MerkleRoot + result.Size = fileRef.Size + + return result, nil + } + + return nil, common.NewError("invalid_file", "File does not exist at path") +} diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index bb3789a42..ff4034242 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -761,6 +761,34 @@ } } }, + "v1UploadFileResponse": { + "type": "object", + "properties": { + "filename": { + "type": "string" + }, + "size": { + "type": "string", + "format": "int64" + }, + "contentHash": { + "type": "string" + }, + "merkleRoot": { + "type": "string" + }, + "uploadLength": { + "type": "string", + "format": "int64", + "description": "UploadLength indicates the size of the entire upload in bytes. The value MUST be a non-negative integer." + }, + "uploadOffset": { + "type": "string", + "format": "int64", + "description": "Upload-Offset indicates a byte offset within a resource. The value MUST be a non-negative integer." + } + } + }, "v1WriteMarker": { "type": "object", "properties": { From b6b6cc9dd930d399c0a5b4358c8ffa50f276b192 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 15:21:59 +0530 Subject: [PATCH 064/183] upload file handler grpc tests added --- .../object_operation_grpc_handler_test.go | 231 ++++++++++++++ .../0chain.net/blobbercore/mocks/FileStore.go | 300 ++++++++++++++++++ .../blobbercore/mocks/PackageHandler.go | 68 +++- 3 files changed, 598 insertions(+), 1 deletion(-) create mode 100644 code/go/0chain.net/blobbercore/mocks/FileStore.go diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go index abeebd162..4fc39c5db 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -1 +1,232 @@ package handler + +import ( + "context" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/mock" + "google.golang.org/grpc/metadata" + "testing" +) + +func TestBlobberGRPCService_WriteFile_Success_POST(t *testing.T) { + allocationTx := randString(32) + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + req := &blobbergrpc.UploadFileRequest{ + Allocation: allocationTx, + Path: `path`, + ConnectionId: `connection_id`, + Method: `POST`, + UploadMeta: `{"filename": "test_file","filepath":"path"}`, + UploadFile: []byte(`this is a upload file content`), + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "client_key", + common.ClientSignatureHeader: clientSignature, + })) + mockStorageHandler := &storageHandlerI{} + alloc := &allocation.Allocation{ + Tx: req.Allocation, + ID: `allocation_id`, + OwnerID: `client`, + OwnerPublicKey: pubKey, + } + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). + Return(alloc, nil) + + mockAllocCollector := &mocks.IAllocationChangeCollector{} + mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) + mockAllocCollector.On(`GetAllocationID`).Return(req.Allocation) + mockAllocCollector.On(`SetSize`, mock.Anything).Return() + mockAllocCollector.On(`GetSize`).Return(int64(1)) + mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() + mockAllocCollector.On(`Save`, mock.Anything).Return(nil) + mockAllocCollector.On(`TableName`).Return(`allocation_connections`) + + mockFileStore := &mocks.FileStore{} + fileOutput := &filestore.FileOutputData{ + Name: "test_file", + Path: "path", + MerkleRoot: "root", + ContentHash: "hash", + } + mockFileStore.On(`WriteFileGRPC`, alloc.ID, mock.Anything, mock.Anything, req.ConnectionId).Return( + fileOutput, nil) + + mockReferencePackage := &mocks.PackageHandler{} + mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, + req.ConnectionId, alloc.ID, alloc.OwnerID).Return(mockAllocCollector, nil) + mockReferencePackage.On(`GetReference`, mock.Anything, alloc.ID, `path`). + Return(nil, nil) + mockReferencePackage.On(`GetFileStore`). + Return(mockFileStore) + + resOk := &blobbergrpc.UploadFileResponse{ + Filename: fileOutput.Name, + Size: 0, + ContentHash: fileOutput.ContentHash, + MerkleRoot: fileOutput.MerkleRoot, + } + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + gotResponse, err := svc.WriteFile(ctx, req) + if err != nil { + t.Fatal("unexpected error - " + err.Error()) + } + + assert.Equal(t, gotResponse, resOk) + +} + +func TestBlobberGRPCService_WriteFile_Success_PUT(t *testing.T) { + allocationTx := randString(32) + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + req := &blobbergrpc.UploadFileRequest{ + Allocation: allocationTx, + Path: `path`, + ConnectionId: `connection_id`, + Method: `PUT`, + UpdateMeta: `{"filename": "test_file","filepath":"path"}`, + UploadFile: []byte(`this is a upload file content`), + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "client_key", + common.ClientSignatureHeader: clientSignature, + })) + mockStorageHandler := &storageHandlerI{} + alloc := &allocation.Allocation{ + Tx: req.Allocation, + ID: `allocation_id`, + OwnerID: `client`, + OwnerPublicKey: pubKey, + } + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). + Return(alloc, nil) + + mockAllocCollector := &mocks.IAllocationChangeCollector{} + mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) + mockAllocCollector.On(`GetAllocationID`).Return(req.Allocation) + mockAllocCollector.On(`SetSize`, mock.Anything).Return() + mockAllocCollector.On(`GetSize`).Return(int64(1)) + mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() + mockAllocCollector.On(`Save`, mock.Anything).Return(nil) + mockAllocCollector.On(`TableName`).Return(`allocation_connections`) + + mockFileStore := &mocks.FileStore{} + fileOutput := &filestore.FileOutputData{ + Name: "test_file", + Path: "path", + MerkleRoot: "root", + ContentHash: "hash", + } + mockFileStore.On(`WriteFileGRPC`, alloc.ID, mock.Anything, mock.Anything, req.ConnectionId).Return( + fileOutput, nil) + + mockReferencePackage := &mocks.PackageHandler{} + mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, + req.ConnectionId, alloc.ID, alloc.OwnerID).Return(mockAllocCollector, nil) + mockReferencePackage.On(`GetReference`, mock.Anything, alloc.ID, `path`). + Return(&reference.Ref{}, nil) + mockReferencePackage.On(`GetFileStore`). + Return(mockFileStore) + + resOk := &blobbergrpc.UploadFileResponse{ + Filename: fileOutput.Name, + Size: 0, + ContentHash: fileOutput.ContentHash, + MerkleRoot: fileOutput.MerkleRoot, + } + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + gotResponse, err := svc.WriteFile(ctx, req) + if err != nil { + t.Fatal("unexpected error - " + err.Error()) + } + + assert.Equal(t, gotResponse, resOk) + +} + +func TestBlobberGRPCService_WriteFile_Success_DELETE(t *testing.T) { + allocationTx := randString(32) + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + req := &blobbergrpc.UploadFileRequest{ + Allocation: allocationTx, + Path: `path`, + ConnectionId: `connection_id`, + Method: `DELETE`, + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "client", + common.ClientKeyHeader: "client_key", + common.ClientSignatureHeader: clientSignature, + })) + mockStorageHandler := &storageHandlerI{} + alloc := &allocation.Allocation{ + Tx: req.Allocation, + ID: `allocation_id`, + OwnerID: `client`, + OwnerPublicKey: pubKey, + PayerID: `client`, + } + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). + Return(alloc, nil) + + mockAllocCollector := &mocks.IAllocationChangeCollector{} + mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) + mockAllocCollector.On(`GetAllocationID`).Return(alloc.ID) + mockAllocCollector.On(`SetSize`, mock.Anything).Return() + mockAllocCollector.On(`GetSize`).Return(int64(1)) + mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() + mockAllocCollector.On(`Save`, mock.Anything).Return(nil) + mockAllocCollector.On(`TableName`).Return(`allocation_connections`) + + mockFileStore := &mocks.FileStore{} + fileRef := &reference.Ref{ + Name: "test_file", + Path: "path", + MerkleRoot: "root", + Hash: "hash", + } + + mockReferencePackage := &mocks.PackageHandler{} + mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, + req.ConnectionId, alloc.ID, alloc.OwnerID).Return(mockAllocCollector, nil) + mockReferencePackage.On(`GetReference`, mock.Anything, alloc.ID, `path`). + Return(fileRef, nil) + mockReferencePackage.On(`GetFileStore`). + Return(mockFileStore) + + resOk := &blobbergrpc.UploadFileResponse{ + Filename: fileRef.Name, + Size: fileRef.Size, + ContentHash: fileRef.Hash, + MerkleRoot: fileRef.MerkleRoot, + } + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + gotResponse, err := svc.WriteFile(ctx, req) + if err != nil { + t.Fatal("unexpected error - " + err.Error()) + } + + assert.Equal(t, gotResponse, resOk) + +} diff --git a/code/go/0chain.net/blobbercore/mocks/FileStore.go b/code/go/0chain.net/blobbercore/mocks/FileStore.go new file mode 100644 index 000000000..27ff86003 --- /dev/null +++ b/code/go/0chain.net/blobbercore/mocks/FileStore.go @@ -0,0 +1,300 @@ +// Code generated by mockery 2.7.5. DO NOT EDIT. + +package mocks + +import ( + io "io" + + filestore "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + + json "encoding/json" + + mock "github.com/stretchr/testify/mock" + + multipart "mime/multipart" + + util "github.com/0chain/blobber/code/go/0chain.net/core/util" +) + +// FileStore is an autogenerated mock type for the FileStore type +type FileStore struct { + mock.Mock +} + +// CommitWrite provides a mock function with given fields: allocationID, fileData, connectionID +func (_m *FileStore) CommitWrite(allocationID string, fileData *filestore.FileInputData, connectionID string) (bool, error) { + ret := _m.Called(allocationID, fileData, connectionID) + + var r0 bool + if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, string) bool); ok { + r0 = rf(allocationID, fileData, connectionID) + } else { + r0 = ret.Get(0).(bool) + } + + var r1 error + if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, string) error); ok { + r1 = rf(allocationID, fileData, connectionID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// DeleteFile provides a mock function with given fields: allocationID, contentHash +func (_m *FileStore) DeleteFile(allocationID string, contentHash string) error { + ret := _m.Called(allocationID, contentHash) + + var r0 error + if rf, ok := ret.Get(0).(func(string, string) error); ok { + r0 = rf(allocationID, contentHash) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// DeleteTempFile provides a mock function with given fields: allocationID, fileData, connectionID +func (_m *FileStore) DeleteTempFile(allocationID string, fileData *filestore.FileInputData, connectionID string) error { + ret := _m.Called(allocationID, fileData, connectionID) + + var r0 error + if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, string) error); ok { + r0 = rf(allocationID, fileData, connectionID) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// DownloadFromCloud provides a mock function with given fields: fileHash, filePath +func (_m *FileStore) DownloadFromCloud(fileHash string, filePath string) error { + ret := _m.Called(fileHash, filePath) + + var r0 error + if rf, ok := ret.Get(0).(func(string, string) error); ok { + r0 = rf(fileHash, filePath) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// GetFileBlock provides a mock function with given fields: allocationID, fileData, blockNum, numBlocks +func (_m *FileStore) GetFileBlock(allocationID string, fileData *filestore.FileInputData, blockNum int64, numBlocks int64) ([]byte, error) { + ret := _m.Called(allocationID, fileData, blockNum, numBlocks) + + var r0 []byte + if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, int64, int64) []byte); ok { + r0 = rf(allocationID, fileData, blockNum, numBlocks) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]byte) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, int64, int64) error); ok { + r1 = rf(allocationID, fileData, blockNum, numBlocks) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetFileBlockForChallenge provides a mock function with given fields: allocationID, fileData, blockoffset +func (_m *FileStore) GetFileBlockForChallenge(allocationID string, fileData *filestore.FileInputData, blockoffset int) (json.RawMessage, util.MerkleTreeI, error) { + ret := _m.Called(allocationID, fileData, blockoffset) + + var r0 json.RawMessage + if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, int) json.RawMessage); ok { + r0 = rf(allocationID, fileData, blockoffset) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(json.RawMessage) + } + } + + var r1 util.MerkleTreeI + if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, int) util.MerkleTreeI); ok { + r1 = rf(allocationID, fileData, blockoffset) + } else { + if ret.Get(1) != nil { + r1 = ret.Get(1).(util.MerkleTreeI) + } + } + + var r2 error + if rf, ok := ret.Get(2).(func(string, *filestore.FileInputData, int) error); ok { + r2 = rf(allocationID, fileData, blockoffset) + } else { + r2 = ret.Error(2) + } + + return r0, r1, r2 +} + +// GetTempPathSize provides a mock function with given fields: allocationID +func (_m *FileStore) GetTempPathSize(allocationID string) (int64, error) { + ret := _m.Called(allocationID) + + var r0 int64 + if rf, ok := ret.Get(0).(func(string) int64); ok { + r0 = rf(allocationID) + } else { + r0 = ret.Get(0).(int64) + } + + var r1 error + if rf, ok := ret.Get(1).(func(string) error); ok { + r1 = rf(allocationID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetTotalDiskSizeUsed provides a mock function with given fields: +func (_m *FileStore) GetTotalDiskSizeUsed() (int64, error) { + ret := _m.Called() + + var r0 int64 + if rf, ok := ret.Get(0).(func() int64); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(int64) + } + + var r1 error + if rf, ok := ret.Get(1).(func() error); ok { + r1 = rf() + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetlDiskSizeUsed provides a mock function with given fields: allocationID +func (_m *FileStore) GetlDiskSizeUsed(allocationID string) (int64, error) { + ret := _m.Called(allocationID) + + var r0 int64 + if rf, ok := ret.Get(0).(func(string) int64); ok { + r0 = rf(allocationID) + } else { + r0 = ret.Get(0).(int64) + } + + var r1 error + if rf, ok := ret.Get(1).(func(string) error); ok { + r1 = rf(allocationID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// IterateObjects provides a mock function with given fields: allocationID, handler +func (_m *FileStore) IterateObjects(allocationID string, handler filestore.FileObjectHandler) error { + ret := _m.Called(allocationID, handler) + + var r0 error + if rf, ok := ret.Get(0).(func(string, filestore.FileObjectHandler) error); ok { + r0 = rf(allocationID, handler) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// SetupAllocation provides a mock function with given fields: allocationID, skipCreate +func (_m *FileStore) SetupAllocation(allocationID string, skipCreate bool) (*filestore.StoreAllocation, error) { + ret := _m.Called(allocationID, skipCreate) + + var r0 *filestore.StoreAllocation + if rf, ok := ret.Get(0).(func(string, bool) *filestore.StoreAllocation); ok { + r0 = rf(allocationID, skipCreate) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*filestore.StoreAllocation) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(string, bool) error); ok { + r1 = rf(allocationID, skipCreate) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// UploadToCloud provides a mock function with given fields: fileHash, filePath +func (_m *FileStore) UploadToCloud(fileHash string, filePath string) error { + ret := _m.Called(fileHash, filePath) + + var r0 error + if rf, ok := ret.Get(0).(func(string, string) error); ok { + r0 = rf(fileHash, filePath) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// WriteFile provides a mock function with given fields: allocationID, fileData, infile, connectionID +func (_m *FileStore) WriteFile(allocationID string, fileData *filestore.FileInputData, infile multipart.File, connectionID string) (*filestore.FileOutputData, error) { + ret := _m.Called(allocationID, fileData, infile, connectionID) + + var r0 *filestore.FileOutputData + if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, multipart.File, string) *filestore.FileOutputData); ok { + r0 = rf(allocationID, fileData, infile, connectionID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*filestore.FileOutputData) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, multipart.File, string) error); ok { + r1 = rf(allocationID, fileData, infile, connectionID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// WriteFileGRPC provides a mock function with given fields: allocationID, fileData, fileReader, connectionID +func (_m *FileStore) WriteFileGRPC(allocationID string, fileData *filestore.FileInputData, fileReader io.Reader, connectionID string) (*filestore.FileOutputData, error) { + ret := _m.Called(allocationID, fileData, fileReader, connectionID) + + var r0 *filestore.FileOutputData + if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, io.Reader, string) *filestore.FileOutputData); ok { + r0 = rf(allocationID, fileData, fileReader, connectionID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*filestore.FileOutputData) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, io.Reader, string) error); ok { + r1 = rf(allocationID, fileData, fileReader, connectionID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 73c3dd36f..8f21faee0 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -1,10 +1,14 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. +// Code generated by mockery 2.7.5. DO NOT EDIT. package mocks import ( context "context" + allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + + filestore "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + mock "github.com/stretchr/testify/mock" reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" @@ -19,6 +23,29 @@ type PackageHandler struct { mock.Mock } +// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID +func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { + ret := _m.Called(ctx, connectionID, allocationID, clientID) + + var r0 allocation.IAllocationChangeCollector + if rf, ok := ret.Get(0).(func(context.Context, string, string, string) allocation.IAllocationChangeCollector); ok { + r0 = rf(ctx, connectionID, allocationID, clientID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(allocation.IAllocationChangeCollector) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { + r1 = rf(ctx, connectionID, allocationID, clientID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // GetCollaborators provides a mock function with given fields: ctx, refID func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { ret := _m.Called(ctx, refID) @@ -88,6 +115,22 @@ func (_m *PackageHandler) GetFileStats(ctx context.Context, refID int64) (*stats return r0, r1 } +// GetFileStore provides a mock function with given fields: +func (_m *PackageHandler) GetFileStore() filestore.FileStore { + ret := _m.Called() + + var r0 filestore.FileStore + if rf, ok := ret.Get(0).(func() filestore.FileStore); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(filestore.FileStore) + } + } + + return r0 +} + // GetObjectPath provides a mock function with given fields: ctx, allocationID, blockNum func (_m *PackageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { ret := _m.Called(ctx, allocationID, blockNum) @@ -157,6 +200,29 @@ func (_m *PackageHandler) GetRefWithChildren(ctx context.Context, allocationID s return r0, r1 } +// GetReference provides a mock function with given fields: ctx, allocationID, newPath +func (_m *PackageHandler) GetReference(ctx context.Context, allocationID string, newPath string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, newPath) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, newPath) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, newPath) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // GetReferenceFromLookupHash provides a mock function with given fields: ctx, allocationID, path_hash func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { ret := _m.Called(ctx, allocationID, path_hash) From f71e01c1ff2bd67b64fb40334f1ddd34d40b6e72 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 30 May 2021 19:13:00 +0530 Subject: [PATCH 065/183] :hammer: attached debugger to blobber in debug mode --- docker.local/Dockerfile | 9 +++++++-- docker.local/bin/blobber.start_bls.sh | 18 +++++++++++------- 2 files changed, 18 insertions(+), 9 deletions(-) diff --git a/docker.local/Dockerfile b/docker.local/Dockerfile index f9d18464f..ef7b728b0 100644 --- a/docker.local/Dockerfile +++ b/docker.local/Dockerfile @@ -34,14 +34,19 @@ WORKDIR $SRC_DIR/code/go/0chain.net/blobber ARG GIT_COMMIT ENV GIT_COMMIT=$GIT_COMMIT -RUN go build -v -tags "bn256 development" -ldflags "-X 0chain.net/core/build.BuildTag=$GIT_COMMIT" +RUN go build -v -tags "bn256 development" -gcflags "all=-N -l" -ldflags "-X 0chain.net/core/build.BuildTag=$GIT_COMMIT" # Copy the build artifact into a minimal runtime image: FROM golang:1.14.9-alpine3.12 -RUN apk add gmp gmp-dev openssl-dev +RUN apk add gmp gmp-dev openssl-dev git COPY --from=blobber_build /usr/local/lib/libmcl*.so \ /usr/local/lib/libbls*.so \ /usr/local/lib/ + +RUN git clone --branch v1.4.1 https://github.com/go-delve/delve +WORKDIR ./delve +RUN go install ./cmd/dlv + ENV APP_DIR=/blobber WORKDIR $APP_DIR COPY --from=blobber_build $APP_DIR/code/go/0chain.net/blobber/blobber $APP_DIR/bin/blobber diff --git a/docker.local/bin/blobber.start_bls.sh b/docker.local/bin/blobber.start_bls.sh index f3686577b..4aba602ee 100755 --- a/docker.local/bin/blobber.start_bls.sh +++ b/docker.local/bin/blobber.start_bls.sh @@ -1,11 +1,15 @@ -#!/bin/sh +#!/bin/bash +set -e + PWD=`pwd` BLOBBER_DIR=`basename $PWD` BLOBBER_ID=`echo my directory $BLOBBER_DIR | sed -e 's/.*\(.\)$/\1/'` - -echo Starting blobber$BLOBBER_ID ... - -# echo blobber$i - -BLOBBER=$BLOBBER_ID docker-compose -p blobber$BLOBBER_ID -f ../b0docker-compose.yml up +if [[ "$*" == *"--debug"* ]] +then + echo Starting blobber$BLOBBER_ID in debug mode... + BLOBBER=$BLOBBER_ID docker-compose -p blobber$BLOBBER_ID -f ../b0docker-compose-debug.yml up +else + echo Starting blobber$BLOBBER_ID ... + BLOBBER=$BLOBBER_ID docker-compose -p blobber$BLOBBER_ID -f ../b0docker-compose.yml up +fi \ No newline at end of file From d2d5e19918f63e70762dd3af36dcd6c12f372dc9 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Sun, 30 May 2021 19:13:18 +0530 Subject: [PATCH 066/183] missing file from previous commit --- docker.local/b0docker-compose-debug.yml | 83 +++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 docker.local/b0docker-compose-debug.yml diff --git a/docker.local/b0docker-compose-debug.yml b/docker.local/b0docker-compose-debug.yml new file mode 100644 index 000000000..f25c128cc --- /dev/null +++ b/docker.local/b0docker-compose-debug.yml @@ -0,0 +1,83 @@ +version: "3" +services: + postgres: + image: postgres:11 + environment: + POSTGRES_PORT: 5432 + POSTGRES_HOST: postgres + POSTGRES_USER: postgres + POSTGRES_HOST_AUTH_METHOD: trust + ports: + - "5432:5432" + volumes: + - ./blobber${BLOBBER}/data/postgresql:/var/lib/postgresql/data + networks: + default: + postgres-post: + image: postgres:11 + environment: + POSTGRES_PORT: 5432 + POSTGRES_HOST: postgres + POSTGRES_USER: postgres + volumes: + - ../bin:/blobber/bin + - ../sql:/blobber/sql + command: bash /blobber/bin/postgres-entrypoint.sh + links: + - postgres:postgres + validator: + image: validator + environment: + - DOCKER= true + depends_on: + - postgres-post + links: + - postgres-post:postgres-post + volumes: + - ../config:/blobber/config + - ./blobber${BLOBBER}/data:/blobber/data + - ./blobber${BLOBBER}/log:/blobber/log + - ./keys_config:/blobber/keysconfig + ports: + - "506${BLOBBER}:506${BLOBBER}" + command: ./bin/validator --port 506${BLOBBER} --hostname 198.18.0.6${BLOBBER} --deployment_mode 0 --keys_file keysconfig/b0bnode${BLOBBER}_keys.txt --log_dir /blobber/log + networks: + default: + testnet0: + ipv4_address: 198.18.0.6${BLOBBER} + + blobber: + image: blobber + environment: + - DOCKER= true + depends_on: + - validator + links: + - validator:validator + volumes: + - ../config:/blobber/config + - ./blobber${BLOBBER}/files:/blobber/files + - ./blobber${BLOBBER}/data:/blobber/data + - ./blobber${BLOBBER}/log:/blobber/log + - ./keys_config:/blobber/keysconfig + - ./blobber${BLOBBER}/data/tmp:/tmp + ports: + - "505${BLOBBER}:505${BLOBBER}" + - "703${BLOBBER}:703${BLOBBER}" + - "236${BLOBBER}:236${BLOBBER}" + command: dlv --listen=:236${BLOBBER} --headless=true --api-version=2 --accept-multiclient exec ./bin/blobber -- --port 505${BLOBBER} --grpc_port 703${BLOBBER} --hostname localhost --deployment_mode 0 --keys_file keysconfig/b0bnode${BLOBBER}_keys.txt --files_dir /blobber/files --log_dir /blobber/log --db_dir /blobber/data --minio_file keysconfig/minio_config.txt + networks: + default: + testnet0: + ipv4_address: 198.18.0.9${BLOBBER} + +networks: + default: + driver: bridge + testnet0: + external: true + +volumes: + data: + config: + bin: From 5dc0272eb0d51a795571879f07b848463b3635ce Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 20:36:17 +0530 Subject: [PATCH 067/183] workflow updated for pull requests --- .github/workflows/ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2e913f0ba..d755406d7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,6 +5,9 @@ on: release: types: - published + pull_request: + paths-ignore: + - '**.md' env: BLOBBER_REGISTRY: ${{ secrets.BLOBBER_REGISTRY }} From 75984a283b27384ee0a38edc0a760835a0bf041d Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 20:54:59 +0530 Subject: [PATCH 068/183] workflow updated for pull requests --- .github/workflows/ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2e913f0ba..f68d4fa2c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,7 +5,9 @@ on: release: types: - published - + pull_request: + paths-ignore: + - '**.md' env: BLOBBER_REGISTRY: ${{ secrets.BLOBBER_REGISTRY }} VALIDATOR_REGISTRY: ${{ secrets.VALIDATOR_REGISTRY }} From efa819e21c1a12a6ed4650f76b5017623d77cbd0 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 20:55:42 +0530 Subject: [PATCH 069/183] workflow updated for pull requests --- .github/workflows/ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2e913f0ba..f68d4fa2c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,7 +5,9 @@ on: release: types: - published - + pull_request: + paths-ignore: + - '**.md' env: BLOBBER_REGISTRY: ${{ secrets.BLOBBER_REGISTRY }} VALIDATOR_REGISTRY: ${{ secrets.VALIDATOR_REGISTRY }} From d0d4c0f9f96f4d97b57b6156e9e8cc16432a1389 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 20:56:13 +0530 Subject: [PATCH 070/183] workflow updated for pull requests --- .github/workflows/ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2e913f0ba..f68d4fa2c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,7 +5,9 @@ on: release: types: - published - + pull_request: + paths-ignore: + - '**.md' env: BLOBBER_REGISTRY: ${{ secrets.BLOBBER_REGISTRY }} VALIDATOR_REGISTRY: ${{ secrets.VALIDATOR_REGISTRY }} From 7f014d56f599efa96fda787f206fc43e49a247f1 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 20:56:46 +0530 Subject: [PATCH 071/183] workflow updated for pull requests --- .github/workflows/ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2e913f0ba..f68d4fa2c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,7 +5,9 @@ on: release: types: - published - + pull_request: + paths-ignore: + - '**.md' env: BLOBBER_REGISTRY: ${{ secrets.BLOBBER_REGISTRY }} VALIDATOR_REGISTRY: ${{ secrets.VALIDATOR_REGISTRY }} From 2373252b16d3db2d467457e814e01d154509e1c5 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 21:57:08 +0530 Subject: [PATCH 072/183] proto versions mismatch fixed --- .../0chain.net/blobbercore/blobbergrpc/blobber.pb.go | 2 +- .../blobbercore/blobbergrpc/blobber_grpc.pb.go | 10 +++------- code/go/0chain.net/blobbercore/handler/zcncore.go | 10 +++++----- 3 files changed, 9 insertions(+), 13 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 47a86f3ca..387a2ca99 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.17.0 +// protoc v3.6.0 // source: blobber.proto package blobbergrpc diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index ba2de938e..7a8482e7b 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -11,7 +11,6 @@ import ( // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. -// Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 // BlobberClient is the client API for Blobber service. @@ -160,8 +159,8 @@ type UnsafeBlobberServer interface { mustEmbedUnimplementedBlobberServer() } -func RegisterBlobberServer(s grpc.ServiceRegistrar, srv BlobberServer) { - s.RegisterService(&Blobber_ServiceDesc, srv) +func RegisterBlobberServer(s *grpc.Server, srv BlobberServer) { + s.RegisterService(&_Blobber_serviceDesc, srv) } func _Blobber_GetAllocation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { @@ -308,10 +307,7 @@ func _Blobber_UpdateObjectAttributes_Handler(srv interface{}, ctx context.Contex return interceptor(ctx, in, info, handler) } -// Blobber_ServiceDesc is the grpc.ServiceDesc for Blobber service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var Blobber_ServiceDesc = grpc.ServiceDesc{ +var _Blobber_serviceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), Methods: []grpc.MethodDesc{ diff --git a/code/go/0chain.net/blobbercore/handler/zcncore.go b/code/go/0chain.net/blobbercore/handler/zcncore.go index 175889f82..e7f12c061 100644 --- a/code/go/0chain.net/blobbercore/handler/zcncore.go +++ b/code/go/0chain.net/blobbercore/handler/zcncore.go @@ -1,8 +1,8 @@ package handler import ( - "sync" "encoding/json" + "sync" "github.com/0chain/gosdk/core/common" "github.com/0chain/gosdk/zcncore" @@ -12,7 +12,7 @@ type ZCNStatus struct { wg *sync.WaitGroup success bool balance int64 - info string + info string } func (zcn *ZCNStatus) OnBalanceAvailable(status int, value int64, info string) { @@ -61,7 +61,7 @@ func CheckBalance() (float64, error) { wg.Add(1) err := zcncore.GetBalance(statusBar) if err != nil { - return 0, common.NewError("check_balance_failed", "Call to GetBalance failed with err: " + err.Error()) + return 0, common.NewError("check_balance_failed", "Call to GetBalance failed with err: "+err.Error()) } wg.Wait() if !statusBar.success { @@ -81,7 +81,7 @@ func GetBlobbers() ([]*zcncore.Blobber, error) { err := zcncore.GetBlobbers(statusBar) if err != nil { - return info.Nodes, common.NewError("get_blobbers_failed", "Call to GetBlobbers failed with err: " + err.Error()) + return info.Nodes, common.NewError("get_blobbers_failed", "Call to GetBlobbers failed with err: "+err.Error()) } wg.Wait() @@ -90,7 +90,7 @@ func GetBlobbers() ([]*zcncore.Blobber, error) { } if err = json.Unmarshal([]byte(statusBar.info), &info); err != nil { - return info.Nodes, common.NewError("get_blobbers_failed", "Decoding response to GetBlobbers failed with err: " + err.Error()) + return info.Nodes, common.NewError("get_blobbers_failed", "Decoding response to GetBlobbers failed with err: "+err.Error()) } return info.Nodes, nil From 00f16cacfe7fe58b63d3094ce867421fe1d6cd2b Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 22:05:24 +0530 Subject: [PATCH 073/183] proto versions mismatch fixed --- code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 387a2ca99..d02ecad08 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.6.0 +// protoc v3.6.1 // source: blobber.proto package blobbergrpc From d8edc7b22e5e1d4b346b9a3a5a20cc41c080ea2f Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 22:11:12 +0530 Subject: [PATCH 074/183] proto versions mismatch fixed --- .../0chain.net/blobbercore/blobbergrpc/blobber.pb.go | 2 +- .../blobbercore/blobbergrpc/blobber_grpc.pb.go | 10 +++------- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 7b2865d7e..fe828221b 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.17.0 +// protoc v3.6.1 // source: blobber.proto package blobbergrpc diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index ed1da3f3b..b4dabdfc4 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -11,7 +11,6 @@ import ( // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. -// Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 // BlobberClient is the client API for Blobber service. @@ -160,8 +159,8 @@ type UnsafeBlobberServer interface { mustEmbedUnimplementedBlobberServer() } -func RegisterBlobberServer(s grpc.ServiceRegistrar, srv BlobberServer) { - s.RegisterService(&Blobber_ServiceDesc, srv) +func RegisterBlobberServer(s *grpc.Server, srv BlobberServer) { + s.RegisterService(&_Blobber_serviceDesc, srv) } func _Blobber_GetAllocation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { @@ -308,10 +307,7 @@ func _Blobber_CopyObject_Handler(srv interface{}, ctx context.Context, dec func( return interceptor(ctx, in, info, handler) } -// Blobber_ServiceDesc is the grpc.ServiceDesc for Blobber service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var Blobber_ServiceDesc = grpc.ServiceDesc{ +var _Blobber_serviceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), Methods: []grpc.MethodDesc{ From 34ca01792f93ca30edcaf5758d8482823e39834f Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 22:12:22 +0530 Subject: [PATCH 075/183] proto versions mismatch fixed --- .../0chain.net/blobbercore/blobbergrpc/blobber.pb.go | 2 +- .../blobbercore/blobbergrpc/blobber_grpc.pb.go | 10 +++------- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 972d362a3..e6186cb43 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.17.0 +// protoc v3.6.1 // source: blobber.proto package blobbergrpc diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 126b9e98c..3e872cfa7 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -11,7 +11,6 @@ import ( // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. -// Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 // BlobberClient is the client API for Blobber service. @@ -160,8 +159,8 @@ type UnsafeBlobberServer interface { mustEmbedUnimplementedBlobberServer() } -func RegisterBlobberServer(s grpc.ServiceRegistrar, srv BlobberServer) { - s.RegisterService(&Blobber_ServiceDesc, srv) +func RegisterBlobberServer(s *grpc.Server, srv BlobberServer) { + s.RegisterService(&_Blobber_serviceDesc, srv) } func _Blobber_GetAllocation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { @@ -308,10 +307,7 @@ func _Blobber_RenameObject_Handler(srv interface{}, ctx context.Context, dec fun return interceptor(ctx, in, info, handler) } -// Blobber_ServiceDesc is the grpc.ServiceDesc for Blobber service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var Blobber_ServiceDesc = grpc.ServiceDesc{ +var _Blobber_serviceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), Methods: []grpc.MethodDesc{ From dea8a98d5c5124001e3d2858baff4bcd105b1587 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 30 May 2021 22:13:22 +0530 Subject: [PATCH 076/183] proto versions mismatch fixed --- .../0chain.net/blobbercore/blobbergrpc/blobber.pb.go | 2 +- .../blobbercore/blobbergrpc/blobber_grpc.pb.go | 10 +++------- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 47a5f11fb..ef57fb91b 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.17.0 +// protoc v3.6.1 // source: blobber.proto package blobbergrpc diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 79e62293f..84d2b298d 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -11,7 +11,6 @@ import ( // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. -// Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 // BlobberClient is the client API for Blobber service. @@ -160,8 +159,8 @@ type UnsafeBlobberServer interface { mustEmbedUnimplementedBlobberServer() } -func RegisterBlobberServer(s grpc.ServiceRegistrar, srv BlobberServer) { - s.RegisterService(&Blobber_ServiceDesc, srv) +func RegisterBlobberServer(s *grpc.Server, srv BlobberServer) { + s.RegisterService(&_Blobber_serviceDesc, srv) } func _Blobber_GetAllocation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { @@ -308,10 +307,7 @@ func _Blobber_DownloadFile_Handler(srv interface{}, ctx context.Context, dec fun return interceptor(ctx, in, info, handler) } -// Blobber_ServiceDesc is the grpc.ServiceDesc for Blobber service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var Blobber_ServiceDesc = grpc.ServiceDesc{ +var _Blobber_serviceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), Methods: []grpc.MethodDesc{ From a6c4de34325ea7c2aa96751c5ad39098f400b78e Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 31 May 2021 01:30:23 +0530 Subject: [PATCH 077/183] :white_check_mark: add integration tests --- .../handler/grpc_handler_helper_unit_test.go | 16 +++++++++++--- .../handler/grpc_handler_integration_test.go | 21 +++++++++++++++++-- 2 files changed, 32 insertions(+), 5 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 88cf51744..23759ea1b 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -550,7 +550,7 @@ func (c *TestDataController) AddCommitTestData(allocationTx, pubkey, clientId, w _, err = tx.Exec(` INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) -VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/root'); +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); `) if err != nil { return err @@ -566,7 +566,7 @@ VALUES ('connection_id' ,'exampleId','` + clientId + `', 1337, 1); _, err = tx.Exec(` INSERT INTO allocation_changes (id, connection_id, operation, size, input) -VALUES (1 ,'connection_id','rename', 1200, '{"new_name":"new_name"}'); +VALUES (1 ,'connection_id','rename', 1200, '{"allocation_id":"exampleId","path":"/some_file","new_name":"new_name"}'); `) if err != nil { return err @@ -574,7 +574,17 @@ VALUES (1 ,'connection_id','rename', 1200, '{"new_name":"new_name"}'); _, err = tx.Exec(` INSERT INTO write_markers(prev_allocation_root, allocation_root, status, allocation_id, size, client_id, signature, blobber_id, timestamp, connection_id, client_key) -VALUES ('/root', '/root', 2,'exampleId', 1337, '` + clientId + `','` + wmSig + `','blobber_id', ` + fmt.Sprint(now) + `, 'connection_id', '` + pubkey + `'); +VALUES ('/', '/', 2,'exampleId', 1337, '` + clientId + `','` + wmSig + `','blobber_id', ` + fmt.Sprint(now) + `, 'connection_id', '` + pubkey + `'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash, parent_path) +VALUES +(1234,'exampleId','exampleId:examplePath','exampleId:examplePath','d','root','/','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'), +(123,'exampleId','exampleId:examplePath','exampleId:examplePath','f','some_file','/some_file','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'); `) if err != nil { return err diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index efcfd0a71..ad416995c 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -7,9 +7,12 @@ import ( "fmt" "log" "os" + "strconv" "testing" "time" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" "github.com/0chain/blobber/code/go/0chain.net/core/common" @@ -540,9 +543,21 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + fr := reference.Ref{ + AllocationID: "exampleId", + Type: "f", + Name: "new_name", + Path: "/new_name", + ContentHash: "contentHash", + MerkleRoot: "merkleRoot", + ActualFileHash: "actualFileHash", + } + + rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + wm := writemarker.WriteMarker{ - AllocationRoot: "/root", - PreviousAllocationRoot: "/root", + AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + PreviousAllocationRoot: "/", AllocationID: "exampleId", Size: 1337, BlobberID: encryption.Hash(blobberPubKeyBytes), @@ -555,6 +570,8 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { t.Fatal(err) } + wm.Signature = wmSig + wmRaw, err := json.Marshal(wm) if err != nil { t.Fatal(err) From f1e98e317fd3d1f9de0ccba7ddf7f0ed018c593d Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 31 May 2021 01:41:26 +0530 Subject: [PATCH 078/183] :memo: updated the grpc developer docs --- code/go/0chain.net/blobbercore/blobbergrpc/README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/README.md b/code/go/0chain.net/blobbercore/blobbergrpc/README.md index 0e1ac4f0c..2fb21f95c 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/README.md +++ b/code/go/0chain.net/blobbercore/blobbergrpc/README.md @@ -2,6 +2,8 @@ ## Installation +Install the [protoc](https://grpc.io/docs/protoc-installation/) command line interface + ``` go install \ github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-grpc-gateway \ @@ -10,7 +12,9 @@ google.golang.org/protobuf/cmd/protoc-gen-go \ google.golang.org/grpc/cmd/protoc-gen-go-grpc ``` -Run this command to install all the grpc related binaries required to generate files using grpc. +Run this command to install all the GRPC related binaries required to generate GRPC related files using `protoc` CLI. + +Now you can run the script in `scripts/generate-grpc.sh` ## Development From 05c008de51e4d9ba41949d892712bfcf5169ff59 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 31 May 2021 01:44:53 +0530 Subject: [PATCH 079/183] :memo: changed section order in grpc developer docs --- .../0chain.net/blobbercore/blobbergrpc/README.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/README.md b/code/go/0chain.net/blobbercore/blobbergrpc/README.md index 2fb21f95c..bfadcfb93 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/README.md +++ b/code/go/0chain.net/blobbercore/blobbergrpc/README.md @@ -1,5 +1,12 @@ # GRPC Endpoints +## Development + +Modify the '.proto' file in `code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto` and run +`scripts/generate-grpc.sh` to add new api's. + +GRPC API is implemented in `code/go/0chain.net/blobbercore/handler/grpc_handler.go`. + ## Installation Install the [protoc](https://grpc.io/docs/protoc-installation/) command line interface @@ -16,13 +23,6 @@ Run this command to install all the GRPC related binaries required to generate G Now you can run the script in `scripts/generate-grpc.sh` -## Development - -Modify the '.proto' file in `code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto` and run -`scripts/generate-grpc.sh` to add new api's. - -GRPC API is implemented in `code/go/0chain.net/blobbercore/handler/grpc_handler.go`. - ## Plugins * [grpc-gateway](https://github.com/grpc-ecosystem/grpc-gateway) From 401cc9d23872f655f79710f6877e0be754574e04 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 31 May 2021 01:47:41 +0530 Subject: [PATCH 080/183] :memo: added missing punctuation grpc developer docs --- code/go/0chain.net/blobbercore/blobbergrpc/README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/README.md b/code/go/0chain.net/blobbercore/blobbergrpc/README.md index bfadcfb93..d45b4a594 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/README.md +++ b/code/go/0chain.net/blobbercore/blobbergrpc/README.md @@ -9,7 +9,7 @@ GRPC API is implemented in `code/go/0chain.net/blobbercore/handler/grpc_handler. ## Installation -Install the [protoc](https://grpc.io/docs/protoc-installation/) command line interface +Install the [protoc](https://grpc.io/docs/protoc-installation/) command line interface. ``` go install \ @@ -21,7 +21,7 @@ google.golang.org/grpc/cmd/protoc-gen-go-grpc Run this command to install all the GRPC related binaries required to generate GRPC related files using `protoc` CLI. -Now you can run the script in `scripts/generate-grpc.sh` +Now you can run the script in `scripts/generate-grpc.sh`. ## Plugins @@ -39,8 +39,8 @@ You can use https://github.com/vektra/mockery to generate mocks for tests. ## Documentation -Basic documentation can be found here - https://grpc.io/docs/languages/go/basics/ +Basic documentation can be found here - https://grpc.io/docs/languages/go/basics/. -Advanced documentation can be found here - https://github.com/grpc/grpc-go/tree/master/Documentation +Advanced documentation can be found here - https://github.com/grpc/grpc-go/tree/master/Documentation. From 76b7e4a3cd8f0128c6b788a446bd32d176725a2e Mon Sep 17 00:00:00 2001 From: Vivek V Date: Mon, 31 May 2021 13:17:01 +0530 Subject: [PATCH 081/183] :adhesive_bandage: changed .proto file rpc url to v2, and added convert response handler for CalculateHashHandler --- .../blobbercore/blobbergrpc/blobber.pb.go | 2 +- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 2 +- .../blobbergrpc/proto/blobber.proto | 2 +- .../blobbercore/convert/responseHandler.go | 9 ++++ .../0chain.net/blobbercore/handler/handler.go | 2 +- .../blobbercore/openapi/blobber.swagger.json | 44 +++++++++---------- 6 files changed, 35 insertions(+), 26 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 96219b6f2..ddd892bbf 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -2493,7 +2493,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x31, + 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 716d36ce7..76fd1fab6 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -964,7 +964,7 @@ var ( pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) - pattern_Blobber_CalculateHash_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v1", "file", "calculatehash", "allocation"}, "")) + pattern_Blobber_CalculateHash_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "calculatehash", "allocation"}, "")) ) var ( diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 65201c867..43f05511c 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -45,7 +45,7 @@ service Blobber { rpc CalculateHash(CalculateHashRequest) returns (CalculateHashResponse) { option (google.api.http) = { - post: "/v1/file/calculatehash/{allocation}" + post: "/v2/file/calculatehash/{allocation}" body: "*" }; } diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index e16a5177e..a8865695a 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -89,3 +89,12 @@ func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTr LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), } } + +func GetCalculateHashResponseHandler(response *blobbergrpc.CalculateHashResponse) interface{} { + result := make(map[string]interface{}) + if msg := response.GetMessage(); msg != "" { + result["msg"] = msg + } + + return result +} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index e41621130..0ec13faa2 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -343,7 +343,7 @@ func CalculateHashHandler(svc *blobberGRPCService) func(ctx context.Context, r * return nil, err } - return response, nil + return convert.GetCalculateHashResponseHandler(response), nil } } diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 1d37eedb2..ce9db1d00 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -16,14 +16,14 @@ "application/json" ], "paths": { - "/v1/file/calculatehash/{allocation}": { - "post": { - "operationId": "Blobber_CalculateHash", + "/v2/allocation": { + "get": { + "operationId": "Blobber_GetAllocation", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1CalculateHashResponse" + "$ref": "#/definitions/v1GetAllocationResponse" } }, "default": { @@ -35,18 +35,10 @@ }, "parameters": [ { - "name": "allocation", - "in": "path", - "required": true, + "name": "id", + "in": "query", + "required": false, "type": "string" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/v1CalculateHashRequest" - } } ], "tags": [ @@ -54,14 +46,14 @@ ] } }, - "/v2/allocation": { - "get": { - "operationId": "Blobber_GetAllocation", + "/v2/file/calculatehash/{allocation}": { + "post": { + "operationId": "Blobber_CalculateHash", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1GetAllocationResponse" + "$ref": "#/definitions/v1CalculateHashResponse" } }, "default": { @@ -73,10 +65,18 @@ }, "parameters": [ { - "name": "id", - "in": "query", - "required": false, + "name": "allocation", + "in": "path", + "required": true, "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1CalculateHashRequest" + } } ], "tags": [ From 83ab5c9ef703a5ee1d41e8918d1c5675085bd77c Mon Sep 17 00:00:00 2001 From: Vivek V Date: Mon, 31 May 2021 14:34:45 +0530 Subject: [PATCH 082/183] :sparkles: migrated CommitMetaTxnHandler to gRPC --- .../blobbercore/blobbergrpc/blobber.pb.go | 1235 ++++++++++------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 115 ++ .../blobbergrpc/blobber_grpc.pb.go | 36 + .../blobbergrpc/proto/blobber.proto | 21 +- .../blobbercore/convert/responseHandler.go | 15 + .../blobbercore/handler/grpc_handler.go | 59 + .../0chain.net/blobbercore/handler/handler.go | 24 +- .../blobbercore/openapi/blobber.swagger.json | 66 + 8 files changed, 1033 insertions(+), 538 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 2d21e6a7b..194d32fea 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -21,6 +21,132 @@ const ( _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) +type CommitMetaTxnRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + AuthToken string `protobuf:"bytes,3,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` + Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` + TxnId string `protobuf:"bytes,5,opt,name=txn_id,json=txnId,proto3" json:"txn_id,omitempty"` +} + +func (x *CommitMetaTxnRequest) Reset() { + *x = CommitMetaTxnRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitMetaTxnRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitMetaTxnRequest) ProtoMessage() {} + +func (x *CommitMetaTxnRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_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 CommitMetaTxnRequest.ProtoReflect.Descriptor instead. +func (*CommitMetaTxnRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{0} +} + +func (x *CommitMetaTxnRequest) GetPath() string { + if x != nil { + return x.Path + } + return "" +} + +func (x *CommitMetaTxnRequest) GetPathHash() string { + if x != nil { + return x.PathHash + } + return "" +} + +func (x *CommitMetaTxnRequest) GetAuthToken() string { + if x != nil { + return x.AuthToken + } + return "" +} + +func (x *CommitMetaTxnRequest) GetAllocation() string { + if x != nil { + return x.Allocation + } + return "" +} + +func (x *CommitMetaTxnRequest) GetTxnId() string { + if x != nil { + return x.TxnId + } + return "" +} + +type CommitMetaTxnResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` +} + +func (x *CommitMetaTxnResponse) Reset() { + *x = CommitMetaTxnResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitMetaTxnResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitMetaTxnResponse) ProtoMessage() {} + +func (x *CommitMetaTxnResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[1] + 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 CommitMetaTxnResponse.ProtoReflect.Descriptor instead. +func (*CommitMetaTxnResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{1} +} + +func (x *CommitMetaTxnResponse) GetMessage() string { + if x != nil { + return x.Message + } + return "" +} + type GetObjectTreeRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -33,7 +159,7 @@ type GetObjectTreeRequest struct { func (x *GetObjectTreeRequest) Reset() { *x = GetObjectTreeRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[0] + mi := &file_blobber_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -46,7 +172,7 @@ func (x *GetObjectTreeRequest) String() string { func (*GetObjectTreeRequest) ProtoMessage() {} func (x *GetObjectTreeRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[0] + mi := &file_blobber_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -59,7 +185,7 @@ func (x *GetObjectTreeRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectTreeRequest.ProtoReflect.Descriptor instead. func (*GetObjectTreeRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{0} + return file_blobber_proto_rawDescGZIP(), []int{2} } func (x *GetObjectTreeRequest) GetPath() string { @@ -88,7 +214,7 @@ type GetObjectTreeResponse struct { func (x *GetObjectTreeResponse) Reset() { *x = GetObjectTreeResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[1] + mi := &file_blobber_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -101,7 +227,7 @@ func (x *GetObjectTreeResponse) String() string { func (*GetObjectTreeResponse) ProtoMessage() {} func (x *GetObjectTreeResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[1] + mi := &file_blobber_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -114,7 +240,7 @@ func (x *GetObjectTreeResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectTreeResponse.ProtoReflect.Descriptor instead. func (*GetObjectTreeResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{1} + return file_blobber_proto_rawDescGZIP(), []int{3} } func (x *GetObjectTreeResponse) GetReferencePath() *ReferencePath { @@ -144,7 +270,7 @@ type GetReferencePathRequest struct { func (x *GetReferencePathRequest) Reset() { *x = GetReferencePathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[2] + mi := &file_blobber_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -157,7 +283,7 @@ func (x *GetReferencePathRequest) String() string { func (*GetReferencePathRequest) ProtoMessage() {} func (x *GetReferencePathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[2] + mi := &file_blobber_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -170,7 +296,7 @@ func (x *GetReferencePathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReferencePathRequest.ProtoReflect.Descriptor instead. func (*GetReferencePathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{2} + return file_blobber_proto_rawDescGZIP(), []int{4} } func (x *GetReferencePathRequest) GetPaths() string { @@ -206,7 +332,7 @@ type GetReferencePathResponse struct { func (x *GetReferencePathResponse) Reset() { *x = GetReferencePathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[3] + mi := &file_blobber_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -219,7 +345,7 @@ func (x *GetReferencePathResponse) String() string { func (*GetReferencePathResponse) ProtoMessage() {} func (x *GetReferencePathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[3] + mi := &file_blobber_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -232,7 +358,7 @@ func (x *GetReferencePathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReferencePathResponse.ProtoReflect.Descriptor instead. func (*GetReferencePathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{3} + return file_blobber_proto_rawDescGZIP(), []int{5} } func (x *GetReferencePathResponse) GetReferencePath() *ReferencePath { @@ -261,7 +387,7 @@ type ReferencePath struct { func (x *ReferencePath) Reset() { *x = ReferencePath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -274,7 +400,7 @@ func (x *ReferencePath) String() string { func (*ReferencePath) ProtoMessage() {} func (x *ReferencePath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -287,7 +413,7 @@ func (x *ReferencePath) ProtoReflect() protoreflect.Message { // Deprecated: Use ReferencePath.ProtoReflect.Descriptor instead. func (*ReferencePath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{4} + return file_blobber_proto_rawDescGZIP(), []int{6} } func (x *ReferencePath) GetMetaData() *FileRef { @@ -317,7 +443,7 @@ type GetObjectPathRequest struct { func (x *GetObjectPathRequest) Reset() { *x = GetObjectPathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -330,7 +456,7 @@ func (x *GetObjectPathRequest) String() string { func (*GetObjectPathRequest) ProtoMessage() {} func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -343,7 +469,7 @@ func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathRequest.ProtoReflect.Descriptor instead. func (*GetObjectPathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{5} + return file_blobber_proto_rawDescGZIP(), []int{7} } func (x *GetObjectPathRequest) GetAllocation() string { @@ -379,7 +505,7 @@ type GetObjectPathResponse struct { func (x *GetObjectPathResponse) Reset() { *x = GetObjectPathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -392,7 +518,7 @@ func (x *GetObjectPathResponse) String() string { func (*GetObjectPathResponse) ProtoMessage() {} func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -405,7 +531,7 @@ func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathResponse.ProtoReflect.Descriptor instead. func (*GetObjectPathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{6} + return file_blobber_proto_rawDescGZIP(), []int{8} } func (x *GetObjectPathResponse) GetObjectPath() *ObjectPath { @@ -437,7 +563,7 @@ type ObjectPath struct { func (x *ObjectPath) Reset() { *x = ObjectPath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -450,7 +576,7 @@ func (x *ObjectPath) String() string { func (*ObjectPath) ProtoMessage() {} func (x *ObjectPath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -463,7 +589,7 @@ func (x *ObjectPath) ProtoReflect() protoreflect.Message { // Deprecated: Use ObjectPath.ProtoReflect.Descriptor instead. func (*ObjectPath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{7} + return file_blobber_proto_rawDescGZIP(), []int{9} } func (x *ObjectPath) GetRootHash() string { @@ -519,7 +645,7 @@ type WriteMarker struct { func (x *WriteMarker) Reset() { *x = WriteMarker{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -532,7 +658,7 @@ func (x *WriteMarker) String() string { func (*WriteMarker) ProtoMessage() {} func (x *WriteMarker) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -545,7 +671,7 @@ func (x *WriteMarker) ProtoReflect() protoreflect.Message { // Deprecated: Use WriteMarker.ProtoReflect.Descriptor instead. func (*WriteMarker) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{8} + return file_blobber_proto_rawDescGZIP(), []int{10} } func (x *WriteMarker) GetAllocationRoot() string { @@ -618,7 +744,7 @@ type ListEntitiesRequest struct { func (x *ListEntitiesRequest) Reset() { *x = ListEntitiesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -631,7 +757,7 @@ func (x *ListEntitiesRequest) String() string { func (*ListEntitiesRequest) ProtoMessage() {} func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -644,7 +770,7 @@ func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ListEntitiesRequest.ProtoReflect.Descriptor instead. func (*ListEntitiesRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{9} + return file_blobber_proto_rawDescGZIP(), []int{11} } func (x *ListEntitiesRequest) GetPath() string { @@ -688,7 +814,7 @@ type ListEntitiesResponse struct { func (x *ListEntitiesResponse) Reset() { *x = ListEntitiesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[10] + mi := &file_blobber_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -701,7 +827,7 @@ func (x *ListEntitiesResponse) String() string { func (*ListEntitiesResponse) ProtoMessage() {} func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[10] + mi := &file_blobber_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -714,7 +840,7 @@ func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ListEntitiesResponse.ProtoReflect.Descriptor instead. func (*ListEntitiesResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{10} + return file_blobber_proto_rawDescGZIP(), []int{12} } func (x *ListEntitiesResponse) GetAllocationRoot() string { @@ -751,7 +877,7 @@ type GetFileStatsRequest struct { func (x *GetFileStatsRequest) Reset() { *x = GetFileStatsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -764,7 +890,7 @@ func (x *GetFileStatsRequest) String() string { func (*GetFileStatsRequest) ProtoMessage() {} func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -777,7 +903,7 @@ func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileStatsRequest.ProtoReflect.Descriptor instead. func (*GetFileStatsRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{11} + return file_blobber_proto_rawDescGZIP(), []int{13} } func (x *GetFileStatsRequest) GetPath() string { @@ -813,7 +939,7 @@ type GetFileStatsResponse struct { func (x *GetFileStatsResponse) Reset() { *x = GetFileStatsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -826,7 +952,7 @@ func (x *GetFileStatsResponse) String() string { func (*GetFileStatsResponse) ProtoMessage() {} func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -839,7 +965,7 @@ func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileStatsResponse.ProtoReflect.Descriptor instead. func (*GetFileStatsResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{12} + return file_blobber_proto_rawDescGZIP(), []int{14} } func (x *GetFileStatsResponse) GetMetaData() *FileRef { @@ -876,7 +1002,7 @@ type FileStats struct { func (x *FileStats) Reset() { *x = FileStats{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -889,7 +1015,7 @@ func (x *FileStats) String() string { func (*FileStats) ProtoMessage() {} func (x *FileStats) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -902,7 +1028,7 @@ func (x *FileStats) ProtoReflect() protoreflect.Message { // Deprecated: Use FileStats.ProtoReflect.Descriptor instead. func (*FileStats) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{13} + return file_blobber_proto_rawDescGZIP(), []int{15} } func (x *FileStats) GetID() int64 { @@ -989,7 +1115,7 @@ type GetFileMetaDataRequest struct { func (x *GetFileMetaDataRequest) Reset() { *x = GetFileMetaDataRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[14] + mi := &file_blobber_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1002,7 +1128,7 @@ func (x *GetFileMetaDataRequest) String() string { func (*GetFileMetaDataRequest) ProtoMessage() {} func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[14] + mi := &file_blobber_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1015,7 +1141,7 @@ func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileMetaDataRequest.ProtoReflect.Descriptor instead. func (*GetFileMetaDataRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{14} + return file_blobber_proto_rawDescGZIP(), []int{16} } func (x *GetFileMetaDataRequest) GetPath() string { @@ -1058,7 +1184,7 @@ type GetFileMetaDataResponse struct { func (x *GetFileMetaDataResponse) Reset() { *x = GetFileMetaDataResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[15] + mi := &file_blobber_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1071,7 +1197,7 @@ func (x *GetFileMetaDataResponse) String() string { func (*GetFileMetaDataResponse) ProtoMessage() {} func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[15] + mi := &file_blobber_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1084,7 +1210,7 @@ func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileMetaDataResponse.ProtoReflect.Descriptor instead. func (*GetFileMetaDataResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{15} + return file_blobber_proto_rawDescGZIP(), []int{17} } func (x *GetFileMetaDataResponse) GetMetaData() *FileRef { @@ -1114,7 +1240,7 @@ type CommitMetaTxn struct { func (x *CommitMetaTxn) Reset() { *x = CommitMetaTxn{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[16] + mi := &file_blobber_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1127,7 +1253,7 @@ func (x *CommitMetaTxn) String() string { func (*CommitMetaTxn) ProtoMessage() {} func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[16] + mi := &file_blobber_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1140,7 +1266,7 @@ func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { // Deprecated: Use CommitMetaTxn.ProtoReflect.Descriptor instead. func (*CommitMetaTxn) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{16} + return file_blobber_proto_rawDescGZIP(), []int{18} } func (x *CommitMetaTxn) GetRefId() int64 { @@ -1177,7 +1303,7 @@ type Collaborator struct { func (x *Collaborator) Reset() { *x = Collaborator{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[17] + mi := &file_blobber_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1190,7 +1316,7 @@ func (x *Collaborator) String() string { func (*Collaborator) ProtoMessage() {} func (x *Collaborator) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[17] + mi := &file_blobber_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1203,7 +1329,7 @@ func (x *Collaborator) ProtoReflect() protoreflect.Message { // Deprecated: Use Collaborator.ProtoReflect.Descriptor instead. func (*Collaborator) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{17} + return file_blobber_proto_rawDescGZIP(), []int{19} } func (x *Collaborator) GetRefId() int64 { @@ -1238,7 +1364,7 @@ type GetAllocationRequest struct { func (x *GetAllocationRequest) Reset() { *x = GetAllocationRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[18] + mi := &file_blobber_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1251,7 +1377,7 @@ func (x *GetAllocationRequest) String() string { func (*GetAllocationRequest) ProtoMessage() {} func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[18] + mi := &file_blobber_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1264,7 +1390,7 @@ func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationRequest.ProtoReflect.Descriptor instead. func (*GetAllocationRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{18} + return file_blobber_proto_rawDescGZIP(), []int{20} } func (x *GetAllocationRequest) GetId() string { @@ -1285,7 +1411,7 @@ type GetAllocationResponse struct { func (x *GetAllocationResponse) Reset() { *x = GetAllocationResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1298,7 +1424,7 @@ func (x *GetAllocationResponse) String() string { func (*GetAllocationResponse) ProtoMessage() {} func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1311,7 +1437,7 @@ func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationResponse.ProtoReflect.Descriptor instead. func (*GetAllocationResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{19} + return file_blobber_proto_rawDescGZIP(), []int{21} } func (x *GetAllocationResponse) GetAllocation() *Allocation { @@ -1348,7 +1474,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1361,7 +1487,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1374,7 +1500,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{22} } func (x *Allocation) GetID() string { @@ -1511,7 +1637,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1524,7 +1650,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1537,7 +1663,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{23} } func (x *Term) GetID() int64 { @@ -1588,7 +1714,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1601,7 +1727,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1614,7 +1740,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{24} } func (x *FileRef) GetType() string { @@ -1672,7 +1798,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1685,7 +1811,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1698,7 +1824,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{23} + return file_blobber_proto_rawDescGZIP(), []int{25} } func (x *FileMetaData) GetType() string { @@ -1889,7 +2015,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1902,7 +2028,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1915,7 +2041,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{24} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *DirMetaData) GetType() string { @@ -1995,382 +2121,405 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x22, 0x4a, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, - 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, - 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, - 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, - 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, - 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, - 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, - 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, - 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, - 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, - 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, - 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, + 0x6f, 0x22, 0x9d, 0x01, 0x0a, 0x14, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, + 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, + 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, + 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x15, 0x0a, 0x06, 0x74, 0x78, + 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x78, 0x6e, 0x49, + 0x64, 0x22, 0x31, 0x0a, 0x15, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, + 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, + 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, + 0x73, 0x61, 0x67, 0x65, 0x22, 0x4a, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, + 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, + 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, + 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, + 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, + 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, + 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, + 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, + 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, - 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, - 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, - 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, - 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, - 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, + 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, + 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, + 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, + 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, + 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, + 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, + 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, + 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, + 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, + 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, + 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, + 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, + 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, + 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, + 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, + 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, + 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, + 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, + 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, + 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, + 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, + 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, + 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, + 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, + 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, + 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, + 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, + 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, + 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, + 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, + 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, + 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, + 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, + 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, - 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, - 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, - 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, - 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, - 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, - 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, - 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, - 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, - 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, - 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, - 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, - 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, - 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, - 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, - 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, - 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, - 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, - 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, - 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, + 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, + 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, + 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, + 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, + 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, + 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, + 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, + 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, + 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, + 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, + 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, + 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, + 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, + 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, + 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, + 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, + 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, + 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, - 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, - 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, - 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, - 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, - 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, - 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, - 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, - 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, - 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, - 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, - 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, - 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, - 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, - 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, - 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, - 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, - 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, - 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, - 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, - 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, - 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, - 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, - 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, - 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, - 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, - 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, - 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, - 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, - 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, - 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, - 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, - 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, - 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, - 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, - 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, - 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, - 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, - 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, - 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, + 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, + 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, + 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, + 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, + 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, + 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, + 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, + 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, + 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, + 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, + 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, + 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, + 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, + 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, + 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, + 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, + 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, + 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, + 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, + 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, + 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, + 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, + 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, + 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, + 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, + 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, + 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, + 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, + 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, + 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, + 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, + 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, + 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, + 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, + 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, + 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, + 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, + 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, + 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, + 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, + 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, + 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, + 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, + 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, + 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, + 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, + 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, + 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, + 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, + 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, + 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, + 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, + 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, + 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, + 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, + 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, + 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, + 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, + 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, + 0xff, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, + 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, - 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xe8, 0x07, 0x0a, - 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, - 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, - 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, - 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, + 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, + 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, + 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, + 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, + 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, + 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, + 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, + 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, - 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, + 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, + 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, + 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, + 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2385,73 +2534,77 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 25) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 27) var file_blobber_proto_goTypes = []interface{}{ - (*GetObjectTreeRequest)(nil), // 0: blobber.service.v1.GetObjectTreeRequest - (*GetObjectTreeResponse)(nil), // 1: blobber.service.v1.GetObjectTreeResponse - (*GetReferencePathRequest)(nil), // 2: blobber.service.v1.GetReferencePathRequest - (*GetReferencePathResponse)(nil), // 3: blobber.service.v1.GetReferencePathResponse - (*ReferencePath)(nil), // 4: blobber.service.v1.ReferencePath - (*GetObjectPathRequest)(nil), // 5: blobber.service.v1.GetObjectPathRequest - (*GetObjectPathResponse)(nil), // 6: blobber.service.v1.GetObjectPathResponse - (*ObjectPath)(nil), // 7: blobber.service.v1.ObjectPath - (*WriteMarker)(nil), // 8: blobber.service.v1.WriteMarker - (*ListEntitiesRequest)(nil), // 9: blobber.service.v1.ListEntitiesRequest - (*ListEntitiesResponse)(nil), // 10: blobber.service.v1.ListEntitiesResponse - (*GetFileStatsRequest)(nil), // 11: blobber.service.v1.GetFileStatsRequest - (*GetFileStatsResponse)(nil), // 12: blobber.service.v1.GetFileStatsResponse - (*FileStats)(nil), // 13: blobber.service.v1.FileStats - (*GetFileMetaDataRequest)(nil), // 14: blobber.service.v1.GetFileMetaDataRequest - (*GetFileMetaDataResponse)(nil), // 15: blobber.service.v1.GetFileMetaDataResponse - (*CommitMetaTxn)(nil), // 16: blobber.service.v1.CommitMetaTxn - (*Collaborator)(nil), // 17: blobber.service.v1.Collaborator - (*GetAllocationRequest)(nil), // 18: blobber.service.v1.GetAllocationRequest - (*GetAllocationResponse)(nil), // 19: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 20: blobber.service.v1.Allocation - (*Term)(nil), // 21: blobber.service.v1.Term - (*FileRef)(nil), // 22: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 23: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 24: blobber.service.v1.DirMetaData + (*CommitMetaTxnRequest)(nil), // 0: blobber.service.v1.CommitMetaTxnRequest + (*CommitMetaTxnResponse)(nil), // 1: blobber.service.v1.CommitMetaTxnResponse + (*GetObjectTreeRequest)(nil), // 2: blobber.service.v1.GetObjectTreeRequest + (*GetObjectTreeResponse)(nil), // 3: blobber.service.v1.GetObjectTreeResponse + (*GetReferencePathRequest)(nil), // 4: blobber.service.v1.GetReferencePathRequest + (*GetReferencePathResponse)(nil), // 5: blobber.service.v1.GetReferencePathResponse + (*ReferencePath)(nil), // 6: blobber.service.v1.ReferencePath + (*GetObjectPathRequest)(nil), // 7: blobber.service.v1.GetObjectPathRequest + (*GetObjectPathResponse)(nil), // 8: blobber.service.v1.GetObjectPathResponse + (*ObjectPath)(nil), // 9: blobber.service.v1.ObjectPath + (*WriteMarker)(nil), // 10: blobber.service.v1.WriteMarker + (*ListEntitiesRequest)(nil), // 11: blobber.service.v1.ListEntitiesRequest + (*ListEntitiesResponse)(nil), // 12: blobber.service.v1.ListEntitiesResponse + (*GetFileStatsRequest)(nil), // 13: blobber.service.v1.GetFileStatsRequest + (*GetFileStatsResponse)(nil), // 14: blobber.service.v1.GetFileStatsResponse + (*FileStats)(nil), // 15: blobber.service.v1.FileStats + (*GetFileMetaDataRequest)(nil), // 16: blobber.service.v1.GetFileMetaDataRequest + (*GetFileMetaDataResponse)(nil), // 17: blobber.service.v1.GetFileMetaDataResponse + (*CommitMetaTxn)(nil), // 18: blobber.service.v1.CommitMetaTxn + (*Collaborator)(nil), // 19: blobber.service.v1.Collaborator + (*GetAllocationRequest)(nil), // 20: blobber.service.v1.GetAllocationRequest + (*GetAllocationResponse)(nil), // 21: blobber.service.v1.GetAllocationResponse + (*Allocation)(nil), // 22: blobber.service.v1.Allocation + (*Term)(nil), // 23: blobber.service.v1.Term + (*FileRef)(nil), // 24: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 25: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 26: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ - 4, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 8, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 4, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 8, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 22, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef - 4, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath - 7, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath - 8, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 22, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 22, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 22, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 22, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 22, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 22, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef - 13, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 22, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef - 17, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 20, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 21, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 23, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 24, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 16, // 21: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 18, // 22: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 14, // 23: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 11, // 24: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 9, // 25: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 5, // 26: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest - 2, // 27: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest - 0, // 28: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 19, // 29: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 15, // 30: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 12, // 31: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 10, // 32: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 6, // 33: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 3, // 34: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 1, // 35: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 29, // [29:36] is the sub-list for method output_type - 22, // [22:29] is the sub-list for method input_type + 6, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 10, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 6, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 10, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 24, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 6, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath + 9, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath + 10, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker + 24, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 24, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 24, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 24, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 24, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 24, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 15, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats + 24, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 19, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 22, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 23, // 18: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 25, // 19: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 26, // 20: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 18, // 21: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 20, // 22: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 16, // 23: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 13, // 24: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 11, // 25: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 7, // 26: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 4, // 27: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest + 2, // 28: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest + 0, // 29: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest + 21, // 30: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 17, // 31: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 14, // 32: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 12, // 33: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 8, // 34: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 5, // 35: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 3, // 36: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 1, // 37: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 30, // [30:38] is the sub-list for method output_type + 22, // [22:30] is the sub-list for method input_type 22, // [22:22] is the sub-list for extension type_name 22, // [22:22] is the sub-list for extension extendee 0, // [0:22] is the sub-list for field type_name @@ -2464,7 +2617,7 @@ func file_blobber_proto_init() { } if !protoimpl.UnsafeEnabled { file_blobber_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectTreeRequest); i { + switch v := v.(*CommitMetaTxnRequest); i { case 0: return &v.state case 1: @@ -2476,7 +2629,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectTreeResponse); i { + switch v := v.(*CommitMetaTxnResponse); i { case 0: return &v.state case 1: @@ -2488,7 +2641,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetReferencePathRequest); i { + switch v := v.(*GetObjectTreeRequest); i { case 0: return &v.state case 1: @@ -2500,7 +2653,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetReferencePathResponse); i { + switch v := v.(*GetObjectTreeResponse); i { case 0: return &v.state case 1: @@ -2512,7 +2665,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReferencePath); i { + switch v := v.(*GetReferencePathRequest); i { case 0: return &v.state case 1: @@ -2524,7 +2677,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathRequest); i { + switch v := v.(*GetReferencePathResponse); i { case 0: return &v.state case 1: @@ -2536,7 +2689,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathResponse); i { + switch v := v.(*ReferencePath); i { case 0: return &v.state case 1: @@ -2548,7 +2701,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ObjectPath); i { + switch v := v.(*GetObjectPathRequest); i { case 0: return &v.state case 1: @@ -2560,7 +2713,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*WriteMarker); i { + switch v := v.(*GetObjectPathResponse); i { case 0: return &v.state case 1: @@ -2572,7 +2725,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesRequest); i { + switch v := v.(*ObjectPath); i { case 0: return &v.state case 1: @@ -2584,7 +2737,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesResponse); i { + switch v := v.(*WriteMarker); i { case 0: return &v.state case 1: @@ -2596,7 +2749,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsRequest); i { + switch v := v.(*ListEntitiesRequest); i { case 0: return &v.state case 1: @@ -2608,7 +2761,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsResponse); i { + switch v := v.(*ListEntitiesResponse); i { case 0: return &v.state case 1: @@ -2620,7 +2773,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileStats); i { + switch v := v.(*GetFileStatsRequest); i { case 0: return &v.state case 1: @@ -2632,7 +2785,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataRequest); i { + switch v := v.(*GetFileStatsResponse); i { case 0: return &v.state case 1: @@ -2644,7 +2797,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataResponse); i { + switch v := v.(*FileStats); i { case 0: return &v.state case 1: @@ -2656,7 +2809,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CommitMetaTxn); i { + switch v := v.(*GetFileMetaDataRequest); i { case 0: return &v.state case 1: @@ -2668,7 +2821,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Collaborator); i { + switch v := v.(*GetFileMetaDataResponse); i { case 0: return &v.state case 1: @@ -2680,7 +2833,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationRequest); i { + switch v := v.(*CommitMetaTxn); i { case 0: return &v.state case 1: @@ -2692,7 +2845,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationResponse); i { + switch v := v.(*Collaborator); i { case 0: return &v.state case 1: @@ -2704,7 +2857,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*GetAllocationRequest); i { case 0: return &v.state case 1: @@ -2716,7 +2869,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*GetAllocationResponse); i { case 0: return &v.state case 1: @@ -2728,7 +2881,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -2740,7 +2893,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -2752,6 +2905,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -2770,7 +2947,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 25, + NumMessages: 27, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 50dc6d47f..14f30f9ba 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -487,6 +487,74 @@ func local_request_Blobber_GetObjectTree_0(ctx context.Context, marshaler runtim } +func request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitMetaTxnRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := client.CommitMetaTxn(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitMetaTxnRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := server.CommitMetaTxn(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterBlobberHandlerServer registers the http handlers for service Blobber to "mux". // UnaryRPC :call BlobberServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -654,6 +722,29 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) + mux.Handle("POST", pattern_Blobber_CommitMetaTxn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CommitMetaTxn") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_CommitMetaTxn_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_CommitMetaTxn_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -835,6 +926,26 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) + mux.Handle("POST", pattern_Blobber_CommitMetaTxn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CommitMetaTxn") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_CommitMetaTxn_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_CommitMetaTxn_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -852,6 +963,8 @@ var ( pattern_Blobber_GetReferencePath_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "referencepath", "allocation"}, "")) pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) + + pattern_Blobber_CommitMetaTxn_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "commitmetatxn", "allocation"}, "")) ) var ( @@ -868,4 +981,6 @@ var ( forward_Blobber_GetReferencePath_0 = runtime.ForwardResponseMessage forward_Blobber_GetObjectTree_0 = runtime.ForwardResponseMessage + + forward_Blobber_CommitMetaTxn_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index e73fdcaf5..1c7032c06 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -24,6 +24,7 @@ type BlobberClient interface { GetObjectPath(ctx context.Context, in *GetObjectPathRequest, opts ...grpc.CallOption) (*GetObjectPathResponse, error) GetReferencePath(ctx context.Context, in *GetReferencePathRequest, opts ...grpc.CallOption) (*GetReferencePathResponse, error) GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) + CommitMetaTxn(ctx context.Context, in *CommitMetaTxnRequest, opts ...grpc.CallOption) (*CommitMetaTxnResponse, error) } type blobberClient struct { @@ -97,6 +98,15 @@ func (c *blobberClient) GetObjectTree(ctx context.Context, in *GetObjectTreeRequ return out, nil } +func (c *blobberClient) CommitMetaTxn(ctx context.Context, in *CommitMetaTxnRequest, opts ...grpc.CallOption) (*CommitMetaTxnResponse, error) { + out := new(CommitMetaTxnResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/CommitMetaTxn", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -108,6 +118,7 @@ type BlobberServer interface { GetObjectPath(context.Context, *GetObjectPathRequest) (*GetObjectPathResponse, error) GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) + CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -136,6 +147,9 @@ func (UnimplementedBlobberServer) GetReferencePath(context.Context, *GetReferenc func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetObjectTree not implemented") } +func (UnimplementedBlobberServer) CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CommitMetaTxn not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -275,6 +289,24 @@ func _Blobber_GetObjectTree_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } +func _Blobber_CommitMetaTxn_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CommitMetaTxnRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).CommitMetaTxn(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/CommitMetaTxn", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).CommitMetaTxn(ctx, req.(*CommitMetaTxnRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Blobber_serviceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), @@ -307,6 +339,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "GetObjectTree", Handler: _Blobber_GetObjectTree_Handler, }, + { + MethodName: "CommitMetaTxn", + Handler: _Blobber_CommitMetaTxn_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index e02cfbd76..f0be9fd5b 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -42,7 +42,26 @@ service Blobber { get: "/v2/file/objecttree/{allocation}" }; } -} + + rpc CommitMetaTxn(CommitMetaTxnRequest) returns (CommitMetaTxnResponse) { + option (google.api.http) = { + post: "/v2/file/commitmetatxn/{allocation}" + body: "*" + }; + } + } + + message CommitMetaTxnRequest { + string path = 1; + string path_hash = 2; + string auth_token = 3; + string allocation = 4; + string txn_id = 5; + } + + message CommitMetaTxnResponse { + string message = 1; + } message GetObjectTreeRequest { string path = 1; diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index e16a5177e..0caae1993 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -89,3 +89,18 @@ func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTr LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), } } + +func GetCommitMetaTxnHandlerResponse(response *blobbergrpc.CommitMetaTxnResponse) interface{} { + msg := response.GetMessage() + if msg == "" { + return nil + } + + result := struct { + Msg string `json:"msg"` + }{ + Msg: msg, + } + + return result +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 9efb8ad08..86d77c8f5 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -446,3 +446,62 @@ func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc } return &refPathResult, nil } + +func (b *blobberGRPCService) CommitMetaTxn(ctx context.Context, req *blobbergrpc.CommitMetaTxnRequest) (*blobbergrpc.CommitMetaTxnResponse, error) { + allocationTx := req.GetAllocation() + allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, true) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) + } + allocationID := allocationObj.ID + + md := GetGRPCMetaDataFromCtx(ctx) + clientID := md.Client + if len(clientID) == 0 { + return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + + pathHash := req.PathHash + path := req.Path + if len(pathHash) == 0 { + if len(path) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid path") + } + pathHash = reference.GetReferenceLookup(allocationID, path) + } + + fileRef, err := b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, pathHash) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid file path. "+err.Error()) + } + + if fileRef.Type != reference.FILE { + return nil, common.NewError("invalid_parameters", "Path is not a file.") + } + + auhToken := req.GetAuthToken() + + if clientID != allocationObj.OwnerID || len(auhToken) > 0 { + authTicketVerified, err := b.storageHandler.verifyAuthTicket(ctx, auhToken, allocationObj, fileRef, clientID) + if err != nil { + return nil, err + } + + if !authTicketVerified { + return nil, common.NewError("auth_ticket_verification_failed", "Could not verify the auth ticket.") + } + } + + txnID := req.GetTxnId() + if len(txnID) == 0 { + return nil, common.NewError("invalid_parameter", "TxnID not present in the params") + } + + if err := reference.AddCommitMetaTxn(ctx, fileRef.ID, txnID); err != nil { + return nil, common.NewError("add_commit_meta_txn_failed", "Failed to add commitMetaTxn with err :"+err.Error()) + } + + return &blobbergrpc.CommitMetaTxnResponse{ + Message: "Added commitMetaTxn successfully", + }, nil +} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 5d001aafc..a3a63d238 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -44,7 +44,7 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler)))) - r.HandleFunc("/v1/file/commitmetatxn/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitMetaTxnHandler)))) + r.HandleFunc("/v1/file/commitmetatxn/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitMetaTxnHandler(svc))))).Methods(http.MethodGet) r.HandleFunc("/v1/file/collaborator/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CollaboratorHandler)))) r.HandleFunc("/v1/file/calculatehash/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CalculateHashHandler)))) @@ -161,15 +161,23 @@ func FileMetaHandler(svc *blobberGRPCService) func(ctx context.Context, r *http. } } -func CommitMetaTxnHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) +func CommitMetaTxnHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerGRPCContext(ctx, r) - response, err := storageHandler.AddCommitMetaTxn(ctx, r) - if err != nil { - return nil, err - } + response, err := svc.CommitMetaTxn(ctx, &blobbergrpc.CommitMetaTxnRequest{ + Path: r.FormValue("path"), + PathHash: r.FormValue("path_hash"), + AuthToken: r.FormValue("auth_token"), + Allocation: mux.Vars(r)["allocation"], + TxnId: r.FormValue("txn_id"), + }) + if err != nil { + return nil, err + } - return response, nil + return convert.GetCommitMetaTxnHandlerResponse(response), nil + } } func CollaboratorHandler(ctx context.Context, r *http.Request) (interface{}, error) { diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index bb3789a42..d5f39dc37 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -46,6 +46,44 @@ ] } }, + "/v2/file/commitmetatxn/{allocation}": { + "post": { + "operationId": "Blobber_CommitMetaTxn", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1CommitMetaTxnResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1CommitMetaTxnRequest" + } + } + ], + "tags": [ + "Blobber" + ] + } + }, "/v2/file/list/{allocation}": { "get": { "operationId": "Blobber_ListEntities", @@ -433,6 +471,34 @@ } } }, + "v1CommitMetaTxnRequest": { + "type": "object", + "properties": { + "path": { + "type": "string" + }, + "pathHash": { + "type": "string" + }, + "authToken": { + "type": "string" + }, + "allocation": { + "type": "string" + }, + "txnId": { + "type": "string" + } + } + }, + "v1CommitMetaTxnResponse": { + "type": "object", + "properties": { + "message": { + "type": "string" + } + } + }, "v1DirMetaData": { "type": "object", "properties": { From 95a906cfb7807a514b043e31bc419eb8aa981461 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 31 May 2021 18:54:45 +0530 Subject: [PATCH 083/183] missing changes from previous commit --- .../blobbercore/blobbergrpc/blobber.pb.go | 1290 +++++++++-------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 115 ++ .../blobbergrpc/blobber_grpc.pb.go | 36 + .../blobbercore/openapi/blobber.swagger.json | 60 + 4 files changed, 934 insertions(+), 567 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 476bb94ec..f498951e6 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -21,6 +21,116 @@ const ( _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) +type CalculateHashRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` + Paths string `protobuf:"bytes,3,opt,name=paths,proto3" json:"paths,omitempty"` +} + +func (x *CalculateHashRequest) Reset() { + *x = CalculateHashRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CalculateHashRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CalculateHashRequest) ProtoMessage() {} + +func (x *CalculateHashRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_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 CalculateHashRequest.ProtoReflect.Descriptor instead. +func (*CalculateHashRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{0} +} + +func (x *CalculateHashRequest) GetAllocation() string { + if x != nil { + return x.Allocation + } + return "" +} + +func (x *CalculateHashRequest) GetPath() string { + if x != nil { + return x.Path + } + return "" +} + +func (x *CalculateHashRequest) GetPaths() string { + if x != nil { + return x.Paths + } + return "" +} + +type CalculateHashResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` +} + +func (x *CalculateHashResponse) Reset() { + *x = CalculateHashResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CalculateHashResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CalculateHashResponse) ProtoMessage() {} + +func (x *CalculateHashResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[1] + 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 CalculateHashResponse.ProtoReflect.Descriptor instead. +func (*CalculateHashResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{1} +} + +func (x *CalculateHashResponse) GetMessage() string { + if x != nil { + return x.Message + } + return "" +} + type CommitRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -34,7 +144,7 @@ type CommitRequest struct { func (x *CommitRequest) Reset() { *x = CommitRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[0] + mi := &file_blobber_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -47,7 +157,7 @@ func (x *CommitRequest) String() string { func (*CommitRequest) ProtoMessage() {} func (x *CommitRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[0] + mi := &file_blobber_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -60,7 +170,7 @@ func (x *CommitRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CommitRequest.ProtoReflect.Descriptor instead. func (*CommitRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{0} + return file_blobber_proto_rawDescGZIP(), []int{2} } func (x *CommitRequest) GetAllocation() string { @@ -98,7 +208,7 @@ type CommitResponse struct { func (x *CommitResponse) Reset() { *x = CommitResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[1] + mi := &file_blobber_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -111,7 +221,7 @@ func (x *CommitResponse) String() string { func (*CommitResponse) ProtoMessage() {} func (x *CommitResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[1] + mi := &file_blobber_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -124,7 +234,7 @@ func (x *CommitResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CommitResponse.ProtoReflect.Descriptor instead. func (*CommitResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{1} + return file_blobber_proto_rawDescGZIP(), []int{3} } func (x *CommitResponse) GetAllocationRoot() string { @@ -167,7 +277,7 @@ type GetObjectTreeRequest struct { func (x *GetObjectTreeRequest) Reset() { *x = GetObjectTreeRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[2] + mi := &file_blobber_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -180,7 +290,7 @@ func (x *GetObjectTreeRequest) String() string { func (*GetObjectTreeRequest) ProtoMessage() {} func (x *GetObjectTreeRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[2] + mi := &file_blobber_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -193,7 +303,7 @@ func (x *GetObjectTreeRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectTreeRequest.ProtoReflect.Descriptor instead. func (*GetObjectTreeRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{2} + return file_blobber_proto_rawDescGZIP(), []int{4} } func (x *GetObjectTreeRequest) GetPath() string { @@ -222,7 +332,7 @@ type GetObjectTreeResponse struct { func (x *GetObjectTreeResponse) Reset() { *x = GetObjectTreeResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[3] + mi := &file_blobber_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -235,7 +345,7 @@ func (x *GetObjectTreeResponse) String() string { func (*GetObjectTreeResponse) ProtoMessage() {} func (x *GetObjectTreeResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[3] + mi := &file_blobber_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -248,7 +358,7 @@ func (x *GetObjectTreeResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectTreeResponse.ProtoReflect.Descriptor instead. func (*GetObjectTreeResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{3} + return file_blobber_proto_rawDescGZIP(), []int{5} } func (x *GetObjectTreeResponse) GetReferencePath() *ReferencePath { @@ -278,7 +388,7 @@ type GetReferencePathRequest struct { func (x *GetReferencePathRequest) Reset() { *x = GetReferencePathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -291,7 +401,7 @@ func (x *GetReferencePathRequest) String() string { func (*GetReferencePathRequest) ProtoMessage() {} func (x *GetReferencePathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -304,7 +414,7 @@ func (x *GetReferencePathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReferencePathRequest.ProtoReflect.Descriptor instead. func (*GetReferencePathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{4} + return file_blobber_proto_rawDescGZIP(), []int{6} } func (x *GetReferencePathRequest) GetPaths() string { @@ -340,7 +450,7 @@ type GetReferencePathResponse struct { func (x *GetReferencePathResponse) Reset() { *x = GetReferencePathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -353,7 +463,7 @@ func (x *GetReferencePathResponse) String() string { func (*GetReferencePathResponse) ProtoMessage() {} func (x *GetReferencePathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -366,7 +476,7 @@ func (x *GetReferencePathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReferencePathResponse.ProtoReflect.Descriptor instead. func (*GetReferencePathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{5} + return file_blobber_proto_rawDescGZIP(), []int{7} } func (x *GetReferencePathResponse) GetReferencePath() *ReferencePath { @@ -395,7 +505,7 @@ type ReferencePath struct { func (x *ReferencePath) Reset() { *x = ReferencePath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -408,7 +518,7 @@ func (x *ReferencePath) String() string { func (*ReferencePath) ProtoMessage() {} func (x *ReferencePath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -421,7 +531,7 @@ func (x *ReferencePath) ProtoReflect() protoreflect.Message { // Deprecated: Use ReferencePath.ProtoReflect.Descriptor instead. func (*ReferencePath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{6} + return file_blobber_proto_rawDescGZIP(), []int{8} } func (x *ReferencePath) GetMetaData() *FileRef { @@ -451,7 +561,7 @@ type GetObjectPathRequest struct { func (x *GetObjectPathRequest) Reset() { *x = GetObjectPathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -464,7 +574,7 @@ func (x *GetObjectPathRequest) String() string { func (*GetObjectPathRequest) ProtoMessage() {} func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -477,7 +587,7 @@ func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathRequest.ProtoReflect.Descriptor instead. func (*GetObjectPathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{7} + return file_blobber_proto_rawDescGZIP(), []int{9} } func (x *GetObjectPathRequest) GetAllocation() string { @@ -513,7 +623,7 @@ type GetObjectPathResponse struct { func (x *GetObjectPathResponse) Reset() { *x = GetObjectPathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -526,7 +636,7 @@ func (x *GetObjectPathResponse) String() string { func (*GetObjectPathResponse) ProtoMessage() {} func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -539,7 +649,7 @@ func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathResponse.ProtoReflect.Descriptor instead. func (*GetObjectPathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{8} + return file_blobber_proto_rawDescGZIP(), []int{10} } func (x *GetObjectPathResponse) GetObjectPath() *ObjectPath { @@ -571,7 +681,7 @@ type ObjectPath struct { func (x *ObjectPath) Reset() { *x = ObjectPath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -584,7 +694,7 @@ func (x *ObjectPath) String() string { func (*ObjectPath) ProtoMessage() {} func (x *ObjectPath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -597,7 +707,7 @@ func (x *ObjectPath) ProtoReflect() protoreflect.Message { // Deprecated: Use ObjectPath.ProtoReflect.Descriptor instead. func (*ObjectPath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{9} + return file_blobber_proto_rawDescGZIP(), []int{11} } func (x *ObjectPath) GetRootHash() string { @@ -653,7 +763,7 @@ type WriteMarker struct { func (x *WriteMarker) Reset() { *x = WriteMarker{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[10] + mi := &file_blobber_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -666,7 +776,7 @@ func (x *WriteMarker) String() string { func (*WriteMarker) ProtoMessage() {} func (x *WriteMarker) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[10] + mi := &file_blobber_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -679,7 +789,7 @@ func (x *WriteMarker) ProtoReflect() protoreflect.Message { // Deprecated: Use WriteMarker.ProtoReflect.Descriptor instead. func (*WriteMarker) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{10} + return file_blobber_proto_rawDescGZIP(), []int{12} } func (x *WriteMarker) GetAllocationRoot() string { @@ -752,7 +862,7 @@ type ListEntitiesRequest struct { func (x *ListEntitiesRequest) Reset() { *x = ListEntitiesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -765,7 +875,7 @@ func (x *ListEntitiesRequest) String() string { func (*ListEntitiesRequest) ProtoMessage() {} func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -778,7 +888,7 @@ func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ListEntitiesRequest.ProtoReflect.Descriptor instead. func (*ListEntitiesRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{11} + return file_blobber_proto_rawDescGZIP(), []int{13} } func (x *ListEntitiesRequest) GetPath() string { @@ -822,7 +932,7 @@ type ListEntitiesResponse struct { func (x *ListEntitiesResponse) Reset() { *x = ListEntitiesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -835,7 +945,7 @@ func (x *ListEntitiesResponse) String() string { func (*ListEntitiesResponse) ProtoMessage() {} func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -848,7 +958,7 @@ func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ListEntitiesResponse.ProtoReflect.Descriptor instead. func (*ListEntitiesResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{12} + return file_blobber_proto_rawDescGZIP(), []int{14} } func (x *ListEntitiesResponse) GetAllocationRoot() string { @@ -885,7 +995,7 @@ type GetFileStatsRequest struct { func (x *GetFileStatsRequest) Reset() { *x = GetFileStatsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -898,7 +1008,7 @@ func (x *GetFileStatsRequest) String() string { func (*GetFileStatsRequest) ProtoMessage() {} func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -911,7 +1021,7 @@ func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileStatsRequest.ProtoReflect.Descriptor instead. func (*GetFileStatsRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{13} + return file_blobber_proto_rawDescGZIP(), []int{15} } func (x *GetFileStatsRequest) GetPath() string { @@ -947,7 +1057,7 @@ type GetFileStatsResponse struct { func (x *GetFileStatsResponse) Reset() { *x = GetFileStatsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[14] + mi := &file_blobber_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -960,7 +1070,7 @@ func (x *GetFileStatsResponse) String() string { func (*GetFileStatsResponse) ProtoMessage() {} func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[14] + mi := &file_blobber_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -973,7 +1083,7 @@ func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileStatsResponse.ProtoReflect.Descriptor instead. func (*GetFileStatsResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{14} + return file_blobber_proto_rawDescGZIP(), []int{16} } func (x *GetFileStatsResponse) GetMetaData() *FileRef { @@ -1010,7 +1120,7 @@ type FileStats struct { func (x *FileStats) Reset() { *x = FileStats{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[15] + mi := &file_blobber_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1023,7 +1133,7 @@ func (x *FileStats) String() string { func (*FileStats) ProtoMessage() {} func (x *FileStats) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[15] + mi := &file_blobber_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1036,7 +1146,7 @@ func (x *FileStats) ProtoReflect() protoreflect.Message { // Deprecated: Use FileStats.ProtoReflect.Descriptor instead. func (*FileStats) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{15} + return file_blobber_proto_rawDescGZIP(), []int{17} } func (x *FileStats) GetID() int64 { @@ -1123,7 +1233,7 @@ type GetFileMetaDataRequest struct { func (x *GetFileMetaDataRequest) Reset() { *x = GetFileMetaDataRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[16] + mi := &file_blobber_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1136,7 +1246,7 @@ func (x *GetFileMetaDataRequest) String() string { func (*GetFileMetaDataRequest) ProtoMessage() {} func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[16] + mi := &file_blobber_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1149,7 +1259,7 @@ func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileMetaDataRequest.ProtoReflect.Descriptor instead. func (*GetFileMetaDataRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{16} + return file_blobber_proto_rawDescGZIP(), []int{18} } func (x *GetFileMetaDataRequest) GetPath() string { @@ -1192,7 +1302,7 @@ type GetFileMetaDataResponse struct { func (x *GetFileMetaDataResponse) Reset() { *x = GetFileMetaDataResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[17] + mi := &file_blobber_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1205,7 +1315,7 @@ func (x *GetFileMetaDataResponse) String() string { func (*GetFileMetaDataResponse) ProtoMessage() {} func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[17] + mi := &file_blobber_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1218,7 +1328,7 @@ func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileMetaDataResponse.ProtoReflect.Descriptor instead. func (*GetFileMetaDataResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{17} + return file_blobber_proto_rawDescGZIP(), []int{19} } func (x *GetFileMetaDataResponse) GetMetaData() *FileRef { @@ -1248,7 +1358,7 @@ type CommitMetaTxn struct { func (x *CommitMetaTxn) Reset() { *x = CommitMetaTxn{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[18] + mi := &file_blobber_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1261,7 +1371,7 @@ func (x *CommitMetaTxn) String() string { func (*CommitMetaTxn) ProtoMessage() {} func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[18] + mi := &file_blobber_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1274,7 +1384,7 @@ func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { // Deprecated: Use CommitMetaTxn.ProtoReflect.Descriptor instead. func (*CommitMetaTxn) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{18} + return file_blobber_proto_rawDescGZIP(), []int{20} } func (x *CommitMetaTxn) GetRefId() int64 { @@ -1311,7 +1421,7 @@ type Collaborator struct { func (x *Collaborator) Reset() { *x = Collaborator{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1324,7 +1434,7 @@ func (x *Collaborator) String() string { func (*Collaborator) ProtoMessage() {} func (x *Collaborator) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1337,7 +1447,7 @@ func (x *Collaborator) ProtoReflect() protoreflect.Message { // Deprecated: Use Collaborator.ProtoReflect.Descriptor instead. func (*Collaborator) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{19} + return file_blobber_proto_rawDescGZIP(), []int{21} } func (x *Collaborator) GetRefId() int64 { @@ -1372,7 +1482,7 @@ type GetAllocationRequest struct { func (x *GetAllocationRequest) Reset() { *x = GetAllocationRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1385,7 +1495,7 @@ func (x *GetAllocationRequest) String() string { func (*GetAllocationRequest) ProtoMessage() {} func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1398,7 +1508,7 @@ func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationRequest.ProtoReflect.Descriptor instead. func (*GetAllocationRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{22} } func (x *GetAllocationRequest) GetId() string { @@ -1419,7 +1529,7 @@ type GetAllocationResponse struct { func (x *GetAllocationResponse) Reset() { *x = GetAllocationResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1432,7 +1542,7 @@ func (x *GetAllocationResponse) String() string { func (*GetAllocationResponse) ProtoMessage() {} func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1445,7 +1555,7 @@ func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationResponse.ProtoReflect.Descriptor instead. func (*GetAllocationResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{23} } func (x *GetAllocationResponse) GetAllocation() *Allocation { @@ -1482,7 +1592,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1495,7 +1605,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1508,7 +1618,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{24} } func (x *Allocation) GetID() string { @@ -1645,7 +1755,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1658,7 +1768,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1671,7 +1781,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{23} + return file_blobber_proto_rawDescGZIP(), []int{25} } func (x *Term) GetID() int64 { @@ -1722,7 +1832,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1735,7 +1845,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1748,7 +1858,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{24} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *FileRef) GetType() string { @@ -1806,7 +1916,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[25] + mi := &file_blobber_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1819,7 +1929,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[25] + mi := &file_blobber_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1832,7 +1942,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{25} + return file_blobber_proto_rawDescGZIP(), []int{27} } func (x *FileMetaData) GetType() string { @@ -2023,7 +2133,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2036,7 +2146,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2049,7 +2159,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{28} } func (x *DirMetaData) GetType() string { @@ -2129,175 +2239,125 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x22, 0x77, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, - 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, - 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x21, 0x0a, 0x0c, 0x77, 0x72, 0x69, 0x74, 0x65, - 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x77, - 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xbc, 0x01, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x27, 0x0a, - 0x0f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x6f, 0x6f, 0x74, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x42, 0x0a, 0x0c, 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, - 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x0b, 0x77, - 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x23, 0x0a, 0x0d, 0x65, 0x72, - 0x72, 0x6f, 0x72, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0c, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, - 0x18, 0x0a, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, - 0x52, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x22, 0x4a, 0x0a, 0x14, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, - 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, - 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, - 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, - 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, - 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, - 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, - 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, - 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, - 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, - 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, - 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, + 0x6f, 0x22, 0x60, 0x0a, 0x14, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, + 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, + 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x14, 0x0a, + 0x05, 0x70, 0x61, 0x74, 0x68, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70, 0x61, + 0x74, 0x68, 0x73, 0x22, 0x31, 0x0a, 0x15, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, + 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, + 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, + 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0x77, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, + 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x21, 0x0a, 0x0c, + 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0b, 0x77, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, + 0xbc, 0x01, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x27, 0x0a, 0x0f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x42, 0x0a, 0x0c, 0x77, + 0x72, 0x69, 0x74, 0x65, 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, + 0x65, 0x72, 0x52, 0x0b, 0x77, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, + 0x23, 0x0a, 0x0d, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x65, 0x73, + 0x73, 0x61, 0x67, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x22, 0x4a, + 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, - 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, - 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, - 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, - 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, - 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, - 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, - 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, - 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, - 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, - 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, - 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, - 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, - 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, - 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, - 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, - 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, - 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, - 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, - 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, - 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, - 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, + 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, + 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, + 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, + 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, + 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, - 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, - 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, - 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, - 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, - 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, + 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, + 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, + 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, + 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, - 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, - 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, - 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, - 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, - 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, - 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, - 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, - 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, - 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, - 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, - 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, - 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, - 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, - 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, - 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, - 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, - 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, - 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, + 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, + 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, + 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, + 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, + 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, + 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, + 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, + 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, + 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, + 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, + 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, + 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, + 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, + 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, + 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, + 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, + 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, + 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, + 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, + 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, @@ -2305,234 +2365,302 @@ var file_blobber_proto_rawDesc = []byte{ 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, - 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, - 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, - 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, - 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, - 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, - 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, - 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, - 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, - 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, - 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, - 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, - 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, - 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, - 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, - 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, - 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, - 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, - 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, - 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, - 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, - 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, - 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, - 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, - 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, - 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, - 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, - 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, - 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, - 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, - 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, - 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, - 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, - 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, - 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, - 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, - 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, - 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, - 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, + 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, + 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, + 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, + 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, + 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, + 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, + 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, - 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, - 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, - 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, - 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, - 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, - 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, - 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, - 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, - 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, - 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, - 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, - 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, - 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, - 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, - 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, - 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, - 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, - 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, - 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, - 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, - 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, - 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, - 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, - 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, - 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, - 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, - 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, - 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, - 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, - 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, - 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, - 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x32, 0xe5, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, + 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, + 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, + 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, + 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, + 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, + 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, + 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, + 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, + 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, + 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, + 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, + 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, + 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, + 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, + 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, + 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, + 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, + 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, + 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, + 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, + 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, + 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, + 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, + 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, + 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, + 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, + 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, + 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, + 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, + 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, + 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, + 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, + 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, + 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, + 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, + 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, + 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, + 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, + 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, + 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, + 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, + 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, + 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, + 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, + 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, + 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, + 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, + 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, + 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, + 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, + 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, + 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, + 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, + 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, + 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, + 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, + 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, + 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, + 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, + 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, + 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, + 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, + 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, + 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, + 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, + 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, + 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, + 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, + 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, + 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, + 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, + 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, + 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, + 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, + 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, + 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, + 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, + 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, + 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, + 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, + 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, + 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xfc, 0x09, 0x0a, 0x07, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, + 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, + 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, + 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, - 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, - 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, + 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, + 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, + 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, + 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7b, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, - 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, - 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, - 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, - 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, - 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, - 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, - 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, - 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, - 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, - 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, - 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, - 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, - 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, - 0x7b, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x2a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x24, 0x12, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, - 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, - 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x42, 0x2c, 0x5a, 0x2a, - 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, - 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x33, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x24, 0x12, 0x22, 0x2f, + 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, + 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, + 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, + 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, + 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2547,78 +2675,82 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 27) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 29) var file_blobber_proto_goTypes = []interface{}{ - (*CommitRequest)(nil), // 0: blobber.service.v1.CommitRequest - (*CommitResponse)(nil), // 1: blobber.service.v1.CommitResponse - (*GetObjectTreeRequest)(nil), // 2: blobber.service.v1.GetObjectTreeRequest - (*GetObjectTreeResponse)(nil), // 3: blobber.service.v1.GetObjectTreeResponse - (*GetReferencePathRequest)(nil), // 4: blobber.service.v1.GetReferencePathRequest - (*GetReferencePathResponse)(nil), // 5: blobber.service.v1.GetReferencePathResponse - (*ReferencePath)(nil), // 6: blobber.service.v1.ReferencePath - (*GetObjectPathRequest)(nil), // 7: blobber.service.v1.GetObjectPathRequest - (*GetObjectPathResponse)(nil), // 8: blobber.service.v1.GetObjectPathResponse - (*ObjectPath)(nil), // 9: blobber.service.v1.ObjectPath - (*WriteMarker)(nil), // 10: blobber.service.v1.WriteMarker - (*ListEntitiesRequest)(nil), // 11: blobber.service.v1.ListEntitiesRequest - (*ListEntitiesResponse)(nil), // 12: blobber.service.v1.ListEntitiesResponse - (*GetFileStatsRequest)(nil), // 13: blobber.service.v1.GetFileStatsRequest - (*GetFileStatsResponse)(nil), // 14: blobber.service.v1.GetFileStatsResponse - (*FileStats)(nil), // 15: blobber.service.v1.FileStats - (*GetFileMetaDataRequest)(nil), // 16: blobber.service.v1.GetFileMetaDataRequest - (*GetFileMetaDataResponse)(nil), // 17: blobber.service.v1.GetFileMetaDataResponse - (*CommitMetaTxn)(nil), // 18: blobber.service.v1.CommitMetaTxn - (*Collaborator)(nil), // 19: blobber.service.v1.Collaborator - (*GetAllocationRequest)(nil), // 20: blobber.service.v1.GetAllocationRequest - (*GetAllocationResponse)(nil), // 21: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 22: blobber.service.v1.Allocation - (*Term)(nil), // 23: blobber.service.v1.Term - (*FileRef)(nil), // 24: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 25: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 26: blobber.service.v1.DirMetaData + (*CalculateHashRequest)(nil), // 0: blobber.service.v1.CalculateHashRequest + (*CalculateHashResponse)(nil), // 1: blobber.service.v1.CalculateHashResponse + (*CommitRequest)(nil), // 2: blobber.service.v1.CommitRequest + (*CommitResponse)(nil), // 3: blobber.service.v1.CommitResponse + (*GetObjectTreeRequest)(nil), // 4: blobber.service.v1.GetObjectTreeRequest + (*GetObjectTreeResponse)(nil), // 5: blobber.service.v1.GetObjectTreeResponse + (*GetReferencePathRequest)(nil), // 6: blobber.service.v1.GetReferencePathRequest + (*GetReferencePathResponse)(nil), // 7: blobber.service.v1.GetReferencePathResponse + (*ReferencePath)(nil), // 8: blobber.service.v1.ReferencePath + (*GetObjectPathRequest)(nil), // 9: blobber.service.v1.GetObjectPathRequest + (*GetObjectPathResponse)(nil), // 10: blobber.service.v1.GetObjectPathResponse + (*ObjectPath)(nil), // 11: blobber.service.v1.ObjectPath + (*WriteMarker)(nil), // 12: blobber.service.v1.WriteMarker + (*ListEntitiesRequest)(nil), // 13: blobber.service.v1.ListEntitiesRequest + (*ListEntitiesResponse)(nil), // 14: blobber.service.v1.ListEntitiesResponse + (*GetFileStatsRequest)(nil), // 15: blobber.service.v1.GetFileStatsRequest + (*GetFileStatsResponse)(nil), // 16: blobber.service.v1.GetFileStatsResponse + (*FileStats)(nil), // 17: blobber.service.v1.FileStats + (*GetFileMetaDataRequest)(nil), // 18: blobber.service.v1.GetFileMetaDataRequest + (*GetFileMetaDataResponse)(nil), // 19: blobber.service.v1.GetFileMetaDataResponse + (*CommitMetaTxn)(nil), // 20: blobber.service.v1.CommitMetaTxn + (*Collaborator)(nil), // 21: blobber.service.v1.Collaborator + (*GetAllocationRequest)(nil), // 22: blobber.service.v1.GetAllocationRequest + (*GetAllocationResponse)(nil), // 23: blobber.service.v1.GetAllocationResponse + (*Allocation)(nil), // 24: blobber.service.v1.Allocation + (*Term)(nil), // 25: blobber.service.v1.Term + (*FileRef)(nil), // 26: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 27: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 28: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ - 10, // 0: blobber.service.v1.CommitResponse.write_marker:type_name -> blobber.service.v1.WriteMarker - 6, // 1: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 10, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 6, // 3: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 10, // 4: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 24, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef - 6, // 6: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath - 9, // 7: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath - 10, // 8: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 24, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 24, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 24, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 24, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 24, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 24, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef - 15, // 15: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 24, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef - 19, // 17: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 22, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 23, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 25, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 26, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 18, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 20, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 16, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 13, // 25: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 11, // 26: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 7, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest - 4, // 28: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest - 2, // 29: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 0, // 30: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest - 21, // 31: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 17, // 32: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 14, // 33: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 12, // 34: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 8, // 35: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 5, // 36: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 3, // 37: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 1, // 38: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 31, // [31:39] is the sub-list for method output_type - 23, // [23:31] is the sub-list for method input_type + 12, // 0: blobber.service.v1.CommitResponse.write_marker:type_name -> blobber.service.v1.WriteMarker + 8, // 1: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 12, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 8, // 3: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 12, // 4: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 26, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 8, // 6: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath + 11, // 7: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath + 12, // 8: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker + 26, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 26, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 26, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 26, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 26, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 26, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 17, // 15: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats + 26, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 21, // 17: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 24, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 25, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 27, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 28, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 20, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 22, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 18, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 15, // 25: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 13, // 26: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 9, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 6, // 28: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest + 4, // 29: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest + 2, // 30: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest + 0, // 31: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest + 23, // 32: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 19, // 33: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 16, // 34: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 14, // 35: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 10, // 36: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 7, // 37: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 5, // 38: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 3, // 39: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 1, // 40: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 32, // [32:41] is the sub-list for method output_type + 23, // [23:32] is the sub-list for method input_type 23, // [23:23] is the sub-list for extension type_name 23, // [23:23] is the sub-list for extension extendee 0, // [0:23] is the sub-list for field type_name @@ -2631,7 +2763,7 @@ func file_blobber_proto_init() { } if !protoimpl.UnsafeEnabled { file_blobber_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CommitRequest); i { + switch v := v.(*CalculateHashRequest); i { case 0: return &v.state case 1: @@ -2643,7 +2775,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CommitResponse); i { + switch v := v.(*CalculateHashResponse); i { case 0: return &v.state case 1: @@ -2655,7 +2787,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectTreeRequest); i { + switch v := v.(*CommitRequest); i { case 0: return &v.state case 1: @@ -2667,7 +2799,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectTreeResponse); i { + switch v := v.(*CommitResponse); i { case 0: return &v.state case 1: @@ -2679,7 +2811,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetReferencePathRequest); i { + switch v := v.(*GetObjectTreeRequest); i { case 0: return &v.state case 1: @@ -2691,7 +2823,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetReferencePathResponse); i { + switch v := v.(*GetObjectTreeResponse); i { case 0: return &v.state case 1: @@ -2703,7 +2835,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReferencePath); i { + switch v := v.(*GetReferencePathRequest); i { case 0: return &v.state case 1: @@ -2715,7 +2847,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathRequest); i { + switch v := v.(*GetReferencePathResponse); i { case 0: return &v.state case 1: @@ -2727,7 +2859,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathResponse); i { + switch v := v.(*ReferencePath); i { case 0: return &v.state case 1: @@ -2739,7 +2871,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ObjectPath); i { + switch v := v.(*GetObjectPathRequest); i { case 0: return &v.state case 1: @@ -2751,7 +2883,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*WriteMarker); i { + switch v := v.(*GetObjectPathResponse); i { case 0: return &v.state case 1: @@ -2763,7 +2895,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesRequest); i { + switch v := v.(*ObjectPath); i { case 0: return &v.state case 1: @@ -2775,7 +2907,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesResponse); i { + switch v := v.(*WriteMarker); i { case 0: return &v.state case 1: @@ -2787,7 +2919,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsRequest); i { + switch v := v.(*ListEntitiesRequest); i { case 0: return &v.state case 1: @@ -2799,7 +2931,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsResponse); i { + switch v := v.(*ListEntitiesResponse); i { case 0: return &v.state case 1: @@ -2811,7 +2943,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileStats); i { + switch v := v.(*GetFileStatsRequest); i { case 0: return &v.state case 1: @@ -2823,7 +2955,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataRequest); i { + switch v := v.(*GetFileStatsResponse); i { case 0: return &v.state case 1: @@ -2835,7 +2967,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataResponse); i { + switch v := v.(*FileStats); i { case 0: return &v.state case 1: @@ -2847,7 +2979,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CommitMetaTxn); i { + switch v := v.(*GetFileMetaDataRequest); i { case 0: return &v.state case 1: @@ -2859,7 +2991,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Collaborator); i { + switch v := v.(*GetFileMetaDataResponse); i { case 0: return &v.state case 1: @@ -2871,7 +3003,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationRequest); i { + switch v := v.(*CommitMetaTxn); i { case 0: return &v.state case 1: @@ -2883,7 +3015,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationResponse); i { + switch v := v.(*Collaborator); i { case 0: return &v.state case 1: @@ -2895,7 +3027,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*GetAllocationRequest); i { case 0: return &v.state case 1: @@ -2907,7 +3039,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*GetAllocationResponse); i { case 0: return &v.state case 1: @@ -2919,7 +3051,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -2931,7 +3063,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -2943,6 +3075,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -2961,7 +3117,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 27, + NumMessages: 29, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 34894ee95..2af35286e 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -557,6 +557,74 @@ func local_request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marsh } +func request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CalculateHashRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := client.CalculateHash(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CalculateHashRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := server.CalculateHash(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterBlobberHandlerServer registers the http handlers for service Blobber to "mux". // UnaryRPC :call BlobberServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -747,6 +815,29 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) + mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_CalculateHash_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -948,6 +1039,26 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) + mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_CalculateHash_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -967,6 +1078,8 @@ var ( pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) pattern_Blobber_Commit_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "connection", "commit", "allocation"}, "")) + + pattern_Blobber_CalculateHash_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "calculatehash", "allocation"}, "")) ) var ( @@ -985,4 +1098,6 @@ var ( forward_Blobber_GetObjectTree_0 = runtime.ForwardResponseMessage forward_Blobber_Commit_0 = runtime.ForwardResponseMessage + + forward_Blobber_CalculateHash_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 5d548f813..189508c67 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -25,6 +25,7 @@ type BlobberClient interface { GetReferencePath(ctx context.Context, in *GetReferencePathRequest, opts ...grpc.CallOption) (*GetReferencePathResponse, error) GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) Commit(ctx context.Context, in *CommitRequest, opts ...grpc.CallOption) (*CommitResponse, error) + CalculateHash(ctx context.Context, in *CalculateHashRequest, opts ...grpc.CallOption) (*CalculateHashResponse, error) } type blobberClient struct { @@ -107,6 +108,15 @@ func (c *blobberClient) Commit(ctx context.Context, in *CommitRequest, opts ...g return out, nil } +func (c *blobberClient) CalculateHash(ctx context.Context, in *CalculateHashRequest, opts ...grpc.CallOption) (*CalculateHashResponse, error) { + out := new(CalculateHashResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/CalculateHash", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -119,6 +129,7 @@ type BlobberServer interface { GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) Commit(context.Context, *CommitRequest) (*CommitResponse, error) + CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -150,6 +161,9 @@ func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeR func (UnimplementedBlobberServer) Commit(context.Context, *CommitRequest) (*CommitResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Commit not implemented") } +func (UnimplementedBlobberServer) CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CalculateHash not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -307,6 +321,24 @@ func _Blobber_Commit_Handler(srv interface{}, ctx context.Context, dec func(inte return interceptor(ctx, in, info, handler) } +func _Blobber_CalculateHash_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CalculateHashRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).CalculateHash(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/CalculateHash", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).CalculateHash(ctx, req.(*CalculateHashRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Blobber_serviceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), @@ -343,6 +375,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "Commit", Handler: _Blobber_Commit_Handler, }, + { + MethodName: "CalculateHash", + Handler: _Blobber_CalculateHash_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 8444ac4e7..05ac0dc8a 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -88,6 +88,44 @@ ] } }, + "/v2/file/calculatehash/{allocation}": { + "post": { + "operationId": "Blobber_CalculateHash", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1CalculateHashResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1CalculateHashRequest" + } + } + ], + "tags": [ + "Blobber" + ] + } + }, "/v2/file/list/{allocation}": { "get": { "operationId": "Blobber_ListEntities", @@ -443,6 +481,28 @@ } } }, + "v1CalculateHashRequest": { + "type": "object", + "properties": { + "allocation": { + "type": "string" + }, + "path": { + "type": "string" + }, + "paths": { + "type": "string" + } + } + }, + "v1CalculateHashResponse": { + "type": "object", + "properties": { + "message": { + "type": "string" + } + } + }, "v1Collaborator": { "type": "object", "properties": { From f4ff3afb1ea82448cd4ba579c615c0ff530f9431 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 31 May 2021 19:05:18 +0530 Subject: [PATCH 084/183] :bug: adding correct grpc gateway handler --- code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 6fe653e34..7f8865b18 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -45,7 +45,8 @@ service Blobber { rpc Commit(CommitRequest) returns (CommitResponse) { option (google.api.http) = { - get: "/v2/connection/commit/{allocation}" + post: "/v2/connection/commit/{allocation}" + body: "*" }; } From c1a81f9710cd92efe9374bdf805d3b16d5bb6f20 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 31 May 2021 19:08:43 +0530 Subject: [PATCH 085/183] :package: updating grpc generated files --- .../blobbercore/blobbergrpc/blobber.pb.go | 33 ++++++++-------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 38 +++++++++---------- .../blobbercore/openapi/blobber.swagger.json | 32 ++++++++++------ 3 files changed, 56 insertions(+), 47 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index f498951e6..d4be19e31 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -2577,7 +2577,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xfc, 0x09, 0x0a, 0x07, 0x42, 0x6c, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xff, 0x09, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, @@ -2640,27 +2640,28 @@ var file_blobber_proto_rawDesc = []byte{ 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7b, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x24, 0x12, 0x22, 0x2f, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x7d, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, - 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, - 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, - 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, + 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, + 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, + 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, + 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, + 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, + 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, } var ( diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 2af35286e..a563e0829 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -487,14 +487,18 @@ func local_request_Blobber_GetObjectTree_0(ctx context.Context, marshaler runtim } -var ( - filter_Blobber_Commit_0 = &utilities.DoubleArray{Encoding: map[string]int{"allocation": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}} -) - func request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CommitRequest var metadata runtime.ServerMetadata + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + var ( val string ok bool @@ -512,13 +516,6 @@ func request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - if err := req.ParseForm(); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Blobber_Commit_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - msg, err := client.Commit(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err @@ -528,6 +525,14 @@ func local_request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marsh var protoReq CommitRequest var metadata runtime.ServerMetadata + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + var ( val string ok bool @@ -545,13 +550,6 @@ func local_request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marsh return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - if err := req.ParseForm(); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Blobber_Commit_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - msg, err := server.Commit(ctx, &protoReq) return msg, metadata, err @@ -792,7 +790,7 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) - mux.Handle("GET", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream @@ -1019,7 +1017,7 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) - mux.Handle("GET", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 05ac0dc8a..3ab5ce83a 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -47,7 +47,7 @@ } }, "/v2/connection/commit/{allocation}": { - "get": { + "post": { "operationId": "Blobber_Commit", "responses": { "200": { @@ -71,16 +71,12 @@ "type": "string" }, { - "name": "connectionId", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "writeMarker", - "in": "query", - "required": false, - "type": "string" + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1CommitRequest" + } } ], "tags": [ @@ -535,6 +531,20 @@ } } }, + "v1CommitRequest": { + "type": "object", + "properties": { + "allocation": { + "type": "string" + }, + "connectionId": { + "type": "string" + }, + "writeMarker": { + "type": "string" + } + } + }, "v1CommitResponse": { "type": "object", "properties": { From 13ee27cdd40b645ad1e1818d1bf374a372d7be91 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 31 May 2021 19:24:32 +0530 Subject: [PATCH 086/183] go lint timeout updated --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index ef5d2f84d..dc1cdf24d 100644 --- a/Makefile +++ b/Makefile @@ -4,7 +4,7 @@ test: go test ./...; lint: - golangci-lint run; + golangci-lint run --timeout 2m0s; integration-tests: go test ./... -args integration; \ No newline at end of file From e972f7134daf1ee2b42216f13b77043da081bbaf Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 31 May 2021 20:16:23 +0530 Subject: [PATCH 087/183] v2 in request path fixed --- .../blobbercore/blobbergrpc/blobber.pb.go | 2 +- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 2 +- .../blobbergrpc/proto/blobber.proto | 2 +- .../blobbercore/openapi/blobber.swagger.json | 44 +++++++++---------- 4 files changed, 25 insertions(+), 25 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index fe828221b..86d819ad9 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -2565,7 +2565,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, + 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 7cb1fbdd5..9d1de1cf6 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -964,7 +964,7 @@ var ( pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) - pattern_Blobber_CopyObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v1", "file", "copy", "allocation"}, "")) + pattern_Blobber_CopyObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "copy", "allocation"}, "")) ) var ( diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 2c3d9799a..2e1eeca29 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -45,7 +45,7 @@ service Blobber { rpc CopyObject(CopyObjectRequest) returns (CopyObjectResponse) { option (google.api.http) = { - post: "/v1/file/copy/{allocation}" + post: "/v2/file/copy/{allocation}" body: "*" }; } diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index c1e68d0e1..f53ecc8d3 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -16,14 +16,14 @@ "application/json" ], "paths": { - "/v1/file/copy/{allocation}": { - "post": { - "operationId": "Blobber_CopyObject", + "/v2/allocation": { + "get": { + "operationId": "Blobber_GetAllocation", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1CopyObjectResponse" + "$ref": "#/definitions/v1GetAllocationResponse" } }, "default": { @@ -35,18 +35,10 @@ }, "parameters": [ { - "name": "allocation", - "in": "path", - "required": true, + "name": "id", + "in": "query", + "required": false, "type": "string" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/v1CopyObjectRequest" - } } ], "tags": [ @@ -54,14 +46,14 @@ ] } }, - "/v2/allocation": { - "get": { - "operationId": "Blobber_GetAllocation", + "/v2/file/copy/{allocation}": { + "post": { + "operationId": "Blobber_CopyObject", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1GetAllocationResponse" + "$ref": "#/definitions/v1CopyObjectResponse" } }, "default": { @@ -73,10 +65,18 @@ }, "parameters": [ { - "name": "id", - "in": "query", - "required": false, + "name": "allocation", + "in": "path", + "required": true, "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1CopyObjectRequest" + } } ], "tags": [ From 34621cbc47727fd3fbe70c06a9f473169386873b Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 31 May 2021 20:19:51 +0530 Subject: [PATCH 088/183] empty file deleted --- .../handler/object_operation_grpc_handler_integration_test.go | 1 - 1 file changed, 1 deletion(-) delete mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go deleted file mode 100644 index abeebd162..000000000 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go +++ /dev/null @@ -1 +0,0 @@ -package handler From c6d0803758dfa7be9e621c52d4e9cbd1c60ce6c4 Mon Sep 17 00:00:00 2001 From: Vivek V Date: Tue, 1 Jun 2021 15:05:34 +0530 Subject: [PATCH 089/183] :white_check_mark: added integration tests --- .../handler/grpc_handler_integration_test.go | 114 ++++++++++++++++-- 1 file changed, 104 insertions(+), 10 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index ad416995c..96b1670cd 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -11,22 +11,16 @@ import ( "testing" "time" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" - "github.com/0chain/blobber/code/go/0chain.net/core/common" - - "google.golang.org/grpc/metadata" - "github.com/0chain/blobber/code/go/0chain.net/core/encryption" - + "google.golang.org/grpc" + "google.golang.org/grpc/metadata" "gorm.io/driver/postgres" "gorm.io/gorm" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" - "google.golang.org/grpc" ) const BlobberTestAddr = "localhost:7031" @@ -646,4 +640,104 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } }) + t.Run("TestCommitMetaTxn", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().UnixNano()) + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + fr := reference.Ref{ + AllocationID: "exampleId", + } + + rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + + wm := writemarker.WriteMarker{ + AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + PreviousAllocationRoot: "/", + AllocationID: "exampleId", + Size: 1337, + BlobberID: encryption.Hash(blobberPubKeyBytes), + Timestamp: now, + ClientID: clientId, + } + + wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + if err != nil { + t.Fatal(err) + } + + wm.Signature = wmSig + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CommitMetaTxnRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + }), + input: &blobbergrpc.CommitMetaTxnRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: allocationTx, + TxnId: "8", + }, + expectedMessage: "Added commitMetaTxn successfully", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + }), + input: &blobbergrpc.CommitMetaTxnRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: allocationTx, + TxnId: "", + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + commitMetaTxnResponse, err := blobberClient.CommitMetaTxn(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if commitMetaTxnResponse.GetMessage() != tc.expectedMessage { + t.Fatal("failed!") + } + } + }) } From 0423ba7e9d41f1a7b2fbf6a832fe7f7e2fa98f62 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 1 Jun 2021 22:06:31 +0530 Subject: [PATCH 090/183] reviews applied --- .../allocation/allocationchange.go | 36 - .../blobbercore/blobbergrpc/blobber.pb.go | 1492 ++++++++--------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 2 +- .../blobbergrpc/proto/blobber.proto | 104 +- .../0chain.net/blobbercore/handler/handler.go | 3 +- .../0chain.net/blobbercore/handler/helper.go | 15 +- .../handler/object_operation_grpc_handler.go | 26 +- ...operation_grpc_handler_integration_test.go | 1 - .../object_operation_grpc_handler_test.go | 35 +- .../mocks/IAllocationChangeCollector.go | 148 -- .../blobbercore/mocks/PackageHandler.go | 333 ---- .../blobbercore/mocks/ReadMakerI.go | 69 - .../blobbercore/openapi/blobber.swagger.json | 44 +- .../blobbercore/readmarker/entity.go | 4 - .../blobbercore/readmarker/readmaker.go | 18 - 15 files changed, 872 insertions(+), 1458 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go delete mode 100644 code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go delete mode 100644 code/go/0chain.net/blobbercore/mocks/PackageHandler.go delete mode 100644 code/go/0chain.net/blobbercore/mocks/ReadMakerI.go delete mode 100644 code/go/0chain.net/blobbercore/readmarker/readmaker.go diff --git a/code/go/0chain.net/blobbercore/allocation/allocationchange.go b/code/go/0chain.net/blobbercore/allocation/allocationchange.go index 967be49be..e3de29dc9 100644 --- a/code/go/0chain.net/blobbercore/allocation/allocationchange.go +++ b/code/go/0chain.net/blobbercore/allocation/allocationchange.go @@ -38,22 +38,6 @@ type AllocationChangeProcessor interface { Marshal() (string, error) Unmarshal(string) error } - -type IAllocationChangeCollector interface { - TableName() string - AddChange(allocationChange *AllocationChange, changeProcessor AllocationChangeProcessor) - Save(ctx context.Context) error - ComputeProperties() - ApplyChanges(ctx context.Context, allocationRoot string) error - CommitToFileStore(ctx context.Context) error - DeleteChanges(ctx context.Context) - GetAllocationID() string - GetConnectionID() string - GetClientID() string - GetSize() int64 - SetSize(size int64) -} - type AllocationChangeCollector struct { ConnectionID string `gorm:"column:connection_id;primary_key"` AllocationID string `gorm:"column:allocation_id"` @@ -185,23 +169,3 @@ func (a *AllocationChangeCollector) DeleteChanges(ctx context.Context) { } } } - -func (cc *AllocationChangeCollector) GetAllocationID() string { - return cc.AllocationID -} - -func (cc *AllocationChangeCollector) GetConnectionID() string { - return cc.ConnectionID -} - -func (cc *AllocationChangeCollector) GetClientID() string { - return cc.ClientID -} - -func (cc *AllocationChangeCollector) GetSize() int64 { - return cc.Size -} - -func (cc *AllocationChangeCollector) SetSize(size int64) { - cc.Size = size -} diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index ef57fb91b..33696da22 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -249,6 +249,61 @@ func (x *GetReferencePathResponse) GetLatestWM() *WriteMarker { return nil } +type ReferencePath struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` + List []*ReferencePath `protobuf:"bytes,2,rep,name=List,proto3" json:"List,omitempty"` +} + +func (x *ReferencePath) Reset() { + *x = ReferencePath{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ReferencePath) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ReferencePath) ProtoMessage() {} + +func (x *ReferencePath) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[4] + 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 ReferencePath.ProtoReflect.Descriptor instead. +func (*ReferencePath) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{4} +} + +func (x *ReferencePath) GetMetaData() *FileRef { + if x != nil { + return x.MetaData + } + return nil +} + +func (x *ReferencePath) GetList() []*ReferencePath { + if x != nil { + return x.List + } + return nil +} + type GetObjectPathRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -262,7 +317,7 @@ type GetObjectPathRequest struct { func (x *GetObjectPathRequest) Reset() { *x = GetObjectPathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -275,7 +330,7 @@ func (x *GetObjectPathRequest) String() string { func (*GetObjectPathRequest) ProtoMessage() {} func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -288,7 +343,7 @@ func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathRequest.ProtoReflect.Descriptor instead. func (*GetObjectPathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{4} + return file_blobber_proto_rawDescGZIP(), []int{5} } func (x *GetObjectPathRequest) GetAllocation() string { @@ -324,7 +379,7 @@ type GetObjectPathResponse struct { func (x *GetObjectPathResponse) Reset() { *x = GetObjectPathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -337,7 +392,7 @@ func (x *GetObjectPathResponse) String() string { func (*GetObjectPathResponse) ProtoMessage() {} func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -350,7 +405,7 @@ func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathResponse.ProtoReflect.Descriptor instead. func (*GetObjectPathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{5} + return file_blobber_proto_rawDescGZIP(), []int{6} } func (x *GetObjectPathResponse) GetObjectPath() *ObjectPath { @@ -367,34 +422,35 @@ func (x *GetObjectPathResponse) GetLatestWriteMarker() *WriteMarker { return nil } -type ListEntitiesRequest struct { +type ObjectPath struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` - PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` - AuthToken string `protobuf:"bytes,3,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` - Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` + RootHash string `protobuf:"bytes,1,opt,name=RootHash,proto3" json:"RootHash,omitempty"` + Meta *FileRef `protobuf:"bytes,2,opt,name=Meta,proto3" json:"Meta,omitempty"` + Path *FileRef `protobuf:"bytes,3,opt,name=Path,proto3" json:"Path,omitempty"` + PathList []*FileRef `protobuf:"bytes,4,rep,name=PathList,proto3" json:"PathList,omitempty"` + FileBlockNum int64 `protobuf:"varint,5,opt,name=FileBlockNum,proto3" json:"FileBlockNum,omitempty"` } -func (x *ListEntitiesRequest) Reset() { - *x = ListEntitiesRequest{} +func (x *ObjectPath) Reset() { + *x = ObjectPath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *ListEntitiesRequest) String() string { +func (x *ObjectPath) String() string { return protoimpl.X.MessageStringOf(x) } -func (*ListEntitiesRequest) ProtoMessage() {} +func (*ObjectPath) ProtoMessage() {} -func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[6] +func (x *ObjectPath) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -405,66 +461,78 @@ func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use ListEntitiesRequest.ProtoReflect.Descriptor instead. -func (*ListEntitiesRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{6} +// Deprecated: Use ObjectPath.ProtoReflect.Descriptor instead. +func (*ObjectPath) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{7} } -func (x *ListEntitiesRequest) GetPath() string { +func (x *ObjectPath) GetRootHash() string { if x != nil { - return x.Path + return x.RootHash } return "" } -func (x *ListEntitiesRequest) GetPathHash() string { +func (x *ObjectPath) GetMeta() *FileRef { if x != nil { - return x.PathHash + return x.Meta } - return "" + return nil } -func (x *ListEntitiesRequest) GetAuthToken() string { +func (x *ObjectPath) GetPath() *FileRef { if x != nil { - return x.AuthToken + return x.Path } - return "" + return nil } -func (x *ListEntitiesRequest) GetAllocation() string { +func (x *ObjectPath) GetPathList() []*FileRef { if x != nil { - return x.Allocation + return x.PathList } - return "" + return nil } -type ListEntitiesResponse struct { +func (x *ObjectPath) GetFileBlockNum() int64 { + if x != nil { + return x.FileBlockNum + } + return 0 +} + +type WriteMarker struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` - MetaData *FileRef `protobuf:"bytes,2,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - Entities []*FileRef `protobuf:"bytes,3,rep,name=Entities,proto3" json:"Entities,omitempty"` + AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` + PreviousAllocationRoot string `protobuf:"bytes,2,opt,name=PreviousAllocationRoot,proto3" json:"PreviousAllocationRoot,omitempty"` + AllocationID string `protobuf:"bytes,3,opt,name=AllocationID,proto3" json:"AllocationID,omitempty"` + Size int64 `protobuf:"varint,4,opt,name=Size,proto3" json:"Size,omitempty"` + BlobberID string `protobuf:"bytes,5,opt,name=BlobberID,proto3" json:"BlobberID,omitempty"` + Timestamp int64 `protobuf:"varint,6,opt,name=Timestamp,proto3" json:"Timestamp,omitempty"` + ClientID string `protobuf:"bytes,7,opt,name=ClientID,proto3" json:"ClientID,omitempty"` + Signature string `protobuf:"bytes,8,opt,name=Signature,proto3" json:"Signature,omitempty"` } -func (x *ListEntitiesResponse) Reset() { - *x = ListEntitiesResponse{} +func (x *WriteMarker) Reset() { + *x = WriteMarker{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *ListEntitiesResponse) String() string { +func (x *WriteMarker) String() string { return protoimpl.X.MessageStringOf(x) } -func (*ListEntitiesResponse) ProtoMessage() {} +func (*WriteMarker) ProtoMessage() {} -func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[7] +func (x *WriteMarker) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -475,59 +543,95 @@ func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use ListEntitiesResponse.ProtoReflect.Descriptor instead. -func (*ListEntitiesResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{7} +// Deprecated: Use WriteMarker.ProtoReflect.Descriptor instead. +func (*WriteMarker) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{8} } -func (x *ListEntitiesResponse) GetAllocationRoot() string { +func (x *WriteMarker) GetAllocationRoot() string { if x != nil { return x.AllocationRoot } return "" } -func (x *ListEntitiesResponse) GetMetaData() *FileRef { +func (x *WriteMarker) GetPreviousAllocationRoot() string { if x != nil { - return x.MetaData + return x.PreviousAllocationRoot } - return nil + return "" } -func (x *ListEntitiesResponse) GetEntities() []*FileRef { +func (x *WriteMarker) GetAllocationID() string { if x != nil { - return x.Entities + return x.AllocationID } - return nil + return "" } -type GetFileStatsRequest struct { +func (x *WriteMarker) GetSize() int64 { + if x != nil { + return x.Size + } + return 0 +} + +func (x *WriteMarker) GetBlobberID() string { + if x != nil { + return x.BlobberID + } + return "" +} + +func (x *WriteMarker) GetTimestamp() int64 { + if x != nil { + return x.Timestamp + } + return 0 +} + +func (x *WriteMarker) GetClientID() string { + if x != nil { + return x.ClientID + } + return "" +} + +func (x *WriteMarker) GetSignature() string { + if x != nil { + return x.Signature + } + return "" +} + +type ListEntitiesRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` - Allocation string `protobuf:"bytes,3,opt,name=allocation,proto3" json:"allocation,omitempty"` + AuthToken string `protobuf:"bytes,3,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` + Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` } -func (x *GetFileStatsRequest) Reset() { - *x = GetFileStatsRequest{} +func (x *ListEntitiesRequest) Reset() { + *x = ListEntitiesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *GetFileStatsRequest) String() string { +func (x *ListEntitiesRequest) String() string { return protoimpl.X.MessageStringOf(x) } -func (*GetFileStatsRequest) ProtoMessage() {} +func (*ListEntitiesRequest) ProtoMessage() {} -func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[8] +func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -538,58 +642,66 @@ func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use GetFileStatsRequest.ProtoReflect.Descriptor instead. -func (*GetFileStatsRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{8} +// Deprecated: Use ListEntitiesRequest.ProtoReflect.Descriptor instead. +func (*ListEntitiesRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{9} } -func (x *GetFileStatsRequest) GetPath() string { +func (x *ListEntitiesRequest) GetPath() string { if x != nil { return x.Path } return "" } -func (x *GetFileStatsRequest) GetPathHash() string { +func (x *ListEntitiesRequest) GetPathHash() string { if x != nil { return x.PathHash } return "" } -func (x *GetFileStatsRequest) GetAllocation() string { +func (x *ListEntitiesRequest) GetAuthToken() string { + if x != nil { + return x.AuthToken + } + return "" +} + +func (x *ListEntitiesRequest) GetAllocation() string { if x != nil { return x.Allocation } return "" } -type GetFileStatsResponse struct { +type ListEntitiesResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - Stats *FileStats `protobuf:"bytes,2,opt,name=Stats,proto3" json:"Stats,omitempty"` + AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` + MetaData *FileRef `protobuf:"bytes,2,opt,name=MetaData,proto3" json:"MetaData,omitempty"` + Entities []*FileRef `protobuf:"bytes,3,rep,name=Entities,proto3" json:"Entities,omitempty"` } -func (x *GetFileStatsResponse) Reset() { - *x = GetFileStatsResponse{} +func (x *ListEntitiesResponse) Reset() { + *x = ListEntitiesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *GetFileStatsResponse) String() string { +func (x *ListEntitiesResponse) String() string { return protoimpl.X.MessageStringOf(x) } -func (*GetFileStatsResponse) ProtoMessage() {} +func (*ListEntitiesResponse) ProtoMessage() {} -func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[9] +func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -600,53 +712,59 @@ func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use GetFileStatsResponse.ProtoReflect.Descriptor instead. -func (*GetFileStatsResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{9} +// Deprecated: Use ListEntitiesResponse.ProtoReflect.Descriptor instead. +func (*ListEntitiesResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{10} } -func (x *GetFileStatsResponse) GetMetaData() *FileRef { +func (x *ListEntitiesResponse) GetAllocationRoot() string { + if x != nil { + return x.AllocationRoot + } + return "" +} + +func (x *ListEntitiesResponse) GetMetaData() *FileRef { if x != nil { return x.MetaData } return nil } -func (x *GetFileStatsResponse) GetStats() *FileStats { +func (x *ListEntitiesResponse) GetEntities() []*FileRef { if x != nil { - return x.Stats + return x.Entities } return nil } -type GetFileMetaDataRequest struct { +type GetFileStatsRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` - AuthToken string `protobuf:"bytes,3,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` - Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` + Allocation string `protobuf:"bytes,3,opt,name=allocation,proto3" json:"allocation,omitempty"` } -func (x *GetFileMetaDataRequest) Reset() { - *x = GetFileMetaDataRequest{} +func (x *GetFileStatsRequest) Reset() { + *x = GetFileStatsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[10] + mi := &file_blobber_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *GetFileMetaDataRequest) String() string { +func (x *GetFileStatsRequest) String() string { return protoimpl.X.MessageStringOf(x) } -func (*GetFileMetaDataRequest) ProtoMessage() {} +func (*GetFileStatsRequest) ProtoMessage() {} -func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[10] +func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -657,65 +775,58 @@ func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use GetFileMetaDataRequest.ProtoReflect.Descriptor instead. -func (*GetFileMetaDataRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{10} +// Deprecated: Use GetFileStatsRequest.ProtoReflect.Descriptor instead. +func (*GetFileStatsRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{11} } -func (x *GetFileMetaDataRequest) GetPath() string { +func (x *GetFileStatsRequest) GetPath() string { if x != nil { return x.Path } return "" } -func (x *GetFileMetaDataRequest) GetPathHash() string { +func (x *GetFileStatsRequest) GetPathHash() string { if x != nil { return x.PathHash } return "" } -func (x *GetFileMetaDataRequest) GetAuthToken() string { - if x != nil { - return x.AuthToken - } - return "" -} - -func (x *GetFileMetaDataRequest) GetAllocation() string { +func (x *GetFileStatsRequest) GetAllocation() string { if x != nil { return x.Allocation } return "" } -type GetFileMetaDataResponse struct { +type GetFileStatsResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - Collaborators []*Collaborator `protobuf:"bytes,2,rep,name=Collaborators,proto3" json:"Collaborators,omitempty"` + MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` + Stats *FileStats `protobuf:"bytes,2,opt,name=Stats,proto3" json:"Stats,omitempty"` } -func (x *GetFileMetaDataResponse) Reset() { - *x = GetFileMetaDataResponse{} +func (x *GetFileStatsResponse) Reset() { + *x = GetFileStatsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *GetFileMetaDataResponse) String() string { +func (x *GetFileStatsResponse) String() string { return protoimpl.X.MessageStringOf(x) } -func (*GetFileMetaDataResponse) ProtoMessage() {} +func (*GetFileStatsResponse) ProtoMessage() {} -func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[11] +func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -726,50 +837,59 @@ func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use GetFileMetaDataResponse.ProtoReflect.Descriptor instead. -func (*GetFileMetaDataResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{11} +// Deprecated: Use GetFileStatsResponse.ProtoReflect.Descriptor instead. +func (*GetFileStatsResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{12} } -func (x *GetFileMetaDataResponse) GetMetaData() *FileRef { +func (x *GetFileStatsResponse) GetMetaData() *FileRef { if x != nil { return x.MetaData } return nil } -func (x *GetFileMetaDataResponse) GetCollaborators() []*Collaborator { +func (x *GetFileStatsResponse) GetStats() *FileStats { if x != nil { - return x.Collaborators + return x.Stats } return nil } -type GetAllocationRequest struct { +type FileStats struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + ID int64 `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"` + RefID int64 `protobuf:"varint,2,opt,name=RefID,proto3" json:"RefID,omitempty"` + NumUpdates int64 `protobuf:"varint,3,opt,name=NumUpdates,proto3" json:"NumUpdates,omitempty"` + NumBlockDownloads int64 `protobuf:"varint,4,opt,name=NumBlockDownloads,proto3" json:"NumBlockDownloads,omitempty"` + SuccessChallenges int64 `protobuf:"varint,5,opt,name=SuccessChallenges,proto3" json:"SuccessChallenges,omitempty"` + FailedChallenges int64 `protobuf:"varint,6,opt,name=FailedChallenges,proto3" json:"FailedChallenges,omitempty"` + LastChallengeResponseTxn string `protobuf:"bytes,7,opt,name=LastChallengeResponseTxn,proto3" json:"LastChallengeResponseTxn,omitempty"` + WriteMarkerRedeemTxn string `protobuf:"bytes,8,opt,name=WriteMarkerRedeemTxn,proto3" json:"WriteMarkerRedeemTxn,omitempty"` + CreatedAt int64 `protobuf:"varint,9,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` + UpdatedAt int64 `protobuf:"varint,10,opt,name=UpdatedAt,proto3" json:"UpdatedAt,omitempty"` } -func (x *GetAllocationRequest) Reset() { - *x = GetAllocationRequest{} +func (x *FileStats) Reset() { + *x = FileStats{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *GetAllocationRequest) String() string { +func (x *FileStats) String() string { return protoimpl.X.MessageStringOf(x) } -func (*GetAllocationRequest) ProtoMessage() {} +func (*FileStats) ProtoMessage() {} -func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[12] +func (x *FileStats) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -780,83 +900,94 @@ func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use GetAllocationRequest.ProtoReflect.Descriptor instead. -func (*GetAllocationRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{12} +// Deprecated: Use FileStats.ProtoReflect.Descriptor instead. +func (*FileStats) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{13} } -func (x *GetAllocationRequest) GetId() string { +func (x *FileStats) GetID() int64 { if x != nil { - return x.Id + return x.ID } - return "" + return 0 } -type GetAllocationResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields +func (x *FileStats) GetRefID() int64 { + if x != nil { + return x.RefID + } + return 0 +} - Allocation *Allocation `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` +func (x *FileStats) GetNumUpdates() int64 { + if x != nil { + return x.NumUpdates + } + return 0 } -func (x *GetAllocationResponse) Reset() { - *x = GetAllocationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) +func (x *FileStats) GetNumBlockDownloads() int64 { + if x != nil { + return x.NumBlockDownloads } + return 0 } -func (x *GetAllocationResponse) String() string { - return protoimpl.X.MessageStringOf(x) +func (x *FileStats) GetSuccessChallenges() int64 { + if x != nil { + return x.SuccessChallenges + } + return 0 } -func (*GetAllocationResponse) ProtoMessage() {} +func (x *FileStats) GetFailedChallenges() int64 { + if x != nil { + return x.FailedChallenges + } + return 0 +} -func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms +func (x *FileStats) GetLastChallengeResponseTxn() string { + if x != nil { + return x.LastChallengeResponseTxn } - return mi.MessageOf(x) + return "" } -// Deprecated: Use GetAllocationResponse.ProtoReflect.Descriptor instead. -func (*GetAllocationResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{13} +func (x *FileStats) GetWriteMarkerRedeemTxn() string { + if x != nil { + return x.WriteMarkerRedeemTxn + } + return "" } -func (x *GetAllocationResponse) GetAllocation() *Allocation { +func (x *FileStats) GetCreatedAt() int64 { if x != nil { - return x.Allocation + return x.CreatedAt } - return nil + return 0 } -type DownloadFileRequest struct { +func (x *FileStats) GetUpdatedAt() int64 { + if x != nil { + return x.UpdatedAt + } + return 0 +} + +type GetFileMetaDataRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` - Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` - PathHash string `protobuf:"bytes,3,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` - RxPay string `protobuf:"bytes,4,opt,name=rx_pay,json=rxPay,proto3" json:"rx_pay,omitempty"` - BlockNum string `protobuf:"bytes,5,opt,name=block_num,json=blockNum,proto3" json:"block_num,omitempty"` - NumBlocks string `protobuf:"bytes,6,opt,name=num_blocks,json=numBlocks,proto3" json:"num_blocks,omitempty"` - ReadMarker string `protobuf:"bytes,7,opt,name=read_marker,json=readMarker,proto3" json:"read_marker,omitempty"` - AuthToken string `protobuf:"bytes,8,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` - Content string `protobuf:"bytes,9,opt,name=content,proto3" json:"content,omitempty"` + Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,2,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + AuthToken string `protobuf:"bytes,3,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` + Allocation string `protobuf:"bytes,4,opt,name=allocation,proto3" json:"allocation,omitempty"` } -func (x *DownloadFileRequest) Reset() { - *x = DownloadFileRequest{} +func (x *GetFileMetaDataRequest) Reset() { + *x = GetFileMetaDataRequest{} if protoimpl.UnsafeEnabled { mi := &file_blobber_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -864,13 +995,13 @@ func (x *DownloadFileRequest) Reset() { } } -func (x *DownloadFileRequest) String() string { +func (x *GetFileMetaDataRequest) String() string { return protoimpl.X.MessageStringOf(x) } -func (*DownloadFileRequest) ProtoMessage() {} +func (*GetFileMetaDataRequest) ProtoMessage() {} -func (x *DownloadFileRequest) ProtoReflect() protoreflect.Message { +func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { mi := &file_blobber_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -882,88 +1013,50 @@ func (x *DownloadFileRequest) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use DownloadFileRequest.ProtoReflect.Descriptor instead. -func (*DownloadFileRequest) Descriptor() ([]byte, []int) { +// Deprecated: Use GetFileMetaDataRequest.ProtoReflect.Descriptor instead. +func (*GetFileMetaDataRequest) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{14} } -func (x *DownloadFileRequest) GetAllocation() string { +func (x *GetFileMetaDataRequest) GetPath() string { if x != nil { - return x.Allocation + return x.Path } return "" } -func (x *DownloadFileRequest) GetPath() string { +func (x *GetFileMetaDataRequest) GetPathHash() string { if x != nil { - return x.Path + return x.PathHash } return "" } -func (x *DownloadFileRequest) GetPathHash() string { +func (x *GetFileMetaDataRequest) GetAuthToken() string { if x != nil { - return x.PathHash + return x.AuthToken } return "" } -func (x *DownloadFileRequest) GetRxPay() string { - if x != nil { - return x.RxPay - } - return "" -} - -func (x *DownloadFileRequest) GetBlockNum() string { - if x != nil { - return x.BlockNum - } - return "" -} - -func (x *DownloadFileRequest) GetNumBlocks() string { - if x != nil { - return x.NumBlocks - } - return "" -} - -func (x *DownloadFileRequest) GetReadMarker() string { - if x != nil { - return x.ReadMarker - } - return "" -} - -func (x *DownloadFileRequest) GetAuthToken() string { - if x != nil { - return x.AuthToken - } - return "" -} - -func (x *DownloadFileRequest) GetContent() string { +func (x *GetFileMetaDataRequest) GetAllocation() string { if x != nil { - return x.Content + return x.Allocation } return "" } -type DownloadFileResponse struct { +type GetFileMetaDataResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"` - Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` - AllocationId string `protobuf:"bytes,3,opt,name=allocation_id,json=allocationId,proto3" json:"allocation_id,omitempty"` - Path string `protobuf:"bytes,4,opt,name=path,proto3" json:"path,omitempty"` - LatestRm *ReadMaker `protobuf:"bytes,5,opt,name=latest_rm,json=latestRm,proto3" json:"latest_rm,omitempty"` + MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` + Collaborators []*Collaborator `protobuf:"bytes,2,rep,name=Collaborators,proto3" json:"Collaborators,omitempty"` } -func (x *DownloadFileResponse) Reset() { - *x = DownloadFileResponse{} +func (x *GetFileMetaDataResponse) Reset() { + *x = GetFileMetaDataResponse{} if protoimpl.UnsafeEnabled { mi := &file_blobber_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -971,13 +1064,13 @@ func (x *DownloadFileResponse) Reset() { } } -func (x *DownloadFileResponse) String() string { +func (x *GetFileMetaDataResponse) String() string { return protoimpl.X.MessageStringOf(x) } -func (*DownloadFileResponse) ProtoMessage() {} +func (*GetFileMetaDataResponse) ProtoMessage() {} -func (x *DownloadFileResponse) ProtoReflect() protoreflect.Message { +func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { mi := &file_blobber_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -989,57 +1082,37 @@ func (x *DownloadFileResponse) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use DownloadFileResponse.ProtoReflect.Descriptor instead. -func (*DownloadFileResponse) Descriptor() ([]byte, []int) { +// Deprecated: Use GetFileMetaDataResponse.ProtoReflect.Descriptor instead. +func (*GetFileMetaDataResponse) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{15} } -func (x *DownloadFileResponse) GetSuccess() bool { - if x != nil { - return x.Success - } - return false -} - -func (x *DownloadFileResponse) GetData() []byte { +func (x *GetFileMetaDataResponse) GetMetaData() *FileRef { if x != nil { - return x.Data + return x.MetaData } return nil } -func (x *DownloadFileResponse) GetAllocationId() string { - if x != nil { - return x.AllocationId - } - return "" -} - -func (x *DownloadFileResponse) GetPath() string { - if x != nil { - return x.Path - } - return "" -} - -func (x *DownloadFileResponse) GetLatestRm() *ReadMaker { +func (x *GetFileMetaDataResponse) GetCollaborators() []*Collaborator { if x != nil { - return x.LatestRm + return x.Collaborators } return nil } -type ReferencePath struct { +type CommitMetaTxn struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - List []*ReferencePath `protobuf:"bytes,2,rep,name=List,proto3" json:"List,omitempty"` + RefId int64 `protobuf:"varint,1,opt,name=RefId,proto3" json:"RefId,omitempty"` + TxnId string `protobuf:"bytes,2,opt,name=TxnId,proto3" json:"TxnId,omitempty"` + CreatedAt int64 `protobuf:"varint,3,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` } -func (x *ReferencePath) Reset() { - *x = ReferencePath{} +func (x *CommitMetaTxn) Reset() { + *x = CommitMetaTxn{} if protoimpl.UnsafeEnabled { mi := &file_blobber_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1047,13 +1120,13 @@ func (x *ReferencePath) Reset() { } } -func (x *ReferencePath) String() string { +func (x *CommitMetaTxn) String() string { return protoimpl.X.MessageStringOf(x) } -func (*ReferencePath) ProtoMessage() {} +func (*CommitMetaTxn) ProtoMessage() {} -func (x *ReferencePath) ProtoReflect() protoreflect.Message { +func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { mi := &file_blobber_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1065,39 +1138,44 @@ func (x *ReferencePath) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use ReferencePath.ProtoReflect.Descriptor instead. -func (*ReferencePath) Descriptor() ([]byte, []int) { +// Deprecated: Use CommitMetaTxn.ProtoReflect.Descriptor instead. +func (*CommitMetaTxn) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{16} } -func (x *ReferencePath) GetMetaData() *FileRef { +func (x *CommitMetaTxn) GetRefId() int64 { if x != nil { - return x.MetaData + return x.RefId } - return nil + return 0 } -func (x *ReferencePath) GetList() []*ReferencePath { +func (x *CommitMetaTxn) GetTxnId() string { if x != nil { - return x.List + return x.TxnId } - return nil + return "" } -type ObjectPath struct { +func (x *CommitMetaTxn) GetCreatedAt() int64 { + if x != nil { + return x.CreatedAt + } + return 0 +} + +type Collaborator struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RootHash string `protobuf:"bytes,1,opt,name=RootHash,proto3" json:"RootHash,omitempty"` - Meta *FileRef `protobuf:"bytes,2,opt,name=Meta,proto3" json:"Meta,omitempty"` - Path *FileRef `protobuf:"bytes,3,opt,name=Path,proto3" json:"Path,omitempty"` - PathList []*FileRef `protobuf:"bytes,4,rep,name=PathList,proto3" json:"PathList,omitempty"` - FileBlockNum int64 `protobuf:"varint,5,opt,name=FileBlockNum,proto3" json:"FileBlockNum,omitempty"` + RefId int64 `protobuf:"varint,1,opt,name=RefId,proto3" json:"RefId,omitempty"` + ClientId string `protobuf:"bytes,2,opt,name=ClientId,proto3" json:"ClientId,omitempty"` + CreatedAt int64 `protobuf:"varint,3,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` } -func (x *ObjectPath) Reset() { - *x = ObjectPath{} +func (x *Collaborator) Reset() { + *x = Collaborator{} if protoimpl.UnsafeEnabled { mi := &file_blobber_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1105,13 +1183,13 @@ func (x *ObjectPath) Reset() { } } -func (x *ObjectPath) String() string { +func (x *Collaborator) String() string { return protoimpl.X.MessageStringOf(x) } -func (*ObjectPath) ProtoMessage() {} +func (*Collaborator) ProtoMessage() {} -func (x *ObjectPath) ProtoReflect() protoreflect.Message { +func (x *Collaborator) ProtoReflect() protoreflect.Message { mi := &file_blobber_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1123,65 +1201,42 @@ func (x *ObjectPath) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use ObjectPath.ProtoReflect.Descriptor instead. -func (*ObjectPath) Descriptor() ([]byte, []int) { +// Deprecated: Use Collaborator.ProtoReflect.Descriptor instead. +func (*Collaborator) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{17} } -func (x *ObjectPath) GetRootHash() string { - if x != nil { - return x.RootHash - } - return "" -} - -func (x *ObjectPath) GetMeta() *FileRef { - if x != nil { - return x.Meta - } - return nil -} - -func (x *ObjectPath) GetPath() *FileRef { +func (x *Collaborator) GetRefId() int64 { if x != nil { - return x.Path + return x.RefId } - return nil + return 0 } -func (x *ObjectPath) GetPathList() []*FileRef { +func (x *Collaborator) GetClientId() string { if x != nil { - return x.PathList + return x.ClientId } - return nil + return "" } -func (x *ObjectPath) GetFileBlockNum() int64 { +func (x *Collaborator) GetCreatedAt() int64 { if x != nil { - return x.FileBlockNum + return x.CreatedAt } return 0 } -type FileStats struct { +type GetAllocationRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ID int64 `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"` - RefID int64 `protobuf:"varint,2,opt,name=RefID,proto3" json:"RefID,omitempty"` - NumUpdates int64 `protobuf:"varint,3,opt,name=NumUpdates,proto3" json:"NumUpdates,omitempty"` - NumBlockDownloads int64 `protobuf:"varint,4,opt,name=NumBlockDownloads,proto3" json:"NumBlockDownloads,omitempty"` - SuccessChallenges int64 `protobuf:"varint,5,opt,name=SuccessChallenges,proto3" json:"SuccessChallenges,omitempty"` - FailedChallenges int64 `protobuf:"varint,6,opt,name=FailedChallenges,proto3" json:"FailedChallenges,omitempty"` - LastChallengeResponseTxn string `protobuf:"bytes,7,opt,name=LastChallengeResponseTxn,proto3" json:"LastChallengeResponseTxn,omitempty"` - WriteMarkerRedeemTxn string `protobuf:"bytes,8,opt,name=WriteMarkerRedeemTxn,proto3" json:"WriteMarkerRedeemTxn,omitempty"` - CreatedAt int64 `protobuf:"varint,9,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` - UpdatedAt int64 `protobuf:"varint,10,opt,name=UpdatedAt,proto3" json:"UpdatedAt,omitempty"` + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` } -func (x *FileStats) Reset() { - *x = FileStats{} +func (x *GetAllocationRequest) Reset() { + *x = GetAllocationRequest{} if protoimpl.UnsafeEnabled { mi := &file_blobber_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1189,13 +1244,13 @@ func (x *FileStats) Reset() { } } -func (x *FileStats) String() string { +func (x *GetAllocationRequest) String() string { return protoimpl.X.MessageStringOf(x) } -func (*FileStats) ProtoMessage() {} +func (*GetAllocationRequest) ProtoMessage() {} -func (x *FileStats) ProtoReflect() protoreflect.Message { +func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { mi := &file_blobber_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1207,93 +1262,28 @@ func (x *FileStats) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use FileStats.ProtoReflect.Descriptor instead. -func (*FileStats) Descriptor() ([]byte, []int) { +// Deprecated: Use GetAllocationRequest.ProtoReflect.Descriptor instead. +func (*GetAllocationRequest) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{18} } -func (x *FileStats) GetID() int64 { - if x != nil { - return x.ID - } - return 0 -} - -func (x *FileStats) GetRefID() int64 { - if x != nil { - return x.RefID - } - return 0 -} - -func (x *FileStats) GetNumUpdates() int64 { - if x != nil { - return x.NumUpdates - } - return 0 -} - -func (x *FileStats) GetNumBlockDownloads() int64 { - if x != nil { - return x.NumBlockDownloads - } - return 0 -} - -func (x *FileStats) GetSuccessChallenges() int64 { - if x != nil { - return x.SuccessChallenges - } - return 0 -} - -func (x *FileStats) GetFailedChallenges() int64 { - if x != nil { - return x.FailedChallenges - } - return 0 -} - -func (x *FileStats) GetLastChallengeResponseTxn() string { - if x != nil { - return x.LastChallengeResponseTxn - } - return "" -} - -func (x *FileStats) GetWriteMarkerRedeemTxn() string { +func (x *GetAllocationRequest) GetId() string { if x != nil { - return x.WriteMarkerRedeemTxn + return x.Id } return "" } -func (x *FileStats) GetCreatedAt() int64 { - if x != nil { - return x.CreatedAt - } - return 0 -} - -func (x *FileStats) GetUpdatedAt() int64 { - if x != nil { - return x.UpdatedAt - } - return 0 -} - -type CommitMetaTxn struct { +type GetAllocationResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RefId int64 `protobuf:"varint,1,opt,name=RefId,proto3" json:"RefId,omitempty"` - TxnId string `protobuf:"bytes,2,opt,name=TxnId,proto3" json:"TxnId,omitempty"` - CreatedAt int64 `protobuf:"varint,3,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` + Allocation *Allocation `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` } -func (x *CommitMetaTxn) Reset() { - *x = CommitMetaTxn{} +func (x *GetAllocationResponse) Reset() { + *x = GetAllocationResponse{} if protoimpl.UnsafeEnabled { mi := &file_blobber_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1301,13 +1291,13 @@ func (x *CommitMetaTxn) Reset() { } } -func (x *CommitMetaTxn) String() string { +func (x *GetAllocationResponse) String() string { return protoimpl.X.MessageStringOf(x) } -func (*CommitMetaTxn) ProtoMessage() {} +func (*GetAllocationResponse) ProtoMessage() {} -func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { +func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { mi := &file_blobber_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1319,44 +1309,36 @@ func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use CommitMetaTxn.ProtoReflect.Descriptor instead. -func (*CommitMetaTxn) Descriptor() ([]byte, []int) { +// Deprecated: Use GetAllocationResponse.ProtoReflect.Descriptor instead. +func (*GetAllocationResponse) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{19} } -func (x *CommitMetaTxn) GetRefId() int64 { - if x != nil { - return x.RefId - } - return 0 -} - -func (x *CommitMetaTxn) GetTxnId() string { - if x != nil { - return x.TxnId - } - return "" -} - -func (x *CommitMetaTxn) GetCreatedAt() int64 { +func (x *GetAllocationResponse) GetAllocation() *Allocation { if x != nil { - return x.CreatedAt + return x.Allocation } - return 0 + return nil } -type Collaborator struct { +type DownloadFileRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RefId int64 `protobuf:"varint,1,opt,name=RefId,proto3" json:"RefId,omitempty"` - ClientId string `protobuf:"bytes,2,opt,name=ClientId,proto3" json:"ClientId,omitempty"` - CreatedAt int64 `protobuf:"varint,3,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` + Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` + Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,3,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + RxPay string `protobuf:"bytes,4,opt,name=rx_pay,json=rxPay,proto3" json:"rx_pay,omitempty"` + BlockNum string `protobuf:"bytes,5,opt,name=block_num,json=blockNum,proto3" json:"block_num,omitempty"` + NumBlocks string `protobuf:"bytes,6,opt,name=num_blocks,json=numBlocks,proto3" json:"num_blocks,omitempty"` + ReadMarker string `protobuf:"bytes,7,opt,name=read_marker,json=readMarker,proto3" json:"read_marker,omitempty"` + AuthToken string `protobuf:"bytes,8,opt,name=auth_token,json=authToken,proto3" json:"auth_token,omitempty"` + Content string `protobuf:"bytes,9,opt,name=content,proto3" json:"content,omitempty"` } -func (x *Collaborator) Reset() { - *x = Collaborator{} +func (x *DownloadFileRequest) Reset() { + *x = DownloadFileRequest{} if protoimpl.UnsafeEnabled { mi := &file_blobber_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1364,13 +1346,13 @@ func (x *Collaborator) Reset() { } } -func (x *Collaborator) String() string { +func (x *DownloadFileRequest) String() string { return protoimpl.X.MessageStringOf(x) } -func (*Collaborator) ProtoMessage() {} +func (*DownloadFileRequest) ProtoMessage() {} -func (x *Collaborator) ProtoReflect() protoreflect.Message { +func (x *DownloadFileRequest) ProtoReflect() protoreflect.Message { mi := &file_blobber_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1382,49 +1364,88 @@ func (x *Collaborator) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use Collaborator.ProtoReflect.Descriptor instead. -func (*Collaborator) Descriptor() ([]byte, []int) { +// Deprecated: Use DownloadFileRequest.ProtoReflect.Descriptor instead. +func (*DownloadFileRequest) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{20} } -func (x *Collaborator) GetRefId() int64 { +func (x *DownloadFileRequest) GetAllocation() string { if x != nil { - return x.RefId + return x.Allocation } - return 0 + return "" } -func (x *Collaborator) GetClientId() string { +func (x *DownloadFileRequest) GetPath() string { if x != nil { - return x.ClientId + return x.Path } return "" } -func (x *Collaborator) GetCreatedAt() int64 { +func (x *DownloadFileRequest) GetPathHash() string { if x != nil { - return x.CreatedAt + return x.PathHash } - return 0 + return "" } -type WriteMarker struct { +func (x *DownloadFileRequest) GetRxPay() string { + if x != nil { + return x.RxPay + } + return "" +} + +func (x *DownloadFileRequest) GetBlockNum() string { + if x != nil { + return x.BlockNum + } + return "" +} + +func (x *DownloadFileRequest) GetNumBlocks() string { + if x != nil { + return x.NumBlocks + } + return "" +} + +func (x *DownloadFileRequest) GetReadMarker() string { + if x != nil { + return x.ReadMarker + } + return "" +} + +func (x *DownloadFileRequest) GetAuthToken() string { + if x != nil { + return x.AuthToken + } + return "" +} + +func (x *DownloadFileRequest) GetContent() string { + if x != nil { + return x.Content + } + return "" +} + +type DownloadFileResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` - PreviousAllocationRoot string `protobuf:"bytes,2,opt,name=PreviousAllocationRoot,proto3" json:"PreviousAllocationRoot,omitempty"` - AllocationID string `protobuf:"bytes,3,opt,name=AllocationID,proto3" json:"AllocationID,omitempty"` - Size int64 `protobuf:"varint,4,opt,name=Size,proto3" json:"Size,omitempty"` - BlobberID string `protobuf:"bytes,5,opt,name=BlobberID,proto3" json:"BlobberID,omitempty"` - Timestamp int64 `protobuf:"varint,6,opt,name=Timestamp,proto3" json:"Timestamp,omitempty"` - ClientID string `protobuf:"bytes,7,opt,name=ClientID,proto3" json:"ClientID,omitempty"` - Signature string `protobuf:"bytes,8,opt,name=Signature,proto3" json:"Signature,omitempty"` + Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"` + Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` + AllocationId string `protobuf:"bytes,3,opt,name=allocation_id,json=allocationId,proto3" json:"allocation_id,omitempty"` + Path string `protobuf:"bytes,4,opt,name=path,proto3" json:"path,omitempty"` + LatestRm *ReadMaker `protobuf:"bytes,5,opt,name=latest_rm,json=latestRm,proto3" json:"latest_rm,omitempty"` } -func (x *WriteMarker) Reset() { - *x = WriteMarker{} +func (x *DownloadFileResponse) Reset() { + *x = DownloadFileResponse{} if protoimpl.UnsafeEnabled { mi := &file_blobber_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1432,13 +1453,13 @@ func (x *WriteMarker) Reset() { } } -func (x *WriteMarker) String() string { +func (x *DownloadFileResponse) String() string { return protoimpl.X.MessageStringOf(x) } -func (*WriteMarker) ProtoMessage() {} +func (*DownloadFileResponse) ProtoMessage() {} -func (x *WriteMarker) ProtoReflect() protoreflect.Message { +func (x *DownloadFileResponse) ProtoReflect() protoreflect.Message { mi := &file_blobber_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1450,65 +1471,44 @@ func (x *WriteMarker) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use WriteMarker.ProtoReflect.Descriptor instead. -func (*WriteMarker) Descriptor() ([]byte, []int) { +// Deprecated: Use DownloadFileResponse.ProtoReflect.Descriptor instead. +func (*DownloadFileResponse) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{21} } -func (x *WriteMarker) GetAllocationRoot() string { - if x != nil { - return x.AllocationRoot - } - return "" -} - -func (x *WriteMarker) GetPreviousAllocationRoot() string { - if x != nil { - return x.PreviousAllocationRoot - } - return "" -} - -func (x *WriteMarker) GetAllocationID() string { +func (x *DownloadFileResponse) GetSuccess() bool { if x != nil { - return x.AllocationID + return x.Success } - return "" + return false } -func (x *WriteMarker) GetSize() int64 { +func (x *DownloadFileResponse) GetData() []byte { if x != nil { - return x.Size + return x.Data } - return 0 + return nil } -func (x *WriteMarker) GetBlobberID() string { +func (x *DownloadFileResponse) GetAllocationId() string { if x != nil { - return x.BlobberID + return x.AllocationId } return "" } -func (x *WriteMarker) GetTimestamp() int64 { - if x != nil { - return x.Timestamp - } - return 0 -} - -func (x *WriteMarker) GetClientID() string { +func (x *DownloadFileResponse) GetPath() string { if x != nil { - return x.ClientID + return x.Path } return "" } -func (x *WriteMarker) GetSignature() string { +func (x *DownloadFileResponse) GetLatestRm() *ReadMaker { if x != nil { - return x.Signature + return x.LatestRm } - return "" + return nil } type ReadMaker struct { @@ -2343,191 +2343,191 @@ var file_blobber_proto_rawDesc = []byte{ 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, - 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, - 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, - 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, - 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, - 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, - 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, - 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, - 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, - 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, - 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, - 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, - 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, - 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, + 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, + 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, + 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, + 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, + 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, + 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, + 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, + 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, - 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, - 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, - 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, - 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, - 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, - 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, + 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, + 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, + 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, + 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, + 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, + 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, + 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, + 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, + 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, + 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, + 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, + 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, + 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, + 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, + 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, + 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, + 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, + 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, + 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, + 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, - 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, - 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, - 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, - 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, - 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, - 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, - 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, - 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x93, 0x02, 0x0a, 0x13, 0x44, 0x6f, - 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, + 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, - 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x15, 0x0a, 0x06, 0x72, 0x78, 0x5f, 0x70, 0x61, 0x79, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x05, 0x72, 0x78, 0x50, 0x61, 0x79, 0x12, 0x1b, 0x0a, 0x09, 0x62, 0x6c, 0x6f, - 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x6c, - 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x12, 0x1d, 0x0a, 0x0a, 0x6e, 0x75, 0x6d, 0x5f, 0x62, 0x6c, - 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x6e, 0x75, 0x6d, 0x42, - 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1f, 0x0a, 0x0b, 0x72, 0x65, 0x61, 0x64, 0x5f, 0x6d, 0x61, - 0x72, 0x6b, 0x65, 0x72, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x72, 0x65, 0x61, 0x64, - 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, - 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, - 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, - 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x22, - 0xb9, 0x01, 0x0a, 0x14, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x63, 0x63, - 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, - 0x73, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, - 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x70, - 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, - 0x3a, 0x0a, 0x09, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x72, 0x6d, 0x18, 0x05, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x6b, 0x65, - 0x72, 0x52, 0x08, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x6d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, + 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, + 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, + 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, + 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, + 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, + 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, + 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, + 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, + 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, + 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, + 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, + 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, + 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, + 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, + 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, + 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, + 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, + 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, + 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, + 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, + 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, + 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, + 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, + 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, + 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, + 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, + 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, + 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x93, 0x02, 0x0a, 0x13, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, + 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, + 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, + 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x15, + 0x0a, 0x06, 0x72, 0x78, 0x5f, 0x70, 0x61, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, + 0x72, 0x78, 0x50, 0x61, 0x79, 0x12, 0x1b, 0x0a, 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, + 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, + 0x75, 0x6d, 0x12, 0x1d, 0x0a, 0x0a, 0x6e, 0x75, 0x6d, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x73, + 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x6e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x73, 0x12, 0x1f, 0x0a, 0x0b, 0x72, 0x65, 0x61, 0x64, 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, + 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x72, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x72, 0x6b, + 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, + 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, + 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x22, 0xb9, 0x01, 0x0a, 0x14, + 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x12, 0x12, + 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, + 0x74, 0x61, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x3a, 0x0a, 0x09, 0x6c, + 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x72, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0xe7, 0x01, 0x0a, - 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, - 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, - 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, - 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, - 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, - 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, - 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, - 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, - 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, - 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, - 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, - 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, - 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, - 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, - 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, - 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, - 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, - 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, - 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, - 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, - 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, - 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, - 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x59, - 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, - 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, - 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, - 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, - 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, - 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, - 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, - 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, - 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, - 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, - 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0xdf, 0x02, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, + 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x6c, + 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x6d, 0x22, 0xdf, 0x02, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x6b, 0x65, 0x72, 0x12, 0x1b, 0x0a, 0x09, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x2a, 0x0a, 0x11, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x70, 0x75, 0x62, @@ -2742,7 +2742,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, 0x6c, + 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x64, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, @@ -2768,24 +2768,24 @@ var file_blobber_proto_goTypes = []interface{}{ (*GetObjectTreeResponse)(nil), // 1: blobber.service.v1.GetObjectTreeResponse (*GetReferencePathRequest)(nil), // 2: blobber.service.v1.GetReferencePathRequest (*GetReferencePathResponse)(nil), // 3: blobber.service.v1.GetReferencePathResponse - (*GetObjectPathRequest)(nil), // 4: blobber.service.v1.GetObjectPathRequest - (*GetObjectPathResponse)(nil), // 5: blobber.service.v1.GetObjectPathResponse - (*ListEntitiesRequest)(nil), // 6: blobber.service.v1.ListEntitiesRequest - (*ListEntitiesResponse)(nil), // 7: blobber.service.v1.ListEntitiesResponse - (*GetFileStatsRequest)(nil), // 8: blobber.service.v1.GetFileStatsRequest - (*GetFileStatsResponse)(nil), // 9: blobber.service.v1.GetFileStatsResponse - (*GetFileMetaDataRequest)(nil), // 10: blobber.service.v1.GetFileMetaDataRequest - (*GetFileMetaDataResponse)(nil), // 11: blobber.service.v1.GetFileMetaDataResponse - (*GetAllocationRequest)(nil), // 12: blobber.service.v1.GetAllocationRequest - (*GetAllocationResponse)(nil), // 13: blobber.service.v1.GetAllocationResponse - (*DownloadFileRequest)(nil), // 14: blobber.service.v1.DownloadFileRequest - (*DownloadFileResponse)(nil), // 15: blobber.service.v1.DownloadFileResponse - (*ReferencePath)(nil), // 16: blobber.service.v1.ReferencePath - (*ObjectPath)(nil), // 17: blobber.service.v1.ObjectPath - (*FileStats)(nil), // 18: blobber.service.v1.FileStats - (*CommitMetaTxn)(nil), // 19: blobber.service.v1.CommitMetaTxn - (*Collaborator)(nil), // 20: blobber.service.v1.Collaborator - (*WriteMarker)(nil), // 21: blobber.service.v1.WriteMarker + (*ReferencePath)(nil), // 4: blobber.service.v1.ReferencePath + (*GetObjectPathRequest)(nil), // 5: blobber.service.v1.GetObjectPathRequest + (*GetObjectPathResponse)(nil), // 6: blobber.service.v1.GetObjectPathResponse + (*ObjectPath)(nil), // 7: blobber.service.v1.ObjectPath + (*WriteMarker)(nil), // 8: blobber.service.v1.WriteMarker + (*ListEntitiesRequest)(nil), // 9: blobber.service.v1.ListEntitiesRequest + (*ListEntitiesResponse)(nil), // 10: blobber.service.v1.ListEntitiesResponse + (*GetFileStatsRequest)(nil), // 11: blobber.service.v1.GetFileStatsRequest + (*GetFileStatsResponse)(nil), // 12: blobber.service.v1.GetFileStatsResponse + (*FileStats)(nil), // 13: blobber.service.v1.FileStats + (*GetFileMetaDataRequest)(nil), // 14: blobber.service.v1.GetFileMetaDataRequest + (*GetFileMetaDataResponse)(nil), // 15: blobber.service.v1.GetFileMetaDataResponse + (*CommitMetaTxn)(nil), // 16: blobber.service.v1.CommitMetaTxn + (*Collaborator)(nil), // 17: blobber.service.v1.Collaborator + (*GetAllocationRequest)(nil), // 18: blobber.service.v1.GetAllocationRequest + (*GetAllocationResponse)(nil), // 19: blobber.service.v1.GetAllocationResponse + (*DownloadFileRequest)(nil), // 20: blobber.service.v1.DownloadFileRequest + (*DownloadFileResponse)(nil), // 21: blobber.service.v1.DownloadFileResponse (*ReadMaker)(nil), // 22: blobber.service.v1.ReadMaker (*Allocation)(nil), // 23: blobber.service.v1.Allocation (*Term)(nil), // 24: blobber.service.v1.Term @@ -2794,45 +2794,45 @@ var file_blobber_proto_goTypes = []interface{}{ (*DirMetaData)(nil), // 27: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ - 16, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 21, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 16, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 21, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 17, // 4: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath - 21, // 5: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 25, // 6: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 25, // 7: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 25, // 8: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef - 18, // 9: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 25, // 10: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef - 20, // 11: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 23, // 12: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 22, // 13: blobber.service.v1.DownloadFileResponse.latest_rm:type_name -> blobber.service.v1.ReadMaker - 25, // 14: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef - 16, // 15: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath - 25, // 16: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 25, // 17: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 25, // 18: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 4, // 0: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 8, // 1: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 4, // 2: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 8, // 3: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 25, // 4: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 4, // 5: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath + 7, // 6: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath + 8, // 7: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker + 25, // 8: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 25, // 9: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 25, // 10: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 25, // 11: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 25, // 12: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 25, // 13: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 13, // 14: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats + 25, // 15: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 17, // 16: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 23, // 17: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 22, // 18: blobber.service.v1.DownloadFileResponse.latest_rm:type_name -> blobber.service.v1.ReadMaker 24, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term 26, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData 27, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 19, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 12, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 10, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 8, // 25: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 6, // 26: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 4, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 16, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 18, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 14, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 11, // 25: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 9, // 26: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 5, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest 2, // 28: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest 0, // 29: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 14, // 30: blobber.service.v1.Blobber.DownloadFile:input_type -> blobber.service.v1.DownloadFileRequest - 13, // 31: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 11, // 32: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 9, // 33: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 7, // 34: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 5, // 35: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 20, // 30: blobber.service.v1.Blobber.DownloadFile:input_type -> blobber.service.v1.DownloadFileRequest + 19, // 31: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 15, // 32: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 12, // 33: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 10, // 34: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 6, // 35: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse 3, // 36: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse 1, // 37: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 15, // 38: blobber.service.v1.Blobber.DownloadFile:output_type -> blobber.service.v1.DownloadFileResponse + 21, // 38: blobber.service.v1.Blobber.DownloadFile:output_type -> blobber.service.v1.DownloadFileResponse 31, // [31:39] is the sub-list for method output_type 23, // [23:31] is the sub-list for method input_type 23, // [23:23] is the sub-list for extension type_name @@ -2895,7 +2895,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathRequest); i { + switch v := v.(*ReferencePath); i { case 0: return &v.state case 1: @@ -2907,7 +2907,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathResponse); i { + switch v := v.(*GetObjectPathRequest); i { case 0: return &v.state case 1: @@ -2919,7 +2919,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesRequest); i { + switch v := v.(*GetObjectPathResponse); i { case 0: return &v.state case 1: @@ -2931,7 +2931,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesResponse); i { + switch v := v.(*ObjectPath); i { case 0: return &v.state case 1: @@ -2943,7 +2943,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsRequest); i { + switch v := v.(*WriteMarker); i { case 0: return &v.state case 1: @@ -2955,7 +2955,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsResponse); i { + switch v := v.(*ListEntitiesRequest); i { case 0: return &v.state case 1: @@ -2967,7 +2967,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataRequest); i { + switch v := v.(*ListEntitiesResponse); i { case 0: return &v.state case 1: @@ -2979,7 +2979,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataResponse); i { + switch v := v.(*GetFileStatsRequest); i { case 0: return &v.state case 1: @@ -2991,7 +2991,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationRequest); i { + switch v := v.(*GetFileStatsResponse); i { case 0: return &v.state case 1: @@ -3003,7 +3003,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationResponse); i { + switch v := v.(*FileStats); i { case 0: return &v.state case 1: @@ -3015,7 +3015,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DownloadFileRequest); i { + switch v := v.(*GetFileMetaDataRequest); i { case 0: return &v.state case 1: @@ -3027,7 +3027,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DownloadFileResponse); i { + switch v := v.(*GetFileMetaDataResponse); i { case 0: return &v.state case 1: @@ -3039,7 +3039,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReferencePath); i { + switch v := v.(*CommitMetaTxn); i { case 0: return &v.state case 1: @@ -3051,7 +3051,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ObjectPath); i { + switch v := v.(*Collaborator); i { case 0: return &v.state case 1: @@ -3063,7 +3063,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileStats); i { + switch v := v.(*GetAllocationRequest); i { case 0: return &v.state case 1: @@ -3075,7 +3075,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CommitMetaTxn); i { + switch v := v.(*GetAllocationResponse); i { case 0: return &v.state case 1: @@ -3087,7 +3087,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Collaborator); i { + switch v := v.(*DownloadFileRequest); i { case 0: return &v.state case 1: @@ -3099,7 +3099,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*WriteMarker); i { + switch v := v.(*DownloadFileResponse); i { case 0: return &v.state case 1: diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 54adaa1cd..609ce9fe0 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -964,7 +964,7 @@ var ( pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) - pattern_Blobber_DownloadFile_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v1", "file", "download", "allocation"}, "")) + pattern_Blobber_DownloadFile_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "download", "allocation"}, "")) ) var ( diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index a87982c58..7b6b2bf28 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -44,7 +44,7 @@ service Blobber { } rpc DownloadFile(DownloadFileRequest) returns (DownloadFileResponse) { option (google.api.http) = { - post: "/v1/file/download/{allocation}" + post: "/v2/file/download/{allocation}" body: "*" }; } @@ -69,6 +69,11 @@ message GetReferencePathResponse { WriteMarker LatestWM = 2; } +message ReferencePath { + FileRef MetaData = 1; + repeated ReferencePath List = 2; +} + message GetObjectPathRequest { string allocation = 1; string Path = 2; @@ -79,12 +84,32 @@ message GetObjectPathResponse { WriteMarker LatestWriteMarker = 2; } +message ObjectPath { + string RootHash = 1; + FileRef Meta = 2; + FileRef Path = 3; + repeated FileRef PathList = 4; + int64 FileBlockNum = 5; +} + +message WriteMarker { + string AllocationRoot = 1; + string PreviousAllocationRoot = 2; + string AllocationID = 3; + int64 Size = 4; + string BlobberID = 5; + int64 Timestamp = 6; + string ClientID = 7; + string Signature = 8; +} + message ListEntitiesRequest { string path = 1; string path_hash = 2; string auth_token = 3; string allocation = 4; } + message ListEntitiesResponse { string AllocationRoot = 1; FileRef MetaData = 2; @@ -96,25 +121,53 @@ message GetFileStatsRequest { string path_hash = 2; string allocation = 3; } + message GetFileStatsResponse { FileRef MetaData = 1; FileStats Stats = 2; } +message FileStats { + int64 ID = 1; + int64 RefID = 2; + int64 NumUpdates = 3; + int64 NumBlockDownloads = 4; + int64 SuccessChallenges = 5; + int64 FailedChallenges = 6; + string LastChallengeResponseTxn = 7; + string WriteMarkerRedeemTxn = 8; + int64 CreatedAt = 9; + int64 UpdatedAt = 10; +} + message GetFileMetaDataRequest { string path = 1; string path_hash = 2; string auth_token = 3; string allocation = 4; } + message GetFileMetaDataResponse { FileRef MetaData = 1; repeated Collaborator Collaborators = 2; } +message CommitMetaTxn { + int64 RefId = 1; + string TxnId = 2; + int64 CreatedAt = 3; +} + +message Collaborator { + int64 RefId = 1; + string ClientId = 2; + int64 CreatedAt = 3; +} + message GetAllocationRequest { string id = 1; } + message GetAllocationResponse { Allocation allocation = 1; } @@ -138,55 +191,6 @@ message DownloadFileResponse { ReadMaker latest_rm = 5; } -message ReferencePath { - FileRef MetaData = 1; - repeated ReferencePath List = 2; -} - -message ObjectPath { - string RootHash = 1; - FileRef Meta = 2; - FileRef Path = 3; - repeated FileRef PathList = 4; - int64 FileBlockNum = 5; -} - -message FileStats { - int64 ID = 1; - int64 RefID = 2; - int64 NumUpdates = 3; - int64 NumBlockDownloads = 4; - int64 SuccessChallenges = 5; - int64 FailedChallenges = 6; - string LastChallengeResponseTxn = 7; - string WriteMarkerRedeemTxn = 8; - int64 CreatedAt = 9; - int64 UpdatedAt = 10; -} - -message CommitMetaTxn { - int64 RefId = 1; - string TxnId = 2; - int64 CreatedAt = 3; -} - -message Collaborator { - int64 RefId = 1; - string ClientId = 2; - int64 CreatedAt = 3; -} - -message WriteMarker { - string AllocationRoot = 1; - string PreviousAllocationRoot = 2; - string AllocationID = 3; - int64 Size = 4; - string BlobberID = 5; - int64 Timestamp = 6; - string ClientID = 7; - string Signature = 8; -} - message ReadMaker { string client_id = 1; string client_public_key = 2; diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 26b5c0dfc..c8f3415b7 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -38,8 +38,7 @@ func SetupHandlers(r *mux.Router) { //object operations r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) - r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common. - ToByteStream(WithConnection(DownloadHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler(svc))))).Methods(http.MethodPost) r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index 13cc86081..2210e1ba5 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -45,8 +45,8 @@ type PackageHandler interface { GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) // write readmeker interface separately and add these two methods - GetNewReadMaker(rm *readmarker.ReadMarker) readmarker.ReadMakerI - GetLatestReadMarkerEntity(ctx context.Context, clientID string) (readmarker.ReadMakerI, error) + GetLatestReadMarkerEntity(ctx context.Context, clientID string) (*readmarker.ReadMarkerEntity, error) + VerifyReadMarker(ctx context.Context, readMake *readmarker.ReadMarkerEntity, alloc *allocation.Allocation) error SaveLatestReadMarker(ctx context.Context, rm *readmarker.ReadMarker, isCreate bool) error // write FileStat related methods in a different interface GetFileStore() filestore.FileStore @@ -101,7 +101,7 @@ func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clien } func (r *packageHandler) GetLatestReadMarkerEntity(ctx context.Context, clientID string) ( - readmarker.ReadMakerI, error) { + *readmarker.ReadMarkerEntity, error) { return readmarker.GetLatestReadMarkerEntity(ctx, clientID) } @@ -118,6 +118,11 @@ func (r *packageHandler) FileBlockDownloaded(ctx context.Context, refID int64) { stats.FileBlockDownloaded(ctx, refID) } -func (r *packageHandler) GetNewReadMaker(rm *readmarker.ReadMarker) readmarker.ReadMakerI { - return readmarker.NewReadMakerEntity(rm) +func (r *packageHandler) VerifyReadMarker(ctx context.Context, readMake *readmarker.ReadMarkerEntity, alloc *allocation.Allocation) error { + return readMake.VerifyMarker(ctx, alloc) } + +// +//func (r *packageHandler) GetNewReadMaker(rm *readmarker.ReadMarker) readmarker.ReadMakerI { +// return readmarker.NewReadMakerEntity(rm) +//} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index 9ad6e9beb..d7b27ab87 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -15,23 +15,22 @@ import ( "strconv" ) -func (b *blobberGRPCService) DownloadFile(ctx context.Context, r *blobbergrpc.DownloadFileRequest) ( - *blobbergrpc.DownloadFileResponse, error) { +func (b *blobberGRPCService) DownloadFile(ctx context.Context, r *blobbergrpc.DownloadFileRequest) (*blobbergrpc.DownloadFileResponse, error) { + md := GetGRPCMetaDataFromCtx(ctx) + ctx = setupGRPCHandlerContext(ctx, md, r.Allocation) + + clientID := md.Client + if len(clientID) == 0 { + return nil, common.NewError("download_file", "invalid client") + } allocationTx := r.Allocation allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) if err != nil { return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) } - - md := GetGRPCMetaDataFromCtx(ctx) - valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) - if !valid || err != nil { - return nil, common.NewError("invalid_signature", "Invalid signature") - } var allocationID = allocationObj.ID - clientID := md.Client if len(clientID) == 0 || allocationObj.OwnerID != clientID { return nil, common.NewError( "invalid_operation", "Operation needs to be performed by the owner of the allocation") @@ -81,9 +80,10 @@ func (b *blobberGRPCService) DownloadFile(ctx context.Context, r *blobbergrpc.Do "error parsing the readmarker for download: %v", err) } - var rmObj = b.packageHandler.GetNewReadMaker(readMarker) + var rmObj = &readmarker.ReadMarkerEntity{} + rmObj.LatestRM = readMarker - if err = rmObj.VerifyMarker(ctx, allocationObj); err != nil { + if err = b.packageHandler.VerifyReadMarker(ctx, rmObj, allocationObj); err != nil { return nil, common.NewErrorf("download_file", "invalid read marker, "+ "failed to verify the read marker: %v", err) } @@ -149,7 +149,7 @@ func (b *blobberGRPCService) DownloadFile(ctx context.Context, r *blobbergrpc.Do } var ( - rme readmarker.ReadMakerI + rme *readmarker.ReadMarkerEntity latestRM *readmarker.ReadMarker pendNumBlocks int64 ) @@ -160,7 +160,7 @@ func (b *blobberGRPCService) DownloadFile(ctx context.Context, r *blobbergrpc.Do } if rme != nil { - latestRM = rme.GetLatestRM() + latestRM = rme.LatestRM if pendNumBlocks, err = rme.PendNumBlocks(); err != nil { return nil, common.NewErrorf("download_file", "couldn't get number of blocks pending redeeming: %v", err) diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go deleted file mode 100644 index abeebd162..000000000 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go +++ /dev/null @@ -1 +0,0 @@ -package handler diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go index dac353f78..7a97bacc8 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -2,6 +2,7 @@ package handler import ( "context" + "encoding/json" "errors" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" @@ -21,6 +22,7 @@ func TestBlobberGRPCService_DownloadFile_Success(t *testing.T) { allocationTx := randString(32) pubKey, _, signScheme := GeneratePubPrivateKey(t) clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + req := &blobbergrpc.DownloadFileRequest{ Allocation: allocationTx, Path: `path`, @@ -37,6 +39,7 @@ func TestBlobberGRPCService_DownloadFile_Success(t *testing.T) { common.ClientKeyHeader: "client_key", common.ClientSignatureHeader: clientSignature, })) + ctx = setupGRPCHandlerContext(ctx, GetGRPCMetaDataFromCtx(ctx), req.Allocation) alloc := &allocation.Allocation{ Tx: req.Allocation, @@ -45,27 +48,34 @@ func TestBlobberGRPCService_DownloadFile_Success(t *testing.T) { OwnerPublicKey: pubKey, } - mockReadMaker := &mocks.ReadMakerI{} - mockReadMaker.On(`VerifyMarker`, mock.Anything, alloc).Return(nil) - var pentBlocksNum = int64(10) + rm := &readmarker.ReadMarker{ + AllocationID: alloc.ID, + ClientPublicKey: `client_key`, + ClientID: `client`, + Signature: clientSignature, + OwnerID: alloc.OwnerID, + } + rmStr, _ := json.Marshal(rm) + req.ReadMarker = string(rmStr) + + //var pentBlocksNum = int64(10) var latestRm = &readmarker.ReadMarker{} - mockReadMaker.On(`PendNumBlocks`).Return(pentBlocksNum, nil) - mockReadMaker.On(`GetLatestRM`).Return(latestRm, nil) mockStorageHandler := &storageHandlerI{} mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). Return(alloc, nil) - mockStorageHandler.On(`readPreRedeem`, mock.Anything, alloc, 5, pentBlocksNum, alloc.OwnerID).Return( + mockStorageHandler.On(`readPreRedeem`, mock.Anything, alloc, int64(5), int64(0), alloc.OwnerID).Return( nil) mockFileStore := &mocks.FileStore{} - mockFileStore.On(`GetFileBlock`, req.Allocation, mock.Anything, req.BlockNum, req.NumBlocks).Return( + mockFileStore.On(`GetFileBlock`, alloc.ID, mock.Anything, int64(5), int64(5)).Return( []byte{}, nil) - mockReferencePackage := &mocks.PackageHandler{} pathHash := req.Allocation + `:` + req.Path mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). Return(pathHash) + mockReferencePackage.On(`VerifyReadMarker`, mock.Anything, mock.Anything, alloc). + Return(nil) objectRef := &reference.Ref{ Name: "test", @@ -76,19 +86,24 @@ func TestBlobberGRPCService_DownloadFile_Success(t *testing.T) { Type: reference.FILE, } + rme := &readmarker.ReadMarkerEntity{ + RedeemRequired: false, + LatestRM: latestRm, + } + mockReferencePackage.On(`GetReferenceFromLookupHash`, mock.Anything, alloc.ID, pathHash). Return(objectRef, nil) mockReferencePackage.On(`IsACollaborator`, mock.Anything, objectRef.ID, alloc.OwnerID). Return(true) mockReferencePackage.On(`GetLatestReadMarkerEntity`, mock.Anything, alloc.OwnerID). - Return(mockReadMaker, nil) + Return(rme, nil) mockReferencePackage.On(`GetFileStore`). Return(mockFileStore) mockReferencePackage.On(`SaveLatestReadMarker`, mock.Anything, mock.Anything, false). Return(nil) mockReferencePackage.On(`FileBlockDownloaded`, mock.Anything, objectRef.ID). Return() - mockReferencePackage.On(`GetNewReadMaker`, mock.Anything).Return(mockReadMaker) + mockReferencePackage.On(`GetNewReadMaker`, mock.Anything).Return(rme) resOk := &blobbergrpc.DownloadFileResponse{ Success: false, diff --git a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go b/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go deleted file mode 100644 index 37556727b..000000000 --- a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go +++ /dev/null @@ -1,148 +0,0 @@ -// Code generated by mockery 2.7.5. DO NOT EDIT. - -package mocks - -import ( - context "context" - - allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - - mock "github.com/stretchr/testify/mock" -) - -// IAllocationChangeCollector is an autogenerated mock type for the IAllocationChangeCollector type -type IAllocationChangeCollector struct { - mock.Mock -} - -// AddChange provides a mock function with given fields: allocationChange, changeProcessor -func (_m *IAllocationChangeCollector) AddChange(allocationChange *allocation.AllocationChange, changeProcessor allocation.AllocationChangeProcessor) { - _m.Called(allocationChange, changeProcessor) -} - -// ApplyChanges provides a mock function with given fields: ctx, allocationRoot -func (_m *IAllocationChangeCollector) ApplyChanges(ctx context.Context, allocationRoot string) error { - ret := _m.Called(ctx, allocationRoot) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, string) error); ok { - r0 = rf(ctx, allocationRoot) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// CommitToFileStore provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) CommitToFileStore(ctx context.Context) error { - ret := _m.Called(ctx) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context) error); ok { - r0 = rf(ctx) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// ComputeProperties provides a mock function with given fields: -func (_m *IAllocationChangeCollector) ComputeProperties() { - _m.Called() -} - -// DeleteChanges provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) DeleteChanges(ctx context.Context) { - _m.Called(ctx) -} - -// GetAllocationID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetAllocationID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetClientID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetClientID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetConnectionID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetConnectionID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetSize provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetSize() int64 { - ret := _m.Called() - - var r0 int64 - if rf, ok := ret.Get(0).(func() int64); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(int64) - } - - return r0 -} - -// Save provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) Save(ctx context.Context) error { - ret := _m.Called(ctx) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context) error); ok { - r0 = rf(ctx) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// SetSize provides a mock function with given fields: size -func (_m *IAllocationChangeCollector) SetSize(size int64) { - _m.Called(size) -} - -// TableName provides a mock function with given fields: -func (_m *IAllocationChangeCollector) TableName() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go deleted file mode 100644 index 9644d5125..000000000 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ /dev/null @@ -1,333 +0,0 @@ -// Code generated by mockery 2.7.5. DO NOT EDIT. - -package mocks - -import ( - context "context" - - filestore "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" - - mock "github.com/stretchr/testify/mock" - - readmarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" - - reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - - stats "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" - - writemarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" -) - -// PackageHandler is an autogenerated mock type for the PackageHandler type -type PackageHandler struct { - mock.Mock -} - -// FileBlockDownloaded provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) FileBlockDownloaded(ctx context.Context, refID int64) { - _m.Called(ctx, refID) -} - -// GetCollaborators provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { - ret := _m.Called(ctx, refID) - - var r0 []reference.Collaborator - if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.Collaborator); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]reference.Collaborator) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetCommitMetaTxns provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) { - ret := _m.Called(ctx, refID) - - var r0 []reference.CommitMetaTxn - if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.CommitMetaTxn); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]reference.CommitMetaTxn) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetFileStats provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) { - ret := _m.Called(ctx, refID) - - var r0 *stats.FileStats - if rf, ok := ret.Get(0).(func(context.Context, int64) *stats.FileStats); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*stats.FileStats) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetFileStore provides a mock function with given fields: -func (_m *PackageHandler) GetFileStore() filestore.FileStore { - ret := _m.Called() - - var r0 filestore.FileStore - if rf, ok := ret.Get(0).(func() filestore.FileStore); ok { - r0 = rf() - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(filestore.FileStore) - } - } - - return r0 -} - -// GetLatestReadMarkerEntity provides a mock function with given fields: ctx, clientID -func (_m *PackageHandler) GetLatestReadMarkerEntity(ctx context.Context, clientID string) (readmarker.ReadMakerI, error) { - ret := _m.Called(ctx, clientID) - - var r0 readmarker.ReadMakerI - if rf, ok := ret.Get(0).(func(context.Context, string) readmarker.ReadMakerI); ok { - r0 = rf(ctx, clientID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(readmarker.ReadMakerI) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string) error); ok { - r1 = rf(ctx, clientID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetNewReadMaker provides a mock function with given fields: rm -func (_m *PackageHandler) GetNewReadMaker(rm *readmarker.ReadMarker) readmarker.ReadMakerI { - ret := _m.Called(rm) - - var r0 readmarker.ReadMakerI - if rf, ok := ret.Get(0).(func(*readmarker.ReadMarker) readmarker.ReadMakerI); ok { - r0 = rf(rm) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(readmarker.ReadMakerI) - } - } - - return r0 -} - -// GetObjectPath provides a mock function with given fields: ctx, allocationID, blockNum -func (_m *PackageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { - ret := _m.Called(ctx, allocationID, blockNum) - - var r0 *reference.ObjectPath - if rf, ok := ret.Get(0).(func(context.Context, string, int64) *reference.ObjectPath); ok { - r0 = rf(ctx, allocationID, blockNum) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.ObjectPath) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, int64) error); ok { - r1 = rf(ctx, allocationID, blockNum) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetObjectTree provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetRefWithChildren provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetReferenceFromLookupHash provides a mock function with given fields: ctx, allocationID, path_hash -func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path_hash) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path_hash) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path_hash) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetReferenceLookup provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { - ret := _m.Called(ctx, allocationID, path) - - var r0 string - if rf, ok := ret.Get(0).(func(context.Context, string, string) string); ok { - r0 = rf(ctx, allocationID, path) - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetReferencePathFromPaths provides a mock function with given fields: ctx, allocationID, paths -func (_m *PackageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, paths) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, []string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, paths) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, []string) error); ok { - r1 = rf(ctx, allocationID, paths) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetWriteMarkerEntity provides a mock function with given fields: ctx, allocation_root -func (_m *PackageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_root string) (*writemarker.WriteMarkerEntity, error) { - ret := _m.Called(ctx, allocation_root) - - var r0 *writemarker.WriteMarkerEntity - if rf, ok := ret.Get(0).(func(context.Context, string) *writemarker.WriteMarkerEntity); ok { - r0 = rf(ctx, allocation_root) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*writemarker.WriteMarkerEntity) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string) error); ok { - r1 = rf(ctx, allocation_root) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// IsACollaborator provides a mock function with given fields: ctx, refID, clientID -func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { - ret := _m.Called(ctx, refID, clientID) - - var r0 bool - if rf, ok := ret.Get(0).(func(context.Context, int64, string) bool); ok { - r0 = rf(ctx, refID, clientID) - } else { - r0 = ret.Get(0).(bool) - } - - return r0 -} - -// SaveLatestReadMarker provides a mock function with given fields: ctx, rm, isCreate -func (_m *PackageHandler) SaveLatestReadMarker(ctx context.Context, rm *readmarker.ReadMarker, isCreate bool) error { - ret := _m.Called(ctx, rm, isCreate) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *readmarker.ReadMarker, bool) error); ok { - r0 = rf(ctx, rm, isCreate) - } else { - r0 = ret.Error(0) - } - - return r0 -} diff --git a/code/go/0chain.net/blobbercore/mocks/ReadMakerI.go b/code/go/0chain.net/blobbercore/mocks/ReadMakerI.go deleted file mode 100644 index cccb06a89..000000000 --- a/code/go/0chain.net/blobbercore/mocks/ReadMakerI.go +++ /dev/null @@ -1,69 +0,0 @@ -// Code generated by mockery 2.7.5. DO NOT EDIT. - -package mocks - -import ( - context "context" - - allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - - mock "github.com/stretchr/testify/mock" - - readmarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" -) - -// ReadMakerI is an autogenerated mock type for the ReadMakerI type -type ReadMakerI struct { - mock.Mock -} - -// GetLatestRM provides a mock function with given fields: -func (_m *ReadMakerI) GetLatestRM() *readmarker.ReadMarker { - ret := _m.Called() - - var r0 *readmarker.ReadMarker - if rf, ok := ret.Get(0).(func() *readmarker.ReadMarker); ok { - r0 = rf() - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*readmarker.ReadMarker) - } - } - - return r0 -} - -// PendNumBlocks provides a mock function with given fields: -func (_m *ReadMakerI) PendNumBlocks() (int64, error) { - ret := _m.Called() - - var r0 int64 - if rf, ok := ret.Get(0).(func() int64); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(int64) - } - - var r1 error - if rf, ok := ret.Get(1).(func() error); ok { - r1 = rf() - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// VerifyMarker provides a mock function with given fields: ctx, sa -func (_m *ReadMakerI) VerifyMarker(ctx context.Context, sa *allocation.Allocation) error { - ret := _m.Called(ctx, sa) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *allocation.Allocation) error); ok { - r0 = rf(ctx, sa) - } else { - r0 = ret.Error(0) - } - - return r0 -} diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 8b868a1fd..65e08c8b4 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -16,14 +16,14 @@ "application/json" ], "paths": { - "/v1/file/download/{allocation}": { - "post": { - "operationId": "Blobber_DownloadFile", + "/v2/allocation": { + "get": { + "operationId": "Blobber_GetAllocation", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1DownloadFileResponse" + "$ref": "#/definitions/v1GetAllocationResponse" } }, "default": { @@ -35,18 +35,10 @@ }, "parameters": [ { - "name": "allocation", - "in": "path", - "required": true, + "name": "id", + "in": "query", + "required": false, "type": "string" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/v1DownloadFileRequest" - } } ], "tags": [ @@ -54,14 +46,14 @@ ] } }, - "/v2/allocation": { - "get": { - "operationId": "Blobber_GetAllocation", + "/v2/file/download/{allocation}": { + "post": { + "operationId": "Blobber_DownloadFile", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1GetAllocationResponse" + "$ref": "#/definitions/v1DownloadFileResponse" } }, "default": { @@ -73,10 +65,18 @@ }, "parameters": [ { - "name": "id", - "in": "query", - "required": false, + "name": "allocation", + "in": "path", + "required": true, "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1DownloadFileRequest" + } } ], "tags": [ diff --git a/code/go/0chain.net/blobbercore/readmarker/entity.go b/code/go/0chain.net/blobbercore/readmarker/entity.go index 18f7f506d..226590940 100644 --- a/code/go/0chain.net/blobbercore/readmarker/entity.go +++ b/code/go/0chain.net/blobbercore/readmarker/entity.go @@ -204,7 +204,3 @@ func (rm *ReadMarkerEntity) UpdateStatus(ctx context.Context, return } - -func (rm *ReadMarkerEntity) GetLatestRM() *ReadMarker { - return rm.LatestRM -} diff --git a/code/go/0chain.net/blobbercore/readmarker/readmaker.go b/code/go/0chain.net/blobbercore/readmarker/readmaker.go deleted file mode 100644 index a641a3720..000000000 --- a/code/go/0chain.net/blobbercore/readmarker/readmaker.go +++ /dev/null @@ -1,18 +0,0 @@ -package readmarker - -import ( - "context" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" -) - -type ReadMakerI interface { - VerifyMarker(ctx context.Context, sa *allocation.Allocation) error - GetLatestRM() *ReadMarker - PendNumBlocks() (pendNumBlocks int64, err error) -} - -func NewReadMakerEntity(rm *ReadMarker) ReadMakerI { - return &ReadMarkerEntity{ - LatestRM: rm, - } -} From 13f88b3006e175d70207c8d5a0e2599df91c9bfe Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 1 Jun 2021 22:06:54 +0530 Subject: [PATCH 091/183] mocks --- .../blobbercore/mocks/PackageHandler.go | 333 ++++++++++++++++++ 1 file changed, 333 insertions(+) create mode 100644 code/go/0chain.net/blobbercore/mocks/PackageHandler.go diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go new file mode 100644 index 000000000..723ce34ec --- /dev/null +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -0,0 +1,333 @@ +// Code generated by mockery 2.7.5. DO NOT EDIT. + +package mocks + +import ( + context "context" + + allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + + filestore "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" + + mock "github.com/stretchr/testify/mock" + + readmarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + + reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + + stats "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + + writemarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" +) + +// PackageHandler is an autogenerated mock type for the PackageHandler type +type PackageHandler struct { + mock.Mock +} + +// FileBlockDownloaded provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) FileBlockDownloaded(ctx context.Context, refID int64) { + _m.Called(ctx, refID) +} + +// GetCollaborators provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { + ret := _m.Called(ctx, refID) + + var r0 []reference.Collaborator + if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.Collaborator); ok { + r0 = rf(ctx, refID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]reference.Collaborator) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { + r1 = rf(ctx, refID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetCommitMetaTxns provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) { + ret := _m.Called(ctx, refID) + + var r0 []reference.CommitMetaTxn + if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.CommitMetaTxn); ok { + r0 = rf(ctx, refID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]reference.CommitMetaTxn) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { + r1 = rf(ctx, refID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetFileStats provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) { + ret := _m.Called(ctx, refID) + + var r0 *stats.FileStats + if rf, ok := ret.Get(0).(func(context.Context, int64) *stats.FileStats); ok { + r0 = rf(ctx, refID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*stats.FileStats) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { + r1 = rf(ctx, refID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetFileStore provides a mock function with given fields: +func (_m *PackageHandler) GetFileStore() filestore.FileStore { + ret := _m.Called() + + var r0 filestore.FileStore + if rf, ok := ret.Get(0).(func() filestore.FileStore); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(filestore.FileStore) + } + } + + return r0 +} + +// GetLatestReadMarkerEntity provides a mock function with given fields: ctx, clientID +func (_m *PackageHandler) GetLatestReadMarkerEntity(ctx context.Context, clientID string) (*readmarker.ReadMarkerEntity, error) { + ret := _m.Called(ctx, clientID) + + var r0 *readmarker.ReadMarkerEntity + if rf, ok := ret.Get(0).(func(context.Context, string) *readmarker.ReadMarkerEntity); ok { + r0 = rf(ctx, clientID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*readmarker.ReadMarkerEntity) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string) error); ok { + r1 = rf(ctx, clientID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetObjectPath provides a mock function with given fields: ctx, allocationID, blockNum +func (_m *PackageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { + ret := _m.Called(ctx, allocationID, blockNum) + + var r0 *reference.ObjectPath + if rf, ok := ret.Get(0).(func(context.Context, string, int64) *reference.ObjectPath); ok { + r0 = rf(ctx, allocationID, blockNum) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.ObjectPath) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, int64) error); ok { + r1 = rf(ctx, allocationID, blockNum) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetObjectTree provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, path) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, path) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, path) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetRefWithChildren provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, path) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, path) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, path) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetReferenceFromLookupHash provides a mock function with given fields: ctx, allocationID, path_hash +func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, path_hash) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, path_hash) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, path_hash) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetReferenceLookup provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { + ret := _m.Called(ctx, allocationID, path) + + var r0 string + if rf, ok := ret.Get(0).(func(context.Context, string, string) string); ok { + r0 = rf(ctx, allocationID, path) + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + +// GetReferencePathFromPaths provides a mock function with given fields: ctx, allocationID, paths +func (_m *PackageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, paths) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, []string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, paths) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, []string) error); ok { + r1 = rf(ctx, allocationID, paths) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetWriteMarkerEntity provides a mock function with given fields: ctx, allocation_root +func (_m *PackageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_root string) (*writemarker.WriteMarkerEntity, error) { + ret := _m.Called(ctx, allocation_root) + + var r0 *writemarker.WriteMarkerEntity + if rf, ok := ret.Get(0).(func(context.Context, string) *writemarker.WriteMarkerEntity); ok { + r0 = rf(ctx, allocation_root) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*writemarker.WriteMarkerEntity) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string) error); ok { + r1 = rf(ctx, allocation_root) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// IsACollaborator provides a mock function with given fields: ctx, refID, clientID +func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { + ret := _m.Called(ctx, refID, clientID) + + var r0 bool + if rf, ok := ret.Get(0).(func(context.Context, int64, string) bool); ok { + r0 = rf(ctx, refID, clientID) + } else { + r0 = ret.Get(0).(bool) + } + + return r0 +} + +// SaveLatestReadMarker provides a mock function with given fields: ctx, rm, isCreate +func (_m *PackageHandler) SaveLatestReadMarker(ctx context.Context, rm *readmarker.ReadMarker, isCreate bool) error { + ret := _m.Called(ctx, rm, isCreate) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *readmarker.ReadMarker, bool) error); ok { + r0 = rf(ctx, rm, isCreate) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// VerifyReadMarker provides a mock function with given fields: ctx, readMake, alloc +func (_m *PackageHandler) VerifyReadMarker(ctx context.Context, readMake *readmarker.ReadMarkerEntity, alloc *allocation.Allocation) error { + ret := _m.Called(ctx, readMake, alloc) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *readmarker.ReadMarkerEntity, *allocation.Allocation) error); ok { + r0 = rf(ctx, readMake, alloc) + } else { + r0 = ret.Error(0) + } + + return r0 +} From 58d82a9e473ff76f1de9c96cee0a393cd0ab7344 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 1 Jun 2021 22:29:43 +0530 Subject: [PATCH 092/183] reviews applied --- .../allocation/allocationchange.go | 36 ----- .../0chain.net/blobbercore/handler/handler.go | 3 +- .../0chain.net/blobbercore/handler/helper.go | 11 +- .../handler/object_operation_grpc_handler.go | 29 ++-- .../object_operation_grpc_handler_test.go | 14 +- .../mocks/IAllocationChangeCollector.go | 148 ------------------ .../blobbercore/mocks/PackageHandler.go | 22 ++- 7 files changed, 43 insertions(+), 220 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go diff --git a/code/go/0chain.net/blobbercore/allocation/allocationchange.go b/code/go/0chain.net/blobbercore/allocation/allocationchange.go index 967be49be..e3de29dc9 100644 --- a/code/go/0chain.net/blobbercore/allocation/allocationchange.go +++ b/code/go/0chain.net/blobbercore/allocation/allocationchange.go @@ -38,22 +38,6 @@ type AllocationChangeProcessor interface { Marshal() (string, error) Unmarshal(string) error } - -type IAllocationChangeCollector interface { - TableName() string - AddChange(allocationChange *AllocationChange, changeProcessor AllocationChangeProcessor) - Save(ctx context.Context) error - ComputeProperties() - ApplyChanges(ctx context.Context, allocationRoot string) error - CommitToFileStore(ctx context.Context) error - DeleteChanges(ctx context.Context) - GetAllocationID() string - GetConnectionID() string - GetClientID() string - GetSize() int64 - SetSize(size int64) -} - type AllocationChangeCollector struct { ConnectionID string `gorm:"column:connection_id;primary_key"` AllocationID string `gorm:"column:allocation_id"` @@ -185,23 +169,3 @@ func (a *AllocationChangeCollector) DeleteChanges(ctx context.Context) { } } } - -func (cc *AllocationChangeCollector) GetAllocationID() string { - return cc.AllocationID -} - -func (cc *AllocationChangeCollector) GetConnectionID() string { - return cc.ConnectionID -} - -func (cc *AllocationChangeCollector) GetClientID() string { - return cc.ClientID -} - -func (cc *AllocationChangeCollector) GetSize() int64 { - return cc.Size -} - -func (cc *AllocationChangeCollector) SetSize(size int64) { - cc.Size = size -} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 39065dea8..59ca285b4 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -40,8 +40,7 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) - r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common. - ToJSONResponse(WithConnection(CopyHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler(svc))))).Methods(http.MethodPost) r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler)))) diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index a86587ba0..ddce474c0 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -41,8 +41,8 @@ type PackageHandler interface { GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) - GetAllocationChanges(ctx context.Context, connectionID string, - allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) + GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) + SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) } @@ -97,8 +97,11 @@ func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clien return reference.IsACollaborator(ctx, refID, clientID) } -func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, - allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { +func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) } + +func (r packageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + return alloc.Save(ctx) +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index 28b752b9d..e46ff1e76 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -12,10 +12,9 @@ import ( "path/filepath" ) -func (b *blobberGRPCService) CopyObject(ctx context.Context, r *blobbergrpc.CopyObjectRequest) ( - *blobbergrpc.CopyObjectResponse, error) { - +func (b *blobberGRPCService) CopyObject(ctx context.Context, r *blobbergrpc.CopyObjectRequest) (*blobbergrpc.CopyObjectResponse, error) { logger := ctxzap.Extract(ctx) + md := GetGRPCMetaDataFromCtx(ctx) allocationTx := r.Allocation allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) @@ -23,24 +22,18 @@ func (b *blobberGRPCService) CopyObject(ctx context.Context, r *blobbergrpc.Copy return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) } - md := GetGRPCMetaDataFromCtx(ctx) valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") } - clientID := md.Client allocationID := allocationObj.ID + clientID := md.Client if len(clientID) == 0 { return nil, common.NewError("invalid_operation", "Invalid client") } - if len(clientID) == 0 || allocationObj.OwnerID != clientID { //already checked clientId ? - return nil, common. - NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") - } - if len(r.Dest) == 0 { return nil, common.NewError("invalid_parameters", "Invalid destination for operation") } @@ -54,6 +47,11 @@ func (b *blobberGRPCService) CopyObject(ctx context.Context, r *blobbergrpc.Copy pathHash = b.packageHandler.GetReferenceLookup(ctx, allocationObj.ID, path) } + if len(clientID) == 0 || allocationObj.OwnerID != clientID { //already checked clientId ? + return nil, common. + NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + connectionID := r.ConnectionId if len(connectionID) == 0 { return nil, common.NewError("invalid_parameters", "Invalid connection id passed") @@ -87,18 +85,17 @@ func (b *blobberGRPCService) CopyObject(ctx context.Context, r *blobbergrpc.Copy } allocationChange := &allocation.AllocationChange{} - allocationChange.ConnectionID = connectionObj.GetConnectionID() + allocationChange.ConnectionID = connectionObj.ConnectionID allocationChange.Size = objectRef.Size allocationChange.Operation = allocation.COPY_OPERATION - dfc := &allocation.CopyFileChange{ConnectionID: connectionObj.GetConnectionID(), - AllocationID: connectionObj.GetAllocationID(), DestPath: r.Dest} + dfc := &allocation.CopyFileChange{ConnectionID: connectionObj.ConnectionID, + AllocationID: connectionObj.AllocationID, DestPath: r.Dest} dfc.SrcPath = objectRef.Path - - connectionObj.SetSize(connectionObj.GetSize() + allocationChange.Size) + connectionObj.Size += allocationChange.Size connectionObj.AddChange(allocationChange, dfc) - err = connectionObj.Save(ctx) + err = b.packageHandler.SaveAllocationChanges(ctx, connectionObj) if err != nil { logger.Error("Error in writing the connection meta data", zap.Error(err)) return nil, common.NewError("connection_write_error", "Error writing the connection meta data") diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go index e5662f9ca..457f81f79 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -44,18 +44,10 @@ func TestBlobberGRPCService_CopyObject_Success(t *testing.T) { mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). Return(alloc, nil) - mockAllocCollector := &mocks.IAllocationChangeCollector{} - mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) - mockAllocCollector.On(`GetAllocationID`).Return(req.Allocation) - mockAllocCollector.On(`SetSize`, mock.Anything).Return() - mockAllocCollector.On(`GetSize`).Return(int64(1)) - mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() - mockAllocCollector.On(`Save`, mock.Anything).Return(nil) - mockAllocCollector.On(`TableName`).Return(`allocation_connections`) - mockReferencePackage := &mocks.PackageHandler{} + allocChange := &allocation.AllocationChangeCollector{} mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, - req.ConnectionId, alloc.ID, alloc.OwnerID).Return(mockAllocCollector, nil) + req.ConnectionId, alloc.ID, alloc.OwnerID).Return(allocChange, nil) pathHash := req.Allocation + `:` + req.Path mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). @@ -75,6 +67,8 @@ func TestBlobberGRPCService_CopyObject_Success(t *testing.T) { Return(nil, nil) mockReferencePackage.On(`GetReference`, mock.Anything, alloc.ID, req.Dest). Return(&reference.Ref{Type: `d`}, nil) + mockReferencePackage.On(`SaveAllocationChanges`, mock.Anything, allocChange). + Return(nil) resOk := &blobbergrpc.CopyObjectResponse{ Filename: objectRef.Name, diff --git a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go b/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go deleted file mode 100644 index 37556727b..000000000 --- a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go +++ /dev/null @@ -1,148 +0,0 @@ -// Code generated by mockery 2.7.5. DO NOT EDIT. - -package mocks - -import ( - context "context" - - allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - - mock "github.com/stretchr/testify/mock" -) - -// IAllocationChangeCollector is an autogenerated mock type for the IAllocationChangeCollector type -type IAllocationChangeCollector struct { - mock.Mock -} - -// AddChange provides a mock function with given fields: allocationChange, changeProcessor -func (_m *IAllocationChangeCollector) AddChange(allocationChange *allocation.AllocationChange, changeProcessor allocation.AllocationChangeProcessor) { - _m.Called(allocationChange, changeProcessor) -} - -// ApplyChanges provides a mock function with given fields: ctx, allocationRoot -func (_m *IAllocationChangeCollector) ApplyChanges(ctx context.Context, allocationRoot string) error { - ret := _m.Called(ctx, allocationRoot) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, string) error); ok { - r0 = rf(ctx, allocationRoot) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// CommitToFileStore provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) CommitToFileStore(ctx context.Context) error { - ret := _m.Called(ctx) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context) error); ok { - r0 = rf(ctx) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// ComputeProperties provides a mock function with given fields: -func (_m *IAllocationChangeCollector) ComputeProperties() { - _m.Called() -} - -// DeleteChanges provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) DeleteChanges(ctx context.Context) { - _m.Called(ctx) -} - -// GetAllocationID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetAllocationID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetClientID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetClientID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetConnectionID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetConnectionID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetSize provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetSize() int64 { - ret := _m.Called() - - var r0 int64 - if rf, ok := ret.Get(0).(func() int64); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(int64) - } - - return r0 -} - -// Save provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) Save(ctx context.Context) error { - ret := _m.Called(ctx) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context) error); ok { - r0 = rf(ctx) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// SetSize provides a mock function with given fields: size -func (_m *IAllocationChangeCollector) SetSize(size int64) { - _m.Called(size) -} - -// TableName provides a mock function with given fields: -func (_m *IAllocationChangeCollector) TableName() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 4275abc64..d4e933ef9 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -22,15 +22,15 @@ type PackageHandler struct { } // GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID -func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { +func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { ret := _m.Called(ctx, connectionID, allocationID, clientID) - var r0 allocation.IAllocationChangeCollector - if rf, ok := ret.Get(0).(func(context.Context, string, string, string) allocation.IAllocationChangeCollector); ok { + var r0 *allocation.AllocationChangeCollector + if rf, ok := ret.Get(0).(func(context.Context, string, string, string) *allocation.AllocationChangeCollector); ok { r0 = rf(ctx, connectionID, allocationID, clientID) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(allocation.IAllocationChangeCollector) + r0 = ret.Get(0).(*allocation.AllocationChangeCollector) } } @@ -301,3 +301,17 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } + +// SaveAllocationChanges provides a mock function with given fields: ctx, alloc +func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + ret := _m.Called(ctx, alloc) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(ctx, alloc) + } else { + r0 = ret.Error(0) + } + + return r0 +} From 5e3242c185bbf56a04699408c7e381cc7dfb6911 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 1 Jun 2021 22:45:35 +0530 Subject: [PATCH 093/183] reviews applied --- .../allocation/allocationchange.go | 35 ----- .../0chain.net/blobbercore/handler/handler.go | 3 +- .../0chain.net/blobbercore/handler/helper.go | 10 +- .../handler/object_operation_grpc_handler.go | 24 ++- ...operation_grpc_handler_integration_test.go | 1 - .../object_operation_grpc_handler_test.go | 14 +- .../mocks/IAllocationChangeCollector.go | 148 ------------------ .../blobbercore/mocks/PackageHandler.go | 22 ++- 8 files changed, 41 insertions(+), 216 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go delete mode 100644 code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go diff --git a/code/go/0chain.net/blobbercore/allocation/allocationchange.go b/code/go/0chain.net/blobbercore/allocation/allocationchange.go index 967be49be..09c124885 100644 --- a/code/go/0chain.net/blobbercore/allocation/allocationchange.go +++ b/code/go/0chain.net/blobbercore/allocation/allocationchange.go @@ -39,21 +39,6 @@ type AllocationChangeProcessor interface { Unmarshal(string) error } -type IAllocationChangeCollector interface { - TableName() string - AddChange(allocationChange *AllocationChange, changeProcessor AllocationChangeProcessor) - Save(ctx context.Context) error - ComputeProperties() - ApplyChanges(ctx context.Context, allocationRoot string) error - CommitToFileStore(ctx context.Context) error - DeleteChanges(ctx context.Context) - GetAllocationID() string - GetConnectionID() string - GetClientID() string - GetSize() int64 - SetSize(size int64) -} - type AllocationChangeCollector struct { ConnectionID string `gorm:"column:connection_id;primary_key"` AllocationID string `gorm:"column:allocation_id"` @@ -185,23 +170,3 @@ func (a *AllocationChangeCollector) DeleteChanges(ctx context.Context) { } } } - -func (cc *AllocationChangeCollector) GetAllocationID() string { - return cc.AllocationID -} - -func (cc *AllocationChangeCollector) GetConnectionID() string { - return cc.ConnectionID -} - -func (cc *AllocationChangeCollector) GetClientID() string { - return cc.ClientID -} - -func (cc *AllocationChangeCollector) GetSize() int64 { - return cc.Size -} - -func (cc *AllocationChangeCollector) SetSize(size int64) { - cc.Size = size -} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index ba50a0d59..19f2ccb20 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -39,8 +39,7 @@ func SetupHandlers(r *mux.Router) { //object operations r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) - r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common. - ToJSONResponse(WithConnection(RenameHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler(svc))))).Methods(http.MethodPost) r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index 41454c91d..320f1e92d 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -40,8 +40,8 @@ type PackageHandler interface { GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) - GetAllocationChanges(ctx context.Context, connectionID string, - allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) + GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) + SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) } @@ -92,7 +92,11 @@ func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clien } func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, - allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { + allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) } + +func (r packageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + return alloc.Save(ctx) +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index ddbb09acd..b6229158b 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -10,9 +10,7 @@ import ( "go.uber.org/zap" ) -func (b *blobberGRPCService) RenameObject(ctx context.Context, r *blobbergrpc.RenameObjectRequest) ( - *blobbergrpc.RenameObjectResponse, error) { - +func (b *blobberGRPCService) RenameObject(ctx context.Context, r *blobbergrpc.RenameObjectRequest) (*blobbergrpc.RenameObjectResponse, error) { logger := ctxzap.Extract(ctx) allocationTx := r.Allocation @@ -34,11 +32,6 @@ func (b *blobberGRPCService) RenameObject(ctx context.Context, r *blobbergrpc.Re return nil, common.NewError("invalid_operation", "Invalid client") } - if len(clientID) == 0 || allocationObj.OwnerID != clientID { - return nil, common. - NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") - } - newName := r.NewName if len(newName) == 0 { return nil, common.NewError("invalid_parameters", "Invalid name") @@ -53,6 +46,11 @@ func (b *blobberGRPCService) RenameObject(ctx context.Context, r *blobbergrpc.Re pathHash = b.packageHandler.GetReferenceLookup(ctx, allocationObj.ID, path) } + if len(clientID) == 0 || allocationObj.OwnerID != clientID { + return nil, common. + NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + connectionID := r.ConnectionId if len(connectionID) == 0 { return nil, common.NewError("invalid_parameters", "Invalid connection id passed") @@ -74,16 +72,16 @@ func (b *blobberGRPCService) RenameObject(ctx context.Context, r *blobbergrpc.Re } allocationChange := &allocation.AllocationChange{} - allocationChange.ConnectionID = connectionObj.GetConnectionID() + allocationChange.ConnectionID = connectionObj.ConnectionID allocationChange.Size = 0 allocationChange.Operation = allocation.RENAME_OPERATION - dfc := &allocation.RenameFileChange{ConnectionID: connectionObj.GetConnectionID(), - AllocationID: connectionObj.GetAllocationID(), Path: objectRef.Path} + dfc := &allocation.RenameFileChange{ConnectionID: connectionObj.ConnectionID, + AllocationID: connectionObj.AllocationID, Path: objectRef.Path} dfc.NewName = newName - connectionObj.SetSize(connectionObj.GetSize() + allocationChange.Size) + connectionObj.Size += allocationChange.Size connectionObj.AddChange(allocationChange, dfc) - err = connectionObj.Save(ctx) + err = b.packageHandler.SaveAllocationChanges(ctx, connectionObj) if err != nil { logger.Error("Error in writing the connection meta data", zap.Error(err)) return nil, common.NewError("connection_write_error", "Error writing the connection meta data") diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go deleted file mode 100644 index abeebd162..000000000 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go +++ /dev/null @@ -1 +0,0 @@ -package handler diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go index 8254d47f2..545b80571 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -42,18 +42,12 @@ func TestBlobberGRPCService_RenameObject_Success(t *testing.T) { mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). Return(alloc, nil) - mockAllocCollector := &mocks.IAllocationChangeCollector{} - mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) - mockAllocCollector.On(`GetAllocationID`).Return(req.Allocation) - mockAllocCollector.On(`SetSize`, mock.Anything).Return() - mockAllocCollector.On(`GetSize`).Return(int64(1)) - mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() - mockAllocCollector.On(`Save`, mock.Anything).Return(nil) - mockAllocCollector.On(`TableName`).Return(`allocation_connections`) - mockReferencePackage := &mocks.PackageHandler{} + allocChange := &allocation.AllocationChangeCollector{} mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, - req.ConnectionId, alloc.ID, `client`).Return(mockAllocCollector, nil) + req.ConnectionId, alloc.ID, `client`).Return(allocChange, nil) + mockReferencePackage.On(`SaveAllocationChanges`, mock.Anything, allocChange). + Return(nil) pathHash := req.Allocation + `:` + req.Path mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). diff --git a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go b/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go deleted file mode 100644 index 37556727b..000000000 --- a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go +++ /dev/null @@ -1,148 +0,0 @@ -// Code generated by mockery 2.7.5. DO NOT EDIT. - -package mocks - -import ( - context "context" - - allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - - mock "github.com/stretchr/testify/mock" -) - -// IAllocationChangeCollector is an autogenerated mock type for the IAllocationChangeCollector type -type IAllocationChangeCollector struct { - mock.Mock -} - -// AddChange provides a mock function with given fields: allocationChange, changeProcessor -func (_m *IAllocationChangeCollector) AddChange(allocationChange *allocation.AllocationChange, changeProcessor allocation.AllocationChangeProcessor) { - _m.Called(allocationChange, changeProcessor) -} - -// ApplyChanges provides a mock function with given fields: ctx, allocationRoot -func (_m *IAllocationChangeCollector) ApplyChanges(ctx context.Context, allocationRoot string) error { - ret := _m.Called(ctx, allocationRoot) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, string) error); ok { - r0 = rf(ctx, allocationRoot) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// CommitToFileStore provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) CommitToFileStore(ctx context.Context) error { - ret := _m.Called(ctx) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context) error); ok { - r0 = rf(ctx) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// ComputeProperties provides a mock function with given fields: -func (_m *IAllocationChangeCollector) ComputeProperties() { - _m.Called() -} - -// DeleteChanges provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) DeleteChanges(ctx context.Context) { - _m.Called(ctx) -} - -// GetAllocationID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetAllocationID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetClientID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetClientID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetConnectionID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetConnectionID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetSize provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetSize() int64 { - ret := _m.Called() - - var r0 int64 - if rf, ok := ret.Get(0).(func() int64); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(int64) - } - - return r0 -} - -// Save provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) Save(ctx context.Context) error { - ret := _m.Called(ctx) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context) error); ok { - r0 = rf(ctx) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// SetSize provides a mock function with given fields: size -func (_m *IAllocationChangeCollector) SetSize(size int64) { - _m.Called(size) -} - -// TableName provides a mock function with given fields: -func (_m *IAllocationChangeCollector) TableName() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 2c3d4c11c..1194a52a0 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -22,15 +22,15 @@ type PackageHandler struct { } // GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID -func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { +func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { ret := _m.Called(ctx, connectionID, allocationID, clientID) - var r0 allocation.IAllocationChangeCollector - if rf, ok := ret.Get(0).(func(context.Context, string, string, string) allocation.IAllocationChangeCollector); ok { + var r0 *allocation.AllocationChangeCollector + if rf, ok := ret.Get(0).(func(context.Context, string, string, string) *allocation.AllocationChangeCollector); ok { r0 = rf(ctx, connectionID, allocationID, clientID) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(allocation.IAllocationChangeCollector) + r0 = ret.Get(0).(*allocation.AllocationChangeCollector) } } @@ -278,3 +278,17 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } + +// SaveAllocationChanges provides a mock function with given fields: ctx, alloc +func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + ret := _m.Called(ctx, alloc) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(ctx, alloc) + } else { + r0 = ret.Error(0) + } + + return r0 +} From e5984e8c7ca1a66eeec5bcc2ad860aad36ede1a5 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 1 Jun 2021 22:47:49 +0530 Subject: [PATCH 094/183] endpoint version updated --- .../blobbercore/blobbergrpc/blobber.pb.go | 2 +- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 2 +- .../blobbergrpc/proto/blobber.proto | 2 +- .../blobbercore/openapi/blobber.swagger.json | 76 +++++++++---------- 4 files changed, 41 insertions(+), 41 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index e6186cb43..f2e6be34a 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -2566,7 +2566,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x31, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, + 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 8516e3e02..1e004b759 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -964,7 +964,7 @@ var ( pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) - pattern_Blobber_RenameObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v1", "file", "rename", "allocation"}, "")) + pattern_Blobber_RenameObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "rename", "allocation"}, "")) ) var ( diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index ca00811e0..726e72317 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -44,7 +44,7 @@ service Blobber { } rpc RenameObject(RenameObjectRequest) returns (RenameObjectResponse) { option (google.api.http) = { - post: "/v1/file/rename/{allocation}" + post: "/v2/file/rename/{allocation}" body: "*" }; } diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index cbc38e476..9940fc247 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -16,44 +16,6 @@ "application/json" ], "paths": { - "/v1/file/rename/{allocation}": { - "post": { - "operationId": "Blobber_RenameObject", - "responses": { - "200": { - "description": "A successful response.", - "schema": { - "$ref": "#/definitions/v1RenameObjectResponse" - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/rpcStatus" - } - } - }, - "parameters": [ - { - "name": "allocation", - "in": "path", - "required": true, - "type": "string" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/v1RenameObjectRequest" - } - } - ], - "tags": [ - "Blobber" - ] - } - }, "/v2/allocation": { "get": { "operationId": "Blobber_GetAllocation", @@ -300,6 +262,44 @@ ] } }, + "/v2/file/rename/{allocation}": { + "post": { + "operationId": "Blobber_RenameObject", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1RenameObjectResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1RenameObjectRequest" + } + } + ], + "tags": [ + "Blobber" + ] + } + }, "/v2/file/stats/{allocation}": { "get": { "operationId": "Blobber_GetFileStats", From d9f85a5daf03ef73a5e779838cfddaa7cdf58d49 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 1 Jun 2021 22:59:54 +0530 Subject: [PATCH 095/183] reviews applied --- .../allocation/allocationchange.go | 35 --- .../0chain.net/blobbercore/handler/handler.go | 3 +- .../0chain.net/blobbercore/handler/helper.go | 10 +- .../handler/object_operation_grpc_handler.go | 25 +- ...operation_grpc_handler_integration_test.go | 1 - .../object_operation_grpc_handler_test.go | 12 +- .../mocks/IAllocationChangeCollector.go | 148 --------- .../blobbercore/mocks/PackageHandler.go | 280 ------------------ 8 files changed, 26 insertions(+), 488 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go delete mode 100644 code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go delete mode 100644 code/go/0chain.net/blobbercore/mocks/PackageHandler.go diff --git a/code/go/0chain.net/blobbercore/allocation/allocationchange.go b/code/go/0chain.net/blobbercore/allocation/allocationchange.go index 967be49be..09c124885 100644 --- a/code/go/0chain.net/blobbercore/allocation/allocationchange.go +++ b/code/go/0chain.net/blobbercore/allocation/allocationchange.go @@ -39,21 +39,6 @@ type AllocationChangeProcessor interface { Unmarshal(string) error } -type IAllocationChangeCollector interface { - TableName() string - AddChange(allocationChange *AllocationChange, changeProcessor AllocationChangeProcessor) - Save(ctx context.Context) error - ComputeProperties() - ApplyChanges(ctx context.Context, allocationRoot string) error - CommitToFileStore(ctx context.Context) error - DeleteChanges(ctx context.Context) - GetAllocationID() string - GetConnectionID() string - GetClientID() string - GetSize() int64 - SetSize(size int64) -} - type AllocationChangeCollector struct { ConnectionID string `gorm:"column:connection_id;primary_key"` AllocationID string `gorm:"column:allocation_id"` @@ -185,23 +170,3 @@ func (a *AllocationChangeCollector) DeleteChanges(ctx context.Context) { } } } - -func (cc *AllocationChangeCollector) GetAllocationID() string { - return cc.AllocationID -} - -func (cc *AllocationChangeCollector) GetConnectionID() string { - return cc.ConnectionID -} - -func (cc *AllocationChangeCollector) GetClientID() string { - return cc.ClientID -} - -func (cc *AllocationChangeCollector) GetSize() int64 { - return cc.Size -} - -func (cc *AllocationChangeCollector) SetSize(size int64) { - cc.Size = size -} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index d1fb9e16f..68539bfb8 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -41,8 +41,7 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) - r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse( - WithConnection(UpdateAttributesHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler(svc))))).Methods(http.MethodPost) r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler)))) r.HandleFunc("/v1/file/commitmetatxn/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitMetaTxnHandler)))) diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index 41454c91d..320f1e92d 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -40,8 +40,8 @@ type PackageHandler interface { GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) - GetAllocationChanges(ctx context.Context, connectionID string, - allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) + GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) + SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) } @@ -92,7 +92,11 @@ func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clien } func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, - allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { + allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) } + +func (r packageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + return alloc.Save(ctx) +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index 66493bf76..d8713294b 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -12,9 +12,7 @@ import ( "go.uber.org/zap" ) -func (b *blobberGRPCService) UpdateObjectAttributes(ctx context.Context, r *blobbergrpc.UpdateObjectAttributesRequest) ( - response *blobbergrpc.UpdateObjectAttributesResponse, err error) { - +func (b *blobberGRPCService) UpdateObjectAttributes(ctx context.Context, r *blobbergrpc.UpdateObjectAttributesRequest) (*blobbergrpc.UpdateObjectAttributesResponse, error) { logger := ctxzap.Extract(ctx) allocationTx := r.Allocation @@ -33,9 +31,9 @@ func (b *blobberGRPCService) UpdateObjectAttributes(ctx context.Context, r *blob //_ = ctx.Value(constants.CLIENT_KEY_CONTEXT_KEY).(string) //why this removed? clientID := md.Client - if len(clientID) == 0 || allocationObj.OwnerID != clientID { - return nil, common.NewError( - "invalid_operation", "Operation needs to be performed by the owner of the allocation") + if clientID == "" { + return nil, common.NewError("update_object_attributes", + "missing client ID") } var attributes = r.Attributes // new attributes as string @@ -59,13 +57,18 @@ func (b *blobberGRPCService) UpdateObjectAttributes(ctx context.Context, r *blob pathHash = b.packageHandler.GetReferenceLookup(ctx, allocationObj.ID, path) } + if allocationObj.OwnerID != clientID { + return nil, common.NewError( + "invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + var connID = r.ConnectionId if connID == "" { return nil, common.NewErrorf("update_object_attributes", "invalid connection id passed: %s", connID) } - var conn allocation.IAllocationChangeCollector + var conn *allocation.AllocationChangeCollector conn, err = b.packageHandler.GetAllocationChanges(ctx, connID, allocationObj.ID, clientID) if err != nil { return nil, common.NewErrorf("update_object_attributes", @@ -85,19 +88,19 @@ func (b *blobberGRPCService) UpdateObjectAttributes(ctx context.Context, r *blob } var change = new(allocation.AllocationChange) - change.ConnectionID = conn.GetConnectionID() + change.ConnectionID = conn.ConnectionID change.Operation = allocation.UPDATE_ATTRS_OPERATION var uafc = &allocation.AttributesChange{ - ConnectionID: conn.GetConnectionID(), - AllocationID: conn.GetAllocationID(), + ConnectionID: conn.ConnectionID, + AllocationID: conn.AllocationID, Path: ref.Path, Attributes: attrs, } conn.AddChange(change, uafc) - err = conn.Save(ctx) + err = b.packageHandler.SaveAllocationChanges(ctx, conn) if err != nil { logger.Error("update_object_attributes: "+ "error in writing the connection meta data", zap.Error(err)) diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go deleted file mode 100644 index abeebd162..000000000 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_integration_test.go +++ /dev/null @@ -1 +0,0 @@ -package handler diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go index 152e88ebe..554807548 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -44,16 +44,12 @@ func TestBlobberGRPCService_UpdateObjectAttributes_Success(t *testing.T) { mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). Return(alloc, nil) - mockAllocCollector := &mocks.IAllocationChangeCollector{} - mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) - mockAllocCollector.On(`GetAllocationID`).Return(req.Allocation) - mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() - mockAllocCollector.On(`Save`, mock.Anything).Return(nil) - mockAllocCollector.On(`TableName`).Return(`allocation_connections`) - mockReferencePackage := &mocks.PackageHandler{} + allocChange := &allocation.AllocationChangeCollector{} mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, - req.ConnectionId, alloc.ID, `client`).Return(mockAllocCollector, nil) + req.ConnectionId, alloc.ID, `client`).Return(allocChange, nil) + mockReferencePackage.On(`SaveAllocationChanges`, mock.Anything, allocChange). + Return(nil) pathHash := req.Allocation + `:` + req.Path mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). diff --git a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go b/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go deleted file mode 100644 index 37556727b..000000000 --- a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go +++ /dev/null @@ -1,148 +0,0 @@ -// Code generated by mockery 2.7.5. DO NOT EDIT. - -package mocks - -import ( - context "context" - - allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - - mock "github.com/stretchr/testify/mock" -) - -// IAllocationChangeCollector is an autogenerated mock type for the IAllocationChangeCollector type -type IAllocationChangeCollector struct { - mock.Mock -} - -// AddChange provides a mock function with given fields: allocationChange, changeProcessor -func (_m *IAllocationChangeCollector) AddChange(allocationChange *allocation.AllocationChange, changeProcessor allocation.AllocationChangeProcessor) { - _m.Called(allocationChange, changeProcessor) -} - -// ApplyChanges provides a mock function with given fields: ctx, allocationRoot -func (_m *IAllocationChangeCollector) ApplyChanges(ctx context.Context, allocationRoot string) error { - ret := _m.Called(ctx, allocationRoot) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, string) error); ok { - r0 = rf(ctx, allocationRoot) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// CommitToFileStore provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) CommitToFileStore(ctx context.Context) error { - ret := _m.Called(ctx) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context) error); ok { - r0 = rf(ctx) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// ComputeProperties provides a mock function with given fields: -func (_m *IAllocationChangeCollector) ComputeProperties() { - _m.Called() -} - -// DeleteChanges provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) DeleteChanges(ctx context.Context) { - _m.Called(ctx) -} - -// GetAllocationID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetAllocationID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetClientID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetClientID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetConnectionID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetConnectionID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetSize provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetSize() int64 { - ret := _m.Called() - - var r0 int64 - if rf, ok := ret.Get(0).(func() int64); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(int64) - } - - return r0 -} - -// Save provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) Save(ctx context.Context) error { - ret := _m.Called(ctx) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context) error); ok { - r0 = rf(ctx) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// SetSize provides a mock function with given fields: size -func (_m *IAllocationChangeCollector) SetSize(size int64) { - _m.Called(size) -} - -// TableName provides a mock function with given fields: -func (_m *IAllocationChangeCollector) TableName() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go deleted file mode 100644 index 2c3d4c11c..000000000 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ /dev/null @@ -1,280 +0,0 @@ -// Code generated by mockery 2.7.5. DO NOT EDIT. - -package mocks - -import ( - context "context" - - allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - - mock "github.com/stretchr/testify/mock" - - reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - - stats "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" - - writemarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" -) - -// PackageHandler is an autogenerated mock type for the PackageHandler type -type PackageHandler struct { - mock.Mock -} - -// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID -func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { - ret := _m.Called(ctx, connectionID, allocationID, clientID) - - var r0 allocation.IAllocationChangeCollector - if rf, ok := ret.Get(0).(func(context.Context, string, string, string) allocation.IAllocationChangeCollector); ok { - r0 = rf(ctx, connectionID, allocationID, clientID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(allocation.IAllocationChangeCollector) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { - r1 = rf(ctx, connectionID, allocationID, clientID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetCollaborators provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { - ret := _m.Called(ctx, refID) - - var r0 []reference.Collaborator - if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.Collaborator); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]reference.Collaborator) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetCommitMetaTxns provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) { - ret := _m.Called(ctx, refID) - - var r0 []reference.CommitMetaTxn - if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.CommitMetaTxn); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]reference.CommitMetaTxn) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetFileStats provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) { - ret := _m.Called(ctx, refID) - - var r0 *stats.FileStats - if rf, ok := ret.Get(0).(func(context.Context, int64) *stats.FileStats); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*stats.FileStats) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetObjectPath provides a mock function with given fields: ctx, allocationID, blockNum -func (_m *PackageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { - ret := _m.Called(ctx, allocationID, blockNum) - - var r0 *reference.ObjectPath - if rf, ok := ret.Get(0).(func(context.Context, string, int64) *reference.ObjectPath); ok { - r0 = rf(ctx, allocationID, blockNum) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.ObjectPath) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, int64) error); ok { - r1 = rf(ctx, allocationID, blockNum) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetObjectTree provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetRefWithChildren provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetReferenceFromLookupHash provides a mock function with given fields: ctx, allocationID, path_hash -func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path_hash) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path_hash) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path_hash) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetReferenceLookup provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { - ret := _m.Called(ctx, allocationID, path) - - var r0 string - if rf, ok := ret.Get(0).(func(context.Context, string, string) string); ok { - r0 = rf(ctx, allocationID, path) - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetReferencePathFromPaths provides a mock function with given fields: ctx, allocationID, paths -func (_m *PackageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, paths) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, []string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, paths) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, []string) error); ok { - r1 = rf(ctx, allocationID, paths) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetWriteMarkerEntity provides a mock function with given fields: ctx, allocation_root -func (_m *PackageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_root string) (*writemarker.WriteMarkerEntity, error) { - ret := _m.Called(ctx, allocation_root) - - var r0 *writemarker.WriteMarkerEntity - if rf, ok := ret.Get(0).(func(context.Context, string) *writemarker.WriteMarkerEntity); ok { - r0 = rf(ctx, allocation_root) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*writemarker.WriteMarkerEntity) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string) error); ok { - r1 = rf(ctx, allocation_root) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// IsACollaborator provides a mock function with given fields: ctx, refID, clientID -func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { - ret := _m.Called(ctx, refID, clientID) - - var r0 bool - if rf, ok := ret.Get(0).(func(context.Context, int64, string) bool); ok { - r0 = rf(ctx, refID, clientID) - } else { - r0 = ret.Get(0).(bool) - } - - return r0 -} From 935a25b4e732bf157aa8fdaca8bfb1e87ba5ace6 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 1 Jun 2021 23:00:13 +0530 Subject: [PATCH 096/183] mocks --- .../blobbercore/mocks/PackageHandler.go | 294 ++++++++++++++++++ 1 file changed, 294 insertions(+) create mode 100644 code/go/0chain.net/blobbercore/mocks/PackageHandler.go diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go new file mode 100644 index 000000000..1194a52a0 --- /dev/null +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -0,0 +1,294 @@ +// Code generated by mockery 2.7.5. DO NOT EDIT. + +package mocks + +import ( + context "context" + + allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + + mock "github.com/stretchr/testify/mock" + + reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + + stats "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + + writemarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" +) + +// PackageHandler is an autogenerated mock type for the PackageHandler type +type PackageHandler struct { + mock.Mock +} + +// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID +func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { + ret := _m.Called(ctx, connectionID, allocationID, clientID) + + var r0 *allocation.AllocationChangeCollector + if rf, ok := ret.Get(0).(func(context.Context, string, string, string) *allocation.AllocationChangeCollector); ok { + r0 = rf(ctx, connectionID, allocationID, clientID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*allocation.AllocationChangeCollector) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { + r1 = rf(ctx, connectionID, allocationID, clientID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetCollaborators provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { + ret := _m.Called(ctx, refID) + + var r0 []reference.Collaborator + if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.Collaborator); ok { + r0 = rf(ctx, refID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]reference.Collaborator) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { + r1 = rf(ctx, refID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetCommitMetaTxns provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) { + ret := _m.Called(ctx, refID) + + var r0 []reference.CommitMetaTxn + if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.CommitMetaTxn); ok { + r0 = rf(ctx, refID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]reference.CommitMetaTxn) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { + r1 = rf(ctx, refID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetFileStats provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) { + ret := _m.Called(ctx, refID) + + var r0 *stats.FileStats + if rf, ok := ret.Get(0).(func(context.Context, int64) *stats.FileStats); ok { + r0 = rf(ctx, refID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*stats.FileStats) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { + r1 = rf(ctx, refID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetObjectPath provides a mock function with given fields: ctx, allocationID, blockNum +func (_m *PackageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { + ret := _m.Called(ctx, allocationID, blockNum) + + var r0 *reference.ObjectPath + if rf, ok := ret.Get(0).(func(context.Context, string, int64) *reference.ObjectPath); ok { + r0 = rf(ctx, allocationID, blockNum) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.ObjectPath) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, int64) error); ok { + r1 = rf(ctx, allocationID, blockNum) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetObjectTree provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, path) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, path) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, path) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetRefWithChildren provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, path) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, path) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, path) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetReferenceFromLookupHash provides a mock function with given fields: ctx, allocationID, path_hash +func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, path_hash) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, path_hash) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, path_hash) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetReferenceLookup provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { + ret := _m.Called(ctx, allocationID, path) + + var r0 string + if rf, ok := ret.Get(0).(func(context.Context, string, string) string); ok { + r0 = rf(ctx, allocationID, path) + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + +// GetReferencePathFromPaths provides a mock function with given fields: ctx, allocationID, paths +func (_m *PackageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, paths) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, []string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, paths) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, []string) error); ok { + r1 = rf(ctx, allocationID, paths) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetWriteMarkerEntity provides a mock function with given fields: ctx, allocation_root +func (_m *PackageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_root string) (*writemarker.WriteMarkerEntity, error) { + ret := _m.Called(ctx, allocation_root) + + var r0 *writemarker.WriteMarkerEntity + if rf, ok := ret.Get(0).(func(context.Context, string) *writemarker.WriteMarkerEntity); ok { + r0 = rf(ctx, allocation_root) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*writemarker.WriteMarkerEntity) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string) error); ok { + r1 = rf(ctx, allocation_root) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// IsACollaborator provides a mock function with given fields: ctx, refID, clientID +func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { + ret := _m.Called(ctx, refID, clientID) + + var r0 bool + if rf, ok := ret.Get(0).(func(context.Context, int64, string) bool); ok { + r0 = rf(ctx, refID, clientID) + } else { + r0 = ret.Get(0).(bool) + } + + return r0 +} + +// SaveAllocationChanges provides a mock function with given fields: ctx, alloc +func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + ret := _m.Called(ctx, alloc) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(ctx, alloc) + } else { + r0 = ret.Error(0) + } + + return r0 +} From 05e22d7e8bd0ba7b0459c897cf11860dc0713369 Mon Sep 17 00:00:00 2001 From: Vivek V Date: Wed, 2 Jun 2021 17:47:19 +0530 Subject: [PATCH 097/183] :white_check_mark: added unit tests --- .../blobbercore/handler/grpc_handler.go | 2 +- .../handler/grpc_handler_unit_test.go | 109 +++++++++++++++--- .../0chain.net/blobbercore/handler/helper.go | 5 + .../blobbercore/mocks/PackageHandler.go | 16 ++- 4 files changed, 114 insertions(+), 18 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 82251ac1c..9d70ba5a4 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -539,7 +539,7 @@ func (b *blobberGRPCService) CommitMetaTxn(ctx context.Context, req *blobbergrpc return nil, common.NewError("invalid_parameter", "TxnID not present in the params") } - if err := reference.AddCommitMetaTxn(ctx, fileRef.ID, txnID); err != nil { + if err := b.packageHandler.AddCommitMetaTxn(ctx, fileRef.ID, txnID); err != nil { return nil, common.NewError("add_commit_meta_txn_failed", "Failed to add commitMetaTxn with err :"+err.Error()) } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index 99f8d860e..3c35fb0f0 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -7,25 +7,16 @@ import ( "strings" "testing" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" "github.com/0chain/blobber/code/go/0chain.net/core/common" - - "google.golang.org/grpc/metadata" - "github.com/0chain/blobber/code/go/0chain.net/core/encryption" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" - "github.com/stretchr/testify/assert" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "github.com/stretchr/testify/mock" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "google.golang.org/grpc/metadata" ) func TestBlobberGRPCService_GetAllocation_Success(t *testing.T) { @@ -591,6 +582,92 @@ func TestBlobberGRPCService_CalculateHashNotOwner(t *testing.T) { svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) _, err := svc.CalculateHash(ctx, req) if err == nil { - t.Fatal("expected error: ", err) + t.Fatal("expected error") + } +} + +func TestBlobberGRPCService_CommitMetaTxnSuccess(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + req := &blobbergrpc.CommitMetaTxnRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: allocationTx, + TxnId: "8", + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "owner", + common.ClientSignatureHeader: clientSignature, + })) + + mockStorageHandler := new(storageHandlerI) + mockReferencePackage := new(mocks.PackageHandler) + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ + ID: "8", + Tx: req.Allocation, + OwnerID: "owner", + OwnerPublicKey: pubKey, + }, nil) + mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ + Name: "test", + ID: 8, + Type: reference.FILE, + }, nil) + mockReferencePackage.On("AddCommitMetaTxn", mock.Anything, mock.Anything, mock.Anything). + Return(nil) + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + resp, err := svc.CommitMetaTxn(ctx, req) + if err != nil { + t.Fatal("unexpected error: ", err) + } + + assert.Equal(t, resp.GetMessage(), "Added commitMetaTxn successfully") +} + +func TestBlobberGRPCService_CommitMetaTxnError(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + req := &blobbergrpc.CommitMetaTxnRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: allocationTx, + TxnId: "", // TxnId not passed, expecting error + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "owner", + common.ClientSignatureHeader: clientSignature, + })) + + mockStorageHandler := new(storageHandlerI) + mockReferencePackage := new(mocks.PackageHandler) + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ + ID: "8", + Tx: req.Allocation, + OwnerID: "owner", + OwnerPublicKey: pubKey, + }, nil) + mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ + Name: "test", + ID: 8, + Type: reference.FILE, + }, nil) + mockReferencePackage.On("AddCommitMetaTxn", mock.Anything, mock.Anything, mock.Anything). + Return(nil) + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + _, err := svc.CommitMetaTxn(ctx, req) + if err == nil { + t.Fatal("expected error") } } diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index eea3de31f..7c712207e 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -32,6 +32,7 @@ type StorageHandlerI interface { type PackageHandler interface { GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) + AddCommitMetaTxn(ctx context.Context, refID int64, txnID string) error GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) IsACollaborator(ctx context.Context, refID int64, clientID string) bool GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) @@ -101,6 +102,10 @@ func (r *packageHandler) GetCommitMetaTxns(ctx context.Context, refID int64) ([] return reference.GetCommitMetaTxns(ctx, refID) } +func (r *packageHandler) AddCommitMetaTxn(ctx context.Context, refID int64, txnID string) error { + return reference.AddCommitMetaTxn(ctx, refID, txnID) +} + func (r *packageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { return reference.GetCollaborators(ctx, refID) } diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index e7ad4bde3..e3ba845b0 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -1,4 +1,4 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. +// Code generated by mockery 2.7.5. DO NOT EDIT. package mocks @@ -21,6 +21,20 @@ type PackageHandler struct { mock.Mock } +// AddCommitMetaTxn provides a mock function with given fields: ctx, refID, txnID +func (_m *PackageHandler) AddCommitMetaTxn(ctx context.Context, refID int64, txnID string) error { + ret := _m.Called(ctx, refID, txnID) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { + r0 = rf(ctx, refID, txnID) + } else { + r0 = ret.Error(0) + } + + return r0 +} + // ApplyChanges provides a mock function with given fields: connectionObj, ctx, allocationRoot func (_m *PackageHandler) ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error { ret := _m.Called(connectionObj, ctx, allocationRoot) From 44c55caa21b38701c3c0e537c7cca43df17ba189 Mon Sep 17 00:00:00 2001 From: Vivek V Date: Wed, 2 Jun 2021 23:36:41 +0530 Subject: [PATCH 098/183] :sparkles: refs #164, migrated CollaboratorHandler to gRPC --- .../blobbercore/blobbergrpc/blobber.pb.go | 1387 ++++++++++------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 115 ++ .../blobbergrpc/blobber_grpc.pb.go | 36 + .../blobbergrpc/proto/blobber.proto | 30 +- .../blobbercore/convert/responseHandler.go | 19 + .../blobbercore/handler/grpc_handler.go | 95 ++ .../0chain.net/blobbercore/handler/handler.go | 24 +- .../blobbercore/handler/handler_test.go | 2 +- .../0chain.net/blobbercore/handler/helper.go | 10 + .../blobbercore/mocks/PackageHandler.go | 30 +- .../blobbercore/openapi/blobber.swagger.json | 72 + 11 files changed, 1206 insertions(+), 614 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index d4be19e31..e36561b7a 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -21,6 +21,140 @@ const ( _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) +type CollaboratorRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` + CollabId string `protobuf:"bytes,2,opt,name=collab_id,json=collabId,proto3" json:"collab_id,omitempty"` + Method string `protobuf:"bytes,3,opt,name=method,proto3" json:"method,omitempty"` + Path string `protobuf:"bytes,4,opt,name=path,proto3" json:"path,omitempty"` + PathHash string `protobuf:"bytes,5,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` +} + +func (x *CollaboratorRequest) Reset() { + *x = CollaboratorRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CollaboratorRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CollaboratorRequest) ProtoMessage() {} + +func (x *CollaboratorRequest) ProtoReflect() protoreflect.Message { + mi := &file_blobber_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 CollaboratorRequest.ProtoReflect.Descriptor instead. +func (*CollaboratorRequest) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{0} +} + +func (x *CollaboratorRequest) GetAllocation() string { + if x != nil { + return x.Allocation + } + return "" +} + +func (x *CollaboratorRequest) GetCollabId() string { + if x != nil { + return x.CollabId + } + return "" +} + +func (x *CollaboratorRequest) GetMethod() string { + if x != nil { + return x.Method + } + return "" +} + +func (x *CollaboratorRequest) GetPath() string { + if x != nil { + return x.Path + } + return "" +} + +func (x *CollaboratorRequest) GetPathHash() string { + if x != nil { + return x.PathHash + } + return "" +} + +type CollaboratorResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` + Collaborators []*Collaborator `protobuf:"bytes,2,rep,name=Collaborators,proto3" json:"Collaborators,omitempty"` +} + +func (x *CollaboratorResponse) Reset() { + *x = CollaboratorResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_blobber_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CollaboratorResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CollaboratorResponse) ProtoMessage() {} + +func (x *CollaboratorResponse) ProtoReflect() protoreflect.Message { + mi := &file_blobber_proto_msgTypes[1] + 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 CollaboratorResponse.ProtoReflect.Descriptor instead. +func (*CollaboratorResponse) Descriptor() ([]byte, []int) { + return file_blobber_proto_rawDescGZIP(), []int{1} +} + +func (x *CollaboratorResponse) GetMessage() string { + if x != nil { + return x.Message + } + return "" +} + +func (x *CollaboratorResponse) GetCollaborators() []*Collaborator { + if x != nil { + return x.Collaborators + } + return nil +} + type CalculateHashRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -34,7 +168,7 @@ type CalculateHashRequest struct { func (x *CalculateHashRequest) Reset() { *x = CalculateHashRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[0] + mi := &file_blobber_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -47,7 +181,7 @@ func (x *CalculateHashRequest) String() string { func (*CalculateHashRequest) ProtoMessage() {} func (x *CalculateHashRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[0] + mi := &file_blobber_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -60,7 +194,7 @@ func (x *CalculateHashRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CalculateHashRequest.ProtoReflect.Descriptor instead. func (*CalculateHashRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{0} + return file_blobber_proto_rawDescGZIP(), []int{2} } func (x *CalculateHashRequest) GetAllocation() string { @@ -95,7 +229,7 @@ type CalculateHashResponse struct { func (x *CalculateHashResponse) Reset() { *x = CalculateHashResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[1] + mi := &file_blobber_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -108,7 +242,7 @@ func (x *CalculateHashResponse) String() string { func (*CalculateHashResponse) ProtoMessage() {} func (x *CalculateHashResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[1] + mi := &file_blobber_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -121,7 +255,7 @@ func (x *CalculateHashResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CalculateHashResponse.ProtoReflect.Descriptor instead. func (*CalculateHashResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{1} + return file_blobber_proto_rawDescGZIP(), []int{3} } func (x *CalculateHashResponse) GetMessage() string { @@ -144,7 +278,7 @@ type CommitRequest struct { func (x *CommitRequest) Reset() { *x = CommitRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[2] + mi := &file_blobber_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -157,7 +291,7 @@ func (x *CommitRequest) String() string { func (*CommitRequest) ProtoMessage() {} func (x *CommitRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[2] + mi := &file_blobber_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -170,7 +304,7 @@ func (x *CommitRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CommitRequest.ProtoReflect.Descriptor instead. func (*CommitRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{2} + return file_blobber_proto_rawDescGZIP(), []int{4} } func (x *CommitRequest) GetAllocation() string { @@ -208,7 +342,7 @@ type CommitResponse struct { func (x *CommitResponse) Reset() { *x = CommitResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[3] + mi := &file_blobber_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -221,7 +355,7 @@ func (x *CommitResponse) String() string { func (*CommitResponse) ProtoMessage() {} func (x *CommitResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[3] + mi := &file_blobber_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -234,7 +368,7 @@ func (x *CommitResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CommitResponse.ProtoReflect.Descriptor instead. func (*CommitResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{3} + return file_blobber_proto_rawDescGZIP(), []int{5} } func (x *CommitResponse) GetAllocationRoot() string { @@ -277,7 +411,7 @@ type GetObjectTreeRequest struct { func (x *GetObjectTreeRequest) Reset() { *x = GetObjectTreeRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -290,7 +424,7 @@ func (x *GetObjectTreeRequest) String() string { func (*GetObjectTreeRequest) ProtoMessage() {} func (x *GetObjectTreeRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[4] + mi := &file_blobber_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -303,7 +437,7 @@ func (x *GetObjectTreeRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectTreeRequest.ProtoReflect.Descriptor instead. func (*GetObjectTreeRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{4} + return file_blobber_proto_rawDescGZIP(), []int{6} } func (x *GetObjectTreeRequest) GetPath() string { @@ -332,7 +466,7 @@ type GetObjectTreeResponse struct { func (x *GetObjectTreeResponse) Reset() { *x = GetObjectTreeResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -345,7 +479,7 @@ func (x *GetObjectTreeResponse) String() string { func (*GetObjectTreeResponse) ProtoMessage() {} func (x *GetObjectTreeResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[5] + mi := &file_blobber_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -358,7 +492,7 @@ func (x *GetObjectTreeResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectTreeResponse.ProtoReflect.Descriptor instead. func (*GetObjectTreeResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{5} + return file_blobber_proto_rawDescGZIP(), []int{7} } func (x *GetObjectTreeResponse) GetReferencePath() *ReferencePath { @@ -388,7 +522,7 @@ type GetReferencePathRequest struct { func (x *GetReferencePathRequest) Reset() { *x = GetReferencePathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -401,7 +535,7 @@ func (x *GetReferencePathRequest) String() string { func (*GetReferencePathRequest) ProtoMessage() {} func (x *GetReferencePathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[6] + mi := &file_blobber_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -414,7 +548,7 @@ func (x *GetReferencePathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReferencePathRequest.ProtoReflect.Descriptor instead. func (*GetReferencePathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{6} + return file_blobber_proto_rawDescGZIP(), []int{8} } func (x *GetReferencePathRequest) GetPaths() string { @@ -450,7 +584,7 @@ type GetReferencePathResponse struct { func (x *GetReferencePathResponse) Reset() { *x = GetReferencePathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -463,7 +597,7 @@ func (x *GetReferencePathResponse) String() string { func (*GetReferencePathResponse) ProtoMessage() {} func (x *GetReferencePathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[7] + mi := &file_blobber_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -476,7 +610,7 @@ func (x *GetReferencePathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReferencePathResponse.ProtoReflect.Descriptor instead. func (*GetReferencePathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{7} + return file_blobber_proto_rawDescGZIP(), []int{9} } func (x *GetReferencePathResponse) GetReferencePath() *ReferencePath { @@ -505,7 +639,7 @@ type ReferencePath struct { func (x *ReferencePath) Reset() { *x = ReferencePath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -518,7 +652,7 @@ func (x *ReferencePath) String() string { func (*ReferencePath) ProtoMessage() {} func (x *ReferencePath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[8] + mi := &file_blobber_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -531,7 +665,7 @@ func (x *ReferencePath) ProtoReflect() protoreflect.Message { // Deprecated: Use ReferencePath.ProtoReflect.Descriptor instead. func (*ReferencePath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{8} + return file_blobber_proto_rawDescGZIP(), []int{10} } func (x *ReferencePath) GetMetaData() *FileRef { @@ -561,7 +695,7 @@ type GetObjectPathRequest struct { func (x *GetObjectPathRequest) Reset() { *x = GetObjectPathRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -574,7 +708,7 @@ func (x *GetObjectPathRequest) String() string { func (*GetObjectPathRequest) ProtoMessage() {} func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[9] + mi := &file_blobber_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -587,7 +721,7 @@ func (x *GetObjectPathRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathRequest.ProtoReflect.Descriptor instead. func (*GetObjectPathRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{9} + return file_blobber_proto_rawDescGZIP(), []int{11} } func (x *GetObjectPathRequest) GetAllocation() string { @@ -623,7 +757,7 @@ type GetObjectPathResponse struct { func (x *GetObjectPathResponse) Reset() { *x = GetObjectPathResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[10] + mi := &file_blobber_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -636,7 +770,7 @@ func (x *GetObjectPathResponse) String() string { func (*GetObjectPathResponse) ProtoMessage() {} func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[10] + mi := &file_blobber_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -649,7 +783,7 @@ func (x *GetObjectPathResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetObjectPathResponse.ProtoReflect.Descriptor instead. func (*GetObjectPathResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{10} + return file_blobber_proto_rawDescGZIP(), []int{12} } func (x *GetObjectPathResponse) GetObjectPath() *ObjectPath { @@ -681,7 +815,7 @@ type ObjectPath struct { func (x *ObjectPath) Reset() { *x = ObjectPath{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -694,7 +828,7 @@ func (x *ObjectPath) String() string { func (*ObjectPath) ProtoMessage() {} func (x *ObjectPath) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[11] + mi := &file_blobber_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -707,7 +841,7 @@ func (x *ObjectPath) ProtoReflect() protoreflect.Message { // Deprecated: Use ObjectPath.ProtoReflect.Descriptor instead. func (*ObjectPath) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{11} + return file_blobber_proto_rawDescGZIP(), []int{13} } func (x *ObjectPath) GetRootHash() string { @@ -763,7 +897,7 @@ type WriteMarker struct { func (x *WriteMarker) Reset() { *x = WriteMarker{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -776,7 +910,7 @@ func (x *WriteMarker) String() string { func (*WriteMarker) ProtoMessage() {} func (x *WriteMarker) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[12] + mi := &file_blobber_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -789,7 +923,7 @@ func (x *WriteMarker) ProtoReflect() protoreflect.Message { // Deprecated: Use WriteMarker.ProtoReflect.Descriptor instead. func (*WriteMarker) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{12} + return file_blobber_proto_rawDescGZIP(), []int{14} } func (x *WriteMarker) GetAllocationRoot() string { @@ -862,7 +996,7 @@ type ListEntitiesRequest struct { func (x *ListEntitiesRequest) Reset() { *x = ListEntitiesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -875,7 +1009,7 @@ func (x *ListEntitiesRequest) String() string { func (*ListEntitiesRequest) ProtoMessage() {} func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[13] + mi := &file_blobber_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -888,7 +1022,7 @@ func (x *ListEntitiesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ListEntitiesRequest.ProtoReflect.Descriptor instead. func (*ListEntitiesRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{13} + return file_blobber_proto_rawDescGZIP(), []int{15} } func (x *ListEntitiesRequest) GetPath() string { @@ -932,7 +1066,7 @@ type ListEntitiesResponse struct { func (x *ListEntitiesResponse) Reset() { *x = ListEntitiesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[14] + mi := &file_blobber_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -945,7 +1079,7 @@ func (x *ListEntitiesResponse) String() string { func (*ListEntitiesResponse) ProtoMessage() {} func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[14] + mi := &file_blobber_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -958,7 +1092,7 @@ func (x *ListEntitiesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ListEntitiesResponse.ProtoReflect.Descriptor instead. func (*ListEntitiesResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{14} + return file_blobber_proto_rawDescGZIP(), []int{16} } func (x *ListEntitiesResponse) GetAllocationRoot() string { @@ -995,7 +1129,7 @@ type GetFileStatsRequest struct { func (x *GetFileStatsRequest) Reset() { *x = GetFileStatsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[15] + mi := &file_blobber_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1008,7 +1142,7 @@ func (x *GetFileStatsRequest) String() string { func (*GetFileStatsRequest) ProtoMessage() {} func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[15] + mi := &file_blobber_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1021,7 +1155,7 @@ func (x *GetFileStatsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileStatsRequest.ProtoReflect.Descriptor instead. func (*GetFileStatsRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{15} + return file_blobber_proto_rawDescGZIP(), []int{17} } func (x *GetFileStatsRequest) GetPath() string { @@ -1057,7 +1191,7 @@ type GetFileStatsResponse struct { func (x *GetFileStatsResponse) Reset() { *x = GetFileStatsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[16] + mi := &file_blobber_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1070,7 +1204,7 @@ func (x *GetFileStatsResponse) String() string { func (*GetFileStatsResponse) ProtoMessage() {} func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[16] + mi := &file_blobber_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1083,7 +1217,7 @@ func (x *GetFileStatsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileStatsResponse.ProtoReflect.Descriptor instead. func (*GetFileStatsResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{16} + return file_blobber_proto_rawDescGZIP(), []int{18} } func (x *GetFileStatsResponse) GetMetaData() *FileRef { @@ -1120,7 +1254,7 @@ type FileStats struct { func (x *FileStats) Reset() { *x = FileStats{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[17] + mi := &file_blobber_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1133,7 +1267,7 @@ func (x *FileStats) String() string { func (*FileStats) ProtoMessage() {} func (x *FileStats) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[17] + mi := &file_blobber_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1146,7 +1280,7 @@ func (x *FileStats) ProtoReflect() protoreflect.Message { // Deprecated: Use FileStats.ProtoReflect.Descriptor instead. func (*FileStats) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{17} + return file_blobber_proto_rawDescGZIP(), []int{19} } func (x *FileStats) GetID() int64 { @@ -1233,7 +1367,7 @@ type GetFileMetaDataRequest struct { func (x *GetFileMetaDataRequest) Reset() { *x = GetFileMetaDataRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[18] + mi := &file_blobber_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1246,7 +1380,7 @@ func (x *GetFileMetaDataRequest) String() string { func (*GetFileMetaDataRequest) ProtoMessage() {} func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[18] + mi := &file_blobber_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1259,7 +1393,7 @@ func (x *GetFileMetaDataRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileMetaDataRequest.ProtoReflect.Descriptor instead. func (*GetFileMetaDataRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{18} + return file_blobber_proto_rawDescGZIP(), []int{20} } func (x *GetFileMetaDataRequest) GetPath() string { @@ -1302,7 +1436,7 @@ type GetFileMetaDataResponse struct { func (x *GetFileMetaDataResponse) Reset() { *x = GetFileMetaDataResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1315,7 +1449,7 @@ func (x *GetFileMetaDataResponse) String() string { func (*GetFileMetaDataResponse) ProtoMessage() {} func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[19] + mi := &file_blobber_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1328,7 +1462,7 @@ func (x *GetFileMetaDataResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetFileMetaDataResponse.ProtoReflect.Descriptor instead. func (*GetFileMetaDataResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{19} + return file_blobber_proto_rawDescGZIP(), []int{21} } func (x *GetFileMetaDataResponse) GetMetaData() *FileRef { @@ -1358,7 +1492,7 @@ type CommitMetaTxn struct { func (x *CommitMetaTxn) Reset() { *x = CommitMetaTxn{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1371,7 +1505,7 @@ func (x *CommitMetaTxn) String() string { func (*CommitMetaTxn) ProtoMessage() {} func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1384,7 +1518,7 @@ func (x *CommitMetaTxn) ProtoReflect() protoreflect.Message { // Deprecated: Use CommitMetaTxn.ProtoReflect.Descriptor instead. func (*CommitMetaTxn) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{22} } func (x *CommitMetaTxn) GetRefId() int64 { @@ -1421,7 +1555,7 @@ type Collaborator struct { func (x *Collaborator) Reset() { *x = Collaborator{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1434,7 +1568,7 @@ func (x *Collaborator) String() string { func (*Collaborator) ProtoMessage() {} func (x *Collaborator) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1447,7 +1581,7 @@ func (x *Collaborator) ProtoReflect() protoreflect.Message { // Deprecated: Use Collaborator.ProtoReflect.Descriptor instead. func (*Collaborator) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{23} } func (x *Collaborator) GetRefId() int64 { @@ -1482,7 +1616,7 @@ type GetAllocationRequest struct { func (x *GetAllocationRequest) Reset() { *x = GetAllocationRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1495,7 +1629,7 @@ func (x *GetAllocationRequest) String() string { func (*GetAllocationRequest) ProtoMessage() {} func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1508,7 +1642,7 @@ func (x *GetAllocationRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationRequest.ProtoReflect.Descriptor instead. func (*GetAllocationRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{24} } func (x *GetAllocationRequest) GetId() string { @@ -1529,7 +1663,7 @@ type GetAllocationResponse struct { func (x *GetAllocationResponse) Reset() { *x = GetAllocationResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1542,7 +1676,7 @@ func (x *GetAllocationResponse) String() string { func (*GetAllocationResponse) ProtoMessage() {} func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[23] + mi := &file_blobber_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1555,7 +1689,7 @@ func (x *GetAllocationResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetAllocationResponse.ProtoReflect.Descriptor instead. func (*GetAllocationResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{23} + return file_blobber_proto_rawDescGZIP(), []int{25} } func (x *GetAllocationResponse) GetAllocation() *Allocation { @@ -1592,7 +1726,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1605,7 +1739,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[24] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1618,7 +1752,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{24} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *Allocation) GetID() string { @@ -1755,7 +1889,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[25] + mi := &file_blobber_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1768,7 +1902,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[25] + mi := &file_blobber_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1781,7 +1915,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{25} + return file_blobber_proto_rawDescGZIP(), []int{27} } func (x *Term) GetID() int64 { @@ -1832,7 +1966,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1845,7 +1979,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1858,7 +1992,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{28} } func (x *FileRef) GetType() string { @@ -1916,7 +2050,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1929,7 +2063,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1942,7 +2076,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{27} + return file_blobber_proto_rawDescGZIP(), []int{29} } func (x *FileMetaData) GetType() string { @@ -2133,7 +2267,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2146,7 +2280,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2159,7 +2293,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{28} + return file_blobber_proto_rawDescGZIP(), []int{30} } func (x *DirMetaData) GetType() string { @@ -2239,58 +2373,59 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x22, 0x60, 0x0a, 0x14, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, - 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x22, 0x9b, 0x01, 0x0a, 0x13, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, + 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x14, 0x0a, - 0x05, 0x70, 0x61, 0x74, 0x68, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70, 0x61, - 0x74, 0x68, 0x73, 0x22, 0x31, 0x0a, 0x15, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, - 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, - 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, - 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0x77, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, - 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, - 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x21, 0x0a, 0x0c, - 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0b, 0x77, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, - 0xbc, 0x01, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x27, 0x0a, 0x0f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x42, 0x0a, 0x0c, 0x77, - 0x72, 0x69, 0x74, 0x65, 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, - 0x65, 0x72, 0x52, 0x0b, 0x77, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, - 0x23, 0x0a, 0x0d, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x65, 0x73, - 0x73, 0x61, 0x67, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x22, 0x4a, - 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, - 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, - 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, - 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, - 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, - 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, - 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, - 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1b, 0x0a, 0x09, 0x63, 0x6f, 0x6c, + 0x6c, 0x61, 0x62, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, 0x6f, + 0x6c, 0x6c, 0x61, 0x62, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x12, 0x12, + 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x22, + 0x78, 0x0a, 0x14, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, + 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, + 0x65, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, + 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, + 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x60, 0x0a, 0x14, 0x43, 0x61, 0x6c, + 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x61, 0x74, 0x68, 0x73, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x70, 0x61, 0x74, 0x68, 0x73, 0x22, 0x31, 0x0a, 0x15, 0x43, + 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0x77, + 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, + 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, + 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x21, 0x0a, 0x0c, 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x77, 0x72, 0x69, 0x74, + 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xbc, 0x01, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x27, 0x0a, 0x0f, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0e, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x6f, 0x6f, 0x74, 0x12, 0x42, 0x0a, 0x0c, 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, + 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x0b, 0x77, 0x72, 0x69, 0x74, + 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x23, 0x0a, 0x0d, 0x65, 0x72, 0x72, 0x6f, 0x72, + 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, + 0x65, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x18, 0x0a, 0x07, + 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, + 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x22, 0x4a, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, + 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, @@ -2299,369 +2434,394 @@ var file_blobber_proto_rawDesc = []byte{ 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, - 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, - 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x57, 0x4d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, + 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, + 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x52, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, + 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, + 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, 0x0d, 0x52, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, + 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, + 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, + 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, + 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, + 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, + 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, + 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, + 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, - 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, - 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, - 0x69, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, - 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, - 0x1a, 0x0a, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, - 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, - 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, - 0x72, 0x52, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, - 0x72, 0x6b, 0x65, 0x72, 0x22, 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, - 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x2f, 0x0a, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, + 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, + 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, + 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, + 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, + 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, + 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, + 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, + 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, + 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, + 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, + 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, + 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, + 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, + 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, + 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, + 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, + 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, + 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, + 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, + 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, + 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, + 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, + 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, + 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, + 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, + 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, + 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, + 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, + 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, + 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, + 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, + 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, + 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, + 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, + 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, + 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, + 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, + 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, + 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, + 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, + 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, + 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, + 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, + 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, + 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, - 0x12, 0x2f, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, + 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, + 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, + 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, + 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, + 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, + 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, + 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, + 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, - 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, - 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, - 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, - 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, - 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, - 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, - 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, - 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, - 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, - 0x13, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, - 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, - 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, - 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, - 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, - 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, - 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, - 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, - 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, - 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, - 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, - 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0x84, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x33, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, - 0x05, 0x53, 0x74, 0x61, 0x74, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, - 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, - 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, - 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, - 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, - 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, - 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, - 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, - 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, - 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, - 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, - 0x0a, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, - 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, - 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, - 0x78, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, - 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, - 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, - 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, - 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, - 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, - 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, - 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, - 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, - 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, - 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, - 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, - 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x22, 0x5e, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, - 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, - 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, - 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, - 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, - 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, - 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, - 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, - 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, - 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, - 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, - 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, - 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, - 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, - 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, - 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, + 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, + 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, + 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, + 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, + 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, + 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, + 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, + 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, + 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, + 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, - 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, - 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, - 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, - 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, - 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, - 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, - 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, - 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, - 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, - 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, - 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, - 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, - 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, - 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, - 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, - 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, - 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, - 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, - 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, - 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, - 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, - 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, - 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, - 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, - 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, - 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, - 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, - 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, - 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, - 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, - 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, - 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, - 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, - 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, - 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, - 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, - 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, - 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, - 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, - 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, - 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, - 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, - 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, - 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, - 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, - 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, - 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, - 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xff, 0x09, 0x0a, 0x07, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, - 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, - 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, - 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, - 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, - 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, + 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, + 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, + 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, + 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, + 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, + 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, + 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, + 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, + 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, + 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, + 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, + 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, + 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, + 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, + 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, + 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, + 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, + 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, + 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, + 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, + 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, + 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, + 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, + 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, + 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, + 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, + 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, + 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, + 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, + 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, + 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, + 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, + 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, + 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, + 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, + 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, + 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, + 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x32, 0x92, 0x0b, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, + 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, - 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, - 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, - 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, + 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, + 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, + 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, + 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, + 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, + 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, + 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, + 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, + 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, + 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, + 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, + 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, + 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, + 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, - 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, - 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, - 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, - 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, - 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, - 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, - 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x33, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, + 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, + 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, + 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, + 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, + 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, + 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, + 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2676,85 +2836,90 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 29) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 31) var file_blobber_proto_goTypes = []interface{}{ - (*CalculateHashRequest)(nil), // 0: blobber.service.v1.CalculateHashRequest - (*CalculateHashResponse)(nil), // 1: blobber.service.v1.CalculateHashResponse - (*CommitRequest)(nil), // 2: blobber.service.v1.CommitRequest - (*CommitResponse)(nil), // 3: blobber.service.v1.CommitResponse - (*GetObjectTreeRequest)(nil), // 4: blobber.service.v1.GetObjectTreeRequest - (*GetObjectTreeResponse)(nil), // 5: blobber.service.v1.GetObjectTreeResponse - (*GetReferencePathRequest)(nil), // 6: blobber.service.v1.GetReferencePathRequest - (*GetReferencePathResponse)(nil), // 7: blobber.service.v1.GetReferencePathResponse - (*ReferencePath)(nil), // 8: blobber.service.v1.ReferencePath - (*GetObjectPathRequest)(nil), // 9: blobber.service.v1.GetObjectPathRequest - (*GetObjectPathResponse)(nil), // 10: blobber.service.v1.GetObjectPathResponse - (*ObjectPath)(nil), // 11: blobber.service.v1.ObjectPath - (*WriteMarker)(nil), // 12: blobber.service.v1.WriteMarker - (*ListEntitiesRequest)(nil), // 13: blobber.service.v1.ListEntitiesRequest - (*ListEntitiesResponse)(nil), // 14: blobber.service.v1.ListEntitiesResponse - (*GetFileStatsRequest)(nil), // 15: blobber.service.v1.GetFileStatsRequest - (*GetFileStatsResponse)(nil), // 16: blobber.service.v1.GetFileStatsResponse - (*FileStats)(nil), // 17: blobber.service.v1.FileStats - (*GetFileMetaDataRequest)(nil), // 18: blobber.service.v1.GetFileMetaDataRequest - (*GetFileMetaDataResponse)(nil), // 19: blobber.service.v1.GetFileMetaDataResponse - (*CommitMetaTxn)(nil), // 20: blobber.service.v1.CommitMetaTxn - (*Collaborator)(nil), // 21: blobber.service.v1.Collaborator - (*GetAllocationRequest)(nil), // 22: blobber.service.v1.GetAllocationRequest - (*GetAllocationResponse)(nil), // 23: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 24: blobber.service.v1.Allocation - (*Term)(nil), // 25: blobber.service.v1.Term - (*FileRef)(nil), // 26: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 27: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 28: blobber.service.v1.DirMetaData + (*CollaboratorRequest)(nil), // 0: blobber.service.v1.CollaboratorRequest + (*CollaboratorResponse)(nil), // 1: blobber.service.v1.CollaboratorResponse + (*CalculateHashRequest)(nil), // 2: blobber.service.v1.CalculateHashRequest + (*CalculateHashResponse)(nil), // 3: blobber.service.v1.CalculateHashResponse + (*CommitRequest)(nil), // 4: blobber.service.v1.CommitRequest + (*CommitResponse)(nil), // 5: blobber.service.v1.CommitResponse + (*GetObjectTreeRequest)(nil), // 6: blobber.service.v1.GetObjectTreeRequest + (*GetObjectTreeResponse)(nil), // 7: blobber.service.v1.GetObjectTreeResponse + (*GetReferencePathRequest)(nil), // 8: blobber.service.v1.GetReferencePathRequest + (*GetReferencePathResponse)(nil), // 9: blobber.service.v1.GetReferencePathResponse + (*ReferencePath)(nil), // 10: blobber.service.v1.ReferencePath + (*GetObjectPathRequest)(nil), // 11: blobber.service.v1.GetObjectPathRequest + (*GetObjectPathResponse)(nil), // 12: blobber.service.v1.GetObjectPathResponse + (*ObjectPath)(nil), // 13: blobber.service.v1.ObjectPath + (*WriteMarker)(nil), // 14: blobber.service.v1.WriteMarker + (*ListEntitiesRequest)(nil), // 15: blobber.service.v1.ListEntitiesRequest + (*ListEntitiesResponse)(nil), // 16: blobber.service.v1.ListEntitiesResponse + (*GetFileStatsRequest)(nil), // 17: blobber.service.v1.GetFileStatsRequest + (*GetFileStatsResponse)(nil), // 18: blobber.service.v1.GetFileStatsResponse + (*FileStats)(nil), // 19: blobber.service.v1.FileStats + (*GetFileMetaDataRequest)(nil), // 20: blobber.service.v1.GetFileMetaDataRequest + (*GetFileMetaDataResponse)(nil), // 21: blobber.service.v1.GetFileMetaDataResponse + (*CommitMetaTxn)(nil), // 22: blobber.service.v1.CommitMetaTxn + (*Collaborator)(nil), // 23: blobber.service.v1.Collaborator + (*GetAllocationRequest)(nil), // 24: blobber.service.v1.GetAllocationRequest + (*GetAllocationResponse)(nil), // 25: blobber.service.v1.GetAllocationResponse + (*Allocation)(nil), // 26: blobber.service.v1.Allocation + (*Term)(nil), // 27: blobber.service.v1.Term + (*FileRef)(nil), // 28: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 29: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 30: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ - 12, // 0: blobber.service.v1.CommitResponse.write_marker:type_name -> blobber.service.v1.WriteMarker - 8, // 1: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 12, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 8, // 3: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 12, // 4: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 26, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef - 8, // 6: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath - 11, // 7: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath - 12, // 8: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 26, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 26, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 26, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 26, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 26, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 26, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef - 17, // 15: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 26, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef - 21, // 17: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 24, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 25, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 27, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 28, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 20, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 22, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 18, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 15, // 25: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 13, // 26: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 9, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest - 6, // 28: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest - 4, // 29: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 2, // 30: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest - 0, // 31: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest - 23, // 32: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 19, // 33: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 16, // 34: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 14, // 35: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 10, // 36: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 7, // 37: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 5, // 38: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 3, // 39: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 1, // 40: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 32, // [32:41] is the sub-list for method output_type - 23, // [23:32] is the sub-list for method input_type - 23, // [23:23] is the sub-list for extension type_name - 23, // [23:23] is the sub-list for extension extendee - 0, // [0:23] is the sub-list for field type_name + 23, // 0: blobber.service.v1.CollaboratorResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 14, // 1: blobber.service.v1.CommitResponse.write_marker:type_name -> blobber.service.v1.WriteMarker + 10, // 2: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 14, // 3: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 10, // 4: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath + 14, // 5: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker + 28, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 10, // 7: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath + 13, // 8: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath + 14, // 9: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker + 28, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 28, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 28, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 28, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 28, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 28, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 19, // 16: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats + 28, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 23, // 18: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 26, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 27, // 20: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 29, // 21: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 30, // 22: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 22, // 23: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 24, // 24: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 20, // 25: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 17, // 26: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 15, // 27: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 11, // 28: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 8, // 29: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest + 6, // 30: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest + 4, // 31: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest + 2, // 32: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest + 0, // 33: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest + 25, // 34: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 21, // 35: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 18, // 36: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 16, // 37: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 12, // 38: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 9, // 39: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 7, // 40: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 5, // 41: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 3, // 42: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 1, // 43: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse + 34, // [34:44] is the sub-list for method output_type + 24, // [24:34] is the sub-list for method input_type + 24, // [24:24] is the sub-list for extension type_name + 24, // [24:24] is the sub-list for extension extendee + 0, // [0:24] is the sub-list for field type_name } func init() { file_blobber_proto_init() } @@ -2764,7 +2929,7 @@ func file_blobber_proto_init() { } if !protoimpl.UnsafeEnabled { file_blobber_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CalculateHashRequest); i { + switch v := v.(*CollaboratorRequest); i { case 0: return &v.state case 1: @@ -2776,7 +2941,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CalculateHashResponse); i { + switch v := v.(*CollaboratorResponse); i { case 0: return &v.state case 1: @@ -2788,7 +2953,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CommitRequest); i { + switch v := v.(*CalculateHashRequest); i { case 0: return &v.state case 1: @@ -2800,7 +2965,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CommitResponse); i { + switch v := v.(*CalculateHashResponse); i { case 0: return &v.state case 1: @@ -2812,7 +2977,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectTreeRequest); i { + switch v := v.(*CommitRequest); i { case 0: return &v.state case 1: @@ -2824,7 +2989,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectTreeResponse); i { + switch v := v.(*CommitResponse); i { case 0: return &v.state case 1: @@ -2836,7 +3001,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetReferencePathRequest); i { + switch v := v.(*GetObjectTreeRequest); i { case 0: return &v.state case 1: @@ -2848,7 +3013,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetReferencePathResponse); i { + switch v := v.(*GetObjectTreeResponse); i { case 0: return &v.state case 1: @@ -2860,7 +3025,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReferencePath); i { + switch v := v.(*GetReferencePathRequest); i { case 0: return &v.state case 1: @@ -2872,7 +3037,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathRequest); i { + switch v := v.(*GetReferencePathResponse); i { case 0: return &v.state case 1: @@ -2884,7 +3049,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetObjectPathResponse); i { + switch v := v.(*ReferencePath); i { case 0: return &v.state case 1: @@ -2896,7 +3061,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ObjectPath); i { + switch v := v.(*GetObjectPathRequest); i { case 0: return &v.state case 1: @@ -2908,7 +3073,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*WriteMarker); i { + switch v := v.(*GetObjectPathResponse); i { case 0: return &v.state case 1: @@ -2920,7 +3085,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesRequest); i { + switch v := v.(*ObjectPath); i { case 0: return &v.state case 1: @@ -2932,7 +3097,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListEntitiesResponse); i { + switch v := v.(*WriteMarker); i { case 0: return &v.state case 1: @@ -2944,7 +3109,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsRequest); i { + switch v := v.(*ListEntitiesRequest); i { case 0: return &v.state case 1: @@ -2956,7 +3121,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileStatsResponse); i { + switch v := v.(*ListEntitiesResponse); i { case 0: return &v.state case 1: @@ -2968,7 +3133,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileStats); i { + switch v := v.(*GetFileStatsRequest); i { case 0: return &v.state case 1: @@ -2980,7 +3145,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataRequest); i { + switch v := v.(*GetFileStatsResponse); i { case 0: return &v.state case 1: @@ -2992,7 +3157,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetFileMetaDataResponse); i { + switch v := v.(*FileStats); i { case 0: return &v.state case 1: @@ -3004,7 +3169,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CommitMetaTxn); i { + switch v := v.(*GetFileMetaDataRequest); i { case 0: return &v.state case 1: @@ -3016,7 +3181,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Collaborator); i { + switch v := v.(*GetFileMetaDataResponse); i { case 0: return &v.state case 1: @@ -3028,7 +3193,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationRequest); i { + switch v := v.(*CommitMetaTxn); i { case 0: return &v.state case 1: @@ -3040,7 +3205,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetAllocationResponse); i { + switch v := v.(*Collaborator); i { case 0: return &v.state case 1: @@ -3052,7 +3217,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*GetAllocationRequest); i { case 0: return &v.state case 1: @@ -3064,7 +3229,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*GetAllocationResponse); i { case 0: return &v.state case 1: @@ -3076,7 +3241,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -3088,7 +3253,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -3100,6 +3265,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -3118,7 +3307,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 29, + NumMessages: 31, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index a563e0829..1eb4630d4 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -623,6 +623,74 @@ func local_request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtim } +func request_Blobber_Collaborator_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CollaboratorRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := client.Collaborator(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_Collaborator_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CollaboratorRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := server.Collaborator(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterBlobberHandlerServer registers the http handlers for service Blobber to "mux". // UnaryRPC :call BlobberServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -836,6 +904,29 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) + mux.Handle("POST", pattern_Blobber_Collaborator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/Collaborator") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_Collaborator_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_Collaborator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -1057,6 +1148,26 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) + mux.Handle("POST", pattern_Blobber_Collaborator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/Collaborator") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_Collaborator_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_Collaborator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -1078,6 +1189,8 @@ var ( pattern_Blobber_Commit_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "connection", "commit", "allocation"}, "")) pattern_Blobber_CalculateHash_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "calculatehash", "allocation"}, "")) + + pattern_Blobber_Collaborator_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "collaborator", "allocation"}, "")) ) var ( @@ -1098,4 +1211,6 @@ var ( forward_Blobber_Commit_0 = runtime.ForwardResponseMessage forward_Blobber_CalculateHash_0 = runtime.ForwardResponseMessage + + forward_Blobber_Collaborator_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 189508c67..eb39a53a6 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -26,6 +26,7 @@ type BlobberClient interface { GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) Commit(ctx context.Context, in *CommitRequest, opts ...grpc.CallOption) (*CommitResponse, error) CalculateHash(ctx context.Context, in *CalculateHashRequest, opts ...grpc.CallOption) (*CalculateHashResponse, error) + Collaborator(ctx context.Context, in *CollaboratorRequest, opts ...grpc.CallOption) (*CollaboratorResponse, error) } type blobberClient struct { @@ -117,6 +118,15 @@ func (c *blobberClient) CalculateHash(ctx context.Context, in *CalculateHashRequ return out, nil } +func (c *blobberClient) Collaborator(ctx context.Context, in *CollaboratorRequest, opts ...grpc.CallOption) (*CollaboratorResponse, error) { + out := new(CollaboratorResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/Collaborator", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -130,6 +140,7 @@ type BlobberServer interface { GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) Commit(context.Context, *CommitRequest) (*CommitResponse, error) CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) + Collaborator(context.Context, *CollaboratorRequest) (*CollaboratorResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -164,6 +175,9 @@ func (UnimplementedBlobberServer) Commit(context.Context, *CommitRequest) (*Comm func (UnimplementedBlobberServer) CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CalculateHash not implemented") } +func (UnimplementedBlobberServer) Collaborator(context.Context, *CollaboratorRequest) (*CollaboratorResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Collaborator not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -339,6 +353,24 @@ func _Blobber_CalculateHash_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } +func _Blobber_Collaborator_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CollaboratorRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).Collaborator(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/Collaborator", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).Collaborator(ctx, req.(*CollaboratorRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Blobber_serviceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), @@ -379,6 +411,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "CalculateHash", Handler: _Blobber_CalculateHash_Handler, }, + { + MethodName: "Collaborator", + Handler: _Blobber_Collaborator_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 7f8865b18..72e91b951 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -51,11 +51,31 @@ service Blobber { } rpc CalculateHash(CalculateHashRequest) returns (CalculateHashResponse) { - option (google.api.http) = { - post: "/v2/file/calculatehash/{allocation}" - body: "*" - }; - } + option (google.api.http) = { + post: "/v2/file/calculatehash/{allocation}" + body: "*" + }; + } + + rpc Collaborator(CollaboratorRequest) returns (CollaboratorResponse) { + option (google.api.http) = { + post: "/v2/file/collaborator/{allocation}" + body: "*" + }; + } +} + +message CollaboratorRequest { + string allocation = 1; + string collab_id = 2; + string method = 3; + string path = 4; + string path_hash = 5; +} + +message CollaboratorResponse { + string message = 1; + repeated Collaborator Collaborators = 2; } message CalculateHashRequest { diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index eaa7e4cd1..1ed6777f4 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -107,3 +107,22 @@ func GetCalculateHashResponseHandler(response *blobbergrpc.CalculateHashResponse return result } + +func CollaboratorResponse(response *blobbergrpc.CollaboratorResponse) interface{} { + if msg := response.GetMessage(); msg != "" { + return struct { + Msg string `json:"msg"` + }{Msg: msg} + } + + if collaborators := response.GetCollaborators(); collaborators != nil { + collabs := make([]reference.Collaborator, 0, len(collaborators)) + for _, c := range collaborators { + collabs = append(collabs, *GRPCCollaboratorToCollaborator(c)) + } + + return collabs + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 9800ae8d8..6e132e5e3 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -3,6 +3,7 @@ package handler import ( "context" "encoding/json" + "net/http" "strconv" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" @@ -488,3 +489,97 @@ func (b *blobberGRPCService) CalculateHash(ctx context.Context, req *blobbergrpc return &blobbergrpc.CalculateHashResponse{Message: "Hash recalculated for the given paths"}, nil } + +func (b *blobberGRPCService) Collaborator(ctx context.Context, req *blobbergrpc.CollaboratorRequest) (*blobbergrpc.CollaboratorResponse, error) { + allocationTx := req.Allocation + allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, true) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) + } + + md := GetGRPCMetaDataFromCtx(ctx) + allocationID := allocationObj.ID + + valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) + if !valid || err != nil { + return nil, common.NewError("invalid_signature", "Invalid signature") + } + + clientID := md.Client + + pathHash := req.PathHash + path := req.Path + if len(pathHash) == 0 { + if len(path) == 0 { + return nil, common.NewError("invalid_parameters", "Invalid path") + } + pathHash = reference.GetReferenceLookup(allocationID, path) + } + + fileRef, err := b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, pathHash) + if err != nil { + return nil, common.NewError("invalid_parameters", "Invalid file path. "+err.Error()) + } + + if fileRef.Type != reference.FILE { + return nil, common.NewError("invalid_parameters", "Path is not a file.") + } + + collabClientID := req.CollabId + if len(collabClientID) == 0 { + return nil, common.NewError("invalid_parameter", "collab_id not present in the params") + } + + var msg string + + switch req.GetMethod() { + case http.MethodPost: + if len(clientID) == 0 || clientID != allocationObj.OwnerID { + return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + + if b.packageHandler.IsACollaborator(ctx, fileRef.ID, collabClientID) { + msg = "Given client ID is already a collaborator" + return &blobbergrpc.CollaboratorResponse{Message: msg}, nil + } + + if err := b.packageHandler.AddCollaborator(ctx, fileRef.ID, collabClientID); err != nil { + return nil, common.NewError("add_collaborator_failed", "Failed to add collaborator with err :"+err.Error()) + } + + msg = "Added collaborator successfully" + + case http.MethodGet: + collaborators, err := b.packageHandler.GetCollaborators(ctx, fileRef.ID) + if err != nil { + return nil, common.NewError("get_collaborator_failed", "Failed to get collaborators from refID with err:"+err.Error()) + } + + var collaboratorsGRPC []*blobbergrpc.Collaborator + for _, c := range collaborators { + collaboratorsGRPC = append(collaboratorsGRPC, convert.CollaboratorToGRPCCollaborator(&c)) + } + + return &blobbergrpc.CollaboratorResponse{ + Collaborators: collaboratorsGRPC, + }, nil + + case http.MethodDelete: + if len(clientID) == 0 || clientID != allocationObj.OwnerID { + return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + } + + if err := b.packageHandler.RemoveCollaborator(ctx, fileRef.ID, collabClientID); err != nil { + return nil, common.NewError("delete_collaborator_failed", "Failed to delete collaborator from refID with err:"+err.Error()) + } + + msg = "Removed collaborator successfully" + + default: + return nil, common.NewError("invalid_method", "Invalid method used. Use POST/GET/DELETE instead") + } + + return &blobbergrpc.CollaboratorResponse{ + Message: msg, + }, nil +} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 2ed96f796..573d40093 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -45,7 +45,7 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler(svc))))).Methods("POST") r.HandleFunc("/v1/file/commitmetatxn/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitMetaTxnHandler)))) - r.HandleFunc("/v1/file/collaborator/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CollaboratorHandler)))) + r.HandleFunc("/v1/file/collaborator/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CollaboratorHandler(svc))))) r.HandleFunc("/v1/file/calculatehash/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CalculateHashHandler(svc))))).Methods(http.MethodPost) //object info related apis @@ -172,15 +172,23 @@ func CommitMetaTxnHandler(ctx context.Context, r *http.Request) (interface{}, er return response, nil } -func CollaboratorHandler(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerContext(ctx, r) +func CollaboratorHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { + return func(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerGRPCContext(ctx, r) - response, err := storageHandler.AddCollaborator(ctx, r) - if err != nil { - return nil, err - } + response, err := svc.Collaborator(ctx, &blobbergrpc.CollaboratorRequest{ + Allocation: mux.Vars(r)["allocation"], + CollabId: r.FormValue("collab_id"), + Method: r.Method, + Path: r.FormValue("path"), + PathHash: r.FormValue("path_hash"), + }) + if err != nil { + return nil, err + } - return response, nil + return convert.CollaboratorResponse(response), nil + } } func FileStatsHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go index 0942083ee..714cbb755 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/handler_test.go @@ -131,7 +131,7 @@ func setupHandlers() (*mux.Router, map[string]string) { collName := "Collaborator" router.HandleFunc(collPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(CollaboratorHandler), + WithReadOnlyConnection(CollaboratorHandler(svc)), ), ), ).Name(collName) diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index eea3de31f..551226e6d 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -34,6 +34,8 @@ type PackageHandler interface { GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) IsACollaborator(ctx context.Context, refID int64, clientID string) bool + AddCollaborator(ctx context.Context, refID int64, clientID string) error + RemoveCollaborator(ctx context.Context, refID int64, clientID string) error GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) GetWriteMarkerEntity(ctx context.Context, allocation_root string) (*writemarker.WriteMarkerEntity, error) GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) @@ -108,3 +110,11 @@ func (r *packageHandler) GetCollaborators(ctx context.Context, refID int64) ([]r func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { return reference.IsACollaborator(ctx, refID, clientID) } + +func (r *packageHandler) AddCollaborator(ctx context.Context, refID int64, clientID string) error { + return reference.AddCollaborator(ctx, refID, clientID) +} + +func (r *packageHandler) RemoveCollaborator(ctx context.Context, refID int64, clientID string) error { + return reference.RemoveCollaborator(ctx, refID, clientID) +} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index e7ad4bde3..78a15bd2b 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -1,4 +1,4 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. +// Code generated by mockery 2.7.5. DO NOT EDIT. package mocks @@ -21,6 +21,20 @@ type PackageHandler struct { mock.Mock } +// AddCollaborator provides a mock function with given fields: ctx, refID, clientID +func (_m *PackageHandler) AddCollaborator(ctx context.Context, refID int64, clientID string) error { + ret := _m.Called(ctx, refID, clientID) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { + r0 = rf(ctx, refID, clientID) + } else { + r0 = ret.Error(0) + } + + return r0 +} + // ApplyChanges provides a mock function with given fields: connectionObj, ctx, allocationRoot func (_m *PackageHandler) ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error { ret := _m.Called(connectionObj, ctx, allocationRoot) @@ -302,6 +316,20 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } +// RemoveCollaborator provides a mock function with given fields: ctx, refID, clientID +func (_m *PackageHandler) RemoveCollaborator(ctx context.Context, refID int64, clientID string) error { + ret := _m.Called(ctx, refID, clientID) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { + r0 = rf(ctx, refID, clientID) + } else { + r0 = ret.Error(0) + } + + return r0 +} + // UpdateAllocationAndCommitChanges provides a mock function with given fields: ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot func (_m *PackageHandler) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { ret := _m.Called(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 3ab5ce83a..400c542e1 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -122,6 +122,44 @@ ] } }, + "/v2/file/collaborator/{allocation}": { + "post": { + "operationId": "Blobber_Collaborator", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1CollaboratorResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1CollaboratorRequest" + } + } + ], + "tags": [ + "Blobber" + ] + } + }, "/v2/file/list/{allocation}": { "get": { "operationId": "Blobber_ListEntities", @@ -515,6 +553,40 @@ } } }, + "v1CollaboratorRequest": { + "type": "object", + "properties": { + "allocation": { + "type": "string" + }, + "collabId": { + "type": "string" + }, + "method": { + "type": "string" + }, + "path": { + "type": "string" + }, + "pathHash": { + "type": "string" + } + } + }, + "v1CollaboratorResponse": { + "type": "object", + "properties": { + "message": { + "type": "string" + }, + "Collaborators": { + "type": "array", + "items": { + "$ref": "#/definitions/v1Collaborator" + } + } + } + }, "v1CommitMetaTxn": { "type": "object", "properties": { From 9dc62859a8fb61b54ba9a72eed9fd0146b279309 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Thu, 3 Jun 2021 00:14:52 +0530 Subject: [PATCH 099/183] reviews applied --- .../allocation/allocationchange.go | 36 ----- .../blobbercore/blobbergrpc/blobber.pb.go | 2 +- .../blobbercore/handler/handler_test.go | 65 ++++++++ .../0chain.net/blobbercore/handler/helper.go | 11 +- .../handler/object_operation_grpc_handler.go | 33 ++-- .../object_operation_grpc_handler_test.go | 48 +++--- .../mocks/IAllocationChangeCollector.go | 148 ------------------ .../blobbercore/mocks/PackageHandler.go | 22 ++- 8 files changed, 124 insertions(+), 241 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go diff --git a/code/go/0chain.net/blobbercore/allocation/allocationchange.go b/code/go/0chain.net/blobbercore/allocation/allocationchange.go index 967be49be..e3de29dc9 100644 --- a/code/go/0chain.net/blobbercore/allocation/allocationchange.go +++ b/code/go/0chain.net/blobbercore/allocation/allocationchange.go @@ -38,22 +38,6 @@ type AllocationChangeProcessor interface { Marshal() (string, error) Unmarshal(string) error } - -type IAllocationChangeCollector interface { - TableName() string - AddChange(allocationChange *AllocationChange, changeProcessor AllocationChangeProcessor) - Save(ctx context.Context) error - ComputeProperties() - ApplyChanges(ctx context.Context, allocationRoot string) error - CommitToFileStore(ctx context.Context) error - DeleteChanges(ctx context.Context) - GetAllocationID() string - GetConnectionID() string - GetClientID() string - GetSize() int64 - SetSize(size int64) -} - type AllocationChangeCollector struct { ConnectionID string `gorm:"column:connection_id;primary_key"` AllocationID string `gorm:"column:allocation_id"` @@ -185,23 +169,3 @@ func (a *AllocationChangeCollector) DeleteChanges(ctx context.Context) { } } } - -func (cc *AllocationChangeCollector) GetAllocationID() string { - return cc.AllocationID -} - -func (cc *AllocationChangeCollector) GetConnectionID() string { - return cc.ConnectionID -} - -func (cc *AllocationChangeCollector) GetClientID() string { - return cc.ClientID -} - -func (cc *AllocationChangeCollector) GetSize() int64 { - return cc.Size -} - -func (cc *AllocationChangeCollector) SetSize(size int64) { - cc.Size = size -} diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 211a72a35..7459b0f28 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 -// protoc v3.17.0 +// protoc v3.6.1 // source: blobber.proto package blobbergrpc diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go index e3af458ea..0ef9a7cf5 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/handler_test.go @@ -271,6 +271,10 @@ func TestHandlers_Requiring_Signature(t *testing.T) { t.Fatal(err) } + if name == `Upload` { + return uploadReq(t, router, alloc, handlers, sch) + } + return r }(), }, @@ -309,6 +313,10 @@ func TestHandlers_Requiring_Signature(t *testing.T) { r.Header.Set(common.ClientSignatureHeader, sign) r.Header.Set(common.ClientHeader, alloc.OwnerID) + if name == `Upload` { + return uploadReq(t, router, alloc, handlers, sch) + } + return r }(), }, @@ -1033,3 +1041,60 @@ func TestHandlers_Requiring_Signature(t *testing.T) { t.Fatal(err) } } + +func uploadReq(t *testing.T, router *mux.Router, alloc *allocation.Allocation, handlers map[string]string, sch *zcncrypto.BLS0ChainScheme) *http.Request { + handlerName := handlers["/v1/file/upload/{allocation}"] + url, err := router.Get(handlerName).URL("allocation", alloc.Tx) + if err != nil { + t.Fatal() + } + + q := url.Query() + formFieldByt, err := json.Marshal(&allocation.UpdateFileChange{}) + if err != nil { + t.Fatal(err) + } + q.Set("uploadMeta", string(formFieldByt)) + q.Set("path", `/path`) + q.Set("new_name", `new name`) + q.Set("connection_id", `connectionID`) + url.RawQuery = q.Encode() + + body := bytes.NewBuffer(nil) + formWriter := multipart.NewWriter(body) + root, _ := os.Getwd() + file, err := os.Open(root + "/handler_test.go") + if err != nil { + t.Fatal(err) + } + fileField, err := formWriter.CreateFormFile("uploadFile", file.Name()) + if err != nil { + t.Fatal(err) + } + fileB := make([]byte, 0) + if _, err := io.ReadFull(file, fileB); err != nil { + t.Fatal(err) + } + if _, err := fileField.Write(fileB); err != nil { + t.Fatal(err) + } + if err := formWriter.Close(); err != nil { + t.Fatal(err) + } + r, err := http.NewRequest(http.MethodPost, url.String(), body) + if err != nil { + t.Fatal(err) + } + + hash := encryption.Hash("another data") + sign, err := sch.Sign(hash) + if err != nil { + t.Fatal(err) + } + + r.Header.Set("Content-Type", formWriter.FormDataContentType()) + r.Header.Set(common.ClientSignatureHeader, sign) + r.Header.Set(common.ClientHeader, alloc.OwnerID) + + return r +} diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index f69e4ea9c..f081d6ac4 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -41,8 +41,8 @@ type PackageHandler interface { GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) - GetAllocationChanges(ctx context.Context, connectionID string, - allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) + GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) + SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error GetFileStore() filestore.FileStore GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) } @@ -94,8 +94,7 @@ func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clien return reference.IsACollaborator(ctx, refID, clientID) } -func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, - allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { +func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) } @@ -103,3 +102,7 @@ func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID func (r *packageHandler) GetFileStore() filestore.FileStore { return filestore.GetFileStore() } + +func (r packageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + return alloc.Save(ctx) +} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index 5600df442..840fdf082 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -15,22 +15,21 @@ import ( "go.uber.org/zap" ) -func (b *blobberGRPCService) WriteFile(ctx context.Context, r *blobbergrpc.UploadFileRequest) ( - *blobbergrpc.UploadFileResponse, error) { - +func (b *blobberGRPCService) WriteFile(ctx context.Context, r *blobbergrpc.UploadFileRequest) (*blobbergrpc.UploadFileResponse, error) { logger := ctxzap.Extract(ctx) if r.Method == "GET" { return nil, common.NewError("invalid_method", "Invalid method used for the upload URL. Use multi-part form POST / PUT / DELETE instead") } + md := GetGRPCMetaDataFromCtx(ctx) + allocationTx := r.Allocation allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) if err != nil { return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) } - md := GetGRPCMetaDataFromCtx(ctx) valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) if !valid || err != nil { return nil, common.NewError("invalid_signature", "Invalid signature") @@ -56,6 +55,7 @@ func (b *blobberGRPCService) WriteFile(ctx context.Context, r *blobbergrpc.Uploa mutex.Lock() defer mutex.Unlock() + result := &blobbergrpc.UploadFileResponse{} mode := allocation.INSERT_OPERATION if r.Method == "PUT" { mode = allocation.UPDATE_OPERATION @@ -63,7 +63,6 @@ func (b *blobberGRPCService) WriteFile(ctx context.Context, r *blobbergrpc.Uploa mode = allocation.DELETE_OPERATION } - result := &blobbergrpc.UploadFileResponse{} if mode == allocation.DELETE_OPERATION { if allocationObj.OwnerID != clientID && allocationObj.PayerID != clientID { return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner or the payer of the allocation") @@ -118,7 +117,7 @@ func (b *blobberGRPCService) WriteFile(ctx context.Context, r *blobbergrpc.Uploa thumbnailPresent := thumb != nil fileInputData := &filestore.FileInputData{Name: formData.Filename, Path: formData.Path, OnCloud: exisitingFileOnCloud} - fileOutputData, err := b.packageHandler.GetFileStore().WriteFileGRPC(allocationID, fileInputData, grpcOrgFile, connectionObj.GetConnectionID()) + fileOutputData, err := b.packageHandler.GetFileStore().WriteFileGRPC(allocationID, fileInputData, grpcOrgFile, connectionObj.ConnectionID) if err != nil { return nil, common.NewError("upload_error", "Failed to upload the file. "+err.Error()) } @@ -147,7 +146,7 @@ func (b *blobberGRPCService) WriteFile(ctx context.Context, r *blobbergrpc.Uploa if thumbnailPresent { thumbFile := bytes.NewReader(thumb) thumbInputData := &filestore.FileInputData{Name: formData.ThumbnailFilename, Path: formData.Path} - thumbOutputData, err := b.packageHandler.GetFileStore().WriteFileGRPC(allocationID, thumbInputData, thumbFile, connectionObj.GetConnectionID()) + thumbOutputData, err := b.packageHandler.GetFileStore().WriteFileGRPC(allocationID, thumbInputData, thumbFile, connectionObj.ConnectionID) if err != nil { return nil, common.NewError("upload_error", "Failed to upload the thumbnail. "+err.Error()) } @@ -164,11 +163,11 @@ func (b *blobberGRPCService) WriteFile(ctx context.Context, r *blobbergrpc.Uploa } allocationChange := &allocation.AllocationChange{} - allocationChange.ConnectionID = connectionObj.GetConnectionID() + allocationChange.ConnectionID = connectionObj.ConnectionID allocationChange.Size = allocationSize - existingFileRefSize allocationChange.Operation = mode - connectionObj.SetSize(connectionObj.GetSize() + allocationChange.Size) + connectionObj.Size += allocationChange.Size if mode == allocation.INSERT_OPERATION { connectionObj.AddChange(allocationChange, &formData.NewFileChange) } else if mode == allocation.UPDATE_OPERATION { @@ -176,7 +175,7 @@ func (b *blobberGRPCService) WriteFile(ctx context.Context, r *blobbergrpc.Uploa } } - err = connectionObj.Save(ctx) + err = b.packageHandler.SaveAllocationChanges(ctx, connectionObj) if err != nil { logger.Error("Error in writing the connection meta data", zap.Error(err)) return nil, common.NewError("connection_write_error", "Error writing the connection meta data") @@ -185,27 +184,25 @@ func (b *blobberGRPCService) WriteFile(ctx context.Context, r *blobbergrpc.Uploa return result, nil } -func (b *blobberGRPCService) DeleteFile(ctx context.Context, r *blobbergrpc.UploadFileRequest, - connectionObj allocation.IAllocationChangeCollector) (*blobbergrpc.UploadFileResponse, error) { - +func (b *blobberGRPCService) DeleteFile(ctx context.Context, r *blobbergrpc.UploadFileRequest, connectionObj *allocation.AllocationChangeCollector) (*blobbergrpc.UploadFileResponse, error) { path := r.Path if len(path) == 0 { return nil, common.NewError("invalid_parameters", "Invalid path") } - fileRef, _ := b.packageHandler.GetReference(ctx, connectionObj.GetAllocationID(), path) + fileRef, _ := b.packageHandler.GetReference(ctx, connectionObj.AllocationID, path) if fileRef != nil { deleteSize := fileRef.Size allocationChange := &allocation.AllocationChange{} - allocationChange.ConnectionID = connectionObj.GetConnectionID() + allocationChange.ConnectionID = connectionObj.ConnectionID allocationChange.Size = 0 - deleteSize allocationChange.Operation = allocation.DELETE_OPERATION - dfc := &allocation.DeleteFileChange{ConnectionID: connectionObj.GetConnectionID(), - AllocationID: connectionObj.GetAllocationID(), Name: fileRef.Name, + dfc := &allocation.DeleteFileChange{ConnectionID: connectionObj.ConnectionID, + AllocationID: connectionObj.AllocationID, Name: fileRef.Name, Hash: fileRef.Hash, Path: fileRef.Path, Size: deleteSize} - connectionObj.SetSize(connectionObj.GetSize() + allocationChange.Size) + connectionObj.Size += allocationChange.Size connectionObj.AddChange(allocationChange, dfc) result := &blobbergrpc.UploadFileResponse{} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go index 4fc39c5db..3ce586f02 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go @@ -44,15 +44,6 @@ func TestBlobberGRPCService_WriteFile_Success_POST(t *testing.T) { mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). Return(alloc, nil) - mockAllocCollector := &mocks.IAllocationChangeCollector{} - mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) - mockAllocCollector.On(`GetAllocationID`).Return(req.Allocation) - mockAllocCollector.On(`SetSize`, mock.Anything).Return() - mockAllocCollector.On(`GetSize`).Return(int64(1)) - mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() - mockAllocCollector.On(`Save`, mock.Anything).Return(nil) - mockAllocCollector.On(`TableName`).Return(`allocation_connections`) - mockFileStore := &mocks.FileStore{} fileOutput := &filestore.FileOutputData{ Name: "test_file", @@ -64,8 +55,13 @@ func TestBlobberGRPCService_WriteFile_Success_POST(t *testing.T) { fileOutput, nil) mockReferencePackage := &mocks.PackageHandler{} + allocChange := &allocation.AllocationChangeCollector{ + ConnectionID: req.ConnectionId, + } mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, - req.ConnectionId, alloc.ID, alloc.OwnerID).Return(mockAllocCollector, nil) + req.ConnectionId, alloc.ID, alloc.OwnerID).Return(allocChange, nil) + mockReferencePackage.On(`SaveAllocationChanges`, mock.Anything, allocChange). + Return(nil) mockReferencePackage.On(`GetReference`, mock.Anything, alloc.ID, `path`). Return(nil, nil) mockReferencePackage.On(`GetFileStore`). @@ -117,15 +113,6 @@ func TestBlobberGRPCService_WriteFile_Success_PUT(t *testing.T) { mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). Return(alloc, nil) - mockAllocCollector := &mocks.IAllocationChangeCollector{} - mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) - mockAllocCollector.On(`GetAllocationID`).Return(req.Allocation) - mockAllocCollector.On(`SetSize`, mock.Anything).Return() - mockAllocCollector.On(`GetSize`).Return(int64(1)) - mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() - mockAllocCollector.On(`Save`, mock.Anything).Return(nil) - mockAllocCollector.On(`TableName`).Return(`allocation_connections`) - mockFileStore := &mocks.FileStore{} fileOutput := &filestore.FileOutputData{ Name: "test_file", @@ -137,8 +124,13 @@ func TestBlobberGRPCService_WriteFile_Success_PUT(t *testing.T) { fileOutput, nil) mockReferencePackage := &mocks.PackageHandler{} + allocChange := &allocation.AllocationChangeCollector{ + ConnectionID: req.ConnectionId, + } mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, - req.ConnectionId, alloc.ID, alloc.OwnerID).Return(mockAllocCollector, nil) + req.ConnectionId, alloc.ID, alloc.OwnerID).Return(allocChange, nil) + mockReferencePackage.On(`SaveAllocationChanges`, mock.Anything, allocChange). + Return(nil) mockReferencePackage.On(`GetReference`, mock.Anything, alloc.ID, `path`). Return(&reference.Ref{}, nil) mockReferencePackage.On(`GetFileStore`). @@ -189,15 +181,6 @@ func TestBlobberGRPCService_WriteFile_Success_DELETE(t *testing.T) { mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). Return(alloc, nil) - mockAllocCollector := &mocks.IAllocationChangeCollector{} - mockAllocCollector.On(`GetConnectionID`).Return(req.ConnectionId) - mockAllocCollector.On(`GetAllocationID`).Return(alloc.ID) - mockAllocCollector.On(`SetSize`, mock.Anything).Return() - mockAllocCollector.On(`GetSize`).Return(int64(1)) - mockAllocCollector.On(`AddChange`, mock.Anything, mock.Anything).Return() - mockAllocCollector.On(`Save`, mock.Anything).Return(nil) - mockAllocCollector.On(`TableName`).Return(`allocation_connections`) - mockFileStore := &mocks.FileStore{} fileRef := &reference.Ref{ Name: "test_file", @@ -207,8 +190,13 @@ func TestBlobberGRPCService_WriteFile_Success_DELETE(t *testing.T) { } mockReferencePackage := &mocks.PackageHandler{} + allocChange := &allocation.AllocationChangeCollector{ + AllocationID: alloc.ID, + } mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, - req.ConnectionId, alloc.ID, alloc.OwnerID).Return(mockAllocCollector, nil) + req.ConnectionId, alloc.ID, alloc.OwnerID).Return(allocChange, nil) + mockReferencePackage.On(`SaveAllocationChanges`, mock.Anything, allocChange). + Return(nil) mockReferencePackage.On(`GetReference`, mock.Anything, alloc.ID, `path`). Return(fileRef, nil) mockReferencePackage.On(`GetFileStore`). diff --git a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go b/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go deleted file mode 100644 index 37556727b..000000000 --- a/code/go/0chain.net/blobbercore/mocks/IAllocationChangeCollector.go +++ /dev/null @@ -1,148 +0,0 @@ -// Code generated by mockery 2.7.5. DO NOT EDIT. - -package mocks - -import ( - context "context" - - allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - - mock "github.com/stretchr/testify/mock" -) - -// IAllocationChangeCollector is an autogenerated mock type for the IAllocationChangeCollector type -type IAllocationChangeCollector struct { - mock.Mock -} - -// AddChange provides a mock function with given fields: allocationChange, changeProcessor -func (_m *IAllocationChangeCollector) AddChange(allocationChange *allocation.AllocationChange, changeProcessor allocation.AllocationChangeProcessor) { - _m.Called(allocationChange, changeProcessor) -} - -// ApplyChanges provides a mock function with given fields: ctx, allocationRoot -func (_m *IAllocationChangeCollector) ApplyChanges(ctx context.Context, allocationRoot string) error { - ret := _m.Called(ctx, allocationRoot) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, string) error); ok { - r0 = rf(ctx, allocationRoot) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// CommitToFileStore provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) CommitToFileStore(ctx context.Context) error { - ret := _m.Called(ctx) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context) error); ok { - r0 = rf(ctx) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// ComputeProperties provides a mock function with given fields: -func (_m *IAllocationChangeCollector) ComputeProperties() { - _m.Called() -} - -// DeleteChanges provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) DeleteChanges(ctx context.Context) { - _m.Called(ctx) -} - -// GetAllocationID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetAllocationID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetClientID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetClientID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetConnectionID provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetConnectionID() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetSize provides a mock function with given fields: -func (_m *IAllocationChangeCollector) GetSize() int64 { - ret := _m.Called() - - var r0 int64 - if rf, ok := ret.Get(0).(func() int64); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(int64) - } - - return r0 -} - -// Save provides a mock function with given fields: ctx -func (_m *IAllocationChangeCollector) Save(ctx context.Context) error { - ret := _m.Called(ctx) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context) error); ok { - r0 = rf(ctx) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// SetSize provides a mock function with given fields: size -func (_m *IAllocationChangeCollector) SetSize(size int64) { - _m.Called(size) -} - -// TableName provides a mock function with given fields: -func (_m *IAllocationChangeCollector) TableName() string { - ret := _m.Called() - - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 8f21faee0..425e1854e 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -24,15 +24,15 @@ type PackageHandler struct { } // GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID -func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (allocation.IAllocationChangeCollector, error) { +func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { ret := _m.Called(ctx, connectionID, allocationID, clientID) - var r0 allocation.IAllocationChangeCollector - if rf, ok := ret.Get(0).(func(context.Context, string, string, string) allocation.IAllocationChangeCollector); ok { + var r0 *allocation.AllocationChangeCollector + if rf, ok := ret.Get(0).(func(context.Context, string, string, string) *allocation.AllocationChangeCollector); ok { r0 = rf(ctx, connectionID, allocationID, clientID) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(allocation.IAllocationChangeCollector) + r0 = ret.Get(0).(*allocation.AllocationChangeCollector) } } @@ -305,3 +305,17 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } + +// SaveAllocationChanges provides a mock function with given fields: ctx, alloc +func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + ret := _m.Called(ctx, alloc) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(ctx, alloc) + } else { + r0 = ret.Error(0) + } + + return r0 +} From a8d912c11177e830a7dccd7274f7bc7d88e6dae0 Mon Sep 17 00:00:00 2001 From: Vivek V Date: Thu, 3 Jun 2021 17:24:37 +0530 Subject: [PATCH 100/183] :white_check_mark: refs #164, added unit tests --- .../handler/grpc_handler_unit_test.go | 84 +++++++++++++++++++ 1 file changed, 84 insertions(+) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index 99f8d860e..dc0e2d888 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -594,3 +594,87 @@ func TestBlobberGRPCService_CalculateHashNotOwner(t *testing.T) { t.Fatal("expected error: ", err) } } + +func TestBlobberGRPCService_AddCollaboratorSuccess(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + req := &blobbergrpc.CollaboratorRequest{ + Allocation: allocationTx, + Path: "some-path", + CollabId: "12", + Method: "POST", + PathHash: "exampleId:examplePath", + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "12", + common.ClientSignatureHeader: clientSignature, + })) + + mockStorageHandler := new(storageHandlerI) + mockReferencePackage := new(mocks.PackageHandler) + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ + ID: "allocationId", + Tx: req.Allocation, + OwnerID: "12", + OwnerPublicKey: pubKey, + }, nil) + mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ + Name: "test", + Type: reference.FILE, + }, nil) + mockReferencePackage.On("IsACollaborator", mock.Anything, mock.Anything, mock.Anything). + Return(false) + mockReferencePackage.On("AddCollaborator", mock.Anything, mock.Anything, mock.Anything). + Return(nil) + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + resp, err := svc.Collaborator(ctx, req) + if err != nil { + t.Fatal("unexpected error: ", err) + } + + assert.Equal(t, resp.GetMessage(), "Added collaborator successfully") +} + +func TestBlobberGRPCService_AddCollaboratorError(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + req := &blobbergrpc.CollaboratorRequest{ + Allocation: allocationTx, + Path: "some-path", + CollabId: "12", + Method: "POST", + PathHash: "exampleId:examplePath", + } + + ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ + common.ClientHeader: "1", + common.ClientSignatureHeader: clientSignature, + })) + + mockStorageHandler := new(storageHandlerI) + mockReferencePackage := new(mocks.PackageHandler) + mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ + ID: "allocationId", + Tx: req.Allocation, + OwnerID: "12", + OwnerPublicKey: pubKey, + }, nil) + mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ + Name: "test", + Type: reference.FILE, + }, nil) + + svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) + _, err := svc.Collaborator(ctx, req) + if err == nil { + t.Fatal("expected error") + } +} From 2938813c5bf5ad42f606e0ab80266e6c9fe4d29b Mon Sep 17 00:00:00 2001 From: Vivek V Date: Thu, 3 Jun 2021 19:38:50 +0530 Subject: [PATCH 101/183] :white_check_mark: fixes #164, added integration tests --- .../handler/grpc_handler_integration_test.go | 107 ++++++++++++++++++ .../handler/grpc_handler_unit_test.go | 5 +- 2 files changed, 110 insertions(+), 2 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 96b1670cd..7dea657d1 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -6,6 +6,7 @@ import ( "encoding/json" "fmt" "log" + "net/http" "os" "strconv" "testing" @@ -740,4 +741,110 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } } }) + + t.Run("TestCollaborator", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().UnixNano()) + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + fr := reference.Ref{ + AllocationID: "exampleId", + } + + rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + + wm := writemarker.WriteMarker{ + AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + PreviousAllocationRoot: "/", + AllocationID: "exampleId", + Size: 1337, + BlobberID: encryption.Hash(blobberPubKeyBytes), + Timestamp: now, + ClientID: clientId, + } + + wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + if err != nil { + t.Fatal(err) + } + + wm.Signature = wmSig + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CollaboratorRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CollaboratorRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + Allocation: allocationTx, + Method: http.MethodPost, + CollabId: "10", + }, + expectedMessage: "Added collaborator successfully", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CollaboratorRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + Allocation: allocationTx, + Method: http.MethodPost, + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := blobberClient.Collaborator(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetMessage() != tc.expectedMessage { + t.Fatal("failed!") + } + } + }) } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index cc5ce4787..dd6b14f58 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -4,6 +4,7 @@ import ( "context" "errors" "math/rand" + "net/http" "strings" "testing" @@ -682,7 +683,7 @@ func TestBlobberGRPCService_AddCollaboratorSuccess(t *testing.T) { Allocation: allocationTx, Path: "some-path", CollabId: "12", - Method: "POST", + Method: http.MethodPost, PathHash: "exampleId:examplePath", } @@ -727,7 +728,7 @@ func TestBlobberGRPCService_AddCollaboratorError(t *testing.T) { Allocation: allocationTx, Path: "some-path", CollabId: "12", - Method: "POST", + Method: http.MethodPost, PathHash: "exampleId:examplePath", } From 845f4594033df65ff7f1739ca16749228b415dd2 Mon Sep 17 00:00:00 2001 From: Vivek V Date: Thu, 3 Jun 2021 19:52:57 +0530 Subject: [PATCH 102/183] :wrench: fixes #164, added HTTP Methods to handler definition --- code/go/0chain.net/blobbercore/handler/handler.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index c9b4b2dc3..15419835f 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -40,7 +40,7 @@ func SetupHandlers(r *mux.Router) { r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler(svc))))).Methods("POST") r.HandleFunc("/v1/file/commitmetatxn/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitMetaTxnHandler(svc))))).Methods(http.MethodPost) - r.HandleFunc("/v1/file/collaborator/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CollaboratorHandler(svc))))) + r.HandleFunc("/v1/file/collaborator/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CollaboratorHandler(svc))))).Methods(http.MethodGet, http.MethodPost, http.MethodDelete) r.HandleFunc("/v1/file/calculatehash/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CalculateHashHandler(svc))))).Methods(http.MethodPost) //object info related apis From 71d4de55e4c112fd852cd852568bee3664531685 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sat, 5 Jun 2021 20:59:25 +0530 Subject: [PATCH 103/183] conflicts resolved with grpc --- .../blobbercore/blobbergrpc/blobber.pb.go | 572 ++++++++++-------- .../blobbergrpc/blobber_grpc.pb.go | 36 +- .../0chain.net/blobbercore/handler/helper.go | 7 - .../blobbercore/mocks/PackageHandler.go | 30 +- .../blobbercore/openapi/blobber.swagger.json | 16 +- go.sum | 19 - 6 files changed, 357 insertions(+), 323 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 794874f7b..56ac240f7 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1706,7 +1706,7 @@ type UpdateObjectAttributesRequest struct { func (x *UpdateObjectAttributesRequest) Reset() { *x = UpdateObjectAttributesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1719,7 +1719,7 @@ func (x *UpdateObjectAttributesRequest) String() string { func (*UpdateObjectAttributesRequest) ProtoMessage() {} func (x *UpdateObjectAttributesRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1732,7 +1732,7 @@ func (x *UpdateObjectAttributesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateObjectAttributesRequest.ProtoReflect.Descriptor instead. func (*UpdateObjectAttributesRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *UpdateObjectAttributesRequest) GetAllocation() string { @@ -1781,7 +1781,7 @@ type UpdateObjectAttributesResponse struct { func (x *UpdateObjectAttributesResponse) Reset() { *x = UpdateObjectAttributesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1794,7 +1794,7 @@ func (x *UpdateObjectAttributesResponse) String() string { func (*UpdateObjectAttributesResponse) ProtoMessage() {} func (x *UpdateObjectAttributesResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1807,7 +1807,7 @@ func (x *UpdateObjectAttributesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateObjectAttributesResponse.ProtoReflect.Descriptor instead. func (*UpdateObjectAttributesResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{27} } func (x *UpdateObjectAttributesResponse) GetWhoPaysForReads() int64 { @@ -1844,7 +1844,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1857,7 +1857,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1870,7 +1870,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{28} } func (x *Allocation) GetID() string { @@ -2007,7 +2007,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2020,7 +2020,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2033,7 +2033,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{27} + return file_blobber_proto_rawDescGZIP(), []int{29} } func (x *Term) GetID() int64 { @@ -2084,7 +2084,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2097,7 +2097,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2110,7 +2110,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{28} + return file_blobber_proto_rawDescGZIP(), []int{30} } func (x *FileRef) GetType() string { @@ -2168,7 +2168,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2181,7 +2181,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2194,7 +2194,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{29} + return file_blobber_proto_rawDescGZIP(), []int{31} } func (x *FileMetaData) GetType() string { @@ -2385,7 +2385,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2398,7 +2398,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2411,7 +2411,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{30} + return file_blobber_proto_rawDescGZIP(), []int{32} } func (x *DirMetaData) GetType() string { @@ -2719,140 +2719,151 @@ var file_blobber_proto_rawDesc = []byte{ 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, - 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, - 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, - 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, - 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, - 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, - 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, - 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, - 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, - 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, - 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, - 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, - 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, - 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, - 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, - 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, - 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, - 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0x96, 0x0b, 0x0a, - 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb5, 0x01, 0x0a, 0x1d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, + 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, + 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x1e, 0x0a, + 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x22, 0x4d, 0x0a, + 0x1e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, + 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x2b, 0x0a, 0x12, 0x77, 0x68, 0x6f, 0x5f, 0x70, 0x61, 0x79, 0x73, 0x5f, 0x66, 0x6f, 0x72, 0x5f, + 0x72, 0x65, 0x61, 0x64, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x77, 0x68, 0x6f, + 0x50, 0x61, 0x79, 0x73, 0x46, 0x6f, 0x72, 0x52, 0x65, 0x61, 0x64, 0x73, 0x22, 0xb6, 0x04, 0x0a, + 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, + 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, + 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, + 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, + 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, + 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, + 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, + 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, + 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, + 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, + 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, + 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, + 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, + 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, + 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, + 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, + 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, + 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, + 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, + 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, + 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, + 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, + 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, + 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, + 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, + 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, + 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, + 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, + 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, + 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, + 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, + 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, + 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, + 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, + 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, + 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, + 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, + 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, + 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, + 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, + 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, + 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, + 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, + 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, + 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, + 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, + 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, + 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, + 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, + 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, + 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, + 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, + 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, + 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, + 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, + 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, + 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, + 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, + 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, + 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, + 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, + 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, + 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x32, 0xc5, 0x0c, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, + 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, @@ -2888,50 +2899,71 @@ var file_blobber_proto_rawDesc = []byte{ 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, - 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, - 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, - 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, + 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, + 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, + 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, + 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, + 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, + 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, + 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, + 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, + 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, - 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, + 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, - 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, + 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, + 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, - 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, - 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, - 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, + 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, + 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, + 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, + 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, + 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, + 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, + 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, } var ( @@ -2946,39 +2978,41 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 31) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 33) var file_blobber_proto_goTypes = []interface{}{ - (*CalculateHashRequest)(nil), // 0: blobber.service.v1.CalculateHashRequest - (*CalculateHashResponse)(nil), // 1: blobber.service.v1.CalculateHashResponse - (*CommitRequest)(nil), // 2: blobber.service.v1.CommitRequest - (*CommitResponse)(nil), // 3: blobber.service.v1.CommitResponse - (*CommitMetaTxnRequest)(nil), // 4: blobber.service.v1.CommitMetaTxnRequest - (*CommitMetaTxnResponse)(nil), // 5: blobber.service.v1.CommitMetaTxnResponse - (*GetObjectTreeRequest)(nil), // 6: blobber.service.v1.GetObjectTreeRequest - (*GetObjectTreeResponse)(nil), // 7: blobber.service.v1.GetObjectTreeResponse - (*GetReferencePathRequest)(nil), // 8: blobber.service.v1.GetReferencePathRequest - (*GetReferencePathResponse)(nil), // 9: blobber.service.v1.GetReferencePathResponse - (*ReferencePath)(nil), // 10: blobber.service.v1.ReferencePath - (*GetObjectPathRequest)(nil), // 11: blobber.service.v1.GetObjectPathRequest - (*GetObjectPathResponse)(nil), // 12: blobber.service.v1.GetObjectPathResponse - (*ObjectPath)(nil), // 13: blobber.service.v1.ObjectPath - (*WriteMarker)(nil), // 14: blobber.service.v1.WriteMarker - (*ListEntitiesRequest)(nil), // 15: blobber.service.v1.ListEntitiesRequest - (*ListEntitiesResponse)(nil), // 16: blobber.service.v1.ListEntitiesResponse - (*GetFileStatsRequest)(nil), // 17: blobber.service.v1.GetFileStatsRequest - (*GetFileStatsResponse)(nil), // 18: blobber.service.v1.GetFileStatsResponse - (*FileStats)(nil), // 19: blobber.service.v1.FileStats - (*GetFileMetaDataRequest)(nil), // 20: blobber.service.v1.GetFileMetaDataRequest - (*GetFileMetaDataResponse)(nil), // 21: blobber.service.v1.GetFileMetaDataResponse - (*CommitMetaTxn)(nil), // 22: blobber.service.v1.CommitMetaTxn - (*Collaborator)(nil), // 23: blobber.service.v1.Collaborator - (*GetAllocationRequest)(nil), // 24: blobber.service.v1.GetAllocationRequest - (*GetAllocationResponse)(nil), // 25: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 26: blobber.service.v1.Allocation - (*Term)(nil), // 27: blobber.service.v1.Term - (*FileRef)(nil), // 28: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 29: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 30: blobber.service.v1.DirMetaData + (*CalculateHashRequest)(nil), // 0: blobber.service.v1.CalculateHashRequest + (*CalculateHashResponse)(nil), // 1: blobber.service.v1.CalculateHashResponse + (*CommitRequest)(nil), // 2: blobber.service.v1.CommitRequest + (*CommitResponse)(nil), // 3: blobber.service.v1.CommitResponse + (*CommitMetaTxnRequest)(nil), // 4: blobber.service.v1.CommitMetaTxnRequest + (*CommitMetaTxnResponse)(nil), // 5: blobber.service.v1.CommitMetaTxnResponse + (*GetObjectTreeRequest)(nil), // 6: blobber.service.v1.GetObjectTreeRequest + (*GetObjectTreeResponse)(nil), // 7: blobber.service.v1.GetObjectTreeResponse + (*GetReferencePathRequest)(nil), // 8: blobber.service.v1.GetReferencePathRequest + (*GetReferencePathResponse)(nil), // 9: blobber.service.v1.GetReferencePathResponse + (*ReferencePath)(nil), // 10: blobber.service.v1.ReferencePath + (*GetObjectPathRequest)(nil), // 11: blobber.service.v1.GetObjectPathRequest + (*GetObjectPathResponse)(nil), // 12: blobber.service.v1.GetObjectPathResponse + (*ObjectPath)(nil), // 13: blobber.service.v1.ObjectPath + (*WriteMarker)(nil), // 14: blobber.service.v1.WriteMarker + (*ListEntitiesRequest)(nil), // 15: blobber.service.v1.ListEntitiesRequest + (*ListEntitiesResponse)(nil), // 16: blobber.service.v1.ListEntitiesResponse + (*GetFileStatsRequest)(nil), // 17: blobber.service.v1.GetFileStatsRequest + (*GetFileStatsResponse)(nil), // 18: blobber.service.v1.GetFileStatsResponse + (*FileStats)(nil), // 19: blobber.service.v1.FileStats + (*GetFileMetaDataRequest)(nil), // 20: blobber.service.v1.GetFileMetaDataRequest + (*GetFileMetaDataResponse)(nil), // 21: blobber.service.v1.GetFileMetaDataResponse + (*CommitMetaTxn)(nil), // 22: blobber.service.v1.CommitMetaTxn + (*Collaborator)(nil), // 23: blobber.service.v1.Collaborator + (*GetAllocationRequest)(nil), // 24: blobber.service.v1.GetAllocationRequest + (*GetAllocationResponse)(nil), // 25: blobber.service.v1.GetAllocationResponse + (*UpdateObjectAttributesRequest)(nil), // 26: blobber.service.v1.UpdateObjectAttributesRequest + (*UpdateObjectAttributesResponse)(nil), // 27: blobber.service.v1.UpdateObjectAttributesResponse + (*Allocation)(nil), // 28: blobber.service.v1.Allocation + (*Term)(nil), // 29: blobber.service.v1.Term + (*FileRef)(nil), // 30: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 31: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 32: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 14, // 0: blobber.service.v1.CommitResponse.write_marker:type_name -> blobber.service.v1.WriteMarker @@ -2986,23 +3020,23 @@ var file_blobber_proto_depIdxs = []int32{ 14, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 10, // 3: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 14, // 4: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 28, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 10, // 6: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 13, // 7: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 14, // 8: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 28, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 28, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 28, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 28, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 28, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 28, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 30, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 30, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 30, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 30, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 19, // 15: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 28, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 23, // 17: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 26, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 27, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 29, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 30, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 28, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 29, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 31, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 32, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 22, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 24, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 20, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -3014,18 +3048,20 @@ var file_blobber_proto_depIdxs = []int32{ 2, // 30: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest 0, // 31: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest 4, // 32: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest - 25, // 33: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 21, // 34: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 18, // 35: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 16, // 36: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 12, // 37: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 9, // 38: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 7, // 39: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 3, // 40: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 1, // 41: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 5, // 42: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 33, // [33:43] is the sub-list for method output_type - 23, // [23:33] is the sub-list for method input_type + 26, // 33: blobber.service.v1.Blobber.UpdateObjectAttributes:input_type -> blobber.service.v1.UpdateObjectAttributesRequest + 25, // 34: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 21, // 35: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 18, // 36: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 16, // 37: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 12, // 38: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 9, // 39: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 7, // 40: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 3, // 41: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 1, // 42: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 5, // 43: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 27, // 44: blobber.service.v1.Blobber.UpdateObjectAttributes:output_type -> blobber.service.v1.UpdateObjectAttributesResponse + 34, // [34:45] is the sub-list for method output_type + 23, // [23:34] is the sub-list for method input_type 23, // [23:23] is the sub-list for extension type_name 23, // [23:23] is the sub-list for extension extendee 0, // [0:23] is the sub-list for field type_name @@ -3350,7 +3386,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*UpdateObjectAttributesRequest); i { case 0: return &v.state case 1: @@ -3362,7 +3398,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*UpdateObjectAttributesResponse); i { case 0: return &v.state case 1: @@ -3374,7 +3410,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -3386,7 +3422,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -3398,6 +3434,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -3416,7 +3476,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 31, + NumMessages: 33, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 81a06e61e..070c75e2f 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -331,24 +331,6 @@ func _Blobber_GetObjectTree_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } -func _Blobber_UpdateObjectAttributes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(UpdateObjectAttributesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(BlobberServer).UpdateObjectAttributes(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/blobber.service.v1.Blobber/UpdateObjectAttributes", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(BlobberServer).UpdateObjectAttributes(ctx, req.(*UpdateObjectAttributesRequest)) - } - return interceptor(ctx, in, info, handler) -} - func _Blobber_Commit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(CommitRequest) if err := dec(in); err != nil { @@ -403,6 +385,24 @@ func _Blobber_CommitMetaTxn_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } +func _Blobber_UpdateObjectAttributes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(UpdateObjectAttributesRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).UpdateObjectAttributes(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/UpdateObjectAttributes", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).UpdateObjectAttributes(ctx, req.(*UpdateObjectAttributesRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Blobber_serviceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index 675d4c327..dd9ea3487 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -44,7 +44,6 @@ type PackageHandler interface { GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) - GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx context.Context, sa *allocation.Allocation, co *allocation.AllocationChangeCollector) error ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error GetReference(ctx context.Context, allocationID string, path string) (*reference.Ref, error) @@ -121,12 +120,6 @@ func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clien return reference.IsACollaborator(ctx, refID, clientID) } -func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, - allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { - - return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) -} - func (r packageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { return alloc.Save(ctx) } diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 5c8ab0a0d..52ae8d64b 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -1,4 +1,4 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. +// Code generated by mockery 2.7.5. DO NOT EDIT. package mocks @@ -330,6 +330,20 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } +// SaveAllocationChanges provides a mock function with given fields: ctx, alloc +func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + ret := _m.Called(ctx, alloc) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(ctx, alloc) + } else { + r0 = ret.Error(0) + } + + return r0 +} + // UpdateAllocationAndCommitChanges provides a mock function with given fields: ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot func (_m *PackageHandler) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { ret := _m.Called(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) @@ -357,17 +371,3 @@ func (_m *PackageHandler) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx co return r0 } - -// SaveAllocationChanges provides a mock function with given fields: ctx, alloc -func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { - ret := _m.Called(ctx, alloc) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { - r0 = rf(ctx, alloc) - } else { - r0 = ret.Error(0) - } - - return r0 -} diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index f46fed315..5229d7487 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -46,14 +46,14 @@ ] } }, - "/v2/file/attributes/{allocation}": { + "/v2/connection/commit/{allocation}": { "post": { - "operationId": "Blobber_UpdateObjectAttributes", + "operationId": "Blobber_Commit", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1UpdateObjectAttributesResponse" + "$ref": "#/definitions/v1CommitResponse" } }, "default": { @@ -75,7 +75,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/v1UpdateObjectAttributesRequest" + "$ref": "#/definitions/v1CommitRequest" } } ], @@ -84,14 +84,14 @@ ] } }, - "/v2/connection/commit/{allocation}": { + "/v2/file/attributes/{allocation}": { "post": { - "operationId": "Blobber_Commit", + "operationId": "Blobber_UpdateObjectAttributes", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1CommitResponse" + "$ref": "#/definitions/v1UpdateObjectAttributesResponse" } }, "default": { @@ -113,7 +113,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/v1CommitRequest" + "$ref": "#/definitions/v1UpdateObjectAttributesRequest" } } ], diff --git a/go.sum b/go.sum index ab6111004..dec840020 100644 --- a/go.sum +++ b/go.sum @@ -94,7 +94,6 @@ github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5Kwzbycv github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/gedex/inflector v0.0.0-20170307190818-16278e9db813/go.mod h1:P+oSoE9yhSRvsmYyZsshflcR6ePWYLql6UU1amW13IM= -github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= @@ -335,7 +334,6 @@ github.com/mitchellh/go-testing-interface v1.0.0/go.mod h1:kRemZodwjscx+RGhAo8eI github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS42BGNg= github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.1.2 h1:fmNYVwqnSfB9mZU6OS2O6GsXM+wcskZDuKQzvN1EDeE= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.3.1 h1:cCBH2gTD2K0OtLlv/Y5H01VQCqmlDxz30kS5Y5bqfLA= github.com/mitchellh/mapstructure v1.3.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= @@ -351,7 +349,6 @@ github.com/patrickmn/go-cache v2.1.0+incompatible/go.mod h1:3Qf8kWWT7OJRJbdiICTK github.com/pelletier/go-toml v1.2.0 h1:T5zMGML61Wp+FlcbWjRDT7yAxhJNAiPPLOFECq181zc= github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pkg/errors v0.8.1 h1:iURUrRGxPUNPdy5/HRSm+Yj6okJ6UtLINN0Q9M4+h3I= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -401,7 +398,6 @@ github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkU github.com/spf13/cobra v1.0.1-0.20201006035406-b97b5ead31f7/go.mod h1:yk5b0mALVusDL5fMM6Rd1wgnoO5jUPhwsQ6LQAJTidQ= github.com/spf13/jwalterweatherman v1.0.0 h1:XHEdyB+EcvlqZamSM4ZOMGlc93t6AcsBEu9Gc1vn7yk= github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= -github.com/spf13/pflag v1.0.3 h1:zPAT6CGy6wXeQ7NtTnaTerfKOsV6V6F8agHXFiazDkg= github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= @@ -413,7 +409,6 @@ github.com/stretchr/objx v0.2.0 h1:Hbg2NidpLE8veEBkEZTL3CvlkUIVzuU9jDplZO54c48= github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= -github.com/stretchr/testify v1.4.0 h1:2E4SXV/wtOkTonXsotYi4li6zVWxYlZuYNCXe9XRJyk= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= @@ -447,22 +442,18 @@ go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.6/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= -go.uber.org/atomic v1.6.0 h1:Ezj3JGmsOnG1MoRWQkPBsKLe9DwWD9QeXzTRzzldNVk= go.uber.org/atomic v1.6.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= go.uber.org/atomic v1.7.0 h1:ADUqmZGgLDDfbSL9ZmPxKTybcoEYHgpYfELNoN+7hsw= go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= -go.uber.org/multierr v1.5.0 h1:KCa4XfM8CWFCpxXRGok+Q0SS/0XBhMDbHHGABQLvD2A= go.uber.org/multierr v1.5.0/go.mod h1:FeouvMocqHpRaaGuG9EjoKcStLC43Zu/fmqdUMPcKYU= go.uber.org/multierr v1.6.0 h1:y6IPFStTAIT5Ytl7/XYmHvzXQ7S3g/IeZW9hyZ5thw4= go.uber.org/multierr v1.6.0/go.mod h1:cdWPpRnG4AhwMwsgIHip0KRBQjJy5kYEpYjJxpXp9iU= go.uber.org/ratelimit v0.2.0 h1:UQE2Bgi7p2B85uP5dC2bbRtig0C+OeNRnNEafLjsLPA= go.uber.org/ratelimit v0.2.0/go.mod h1:YYBV4e4naJvhpitQrWJu1vCpgB7CboMe0qhltKt6mUg= -go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee h1:0mgffUl7nfd+FpvXMVz4IDEaUSmT1ysygQC7qYo7sG4= go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee/go.mod h1:vJERXedbb3MVM5f9Ejo0C68/HhF8uaILCdgjnY+goOA= go.uber.org/zap v1.9.1/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= -go.uber.org/zap v1.15.0 h1:ZZCA22JRF2gQE5FoNmhmrf7jeJJ2uhqDUNRYKm8dvmM= go.uber.org/zap v1.15.0/go.mod h1:Mb2vm2krFEG5DV0W9qcHBYFtp/Wku1cvYaqPsS/WYfc= go.uber.org/zap v1.16.0 h1:uFRZXykJGK9lLY4HtgSw44DnIcAM+kRBP7x5m+NpAOM= go.uber.org/zap v1.16.0/go.mod h1:MA8QOfq0BHJwdXa996Y4dYkAqRKB8/1K1QMMZVaNZjQ= @@ -476,7 +467,6 @@ golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190911031432-227b76d455e7/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550 h1:ObdrDkeb4kJdCP557AjRjq69pTHfNouLtWZG7j9rPN8= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200323165209-0ec3e9974c59/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= @@ -501,7 +491,6 @@ golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTk golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/lint v0.0.0-20190409202823-959b441ac422/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/lint v0.0.0-20190909230951-414d861bb4ac/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/lint v0.0.0-20190930215403-16217165b5de h1:5hukYrvBGR8/eNkX5mdUezrA6JiaEZDtJb9Ei+1LlBs= golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/lint v0.0.0-20191125180803-fdd1cda4f05f/go.mod h1:5qLYkcX4OjUUV8bRuDixDT3tpyyb+LUpUlRWLxfhWrs= golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= @@ -514,7 +503,6 @@ golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKG golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY= golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= golang.org/x/mod v0.1.1-0.20191107180719-034126e5016b/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= -golang.org/x/mod v0.1.1-0.20191209134235-331c550502dd h1:ePuNC7PZ6O5BzgPn9bZayERXBdfZjUYoXEf5BTfDfh8= golang.org/x/mod v0.1.1-0.20191209134235-331c550502dd/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0 h1:RM4zey1++hCTbCVQfnWeKs9/IEsaBLA8vTkd0WVtmH4= @@ -615,7 +603,6 @@ golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9sn golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/text v0.3.2 h1:tW2bmiBqwgJj/UpqtC8EpXEZVYOwU0yG4iWbprSVAcs= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.5 h1:i6eZZ+zk0SOf0xgBpEpPD18qWcJda6q1sxt3S0kzyUQ= @@ -658,7 +645,6 @@ golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapK golang.org/x/tools v0.0.0-20200122220014-bf1340f18c4a/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200204074204-1cc6d1ef6c74/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200207183749-b753a1ba74fa h1:5E4dL8+NgFOgjwbTKz+OOEGGhP+ectTmF842l6KjupQ= golang.org/x/tools v0.0.0-20200207183749-b753a1ba74fa/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200212150539-ea181f53ac56/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200224181240-023911ca70b2/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= @@ -682,7 +668,6 @@ golang.org/x/xerrors v0.0.0-20190410155217-1f06c39b4373/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20190513163551-3ee3066db522/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -757,7 +742,6 @@ google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv google.golang.org/grpc v1.35.0-dev.0.20201218190559-666aea1fb34c/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.0 h1:o1bcQ6imQMIOpdrO3SWf2z5RV72WbDwdXuK0MDlc8As= google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= -google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.0.0 h1:lQ+dE99pFsb8osbJB3oRfE5eW4Hx6a/lZQr8Jh+eoT4= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.0.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= @@ -780,7 +764,6 @@ gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 h1:qIbj1fsPNlZgppZ+VLlY7N33 gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/inconshreveable/log15.v2 v2.0.0-20180818164646-67afb5ed74ec/go.mod h1:aPpfJ7XW+gOuirDoZ8gHhLh3kZ1B08FtV2bbmy7Jv3s= -gopkg.in/ini.v1 v1.51.0 h1:AQvPpx3LzTDM0AjnIRlVFwFFGC+npRopjZxLJj6gdno= gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/ini.v1 v1.61.0 h1:LBCdW4FmFYL4s/vDZD1RQYX7oAR6IjujCYgMdbHBR10= gopkg.in/ini.v1 v1.61.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= @@ -792,7 +775,6 @@ gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.4 h1:/eiJrUcujPVeJ3xlSWaiNi3uSVmDGBK1pDHUHAnao1I= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -820,7 +802,6 @@ honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWh honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.1-2019.2.3 h1:3JgtbtFHMiCmsznwGVTUWbgGov+pVqnlf1dEJTNAXeM= honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4 h1:UoveltGrhghAA7ePc+e+QYDHXrBps2PqFZiHkGR/xK8= From cc965f9d5997087a8ac3ffd08ff3d6a6cff5f1d0 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sat, 5 Jun 2021 21:25:10 +0530 Subject: [PATCH 104/183] 153 conflicts resolved with grpc --- .../blobbercore/blobbergrpc/blobber.pb.go | 382 ++++++++++-------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 80 ++++ .../blobbergrpc/blobber_grpc.pb.go | 36 +- .../0chain.net/blobbercore/handler/helper.go | 12 - .../blobbercore/mocks/PackageHandler.go | 76 ++-- 5 files changed, 348 insertions(+), 238 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index e347288dd..b0591fa2f 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1706,7 +1706,7 @@ type CopyObjectRequest struct { func (x *CopyObjectRequest) Reset() { *x = CopyObjectRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1719,7 +1719,7 @@ func (x *CopyObjectRequest) String() string { func (*CopyObjectRequest) ProtoMessage() {} func (x *CopyObjectRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1732,7 +1732,7 @@ func (x *CopyObjectRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CopyObjectRequest.ProtoReflect.Descriptor instead. func (*CopyObjectRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *CopyObjectRequest) GetAllocation() string { @@ -1788,7 +1788,7 @@ type CopyObjectResponse struct { func (x *CopyObjectResponse) Reset() { *x = CopyObjectResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1801,7 +1801,7 @@ func (x *CopyObjectResponse) String() string { func (*CopyObjectResponse) ProtoMessage() {} func (x *CopyObjectResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1814,7 +1814,7 @@ func (x *CopyObjectResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CopyObjectResponse.ProtoReflect.Descriptor instead. func (*CopyObjectResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{27} } func (x *CopyObjectResponse) GetFilename() string { @@ -1886,7 +1886,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1899,7 +1899,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1912,7 +1912,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{28} } func (x *Allocation) GetID() string { @@ -2049,7 +2049,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2062,7 +2062,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2075,7 +2075,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{27} + return file_blobber_proto_rawDescGZIP(), []int{29} } func (x *Term) GetID() int64 { @@ -2126,7 +2126,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2139,7 +2139,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2152,7 +2152,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{28} + return file_blobber_proto_rawDescGZIP(), []int{30} } func (x *FileRef) GetType() string { @@ -2210,7 +2210,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2223,7 +2223,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2236,7 +2236,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{29} + return file_blobber_proto_rawDescGZIP(), []int{31} } func (x *FileMetaData) GetType() string { @@ -2427,7 +2427,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2440,7 +2440,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2453,7 +2453,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{30} + return file_blobber_proto_rawDescGZIP(), []int{32} } func (x *DirMetaData) GetType() string { @@ -2877,125 +2877,139 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, - 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0x96, 0x0b, 0x0a, - 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, - 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, - 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, - 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, - 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, + 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, + 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, + 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, + 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, + 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, + 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, + 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, + 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, + 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, + 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, + 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x32, 0x9b, 0x0c, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, + 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, - 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, - 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, - 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, + 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, + 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, + 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, + 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, + 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, + 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, + 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, + 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, + 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, + 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, + 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, + 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, - 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, - 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, - 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, - 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, - 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, - 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, + 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, + 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, + 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, + 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, + 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, + 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, + 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, + 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, + 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, + 0x22, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, + 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, + 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, + 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -3010,7 +3024,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 31) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 33) var file_blobber_proto_goTypes = []interface{}{ (*CalculateHashRequest)(nil), // 0: blobber.service.v1.CalculateHashRequest (*CalculateHashResponse)(nil), // 1: blobber.service.v1.CalculateHashResponse @@ -3038,11 +3052,13 @@ var file_blobber_proto_goTypes = []interface{}{ (*Collaborator)(nil), // 23: blobber.service.v1.Collaborator (*GetAllocationRequest)(nil), // 24: blobber.service.v1.GetAllocationRequest (*GetAllocationResponse)(nil), // 25: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 26: blobber.service.v1.Allocation - (*Term)(nil), // 27: blobber.service.v1.Term - (*FileRef)(nil), // 28: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 29: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 30: blobber.service.v1.DirMetaData + (*CopyObjectRequest)(nil), // 26: blobber.service.v1.CopyObjectRequest + (*CopyObjectResponse)(nil), // 27: blobber.service.v1.CopyObjectResponse + (*Allocation)(nil), // 28: blobber.service.v1.Allocation + (*Term)(nil), // 29: blobber.service.v1.Term + (*FileRef)(nil), // 30: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 31: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 32: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 14, // 0: blobber.service.v1.CommitResponse.write_marker:type_name -> blobber.service.v1.WriteMarker @@ -3050,23 +3066,23 @@ var file_blobber_proto_depIdxs = []int32{ 14, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 10, // 3: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 14, // 4: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 28, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 10, // 6: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 13, // 7: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 14, // 8: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 28, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 28, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 28, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 28, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 28, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 28, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 30, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 30, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 30, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 30, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 19, // 15: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 28, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 23, // 17: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 26, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 27, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 29, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 30, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 28, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 29, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 31, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 32, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 22, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 24, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 20, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -3078,18 +3094,20 @@ var file_blobber_proto_depIdxs = []int32{ 2, // 30: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest 0, // 31: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest 4, // 32: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest - 25, // 33: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 21, // 34: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 18, // 35: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 16, // 36: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 12, // 37: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 9, // 38: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 7, // 39: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 3, // 40: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 1, // 41: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 5, // 42: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 33, // [33:43] is the sub-list for method output_type - 23, // [23:33] is the sub-list for method input_type + 26, // 33: blobber.service.v1.Blobber.CopyObject:input_type -> blobber.service.v1.CopyObjectRequest + 25, // 34: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 21, // 35: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 18, // 36: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 16, // 37: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 12, // 38: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 9, // 39: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 7, // 40: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 3, // 41: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 1, // 42: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 5, // 43: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 27, // 44: blobber.service.v1.Blobber.CopyObject:output_type -> blobber.service.v1.CopyObjectResponse + 34, // [34:45] is the sub-list for method output_type + 23, // [23:34] is the sub-list for method input_type 23, // [23:23] is the sub-list for extension type_name 23, // [23:23] is the sub-list for extension extendee 0, // [0:23] is the sub-list for field type_name @@ -3414,7 +3432,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*CopyObjectRequest); i { case 0: return &v.state case 1: @@ -3426,7 +3444,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*CopyObjectResponse); i { case 0: return &v.state case 1: @@ -3438,7 +3456,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -3450,7 +3468,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -3462,6 +3480,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -3480,7 +3522,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 31, + NumMessages: 33, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 447dc93a5..9a9b60c30 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -1199,6 +1199,86 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) + mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/Commit") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_Commit_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_Commit_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_CalculateHash_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_Blobber_CommitMetaTxn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CommitMetaTxn") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_CommitMetaTxn_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_CommitMetaTxn_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_Blobber_CopyObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CopyObject") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_CopyObject_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_CopyObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index fe4e60e1a..24f8a55e7 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -331,24 +331,6 @@ func _Blobber_GetObjectTree_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } -func _Blobber_CopyObject_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(CopyObjectRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(BlobberServer).CopyObject(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/blobber.service.v1.Blobber/CopyObject", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(BlobberServer).CopyObject(ctx, req.(*CopyObjectRequest)) - } - return interceptor(ctx, in, info, handler) -} - func _Blobber_Commit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(CommitRequest) if err := dec(in); err != nil { @@ -403,6 +385,24 @@ func _Blobber_CommitMetaTxn_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } +func _Blobber_CopyObject_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CopyObjectRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).CopyObject(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/CopyObject", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).CopyObject(ctx, req.(*CopyObjectRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Blobber_serviceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index c6b4efee2..6f22b3dad 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -45,10 +45,8 @@ type PackageHandler interface { GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) - GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx context.Context, sa *allocation.Allocation, co *allocation.AllocationChangeCollector) error ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error - GetReference(ctx context.Context, allocationID string, path string) (*reference.Ref, error) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error } @@ -98,11 +96,6 @@ func (r *packageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_ro return writemarker.GetWriteMarkerEntity(ctx, allocation_root) } -func (r *packageHandler) GetReference(ctx context.Context, allocationID string, newPath string) ( - *reference.Ref, error) { - return reference.GetReference(ctx, allocationID, newPath) -} - func (r *packageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { return reference.GetReferenceLookup(allocationID, path) } @@ -127,11 +120,6 @@ func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clien return reference.IsACollaborator(ctx, refID, clientID) } -func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { - - return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) -} - func (r packageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { return alloc.Save(ctx) } diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index da4421923..124bea439 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -1,4 +1,4 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. +// Code generated by mockery 2.7.5. DO NOT EDIT. package mocks @@ -21,29 +21,6 @@ type PackageHandler struct { mock.Mock } -// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID -func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { - ret := _m.Called(ctx, connectionID, allocationID, clientID) - - var r0 *allocation.AllocationChangeCollector - if rf, ok := ret.Get(0).(func(context.Context, string, string, string) *allocation.AllocationChangeCollector); ok { - r0 = rf(ctx, connectionID, allocationID, clientID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*allocation.AllocationChangeCollector) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { - r1 = rf(ctx, connectionID, allocationID, clientID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - // AddCommitMetaTxn provides a mock function with given fields: ctx, refID, txnID func (_m *PackageHandler) AddCommitMetaTxn(ctx context.Context, refID int64, txnID string) error { ret := _m.Called(ctx, refID, txnID) @@ -72,6 +49,29 @@ func (_m *PackageHandler) ApplyChanges(connectionObj *allocation.AllocationChang return r0 } +// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID +func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { + ret := _m.Called(ctx, connectionID, allocationID, clientID) + + var r0 *allocation.AllocationChangeCollector + if rf, ok := ret.Get(0).(func(context.Context, string, string, string) *allocation.AllocationChangeCollector); ok { + r0 = rf(ctx, connectionID, allocationID, clientID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*allocation.AllocationChangeCollector) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { + r1 = rf(ctx, connectionID, allocationID, clientID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // GetCollaborators provides a mock function with given fields: ctx, refID func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { ret := _m.Called(ctx, refID) @@ -330,6 +330,20 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } +// SaveAllocationChanges provides a mock function with given fields: ctx, alloc +func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + ret := _m.Called(ctx, alloc) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(ctx, alloc) + } else { + r0 = ret.Error(0) + } + + return r0 +} + // UpdateAllocationAndCommitChanges provides a mock function with given fields: ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot func (_m *PackageHandler) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { ret := _m.Called(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) @@ -357,17 +371,3 @@ func (_m *PackageHandler) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx co return r0 } - -// SaveAllocationChanges provides a mock function with given fields: ctx, alloc -func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { - ret := _m.Called(ctx, alloc) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { - r0 = rf(ctx, alloc) - } else { - r0 = ret.Error(0) - } - - return r0 -} From 7603fb49e37029e7c4b9c606b99917c5cfac8ec4 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sat, 5 Jun 2021 21:41:24 +0530 Subject: [PATCH 105/183] 156 conflicts resolved with grpc --- .../blobbercore/blobbergrpc/blobber.pb.go | 200 ++++----- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 120 +++--- .../blobbergrpc/blobber_grpc.pb.go | 36 +- .../0chain.net/blobbercore/handler/helper.go | 7 - .../blobbercore/mocks/PackageHandler.go | 396 ------------------ 5 files changed, 184 insertions(+), 575 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/mocks/PackageHandler.go diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index e8591b1a8..85fda4e42 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1706,7 +1706,7 @@ type RenameObjectRequest struct { func (x *RenameObjectRequest) Reset() { *x = RenameObjectRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1719,7 +1719,7 @@ func (x *RenameObjectRequest) String() string { func (*RenameObjectRequest) ProtoMessage() {} func (x *RenameObjectRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1732,7 +1732,7 @@ func (x *RenameObjectRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use RenameObjectRequest.ProtoReflect.Descriptor instead. func (*RenameObjectRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *RenameObjectRequest) GetAllocation() string { @@ -1788,7 +1788,7 @@ type RenameObjectResponse struct { func (x *RenameObjectResponse) Reset() { *x = RenameObjectResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1801,7 +1801,7 @@ func (x *RenameObjectResponse) String() string { func (*RenameObjectResponse) ProtoMessage() {} func (x *RenameObjectResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1814,7 +1814,7 @@ func (x *RenameObjectResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use RenameObjectResponse.ProtoReflect.Descriptor instead. func (*RenameObjectResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{27} } func (x *RenameObjectResponse) GetFilename() string { @@ -1886,7 +1886,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1899,7 +1899,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1912,7 +1912,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{28} } func (x *Allocation) GetID() string { @@ -2049,7 +2049,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2062,7 +2062,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2075,7 +2075,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{27} + return file_blobber_proto_rawDescGZIP(), []int{29} } func (x *Term) GetID() int64 { @@ -2126,7 +2126,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2139,7 +2139,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2152,7 +2152,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{28} + return file_blobber_proto_rawDescGZIP(), []int{30} } func (x *FileRef) GetType() string { @@ -2210,7 +2210,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2223,7 +2223,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2236,7 +2236,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{29} + return file_blobber_proto_rawDescGZIP(), []int{31} } func (x *FileMetaData) GetType() string { @@ -2427,7 +2427,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2440,7 +2440,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2453,7 +2453,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{30} + return file_blobber_proto_rawDescGZIP(), []int{32} } func (x *DirMetaData) GetType() string { @@ -2908,7 +2908,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0x96, 0x0b, 0x0a, + 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xa3, 0x0c, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, @@ -2971,37 +2971,46 @@ var file_blobber_proto_rawDesc = []byte{ 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, - 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, - 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, - 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, - 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, - 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, - 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, - 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, - 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, - 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8a, 0x01, 0x0a, 0x0c, 0x52, 0x65, 0x6e, 0x61, + 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, + 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, + 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, + 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, + 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, + 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, + 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, + 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, + 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, + 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, + 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -3016,7 +3025,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 31) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 33) var file_blobber_proto_goTypes = []interface{}{ (*CalculateHashRequest)(nil), // 0: blobber.service.v1.CalculateHashRequest (*CalculateHashResponse)(nil), // 1: blobber.service.v1.CalculateHashResponse @@ -3044,11 +3053,13 @@ var file_blobber_proto_goTypes = []interface{}{ (*Collaborator)(nil), // 23: blobber.service.v1.Collaborator (*GetAllocationRequest)(nil), // 24: blobber.service.v1.GetAllocationRequest (*GetAllocationResponse)(nil), // 25: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 26: blobber.service.v1.Allocation - (*Term)(nil), // 27: blobber.service.v1.Term - (*FileRef)(nil), // 28: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 29: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 30: blobber.service.v1.DirMetaData + (*RenameObjectRequest)(nil), // 26: blobber.service.v1.RenameObjectRequest + (*RenameObjectResponse)(nil), // 27: blobber.service.v1.RenameObjectResponse + (*Allocation)(nil), // 28: blobber.service.v1.Allocation + (*Term)(nil), // 29: blobber.service.v1.Term + (*FileRef)(nil), // 30: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 31: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 32: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 14, // 0: blobber.service.v1.CommitResponse.write_marker:type_name -> blobber.service.v1.WriteMarker @@ -3056,23 +3067,23 @@ var file_blobber_proto_depIdxs = []int32{ 14, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 10, // 3: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 14, // 4: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 28, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 10, // 6: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 13, // 7: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 14, // 8: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 28, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 28, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 28, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 28, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 28, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 28, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 30, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 30, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 30, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 30, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 19, // 15: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 28, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 23, // 17: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 26, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 27, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 29, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 30, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 28, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 29, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 31, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 32, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 22, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 24, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 20, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -3081,21 +3092,23 @@ var file_blobber_proto_depIdxs = []int32{ 11, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest 8, // 28: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest 6, // 29: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 2, // 30: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest - 0, // 31: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest - 4, // 32: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest - 25, // 33: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 21, // 34: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 18, // 35: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 16, // 36: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 12, // 37: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 9, // 38: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 7, // 39: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 3, // 40: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 1, // 41: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 5, // 42: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 33, // [33:43] is the sub-list for method output_type - 23, // [23:33] is the sub-list for method input_type + 26, // 30: blobber.service.v1.Blobber.RenameObject:input_type -> blobber.service.v1.RenameObjectRequest + 2, // 31: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest + 0, // 32: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest + 4, // 33: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest + 25, // 34: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 21, // 35: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 18, // 36: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 16, // 37: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 12, // 38: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 9, // 39: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 7, // 40: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 27, // 41: blobber.service.v1.Blobber.RenameObject:output_type -> blobber.service.v1.RenameObjectResponse + 3, // 42: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 1, // 43: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 5, // 44: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 34, // [34:45] is the sub-list for method output_type + 23, // [23:34] is the sub-list for method input_type 23, // [23:23] is the sub-list for extension type_name 23, // [23:23] is the sub-list for extension extendee 0, // [0:23] is the sub-list for field type_name @@ -3420,7 +3433,6 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { - file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RenameObjectRequest); i { case 0: return &v.state @@ -3432,7 +3444,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RenameObjectResponse); i { case 0: return &v.state @@ -3444,7 +3456,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Allocation); i { case 0: return &v.state @@ -3456,7 +3468,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Term); i { case 0: return &v.state @@ -3468,7 +3480,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileRef); i { case 0: return &v.state @@ -3480,7 +3492,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileMetaData); i { case 0: return &v.state @@ -3492,7 +3504,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -3511,7 +3523,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 31, + NumMessages: 33, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index b7454b149..b635a2b12 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -487,8 +487,8 @@ func local_request_Blobber_GetObjectTree_0(ctx context.Context, marshaler runtim } -func request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CommitRequest +func request_Blobber_RenameObject_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RenameObjectRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -516,13 +516,13 @@ func request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.Commit(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.RenameObject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CommitRequest +func local_request_Blobber_RenameObject_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RenameObjectRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -550,13 +550,13 @@ func local_request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marsh return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.Commit(ctx, &protoReq) + msg, err := server.RenameObject(ctx, &protoReq) return msg, metadata, err } -func request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CalculateHashRequest +func request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -584,13 +584,13 @@ func request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Mars return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.CalculateHash(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.Commit(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CalculateHashRequest +func local_request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -618,13 +618,13 @@ func local_request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtim return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.CalculateHash(ctx, &protoReq) + msg, err := server.Commit(ctx, &protoReq) return msg, metadata, err } -func request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CommitMetaTxnRequest +func request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CalculateHashRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -652,13 +652,13 @@ func request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Mars return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.CommitMetaTxn(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.CalculateHash(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CommitMetaTxnRequest +func local_request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CalculateHashRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -686,13 +686,13 @@ func local_request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtim return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.CommitMetaTxn(ctx, &protoReq) + msg, err := server.CalculateHash(ctx, &protoReq) return msg, metadata, err } -func request_Blobber_RenameObject_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq RenameObjectRequest +func request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitMetaTxnRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -720,13 +720,13 @@ func request_Blobber_RenameObject_0(ctx context.Context, marshaler runtime.Marsh return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.RenameObject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.CommitMetaTxn(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_RenameObject_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq RenameObjectRequest +func local_request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitMetaTxnRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -754,7 +754,7 @@ func local_request_Blobber_RenameObject_0(ctx context.Context, marshaler runtime return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.RenameObject(ctx, &protoReq) + msg, err := server.CommitMetaTxn(ctx, &protoReq) return msg, metadata, err } @@ -926,18 +926,18 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) - mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_RenameObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/Commit") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/RenameObject") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_Commit_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_RenameObject_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -945,22 +945,22 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_Commit_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_RenameObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/Commit") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_CalculateHash_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_Commit_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -968,22 +968,22 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_Commit_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_CommitMetaTxn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CommitMetaTxn") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_CommitMetaTxn_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_CalculateHash_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -991,22 +991,22 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_CommitMetaTxn_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_RenameObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_CommitMetaTxn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/RenameObject") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CommitMetaTxn") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_RenameObject_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_CommitMetaTxn_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -1014,7 +1014,7 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_RenameObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_CommitMetaTxn_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) @@ -1199,83 +1199,83 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) - mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_RenameObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/Commit") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/RenameObject") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_Commit_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_RenameObject_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_Commit_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_RenameObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/Commit") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_CalculateHash_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_Commit_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_Commit_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_CommitMetaTxn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CommitMetaTxn") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_CommitMetaTxn_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_CalculateHash_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_CommitMetaTxn_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_RenameObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_CommitMetaTxn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/RenameObject") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CommitMetaTxn") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_RenameObject_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_CommitMetaTxn_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_RenameObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_CommitMetaTxn_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) @@ -1297,13 +1297,13 @@ var ( pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) + pattern_Blobber_RenameObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "rename", "allocation"}, "")) + pattern_Blobber_Commit_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "connection", "commit", "allocation"}, "")) pattern_Blobber_CalculateHash_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "calculatehash", "allocation"}, "")) pattern_Blobber_CommitMetaTxn_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "commitmetatxn", "allocation"}, "")) - - pattern_Blobber_RenameObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "rename", "allocation"}, "")) ) var ( @@ -1321,11 +1321,11 @@ var ( forward_Blobber_GetObjectTree_0 = runtime.ForwardResponseMessage + forward_Blobber_RenameObject_0 = runtime.ForwardResponseMessage + forward_Blobber_Commit_0 = runtime.ForwardResponseMessage forward_Blobber_CalculateHash_0 = runtime.ForwardResponseMessage forward_Blobber_CommitMetaTxn_0 = runtime.ForwardResponseMessage - - forward_Blobber_RenameObject_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index aa2d40ece..1c0e4dcb7 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -24,10 +24,10 @@ type BlobberClient interface { GetObjectPath(ctx context.Context, in *GetObjectPathRequest, opts ...grpc.CallOption) (*GetObjectPathResponse, error) GetReferencePath(ctx context.Context, in *GetReferencePathRequest, opts ...grpc.CallOption) (*GetReferencePathResponse, error) GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) + RenameObject(ctx context.Context, in *RenameObjectRequest, opts ...grpc.CallOption) (*RenameObjectResponse, error) Commit(ctx context.Context, in *CommitRequest, opts ...grpc.CallOption) (*CommitResponse, error) CalculateHash(ctx context.Context, in *CalculateHashRequest, opts ...grpc.CallOption) (*CalculateHashResponse, error) CommitMetaTxn(ctx context.Context, in *CommitMetaTxnRequest, opts ...grpc.CallOption) (*CommitMetaTxnResponse, error) - RenameObject(ctx context.Context, in *RenameObjectRequest, opts ...grpc.CallOption) (*RenameObjectResponse, error) } type blobberClient struct { @@ -101,6 +101,15 @@ func (c *blobberClient) GetObjectTree(ctx context.Context, in *GetObjectTreeRequ return out, nil } +func (c *blobberClient) RenameObject(ctx context.Context, in *RenameObjectRequest, opts ...grpc.CallOption) (*RenameObjectResponse, error) { + out := new(RenameObjectResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/RenameObject", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *blobberClient) Commit(ctx context.Context, in *CommitRequest, opts ...grpc.CallOption) (*CommitResponse, error) { out := new(CommitResponse) err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/Commit", in, out, opts...) @@ -128,15 +137,6 @@ func (c *blobberClient) CommitMetaTxn(ctx context.Context, in *CommitMetaTxnRequ return out, nil } -func (c *blobberClient) RenameObject(ctx context.Context, in *RenameObjectRequest, opts ...grpc.CallOption) (*RenameObjectResponse, error) { - out := new(RenameObjectResponse) - err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/RenameObject", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -148,10 +148,10 @@ type BlobberServer interface { GetObjectPath(context.Context, *GetObjectPathRequest) (*GetObjectPathResponse, error) GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) + RenameObject(context.Context, *RenameObjectRequest) (*RenameObjectResponse, error) Commit(context.Context, *CommitRequest) (*CommitResponse, error) CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) - RenameObject(context.Context, *RenameObjectRequest) (*RenameObjectResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -180,6 +180,9 @@ func (UnimplementedBlobberServer) GetReferencePath(context.Context, *GetReferenc func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetObjectTree not implemented") } +func (UnimplementedBlobberServer) RenameObject(context.Context, *RenameObjectRequest) (*RenameObjectResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RenameObject not implemented") +} func (UnimplementedBlobberServer) Commit(context.Context, *CommitRequest) (*CommitResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Commit not implemented") } @@ -189,9 +192,6 @@ func (UnimplementedBlobberServer) CalculateHash(context.Context, *CalculateHashR func (UnimplementedBlobberServer) CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CommitMetaTxn not implemented") } -func (UnimplementedBlobberServer) RenameObject(context.Context, *RenameObjectRequest) (*RenameObjectResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method RenameObject not implemented") -} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -435,6 +435,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "GetObjectTree", Handler: _Blobber_GetObjectTree_Handler, }, + { + MethodName: "RenameObject", + Handler: _Blobber_RenameObject_Handler, + }, { MethodName: "Commit", Handler: _Blobber_Commit_Handler, @@ -447,10 +451,6 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "CommitMetaTxn", Handler: _Blobber_CommitMetaTxn_Handler, }, - { - MethodName: "RenameObject", - Handler: _Blobber_RenameObject_Handler, - }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index 675d4c327..dd9ea3487 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -44,7 +44,6 @@ type PackageHandler interface { GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) - GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx context.Context, sa *allocation.Allocation, co *allocation.AllocationChangeCollector) error ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error GetReference(ctx context.Context, allocationID string, path string) (*reference.Ref, error) @@ -121,12 +120,6 @@ func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clien return reference.IsACollaborator(ctx, refID, clientID) } -func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, - allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { - - return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) -} - func (r packageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { return alloc.Save(ctx) } diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go deleted file mode 100644 index 3dc22c7ac..000000000 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ /dev/null @@ -1,396 +0,0 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. - -package mocks - -import ( - context "context" - - allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - - mock "github.com/stretchr/testify/mock" - - reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - - stats "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" - - writemarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" -) - -// PackageHandler is an autogenerated mock type for the PackageHandler type -type PackageHandler struct { - mock.Mock -} - -// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID -func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { - ret := _m.Called(ctx, connectionID, allocationID, clientID) - - var r0 *allocation.AllocationChangeCollector - if rf, ok := ret.Get(0).(func(context.Context, string, string, string) *allocation.AllocationChangeCollector); ok { - r0 = rf(ctx, connectionID, allocationID, clientID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*allocation.AllocationChangeCollector) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { - r1 = rf(ctx, connectionID, allocationID, clientID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// AddCommitMetaTxn provides a mock function with given fields: ctx, refID, txnID -func (_m *PackageHandler) AddCommitMetaTxn(ctx context.Context, refID int64, txnID string) error { - ret := _m.Called(ctx, refID, txnID) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { - r0 = rf(ctx, refID, txnID) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// ApplyChanges provides a mock function with given fields: connectionObj, ctx, allocationRoot -func (_m *PackageHandler) ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error { - ret := _m.Called(connectionObj, ctx, allocationRoot) - - var r0 error - if rf, ok := ret.Get(0).(func(*allocation.AllocationChangeCollector, context.Context, string) error); ok { - r0 = rf(connectionObj, ctx, allocationRoot) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID -func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { - ret := _m.Called(ctx, connectionID, allocationID, clientID) - - var r0 *allocation.AllocationChangeCollector - if rf, ok := ret.Get(0).(func(context.Context, string, string, string) *allocation.AllocationChangeCollector); ok { - r0 = rf(ctx, connectionID, allocationID, clientID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*allocation.AllocationChangeCollector) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { - r1 = rf(ctx, connectionID, allocationID, clientID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetCollaborators provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { - ret := _m.Called(ctx, refID) - - var r0 []reference.Collaborator - if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.Collaborator); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]reference.Collaborator) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetCommitMetaTxns provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) { - ret := _m.Called(ctx, refID) - - var r0 []reference.CommitMetaTxn - if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.CommitMetaTxn); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]reference.CommitMetaTxn) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetFileStats provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) { - ret := _m.Called(ctx, refID) - - var r0 *stats.FileStats - if rf, ok := ret.Get(0).(func(context.Context, int64) *stats.FileStats); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*stats.FileStats) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetObjectPath provides a mock function with given fields: ctx, allocationID, blockNum -func (_m *PackageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { - ret := _m.Called(ctx, allocationID, blockNum) - - var r0 *reference.ObjectPath - if rf, ok := ret.Get(0).(func(context.Context, string, int64) *reference.ObjectPath); ok { - r0 = rf(ctx, allocationID, blockNum) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.ObjectPath) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, int64) error); ok { - r1 = rf(ctx, allocationID, blockNum) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetObjectTree provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetRefWithChildren provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetReference provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetReference(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetReferenceFromLookupHash provides a mock function with given fields: ctx, allocationID, path_hash -func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path_hash) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path_hash) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path_hash) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetReferenceLookup provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { - ret := _m.Called(ctx, allocationID, path) - - var r0 string - if rf, ok := ret.Get(0).(func(context.Context, string, string) string); ok { - r0 = rf(ctx, allocationID, path) - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetReferencePathFromPaths provides a mock function with given fields: ctx, allocationID, paths -func (_m *PackageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, paths) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, []string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, paths) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, []string) error); ok { - r1 = rf(ctx, allocationID, paths) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetWriteMarkerEntity provides a mock function with given fields: ctx, allocation_root -func (_m *PackageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_root string) (*writemarker.WriteMarkerEntity, error) { - ret := _m.Called(ctx, allocation_root) - - var r0 *writemarker.WriteMarkerEntity - if rf, ok := ret.Get(0).(func(context.Context, string) *writemarker.WriteMarkerEntity); ok { - r0 = rf(ctx, allocation_root) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*writemarker.WriteMarkerEntity) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string) error); ok { - r1 = rf(ctx, allocation_root) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// IsACollaborator provides a mock function with given fields: ctx, refID, clientID -func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { - ret := _m.Called(ctx, refID, clientID) - - var r0 bool - if rf, ok := ret.Get(0).(func(context.Context, int64, string) bool); ok { - r0 = rf(ctx, refID, clientID) - } else { - r0 = ret.Get(0).(bool) - } - - return r0 -} - -// UpdateAllocationAndCommitChanges provides a mock function with given fields: ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot -func (_m *PackageHandler) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { - ret := _m.Called(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *writemarker.WriteMarkerEntity, *allocation.AllocationChangeCollector, *allocation.Allocation, string) error); ok { - r0 = rf(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// VerifyMarker provides a mock function with given fields: wm, ctx, sa, co -func (_m *PackageHandler) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx context.Context, sa *allocation.Allocation, co *allocation.AllocationChangeCollector) error { - ret := _m.Called(wm, ctx, sa, co) - - var r0 error - if rf, ok := ret.Get(0).(func(*writemarker.WriteMarkerEntity, context.Context, *allocation.Allocation, *allocation.AllocationChangeCollector) error); ok { - r0 = rf(wm, ctx, sa, co) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// SaveAllocationChanges provides a mock function with given fields: ctx, alloc -func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { - ret := _m.Called(ctx, alloc) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { - r0 = rf(ctx, alloc) - } else { - r0 = ret.Error(0) - } - - return r0 -} From f43c1f7d052334d387bda7fc407ac8251bd9c664 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sat, 5 Jun 2021 21:41:48 +0530 Subject: [PATCH 106/183] 156 conflicts resolved with grpc --- .../blobbercore/mocks/PackageHandler.go | 373 ++++++++++++++++++ 1 file changed, 373 insertions(+) create mode 100644 code/go/0chain.net/blobbercore/mocks/PackageHandler.go diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go new file mode 100644 index 000000000..52ae8d64b --- /dev/null +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -0,0 +1,373 @@ +// Code generated by mockery 2.7.5. DO NOT EDIT. + +package mocks + +import ( + context "context" + + allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + + mock "github.com/stretchr/testify/mock" + + reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + + stats "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + + writemarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" +) + +// PackageHandler is an autogenerated mock type for the PackageHandler type +type PackageHandler struct { + mock.Mock +} + +// AddCommitMetaTxn provides a mock function with given fields: ctx, refID, txnID +func (_m *PackageHandler) AddCommitMetaTxn(ctx context.Context, refID int64, txnID string) error { + ret := _m.Called(ctx, refID, txnID) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { + r0 = rf(ctx, refID, txnID) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// ApplyChanges provides a mock function with given fields: connectionObj, ctx, allocationRoot +func (_m *PackageHandler) ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error { + ret := _m.Called(connectionObj, ctx, allocationRoot) + + var r0 error + if rf, ok := ret.Get(0).(func(*allocation.AllocationChangeCollector, context.Context, string) error); ok { + r0 = rf(connectionObj, ctx, allocationRoot) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID +func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { + ret := _m.Called(ctx, connectionID, allocationID, clientID) + + var r0 *allocation.AllocationChangeCollector + if rf, ok := ret.Get(0).(func(context.Context, string, string, string) *allocation.AllocationChangeCollector); ok { + r0 = rf(ctx, connectionID, allocationID, clientID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*allocation.AllocationChangeCollector) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { + r1 = rf(ctx, connectionID, allocationID, clientID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetCollaborators provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { + ret := _m.Called(ctx, refID) + + var r0 []reference.Collaborator + if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.Collaborator); ok { + r0 = rf(ctx, refID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]reference.Collaborator) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { + r1 = rf(ctx, refID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetCommitMetaTxns provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) { + ret := _m.Called(ctx, refID) + + var r0 []reference.CommitMetaTxn + if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.CommitMetaTxn); ok { + r0 = rf(ctx, refID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]reference.CommitMetaTxn) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { + r1 = rf(ctx, refID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetFileStats provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) { + ret := _m.Called(ctx, refID) + + var r0 *stats.FileStats + if rf, ok := ret.Get(0).(func(context.Context, int64) *stats.FileStats); ok { + r0 = rf(ctx, refID) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*stats.FileStats) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { + r1 = rf(ctx, refID) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetObjectPath provides a mock function with given fields: ctx, allocationID, blockNum +func (_m *PackageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { + ret := _m.Called(ctx, allocationID, blockNum) + + var r0 *reference.ObjectPath + if rf, ok := ret.Get(0).(func(context.Context, string, int64) *reference.ObjectPath); ok { + r0 = rf(ctx, allocationID, blockNum) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.ObjectPath) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, int64) error); ok { + r1 = rf(ctx, allocationID, blockNum) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetObjectTree provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, path) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, path) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, path) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetRefWithChildren provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, path) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, path) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, path) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetReference provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetReference(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, path) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, path) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, path) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetReferenceFromLookupHash provides a mock function with given fields: ctx, allocationID, path_hash +func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, path_hash) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, path_hash) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { + r1 = rf(ctx, allocationID, path_hash) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetReferenceLookup provides a mock function with given fields: ctx, allocationID, path +func (_m *PackageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { + ret := _m.Called(ctx, allocationID, path) + + var r0 string + if rf, ok := ret.Get(0).(func(context.Context, string, string) string); ok { + r0 = rf(ctx, allocationID, path) + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + +// GetReferencePathFromPaths provides a mock function with given fields: ctx, allocationID, paths +func (_m *PackageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { + ret := _m.Called(ctx, allocationID, paths) + + var r0 *reference.Ref + if rf, ok := ret.Get(0).(func(context.Context, string, []string) *reference.Ref); ok { + r0 = rf(ctx, allocationID, paths) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*reference.Ref) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string, []string) error); ok { + r1 = rf(ctx, allocationID, paths) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// GetWriteMarkerEntity provides a mock function with given fields: ctx, allocation_root +func (_m *PackageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_root string) (*writemarker.WriteMarkerEntity, error) { + ret := _m.Called(ctx, allocation_root) + + var r0 *writemarker.WriteMarkerEntity + if rf, ok := ret.Get(0).(func(context.Context, string) *writemarker.WriteMarkerEntity); ok { + r0 = rf(ctx, allocation_root) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*writemarker.WriteMarkerEntity) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, string) error); ok { + r1 = rf(ctx, allocation_root) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// IsACollaborator provides a mock function with given fields: ctx, refID, clientID +func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { + ret := _m.Called(ctx, refID, clientID) + + var r0 bool + if rf, ok := ret.Get(0).(func(context.Context, int64, string) bool); ok { + r0 = rf(ctx, refID, clientID) + } else { + r0 = ret.Get(0).(bool) + } + + return r0 +} + +// SaveAllocationChanges provides a mock function with given fields: ctx, alloc +func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + ret := _m.Called(ctx, alloc) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(ctx, alloc) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// UpdateAllocationAndCommitChanges provides a mock function with given fields: ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot +func (_m *PackageHandler) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { + ret := _m.Called(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *writemarker.WriteMarkerEntity, *allocation.AllocationChangeCollector, *allocation.Allocation, string) error); ok { + r0 = rf(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// VerifyMarker provides a mock function with given fields: wm, ctx, sa, co +func (_m *PackageHandler) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx context.Context, sa *allocation.Allocation, co *allocation.AllocationChangeCollector) error { + ret := _m.Called(wm, ctx, sa, co) + + var r0 error + if rf, ok := ret.Get(0).(func(*writemarker.WriteMarkerEntity, context.Context, *allocation.Allocation, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(wm, ctx, sa, co) + } else { + r0 = ret.Error(0) + } + + return r0 +} From 62328cef0dcecff44a2533545e05db1e4871d08f Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sat, 5 Jun 2021 22:03:48 +0530 Subject: [PATCH 107/183] 158 conflicts resolved with grpc --- .../blobbercore/blobbergrpc/blobber.pb.go | 351 ++++++++---------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 120 +++--- .../blobbergrpc/blobber_grpc.pb.go | 26 +- .../0chain.net/blobbercore/handler/helper.go | 5 - .../blobbercore/mocks/PackageHandler.go | 40 +- .../blobbercore/openapi/blobber.swagger.json | 32 +- 6 files changed, 263 insertions(+), 311 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 0789b898c..afbe831c6 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1710,7 +1710,7 @@ type DownloadFileRequest struct { func (x *DownloadFileRequest) Reset() { *x = DownloadFileRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1723,7 +1723,7 @@ func (x *DownloadFileRequest) String() string { func (*DownloadFileRequest) ProtoMessage() {} func (x *DownloadFileRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1736,7 +1736,7 @@ func (x *DownloadFileRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use DownloadFileRequest.ProtoReflect.Descriptor instead. func (*DownloadFileRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *DownloadFileRequest) GetAllocation() string { @@ -1817,7 +1817,7 @@ type DownloadFileResponse struct { func (x *DownloadFileResponse) Reset() { *x = DownloadFileResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1830,7 +1830,7 @@ func (x *DownloadFileResponse) String() string { func (*DownloadFileResponse) ProtoMessage() {} func (x *DownloadFileResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1843,7 +1843,7 @@ func (x *DownloadFileResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use DownloadFileResponse.ProtoReflect.Descriptor instead. func (*DownloadFileResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{27} } func (x *DownloadFileResponse) GetSuccess() bool { @@ -1902,7 +1902,7 @@ type ReadMaker struct { func (x *ReadMaker) Reset() { *x = ReadMaker{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1915,7 +1915,7 @@ func (x *ReadMaker) String() string { func (*ReadMaker) ProtoMessage() {} func (x *ReadMaker) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[22] + mi := &file_blobber_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1928,7 +1928,7 @@ func (x *ReadMaker) ProtoReflect() protoreflect.Message { // Deprecated: Use ReadMaker.ProtoReflect.Descriptor instead. func (*ReadMaker) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{22} + return file_blobber_proto_rawDescGZIP(), []int{28} } func (x *ReadMaker) GetClientId() string { @@ -2035,7 +2035,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2048,7 +2048,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[29] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2061,7 +2061,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{29} } func (x *Allocation) GetID() string { @@ -2198,7 +2198,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2211,7 +2211,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[30] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2224,7 +2224,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{27} + return file_blobber_proto_rawDescGZIP(), []int{30} } func (x *Term) GetID() int64 { @@ -2275,7 +2275,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2288,7 +2288,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[31] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2301,7 +2301,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{28} + return file_blobber_proto_rawDescGZIP(), []int{31} } func (x *FileRef) GetType() string { @@ -2359,7 +2359,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2372,7 +2372,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[32] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2385,7 +2385,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{29} + return file_blobber_proto_rawDescGZIP(), []int{32} } func (x *FileMetaData) GetType() string { @@ -2576,7 +2576,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2589,7 +2589,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[33] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2602,7 +2602,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{30} + return file_blobber_proto_rawDescGZIP(), []int{33} } func (x *DirMetaData) GetType() string { @@ -3085,93 +3085,19 @@ var file_blobber_proto_rawDesc = []byte{ 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x32, 0xf7, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, + 0x32, 0xa5, 0x0c, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, - 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0x96, 0x0b, 0x0a, - 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, @@ -3199,43 +3125,68 @@ var file_blobber_proto_rawDesc = []byte{ 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, + 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, + 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8c, 0x01, 0x0a, 0x0c, + 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x27, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, + 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x64, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, - 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, - 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, - 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, - 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, - 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, - 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, - 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, - 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, - 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, + 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, + 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, + 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, + 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, + 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, + 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, + 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, + 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, + 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -3250,7 +3201,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 31) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 34) var file_blobber_proto_goTypes = []interface{}{ (*CalculateHashRequest)(nil), // 0: blobber.service.v1.CalculateHashRequest (*CalculateHashResponse)(nil), // 1: blobber.service.v1.CalculateHashResponse @@ -3278,11 +3229,14 @@ var file_blobber_proto_goTypes = []interface{}{ (*Collaborator)(nil), // 23: blobber.service.v1.Collaborator (*GetAllocationRequest)(nil), // 24: blobber.service.v1.GetAllocationRequest (*GetAllocationResponse)(nil), // 25: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 26: blobber.service.v1.Allocation - (*Term)(nil), // 27: blobber.service.v1.Term - (*FileRef)(nil), // 28: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 29: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 30: blobber.service.v1.DirMetaData + (*DownloadFileRequest)(nil), // 26: blobber.service.v1.DownloadFileRequest + (*DownloadFileResponse)(nil), // 27: blobber.service.v1.DownloadFileResponse + (*ReadMaker)(nil), // 28: blobber.service.v1.ReadMaker + (*Allocation)(nil), // 29: blobber.service.v1.Allocation + (*Term)(nil), // 30: blobber.service.v1.Term + (*FileRef)(nil), // 31: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 32: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 33: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 14, // 0: blobber.service.v1.CommitResponse.write_marker:type_name -> blobber.service.v1.WriteMarker @@ -3290,49 +3244,52 @@ var file_blobber_proto_depIdxs = []int32{ 14, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 10, // 3: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 14, // 4: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 28, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 31, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 10, // 6: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 13, // 7: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 14, // 8: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 28, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 28, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 28, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 28, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 28, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 28, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 31, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 31, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 31, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 31, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 31, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 31, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 19, // 15: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 28, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 31, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 23, // 17: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 26, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 27, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 29, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 30, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 22, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 24, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 20, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 17, // 25: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 15, // 26: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 11, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest - 8, // 28: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest - 6, // 29: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 2, // 30: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest - 0, // 31: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest - 4, // 32: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest - 25, // 33: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 21, // 34: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 18, // 35: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 16, // 36: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 12, // 37: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 9, // 38: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 7, // 39: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 3, // 40: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 1, // 41: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 5, // 42: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 33, // [33:43] is the sub-list for method output_type - 23, // [23:33] is the sub-list for method input_type - 23, // [23:23] is the sub-list for extension type_name - 23, // [23:23] is the sub-list for extension extendee - 0, // [0:23] is the sub-list for field type_name + 29, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 28, // 19: blobber.service.v1.DownloadFileResponse.latest_rm:type_name -> blobber.service.v1.ReadMaker + 30, // 20: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 32, // 21: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 33, // 22: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 22, // 23: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 24, // 24: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 20, // 25: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 17, // 26: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 15, // 27: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 11, // 28: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 8, // 29: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest + 6, // 30: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest + 26, // 31: blobber.service.v1.Blobber.DownloadFile:input_type -> blobber.service.v1.DownloadFileRequest + 2, // 32: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest + 0, // 33: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest + 4, // 34: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest + 25, // 35: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 21, // 36: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 18, // 37: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 16, // 38: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 12, // 39: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 9, // 40: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 7, // 41: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 27, // 42: blobber.service.v1.Blobber.DownloadFile:output_type -> blobber.service.v1.DownloadFileResponse + 3, // 43: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 1, // 44: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 5, // 45: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 35, // [35:46] is the sub-list for method output_type + 24, // [24:35] is the sub-list for method input_type + 24, // [24:24] is the sub-list for extension type_name + 24, // [24:24] is the sub-list for extension extendee + 0, // [0:24] is the sub-list for field type_name } func init() { file_blobber_proto_init() } @@ -3665,7 +3622,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DownloadFileResponse); i { case 0: return &v.state @@ -3677,7 +3634,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*ReadMaker); i { case 0: return &v.state @@ -3689,7 +3646,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Allocation); i { case 0: return &v.state @@ -3701,7 +3658,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Term); i { case 0: return &v.state @@ -3713,7 +3670,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileRef); i { case 0: return &v.state @@ -3725,7 +3682,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileMetaData); i { case 0: return &v.state @@ -3737,7 +3694,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[33].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -3756,7 +3713,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 31, + NumMessages: 34, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 2073bdfc9..352b25852 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -487,8 +487,8 @@ func local_request_Blobber_GetObjectTree_0(ctx context.Context, marshaler runtim } -func request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CommitRequest +func request_Blobber_DownloadFile_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DownloadFileRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -516,13 +516,13 @@ func request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.Commit(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.DownloadFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CommitRequest +func local_request_Blobber_DownloadFile_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DownloadFileRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -550,13 +550,13 @@ func local_request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marsh return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.Commit(ctx, &protoReq) + msg, err := server.DownloadFile(ctx, &protoReq) return msg, metadata, err } -func request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CalculateHashRequest +func request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -584,13 +584,13 @@ func request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Mars return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.CalculateHash(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.Commit(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CalculateHashRequest +func local_request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -618,13 +618,13 @@ func local_request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtim return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.CalculateHash(ctx, &protoReq) + msg, err := server.Commit(ctx, &protoReq) return msg, metadata, err } -func request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CommitMetaTxnRequest +func request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CalculateHashRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -652,13 +652,13 @@ func request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Mars return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.CommitMetaTxn(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.CalculateHash(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CommitMetaTxnRequest +func local_request_Blobber_CalculateHash_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CalculateHashRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -686,13 +686,13 @@ func local_request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtim return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.CommitMetaTxn(ctx, &protoReq) + msg, err := server.CalculateHash(ctx, &protoReq) return msg, metadata, err } -func request_Blobber_DownloadFile_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq DownloadFileRequest +func request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitMetaTxnRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -720,13 +720,13 @@ func request_Blobber_DownloadFile_0(ctx context.Context, marshaler runtime.Marsh return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.DownloadFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.CommitMetaTxn(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_DownloadFile_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq DownloadFileRequest +func local_request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CommitMetaTxnRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -754,7 +754,7 @@ func local_request_Blobber_DownloadFile_0(ctx context.Context, marshaler runtime return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.DownloadFile(ctx, &protoReq) + msg, err := server.CommitMetaTxn(ctx, &protoReq) return msg, metadata, err } @@ -926,18 +926,18 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) - mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_DownloadFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/Commit") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/DownloadFile") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_Commit_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_DownloadFile_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -945,22 +945,22 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_Commit_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_DownloadFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/Commit") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_CalculateHash_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_Commit_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -968,22 +968,22 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_Commit_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_CommitMetaTxn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CommitMetaTxn") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_CommitMetaTxn_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_CalculateHash_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -991,22 +991,22 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_CommitMetaTxn_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_DownloadFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_CommitMetaTxn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/DownloadFile") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CommitMetaTxn") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_DownloadFile_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_CommitMetaTxn_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -1014,7 +1014,7 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_DownloadFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_CommitMetaTxn_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) @@ -1199,83 +1199,83 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) - mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_DownloadFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/Commit") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/DownloadFile") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_Commit_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_DownloadFile_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_Commit_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_DownloadFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/Commit") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_CalculateHash_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_Commit_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_Commit_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_CommitMetaTxn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_CalculateHash_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CommitMetaTxn") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CalculateHash") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_CommitMetaTxn_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_CalculateHash_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_CommitMetaTxn_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_CalculateHash_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_DownloadFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_CommitMetaTxn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/DownloadFile") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CommitMetaTxn") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_DownloadFile_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_CommitMetaTxn_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_DownloadFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_CommitMetaTxn_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) @@ -1297,13 +1297,13 @@ var ( pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) + pattern_Blobber_DownloadFile_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "download", "allocation"}, "")) + pattern_Blobber_Commit_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "connection", "commit", "allocation"}, "")) pattern_Blobber_CalculateHash_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "calculatehash", "allocation"}, "")) pattern_Blobber_CommitMetaTxn_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "commitmetatxn", "allocation"}, "")) - - pattern_Blobber_DownloadFile_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "download", "allocation"}, "")) ) var ( @@ -1321,11 +1321,11 @@ var ( forward_Blobber_GetObjectTree_0 = runtime.ForwardResponseMessage + forward_Blobber_DownloadFile_0 = runtime.ForwardResponseMessage + forward_Blobber_Commit_0 = runtime.ForwardResponseMessage forward_Blobber_CalculateHash_0 = runtime.ForwardResponseMessage forward_Blobber_CommitMetaTxn_0 = runtime.ForwardResponseMessage - - forward_Blobber_DownloadFile_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 710d81299..f91624c41 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -101,6 +101,15 @@ func (c *blobberClient) GetObjectTree(ctx context.Context, in *GetObjectTreeRequ return out, nil } +func (c *blobberClient) DownloadFile(ctx context.Context, in *DownloadFileRequest, opts ...grpc.CallOption) (*DownloadFileResponse, error) { + out := new(DownloadFileResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/DownloadFile", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *blobberClient) Commit(ctx context.Context, in *CommitRequest, opts ...grpc.CallOption) (*CommitResponse, error) { out := new(CommitResponse) err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/Commit", in, out, opts...) @@ -128,15 +137,6 @@ func (c *blobberClient) CommitMetaTxn(ctx context.Context, in *CommitMetaTxnRequ return out, nil } -func (c *blobberClient) DownloadFile(ctx context.Context, in *DownloadFileRequest, opts ...grpc.CallOption) (*DownloadFileResponse, error) { - out := new(DownloadFileResponse) - err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/DownloadFile", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -435,6 +435,10 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "GetObjectTree", Handler: _Blobber_GetObjectTree_Handler, }, + { + MethodName: "DownloadFile", + Handler: _Blobber_DownloadFile_Handler, + }, { MethodName: "Commit", Handler: _Blobber_Commit_Handler, @@ -447,10 +451,6 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "CommitMetaTxn", Handler: _Blobber_CommitMetaTxn_Handler, }, - { - MethodName: "DownloadFile", - Handler: _Blobber_DownloadFile_Handler, - }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index 1e9bb8c7f..8438f6b4e 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -151,8 +151,3 @@ func (r *packageHandler) FileBlockDownloaded(ctx context.Context, refID int64) { func (r *packageHandler) VerifyReadMarker(ctx context.Context, readMake *readmarker.ReadMarkerEntity, alloc *allocation.Allocation) error { return readMake.VerifyMarker(ctx, alloc) } - -// -//func (r *packageHandler) GetNewReadMaker(rm *readmarker.ReadMarker) readmarker.ReadMakerI { -// return readmarker.NewReadMakerEntity(rm) -//} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 34b466e18..9239a4a1b 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -1,4 +1,4 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. +// Code generated by mockery 2.7.5. DO NOT EDIT. package mocks @@ -53,6 +53,11 @@ func (_m *PackageHandler) ApplyChanges(connectionObj *allocation.AllocationChang return r0 } +// FileBlockDownloaded provides a mock function with given fields: ctx, refID +func (_m *PackageHandler) FileBlockDownloaded(ctx context.Context, refID int64) { + _m.Called(ctx, refID) +} + // GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { ret := _m.Called(ctx, connectionID, allocationID, clientID) @@ -76,11 +81,6 @@ func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID return r0, r1 } -// FileBlockDownloaded provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) FileBlockDownloaded(ctx context.Context, refID int64) { - _m.Called(ctx, refID) -} - // GetCollaborators provides a mock function with given fields: ctx, refID func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { ret := _m.Called(ctx, refID) @@ -378,6 +378,20 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } +// SaveLatestReadMarker provides a mock function with given fields: ctx, rm, isCreate +func (_m *PackageHandler) SaveLatestReadMarker(ctx context.Context, rm *readmarker.ReadMarker, isCreate bool) error { + ret := _m.Called(ctx, rm, isCreate) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *readmarker.ReadMarker, bool) error); ok { + r0 = rf(ctx, rm, isCreate) + } else { + r0 = ret.Error(0) + } + + return r0 +} + // UpdateAllocationAndCommitChanges provides a mock function with given fields: ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot func (_m *PackageHandler) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { ret := _m.Called(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) @@ -406,20 +420,6 @@ func (_m *PackageHandler) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx co return r0 } -// SaveLatestReadMarker provides a mock function with given fields: ctx, rm, isCreate -func (_m *PackageHandler) SaveLatestReadMarker(ctx context.Context, rm *readmarker.ReadMarker, isCreate bool) error { - ret := _m.Called(ctx, rm, isCreate) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *readmarker.ReadMarker, bool) error); ok { - r0 = rf(ctx, rm, isCreate) - } else { - r0 = ret.Error(0) - } - - return r0 -} - // VerifyReadMarker provides a mock function with given fields: ctx, readMake, alloc func (_m *PackageHandler) VerifyReadMarker(ctx context.Context, readMake *readmarker.ReadMarkerEntity, alloc *allocation.Allocation) error { ret := _m.Called(ctx, readMake, alloc) diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 2d3ba21a3..03df47175 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -46,14 +46,14 @@ ] } }, - "/v2/file/download/{allocation}": { + "/v2/connection/commit/{allocation}": { "post": { - "operationId": "Blobber_DownloadFile", + "operationId": "Blobber_Commit", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1DownloadFileResponse" + "$ref": "#/definitions/v1CommitResponse" } }, "default": { @@ -75,7 +75,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/v1DownloadFileRequest" + "$ref": "#/definitions/v1CommitRequest" } } ], @@ -84,14 +84,14 @@ ] } }, - "/v2/connection/commit/{allocation}": { + "/v2/file/calculatehash/{allocation}": { "post": { - "operationId": "Blobber_Commit", + "operationId": "Blobber_CalculateHash", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1CommitResponse" + "$ref": "#/definitions/v1CalculateHashResponse" } }, "default": { @@ -113,7 +113,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/v1CommitRequest" + "$ref": "#/definitions/v1CalculateHashRequest" } } ], @@ -122,14 +122,14 @@ ] } }, - "/v2/file/calculatehash/{allocation}": { + "/v2/file/commitmetatxn/{allocation}": { "post": { - "operationId": "Blobber_CalculateHash", + "operationId": "Blobber_CommitMetaTxn", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1CalculateHashResponse" + "$ref": "#/definitions/v1CommitMetaTxnResponse" } }, "default": { @@ -151,7 +151,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/v1CalculateHashRequest" + "$ref": "#/definitions/v1CommitMetaTxnRequest" } } ], @@ -160,14 +160,14 @@ ] } }, - "/v2/file/commitmetatxn/{allocation}": { + "/v2/file/download/{allocation}": { "post": { - "operationId": "Blobber_CommitMetaTxn", + "operationId": "Blobber_DownloadFile", "responses": { "200": { "description": "A successful response.", "schema": { - "$ref": "#/definitions/v1CommitMetaTxnResponse" + "$ref": "#/definitions/v1DownloadFileResponse" } }, "default": { @@ -189,7 +189,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/v1CommitMetaTxnRequest" + "$ref": "#/definitions/v1DownloadFileRequest" } } ], From 7e3ade8447bb30eb2a890b029c63a4dcb1a6d3b7 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sat, 5 Jun 2021 22:31:13 +0530 Subject: [PATCH 108/183] 169 conflicts resolved with grpc --- .../blobbercore/blobbergrpc/blobber.pb.go | 295 +++++++----------- .../blobbergrpc/blobber_grpc.pb.go | 77 +++-- .../0chain.net/blobbercore/handler/helper.go | 12 - .../blobbercore/mocks/PackageHandler.go | 30 +- 4 files changed, 164 insertions(+), 250 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 8b11e4afd..8a006a74a 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1709,7 +1709,7 @@ type UploadFileRequest struct { func (x *UploadFileRequest) Reset() { *x = UploadFileRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1722,7 +1722,7 @@ func (x *UploadFileRequest) String() string { func (*UploadFileRequest) ProtoMessage() {} func (x *UploadFileRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[20] + mi := &file_blobber_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1735,7 +1735,7 @@ func (x *UploadFileRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use UploadFileRequest.ProtoReflect.Descriptor instead. func (*UploadFileRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{20} + return file_blobber_proto_rawDescGZIP(), []int{26} } func (x *UploadFileRequest) GetAllocation() string { @@ -1812,7 +1812,7 @@ type UploadFileResponse struct { func (x *UploadFileResponse) Reset() { *x = UploadFileResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1825,7 +1825,7 @@ func (x *UploadFileResponse) String() string { func (*UploadFileResponse) ProtoMessage() {} func (x *UploadFileResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[21] + mi := &file_blobber_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1838,7 +1838,7 @@ func (x *UploadFileResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use UploadFileResponse.ProtoReflect.Descriptor instead. func (*UploadFileResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{21} + return file_blobber_proto_rawDescGZIP(), []int{27} } func (x *UploadFileResponse) GetFilename() string { @@ -1910,7 +1910,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1923,7 +1923,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1936,7 +1936,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{28} } func (x *Allocation) GetID() string { @@ -2073,7 +2073,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2086,7 +2086,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2099,7 +2099,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{27} + return file_blobber_proto_rawDescGZIP(), []int{29} } func (x *Term) GetID() int64 { @@ -2150,7 +2150,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2163,7 +2163,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2176,7 +2176,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{28} + return file_blobber_proto_rawDescGZIP(), []int{30} } func (x *FileRef) GetType() string { @@ -2234,7 +2234,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2247,7 +2247,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2260,7 +2260,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{29} + return file_blobber_proto_rawDescGZIP(), []int{31} } func (x *FileMetaData) GetType() string { @@ -2451,7 +2451,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2464,7 +2464,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2477,7 +2477,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{30} + return file_blobber_proto_rawDescGZIP(), []int{32} } func (x *DirMetaData) GetType() string { @@ -2940,7 +2940,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, - 0xc6, 0x08, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, + 0xf4, 0x0b, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, @@ -2951,82 +2951,6 @@ var file_blobber_proto_rawDesc = []byte{ 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, - 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, - 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, - 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, - 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, - 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0x96, 0x0b, 0x0a, - 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, @@ -3072,50 +2996,49 @@ var file_blobber_proto_rawDesc = []byte{ 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, - 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, - 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, - 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, - 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, - 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, - 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, + 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x5c, 0x0a, 0x09, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, + 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, + 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, + 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, - 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, - 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, - 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, + 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, + 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, + 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, + 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, + 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, + 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -3130,7 +3053,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 31) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 33) var file_blobber_proto_goTypes = []interface{}{ (*CalculateHashRequest)(nil), // 0: blobber.service.v1.CalculateHashRequest (*CalculateHashResponse)(nil), // 1: blobber.service.v1.CalculateHashResponse @@ -3158,11 +3081,13 @@ var file_blobber_proto_goTypes = []interface{}{ (*Collaborator)(nil), // 23: blobber.service.v1.Collaborator (*GetAllocationRequest)(nil), // 24: blobber.service.v1.GetAllocationRequest (*GetAllocationResponse)(nil), // 25: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 26: blobber.service.v1.Allocation - (*Term)(nil), // 27: blobber.service.v1.Term - (*FileRef)(nil), // 28: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 29: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 30: blobber.service.v1.DirMetaData + (*UploadFileRequest)(nil), // 26: blobber.service.v1.UploadFileRequest + (*UploadFileResponse)(nil), // 27: blobber.service.v1.UploadFileResponse + (*Allocation)(nil), // 28: blobber.service.v1.Allocation + (*Term)(nil), // 29: blobber.service.v1.Term + (*FileRef)(nil), // 30: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 31: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 32: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 14, // 0: blobber.service.v1.CommitResponse.write_marker:type_name -> blobber.service.v1.WriteMarker @@ -3170,23 +3095,23 @@ var file_blobber_proto_depIdxs = []int32{ 14, // 2: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 10, // 3: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 14, // 4: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 28, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 5: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 10, // 6: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 13, // 7: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 14, // 8: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 28, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 28, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 28, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 28, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 28, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 28, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 9: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 30, // 10: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 30, // 11: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 30, // 12: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 13: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 30, // 14: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 19, // 15: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 28, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 30, // 16: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 23, // 17: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 26, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 27, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 29, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 30, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 28, // 18: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 29, // 19: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 31, // 20: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 32, // 21: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 22, // 22: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 24, // 23: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 20, // 24: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -3195,21 +3120,23 @@ var file_blobber_proto_depIdxs = []int32{ 11, // 27: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest 8, // 28: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest 6, // 29: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 2, // 30: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest - 0, // 31: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest - 4, // 32: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest - 25, // 33: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 21, // 34: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 18, // 35: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 16, // 36: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 12, // 37: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 9, // 38: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 7, // 39: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 3, // 40: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 1, // 41: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 5, // 42: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 33, // [33:43] is the sub-list for method output_type - 23, // [23:33] is the sub-list for method input_type + 26, // 30: blobber.service.v1.Blobber.WriteFile:input_type -> blobber.service.v1.UploadFileRequest + 2, // 31: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest + 0, // 32: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest + 4, // 33: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest + 25, // 34: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 21, // 35: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 18, // 36: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 16, // 37: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 12, // 38: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 9, // 39: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 7, // 40: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 27, // 41: blobber.service.v1.Blobber.WriteFile:output_type -> blobber.service.v1.UploadFileResponse + 3, // 42: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 1, // 43: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 5, // 44: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 34, // [34:45] is the sub-list for method output_type + 23, // [23:34] is the sub-list for method input_type 23, // [23:23] is the sub-list for extension type_name 23, // [23:23] is the sub-list for extension extendee 0, // [0:23] is the sub-list for field type_name @@ -3534,7 +3461,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*UploadFileRequest); i { case 0: return &v.state case 1: @@ -3546,7 +3473,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*UploadFileResponse); i { case 0: return &v.state case 1: @@ -3557,8 +3484,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UploadFileRequest); i { + file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -3569,8 +3496,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UploadFileResponse); i { + file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -3581,7 +3508,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileRef); i { case 0: return &v.state @@ -3593,7 +3520,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileMetaData); i { case 0: return &v.state @@ -3605,7 +3532,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -3624,7 +3551,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 31, + NumMessages: 33, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 565dbf032..4035bca71 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -11,7 +11,6 @@ import ( // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. -// Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 // BlobberClient is the client API for Blobber service. @@ -25,10 +24,10 @@ type BlobberClient interface { GetObjectPath(ctx context.Context, in *GetObjectPathRequest, opts ...grpc.CallOption) (*GetObjectPathResponse, error) GetReferencePath(ctx context.Context, in *GetReferencePathRequest, opts ...grpc.CallOption) (*GetReferencePathResponse, error) GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) + WriteFile(ctx context.Context, in *UploadFileRequest, opts ...grpc.CallOption) (*UploadFileResponse, error) Commit(ctx context.Context, in *CommitRequest, opts ...grpc.CallOption) (*CommitResponse, error) CalculateHash(ctx context.Context, in *CalculateHashRequest, opts ...grpc.CallOption) (*CalculateHashResponse, error) CommitMetaTxn(ctx context.Context, in *CommitMetaTxnRequest, opts ...grpc.CallOption) (*CommitMetaTxnResponse, error) - WriteFile(ctx context.Context, in *UploadFileRequest, opts ...grpc.CallOption) (*UploadFileResponse, error) } type blobberClient struct { @@ -102,6 +101,15 @@ func (c *blobberClient) GetObjectTree(ctx context.Context, in *GetObjectTreeRequ return out, nil } +func (c *blobberClient) WriteFile(ctx context.Context, in *UploadFileRequest, opts ...grpc.CallOption) (*UploadFileResponse, error) { + out := new(UploadFileResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/WriteFile", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *blobberClient) Commit(ctx context.Context, in *CommitRequest, opts ...grpc.CallOption) (*CommitResponse, error) { out := new(CommitResponse) err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/Commit", in, out, opts...) @@ -129,15 +137,6 @@ func (c *blobberClient) CommitMetaTxn(ctx context.Context, in *CommitMetaTxnRequ return out, nil } -func (c *blobberClient) WriteFile(ctx context.Context, in *UploadFileRequest, opts ...grpc.CallOption) (*UploadFileResponse, error) { - out := new(UploadFileResponse) - err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/WriteFile", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - // BlobberServer is the server API for Blobber service. // All implementations must embed UnimplementedBlobberServer // for forward compatibility @@ -149,10 +148,10 @@ type BlobberServer interface { GetObjectPath(context.Context, *GetObjectPathRequest) (*GetObjectPathResponse, error) GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) + WriteFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) Commit(context.Context, *CommitRequest) (*CommitResponse, error) CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) - WriteFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -181,6 +180,9 @@ func (UnimplementedBlobberServer) GetReferencePath(context.Context, *GetReferenc func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetObjectTree not implemented") } +func (UnimplementedBlobberServer) WriteFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method WriteFile not implemented") +} func (UnimplementedBlobberServer) Commit(context.Context, *CommitRequest) (*CommitResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Commit not implemented") } @@ -190,9 +192,6 @@ func (UnimplementedBlobberServer) CalculateHash(context.Context, *CalculateHashR func (UnimplementedBlobberServer) CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CommitMetaTxn not implemented") } -func (UnimplementedBlobberServer) WriteFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method WriteFile not implemented") -} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -202,8 +201,8 @@ type UnsafeBlobberServer interface { mustEmbedUnimplementedBlobberServer() } -func RegisterBlobberServer(s grpc.ServiceRegistrar, srv BlobberServer) { - s.RegisterService(&Blobber_ServiceDesc, srv) +func RegisterBlobberServer(s *grpc.Server, srv BlobberServer) { + s.RegisterService(&_Blobber_serviceDesc, srv) } func _Blobber_GetAllocation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { @@ -332,6 +331,24 @@ func _Blobber_GetObjectTree_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } +func _Blobber_WriteFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(UploadFileRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlobberServer).WriteFile(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/blobber.service.v1.Blobber/WriteFile", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlobberServer).WriteFile(ctx, req.(*UploadFileRequest)) + } + return interceptor(ctx, in, info, handler) +} + func _Blobber_Commit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(CommitRequest) if err := dec(in); err != nil { @@ -387,28 +404,6 @@ func _Blobber_CommitMetaTxn_Handler(srv interface{}, ctx context.Context, dec fu } var _Blobber_serviceDesc = grpc.ServiceDesc{ -func _Blobber_WriteFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(UploadFileRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(BlobberServer).WriteFile(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/blobber.service.v1.Blobber/WriteFile", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(BlobberServer).WriteFile(ctx, req.(*UploadFileRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// Blobber_ServiceDesc is the grpc.ServiceDesc for Blobber service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var Blobber_ServiceDesc = grpc.ServiceDesc{ ServiceName: "blobber.service.v1.Blobber", HandlerType: (*BlobberServer)(nil), Methods: []grpc.MethodDesc{ @@ -440,6 +435,10 @@ var Blobber_ServiceDesc = grpc.ServiceDesc{ MethodName: "GetObjectTree", Handler: _Blobber_GetObjectTree_Handler, }, + { + MethodName: "WriteFile", + Handler: _Blobber_WriteFile_Handler, + }, { MethodName: "Commit", Handler: _Blobber_Commit_Handler, diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index 754b15133..3062c072e 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -31,7 +31,6 @@ type StorageHandlerI interface { // PackageHandler is an interface for all static functions that may need to be mocked type PackageHandler interface { - GetReference(ctx context.Context, allocationID string, newPath string) (*reference.Ref, error) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) AddCommitMetaTxn(ctx context.Context, refID int64, txnID string) error @@ -42,7 +41,6 @@ type PackageHandler interface { GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) - GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error GetFileStore() filestore.FileStore GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) @@ -99,11 +97,6 @@ func (r *packageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_ro return writemarker.GetWriteMarkerEntity(ctx, allocation_root) } -func (r *packageHandler) GetReference(ctx context.Context, allocationID string, newPath string) ( - *reference.Ref, error) { - return reference.GetReference(ctx, allocationID, newPath) -} - func (r *packageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { return reference.GetReferenceFromLookupHash(ctx, allocationID, path_hash) } @@ -124,11 +117,6 @@ func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clien return reference.IsACollaborator(ctx, refID, clientID) } -func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { - - return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) -} - func (r *packageHandler) GetFileStore() filestore.FileStore { return filestore.GetFileStore() } diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index ac21fe4e3..6aa3e6be0 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -1,4 +1,4 @@ -// Code generated by mockery v0.0.0-dev. DO NOT EDIT. +// Code generated by mockery 2.7.5. DO NOT EDIT. package mocks @@ -334,6 +334,20 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } +// SaveAllocationChanges provides a mock function with given fields: ctx, alloc +func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + ret := _m.Called(ctx, alloc) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(ctx, alloc) + } else { + r0 = ret.Error(0) + } + + return r0 +} + // UpdateAllocationAndCommitChanges provides a mock function with given fields: ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot func (_m *PackageHandler) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { ret := _m.Called(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) @@ -361,17 +375,3 @@ func (_m *PackageHandler) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx co return r0 } - -// SaveAllocationChanges provides a mock function with given fields: ctx, alloc -func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { - ret := _m.Called(ctx, alloc) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { - r0 = rf(ctx, alloc) - } else { - r0 = ret.Error(0) - } - - return r0 -} From b2701f4bdadc1e8679d31c53905ff2061c26f398 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sat, 5 Jun 2021 22:49:19 +0530 Subject: [PATCH 109/183] 137 conflicts resolved with grpc ii --- .../blobbercore/blobbergrpc/blobber.pb.go | 659 +++++++++--------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 40 +- .../blobbergrpc/blobber_grpc.pb.go | 48 +- .../blobbercore/mocks/PackageHandler.go | 20 +- 4 files changed, 399 insertions(+), 368 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index be27d2bf9..1e8cff8ea 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -229,7 +229,7 @@ type CalculateHashResponse struct { func (x *CalculateHashResponse) Reset() { *x = CalculateHashResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[1] + mi := &file_blobber_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1840,7 +1840,7 @@ type UpdateObjectAttributesRequest struct { func (x *UpdateObjectAttributesRequest) Reset() { *x = UpdateObjectAttributesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1853,7 +1853,7 @@ func (x *UpdateObjectAttributesRequest) String() string { func (*UpdateObjectAttributesRequest) ProtoMessage() {} func (x *UpdateObjectAttributesRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1866,7 +1866,7 @@ func (x *UpdateObjectAttributesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateObjectAttributesRequest.ProtoReflect.Descriptor instead. func (*UpdateObjectAttributesRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{28} } func (x *UpdateObjectAttributesRequest) GetAllocation() string { @@ -1915,7 +1915,7 @@ type UpdateObjectAttributesResponse struct { func (x *UpdateObjectAttributesResponse) Reset() { *x = UpdateObjectAttributesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1928,7 +1928,7 @@ func (x *UpdateObjectAttributesResponse) String() string { func (*UpdateObjectAttributesResponse) ProtoMessage() {} func (x *UpdateObjectAttributesResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1941,7 +1941,7 @@ func (x *UpdateObjectAttributesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateObjectAttributesResponse.ProtoReflect.Descriptor instead. func (*UpdateObjectAttributesResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{27} + return file_blobber_proto_rawDescGZIP(), []int{29} } func (x *UpdateObjectAttributesResponse) GetWhoPaysForReads() int64 { @@ -1978,7 +1978,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1991,7 +1991,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2004,7 +2004,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{28} + return file_blobber_proto_rawDescGZIP(), []int{30} } func (x *Allocation) GetID() string { @@ -2141,7 +2141,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2154,7 +2154,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2167,7 +2167,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{29} + return file_blobber_proto_rawDescGZIP(), []int{31} } func (x *Term) GetID() int64 { @@ -2218,7 +2218,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2231,7 +2231,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2244,7 +2244,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{30} + return file_blobber_proto_rawDescGZIP(), []int{32} } func (x *FileRef) GetType() string { @@ -2302,7 +2302,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[31] + mi := &file_blobber_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2315,7 +2315,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[31] + mi := &file_blobber_proto_msgTypes[33] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2328,7 +2328,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{31} + return file_blobber_proto_rawDescGZIP(), []int{33} } func (x *FileMetaData) GetType() string { @@ -2519,7 +2519,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[32] + mi := &file_blobber_proto_msgTypes[34] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2532,7 +2532,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[32] + mi := &file_blobber_proto_msgTypes[34] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2545,7 +2545,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{32} + return file_blobber_proto_rawDescGZIP(), []int{34} } func (x *DirMetaData) GetType() string { @@ -2870,233 +2870,260 @@ var file_blobber_proto_rawDesc = []byte{ 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, - 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, - 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, - 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, - 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, - 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, - 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, - 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, - 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, - 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, - 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, - 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, - 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, - 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, - 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, - 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, - 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, - 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, - 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, - 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, - 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, - 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, - 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, - 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, - 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, - 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, - 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, - 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, - 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, - 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, - 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, - 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, - 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, - 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, - 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, - 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, - 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, - 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, - 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, - 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, - 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, - 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, - 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, - 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, - 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, - 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, - 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, - 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, - 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, - 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, - 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, - 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, - 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, - 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, - 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, - 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, - 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, - 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, - 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x32, 0xa9, 0x0c, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, - 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, - 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, - 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, - 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, - 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb5, 0x01, + 0x0a, 0x1d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, + 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, + 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, + 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, + 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, + 0x62, 0x75, 0x74, 0x65, 0x73, 0x22, 0x4d, 0x0a, 0x1e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2b, 0x0a, 0x12, 0x77, 0x68, 0x6f, 0x5f, 0x70, + 0x61, 0x79, 0x73, 0x5f, 0x66, 0x6f, 0x72, 0x5f, 0x72, 0x65, 0x61, 0x64, 0x73, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0f, 0x77, 0x68, 0x6f, 0x50, 0x61, 0x79, 0x73, 0x46, 0x6f, 0x72, 0x52, + 0x65, 0x61, 0x64, 0x73, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, + 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, + 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, + 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, + 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, + 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, + 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, + 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, + 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, + 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, + 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, + 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, + 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, + 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, + 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, + 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, + 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, + 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, + 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, + 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, + 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, + 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, + 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, + 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, + 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, + 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, + 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, + 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, + 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, + 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, + 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, + 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, + 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, + 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, + 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, + 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, + 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, + 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, + 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, + 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, + 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, + 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, + 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, + 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, + 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, + 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, + 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, + 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, + 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, + 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, + 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, + 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, + 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xd8, 0x0d, 0x0a, 0x07, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, + 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, + 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, - 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, + 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, + 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, + 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, + 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, - 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, - 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, - 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, - 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, - 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, - 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, - 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, - 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, + 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, + 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, - 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, - 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, - 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, - 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, - 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, - 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, + 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, + 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, + 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, + 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, + 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, + 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, - 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, - 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, - 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, - 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, - 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, + 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, + 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, + 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, + 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, + 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x22, 0x20, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, + 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, + 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, + 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, + 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -3111,41 +3138,43 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 33) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 35) var file_blobber_proto_goTypes = []interface{}{ - (*CollaboratorRequest)(nil), // 0: blobber.service.v1.CollaboratorRequest - (*CollaboratorResponse)(nil), // 1: blobber.service.v1.CollaboratorResponse - (*CalculateHashRequest)(nil), // 2: blobber.service.v1.CalculateHashRequest - (*CalculateHashResponse)(nil), // 3: blobber.service.v1.CalculateHashResponse - (*CommitRequest)(nil), // 4: blobber.service.v1.CommitRequest - (*CommitResponse)(nil), // 5: blobber.service.v1.CommitResponse - (*CommitMetaTxnRequest)(nil), // 6: blobber.service.v1.CommitMetaTxnRequest - (*CommitMetaTxnResponse)(nil), // 7: blobber.service.v1.CommitMetaTxnResponse - (*GetObjectTreeRequest)(nil), // 8: blobber.service.v1.GetObjectTreeRequest - (*GetObjectTreeResponse)(nil), // 9: blobber.service.v1.GetObjectTreeResponse - (*GetReferencePathRequest)(nil), // 10: blobber.service.v1.GetReferencePathRequest - (*GetReferencePathResponse)(nil), // 11: blobber.service.v1.GetReferencePathResponse - (*ReferencePath)(nil), // 12: blobber.service.v1.ReferencePath - (*GetObjectPathRequest)(nil), // 13: blobber.service.v1.GetObjectPathRequest - (*GetObjectPathResponse)(nil), // 14: blobber.service.v1.GetObjectPathResponse - (*ObjectPath)(nil), // 15: blobber.service.v1.ObjectPath - (*WriteMarker)(nil), // 16: blobber.service.v1.WriteMarker - (*ListEntitiesRequest)(nil), // 17: blobber.service.v1.ListEntitiesRequest - (*ListEntitiesResponse)(nil), // 18: blobber.service.v1.ListEntitiesResponse - (*GetFileStatsRequest)(nil), // 19: blobber.service.v1.GetFileStatsRequest - (*GetFileStatsResponse)(nil), // 20: blobber.service.v1.GetFileStatsResponse - (*FileStats)(nil), // 21: blobber.service.v1.FileStats - (*GetFileMetaDataRequest)(nil), // 22: blobber.service.v1.GetFileMetaDataRequest - (*GetFileMetaDataResponse)(nil), // 23: blobber.service.v1.GetFileMetaDataResponse - (*CommitMetaTxn)(nil), // 24: blobber.service.v1.CommitMetaTxn - (*Collaborator)(nil), // 25: blobber.service.v1.Collaborator - (*GetAllocationRequest)(nil), // 26: blobber.service.v1.GetAllocationRequest - (*GetAllocationResponse)(nil), // 27: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 28: blobber.service.v1.Allocation - (*Term)(nil), // 29: blobber.service.v1.Term - (*FileRef)(nil), // 30: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 31: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 32: blobber.service.v1.DirMetaData + (*CollaboratorRequest)(nil), // 0: blobber.service.v1.CollaboratorRequest + (*CollaboratorResponse)(nil), // 1: blobber.service.v1.CollaboratorResponse + (*CalculateHashRequest)(nil), // 2: blobber.service.v1.CalculateHashRequest + (*CalculateHashResponse)(nil), // 3: blobber.service.v1.CalculateHashResponse + (*CommitRequest)(nil), // 4: blobber.service.v1.CommitRequest + (*CommitResponse)(nil), // 5: blobber.service.v1.CommitResponse + (*CommitMetaTxnRequest)(nil), // 6: blobber.service.v1.CommitMetaTxnRequest + (*CommitMetaTxnResponse)(nil), // 7: blobber.service.v1.CommitMetaTxnResponse + (*GetObjectTreeRequest)(nil), // 8: blobber.service.v1.GetObjectTreeRequest + (*GetObjectTreeResponse)(nil), // 9: blobber.service.v1.GetObjectTreeResponse + (*GetReferencePathRequest)(nil), // 10: blobber.service.v1.GetReferencePathRequest + (*GetReferencePathResponse)(nil), // 11: blobber.service.v1.GetReferencePathResponse + (*ReferencePath)(nil), // 12: blobber.service.v1.ReferencePath + (*GetObjectPathRequest)(nil), // 13: blobber.service.v1.GetObjectPathRequest + (*GetObjectPathResponse)(nil), // 14: blobber.service.v1.GetObjectPathResponse + (*ObjectPath)(nil), // 15: blobber.service.v1.ObjectPath + (*WriteMarker)(nil), // 16: blobber.service.v1.WriteMarker + (*ListEntitiesRequest)(nil), // 17: blobber.service.v1.ListEntitiesRequest + (*ListEntitiesResponse)(nil), // 18: blobber.service.v1.ListEntitiesResponse + (*GetFileStatsRequest)(nil), // 19: blobber.service.v1.GetFileStatsRequest + (*GetFileStatsResponse)(nil), // 20: blobber.service.v1.GetFileStatsResponse + (*FileStats)(nil), // 21: blobber.service.v1.FileStats + (*GetFileMetaDataRequest)(nil), // 22: blobber.service.v1.GetFileMetaDataRequest + (*GetFileMetaDataResponse)(nil), // 23: blobber.service.v1.GetFileMetaDataResponse + (*CommitMetaTxn)(nil), // 24: blobber.service.v1.CommitMetaTxn + (*Collaborator)(nil), // 25: blobber.service.v1.Collaborator + (*GetAllocationRequest)(nil), // 26: blobber.service.v1.GetAllocationRequest + (*GetAllocationResponse)(nil), // 27: blobber.service.v1.GetAllocationResponse + (*UpdateObjectAttributesRequest)(nil), // 28: blobber.service.v1.UpdateObjectAttributesRequest + (*UpdateObjectAttributesResponse)(nil), // 29: blobber.service.v1.UpdateObjectAttributesResponse + (*Allocation)(nil), // 30: blobber.service.v1.Allocation + (*Term)(nil), // 31: blobber.service.v1.Term + (*FileRef)(nil), // 32: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 33: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 34: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 25, // 0: blobber.service.v1.CollaboratorResponse.Collaborators:type_name -> blobber.service.v1.Collaborator @@ -3154,23 +3183,23 @@ var file_blobber_proto_depIdxs = []int32{ 16, // 3: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 12, // 4: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 16, // 5: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 30, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 32, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 12, // 7: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 15, // 8: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 16, // 9: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 30, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 30, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 30, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 30, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 30, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 30, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 32, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 32, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 32, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 32, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 32, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 32, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 21, // 16: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 30, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 32, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 25, // 18: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 28, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 29, // 20: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 31, // 21: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 32, // 22: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 30, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 31, // 20: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 33, // 21: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 34, // 22: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 24, // 23: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 26, // 24: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 22, // 25: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -3182,20 +3211,22 @@ var file_blobber_proto_depIdxs = []int32{ 4, // 31: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest 2, // 32: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest 6, // 33: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest - 0, // 34: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest - 27, // 35: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 23, // 36: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 20, // 37: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 18, // 38: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 14, // 39: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 11, // 40: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 9, // 41: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 5, // 42: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 3, // 43: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 7, // 44: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 1, // 45: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse - 35, // [35:46] is the sub-list for method output_type - 24, // [24:35] is the sub-list for method input_type + 28, // 34: blobber.service.v1.Blobber.UpdateObjectAttributes:input_type -> blobber.service.v1.UpdateObjectAttributesRequest + 0, // 35: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest + 27, // 36: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 23, // 37: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 20, // 38: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 18, // 39: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 14, // 40: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 11, // 41: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 9, // 42: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 5, // 43: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 3, // 44: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 7, // 45: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 29, // 46: blobber.service.v1.Blobber.UpdateObjectAttributes:output_type -> blobber.service.v1.UpdateObjectAttributesResponse + 1, // 47: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse + 36, // [36:48] is the sub-list for method output_type + 24, // [24:36] is the sub-list for method input_type 24, // [24:24] is the sub-list for extension type_name 24, // [24:24] is the sub-list for extension extendee 0, // [0:24] is the sub-list for field type_name @@ -3544,7 +3575,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*UpdateObjectAttributesRequest); i { case 0: return &v.state case 1: @@ -3556,7 +3587,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*UpdateObjectAttributesResponse); i { case 0: return &v.state case 1: @@ -3567,8 +3598,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UpdateObjectAttributesRequest); i { + file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -3579,8 +3610,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UpdateObjectAttributesResponse); i { + file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -3591,7 +3622,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileRef); i { case 0: return &v.state @@ -3603,7 +3634,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[33].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileMetaData); i { case 0: return &v.state @@ -3615,7 +3646,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[34].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -3634,7 +3665,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 33, + NumMessages: 35, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 25c8d0db2..98eb37217 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -1063,18 +1063,18 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) - mux.Handle("POST", pattern_Blobber_Collaborator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_UpdateObjectAttributes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/Collaborator") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/UpdateObjectAttributes") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_Collaborator_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_UpdateObjectAttributes_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -1082,22 +1082,22 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_Collaborator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_UpdateObjectAttributes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_UpdateObjectAttributes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_Collaborator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/UpdateObjectAttributes") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/Collaborator") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_UpdateObjectAttributes_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_Collaborator_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -1105,7 +1105,7 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_UpdateObjectAttributes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_Collaborator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) @@ -1350,43 +1350,43 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) - mux.Handle("POST", pattern_Blobber_Collaborator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_UpdateObjectAttributes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/Collaborator") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/UpdateObjectAttributes") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_Collaborator_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_UpdateObjectAttributes_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_Collaborator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_UpdateObjectAttributes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_UpdateObjectAttributes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_Collaborator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/UpdateObjectAttributes") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/Collaborator") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_UpdateObjectAttributes_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_Collaborator_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_UpdateObjectAttributes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_Collaborator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) @@ -1414,9 +1414,9 @@ var ( pattern_Blobber_CommitMetaTxn_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "commitmetatxn", "allocation"}, "")) - pattern_Blobber_Collaborator_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "collaborator", "allocation"}, "")) - pattern_Blobber_UpdateObjectAttributes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "attributes", "allocation"}, "")) + + pattern_Blobber_Collaborator_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "collaborator", "allocation"}, "")) ) var ( @@ -1440,7 +1440,7 @@ var ( forward_Blobber_CommitMetaTxn_0 = runtime.ForwardResponseMessage - forward_Blobber_Collaborator_0 = runtime.ForwardResponseMessage - forward_Blobber_UpdateObjectAttributes_0 = runtime.ForwardResponseMessage + + forward_Blobber_Collaborator_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 82cfdf23c..9d4e7a0d8 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -129,18 +129,18 @@ func (c *blobberClient) CommitMetaTxn(ctx context.Context, in *CommitMetaTxnRequ return out, nil } -func (c *blobberClient) Collaborator(ctx context.Context, in *CollaboratorRequest, opts ...grpc.CallOption) (*CollaboratorResponse, error) { - out := new(CollaboratorResponse) - err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/Collaborator", in, out, opts...) +func (c *blobberClient) UpdateObjectAttributes(ctx context.Context, in *UpdateObjectAttributesRequest, opts ...grpc.CallOption) (*UpdateObjectAttributesResponse, error) { + out := new(UpdateObjectAttributesResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/UpdateObjectAttributes", in, out, opts...) if err != nil { return nil, err } return out, nil } -func (c *blobberClient) UpdateObjectAttributes(ctx context.Context, in *UpdateObjectAttributesRequest, opts ...grpc.CallOption) (*UpdateObjectAttributesResponse, error) { - out := new(UpdateObjectAttributesResponse) - err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/UpdateObjectAttributes", in, out, opts...) +func (c *blobberClient) Collaborator(ctx context.Context, in *CollaboratorRequest, opts ...grpc.CallOption) (*CollaboratorResponse, error) { + out := new(CollaboratorResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/Collaborator", in, out, opts...) if err != nil { return nil, err } @@ -161,8 +161,8 @@ type BlobberServer interface { Commit(context.Context, *CommitRequest) (*CommitResponse, error) CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) - Collaborator(context.Context, *CollaboratorRequest) (*CollaboratorResponse, error) UpdateObjectAttributes(context.Context, *UpdateObjectAttributesRequest) (*UpdateObjectAttributesResponse, error) + Collaborator(context.Context, *CollaboratorRequest) (*CollaboratorResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -200,12 +200,12 @@ func (UnimplementedBlobberServer) CalculateHash(context.Context, *CalculateHashR func (UnimplementedBlobberServer) CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CommitMetaTxn not implemented") } -func (UnimplementedBlobberServer) Collaborator(context.Context, *CollaboratorRequest) (*CollaboratorResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Collaborator not implemented") -} func (UnimplementedBlobberServer) UpdateObjectAttributes(context.Context, *UpdateObjectAttributesRequest) (*UpdateObjectAttributesResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method UpdateObjectAttributes not implemented") } +func (UnimplementedBlobberServer) Collaborator(context.Context, *CollaboratorRequest) (*CollaboratorResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Collaborator not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -399,38 +399,38 @@ func _Blobber_CommitMetaTxn_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } -func _Blobber_Collaborator_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(CollaboratorRequest) +func _Blobber_UpdateObjectAttributes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(UpdateObjectAttributesRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { - return srv.(BlobberServer).Collaborator(ctx, in) + return srv.(BlobberServer).UpdateObjectAttributes(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/blobber.service.v1.Blobber/Collaborator", + FullMethod: "/blobber.service.v1.Blobber/UpdateObjectAttributes", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(BlobberServer).Collaborator(ctx, req.(*CollaboratorRequest)) + return srv.(BlobberServer).UpdateObjectAttributes(ctx, req.(*UpdateObjectAttributesRequest)) } return interceptor(ctx, in, info, handler) } -func _Blobber_UpdateObjectAttributes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(UpdateObjectAttributesRequest) +func _Blobber_Collaborator_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CollaboratorRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { - return srv.(BlobberServer).UpdateObjectAttributes(ctx, in) + return srv.(BlobberServer).Collaborator(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/blobber.service.v1.Blobber/UpdateObjectAttributes", + FullMethod: "/blobber.service.v1.Blobber/Collaborator", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(BlobberServer).UpdateObjectAttributes(ctx, req.(*UpdateObjectAttributesRequest)) + return srv.(BlobberServer).Collaborator(ctx, req.(*CollaboratorRequest)) } return interceptor(ctx, in, info, handler) } @@ -479,14 +479,14 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "CommitMetaTxn", Handler: _Blobber_CommitMetaTxn_Handler, }, - { - MethodName: "Collaborator", - Handler: _Blobber_Collaborator_Handler, - }, { MethodName: "UpdateObjectAttributes", Handler: _Blobber_UpdateObjectAttributes_Handler, }, + { + MethodName: "Collaborator", + Handler: _Blobber_Collaborator_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 005dd26bd..350ed519f 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -344,13 +344,13 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } -// SaveAllocationChanges provides a mock function with given fields: ctx, alloc -func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { - ret := _m.Called(ctx, alloc) +// RemoveCollaborator provides a mock function with given fields: ctx, refID, clientID +func (_m *PackageHandler) RemoveCollaborator(ctx context.Context, refID int64, clientID string) error { + ret := _m.Called(ctx, refID, clientID) var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { - r0 = rf(ctx, alloc) + if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { + r0 = rf(ctx, refID, clientID) } else { r0 = ret.Error(0) } @@ -358,13 +358,13 @@ func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allo return r0 } -// RemoveCollaborator provides a mock function with given fields: ctx, refID, clientID -func (_m *PackageHandler) RemoveCollaborator(ctx context.Context, refID int64, clientID string) error { - ret := _m.Called(ctx, refID, clientID) +// SaveAllocationChanges provides a mock function with given fields: ctx, alloc +func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + ret := _m.Called(ctx, alloc) var r0 error - if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { - r0 = rf(ctx, refID, clientID) + if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(ctx, alloc) } else { r0 = ret.Error(0) } From bc47664e807000c33c3cfd7c9c172f00f6cf204c Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sat, 5 Jun 2021 23:02:28 +0530 Subject: [PATCH 110/183] 153 conflicts resolved with grpc ii --- .../blobbercore/blobbergrpc/blobber.pb.go | 621 ++++++++++-------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 64 +- .../blobbergrpc/blobber_grpc.pb.go | 48 +- 3 files changed, 396 insertions(+), 337 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 9af5e39a3..2fafae0e9 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1840,7 +1840,7 @@ type CopyObjectRequest struct { func (x *CopyObjectRequest) Reset() { *x = CopyObjectRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1853,7 +1853,7 @@ func (x *CopyObjectRequest) String() string { func (*CopyObjectRequest) ProtoMessage() {} func (x *CopyObjectRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1866,7 +1866,7 @@ func (x *CopyObjectRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CopyObjectRequest.ProtoReflect.Descriptor instead. func (*CopyObjectRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{28} } func (x *CopyObjectRequest) GetAllocation() string { @@ -1922,7 +1922,7 @@ type CopyObjectResponse struct { func (x *CopyObjectResponse) Reset() { *x = CopyObjectResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1935,7 +1935,7 @@ func (x *CopyObjectResponse) String() string { func (*CopyObjectResponse) ProtoMessage() {} func (x *CopyObjectResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1948,7 +1948,7 @@ func (x *CopyObjectResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CopyObjectResponse.ProtoReflect.Descriptor instead. func (*CopyObjectResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{27} + return file_blobber_proto_rawDescGZIP(), []int{29} } func (x *CopyObjectResponse) GetFilename() string { @@ -2020,7 +2020,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2033,7 +2033,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2046,7 +2046,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{28} + return file_blobber_proto_rawDescGZIP(), []int{30} } func (x *Allocation) GetID() string { @@ -2183,7 +2183,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2196,7 +2196,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2209,7 +2209,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{29} + return file_blobber_proto_rawDescGZIP(), []int{31} } func (x *Term) GetID() int64 { @@ -2260,7 +2260,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2273,7 +2273,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2286,7 +2286,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{30} + return file_blobber_proto_rawDescGZIP(), []int{32} } func (x *FileRef) GetType() string { @@ -2344,7 +2344,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[31] + mi := &file_blobber_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2357,7 +2357,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[31] + mi := &file_blobber_proto_msgTypes[33] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2370,7 +2370,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{31} + return file_blobber_proto_rawDescGZIP(), []int{33} } func (x *FileMetaData) GetType() string { @@ -2561,7 +2561,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[32] + mi := &file_blobber_proto_msgTypes[34] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2574,7 +2574,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[32] + mi := &file_blobber_proto_msgTypes[34] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2587,7 +2587,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{32} + return file_blobber_proto_rawDescGZIP(), []int{34} } func (x *DirMetaData) GetType() string { @@ -2912,233 +2912,264 @@ var file_blobber_proto_rawDesc = []byte{ 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb6, 0x04, - 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, - 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, - 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, - 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, - 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, - 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, - 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, - 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, - 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, - 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, - 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, - 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, - 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, - 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, - 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, - 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, - 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, - 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, - 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, - 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, - 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, - 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, - 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, - 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, - 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, - 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, + 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, + 0x0a, 0x11, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, + 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, + 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, + 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x65, 0x73, + 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x64, 0x65, 0x73, 0x74, 0x22, 0xd2, 0x01, + 0x0a, 0x12, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, + 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, + 0x73, 0x69, 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, + 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, + 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, + 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, + 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, + 0x61, 0x64, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, + 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, + 0x65, 0x74, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, + 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, + 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, + 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, + 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, + 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, + 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, + 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, + 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, + 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, + 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, + 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, + 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, + 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, + 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, + 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, + 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, + 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, + 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, + 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, + 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, + 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, + 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, + 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, + 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, + 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, + 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, + 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, - 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, - 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, - 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, - 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, - 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, - 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, - 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, - 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, - 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, - 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, - 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, - 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, - 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, - 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, - 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, - 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, - 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, - 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, - 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, - 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, - 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, - 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, - 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, - 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, - 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, - 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, - 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, - 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, - 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, - 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, - 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, - 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x32, 0xa9, 0x0c, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, - 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, - 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, + 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, + 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, + 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, + 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, + 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, + 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, + 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, + 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, + 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, + 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, + 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, + 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, + 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, + 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, + 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, + 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, + 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, + 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, + 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, + 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, + 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, + 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, + 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, + 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, + 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, + 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xae, 0x0d, 0x0a, 0x07, 0x42, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, - 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, - 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, - 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, - 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, - 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, - 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, - 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, - 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, - 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, - 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, - 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, - 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, - 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, - 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, - 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, - 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, - 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, - 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, - 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, + 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, + 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, - 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, - 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, - 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, - 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, + 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, + 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, + 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, + 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, + 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, + 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, + 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, + 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, + 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, + 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, + 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, + 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, + 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, + 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, + 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, + 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -3153,7 +3184,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 33) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 35) var file_blobber_proto_goTypes = []interface{}{ (*CollaboratorRequest)(nil), // 0: blobber.service.v1.CollaboratorRequest (*CollaboratorResponse)(nil), // 1: blobber.service.v1.CollaboratorResponse @@ -3183,11 +3214,13 @@ var file_blobber_proto_goTypes = []interface{}{ (*Collaborator)(nil), // 25: blobber.service.v1.Collaborator (*GetAllocationRequest)(nil), // 26: blobber.service.v1.GetAllocationRequest (*GetAllocationResponse)(nil), // 27: blobber.service.v1.GetAllocationResponse - (*Allocation)(nil), // 28: blobber.service.v1.Allocation - (*Term)(nil), // 29: blobber.service.v1.Term - (*FileRef)(nil), // 30: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 31: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 32: blobber.service.v1.DirMetaData + (*CopyObjectRequest)(nil), // 28: blobber.service.v1.CopyObjectRequest + (*CopyObjectResponse)(nil), // 29: blobber.service.v1.CopyObjectResponse + (*Allocation)(nil), // 30: blobber.service.v1.Allocation + (*Term)(nil), // 31: blobber.service.v1.Term + (*FileRef)(nil), // 32: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 33: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 34: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 25, // 0: blobber.service.v1.CollaboratorResponse.Collaborators:type_name -> blobber.service.v1.Collaborator @@ -3196,23 +3229,23 @@ var file_blobber_proto_depIdxs = []int32{ 16, // 3: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 12, // 4: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 16, // 5: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 30, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 32, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 12, // 7: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 15, // 8: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 16, // 9: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 30, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 30, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 30, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 30, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 30, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 30, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 32, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 32, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 32, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 32, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 32, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 32, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 21, // 16: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 30, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 32, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 25, // 18: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 28, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 29, // 20: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 31, // 21: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 32, // 22: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 30, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 31, // 20: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 33, // 21: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 34, // 22: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 24, // 23: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 26, // 24: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 22, // 25: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -3224,20 +3257,22 @@ var file_blobber_proto_depIdxs = []int32{ 4, // 31: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest 2, // 32: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest 6, // 33: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest - 0, // 34: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest - 27, // 35: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 23, // 36: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 20, // 37: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 18, // 38: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 14, // 39: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 11, // 40: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 9, // 41: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 5, // 42: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 3, // 43: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 7, // 44: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 1, // 45: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse - 35, // [35:46] is the sub-list for method output_type - 24, // [24:35] is the sub-list for method input_type + 28, // 34: blobber.service.v1.Blobber.CopyObject:input_type -> blobber.service.v1.CopyObjectRequest + 0, // 35: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest + 27, // 36: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 23, // 37: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 20, // 38: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 18, // 39: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 14, // 40: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 11, // 41: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 9, // 42: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 5, // 43: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 3, // 44: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 7, // 45: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 29, // 46: blobber.service.v1.Blobber.CopyObject:output_type -> blobber.service.v1.CopyObjectResponse + 1, // 47: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse + 36, // [36:48] is the sub-list for method output_type + 24, // [24:36] is the sub-list for method input_type 24, // [24:24] is the sub-list for extension type_name 24, // [24:24] is the sub-list for extension extendee 0, // [0:24] is the sub-list for field type_name @@ -3586,7 +3621,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*CopyObjectRequest); i { case 0: return &v.state case 1: @@ -3598,7 +3633,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*CopyObjectResponse); i { case 0: return &v.state case 1: @@ -3610,7 +3645,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -3622,7 +3657,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -3634,6 +3669,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[33].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[34].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -3652,7 +3711,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 33, + NumMessages: 35, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 87cdb7872..4cb704ebd 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -691,8 +691,8 @@ func local_request_Blobber_CommitMetaTxn_0(ctx context.Context, marshaler runtim } -func request_Blobber_Collaborator_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CollaboratorRequest +func request_Blobber_CopyObject_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CopyObjectRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -720,13 +720,13 @@ func request_Blobber_Collaborator_0(ctx context.Context, marshaler runtime.Marsh return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.Collaborator(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.CopyObject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_Collaborator_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CollaboratorRequest +func local_request_Blobber_CopyObject_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CopyObjectRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -754,13 +754,13 @@ func local_request_Blobber_Collaborator_0(ctx context.Context, marshaler runtime return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.Collaborator(ctx, &protoReq) + msg, err := server.CopyObject(ctx, &protoReq) return msg, metadata, err } -func request_Blobber_CopyObject_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CopyObjectRequest +func request_Blobber_Collaborator_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CollaboratorRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -788,13 +788,13 @@ func request_Blobber_CopyObject_0(ctx context.Context, marshaler runtime.Marshal return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.CopyObject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.Collaborator(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_CopyObject_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CopyObjectRequest +func local_request_Blobber_Collaborator_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CollaboratorRequest var metadata runtime.ServerMetadata newReader, berr := utilities.IOReaderFactory(req.Body) @@ -822,7 +822,7 @@ func local_request_Blobber_CopyObject_0(ctx context.Context, marshaler runtime.M return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.CopyObject(ctx, &protoReq) + msg, err := server.Collaborator(ctx, &protoReq) return msg, metadata, err } @@ -1063,18 +1063,18 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) - mux.Handle("POST", pattern_Blobber_Collaborator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_CopyObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/Collaborator") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CopyObject") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_Collaborator_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_CopyObject_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -1082,22 +1082,22 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_Collaborator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_CopyObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_CopyObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_Collaborator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/CopyObject") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/Collaborator") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_CopyObject_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_Collaborator_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -1105,7 +1105,7 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_CopyObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_Collaborator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) @@ -1350,43 +1350,43 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) - mux.Handle("POST", pattern_Blobber_Collaborator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_CopyObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/Collaborator") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CopyObject") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_Collaborator_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_CopyObject_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_Collaborator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_CopyObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("POST", pattern_Blobber_CopyObject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_Collaborator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/CopyObject") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/Collaborator") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_CopyObject_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_Collaborator_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_CopyObject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_Collaborator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) @@ -1414,9 +1414,9 @@ var ( pattern_Blobber_CommitMetaTxn_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "commitmetatxn", "allocation"}, "")) - pattern_Blobber_Collaborator_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "collaborator", "allocation"}, "")) - pattern_Blobber_CopyObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "copy", "allocation"}, "")) + + pattern_Blobber_Collaborator_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "collaborator", "allocation"}, "")) ) var ( @@ -1440,7 +1440,7 @@ var ( forward_Blobber_CommitMetaTxn_0 = runtime.ForwardResponseMessage - forward_Blobber_Collaborator_0 = runtime.ForwardResponseMessage - forward_Blobber_CopyObject_0 = runtime.ForwardResponseMessage + + forward_Blobber_Collaborator_0 = runtime.ForwardResponseMessage ) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index a6077e917..20e1c7ac8 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -129,18 +129,18 @@ func (c *blobberClient) CommitMetaTxn(ctx context.Context, in *CommitMetaTxnRequ return out, nil } -func (c *blobberClient) Collaborator(ctx context.Context, in *CollaboratorRequest, opts ...grpc.CallOption) (*CollaboratorResponse, error) { - out := new(CollaboratorResponse) - err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/Collaborator", in, out, opts...) +func (c *blobberClient) CopyObject(ctx context.Context, in *CopyObjectRequest, opts ...grpc.CallOption) (*CopyObjectResponse, error) { + out := new(CopyObjectResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/CopyObject", in, out, opts...) if err != nil { return nil, err } return out, nil } -func (c *blobberClient) CopyObject(ctx context.Context, in *CopyObjectRequest, opts ...grpc.CallOption) (*CopyObjectResponse, error) { - out := new(CopyObjectResponse) - err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/CopyObject", in, out, opts...) +func (c *blobberClient) Collaborator(ctx context.Context, in *CollaboratorRequest, opts ...grpc.CallOption) (*CollaboratorResponse, error) { + out := new(CollaboratorResponse) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/Collaborator", in, out, opts...) if err != nil { return nil, err } @@ -161,8 +161,8 @@ type BlobberServer interface { Commit(context.Context, *CommitRequest) (*CommitResponse, error) CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) - Collaborator(context.Context, *CollaboratorRequest) (*CollaboratorResponse, error) CopyObject(context.Context, *CopyObjectRequest) (*CopyObjectResponse, error) + Collaborator(context.Context, *CollaboratorRequest) (*CollaboratorResponse, error) mustEmbedUnimplementedBlobberServer() } @@ -200,12 +200,12 @@ func (UnimplementedBlobberServer) CalculateHash(context.Context, *CalculateHashR func (UnimplementedBlobberServer) CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CommitMetaTxn not implemented") } -func (UnimplementedBlobberServer) Collaborator(context.Context, *CollaboratorRequest) (*CollaboratorResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Collaborator not implemented") -} func (UnimplementedBlobberServer) CopyObject(context.Context, *CopyObjectRequest) (*CopyObjectResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CopyObject not implemented") } +func (UnimplementedBlobberServer) Collaborator(context.Context, *CollaboratorRequest) (*CollaboratorResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Collaborator not implemented") +} func (UnimplementedBlobberServer) mustEmbedUnimplementedBlobberServer() {} // UnsafeBlobberServer may be embedded to opt out of forward compatibility for this service. @@ -399,38 +399,38 @@ func _Blobber_CommitMetaTxn_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } -func _Blobber_Collaborator_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(CollaboratorRequest) +func _Blobber_CopyObject_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CopyObjectRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { - return srv.(BlobberServer).Collaborator(ctx, in) + return srv.(BlobberServer).CopyObject(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/blobber.service.v1.Blobber/Collaborator", + FullMethod: "/blobber.service.v1.Blobber/CopyObject", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(BlobberServer).Collaborator(ctx, req.(*CollaboratorRequest)) + return srv.(BlobberServer).CopyObject(ctx, req.(*CopyObjectRequest)) } return interceptor(ctx, in, info, handler) } -func _Blobber_CopyObject_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(CopyObjectRequest) +func _Blobber_Collaborator_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CollaboratorRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { - return srv.(BlobberServer).CopyObject(ctx, in) + return srv.(BlobberServer).Collaborator(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/blobber.service.v1.Blobber/CopyObject", + FullMethod: "/blobber.service.v1.Blobber/Collaborator", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(BlobberServer).CopyObject(ctx, req.(*CopyObjectRequest)) + return srv.(BlobberServer).Collaborator(ctx, req.(*CollaboratorRequest)) } return interceptor(ctx, in, info, handler) } @@ -479,14 +479,14 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ MethodName: "CommitMetaTxn", Handler: _Blobber_CommitMetaTxn_Handler, }, - { - MethodName: "Collaborator", - Handler: _Blobber_Collaborator_Handler, - }, { MethodName: "CopyObject", Handler: _Blobber_CopyObject_Handler, }, + { + MethodName: "Collaborator", + Handler: _Blobber_Collaborator_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "blobber.proto", From 8fddd8591459b10e65adc41cd955f94e66b8581a Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sat, 5 Jun 2021 23:02:33 +0530 Subject: [PATCH 111/183] 153 conflicts resolved with grpc ii --- .../blobbercore/mocks/PackageHandler.go | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go index 221b3a120..86ac709c9 100644 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go @@ -344,13 +344,13 @@ func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clie return r0 } -// SaveAllocationChanges provides a mock function with given fields: ctx, alloc -func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { - ret := _m.Called(ctx, alloc) +// RemoveCollaborator provides a mock function with given fields: ctx, refID, clientID +func (_m *PackageHandler) RemoveCollaborator(ctx context.Context, refID int64, clientID string) error { + ret := _m.Called(ctx, refID, clientID) var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { - r0 = rf(ctx, alloc) + if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { + r0 = rf(ctx, refID, clientID) } else { r0 = ret.Error(0) } @@ -358,13 +358,13 @@ func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allo return r0 } -// RemoveCollaborator provides a mock function with given fields: ctx, refID, clientID -func (_m *PackageHandler) RemoveCollaborator(ctx context.Context, refID int64, clientID string) error { - ret := _m.Called(ctx, refID, clientID) +// SaveAllocationChanges provides a mock function with given fields: ctx, alloc +func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { + ret := _m.Called(ctx, alloc) var r0 error - if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { - r0 = rf(ctx, refID, clientID) + if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { + r0 = rf(ctx, alloc) } else { r0 = ret.Error(0) } From a41eabd42a934d3464c6008e50aaacaf66e720db Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 7 Jun 2021 21:24:21 +0530 Subject: [PATCH 112/183] 153 conflicts resolved with grpc iii --- .../blobbercore/blobbergrpc/blobber.pb.go | 662 ++++++++++-------- 1 file changed, 353 insertions(+), 309 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 74e322d3d..698e06aee 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1966,7 +1966,7 @@ type CopyObjectRequest struct { func (x *CopyObjectRequest) Reset() { *x = CopyObjectRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1979,7 +1979,7 @@ func (x *CopyObjectRequest) String() string { func (*CopyObjectRequest) ProtoMessage() {} func (x *CopyObjectRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1992,7 +1992,7 @@ func (x *CopyObjectRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CopyObjectRequest.ProtoReflect.Descriptor instead. func (*CopyObjectRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{28} + return file_blobber_proto_rawDescGZIP(), []int{30} } func (x *CopyObjectRequest) GetAllocation() string { @@ -2048,7 +2048,7 @@ type CopyObjectResponse struct { func (x *CopyObjectResponse) Reset() { *x = CopyObjectResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2061,7 +2061,7 @@ func (x *CopyObjectResponse) String() string { func (*CopyObjectResponse) ProtoMessage() {} func (x *CopyObjectResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[31] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2074,7 +2074,7 @@ func (x *CopyObjectResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CopyObjectResponse.ProtoReflect.Descriptor instead. func (*CopyObjectResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{29} + return file_blobber_proto_rawDescGZIP(), []int{31} } func (x *CopyObjectResponse) GetFilename() string { @@ -2146,7 +2146,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2159,7 +2159,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[32] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2172,7 +2172,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{30} + return file_blobber_proto_rawDescGZIP(), []int{32} } func (x *Allocation) GetID() string { @@ -2309,7 +2309,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[31] + mi := &file_blobber_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2322,7 +2322,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[31] + mi := &file_blobber_proto_msgTypes[33] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2335,7 +2335,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{31} + return file_blobber_proto_rawDescGZIP(), []int{33} } func (x *Term) GetID() int64 { @@ -2386,7 +2386,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[32] + mi := &file_blobber_proto_msgTypes[34] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2399,7 +2399,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[32] + mi := &file_blobber_proto_msgTypes[34] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2412,7 +2412,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{32} + return file_blobber_proto_rawDescGZIP(), []int{34} } func (x *FileRef) GetType() string { @@ -2470,7 +2470,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[33] + mi := &file_blobber_proto_msgTypes[35] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2483,7 +2483,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[33] + mi := &file_blobber_proto_msgTypes[35] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2496,7 +2496,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{33} + return file_blobber_proto_rawDescGZIP(), []int{35} } func (x *FileMetaData) GetType() string { @@ -2687,7 +2687,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[34] + mi := &file_blobber_proto_msgTypes[36] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2700,7 +2700,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[34] + mi := &file_blobber_proto_msgTypes[36] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2713,7 +2713,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{34} + return file_blobber_proto_rawDescGZIP(), []int{36} } func (x *DirMetaData) GetType() string { @@ -3055,243 +3055,275 @@ var file_blobber_proto_rawDesc = []byte{ 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2b, 0x0a, 0x12, 0x77, 0x68, 0x6f, 0x5f, 0x70, 0x61, 0x79, 0x73, 0x5f, 0x66, 0x6f, 0x72, 0x5f, 0x72, 0x65, 0x61, 0x64, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x77, 0x68, 0x6f, 0x50, 0x61, 0x79, 0x73, 0x46, 0x6f, 0x72, 0x52, - 0x65, 0x61, 0x64, 0x73, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, - 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, - 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, - 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, - 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, - 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, - 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, - 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, - 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, - 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, - 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, - 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, - 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, - 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, - 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, - 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, - 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, - 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, - 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, - 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, - 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, - 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, - 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, - 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, - 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, - 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, - 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, - 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, - 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, - 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, - 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, - 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, - 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, - 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, - 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, - 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, - 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, - 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, - 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, - 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, - 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, + 0x65, 0x61, 0x64, 0x73, 0x22, 0x9d, 0x01, 0x0a, 0x11, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, + 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, + 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, + 0x12, 0x12, 0x0a, 0x04, 0x64, 0x65, 0x73, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x64, 0x65, 0x73, 0x74, 0x22, 0xd2, 0x01, 0x0a, 0x12, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, + 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, + 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x63, + 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, + 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, + 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, + 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, + 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, + 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, + 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, + 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, + 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, + 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, + 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, + 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, + 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, + 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, + 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, + 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, + 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, + 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, + 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, + 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, + 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, + 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, + 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, + 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, + 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, + 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, + 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, + 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, + 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, + 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, + 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, + 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, + 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, + 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, + 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, + 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, + 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, + 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, + 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, + 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, + 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, + 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, + 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, + 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, + 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, + 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, - 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, - 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, - 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, - 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, - 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, - 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, - 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, - 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, - 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, - 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, - 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, - 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, - 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, - 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xd8, 0x0d, 0x0a, 0x07, - 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, - 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, - 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, - 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, - 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, - 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, - 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, - 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, - 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, - 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, + 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, + 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, + 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, + 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, + 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, + 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, + 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, + 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, + 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, + 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, + 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, + 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, + 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, + 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, + 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, + 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, + 0x32, 0xdd, 0x0e, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, + 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, - 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, - 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, - 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, - 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, - 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, - 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, - 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, - 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, - 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, - 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, - 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, - 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x22, 0x20, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, - 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, - 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, - 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, + 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, + 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, + 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, + 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, + 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, + 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, + 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, + 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, + 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, + 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, + 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, + 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, + 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, + 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, - 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, - 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, - 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, + 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, + 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, + 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, + 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, + 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, + 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, + 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, + 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, + 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, + 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, + 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, + 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, + 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -3306,7 +3338,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 35) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 37) var file_blobber_proto_goTypes = []interface{}{ (*CollaboratorRequest)(nil), // 0: blobber.service.v1.CollaboratorRequest (*CollaboratorResponse)(nil), // 1: blobber.service.v1.CollaboratorResponse @@ -3338,11 +3370,13 @@ var file_blobber_proto_goTypes = []interface{}{ (*GetAllocationResponse)(nil), // 27: blobber.service.v1.GetAllocationResponse (*UpdateObjectAttributesRequest)(nil), // 28: blobber.service.v1.UpdateObjectAttributesRequest (*UpdateObjectAttributesResponse)(nil), // 29: blobber.service.v1.UpdateObjectAttributesResponse - (*Allocation)(nil), // 30: blobber.service.v1.Allocation - (*Term)(nil), // 31: blobber.service.v1.Term - (*FileRef)(nil), // 32: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 33: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 34: blobber.service.v1.DirMetaData + (*CopyObjectRequest)(nil), // 30: blobber.service.v1.CopyObjectRequest + (*CopyObjectResponse)(nil), // 31: blobber.service.v1.CopyObjectResponse + (*Allocation)(nil), // 32: blobber.service.v1.Allocation + (*Term)(nil), // 33: blobber.service.v1.Term + (*FileRef)(nil), // 34: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 35: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 36: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 25, // 0: blobber.service.v1.CollaboratorResponse.Collaborators:type_name -> blobber.service.v1.Collaborator @@ -3351,23 +3385,23 @@ var file_blobber_proto_depIdxs = []int32{ 16, // 3: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 12, // 4: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 16, // 5: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 32, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 34, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 12, // 7: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 15, // 8: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 16, // 9: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 32, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 32, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 32, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 32, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 32, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 32, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 34, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 34, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 34, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 34, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 34, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 34, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 21, // 16: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 32, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 34, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 25, // 18: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 30, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 31, // 20: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 33, // 21: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 34, // 22: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 32, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 33, // 20: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 35, // 21: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 36, // 22: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 24, // 23: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 26, // 24: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 22, // 25: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -3380,37 +3414,23 @@ var file_blobber_proto_depIdxs = []int32{ 2, // 32: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest 6, // 33: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest 28, // 34: blobber.service.v1.Blobber.UpdateObjectAttributes:input_type -> blobber.service.v1.UpdateObjectAttributesRequest - 0, // 35: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest - 27, // 36: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 23, // 37: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 20, // 38: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 18, // 39: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 14, // 40: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 11, // 41: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 9, // 42: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 5, // 43: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 3, // 44: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 7, // 45: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 29, // 46: blobber.service.v1.Blobber.UpdateObjectAttributes:output_type -> blobber.service.v1.UpdateObjectAttributesResponse - 1, // 47: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse - 36, // [36:48] is the sub-list for method output_type - 24, // [24:36] is the sub-list for method input_type - 28, // 34: blobber.service.v1.Blobber.CopyObject:input_type -> blobber.service.v1.CopyObjectRequest - 0, // 35: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest - 27, // 36: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 23, // 37: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 20, // 38: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 18, // 39: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 14, // 40: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 11, // 41: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 9, // 42: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 5, // 43: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 3, // 44: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 7, // 45: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 29, // 46: blobber.service.v1.Blobber.CopyObject:output_type -> blobber.service.v1.CopyObjectResponse - 1, // 47: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse - 36, // [36:48] is the sub-list for method output_type - 24, // [24:36] is the sub-list for method input_type + 30, // 35: blobber.service.v1.Blobber.CopyObject:input_type -> blobber.service.v1.CopyObjectRequest + 0, // 36: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest + 27, // 37: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 23, // 38: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 20, // 39: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 18, // 40: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 14, // 41: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 11, // 42: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 9, // 43: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 5, // 44: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 3, // 45: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 7, // 46: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 29, // 47: blobber.service.v1.Blobber.UpdateObjectAttributes:output_type -> blobber.service.v1.UpdateObjectAttributesResponse + 31, // 48: blobber.service.v1.Blobber.CopyObject:output_type -> blobber.service.v1.CopyObjectResponse + 1, // 49: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse + 37, // [37:50] is the sub-list for method output_type + 24, // [24:37] is the sub-list for method input_type 24, // [24:24] is the sub-list for extension type_name 24, // [24:24] is the sub-list for extension extendee 0, // [0:24] is the sub-list for field type_name @@ -3759,7 +3779,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*UpdateObjectAttributesRequest); i { case 0: return &v.state case 1: @@ -3783,7 +3803,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*CopyObjectRequest); i { case 0: return &v.state case 1: @@ -3795,7 +3815,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*CopyObjectResponse); i { case 0: return &v.state case 1: @@ -3807,7 +3827,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -3819,7 +3839,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[33].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -3831,6 +3851,30 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[34].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileRef); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[35].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FileMetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_blobber_proto_msgTypes[36].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -3849,7 +3893,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 35, + NumMessages: 37, NumExtensions: 0, NumServices: 1, }, From 71f6458ab52c297ae9817f519fb70579e6ef5ea7 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 14:52:05 +0530 Subject: [PATCH 113/183] :sparkles: pointed getallocation grpc to http --- .../blobbercore/convert/responseHandler.go | 7 +- .../handler/grpc_commit_handler.go | 2 +- .../blobbercore/handler/grpc_handler.go | 11 +- .../handler/grpc_handler_integration_test.go | 1467 ++++++++--------- .../handler/grpc_handler_unit_test.go | 35 - .../0chain.net/blobbercore/handler/handler.go | 311 ++-- .../blobbercore/handler/handler_test.go | 15 +- .../blobbercore/handler/metadata.go | 15 +- 8 files changed, 868 insertions(+), 995 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 760f31cb7..d8b0cdc9a 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -3,6 +3,7 @@ package convert import ( "context" "encoding/json" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" @@ -11,8 +12,10 @@ import ( "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" ) -func GetAllocationResponseHandler(resp *blobbergrpc.GetAllocationResponse) *allocation.Allocation { - return GRPCAllocationToAllocation(resp.Allocation) +func GetAllocationResponseCreator(resp interface{}) *blobbergrpc.GetAllocationResponse { + alloc, _ := resp.(*allocation.Allocation) + + return &blobbergrpc.GetAllocationResponse{Allocation: AllocationToGRPCAllocation(alloc)} } func GetFileMetaDataResponseHandler(resp *blobbergrpc.GetFileMetaDataResponse) map[string]interface{} { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go index c31257737..03dfa4058 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go @@ -20,7 +20,7 @@ import ( func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.CommitRequest) (*blobbergrpc.CommitResponse, error) { md := GetGRPCMetaDataFromCtx(ctx) - ctx = setupGRPCHandlerContext(ctx, md, req.Allocation) + //ctx = httpRequestWithMetaData(ctx, md, req.Allocation) allocationTx := req.Allocation clientID := md.Client diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 5820930c2..693348a60 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -29,14 +29,19 @@ func newGRPCBlobberService(sh StorageHandlerI, r PackageHandler) *blobberGRPCSer } func (b *blobberGRPCService) GetAllocation(ctx context.Context, request *blobbergrpc.GetAllocationRequest) (*blobbergrpc.GetAllocationResponse, error) { - ctx = setupGRPCHandlerContext(ctx, GetGRPCMetaDataFromCtx(ctx), "") + r, err := http.NewRequest("GET", "", nil) + if err != nil { + return nil, err + } + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), "") + r.Form = map[string][]string{"id": {request.Id}} - allocation, err := b.storageHandler.verifyAllocation(ctx, request.Id, false) + resp, err := AllocationHandler(ctx, r) if err != nil { return nil, err } - return &blobbergrpc.GetAllocationResponse{Allocation: convert.AllocationToGRPCAllocation(allocation)}, nil + return convert.GetAllocationResponseCreator(resp), nil } func (b *blobberGRPCService) GetFileMetaData(ctx context.Context, req *blobbergrpc.GetFileMetaDataRequest) (*blobbergrpc.GetFileMetaDataResponse, error) { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 7dea657d1..5c5e4f660 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -2,24 +2,15 @@ package handler import ( "context" - "encoding/hex" - "encoding/json" "fmt" "log" - "net/http" "os" - "strconv" "testing" "time" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" - "github.com/0chain/blobber/code/go/0chain.net/core/common" - "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "google.golang.org/grpc" - "google.golang.org/grpc/metadata" "gorm.io/driver/postgres" "gorm.io/gorm" ) @@ -34,7 +25,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { args[arg] = true } if !args["integration"] { - t.Skip() + //t.Skip() } var conn *grpc.ClientConn @@ -119,732 +110,732 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } }) - t.Run("TestGetFileMetaData", func(t *testing.T) { - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetFileMetaDataTestData() - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.GetFileMetaDataRequest - expectedFileName string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - }), - input: &blobbergrpc.GetFileMetaDataRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath", - Allocation: "exampleTransaction", - }, - expectedFileName: "filename", - expectingError: false, - }, - { - name: "Unknown file path", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - }), - input: &blobbergrpc.GetFileMetaDataRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath123", - Allocation: "exampleTransaction", - }, - expectedFileName: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getFileMetaDataResp, err := blobberClient.GetFileMetaData(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getFileMetaDataResp.MetaData.FileMetaData.Name != tc.expectedFileName { - t.Fatal("unexpected file name from GetFileMetaData rpc") - } - } - }) - - t.Run("TestGetFileStats", func(t *testing.T) { - - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetFileStatsTestData(allocationTx, pubKey) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.GetFileStatsRequest - expectedFileName string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetFileStatsRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath", - Allocation: allocationTx, - }, - expectedFileName: "filename", - expectingError: false, - }, - { - name: "Unknown Path", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetFileStatsRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath123", - Allocation: allocationTx, - }, - expectedFileName: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getFileStatsResp, err := blobberClient.GetFileStats(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getFileStatsResp.MetaData.FileMetaData.Name != tc.expectedFileName { - t.Fatal("unexpected file name from GetFileStats rpc") - } - } - - }) - - t.Run("TestListEntities", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddListEntitiesTestData(allocationTx, pubKey) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.ListEntitiesRequest - expectedPath string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.ListEntitiesRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath", - AuthToken: "", - Allocation: allocationTx, - }, - expectedPath: "examplePath", - expectingError: false, - }, - { - name: "bad path", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.ListEntitiesRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath123", - AuthToken: "", - Allocation: allocationTx, - }, - expectedPath: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - listEntitiesResp, err := blobberClient.ListEntities(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if listEntitiesResp.MetaData.DirMetaData.Path != tc.expectedPath { - t.Fatal("unexpected path from ListEntities rpc") - } - } - - }) - - t.Run("TestGetObjectPath", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetObjectPathTestData(allocationTx, pubKey) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.GetObjectPathRequest - expectedPath string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetObjectPathRequest{ - Allocation: allocationTx, - Path: "examplePath", - BlockNum: "0", - }, - expectedPath: "/", - expectingError: false, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getObjectPathResp, err := blobberClient.GetObjectPath(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getObjectPathResp.ObjectPath.Path.DirMetaData.Path != tc.expectedPath { - t.Fatal("unexpected root hash from GetObjectPath rpc") - } - } - }) - - t.Run("TestGetReferencePath", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetReferencePathTestData(allocationTx, pubKey) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.GetReferencePathRequest - expectedPath string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetReferencePathRequest{ - Paths: "", - Path: "/", - Allocation: allocationTx, - }, - expectedPath: "/", - expectingError: false, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getReferencePathResp, err := blobberClient.GetReferencePath(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getReferencePathResp.ReferencePath.MetaData.DirMetaData.Path != tc.expectedPath { - t.Fatal("unexpected path from GetReferencePath rpc") - } - } - }) - - t.Run("TestGetObjectTree", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetObjectTreeTestData(allocationTx, pubKey) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.GetObjectTreeRequest - expectedFileName string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetObjectTreeRequest{ - Path: "/", - Allocation: allocationTx, - }, - expectedFileName: "root", - expectingError: false, - }, - { - name: "bad path", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetObjectTreeRequest{ - Path: "/2", - Allocation: "", - }, - expectedFileName: "root", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getObjectTreeResp, err := blobberClient.GetObjectTree(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getObjectTreeResp.ReferencePath.MetaData.DirMetaData.Name != tc.expectedFileName { - t.Fatal("unexpected root name from GetObject") - } - } - - }) - - t.Run("TestCommit", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - pubKeyBytes, _ := hex.DecodeString(pubKey) - clientId := encryption.Hash(pubKeyBytes) - now := common.Timestamp(time.Now().UnixNano()) - - blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" - blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) - - fr := reference.Ref{ - AllocationID: "exampleId", - Type: "f", - Name: "new_name", - Path: "/new_name", - ContentHash: "contentHash", - MerkleRoot: "merkleRoot", - ActualFileHash: "actualFileHash", - } - - rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) - - wm := writemarker.WriteMarker{ - AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), - PreviousAllocationRoot: "/", - AllocationID: "exampleId", - Size: 1337, - BlobberID: encryption.Hash(blobberPubKeyBytes), - Timestamp: now, - ClientID: clientId, - } - - wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) - if err != nil { - t.Fatal(err) - } - - wm.Signature = wmSig - - wmRaw, err := json.Marshal(wm) - if err != nil { - t.Fatal(err) - } - - err = tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.CommitRequest - expectedAllocation string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.CommitRequest{ - Allocation: allocationTx, - ConnectionId: "connection_id", - WriteMarker: string(wmRaw), - }, - expectedAllocation: "exampleId", - expectingError: false, - }, - { - name: "invalid write_marker", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.CommitRequest{ - Allocation: allocationTx, - ConnectionId: "invalid", - WriteMarker: "invalid", - }, - expectedAllocation: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getCommiteResp, err := blobberClient.Commit(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getCommiteResp.WriteMarker.AllocationID != tc.expectedAllocation { - t.Fatal("unexpected root name from GetObject") - } - } - }) - - t.Run("TestCommitMetaTxn", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - pubKeyBytes, _ := hex.DecodeString(pubKey) - clientId := encryption.Hash(pubKeyBytes) - now := common.Timestamp(time.Now().UnixNano()) - - blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" - blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) - - fr := reference.Ref{ - AllocationID: "exampleId", - } - - rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) - - wm := writemarker.WriteMarker{ - AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), - PreviousAllocationRoot: "/", - AllocationID: "exampleId", - Size: 1337, - BlobberID: encryption.Hash(blobberPubKeyBytes), - Timestamp: now, - ClientID: clientId, - } - - wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) - if err != nil { - t.Fatal(err) - } - - wm.Signature = wmSig - - if err := tdController.ClearDatabase(); err != nil { - t.Fatal(err) - } - if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.CommitMetaTxnRequest - expectedMessage string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - }), - input: &blobbergrpc.CommitMetaTxnRequest{ - Path: "/some_file", - PathHash: "exampleId:examplePath", - AuthToken: "", - Allocation: allocationTx, - TxnId: "8", - }, - expectedMessage: "Added commitMetaTxn successfully", - expectingError: false, - }, - { - name: "Fail", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - }), - input: &blobbergrpc.CommitMetaTxnRequest{ - Path: "/some_file", - PathHash: "exampleId:examplePath", - AuthToken: "", - Allocation: allocationTx, - TxnId: "", - }, - expectedMessage: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - commitMetaTxnResponse, err := blobberClient.CommitMetaTxn(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if commitMetaTxnResponse.GetMessage() != tc.expectedMessage { - t.Fatal("failed!") - } - } - }) - - t.Run("TestCollaborator", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - pubKeyBytes, _ := hex.DecodeString(pubKey) - clientId := encryption.Hash(pubKeyBytes) - now := common.Timestamp(time.Now().UnixNano()) - - blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" - blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) - - fr := reference.Ref{ - AllocationID: "exampleId", - } - - rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) - - wm := writemarker.WriteMarker{ - AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), - PreviousAllocationRoot: "/", - AllocationID: "exampleId", - Size: 1337, - BlobberID: encryption.Hash(blobberPubKeyBytes), - Timestamp: now, - ClientID: clientId, - } - - wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) - if err != nil { - t.Fatal(err) - } - - wm.Signature = wmSig - - if err := tdController.ClearDatabase(); err != nil { - t.Fatal(err) - } - if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.CollaboratorRequest - expectedMessage string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.CollaboratorRequest{ - Path: "/some_file", - PathHash: "exampleId:examplePath", - Allocation: allocationTx, - Method: http.MethodPost, - CollabId: "10", - }, - expectedMessage: "Added collaborator successfully", - expectingError: false, - }, - { - name: "Fail", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.CollaboratorRequest{ - Path: "/some_file", - PathHash: "exampleId:examplePath", - Allocation: allocationTx, - Method: http.MethodPost, - }, - expectedMessage: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - response, err := blobberClient.Collaborator(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if response.GetMessage() != tc.expectedMessage { - t.Fatal("failed!") - } - } - }) + //t.Run("TestGetFileMetaData", func(t *testing.T) { + // err := tdController.ClearDatabase() + // if err != nil { + // t.Fatal(err) + // } + // err = tdController.AddGetFileMetaDataTestData() + // if err != nil { + // t.Fatal(err) + // } + // + // testCases := []struct { + // name string + // context metadata.MD + // input *blobbergrpc.GetFileMetaDataRequest + // expectedFileName string + // expectingError bool + // }{ + // { + // name: "Success", + // context: metadata.New(map[string]string{ + // common.ClientHeader: "exampleOwnerId", + // }), + // input: &blobbergrpc.GetFileMetaDataRequest{ + // Path: "examplePath", + // PathHash: "exampleId:examplePath", + // Allocation: "exampleTransaction", + // }, + // expectedFileName: "filename", + // expectingError: false, + // }, + // { + // name: "Unknown file path", + // context: metadata.New(map[string]string{ + // common.ClientHeader: "exampleOwnerId", + // }), + // input: &blobbergrpc.GetFileMetaDataRequest{ + // Path: "examplePath", + // PathHash: "exampleId:examplePath123", + // Allocation: "exampleTransaction", + // }, + // expectedFileName: "", + // expectingError: true, + // }, + // } + // + // for _, tc := range testCases { + // ctx := context.Background() + // ctx = metadata.NewOutgoingContext(ctx, tc.context) + // getFileMetaDataResp, err := blobberClient.GetFileMetaData(ctx, tc.input) + // if err != nil { + // if !tc.expectingError { + // t.Fatal(err) + // } + // continue + // } + // + // if tc.expectingError { + // t.Fatal("expected error") + // } + // + // if getFileMetaDataResp.MetaData.FileMetaData.Name != tc.expectedFileName { + // t.Fatal("unexpected file name from GetFileMetaData rpc") + // } + // } + //}) + // + //t.Run("TestGetFileStats", func(t *testing.T) { + // + // allocationTx := randString(32) + // + // pubKey, _, signScheme := GeneratePubPrivateKey(t) + // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + // + // err := tdController.ClearDatabase() + // if err != nil { + // t.Fatal(err) + // } + // err = tdController.AddGetFileStatsTestData(allocationTx, pubKey) + // if err != nil { + // t.Fatal(err) + // } + // + // testCases := []struct { + // name string + // context metadata.MD + // input *blobbergrpc.GetFileStatsRequest + // expectedFileName string + // expectingError bool + // }{ + // { + // name: "Success", + // context: metadata.New(map[string]string{ + // common.ClientHeader: "exampleOwnerId", + // common.ClientSignatureHeader: clientSignature, + // }), + // input: &blobbergrpc.GetFileStatsRequest{ + // Path: "examplePath", + // PathHash: "exampleId:examplePath", + // Allocation: allocationTx, + // }, + // expectedFileName: "filename", + // expectingError: false, + // }, + // { + // name: "Unknown Path", + // context: metadata.New(map[string]string{ + // common.ClientHeader: "exampleOwnerId", + // common.ClientSignatureHeader: clientSignature, + // }), + // input: &blobbergrpc.GetFileStatsRequest{ + // Path: "examplePath", + // PathHash: "exampleId:examplePath123", + // Allocation: allocationTx, + // }, + // expectedFileName: "", + // expectingError: true, + // }, + // } + // + // for _, tc := range testCases { + // ctx := context.Background() + // ctx = metadata.NewOutgoingContext(ctx, tc.context) + // getFileStatsResp, err := blobberClient.GetFileStats(ctx, tc.input) + // if err != nil { + // if !tc.expectingError { + // t.Fatal(err) + // } + // continue + // } + // + // if tc.expectingError { + // t.Fatal("expected error") + // } + // + // if getFileStatsResp.MetaData.FileMetaData.Name != tc.expectedFileName { + // t.Fatal("unexpected file name from GetFileStats rpc") + // } + // } + // + //}) + // + //t.Run("TestListEntities", func(t *testing.T) { + // allocationTx := randString(32) + // + // pubKey, _, signScheme := GeneratePubPrivateKey(t) + // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + // + // err := tdController.ClearDatabase() + // if err != nil { + // t.Fatal(err) + // } + // err = tdController.AddListEntitiesTestData(allocationTx, pubKey) + // if err != nil { + // t.Fatal(err) + // } + // + // testCases := []struct { + // name string + // context metadata.MD + // input *blobbergrpc.ListEntitiesRequest + // expectedPath string + // expectingError bool + // }{ + // { + // name: "Success", + // context: metadata.New(map[string]string{ + // common.ClientHeader: "exampleOwnerId", + // common.ClientSignatureHeader: clientSignature, + // }), + // input: &blobbergrpc.ListEntitiesRequest{ + // Path: "examplePath", + // PathHash: "exampleId:examplePath", + // AuthToken: "", + // Allocation: allocationTx, + // }, + // expectedPath: "examplePath", + // expectingError: false, + // }, + // { + // name: "bad path", + // context: metadata.New(map[string]string{ + // common.ClientHeader: "exampleOwnerId", + // common.ClientSignatureHeader: clientSignature, + // }), + // input: &blobbergrpc.ListEntitiesRequest{ + // Path: "examplePath", + // PathHash: "exampleId:examplePath123", + // AuthToken: "", + // Allocation: allocationTx, + // }, + // expectedPath: "", + // expectingError: true, + // }, + // } + // + // for _, tc := range testCases { + // ctx := context.Background() + // ctx = metadata.NewOutgoingContext(ctx, tc.context) + // listEntitiesResp, err := blobberClient.ListEntities(ctx, tc.input) + // if err != nil { + // if !tc.expectingError { + // t.Fatal(err) + // } + // continue + // } + // + // if tc.expectingError { + // t.Fatal("expected error") + // } + // + // if listEntitiesResp.MetaData.DirMetaData.Path != tc.expectedPath { + // t.Fatal("unexpected path from ListEntities rpc") + // } + // } + // + //}) + // + //t.Run("TestGetObjectPath", func(t *testing.T) { + // allocationTx := randString(32) + // + // pubKey, _, signScheme := GeneratePubPrivateKey(t) + // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + // + // err := tdController.ClearDatabase() + // if err != nil { + // t.Fatal(err) + // } + // err = tdController.AddGetObjectPathTestData(allocationTx, pubKey) + // if err != nil { + // t.Fatal(err) + // } + // + // testCases := []struct { + // name string + // context metadata.MD + // input *blobbergrpc.GetObjectPathRequest + // expectedPath string + // expectingError bool + // }{ + // { + // name: "Success", + // context: metadata.New(map[string]string{ + // common.ClientHeader: "exampleOwnerId", + // common.ClientSignatureHeader: clientSignature, + // }), + // input: &blobbergrpc.GetObjectPathRequest{ + // Allocation: allocationTx, + // Path: "examplePath", + // BlockNum: "0", + // }, + // expectedPath: "/", + // expectingError: false, + // }, + // } + // + // for _, tc := range testCases { + // ctx := context.Background() + // ctx = metadata.NewOutgoingContext(ctx, tc.context) + // getObjectPathResp, err := blobberClient.GetObjectPath(ctx, tc.input) + // if err != nil { + // if !tc.expectingError { + // t.Fatal(err) + // } + // continue + // } + // + // if tc.expectingError { + // t.Fatal("expected error") + // } + // + // if getObjectPathResp.ObjectPath.Path.DirMetaData.Path != tc.expectedPath { + // t.Fatal("unexpected root hash from GetObjectPath rpc") + // } + // } + //}) + // + //t.Run("TestGetReferencePath", func(t *testing.T) { + // allocationTx := randString(32) + // + // pubKey, _, signScheme := GeneratePubPrivateKey(t) + // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + // + // err := tdController.ClearDatabase() + // if err != nil { + // t.Fatal(err) + // } + // err = tdController.AddGetReferencePathTestData(allocationTx, pubKey) + // if err != nil { + // t.Fatal(err) + // } + // + // testCases := []struct { + // name string + // context metadata.MD + // input *blobbergrpc.GetReferencePathRequest + // expectedPath string + // expectingError bool + // }{ + // { + // name: "Success", + // context: metadata.New(map[string]string{ + // common.ClientHeader: "exampleOwnerId", + // common.ClientSignatureHeader: clientSignature, + // }), + // input: &blobbergrpc.GetReferencePathRequest{ + // Paths: "", + // Path: "/", + // Allocation: allocationTx, + // }, + // expectedPath: "/", + // expectingError: false, + // }, + // } + // + // for _, tc := range testCases { + // ctx := context.Background() + // ctx = metadata.NewOutgoingContext(ctx, tc.context) + // getReferencePathResp, err := blobberClient.GetReferencePath(ctx, tc.input) + // if err != nil { + // if !tc.expectingError { + // t.Fatal(err) + // } + // continue + // } + // + // if tc.expectingError { + // t.Fatal("expected error") + // } + // + // if getReferencePathResp.ReferencePath.MetaData.DirMetaData.Path != tc.expectedPath { + // t.Fatal("unexpected path from GetReferencePath rpc") + // } + // } + //}) + // + //t.Run("TestGetObjectTree", func(t *testing.T) { + // allocationTx := randString(32) + // + // pubKey, _, signScheme := GeneratePubPrivateKey(t) + // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + // + // err := tdController.ClearDatabase() + // if err != nil { + // t.Fatal(err) + // } + // err = tdController.AddGetObjectTreeTestData(allocationTx, pubKey) + // if err != nil { + // t.Fatal(err) + // } + // + // testCases := []struct { + // name string + // context metadata.MD + // input *blobbergrpc.GetObjectTreeRequest + // expectedFileName string + // expectingError bool + // }{ + // { + // name: "Success", + // context: metadata.New(map[string]string{ + // common.ClientHeader: "exampleOwnerId", + // common.ClientSignatureHeader: clientSignature, + // }), + // input: &blobbergrpc.GetObjectTreeRequest{ + // Path: "/", + // Allocation: allocationTx, + // }, + // expectedFileName: "root", + // expectingError: false, + // }, + // { + // name: "bad path", + // context: metadata.New(map[string]string{ + // common.ClientHeader: "exampleOwnerId", + // common.ClientSignatureHeader: clientSignature, + // }), + // input: &blobbergrpc.GetObjectTreeRequest{ + // Path: "/2", + // Allocation: "", + // }, + // expectedFileName: "root", + // expectingError: true, + // }, + // } + // + // for _, tc := range testCases { + // ctx := context.Background() + // ctx = metadata.NewOutgoingContext(ctx, tc.context) + // getObjectTreeResp, err := blobberClient.GetObjectTree(ctx, tc.input) + // if err != nil { + // if !tc.expectingError { + // t.Fatal(err) + // } + // continue + // } + // + // if tc.expectingError { + // t.Fatal("expected error") + // } + // + // if getObjectTreeResp.ReferencePath.MetaData.DirMetaData.Name != tc.expectedFileName { + // t.Fatal("unexpected root name from GetObject") + // } + // } + // + //}) + // + //t.Run("TestCommit", func(t *testing.T) { + // allocationTx := randString(32) + // + // pubKey, _, signScheme := GeneratePubPrivateKey(t) + // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + // pubKeyBytes, _ := hex.DecodeString(pubKey) + // clientId := encryption.Hash(pubKeyBytes) + // now := common.Timestamp(time.Now().UnixNano()) + // + // blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + // blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + // + // fr := reference.Ref{ + // AllocationID: "exampleId", + // Type: "f", + // Name: "new_name", + // Path: "/new_name", + // ContentHash: "contentHash", + // MerkleRoot: "merkleRoot", + // ActualFileHash: "actualFileHash", + // } + // + // rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + // + // wm := writemarker.WriteMarker{ + // AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + // PreviousAllocationRoot: "/", + // AllocationID: "exampleId", + // Size: 1337, + // BlobberID: encryption.Hash(blobberPubKeyBytes), + // Timestamp: now, + // ClientID: clientId, + // } + // + // wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + // if err != nil { + // t.Fatal(err) + // } + // + // wm.Signature = wmSig + // + // wmRaw, err := json.Marshal(wm) + // if err != nil { + // t.Fatal(err) + // } + // + // err = tdController.ClearDatabase() + // if err != nil { + // t.Fatal(err) + // } + // err = tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now) + // if err != nil { + // t.Fatal(err) + // } + // + // testCases := []struct { + // name string + // context metadata.MD + // input *blobbergrpc.CommitRequest + // expectedAllocation string + // expectingError bool + // }{ + // { + // name: "Success", + // context: metadata.New(map[string]string{ + // common.ClientHeader: clientId, + // common.ClientSignatureHeader: clientSignature, + // common.ClientKeyHeader: pubKey, + // }), + // input: &blobbergrpc.CommitRequest{ + // Allocation: allocationTx, + // ConnectionId: "connection_id", + // WriteMarker: string(wmRaw), + // }, + // expectedAllocation: "exampleId", + // expectingError: false, + // }, + // { + // name: "invalid write_marker", + // context: metadata.New(map[string]string{ + // common.ClientHeader: clientId, + // common.ClientSignatureHeader: clientSignature, + // common.ClientKeyHeader: pubKey, + // }), + // input: &blobbergrpc.CommitRequest{ + // Allocation: allocationTx, + // ConnectionId: "invalid", + // WriteMarker: "invalid", + // }, + // expectedAllocation: "", + // expectingError: true, + // }, + // } + // + // for _, tc := range testCases { + // ctx := context.Background() + // ctx = metadata.NewOutgoingContext(ctx, tc.context) + // getCommiteResp, err := blobberClient.Commit(ctx, tc.input) + // if err != nil { + // if !tc.expectingError { + // t.Fatal(err) + // } + // continue + // } + // + // if tc.expectingError { + // t.Fatal("expected error") + // } + // + // if getCommiteResp.WriteMarker.AllocationID != tc.expectedAllocation { + // t.Fatal("unexpected root name from GetObject") + // } + // } + //}) + // + //t.Run("TestCommitMetaTxn", func(t *testing.T) { + // allocationTx := randString(32) + // + // pubKey, _, signScheme := GeneratePubPrivateKey(t) + // pubKeyBytes, _ := hex.DecodeString(pubKey) + // clientId := encryption.Hash(pubKeyBytes) + // now := common.Timestamp(time.Now().UnixNano()) + // + // blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + // blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + // + // fr := reference.Ref{ + // AllocationID: "exampleId", + // } + // + // rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + // + // wm := writemarker.WriteMarker{ + // AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + // PreviousAllocationRoot: "/", + // AllocationID: "exampleId", + // Size: 1337, + // BlobberID: encryption.Hash(blobberPubKeyBytes), + // Timestamp: now, + // ClientID: clientId, + // } + // + // wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + // if err != nil { + // t.Fatal(err) + // } + // + // wm.Signature = wmSig + // + // if err := tdController.ClearDatabase(); err != nil { + // t.Fatal(err) + // } + // if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { + // t.Fatal(err) + // } + // + // testCases := []struct { + // name string + // context metadata.MD + // input *blobbergrpc.CommitMetaTxnRequest + // expectedMessage string + // expectingError bool + // }{ + // { + // name: "Success", + // context: metadata.New(map[string]string{ + // common.ClientHeader: clientId, + // }), + // input: &blobbergrpc.CommitMetaTxnRequest{ + // Path: "/some_file", + // PathHash: "exampleId:examplePath", + // AuthToken: "", + // Allocation: allocationTx, + // TxnId: "8", + // }, + // expectedMessage: "Added commitMetaTxn successfully", + // expectingError: false, + // }, + // { + // name: "Fail", + // context: metadata.New(map[string]string{ + // common.ClientHeader: clientId, + // }), + // input: &blobbergrpc.CommitMetaTxnRequest{ + // Path: "/some_file", + // PathHash: "exampleId:examplePath", + // AuthToken: "", + // Allocation: allocationTx, + // TxnId: "", + // }, + // expectedMessage: "", + // expectingError: true, + // }, + // } + // + // for _, tc := range testCases { + // ctx := context.Background() + // ctx = metadata.NewOutgoingContext(ctx, tc.context) + // commitMetaTxnResponse, err := blobberClient.CommitMetaTxn(ctx, tc.input) + // if err != nil { + // if !tc.expectingError { + // t.Fatal(err) + // } + // continue + // } + // + // if tc.expectingError { + // t.Fatal("expected error") + // } + // + // if commitMetaTxnResponse.GetMessage() != tc.expectedMessage { + // t.Fatal("failed!") + // } + // } + //}) + // + //t.Run("TestCollaborator", func(t *testing.T) { + // allocationTx := randString(32) + // + // pubKey, _, signScheme := GeneratePubPrivateKey(t) + // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + // pubKeyBytes, _ := hex.DecodeString(pubKey) + // clientId := encryption.Hash(pubKeyBytes) + // now := common.Timestamp(time.Now().UnixNano()) + // + // blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + // blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + // + // fr := reference.Ref{ + // AllocationID: "exampleId", + // } + // + // rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + // + // wm := writemarker.WriteMarker{ + // AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + // PreviousAllocationRoot: "/", + // AllocationID: "exampleId", + // Size: 1337, + // BlobberID: encryption.Hash(blobberPubKeyBytes), + // Timestamp: now, + // ClientID: clientId, + // } + // + // wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + // if err != nil { + // t.Fatal(err) + // } + // + // wm.Signature = wmSig + // + // if err := tdController.ClearDatabase(); err != nil { + // t.Fatal(err) + // } + // if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { + // t.Fatal(err) + // } + // + // testCases := []struct { + // name string + // context metadata.MD + // input *blobbergrpc.CollaboratorRequest + // expectedMessage string + // expectingError bool + // }{ + // { + // name: "Success", + // context: metadata.New(map[string]string{ + // common.ClientHeader: clientId, + // common.ClientSignatureHeader: clientSignature, + // common.ClientKeyHeader: pubKey, + // }), + // input: &blobbergrpc.CollaboratorRequest{ + // Path: "/some_file", + // PathHash: "exampleId:examplePath", + // Allocation: allocationTx, + // Method: http.MethodPost, + // CollabId: "10", + // }, + // expectedMessage: "Added collaborator successfully", + // expectingError: false, + // }, + // { + // name: "Fail", + // context: metadata.New(map[string]string{ + // common.ClientHeader: clientId, + // common.ClientSignatureHeader: clientSignature, + // common.ClientKeyHeader: pubKey, + // }), + // input: &blobbergrpc.CollaboratorRequest{ + // Path: "/some_file", + // PathHash: "exampleId:examplePath", + // Allocation: allocationTx, + // Method: http.MethodPost, + // }, + // expectedMessage: "", + // expectingError: true, + // }, + // } + // + // for _, tc := range testCases { + // ctx := context.Background() + // ctx = metadata.NewOutgoingContext(ctx, tc.context) + // response, err := blobberClient.Collaborator(ctx, tc.input) + // if err != nil { + // if !tc.expectingError { + // t.Fatal(err) + // } + // + // continue + // } + // + // if tc.expectingError { + // t.Fatal("expected error") + // } + // + // if response.GetMessage() != tc.expectedMessage { + // t.Fatal("failed!") + // } + // } + //}) } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index dd6b14f58..486df77a4 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -20,41 +20,6 @@ import ( "google.golang.org/grpc/metadata" ) -func TestBlobberGRPCService_GetAllocation_Success(t *testing.T) { - req := &blobbergrpc.GetAllocationRequest{ - Id: "something", - } - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Id, false).Return(&allocation.Allocation{ - Tx: req.Id, - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - allocation, err := svc.GetAllocation(context.Background(), req) - assert.NoError(t, err) - assert.Equal(t, allocation.Allocation.Tx, req.Id) -} - -func TestBlobberGRPCService_GetAllocation_invalidAllocation(t *testing.T) { - req := &blobbergrpc.GetAllocationRequest{ - Id: "invalid_allocation", - } - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Id, false).Return(nil, errors.New("some error")) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.GetAllocation(context.Background(), req) - if err == nil { - t.Fatal("expected error") - } - - assert.Equal(t, err.Error(), "some error") -} - func TestBlobberGRPCService_GetFileMetaData_Success(t *testing.T) { req := &blobbergrpc.GetFileMetaDataRequest{ Path: "path", diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index cd3dbb44c..45b7163fb 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -7,18 +7,17 @@ import ( "net/http" "os" "runtime/pprof" + "time" + + "go.uber.org/zap" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" "github.com/0chain/blobber/code/go/0chain.net/core/common" . "github.com/0chain/blobber/code/go/0chain.net/core/logging" "github.com/gorilla/mux" - "go.uber.org/zap" - "google.golang.org/grpc/metadata" ) var storageHandler StorageHandler @@ -29,28 +28,26 @@ func GetMetaDataStore() *datastore.Store { /*SetupHandlers sets up the necessary API end points */ func SetupHandlers(r *mux.Router) { - svc := newGRPCBlobberService(&storageHandler, &packageHandler{}) - //object operations r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) - r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler(svc))))).Methods(http.MethodPost) - r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) + r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) - r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler(svc))))).Methods("POST") - r.HandleFunc("/v1/file/commitmetatxn/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitMetaTxnHandler(svc))))).Methods(http.MethodPost) - r.HandleFunc("/v1/file/collaborator/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CollaboratorHandler(svc))))).Methods(http.MethodGet, http.MethodPost, http.MethodDelete) - r.HandleFunc("/v1/file/calculatehash/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CalculateHashHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/connection/commit/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitHandler)))) + r.HandleFunc("/v1/file/commitmetatxn/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CommitMetaTxnHandler)))) + r.HandleFunc("/v1/file/collaborator/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CollaboratorHandler)))) + r.HandleFunc("/v1/file/calculatehash/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CalculateHashHandler)))) //object info related apis - r.HandleFunc("/allocation", common.UserRateLimit(common.ToJSONResponse(WithConnection(AllocationHandler(svc))))).Methods(http.MethodGet) - r.HandleFunc("/v1/file/meta/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileMetaHandler(svc))))).Methods(http.MethodPost) - r.HandleFunc("/v1/file/stats/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileStatsHandler(svc))))).Methods(http.MethodPost) - r.HandleFunc("/v1/file/list/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ListHandler(svc))))).Methods(http.MethodGet) - r.HandleFunc("/v1/file/objectpath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectPathHandler(svc))))).Methods(http.MethodGet) - r.HandleFunc("/v1/file/referencepath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ReferencePathHandler(svc))))).Methods(http.MethodGet) - r.HandleFunc("/v1/file/objecttree/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectTreeHandler(svc))))).Methods(http.MethodGet) + r.HandleFunc("/allocation", common.UserRateLimit(common.ToJSONResponse(WithConnection(AllocationHandler)))) + r.HandleFunc("/v1/file/meta/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileMetaHandler)))) + r.HandleFunc("/v1/file/stats/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(FileStatsHandler)))) + r.HandleFunc("/v1/file/list/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ListHandler)))) + r.HandleFunc("/v1/file/objectpath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectPathHandler)))) + r.HandleFunc("/v1/file/referencepath/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ReferencePathHandler)))) + r.HandleFunc("/v1/file/objecttree/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithReadOnlyConnection(ObjectTreeHandler)))) //admin related r.HandleFunc("/_debug", common.UserRateLimit(common.ToJSONResponse(DumpGoRoutines))) @@ -115,100 +112,59 @@ func setupHandlerContext(ctx context.Context, r *http.Request) context.Context { return ctx } -func setupHandlerGRPCContext(ctx context.Context, r *http.Request) context.Context { - return metadata.NewIncomingContext(ctx, metadata.New(map[string]string{ - common.ClientHeader: r.Header.Get(common.ClientHeader), - common.ClientKeyHeader: r.Header.Get(common.ClientKeyHeader), - common.ClientSignatureHeader: r.Header.Get(common.ClientSignatureHeader), - })) -} - -func AllocationHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - - getAllocationResp, err := svc.GetAllocation(ctx, &blobbergrpc.GetAllocationRequest{ - Id: r.FormValue("id"), - }) - if err != nil { - return nil, err - } +func AllocationHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) - return convert.GetAllocationResponseHandler(getAllocationResp), nil + response, err := storageHandler.GetAllocationDetails(ctx, r) + if err != nil { + return nil, err } + + return response, nil } -func FileMetaHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - - getFileMetaDataResp, err := svc.GetFileMetaData(ctx, &blobbergrpc.GetFileMetaDataRequest{ - Path: r.FormValue("path"), - PathHash: r.FormValue("path_hash"), - AuthToken: r.FormValue("auth_token"), - Allocation: mux.Vars(r)["allocation"], - }) - if err != nil { - return nil, err - } +func FileMetaHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) - return convert.GetFileMetaDataResponseHandler(getFileMetaDataResp), nil + response, err := storageHandler.GetFileMeta(ctx, r) + if err != nil { + return nil, err } + + return response, nil } -func CommitMetaTxnHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - - response, err := svc.CommitMetaTxn(ctx, &blobbergrpc.CommitMetaTxnRequest{ - Path: r.FormValue("path"), - PathHash: r.FormValue("path_hash"), - AuthToken: r.FormValue("auth_token"), - Allocation: mux.Vars(r)["allocation"], - TxnId: r.FormValue("txn_id"), - }) - if err != nil { - return nil, err - } +func CommitMetaTxnHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) - return convert.GetCommitMetaTxnHandlerResponse(response), nil + response, err := storageHandler.AddCommitMetaTxn(ctx, r) + if err != nil { + return nil, err } + + return response, nil } -func CollaboratorHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - - response, err := svc.Collaborator(ctx, &blobbergrpc.CollaboratorRequest{ - Allocation: mux.Vars(r)["allocation"], - CollabId: r.FormValue("collab_id"), - Method: r.Method, - Path: r.FormValue("path"), - PathHash: r.FormValue("path_hash"), - }) - if err != nil { - return nil, err - } +func CollaboratorHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) - return convert.CollaboratorResponse(response), nil + response, err := storageHandler.AddCollaborator(ctx, r) + if err != nil { + return nil, err } -} -func FileStatsHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) + return response, nil +} - getFileStatsResponse, err := svc.GetFileStats(ctx, &blobbergrpc.GetFileStatsRequest{ - Path: r.FormValue("path"), - PathHash: r.FormValue("path_hash"), - Allocation: mux.Vars(r)["allocation"], - }) - if err != nil { - return nil, err - } +func FileStatsHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) - return convert.GetFileStatsResponseHandler(getFileStatsResponse), nil + response, err := storageHandler.GetFileStats(ctx, r) + if err != nil { + return nil, err } + + return response, nil } /*DownloadHandler is the handler to respond to download requests from clients*/ @@ -224,86 +180,63 @@ func DownloadHandler(ctx context.Context, r *http.Request) (interface{}, error) } /*ListHandler is the handler to respond to upload requests fro clients*/ -func ListHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - listEntitiesResponse, err := svc.ListEntities(ctx, &blobbergrpc.ListEntitiesRequest{ - Path: r.FormValue("path"), - PathHash: r.FormValue("path_hash"), - AuthToken: r.FormValue("auth_token"), - Allocation: mux.Vars(r)["allocation"], - }) - if err != nil { - return nil, err - } +func ListHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) - return convert.ListEntitesResponseHandler(listEntitiesResponse), nil + response, err := storageHandler.ListEntities(ctx, r) + if err != nil { + return nil, err } + + return response, nil } /*CommitHandler is the handler to respond to upload requests fro clients*/ -func CommitHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - - response, err := svc.Commit(ctx, &blobbergrpc.CommitRequest{ - Allocation: mux.Vars(r)["allocation"], - ConnectionId: r.FormValue("connection_id"), - WriteMarker: r.FormValue("write_marker"), - }) - if err != nil { - return nil, err - } +func CommitHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) - return convert.CommitWriteResponseHandler(response), nil + response, err := storageHandler.CommitWrite(ctx, r) + if err != nil { + return nil, err } + + return response, nil } -func ReferencePathHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - getReferencePathResponse, err := svc.GetReferencePath(ctx, &blobbergrpc.GetReferencePathRequest{ - Paths: r.FormValue("paths"), - Path: r.FormValue("path"), - Allocation: mux.Vars(r)["allocation"], - }) - if err != nil { - return nil, err - } +func ReferencePathHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx, canceler := context.WithTimeout(ctx, time.Second*10) + defer canceler() + + ctx = setupHandlerContext(ctx, r) - return convert.GetReferencePathResponseHandler(getReferencePathResponse), nil + response, err := storageHandler.GetReferencePath(ctx, r) + if err != nil { + return nil, err } + + return response, nil } -func ObjectPathHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - getObjectPathResponse, err := svc.GetObjectPath(ctx, &blobbergrpc.GetObjectPathRequest{ - Allocation: mux.Vars(r)["allocation"], - Path: r.FormValue("path"), - BlockNum: r.FormValue("block_num"), - }) - if err != nil { - return nil, err - } +func ObjectPathHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) - return convert.GetObjectPathResponseHandler(getObjectPathResponse), nil + response, err := storageHandler.GetObjectPath(ctx, r) + if err != nil { + return nil, err } + + return response, nil } -func ObjectTreeHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - getObjectTreeResponse, err := svc.GetObjectTree(ctx, &blobbergrpc.GetObjectTreeRequest{ - Path: r.FormValue("path"), - Allocation: mux.Vars(r)["allocation"], - }) - if err != nil { - return nil, err - } +func ObjectTreeHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) - return convert.GetObjectTreeResponseHandler(getObjectTreeResponse), nil + response, err := storageHandler.GetObjectTree(ctx, r) + if err != nil { + return nil, err } + + return response, nil } func RenameHandler(ctx context.Context, r *http.Request) (interface{}, error) { @@ -316,23 +249,14 @@ func RenameHandler(ctx context.Context, r *http.Request) (interface{}, error) { return response, nil } -func CopyHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - - copyObjResponse, err := svc.CopyObject(ctx, &blobbergrpc.CopyObjectRequest{ - Allocation: mux.Vars(r)["allocation"], - Path: r.FormValue("path"), - PathHash: r.FormValue("path_hash"), - ConnectionId: r.FormValue("connection_id"), - Dest: r.FormValue("dest"), - }) - if err != nil { - return nil, err - } - - return convert.CopyObjectResponseHandler(copyObjResponse), nil +func CopyHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) + response, err := storageHandler.CopyObject(ctx, r) + if err != nil { + return nil, err } + + return response, nil } /*UploadHandler is the handler to respond to upload requests fro clients*/ @@ -346,40 +270,25 @@ func UploadHandler(ctx context.Context, r *http.Request) (interface{}, error) { return response, nil } -func UpdateAttributesHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - - updateAttrResp, err := svc.UpdateObjectAttributes(ctx, &blobbergrpc.UpdateObjectAttributesRequest{ - Path: r.FormValue("path"), - PathHash: r.FormValue("path_hash"), - Allocation: mux.Vars(r)["allocation"], - ConnectionId: r.FormValue("connection_id"), - Attributes: r.FormValue("attributes"), - }) - if err != nil { - return nil, err - } - - return convert.UpdateObjectAttributesResponseHandler(updateAttrResp), nil +func UpdateAttributesHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) + response, err := storageHandler.UpdateObjectAttributes(ctx, r) + if err != nil { + return nil, err } -} -func CalculateHashHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) + return response, nil +} - response, err := svc.CalculateHash(ctx, &blobbergrpc.CalculateHashRequest{ - Allocation: mux.Vars(r)["allocation"], - Paths: r.FormValue("paths"), - Path: r.FormValue("path"), - }) - if err != nil { - return nil, err - } +func CalculateHashHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) - return convert.GetCalculateHashResponseHandler(response), nil + response, err := storageHandler.CalculateHash(ctx, r) + if err != nil { + return nil, err } + + return response, nil } //nolint:gosimple // need more time to verify diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go index c14fb811a..49614a930 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/handler_test.go @@ -89,13 +89,12 @@ func setup(t *testing.T) { func setupHandlers() (*mux.Router, map[string]string) { router := mux.NewRouter() - svc := newGRPCBlobberService(&storageHandler, &packageHandler{}) opPath := "/v1/file/objectpath/{allocation}" opName := "Object_Path" router.HandleFunc(opPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(ObjectPathHandler(svc)), + WithReadOnlyConnection(ObjectPathHandler), ), ), ).Name(opName) @@ -104,7 +103,7 @@ func setupHandlers() (*mux.Router, map[string]string) { rpName := "Reference_Path" router.HandleFunc(rpPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(ReferencePathHandler(svc)), + WithReadOnlyConnection(ReferencePathHandler), ), ), ).Name(rpName) @@ -113,7 +112,7 @@ func setupHandlers() (*mux.Router, map[string]string) { sName := "Stats" router.HandleFunc(sPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(FileStatsHandler(svc)), + WithReadOnlyConnection(FileStatsHandler), ), ), ).Name(sName) @@ -122,7 +121,7 @@ func setupHandlers() (*mux.Router, map[string]string) { otName := "Object_Tree" router.HandleFunc(otPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(ObjectTreeHandler(svc)), + WithReadOnlyConnection(ObjectTreeHandler), ), ), ).Name(otName) @@ -131,7 +130,7 @@ func setupHandlers() (*mux.Router, map[string]string) { collName := "Collaborator" router.HandleFunc(collPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(CollaboratorHandler(svc)), + WithReadOnlyConnection(CollaboratorHandler), ), ), ).Name(collName) @@ -149,7 +148,7 @@ func setupHandlers() (*mux.Router, map[string]string) { cName := "Copy" router.HandleFunc(cPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(CopyHandler(svc)), + WithReadOnlyConnection(CopyHandler), ), ), ).Name(cName) @@ -158,7 +157,7 @@ func setupHandlers() (*mux.Router, map[string]string) { aName := "Attributes" router.HandleFunc(aPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(UpdateAttributesHandler(svc)), + WithReadOnlyConnection(UpdateAttributesHandler), ), ), ).Name(aName) diff --git a/code/go/0chain.net/blobbercore/handler/metadata.go b/code/go/0chain.net/blobbercore/handler/metadata.go index 0ad3cb7fd..822eb80ae 100644 --- a/code/go/0chain.net/blobbercore/handler/metadata.go +++ b/code/go/0chain.net/blobbercore/handler/metadata.go @@ -2,8 +2,10 @@ package handler import ( "context" + "net/http" + + "github.com/gorilla/mux" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" "github.com/0chain/blobber/code/go/0chain.net/core/common" "google.golang.org/grpc/metadata" ) @@ -36,10 +38,9 @@ func GetGRPCMetaDataFromCtx(ctx context.Context) *GRPCMetaData { return metaData } -func setupGRPCHandlerContext(ctx context.Context, md *GRPCMetaData, alloc string) context.Context { - ctx = context.WithValue(ctx, constants.CLIENT_CONTEXT_KEY, md.Client) - ctx = context.WithValue(ctx, constants.CLIENT_KEY_CONTEXT_KEY, md.ClientKey) - ctx = context.WithValue(ctx, constants.ALLOCATION_CONTEXT_KEY, alloc) - ctx = context.WithValue(ctx, constants.CLIENT_SIGNATURE_HEADER_KEY, md.ClientSignature) - return ctx +func httpRequestWithMetaData(r *http.Request, md *GRPCMetaData, alloc string) { + r.Header.Set(common.ClientHeader, md.Client) + r.Header.Set(common.ClientKeyHeader, md.ClientKey) + r.Header.Set(common.ClientSignatureHeader, md.ClientSignature) + mux.SetURLVars(r, map[string]string{"allocation": alloc}) } From a48c03ed02c1a2445ef0820bb8d94e9eb5dcbcd5 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 15:13:36 +0530 Subject: [PATCH 114/183] :sparkles: grpc -> http getfilemetadata --- .../blobbercore/convert/responseHandler.go | 17 +-- .../blobbercore/handler/grpc_handler.go | 71 ++-------- .../handler/grpc_handler_integration_test.go | 133 +++++++++--------- .../handler/grpc_handler_unit_test.go | 81 ----------- 4 files changed, 87 insertions(+), 215 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index d8b0cdc9a..96f9e75e8 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -14,19 +14,20 @@ import ( func GetAllocationResponseCreator(resp interface{}) *blobbergrpc.GetAllocationResponse { alloc, _ := resp.(*allocation.Allocation) - return &blobbergrpc.GetAllocationResponse{Allocation: AllocationToGRPCAllocation(alloc)} } -func GetFileMetaDataResponseHandler(resp *blobbergrpc.GetFileMetaDataResponse) map[string]interface{} { - var collaborators []reference.Collaborator - for _, c := range resp.Collaborators { - collaborators = append(collaborators, *GRPCCollaboratorToCollaborator(c)) +func GetFileMetaDataResponseCreator(httpResp interface{}) *blobbergrpc.GetFileMetaDataResponse { + r, _ := httpResp.(map[string]interface{}) + + var resp blobbergrpc.GetFileMetaDataResponse + collaborators, _ := r["collaborators"].([]reference.Collaborator) + for _, c := range collaborators { + resp.Collaborators = append(resp.Collaborators, CollaboratorToGRPCCollaborator(&c)) } - result := FileRefGRPCToFileRef(resp.MetaData).GetListingData(context.Background()) - result["collaborators"] = collaborators - return result + resp.MetaData = FileRefToFileRefGRPC(reference.ListingDataToRef(r)) + return &resp } func GetFileStatsResponseHandler(resp *blobbergrpc.GetFileStatsResponse) map[string]interface{} { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 693348a60..e0ec3e37f 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -12,7 +12,6 @@ import ( "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap/ctxzap" - "go.uber.org/zap" ) type blobberGRPCService struct { @@ -45,73 +44,23 @@ func (b *blobberGRPCService) GetAllocation(ctx context.Context, request *blobber } func (b *blobberGRPCService) GetFileMetaData(ctx context.Context, req *blobbergrpc.GetFileMetaDataRequest) (*blobbergrpc.GetFileMetaDataResponse, error) { - logger := ctxzap.Extract(ctx) - md := GetGRPCMetaDataFromCtx(ctx) - - allocationObj, err := b.storageHandler.verifyAllocation(ctx, req.Allocation, true) - if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - allocationID := allocationObj.ID - - clientID := md.Client - if len(clientID) == 0 { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") - } - - path_hash := req.PathHash - path := req.Path - if len(path_hash) == 0 { - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") - } - path_hash = reference.GetReferenceLookup(allocationID, path) - } - - fileref, err := b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, path_hash) + r, err := http.NewRequest("POST", "", nil) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid file path. "+err.Error()) + return nil, err } - - if fileref.Type != reference.FILE { - return nil, common.NewError("invalid_parameters", "Path is not a file.") + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path_hash": {req.PathHash}, + "path": {req.Path}, + "auth_token": {req.AuthToken}, } - commitMetaTxns, err := b.packageHandler.GetCommitMetaTxns(ctx, fileref.ID) + resp, err := FileMetaHandler(ctx, r) if err != nil { - logger.Error("Failed to get commitMetaTxns from refID", zap.Error(err), zap.Any("ref_id", fileref.ID)) - } - fileref.CommitMetaTxns = commitMetaTxns - - collaborators, err := b.packageHandler.GetCollaborators(ctx, fileref.ID) - if err != nil { - logger.Error("Failed to get collaborators from refID", zap.Error(err), zap.Any("ref_id", fileref.ID)) - } - - authTokenString := req.AuthToken - - if (allocationObj.OwnerID != clientID && - allocationObj.PayerID != clientID && - !b.packageHandler.IsACollaborator(ctx, fileref.ID, clientID)) || len(authTokenString) > 0 { - authTicketVerified, err := b.storageHandler.verifyAuthTicket(ctx, req.AuthToken, allocationObj, fileref, clientID) - if err != nil { - return nil, err - } - if !authTicketVerified { - return nil, common.NewError("auth_ticket_verification_failed", "Could not verify the auth ticket.") - } - fileref.Path = "" - } - - var collaboratorsGRPC []*blobbergrpc.Collaborator - for _, c := range collaborators { - collaboratorsGRPC = append(collaboratorsGRPC, convert.CollaboratorToGRPCCollaborator(&c)) + return nil, err } - return &blobbergrpc.GetFileMetaDataResponse{ - MetaData: convert.FileRefToFileRefGRPC(fileref), - Collaborators: collaboratorsGRPC, - }, nil + return convert.GetFileMetaDataResponseCreator(resp), nil } func (b *blobberGRPCService) GetFileStats(ctx context.Context, req *blobbergrpc.GetFileStatsRequest) (*blobbergrpc.GetFileStatsResponse, error) { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 5c5e4f660..1ed390d18 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -8,6 +8,9 @@ import ( "testing" "time" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "google.golang.org/grpc/metadata" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" "google.golang.org/grpc" @@ -110,71 +113,71 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } }) - //t.Run("TestGetFileMetaData", func(t *testing.T) { - // err := tdController.ClearDatabase() - // if err != nil { - // t.Fatal(err) - // } - // err = tdController.AddGetFileMetaDataTestData() - // if err != nil { - // t.Fatal(err) - // } - // - // testCases := []struct { - // name string - // context metadata.MD - // input *blobbergrpc.GetFileMetaDataRequest - // expectedFileName string - // expectingError bool - // }{ - // { - // name: "Success", - // context: metadata.New(map[string]string{ - // common.ClientHeader: "exampleOwnerId", - // }), - // input: &blobbergrpc.GetFileMetaDataRequest{ - // Path: "examplePath", - // PathHash: "exampleId:examplePath", - // Allocation: "exampleTransaction", - // }, - // expectedFileName: "filename", - // expectingError: false, - // }, - // { - // name: "Unknown file path", - // context: metadata.New(map[string]string{ - // common.ClientHeader: "exampleOwnerId", - // }), - // input: &blobbergrpc.GetFileMetaDataRequest{ - // Path: "examplePath", - // PathHash: "exampleId:examplePath123", - // Allocation: "exampleTransaction", - // }, - // expectedFileName: "", - // expectingError: true, - // }, - // } - // - // for _, tc := range testCases { - // ctx := context.Background() - // ctx = metadata.NewOutgoingContext(ctx, tc.context) - // getFileMetaDataResp, err := blobberClient.GetFileMetaData(ctx, tc.input) - // if err != nil { - // if !tc.expectingError { - // t.Fatal(err) - // } - // continue - // } - // - // if tc.expectingError { - // t.Fatal("expected error") - // } - // - // if getFileMetaDataResp.MetaData.FileMetaData.Name != tc.expectedFileName { - // t.Fatal("unexpected file name from GetFileMetaData rpc") - // } - // } - //}) + t.Run("TestGetFileMetaData", func(t *testing.T) { + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetFileMetaDataTestData() + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.GetFileMetaDataRequest + expectedFileName string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + }), + input: &blobbergrpc.GetFileMetaDataRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath", + Allocation: "exampleTransaction", + }, + expectedFileName: "filename", + expectingError: false, + }, + { + name: "Unknown file path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + }), + input: &blobbergrpc.GetFileMetaDataRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath123", + Allocation: "exampleTransaction", + }, + expectedFileName: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getFileMetaDataResp, err := blobberClient.GetFileMetaData(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getFileMetaDataResp.MetaData.FileMetaData.Name != tc.expectedFileName { + t.Fatal("unexpected file name from GetFileMetaData rpc") + } + } + }) // //t.Run("TestGetFileStats", func(t *testing.T) { // diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index 486df77a4..0b19757b0 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -20,87 +20,6 @@ import ( "google.golang.org/grpc/metadata" ) -func TestBlobberGRPCService_GetFileMetaData_Success(t *testing.T) { - req := &blobbergrpc.GetFileMetaDataRequest{ - Path: "path", - PathHash: "path_hash", - AuthToken: "testval", - Allocation: "something", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: "", - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - }, nil) - mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - Type: reference.FILE, - }, nil) - mockReferencePackage.On("GetCommitMetaTxns", mock.Anything, mock.Anything).Return(nil, nil) - mockReferencePackage.On("GetCollaborators", mock.Anything, mock.Anything).Return([]reference.Collaborator{ - reference.Collaborator{ - RefID: 1, - ClientID: "test", - }, - }, nil) - mockReferencePackage.On("IsACollaborator", mock.Anything, mock.Anything, mock.Anything).Return(true) - mockStorageHandler.On("verifyAuthTicket", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(true, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.GetFileMetaData(ctx, req) - if err != nil { - t.Fatal("unexpected error") - } - - assert.Equal(t, resp.MetaData.FileMetaData.Name, "test") -} - -func TestBlobberGRPCService_GetFileMetaData_FileNotExist(t *testing.T) { - req := &blobbergrpc.GetFileMetaDataRequest{ - Path: "path", - PathHash: "path_hash", - AuthToken: "testval", - Allocation: "something", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: "", - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - }, nil) - mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(nil, errors.New("file doesnt exist")) - mockReferencePackage.On("GetCommitMetaTxns", mock.Anything, mock.Anything).Return(nil, nil) - mockReferencePackage.On("GetCollaborators", mock.Anything, mock.Anything).Return([]reference.Collaborator{ - reference.Collaborator{ - RefID: 1, - ClientID: "test", - }, - }, nil) - mockReferencePackage.On("IsACollaborator", mock.Anything, mock.Anything, mock.Anything).Return(true) - mockStorageHandler.On("verifyAuthTicket", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(true, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.GetFileMetaData(ctx, req) - if err == nil { - t.Fatal("expected error") - } -} - func randString(n int) string { const hexLetters = "abcdef0123456789" From 3d3cd2f41bd54e7b1440b47cd5d7a00b085816a4 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 15:29:50 +0530 Subject: [PATCH 115/183] :sparkles: grpc -> http getfilstats --- .../blobbercore/convert/responseHandler.go | 21 +-- .../blobbercore/handler/grpc_handler.go | 50 ++---- .../handler/grpc_handler_integration_test.go | 151 +++++++++--------- .../handler/grpc_handler_unit_test.go | 80 ---------- 4 files changed, 96 insertions(+), 206 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 96f9e75e8..d9811f19c 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -4,6 +4,8 @@ import ( "context" "encoding/json" + stats2 "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" @@ -30,19 +32,18 @@ func GetFileMetaDataResponseCreator(httpResp interface{}) *blobbergrpc.GetFileMe return &resp } -func GetFileStatsResponseHandler(resp *blobbergrpc.GetFileStatsResponse) map[string]interface{} { - ctx := context.Background() - result := FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx) +func GetFileStatsResponseCreator(r interface{}) *blobbergrpc.GetFileStatsResponse { + httpResp, _ := r.(map[string]interface{}) - statsMap := make(map[string]interface{}) - statsBytes, _ := json.Marshal(FileStatsGRPCToFileStats(resp.Stats)) - _ = json.Unmarshal(statsBytes, &statsMap) + var resp blobbergrpc.GetFileStatsResponse + resp.MetaData = FileRefToFileRefGRPC(reference.ListingDataToRef(httpResp)) - for k, v := range statsMap { - result[k] = v - } + respRaw, _ := json.Marshal(httpResp) + var stats stats2.FileStats + _ = json.Unmarshal(respRaw, &stats) + resp.Stats = FileStatsToFileStatsGRPC(&stats) - return result + return &resp } func ListEntitesResponseHandler(resp *blobbergrpc.ListEntitiesResponse) *blobberHTTP.ListResult { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index e0ec3e37f..2b2bb699f 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -64,54 +64,22 @@ func (b *blobberGRPCService) GetFileMetaData(ctx context.Context, req *blobbergr } func (b *blobberGRPCService) GetFileStats(ctx context.Context, req *blobbergrpc.GetFileStatsRequest) (*blobbergrpc.GetFileStatsResponse, error) { - allocationTx := req.Allocation - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, true) - md := GetGRPCMetaDataFromCtx(ctx) - + r, err := http.NewRequest("POST", "", nil) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - allocationID := allocationObj.ID - - valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) - if !valid || err != nil { - return nil, common.NewError("invalid_signature", "Invalid signature") - } - - clientID := md.Client - if len(clientID) == 0 || allocationObj.OwnerID != clientID { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + return nil, err } - - path_hash := req.PathHash - path := req.Path - if len(path_hash) == 0 { - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") - } - path_hash = reference.GetReferenceLookup(allocationID, path) + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "path_hash": {req.PathHash}, } - fileref, err := b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, path_hash) - + resp, err := FileStatsHandler(ctx, r) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid file path. "+err.Error()) - } - - if fileref.Type != reference.FILE { - return nil, common.NewError("invalid_parameters", "Path is not a file.") - } - - stats, _ := b.packageHandler.GetFileStats(ctx, fileref.ID) - wm, _ := b.packageHandler.GetWriteMarkerEntity(ctx, fileref.WriteMarker) - if wm != nil && stats != nil { - stats.WriteMarkerRedeemTxn = wm.CloseTxnID + return nil, err } - return &blobbergrpc.GetFileStatsResponse{ - MetaData: convert.FileRefToFileRefGRPC(fileref), - Stats: convert.FileStatsToFileStatsGRPC(stats), - }, nil + return convert.GetFileStatsResponseCreator(resp), nil } func (b *blobberGRPCService) ListEntities(ctx context.Context, req *blobbergrpc.ListEntitiesRequest) (*blobbergrpc.ListEntitiesResponse, error) { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 1ed390d18..5d99ade75 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -9,6 +9,7 @@ import ( "time" "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "google.golang.org/grpc/metadata" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" @@ -178,81 +179,81 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } } }) - // - //t.Run("TestGetFileStats", func(t *testing.T) { - // - // allocationTx := randString(32) - // - // pubKey, _, signScheme := GeneratePubPrivateKey(t) - // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - // - // err := tdController.ClearDatabase() - // if err != nil { - // t.Fatal(err) - // } - // err = tdController.AddGetFileStatsTestData(allocationTx, pubKey) - // if err != nil { - // t.Fatal(err) - // } - // - // testCases := []struct { - // name string - // context metadata.MD - // input *blobbergrpc.GetFileStatsRequest - // expectedFileName string - // expectingError bool - // }{ - // { - // name: "Success", - // context: metadata.New(map[string]string{ - // common.ClientHeader: "exampleOwnerId", - // common.ClientSignatureHeader: clientSignature, - // }), - // input: &blobbergrpc.GetFileStatsRequest{ - // Path: "examplePath", - // PathHash: "exampleId:examplePath", - // Allocation: allocationTx, - // }, - // expectedFileName: "filename", - // expectingError: false, - // }, - // { - // name: "Unknown Path", - // context: metadata.New(map[string]string{ - // common.ClientHeader: "exampleOwnerId", - // common.ClientSignatureHeader: clientSignature, - // }), - // input: &blobbergrpc.GetFileStatsRequest{ - // Path: "examplePath", - // PathHash: "exampleId:examplePath123", - // Allocation: allocationTx, - // }, - // expectedFileName: "", - // expectingError: true, - // }, - // } - // - // for _, tc := range testCases { - // ctx := context.Background() - // ctx = metadata.NewOutgoingContext(ctx, tc.context) - // getFileStatsResp, err := blobberClient.GetFileStats(ctx, tc.input) - // if err != nil { - // if !tc.expectingError { - // t.Fatal(err) - // } - // continue - // } - // - // if tc.expectingError { - // t.Fatal("expected error") - // } - // - // if getFileStatsResp.MetaData.FileMetaData.Name != tc.expectedFileName { - // t.Fatal("unexpected file name from GetFileStats rpc") - // } - // } - // - //}) + + t.Run("TestGetFileStats", func(t *testing.T) { + + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetFileStatsTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.GetFileStatsRequest + expectedFileName string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetFileStatsRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath", + Allocation: allocationTx, + }, + expectedFileName: "filename", + expectingError: false, + }, + { + name: "Unknown Path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetFileStatsRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath123", + Allocation: allocationTx, + }, + expectedFileName: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getFileStatsResp, err := blobberClient.GetFileStats(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getFileStatsResp.MetaData.FileMetaData.Name != tc.expectedFileName { + t.Fatal("unexpected file name from GetFileStats rpc") + } + } + + }) // //t.Run("TestListEntities", func(t *testing.T) { // allocationTx := randString(32) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index 0b19757b0..92fff7189 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -12,7 +12,6 @@ import ( "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "github.com/stretchr/testify/assert" @@ -31,85 +30,6 @@ func randString(n int) string { return sb.String() } -func TestBlobberGRPCService_GetFileStats_Success(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.GetFileStatsRequest{ - Path: "path", - PathHash: "path_hash", - Allocation: allocationTx, - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "owner", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: clientSignature, - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", - OwnerPublicKey: pubKey, - }, nil) - mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - ID: 123, - Name: "test", - Type: reference.FILE, - }, nil) - mockReferencePackage.On("GetFileStats", mock.Anything, int64(123)).Return(&stats.FileStats{ - NumBlockDownloads: 10, - }, nil) - mockReferencePackage.On("GetWriteMarkerEntity", mock.Anything, mock.Anything).Return(nil, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.GetFileStats(ctx, req) - if err != nil { - t.Fatal("unexpected error") - } - - assert.Equal(t, resp.MetaData.FileMetaData.Name, "test") - assert.Equal(t, resp.Stats.NumBlockDownloads, int64(10)) -} - -func TestBlobberGRPCService_GetFileStats_FileNotExist(t *testing.T) { - req := &blobbergrpc.GetFileStatsRequest{ - Path: "path", - PathHash: "path_hash", - Allocation: "", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "owner", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: "", - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", - }, nil) - mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(nil, errors.New("file does not exist")) - mockReferencePackage.On("GetFileStats", mock.Anything, int64(123)).Return(&stats.FileStats{ - NumBlockDownloads: 10, - }, nil) - mockReferencePackage.On("GetWriteMarkerEntity", mock.Anything, mock.Anything).Return(nil, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.GetFileStats(ctx, req) - if err == nil { - t.Fatal("expected error") - } -} - func TestBlobberGRPCService_ListEntities_Success(t *testing.T) { req := &blobbergrpc.ListEntitiesRequest{ Path: "path", From d14d66135e00b8bdccb7557a61fd78ccc1812f3b Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 15:39:49 +0530 Subject: [PATCH 116/183] :sparkles: grpc -> http listentities --- .../blobbercore/convert/responseHandler.go | 19 +-- .../blobbercore/handler/grpc_handler.go | 69 ++------ .../handler/grpc_handler_integration_test.go | 154 +++++++++--------- .../handler/grpc_handler_unit_test.go | 79 --------- 4 files changed, 96 insertions(+), 225 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index d9811f19c..f6bb02180 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -46,18 +46,17 @@ func GetFileStatsResponseCreator(r interface{}) *blobbergrpc.GetFileStatsRespons return &resp } -func ListEntitesResponseHandler(resp *blobbergrpc.ListEntitiesResponse) *blobberHTTP.ListResult { - ctx := context.Background() - var entities []map[string]interface{} - for i := range resp.Entities { - entities = append(entities, FileRefGRPCToFileRef(resp.Entities[i]).GetListingData(ctx)) - } +func ListEntitesResponseCreator(r interface{}) *blobbergrpc.ListEntitiesResponse { + httpResp, _ := r.(*blobberHTTP.ListResult) - return &blobberHTTP.ListResult{ - AllocationRoot: resp.AllocationRoot, - Meta: FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx), - Entities: entities, + var resp blobbergrpc.ListEntitiesResponse + for i := range httpResp.Entities { + resp.Entities = append(resp.Entities, FileRefToFileRefGRPC(reference.ListingDataToRef(httpResp.Entities[i]))) } + + resp.MetaData = FileRefToFileRefGRPC(reference.ListingDataToRef(httpResp.Meta)) + resp.AllocationRoot = httpResp.AllocationRoot + return &resp } func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetReferencePathResponse) *blobberHTTP.ReferencePathResult { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 2b2bb699f..45993ba25 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -11,7 +11,6 @@ import ( "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" "github.com/0chain/blobber/code/go/0chain.net/core/common" - "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap/ctxzap" ) type blobberGRPCService struct { @@ -83,71 +82,23 @@ func (b *blobberGRPCService) GetFileStats(ctx context.Context, req *blobbergrpc. } func (b *blobberGRPCService) ListEntities(ctx context.Context, req *blobbergrpc.ListEntitiesRequest) (*blobbergrpc.ListEntitiesResponse, error) { - logger := ctxzap.Extract(ctx) - md := GetGRPCMetaDataFromCtx(ctx) - - clientID := md.Client - allocationTx := req.Allocation - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, true) - + r, err := http.NewRequest("", "", nil) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - allocationID := allocationObj.ID - - if len(clientID) == 0 { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") - } - - path_hash := req.PathHash - path := req.Path - if len(path_hash) == 0 { - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") - } - path_hash = reference.GetReferenceLookup(allocationID, path) - } - - logger.Info("Path Hash for list dir :" + path_hash) - - fileref, err := b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, path_hash) - if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid path. "+err.Error()) + return nil, err } - authTokenString := req.AuthToken - if clientID != allocationObj.OwnerID || len(authTokenString) > 0 { - authTicketVerified, err := b.storageHandler.verifyAuthTicket(ctx, authTokenString, allocationObj, fileref, clientID) - if err != nil { - return nil, err - } - if !authTicketVerified { - return nil, common.NewError("auth_ticket_verification_failed", "Could not verify the auth ticket.") - } + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "path_hash": {req.PathHash}, + "auth_token": {req.AuthToken}, } - dirref, err := b.packageHandler.GetRefWithChildren(ctx, allocationID, fileref.Path) + resp, err := ListHandler(ctx, r) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid path. "+err.Error()) - } - - if clientID != allocationObj.OwnerID { - dirref.Path = "" - } - - var entities []*blobbergrpc.FileRef - for _, entity := range dirref.Children { - if clientID != allocationObj.OwnerID { - entity.Path = "" - } - entities = append(entities, convert.FileRefToFileRefGRPC(entity)) + return nil, err } - refGRPC := convert.FileRefToFileRefGRPC(dirref) - return &blobbergrpc.ListEntitiesResponse{ - AllocationRoot: allocationObj.AllocationRoot, - MetaData: refGRPC, - Entities: entities, - }, nil + return convert.ListEntitesResponseCreator(resp), nil } func (b *blobberGRPCService) GetObjectPath(ctx context.Context, req *blobbergrpc.GetObjectPathRequest) (*blobbergrpc.GetObjectPathResponse, error) { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 5d99ade75..fd6943922 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -254,83 +254,83 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } }) - // - //t.Run("TestListEntities", func(t *testing.T) { - // allocationTx := randString(32) - // - // pubKey, _, signScheme := GeneratePubPrivateKey(t) - // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - // - // err := tdController.ClearDatabase() - // if err != nil { - // t.Fatal(err) - // } - // err = tdController.AddListEntitiesTestData(allocationTx, pubKey) - // if err != nil { - // t.Fatal(err) - // } - // - // testCases := []struct { - // name string - // context metadata.MD - // input *blobbergrpc.ListEntitiesRequest - // expectedPath string - // expectingError bool - // }{ - // { - // name: "Success", - // context: metadata.New(map[string]string{ - // common.ClientHeader: "exampleOwnerId", - // common.ClientSignatureHeader: clientSignature, - // }), - // input: &blobbergrpc.ListEntitiesRequest{ - // Path: "examplePath", - // PathHash: "exampleId:examplePath", - // AuthToken: "", - // Allocation: allocationTx, - // }, - // expectedPath: "examplePath", - // expectingError: false, - // }, - // { - // name: "bad path", - // context: metadata.New(map[string]string{ - // common.ClientHeader: "exampleOwnerId", - // common.ClientSignatureHeader: clientSignature, - // }), - // input: &blobbergrpc.ListEntitiesRequest{ - // Path: "examplePath", - // PathHash: "exampleId:examplePath123", - // AuthToken: "", - // Allocation: allocationTx, - // }, - // expectedPath: "", - // expectingError: true, - // }, - // } - // - // for _, tc := range testCases { - // ctx := context.Background() - // ctx = metadata.NewOutgoingContext(ctx, tc.context) - // listEntitiesResp, err := blobberClient.ListEntities(ctx, tc.input) - // if err != nil { - // if !tc.expectingError { - // t.Fatal(err) - // } - // continue - // } - // - // if tc.expectingError { - // t.Fatal("expected error") - // } - // - // if listEntitiesResp.MetaData.DirMetaData.Path != tc.expectedPath { - // t.Fatal("unexpected path from ListEntities rpc") - // } - // } - // - //}) - // + + t.Run("TestListEntities", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddListEntitiesTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.ListEntitiesRequest + expectedPath string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.ListEntitiesRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: allocationTx, + }, + expectedPath: "examplePath", + expectingError: false, + }, + { + name: "bad path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.ListEntitiesRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath123", + AuthToken: "", + Allocation: allocationTx, + }, + expectedPath: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + listEntitiesResp, err := blobberClient.ListEntities(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if listEntitiesResp.MetaData.DirMetaData.Path != tc.expectedPath { + t.Fatal("unexpected path from ListEntities rpc") + } + } + + }) + //t.Run("TestGetObjectPath", func(t *testing.T) { // allocationTx := randString(32) // diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index 92fff7189..15e858b2b 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -30,85 +30,6 @@ func randString(n int) string { return sb.String() } -func TestBlobberGRPCService_ListEntities_Success(t *testing.T) { - req := &blobbergrpc.ListEntitiesRequest{ - Path: "path", - PathHash: "path_hash", - AuthToken: "something", - Allocation: "", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: "", - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", - AllocationRoot: "/allocationroot", - }, nil) - mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - Type: reference.FILE, - }, nil) - mockStorageHandler.On("verifyAuthTicket", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(true, nil) - mockReferencePackage.On("GetRefWithChildren", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - Type: reference.DIRECTORY, - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.ListEntities(ctx, req) - if err != nil { - t.Fatal("unexpected error") - } - - assert.Equal(t, resp.AllocationRoot, "/allocationroot") -} - -func TestBlobberGRPCService_ListEntities_InvalidAuthTicket(t *testing.T) { - req := &blobbergrpc.ListEntitiesRequest{ - Path: "path", - PathHash: "path_hash", - AuthToken: "something", - Allocation: "", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: "", - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", - }, nil) - mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - Type: reference.FILE, - }, nil) - mockStorageHandler.On("verifyAuthTicket", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(false, nil) - mockReferencePackage.On("GetRefWithChildren", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - Type: reference.DIRECTORY, - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.ListEntities(ctx, req) - if err == nil { - t.Fatal("expected error") - } -} - func TestBlobberGRPCService_GetObjectPath_Success(t *testing.T) { allocationTx := randString(32) From 17356e0c0c3441ce25bda1ab1305ed508a06dbfd Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 16:25:29 +0530 Subject: [PATCH 117/183] :sparkles: grpc -> http objectpath --- .../blobbercore/convert/responseHandler.go | 53 ++-- .../blobbercore/handler/grpc_handler.go | 71 +----- .../handler/grpc_handler_integration_test.go | 234 +++++++++--------- .../handler/grpc_handler_unit_test.go | 70 ------ 4 files changed, 162 insertions(+), 266 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index f6bb02180..c1a057c30 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -1,7 +1,6 @@ package convert import ( - "context" "encoding/json" stats2 "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" @@ -15,11 +14,19 @@ import ( ) func GetAllocationResponseCreator(resp interface{}) *blobbergrpc.GetAllocationResponse { + if resp == nil { + return nil + } + alloc, _ := resp.(*allocation.Allocation) return &blobbergrpc.GetAllocationResponse{Allocation: AllocationToGRPCAllocation(alloc)} } func GetFileMetaDataResponseCreator(httpResp interface{}) *blobbergrpc.GetFileMetaDataResponse { + if httpResp == nil { + return nil + } + r, _ := httpResp.(map[string]interface{}) var resp blobbergrpc.GetFileMetaDataResponse @@ -33,6 +40,10 @@ func GetFileMetaDataResponseCreator(httpResp interface{}) *blobbergrpc.GetFileMe } func GetFileStatsResponseCreator(r interface{}) *blobbergrpc.GetFileStatsResponse { + if r == nil { + return nil + } + httpResp, _ := r.(map[string]interface{}) var resp blobbergrpc.GetFileStatsResponse @@ -47,6 +58,10 @@ func GetFileStatsResponseCreator(r interface{}) *blobbergrpc.GetFileStatsRespons } func ListEntitesResponseCreator(r interface{}) *blobbergrpc.ListEntitiesResponse { + if r == nil { + return nil + } + httpResp, _ := r.(*blobberHTTP.ListResult) var resp blobbergrpc.ListEntitiesResponse @@ -67,24 +82,30 @@ func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetRe } } -func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPathResponse) *blobberHTTP.ObjectPathResult { - ctx := context.Background() - path := FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Path).GetListingData(ctx) - var pathList []map[string]interface{} - for _, pl := range getObjectPathResponse.ObjectPath.PathList { - pathList = append(pathList, FileRefGRPCToFileRef(pl).GetListingData(ctx)) +func GetObjectPathResponseCreator(r interface{}) *blobbergrpc.GetObjectPathResponse { + if r == nil { + return nil } - path["list"] = pathList - return &blobberHTTP.ObjectPathResult{ - ObjectPath: &reference.ObjectPath{ - RootHash: getObjectPathResponse.ObjectPath.RootHash, - Meta: FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Meta).GetListingData(ctx), - Path: path, - FileBlockNum: getObjectPathResponse.ObjectPath.FileBlockNum, - }, - LatestWM: WriteMarkerGRPCToWriteMarker(getObjectPathResponse.LatestWriteMarker), + httpResp, _ := r.(*blobberHTTP.ObjectPathResult) + var resp blobbergrpc.GetObjectPathResponse + + var pathList []*blobbergrpc.FileRef + pl, _ := httpResp.Path["list"].([]map[string]interface{}) + for _, v := range pl { + pathList = append(pathList, FileRefToFileRefGRPC(reference.ListingDataToRef(v))) } + + resp.LatestWriteMarker = WriteMarkerToWriteMarkerGRPC(httpResp.LatestWM) + resp.ObjectPath = &blobbergrpc.ObjectPath{ + RootHash: httpResp.RootHash, + Meta: FileRefToFileRefGRPC(reference.ListingDataToRef(httpResp.Meta)), + Path: FileRefToFileRefGRPC(reference.ListingDataToRef(httpResp.Path)), + PathList: pathList, + FileBlockNum: httpResp.FileBlockNum, + } + + return &resp } func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTreeResponse) *blobberHTTP.ReferencePathResult { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 45993ba25..94e31493a 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -4,7 +4,6 @@ import ( "context" "encoding/json" "net/http" - "strconv" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" @@ -102,76 +101,22 @@ func (b *blobberGRPCService) ListEntities(ctx context.Context, req *blobbergrpc. } func (b *blobberGRPCService) GetObjectPath(ctx context.Context, req *blobbergrpc.GetObjectPathRequest) (*blobbergrpc.GetObjectPathResponse, error) { - allocationTx := req.Allocation - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) - md := GetGRPCMetaDataFromCtx(ctx) - + r, err := http.NewRequest("", "", nil) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - allocationID := allocationObj.ID - - valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) - if !valid || err != nil { - return nil, common.NewError("invalid_signature", "Invalid signature") - } - - clientID := md.Client - if len(clientID) == 0 || allocationObj.OwnerID != clientID { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") - } - path := req.Path - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") - } - - blockNumStr := req.BlockNum - if len(blockNumStr) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") + return nil, err } - - blockNum, err := strconv.ParseInt(blockNumStr, 10, 64) - if err != nil || blockNum < 0 { - return nil, common.NewError("invalid_parameters", "Invalid block number") + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "block_num": {req.BlockNum}, } - objectPath, err := b.packageHandler.GetObjectPath(ctx, allocationID, blockNum) + resp, err := ObjectPathHandler(ctx, r) if err != nil { return nil, err } - var latestWM *writemarker.WriteMarkerEntity - if len(allocationObj.AllocationRoot) == 0 { - latestWM = nil - } else { - latestWM, err = b.packageHandler.GetWriteMarkerEntity(ctx, allocationObj.AllocationRoot) - if err != nil { - return nil, common.NewError("latest_write_marker_read_error", "Error reading the latest write marker for allocation."+err.Error()) - } - } - var latestWriteMarketGRPC *blobbergrpc.WriteMarker - if latestWM != nil { - latestWriteMarketGRPC = convert.WriteMarkerToWriteMarkerGRPC(&latestWM.WM) - } - - pathList := make([]*blobbergrpc.FileRef, 0) - list, _ := objectPath.Path["list"].([]map[string]interface{}) - if len(list) > 0 { - for _, pl := range list { - pathList = append(pathList, convert.FileRefToFileRefGRPC(reference.ListingDataToRef(pl))) - } - } - - return &blobbergrpc.GetObjectPathResponse{ - ObjectPath: &blobbergrpc.ObjectPath{ - RootHash: objectPath.RootHash, - Meta: convert.FileRefToFileRefGRPC(reference.ListingDataToRef(objectPath.Meta)), - Path: convert.FileRefToFileRefGRPC(reference.ListingDataToRef(objectPath.Path)), - PathList: pathList, - FileBlockNum: objectPath.FileBlockNum, - }, - LatestWriteMarker: latestWriteMarketGRPC, - }, nil + return convert.GetObjectPathResponseCreator(resp), nil } func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobbergrpc.GetReferencePathRequest) (*blobbergrpc.GetReferencePathResponse, error) { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index fd6943922..e1169a4e1 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -331,123 +331,123 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { }) - //t.Run("TestGetObjectPath", func(t *testing.T) { - // allocationTx := randString(32) - // - // pubKey, _, signScheme := GeneratePubPrivateKey(t) - // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - // - // err := tdController.ClearDatabase() - // if err != nil { - // t.Fatal(err) - // } - // err = tdController.AddGetObjectPathTestData(allocationTx, pubKey) - // if err != nil { - // t.Fatal(err) - // } - // - // testCases := []struct { - // name string - // context metadata.MD - // input *blobbergrpc.GetObjectPathRequest - // expectedPath string - // expectingError bool - // }{ - // { - // name: "Success", - // context: metadata.New(map[string]string{ - // common.ClientHeader: "exampleOwnerId", - // common.ClientSignatureHeader: clientSignature, - // }), - // input: &blobbergrpc.GetObjectPathRequest{ - // Allocation: allocationTx, - // Path: "examplePath", - // BlockNum: "0", - // }, - // expectedPath: "/", - // expectingError: false, - // }, - // } - // - // for _, tc := range testCases { - // ctx := context.Background() - // ctx = metadata.NewOutgoingContext(ctx, tc.context) - // getObjectPathResp, err := blobberClient.GetObjectPath(ctx, tc.input) - // if err != nil { - // if !tc.expectingError { - // t.Fatal(err) - // } - // continue - // } - // - // if tc.expectingError { - // t.Fatal("expected error") - // } - // - // if getObjectPathResp.ObjectPath.Path.DirMetaData.Path != tc.expectedPath { - // t.Fatal("unexpected root hash from GetObjectPath rpc") - // } - // } - //}) - // - //t.Run("TestGetReferencePath", func(t *testing.T) { - // allocationTx := randString(32) - // - // pubKey, _, signScheme := GeneratePubPrivateKey(t) - // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - // - // err := tdController.ClearDatabase() - // if err != nil { - // t.Fatal(err) - // } - // err = tdController.AddGetReferencePathTestData(allocationTx, pubKey) - // if err != nil { - // t.Fatal(err) - // } - // - // testCases := []struct { - // name string - // context metadata.MD - // input *blobbergrpc.GetReferencePathRequest - // expectedPath string - // expectingError bool - // }{ - // { - // name: "Success", - // context: metadata.New(map[string]string{ - // common.ClientHeader: "exampleOwnerId", - // common.ClientSignatureHeader: clientSignature, - // }), - // input: &blobbergrpc.GetReferencePathRequest{ - // Paths: "", - // Path: "/", - // Allocation: allocationTx, - // }, - // expectedPath: "/", - // expectingError: false, - // }, - // } - // - // for _, tc := range testCases { - // ctx := context.Background() - // ctx = metadata.NewOutgoingContext(ctx, tc.context) - // getReferencePathResp, err := blobberClient.GetReferencePath(ctx, tc.input) - // if err != nil { - // if !tc.expectingError { - // t.Fatal(err) - // } - // continue - // } - // - // if tc.expectingError { - // t.Fatal("expected error") - // } - // - // if getReferencePathResp.ReferencePath.MetaData.DirMetaData.Path != tc.expectedPath { - // t.Fatal("unexpected path from GetReferencePath rpc") - // } - // } - //}) + t.Run("TestGetObjectPath", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetObjectPathTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.GetObjectPathRequest + expectedPath string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetObjectPathRequest{ + Allocation: allocationTx, + Path: "examplePath", + BlockNum: "0", + }, + expectedPath: "/", + expectingError: false, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getObjectPathResp, err := blobberClient.GetObjectPath(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getObjectPathResp.ObjectPath.Path.DirMetaData.Path != tc.expectedPath { + t.Fatal("unexpected root hash from GetObjectPath rpc") + } + } + }) + + t.Run("TestGetReferencePath", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetReferencePathTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.GetReferencePathRequest + expectedPath string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetReferencePathRequest{ + Paths: "", + Path: "/", + Allocation: allocationTx, + }, + expectedPath: "/", + expectingError: false, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getReferencePathResp, err := blobberClient.GetReferencePath(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getReferencePathResp.ReferencePath.MetaData.DirMetaData.Path != tc.expectedPath { + t.Fatal("unexpected path from GetReferencePath rpc") + } + } + }) // //t.Run("TestGetObjectTree", func(t *testing.T) { // allocationTx := randString(32) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index 15e858b2b..e76722781 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -30,76 +30,6 @@ func randString(n int) string { return sb.String() } -func TestBlobberGRPCService_GetObjectPath_Success(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.GetObjectPathRequest{ - Allocation: allocationTx, - Path: "path", - BlockNum: "120", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "owner", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: clientSignature, - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", - OwnerPublicKey: pubKey, - }, nil) - mockReferencePackage.On("GetObjectPath", mock.Anything, mock.Anything, mock.Anything).Return(&reference.ObjectPath{ - RootHash: "hash", - FileBlockNum: 120, - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.GetObjectPath(ctx, req) - if err != nil { - t.Fatal("unexpected error") - } - - assert.Equal(t, resp.ObjectPath.RootHash, "hash") - assert.Equal(t, resp.ObjectPath.FileBlockNum, int64(120)) - -} - -func TestBlobberGRPCService_GetObjectPath_InvalidAllocation(t *testing.T) { - req := &blobbergrpc.GetObjectPathRequest{ - Allocation: "", - Path: "path", - BlockNum: "120", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "owner", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: "", - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(nil, errors.New("invalid allocation")) - mockReferencePackage.On("GetObjectPathGRPC", mock.Anything, mock.Anything, mock.Anything).Return(&blobbergrpc.ObjectPath{ - RootHash: "hash", - FileBlockNum: 120, - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.GetObjectPath(ctx, req) - if err == nil { - t.Fatal("expected error") - } -} - func TestBlobberGRPCService_GetReferencePath_Success(t *testing.T) { allocationTx := randString(32) From 15cb22c91364b95f109915ed51b912b0e6ae97ac Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 16:38:34 +0530 Subject: [PATCH 118/183] :sparkles: grpc -> http referencePath --- .../blobbercore/convert/responseHandler.go | 16 ++-- .../blobbercore/handler/grpc_handler.go | 74 ++--------------- .../handler/grpc_handler_unit_test.go | 81 ------------------- 3 files changed, 19 insertions(+), 152 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index c1a057c30..47a586185 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -74,12 +74,18 @@ func ListEntitesResponseCreator(r interface{}) *blobbergrpc.ListEntitiesResponse return &resp } -func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetReferencePathResponse) *blobberHTTP.ReferencePathResult { - var recursionCount int - return &blobberHTTP.ReferencePathResult{ - ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getReferencePathResponse.ReferencePath), - LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWM), +func GetReferencePathResponseCreator(r interface{}) *blobbergrpc.GetReferencePathResponse { + if r == nil { + return nil } + + httpResp, _ := r.(*blobberHTTP.ReferencePathResult) + var resp blobbergrpc.GetReferencePathResponse + + var recursionCount int + resp.LatestWM = WriteMarkerToWriteMarkerGRPC(httpResp.LatestWM) + resp.ReferencePath = ReferencePathToReferencePathGRPC(&recursionCount, httpResp.ReferencePath) + return &resp } func GetObjectPathResponseCreator(r interface{}) *blobbergrpc.GetObjectPathResponse { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 94e31493a..4ae994ad2 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -120,80 +120,22 @@ func (b *blobberGRPCService) GetObjectPath(ctx context.Context, req *blobbergrpc } func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobbergrpc.GetReferencePathRequest) (*blobbergrpc.GetReferencePathResponse, error) { - md := GetGRPCMetaDataFromCtx(ctx) - allocationTx := req.Allocation - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) - + r, err := http.NewRequest("", "", nil) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - allocationID := allocationObj.ID - - valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) - if !valid || err != nil { - return nil, common.NewError("invalid_signature", "Invalid signature") - } - - clientID := md.Client - if len(clientID) == 0 { - return nil, common.NewError("invalid_operation", "Please pass clientID in the header") + return nil, err } - - var paths []string - pathsString := req.Paths - if len(pathsString) == 0 { - path := req.Path - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") - } - paths = append(paths, path) - } else { - err = json.Unmarshal([]byte(pathsString), &paths) - if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid path array json") - } + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "paths": {req.Paths}, } - rootRef, err := b.packageHandler.GetReferencePathFromPaths(ctx, allocationID, paths) + resp, err := ReferencePathHandler(ctx, r) if err != nil { return nil, err } - refPath := &reference.ReferencePath{Ref: rootRef} - refsToProcess := make([]*reference.ReferencePath, 0) - refsToProcess = append(refsToProcess, refPath) - for len(refsToProcess) > 0 { - refToProcess := refsToProcess[0] - refToProcess.Meta = refToProcess.Ref.GetListingData(ctx) - if len(refToProcess.Ref.Children) > 0 { - refToProcess.List = make([]*reference.ReferencePath, len(refToProcess.Ref.Children)) - } - for idx, child := range refToProcess.Ref.Children { - childRefPath := &reference.ReferencePath{Ref: child} - refToProcess.List[idx] = childRefPath - refsToProcess = append(refsToProcess, childRefPath) - } - refsToProcess = refsToProcess[1:] - } - - var latestWM *writemarker.WriteMarkerEntity - if len(allocationObj.AllocationRoot) == 0 { - latestWM = nil - } else { - latestWM, err = writemarker.GetWriteMarkerEntity(ctx, allocationObj.AllocationRoot) - if err != nil { - return nil, common.NewError("latest_write_marker_read_error", "Error reading the latest write marker for allocation."+err.Error()) - } - } - - var refPathResult blobbergrpc.GetReferencePathResponse - var recursionCount int - refPathResult.ReferencePath = convert.ReferencePathToReferencePathGRPC(&recursionCount, refPath) - if latestWM != nil { - refPathResult.LatestWM = convert.WriteMarkerToWriteMarkerGRPC(&latestWM.WM) - } - - return &refPathResult, nil + return convert.GetReferencePathResponseCreator(resp), nil } func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc.GetObjectTreeRequest) (*blobbergrpc.GetObjectTreeResponse, error) { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index e76722781..f9fdce8af 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -2,7 +2,6 @@ package handler import ( "context" - "errors" "math/rand" "net/http" "strings" @@ -30,86 +29,6 @@ func randString(n int) string { return sb.String() } -func TestBlobberGRPCService_GetReferencePath_Success(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.GetReferencePathRequest{ - Paths: `["something"]`, - Path: "", - Allocation: allocationTx, - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: clientSignature, - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", - OwnerPublicKey: pubKey, - }, nil) - mockReferencePackage.On("GetReferencePathFromPaths", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - Type: reference.DIRECTORY, - Children: []*reference.Ref{{Name: "test1", Type: reference.FILE}}, - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.GetReferencePath(ctx, req) - if err != nil { - t.Fatal("unexpected error") - } - - assert.Equal(t, resp.ReferencePath.MetaData.DirMetaData.Name, "test") - -} - -func TestBlobberGRPCService_GetReferencePath_InvalidPaths(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.GetReferencePathRequest{ - Paths: `["something"]`, - Path: "", - Allocation: allocationTx, - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: clientSignature, - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", - OwnerPublicKey: pubKey, - }, nil) - mockReferencePackage.On("GetReferencePathFromPaths", mock.Anything, mock.Anything, mock.Anything).Return(nil, errors.New("invalid paths")) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.GetReferencePath(ctx, req) - if err == nil { - t.Fatal("expected error") - } - - assert.Equal(t, err.Error(), "invalid paths") - -} - func TestBlobberGRPCService_GetObjectTree_Success(t *testing.T) { allocationTx := randString(32) From 9f12e10fa7261b1cd1f0b40b8daddd7022434fd4 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 16:46:53 +0530 Subject: [PATCH 119/183] :sparkles: grpc -> http objecttree --- .../blobbercore/convert/responseHandler.go | 22 +- .../blobbercore/handler/grpc_handler.go | 61 +- .../handler/grpc_handler_integration_test.go | 566 +++++++++--------- .../handler/grpc_handler_unit_test.go | 68 --- 4 files changed, 307 insertions(+), 410 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 47a586185..555ba1790 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -88,6 +88,20 @@ func GetReferencePathResponseCreator(r interface{}) *blobbergrpc.GetReferencePat return &resp } +func GetObjectTreeResponseCreator(r interface{}) *blobbergrpc.GetObjectTreeResponse { + if r == nil { + return nil + } + + httpResp, _ := r.(*blobberHTTP.ReferencePathResult) + var resp blobbergrpc.GetObjectTreeResponse + + var recursionCount int + resp.LatestWM = WriteMarkerToWriteMarkerGRPC(httpResp.LatestWM) + resp.ReferencePath = ReferencePathToReferencePathGRPC(&recursionCount, httpResp.ReferencePath) + return &resp +} + func GetObjectPathResponseCreator(r interface{}) *blobbergrpc.GetObjectPathResponse { if r == nil { return nil @@ -114,14 +128,6 @@ func GetObjectPathResponseCreator(r interface{}) *blobbergrpc.GetObjectPathRespo return &resp } -func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTreeResponse) *blobberHTTP.ReferencePathResult { - var recursionCount int - return &blobberHTTP.ReferencePathResult{ - ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getObjectTreeResponse.ReferencePath), - LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), - } -} - func CommitWriteResponseHandler(resp *blobbergrpc.CommitResponse) *blobberHTTP.CommitResult { return &blobberHTTP.CommitResult{ AllocationRoot: resp.AllocationRoot, diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 4ae994ad2..71533b4c7 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -8,7 +8,6 @@ import ( "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" "github.com/0chain/blobber/code/go/0chain.net/core/common" ) @@ -139,67 +138,21 @@ func (b *blobberGRPCService) GetReferencePath(ctx context.Context, req *blobberg } func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc.GetObjectTreeRequest) (*blobbergrpc.GetObjectTreeResponse, error) { - allocationTx := req.Allocation - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) - md := GetGRPCMetaDataFromCtx(ctx) - + r, err := http.NewRequest("", "", nil) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - allocationID := allocationObj.ID - - valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) - if !valid || err != nil { - return nil, common.NewError("invalid_signature", "Invalid signature") - } - - clientID := md.Client - if len(clientID) == 0 || allocationObj.OwnerID != clientID { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + return nil, err } - path := req.Path - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, } - rootRef, err := b.packageHandler.GetObjectTree(ctx, allocationID, path) + resp, err := ObjectTreeHandler(ctx, r) if err != nil { return nil, err } - refPath := &reference.ReferencePath{Ref: rootRef} - refsToProcess := make([]*reference.ReferencePath, 0) - refsToProcess = append(refsToProcess, refPath) - for len(refsToProcess) > 0 { - refToProcess := refsToProcess[0] - refToProcess.Meta = refToProcess.Ref.GetListingData(ctx) - if len(refToProcess.Ref.Children) > 0 { - refToProcess.List = make([]*reference.ReferencePath, len(refToProcess.Ref.Children)) - } - for idx, child := range refToProcess.Ref.Children { - childRefPath := &reference.ReferencePath{Ref: child} - refToProcess.List[idx] = childRefPath - refsToProcess = append(refsToProcess, childRefPath) - } - refsToProcess = refsToProcess[1:] - } - - var latestWM *writemarker.WriteMarkerEntity - if len(allocationObj.AllocationRoot) == 0 { - latestWM = nil - } else { - latestWM, err = writemarker.GetWriteMarkerEntity(ctx, allocationObj.AllocationRoot) - if err != nil { - return nil, common.NewError("latest_write_marker_read_error", "Error reading the latest write marker for allocation."+err.Error()) - } - } - var refPathResult blobbergrpc.GetObjectTreeResponse - var recursionCount int - refPathResult.ReferencePath = convert.ReferencePathToReferencePathGRPC(&recursionCount, refPath) - if latestWM != nil { - refPathResult.LatestWM = convert.WriteMarkerToWriteMarkerGRPC(&latestWM.WM) - } - return &refPathResult, nil + return convert.GetObjectTreeResponseCreator(resp), nil } func (b *blobberGRPCService) CalculateHash(ctx context.Context, req *blobbergrpc.CalculateHashRequest) (*blobbergrpc.CalculateHashResponse, error) { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index e1169a4e1..7f37ade0d 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -2,12 +2,18 @@ package handler import ( "context" + "encoding/hex" "fmt" "log" + "net/http" "os" + "strconv" "testing" "time" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/0chain/blobber/code/go/0chain.net/core/encryption" "google.golang.org/grpc/metadata" @@ -448,79 +454,79 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } } }) - // - //t.Run("TestGetObjectTree", func(t *testing.T) { - // allocationTx := randString(32) - // - // pubKey, _, signScheme := GeneratePubPrivateKey(t) - // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - // - // err := tdController.ClearDatabase() - // if err != nil { - // t.Fatal(err) - // } - // err = tdController.AddGetObjectTreeTestData(allocationTx, pubKey) - // if err != nil { - // t.Fatal(err) - // } - // - // testCases := []struct { - // name string - // context metadata.MD - // input *blobbergrpc.GetObjectTreeRequest - // expectedFileName string - // expectingError bool - // }{ - // { - // name: "Success", - // context: metadata.New(map[string]string{ - // common.ClientHeader: "exampleOwnerId", - // common.ClientSignatureHeader: clientSignature, - // }), - // input: &blobbergrpc.GetObjectTreeRequest{ - // Path: "/", - // Allocation: allocationTx, - // }, - // expectedFileName: "root", - // expectingError: false, - // }, - // { - // name: "bad path", - // context: metadata.New(map[string]string{ - // common.ClientHeader: "exampleOwnerId", - // common.ClientSignatureHeader: clientSignature, - // }), - // input: &blobbergrpc.GetObjectTreeRequest{ - // Path: "/2", - // Allocation: "", - // }, - // expectedFileName: "root", - // expectingError: true, - // }, - // } - // - // for _, tc := range testCases { - // ctx := context.Background() - // ctx = metadata.NewOutgoingContext(ctx, tc.context) - // getObjectTreeResp, err := blobberClient.GetObjectTree(ctx, tc.input) - // if err != nil { - // if !tc.expectingError { - // t.Fatal(err) - // } - // continue - // } - // - // if tc.expectingError { - // t.Fatal("expected error") - // } - // - // if getObjectTreeResp.ReferencePath.MetaData.DirMetaData.Name != tc.expectedFileName { - // t.Fatal("unexpected root name from GetObject") - // } - // } - // - //}) - // + + t.Run("TestGetObjectTree", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetObjectTreeTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.GetObjectTreeRequest + expectedFileName string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetObjectTreeRequest{ + Path: "/", + Allocation: allocationTx, + }, + expectedFileName: "root", + expectingError: false, + }, + { + name: "bad path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetObjectTreeRequest{ + Path: "/2", + Allocation: "", + }, + expectedFileName: "root", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getObjectTreeResp, err := blobberClient.GetObjectTree(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getObjectTreeResp.ReferencePath.MetaData.DirMetaData.Name != tc.expectedFileName { + t.Fatal("unexpected root name from GetObject") + } + } + + }) + //t.Run("TestCommit", func(t *testing.T) { // allocationTx := randString(32) // @@ -635,211 +641,211 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { // } // } //}) - // - //t.Run("TestCommitMetaTxn", func(t *testing.T) { - // allocationTx := randString(32) - // - // pubKey, _, signScheme := GeneratePubPrivateKey(t) - // pubKeyBytes, _ := hex.DecodeString(pubKey) - // clientId := encryption.Hash(pubKeyBytes) - // now := common.Timestamp(time.Now().UnixNano()) - // - // blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" - // blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) - // - // fr := reference.Ref{ - // AllocationID: "exampleId", - // } - // - // rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) - // - // wm := writemarker.WriteMarker{ - // AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), - // PreviousAllocationRoot: "/", - // AllocationID: "exampleId", - // Size: 1337, - // BlobberID: encryption.Hash(blobberPubKeyBytes), - // Timestamp: now, - // ClientID: clientId, - // } - // - // wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) - // if err != nil { - // t.Fatal(err) - // } - // - // wm.Signature = wmSig - // - // if err := tdController.ClearDatabase(); err != nil { - // t.Fatal(err) - // } - // if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { - // t.Fatal(err) - // } - // - // testCases := []struct { - // name string - // context metadata.MD - // input *blobbergrpc.CommitMetaTxnRequest - // expectedMessage string - // expectingError bool - // }{ - // { - // name: "Success", - // context: metadata.New(map[string]string{ - // common.ClientHeader: clientId, - // }), - // input: &blobbergrpc.CommitMetaTxnRequest{ - // Path: "/some_file", - // PathHash: "exampleId:examplePath", - // AuthToken: "", - // Allocation: allocationTx, - // TxnId: "8", - // }, - // expectedMessage: "Added commitMetaTxn successfully", - // expectingError: false, - // }, - // { - // name: "Fail", - // context: metadata.New(map[string]string{ - // common.ClientHeader: clientId, - // }), - // input: &blobbergrpc.CommitMetaTxnRequest{ - // Path: "/some_file", - // PathHash: "exampleId:examplePath", - // AuthToken: "", - // Allocation: allocationTx, - // TxnId: "", - // }, - // expectedMessage: "", - // expectingError: true, - // }, - // } - // - // for _, tc := range testCases { - // ctx := context.Background() - // ctx = metadata.NewOutgoingContext(ctx, tc.context) - // commitMetaTxnResponse, err := blobberClient.CommitMetaTxn(ctx, tc.input) - // if err != nil { - // if !tc.expectingError { - // t.Fatal(err) - // } - // continue - // } - // - // if tc.expectingError { - // t.Fatal("expected error") - // } - // - // if commitMetaTxnResponse.GetMessage() != tc.expectedMessage { - // t.Fatal("failed!") - // } - // } - //}) - // - //t.Run("TestCollaborator", func(t *testing.T) { - // allocationTx := randString(32) - // - // pubKey, _, signScheme := GeneratePubPrivateKey(t) - // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - // pubKeyBytes, _ := hex.DecodeString(pubKey) - // clientId := encryption.Hash(pubKeyBytes) - // now := common.Timestamp(time.Now().UnixNano()) - // - // blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" - // blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) - // - // fr := reference.Ref{ - // AllocationID: "exampleId", - // } - // - // rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) - // - // wm := writemarker.WriteMarker{ - // AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), - // PreviousAllocationRoot: "/", - // AllocationID: "exampleId", - // Size: 1337, - // BlobberID: encryption.Hash(blobberPubKeyBytes), - // Timestamp: now, - // ClientID: clientId, - // } - // - // wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) - // if err != nil { - // t.Fatal(err) - // } - // - // wm.Signature = wmSig - // - // if err := tdController.ClearDatabase(); err != nil { - // t.Fatal(err) - // } - // if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { - // t.Fatal(err) - // } - // - // testCases := []struct { - // name string - // context metadata.MD - // input *blobbergrpc.CollaboratorRequest - // expectedMessage string - // expectingError bool - // }{ - // { - // name: "Success", - // context: metadata.New(map[string]string{ - // common.ClientHeader: clientId, - // common.ClientSignatureHeader: clientSignature, - // common.ClientKeyHeader: pubKey, - // }), - // input: &blobbergrpc.CollaboratorRequest{ - // Path: "/some_file", - // PathHash: "exampleId:examplePath", - // Allocation: allocationTx, - // Method: http.MethodPost, - // CollabId: "10", - // }, - // expectedMessage: "Added collaborator successfully", - // expectingError: false, - // }, - // { - // name: "Fail", - // context: metadata.New(map[string]string{ - // common.ClientHeader: clientId, - // common.ClientSignatureHeader: clientSignature, - // common.ClientKeyHeader: pubKey, - // }), - // input: &blobbergrpc.CollaboratorRequest{ - // Path: "/some_file", - // PathHash: "exampleId:examplePath", - // Allocation: allocationTx, - // Method: http.MethodPost, - // }, - // expectedMessage: "", - // expectingError: true, - // }, - // } - // - // for _, tc := range testCases { - // ctx := context.Background() - // ctx = metadata.NewOutgoingContext(ctx, tc.context) - // response, err := blobberClient.Collaborator(ctx, tc.input) - // if err != nil { - // if !tc.expectingError { - // t.Fatal(err) - // } - // - // continue - // } - // - // if tc.expectingError { - // t.Fatal("expected error") - // } - // - // if response.GetMessage() != tc.expectedMessage { - // t.Fatal("failed!") - // } - // } - //}) + + t.Run("TestCommitMetaTxn", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().UnixNano()) + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + fr := reference.Ref{ + AllocationID: "exampleId", + } + + rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + + wm := writemarker.WriteMarker{ + AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + PreviousAllocationRoot: "/", + AllocationID: "exampleId", + Size: 1337, + BlobberID: encryption.Hash(blobberPubKeyBytes), + Timestamp: now, + ClientID: clientId, + } + + wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + if err != nil { + t.Fatal(err) + } + + wm.Signature = wmSig + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CommitMetaTxnRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + }), + input: &blobbergrpc.CommitMetaTxnRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: allocationTx, + TxnId: "8", + }, + expectedMessage: "Added commitMetaTxn successfully", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + }), + input: &blobbergrpc.CommitMetaTxnRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: allocationTx, + TxnId: "", + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + commitMetaTxnResponse, err := blobberClient.CommitMetaTxn(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if commitMetaTxnResponse.GetMessage() != tc.expectedMessage { + t.Fatal("failed!") + } + } + }) + + t.Run("TestCollaborator", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().UnixNano()) + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + fr := reference.Ref{ + AllocationID: "exampleId", + } + + rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + + wm := writemarker.WriteMarker{ + AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + PreviousAllocationRoot: "/", + AllocationID: "exampleId", + Size: 1337, + BlobberID: encryption.Hash(blobberPubKeyBytes), + Timestamp: now, + ClientID: clientId, + } + + wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + if err != nil { + t.Fatal(err) + } + + wm.Signature = wmSig + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CollaboratorRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CollaboratorRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + Allocation: allocationTx, + Method: http.MethodPost, + CollabId: "10", + }, + expectedMessage: "Added collaborator successfully", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CollaboratorRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + Allocation: allocationTx, + Method: http.MethodPost, + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := blobberClient.Collaborator(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetMessage() != tc.expectedMessage { + t.Fatal("failed!") + } + } + }) } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index f9fdce8af..b65999492 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -29,74 +29,6 @@ func randString(n int) string { return sb.String() } -func TestBlobberGRPCService_GetObjectTree_Success(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.GetObjectTreeRequest{ - Path: "something", - Allocation: allocationTx, - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "owner", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: clientSignature, - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", - OwnerPublicKey: pubKey, - }, nil) - mockReferencePackage.On("GetObjectTree", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - Type: reference.DIRECTORY, - Children: []*reference.Ref{{Name: "test1", Type: reference.FILE}}, - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.GetObjectTree(ctx, req) - if err != nil { - t.Fatal("unexpected error - " + err.Error()) - } - - assert.Equal(t, resp.ReferencePath.MetaData.DirMetaData.Name, "test") - -} - -func TestBlobberGRPCService_GetObjectTree_NotOwner(t *testing.T) { - req := &blobbergrpc.GetObjectTreeRequest{ - Path: "something", - Allocation: "", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "hacker", - common.ClientKeyHeader: "", - common.ClientSignatureHeader: "", - })) - - mockStorageHandler := &storageHandlerI{} - mockReferencePackage := &mocks.PackageHandler{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.GetObjectTree(ctx, req) - if err == nil { - t.Fatal("expected error") - } -} - func TestBlobberGRPCService_CalculateHashSuccess(t *testing.T) { allocationTx := randString(32) From f370af4d5245a30a1739a9e024f895c12840c2d3 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 17:25:54 +0530 Subject: [PATCH 120/183] :sparkles: grpc -> http commithash --- .../blobbercore/convert/responseHandler.go | 10 ++- .../blobbercore/handler/grpc_handler.go | 40 +++--------- .../handler/grpc_handler_unit_test.go | 64 ------------------- .../blobbercore/handler/metadata.go | 2 +- 4 files changed, 13 insertions(+), 103 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 555ba1790..4b4f3383e 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -137,13 +137,11 @@ func CommitWriteResponseHandler(resp *blobbergrpc.CommitResponse) *blobberHTTP.C } } -func GetCalculateHashResponseHandler(response *blobbergrpc.CalculateHashResponse) interface{} { - result := make(map[string]interface{}) - if msg := response.GetMessage(); msg != "" { - result["msg"] = msg - } +func GetCalculateHashResponseHandler(r interface{}) *blobbergrpc.CalculateHashResponse { + httpResp, _ := r.(map[string]interface{}) + msg, _ := httpResp["msg"].(string) - return result + return &blobbergrpc.CalculateHashResponse{Message: msg} } func GetCommitMetaTxnHandlerResponse(response *blobbergrpc.CommitMetaTxnResponse) interface{} { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 71533b4c7..bd9641908 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -2,7 +2,6 @@ package handler import ( "context" - "encoding/json" "net/http" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" @@ -156,45 +155,22 @@ func (b *blobberGRPCService) GetObjectTree(ctx context.Context, req *blobbergrpc } func (b *blobberGRPCService) CalculateHash(ctx context.Context, req *blobbergrpc.CalculateHashRequest) (*blobbergrpc.CalculateHashResponse, error) { - allocationTx := req.Allocation - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) + r, err := http.NewRequest("POST", "", nil) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - - md := GetGRPCMetaDataFromCtx(ctx) - allocationID := allocationObj.ID - - clientID := md.Client - if len(clientID) == 0 || allocationObj.OwnerID != clientID { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + return nil, err } - - var paths []string - pathsString := req.Paths - if len(pathsString) == 0 { - path := req.Path - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") - } - paths = append(paths, path) - } else { - err = json.Unmarshal([]byte(pathsString), &paths) - if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid path array json") - } + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "paths": {req.Paths}, } - rootRef, err := b.packageHandler.GetReferencePathFromPaths(ctx, allocationID, paths) + resp, err := CalculateHashHandler(ctx, r) if err != nil { return nil, err } - if _, err := rootRef.CalculateHash(ctx, true); err != nil { - return nil, err - } - - return &blobbergrpc.CalculateHashResponse{Message: "Hash recalculated for the given paths"}, nil + return convert.GetCalculateHashResponseHandler(resp), nil } func (b *blobberGRPCService) CommitMetaTxn(ctx context.Context, req *blobbergrpc.CommitMetaTxnRequest) (*blobbergrpc.CommitMetaTxnResponse, error) { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go index b65999492..b4186d0f9 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go @@ -29,70 +29,6 @@ func randString(n int) string { return sb.String() } -func TestBlobberGRPCService_CalculateHashSuccess(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.CalculateHashRequest{ - Allocation: allocationTx, - Path: "some-path", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "owner", - common.ClientSignatureHeader: clientSignature, - })) - - mockStorageHandler := new(storageHandlerI) - mockReferencePackage := new(mocks.PackageHandler) - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", - OwnerPublicKey: pubKey, - }, nil) - mockReferencePackage.On("GetReferencePathFromPaths", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - Type: reference.DIRECTORY, - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.CalculateHash(ctx, req) - if err != nil { - t.Fatal("unexpected error: ", err) - } - - assert.Equal(t, resp.GetMessage(), "Hash recalculated for the given paths") -} - -func TestBlobberGRPCService_CalculateHashNotOwner(t *testing.T) { - req := &blobbergrpc.CalculateHashRequest{ - Allocation: "", - Path: "some-path", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "hacker", - common.ClientSignatureHeader: "", - })) - - mockStorageHandler := new(storageHandlerI) - mockReferencePackage := new(mocks.PackageHandler) - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "owner", - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.CalculateHash(ctx, req) - if err == nil { - t.Fatal("expected error") - } -} - func TestBlobberGRPCService_CommitMetaTxnSuccess(t *testing.T) { allocationTx := randString(32) diff --git a/code/go/0chain.net/blobbercore/handler/metadata.go b/code/go/0chain.net/blobbercore/handler/metadata.go index 822eb80ae..c07a14ea6 100644 --- a/code/go/0chain.net/blobbercore/handler/metadata.go +++ b/code/go/0chain.net/blobbercore/handler/metadata.go @@ -42,5 +42,5 @@ func httpRequestWithMetaData(r *http.Request, md *GRPCMetaData, alloc string) { r.Header.Set(common.ClientHeader, md.Client) r.Header.Set(common.ClientKeyHeader, md.ClientKey) r.Header.Set(common.ClientSignatureHeader, md.ClientSignature) - mux.SetURLVars(r, map[string]string{"allocation": alloc}) + *r = *mux.SetURLVars(r, map[string]string{"allocation": alloc}) } From d48605f9a50e3a681665be10df6f8fa4194f425a Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 17:49:04 +0530 Subject: [PATCH 121/183] :sparkles: grpc -> http collaboratos and commitmeta --- .../blobbercore/convert/responseHandler.go | 42 ++-- .../blobbercore/handler/grpc_handler.go | 157 ++------------ .../handler/grpc_handler_integration_test.go | 13 ++ .../handler/grpc_handler_unit_test.go | 200 ------------------ 4 files changed, 54 insertions(+), 358 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 4b4f3383e..355c61a29 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -144,38 +144,34 @@ func GetCalculateHashResponseHandler(r interface{}) *blobbergrpc.CalculateHashRe return &blobbergrpc.CalculateHashResponse{Message: msg} } -func GetCommitMetaTxnHandlerResponse(response *blobbergrpc.CommitMetaTxnResponse) interface{} { - msg := response.GetMessage() - if msg == "" { - return nil - } - - result := struct { +func GetCommitMetaTxnHandlerResponse(r interface{}) *blobbergrpc.CommitMetaTxnResponse { + msg, _ := r.(struct { Msg string `json:"msg"` - }{ - Msg: msg, - } + }) - return result + return &blobbergrpc.CommitMetaTxnResponse{Message: msg.Msg} } -func CollaboratorResponse(response *blobbergrpc.CollaboratorResponse) interface{} { - if msg := response.GetMessage(); msg != "" { - return struct { - Msg string `json:"msg"` - }{Msg: msg} +func CollaboratorResponse(r interface{}) *blobbergrpc.CollaboratorResponse { + if r == nil { + return nil } - if collaborators := response.GetCollaborators(); collaborators != nil { - collabs := make([]reference.Collaborator, 0, len(collaborators)) - for _, c := range collaborators { - collabs = append(collabs, *GRPCCollaboratorToCollaborator(c)) - } + msg, _ := r.(struct { + Msg string `json:"msg"` + }) + var resp blobbergrpc.CollaboratorResponse + if msg.Msg != "" { + resp.Message = msg.Msg + return &resp + } - return collabs + collabs, _ := r.([]reference.Collaborator) + for _, c := range collabs { + resp.Collaborators = append(resp.Collaborators, CollaboratorToGRPCCollaborator(&c)) } - return nil + return &resp } func UpdateObjectAttributesResponseHandler(updateAttributesResponse *blobbergrpc.UpdateObjectAttributesResponse) *blobberHTTP.UpdateObjectAttributesResponse { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index bd9641908..972e80643 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -3,11 +3,10 @@ package handler import ( "context" "net/http" + "strings" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/core/common" ) type blobberGRPCService struct { @@ -174,154 +173,42 @@ func (b *blobberGRPCService) CalculateHash(ctx context.Context, req *blobbergrpc } func (b *blobberGRPCService) CommitMetaTxn(ctx context.Context, req *blobbergrpc.CommitMetaTxnRequest) (*blobbergrpc.CommitMetaTxnResponse, error) { - allocationTx := req.GetAllocation() - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, true) + r, err := http.NewRequest("POST", "", nil) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - allocationID := allocationObj.ID - - md := GetGRPCMetaDataFromCtx(ctx) - clientID := md.Client - if len(clientID) == 0 { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + return nil, err } - - pathHash := req.PathHash - path := req.Path - if len(pathHash) == 0 { - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") - } - pathHash = reference.GetReferenceLookup(allocationID, path) + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "path_hash": {req.PathHash}, + "auth_token": {req.AuthToken}, + "txn_id": {req.TxnId}, } - fileRef, err := b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, pathHash) + resp, err := CommitMetaTxnHandler(ctx, r) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid file path. "+err.Error()) - } - - if fileRef.Type != reference.FILE { - return nil, common.NewError("invalid_parameters", "Path is not a file.") - } - - auhToken := req.GetAuthToken() - - if clientID != allocationObj.OwnerID || len(auhToken) > 0 { - authTicketVerified, err := b.storageHandler.verifyAuthTicket(ctx, auhToken, allocationObj, fileRef, clientID) - if err != nil { - return nil, err - } - - if !authTicketVerified { - return nil, common.NewError("auth_ticket_verification_failed", "Could not verify the auth ticket.") - } - } - - txnID := req.GetTxnId() - if len(txnID) == 0 { - return nil, common.NewError("invalid_parameter", "TxnID not present in the params") - } - - if err := b.packageHandler.AddCommitMetaTxn(ctx, fileRef.ID, txnID); err != nil { - return nil, common.NewError("add_commit_meta_txn_failed", "Failed to add commitMetaTxn with err :"+err.Error()) + return nil, err } - return &blobbergrpc.CommitMetaTxnResponse{ - Message: "Added commitMetaTxn successfully", - }, nil + return convert.GetCommitMetaTxnHandlerResponse(resp), nil } func (b *blobberGRPCService) Collaborator(ctx context.Context, req *blobbergrpc.CollaboratorRequest) (*blobbergrpc.CollaboratorResponse, error) { - allocationTx := req.Allocation - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, true) + r, err := http.NewRequest(strings.ToUpper(req.Method), "", nil) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - - md := GetGRPCMetaDataFromCtx(ctx) - allocationID := allocationObj.ID - - valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) - if !valid || err != nil { - return nil, common.NewError("invalid_signature", "Invalid signature") + return nil, err } - - clientID := md.Client - - pathHash := req.PathHash - path := req.Path - if len(pathHash) == 0 { - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") - } - pathHash = reference.GetReferenceLookup(allocationID, path) + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "path_hash": {req.PathHash}, + "collab_id": {req.CollabId}, } - fileRef, err := b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, pathHash) + resp, err := CollaboratorHandler(ctx, r) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid file path. "+err.Error()) - } - - if fileRef.Type != reference.FILE { - return nil, common.NewError("invalid_parameters", "Path is not a file.") - } - - collabClientID := req.CollabId - if len(collabClientID) == 0 { - return nil, common.NewError("invalid_parameter", "collab_id not present in the params") - } - - var msg string - - switch req.GetMethod() { - case http.MethodPost: - if len(clientID) == 0 || clientID != allocationObj.OwnerID { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") - } - - if b.packageHandler.IsACollaborator(ctx, fileRef.ID, collabClientID) { - msg = "Given client ID is already a collaborator" - return &blobbergrpc.CollaboratorResponse{Message: msg}, nil - } - - if err := b.packageHandler.AddCollaborator(ctx, fileRef.ID, collabClientID); err != nil { - return nil, common.NewError("add_collaborator_failed", "Failed to add collaborator with err :"+err.Error()) - } - - msg = "Added collaborator successfully" - - case http.MethodGet: - collaborators, err := b.packageHandler.GetCollaborators(ctx, fileRef.ID) - if err != nil { - return nil, common.NewError("get_collaborator_failed", "Failed to get collaborators from refID with err:"+err.Error()) - } - - var collaboratorsGRPC []*blobbergrpc.Collaborator - for _, c := range collaborators { - collaboratorsGRPC = append(collaboratorsGRPC, convert.CollaboratorToGRPCCollaborator(&c)) - } - - return &blobbergrpc.CollaboratorResponse{ - Collaborators: collaboratorsGRPC, - }, nil - - case http.MethodDelete: - if len(clientID) == 0 || clientID != allocationObj.OwnerID { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") - } - - if err := b.packageHandler.RemoveCollaborator(ctx, fileRef.ID, collabClientID); err != nil { - return nil, common.NewError("delete_collaborator_failed", "Failed to delete collaborator from refID with err:"+err.Error()) - } - - msg = "Removed collaborator successfully" - - default: - return nil, common.NewError("invalid_method", "Invalid method used. Use POST/GET/DELETE instead") + return nil, err } - return &blobbergrpc.CollaboratorResponse{ - Message: msg, - }, nil + return convert.CollaboratorResponse(resp), nil } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 7f37ade0d..9e4574452 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -5,9 +5,11 @@ import ( "encoding/hex" "fmt" "log" + "math/rand" "net/http" "os" "strconv" + "strings" "testing" "time" @@ -849,3 +851,14 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } }) } + +func randString(n int) string { + + const hexLetters = "abcdef0123456789" + + var sb strings.Builder + for i := 0; i < n; i++ { + sb.WriteByte(hexLetters[rand.Intn(len(hexLetters))]) + } + return sb.String() +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go deleted file mode 100644 index b4186d0f9..000000000 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_unit_test.go +++ /dev/null @@ -1,200 +0,0 @@ -package handler - -import ( - "context" - "math/rand" - "net/http" - "strings" - "testing" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/core/common" - "github.com/0chain/blobber/code/go/0chain.net/core/encryption" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/mock" - "google.golang.org/grpc/metadata" -) - -func randString(n int) string { - - const hexLetters = "abcdef0123456789" - - var sb strings.Builder - for i := 0; i < n; i++ { - sb.WriteByte(hexLetters[rand.Intn(len(hexLetters))]) - } - return sb.String() -} - -func TestBlobberGRPCService_CommitMetaTxnSuccess(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.CommitMetaTxnRequest{ - Path: "/some_file", - PathHash: "exampleId:examplePath", - AuthToken: "", - Allocation: allocationTx, - TxnId: "8", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "owner", - common.ClientSignatureHeader: clientSignature, - })) - - mockStorageHandler := new(storageHandlerI) - mockReferencePackage := new(mocks.PackageHandler) - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ - ID: "8", - Tx: req.Allocation, - OwnerID: "owner", - OwnerPublicKey: pubKey, - }, nil) - mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - ID: 8, - Type: reference.FILE, - }, nil) - mockReferencePackage.On("AddCommitMetaTxn", mock.Anything, mock.Anything, mock.Anything). - Return(nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.CommitMetaTxn(ctx, req) - if err != nil { - t.Fatal("unexpected error: ", err) - } - - assert.Equal(t, resp.GetMessage(), "Added commitMetaTxn successfully") -} - -func TestBlobberGRPCService_CommitMetaTxnError(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.CommitMetaTxnRequest{ - Path: "/some_file", - PathHash: "exampleId:examplePath", - AuthToken: "", - Allocation: allocationTx, - TxnId: "", // TxnId not passed, expecting error - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "owner", - common.ClientSignatureHeader: clientSignature, - })) - - mockStorageHandler := new(storageHandlerI) - mockReferencePackage := new(mocks.PackageHandler) - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ - ID: "8", - Tx: req.Allocation, - OwnerID: "owner", - OwnerPublicKey: pubKey, - }, nil) - mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - ID: 8, - Type: reference.FILE, - }, nil) - mockReferencePackage.On("AddCommitMetaTxn", mock.Anything, mock.Anything, mock.Anything). - Return(nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.CommitMetaTxn(ctx, req) - if err == nil { - t.Fatal("expected error") - } -} - -func TestBlobberGRPCService_AddCollaboratorSuccess(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.CollaboratorRequest{ - Allocation: allocationTx, - Path: "some-path", - CollabId: "12", - Method: http.MethodPost, - PathHash: "exampleId:examplePath", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "12", - common.ClientSignatureHeader: clientSignature, - })) - - mockStorageHandler := new(storageHandlerI) - mockReferencePackage := new(mocks.PackageHandler) - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "12", - OwnerPublicKey: pubKey, - }, nil) - mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - Type: reference.FILE, - }, nil) - mockReferencePackage.On("IsACollaborator", mock.Anything, mock.Anything, mock.Anything). - Return(false) - mockReferencePackage.On("AddCollaborator", mock.Anything, mock.Anything, mock.Anything). - Return(nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - resp, err := svc.Collaborator(ctx, req) - if err != nil { - t.Fatal("unexpected error: ", err) - } - - assert.Equal(t, resp.GetMessage(), "Added collaborator successfully") -} - -func TestBlobberGRPCService_AddCollaboratorError(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.CollaboratorRequest{ - Allocation: allocationTx, - Path: "some-path", - CollabId: "12", - Method: http.MethodPost, - PathHash: "exampleId:examplePath", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "1", - common.ClientSignatureHeader: clientSignature, - })) - - mockStorageHandler := new(storageHandlerI) - mockReferencePackage := new(mocks.PackageHandler) - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, true).Return(&allocation.Allocation{ - ID: "allocationId", - Tx: req.Allocation, - OwnerID: "12", - OwnerPublicKey: pubKey, - }, nil) - mockReferencePackage.On("GetReferenceFromLookupHash", mock.Anything, mock.Anything, mock.Anything).Return(&reference.Ref{ - Name: "test", - Type: reference.FILE, - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.Collaborator(ctx, req) - if err == nil { - t.Fatal("expected error") - } -} From d085d2ccf3d90ff1c7c6f50b8cc49eba7d60ac52 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 17:55:05 +0530 Subject: [PATCH 122/183] :sparkles: grpc -> http commit --- .../blobbercore/convert/responseHandler.go | 18 +- .../handler/grpc_commit_handler.go | 179 +------------ .../handler/grpc_commit_handler_unit_test.go | 237 ------------------ 3 files changed, 20 insertions(+), 414 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/handler/grpc_commit_handler_unit_test.go diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 355c61a29..6630e87b7 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -128,12 +128,18 @@ func GetObjectPathResponseCreator(r interface{}) *blobbergrpc.GetObjectPathRespo return &resp } -func CommitWriteResponseHandler(resp *blobbergrpc.CommitResponse) *blobberHTTP.CommitResult { - return &blobberHTTP.CommitResult{ - AllocationRoot: resp.AllocationRoot, - WriteMarker: WriteMarkerGRPCToWriteMarker(resp.WriteMarker), - Success: resp.Success, - ErrorMessage: resp.ErrorMessage, +func CommitWriteResponseHandler(r interface{}) *blobbergrpc.CommitResponse { + if r == nil { + return nil + } + + httpResp, _ := r.(*blobberHTTP.CommitResult) + + return &blobbergrpc.CommitResponse{ + AllocationRoot: httpResp.AllocationRoot, + WriteMarker: WriteMarkerToWriteMarkerGRPC(httpResp.WriteMarker), + ErrorMessage: httpResp.ErrorMessage, + Success: httpResp.Success, } } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go index 03dfa4058..362ef2a1a 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go @@ -2,190 +2,27 @@ package handler import ( "context" - "encoding/hex" - "encoding/json" - "strconv" + "net/http" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" - "github.com/0chain/blobber/code/go/0chain.net/core/common" - "github.com/0chain/blobber/code/go/0chain.net/core/encryption" - "github.com/0chain/blobber/code/go/0chain.net/core/lock" - "gorm.io/gorm" ) func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.CommitRequest) (*blobbergrpc.CommitResponse, error) { - md := GetGRPCMetaDataFromCtx(ctx) - //ctx = httpRequestWithMetaData(ctx, md, req.Allocation) - - allocationTx := req.Allocation - clientID := md.Client - clientKey := md.ClientKey - clientKeyBytes, _ := hex.DecodeString(clientKey) - - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) - if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - - allocationID := allocationObj.ID - - connectionID := req.ConnectionId - if len(connectionID) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid connection id passed") - } - - mutex := lock.GetMutex(allocationObj.TableName(), allocationID) - mutex.Lock() - defer mutex.Unlock() - - connectionObj, err := b.packageHandler.GetAllocationChanges(ctx, connectionID, allocationID, clientID) - if err != nil { - return nil, common.NewErrorf("invalid_parameters", - "Invalid connection id. Connection id was not found: %v", err) - } - if len(connectionObj.Changes) == 0 { - return nil, common.NewError("invalid_parameters", - "Invalid connection id. Connection does not have any changes.") - } - - var isACollaborator bool - for _, change := range connectionObj.Changes { - if change.Operation == allocation.UPDATE_OPERATION { - updateFileChange := new(allocation.UpdateFileChange) - if err := updateFileChange.Unmarshal(change.Input); err != nil { - return nil, err - } - fileRef, err := reference.GetReference(ctx, allocationID, updateFileChange.Path) - if err != nil { - return nil, err - } - isACollaborator = reference.IsACollaborator(ctx, fileRef.ID, clientID) - break - } - } - - if len(clientID) == 0 || len(clientKey) == 0 { - return nil, common.NewError("invalid_params", "Please provide clientID and clientKey") - } - - if (allocationObj.OwnerID != clientID || encryption.Hash(clientKeyBytes) != clientID) && !isACollaborator { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") - } - - if allocationObj.BlobberSizeUsed+connectionObj.Size > allocationObj.BlobberSize { - return nil, common.NewError("max_allocation_size", - "Max size reached for the allocation with this blobber") - } - - writeMarkerString := req.WriteMarker - writeMarker := writemarker.WriteMarker{} - err = json.Unmarshal([]byte(writeMarkerString), &writeMarker) - if err != nil { - return nil, common.NewErrorf("invalid_parameters", - "Invalid parameters. Error parsing the writemarker for commit: %v", - err) - } - - var result blobbergrpc.CommitResponse - var latestWM *writemarker.WriteMarkerEntity - if len(allocationObj.AllocationRoot) == 0 { - latestWM = nil - } else { - latestWM, err = b.packageHandler.GetWriteMarkerEntity(ctx, - allocationObj.AllocationRoot) - if err != nil { - return nil, common.NewErrorf("latest_write_marker_read_error", - "Error reading the latest write marker for allocation: %v", err) - } - } - - writemarkerObj := &writemarker.WriteMarkerEntity{} - writemarkerObj.WM = writeMarker - - err = b.packageHandler.VerifyMarker(writemarkerObj, ctx, allocationObj, connectionObj) + r, err := http.NewRequest("", "", nil) if err != nil { - result.AllocationRoot = allocationObj.AllocationRoot - result.ErrorMessage = "Verification of write marker failed: " + err.Error() - result.Success = false - if latestWM != nil { - result.WriteMarker = convert.WriteMarkerToWriteMarkerGRPC(&latestWM.WM) - } - return &result, common.NewError("write_marker_verification_failed", result.ErrorMessage) - } - - var clientIDForWriteRedeem = writeMarker.ClientID - if isACollaborator { - clientIDForWriteRedeem = allocationObj.OwnerID - } - - if err = writePreRedeem(ctx, allocationObj, &writeMarker, clientIDForWriteRedeem); err != nil { return nil, err } - - err = b.packageHandler.ApplyChanges(connectionObj, ctx, writeMarker.AllocationRoot) - if err != nil { - return nil, err - } - rootRef, err := b.packageHandler.GetReference(ctx, allocationID, "/") - if err != nil { - return nil, err - } - allocationRoot := encryption.Hash(rootRef.Hash + ":" + strconv.FormatInt(int64(writeMarker.Timestamp), 10)) - - if allocationRoot != writeMarker.AllocationRoot { - result.AllocationRoot = allocationObj.AllocationRoot - if latestWM != nil { - result.WriteMarker = convert.WriteMarkerToWriteMarkerGRPC(&latestWM.WM) - } - result.Success = false - result.ErrorMessage = "Allocation root in the write marker does not match the calculated allocation root. Expected hash: " + allocationRoot - return &result, common.NewError("allocation_root_mismatch", result.ErrorMessage) + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "write_marker": {req.WriteMarker}, + "connection_id": {req.ConnectionId}, } - writemarkerObj.ConnectionID = connectionObj.ConnectionID - writemarkerObj.ClientPublicKey = clientKey - err = b.packageHandler.UpdateAllocationAndCommitChanges(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) + resp, err := CommitHandler(ctx, r) if err != nil { return nil, err } - result.AllocationRoot = allocationObj.AllocationRoot - result.WriteMarker = convert.WriteMarkerToWriteMarkerGRPC(&writeMarker) - result.Success = true - result.ErrorMessage = "" - - return &result, nil -} - -func UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { - err := writemarkerObj.Save(ctx) - if err != nil { - return common.NewError("write_marker_error", "Error persisting the write marker") - } - - db := datastore.GetStore().GetTransaction(ctx) - allocationUpdates := make(map[string]interface{}) - allocationUpdates["blobber_size_used"] = gorm.Expr("blobber_size_used + ?", connectionObj.Size) - allocationUpdates["used_size"] = gorm.Expr("used_size + ?", connectionObj.Size) - allocationUpdates["allocation_root"] = allocationRoot - allocationUpdates["is_redeem_required"] = true - - err = db.Model(allocationObj).Updates(allocationUpdates).Error - if err != nil { - return common.NewError("allocation_write_error", "Error persisting the allocation object") - } - err = connectionObj.CommitToFileStore(ctx) - if err != nil { - return common.NewError("file_store_error", "Error committing to file store. "+err.Error()) - } - - connectionObj.DeleteChanges(ctx) //nolint:errcheck // never returns an error anyway - - db.Model(connectionObj).Updates(allocation.AllocationChangeCollector{Status: allocation.CommittedConnection}) - return nil + return convert.CommitWriteResponseHandler(resp), nil } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler_unit_test.go deleted file mode 100644 index 9e9ce4ce0..000000000 --- a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler_unit_test.go +++ /dev/null @@ -1,237 +0,0 @@ -package handler - -import ( - "context" - "encoding/hex" - "fmt" - "strconv" - "testing" - "time" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" - "github.com/0chain/blobber/code/go/0chain.net/core/common" - "github.com/0chain/blobber/code/go/0chain.net/core/encryption" - "github.com/magiconair/properties/assert" - "github.com/stretchr/testify/mock" - "google.golang.org/grpc/metadata" -) - -func TestBlobberGRPCService_Commit(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - pubKeyBytes, err := hex.DecodeString(pubKey) - if err != nil { - t.Fatal(err) - } - - timestamp := time.Now().UnixNano() - rootRefHash := "someHash" - clientId := encryption.Hash(pubKeyBytes) - connectionId := "connection_id" - allocationId := "allocationId" - req := &blobbergrpc.CommitRequest{ - Allocation: allocationTx, - ConnectionId: connectionId, - WriteMarker: `{"allocation_id":"` + allocationId + `","timestamp":` + fmt.Sprint(timestamp) + `,"allocation_root":"` + encryption.Hash(rootRefHash+":"+strconv.FormatInt(int64(timestamp), 10)) + `"}`, - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientKeyHeader: pubKey, - common.ClientSignatureHeader: clientSignature, - })) - - testcases := []struct { - description string - getAllocationChangesReturn func() (*allocation.AllocationChangeCollector, error) - verifyMarkerReturn func() error - applyChangesReturn func() error - getReferenceReturn func() (*reference.Ref, error) - verifyAllocationReturn func() (*allocation.Allocation, error) - getWriteMarkerEntityReturn func() (*writemarker.WriteMarkerEntity, error) - updateAllocationAndCommitChangesReturn func() error - expectedError bool - }{ - { - description: "success", - expectedError: false, - getAllocationChangesReturn: func() (*allocation.AllocationChangeCollector, error) { - return &allocation.AllocationChangeCollector{ - ConnectionID: connectionId, - AllocationID: allocationId, - ClientID: "", - Size: 0, - Changes: []*allocation.AllocationChange{&allocation.AllocationChange{ - ChangeID: 1, - Size: 0, - Operation: "insert", - ConnectionID: connectionId, - Input: "", - ModelWithTS: datastore.ModelWithTS{}, - }}, - AllocationChanges: nil, - Status: 0, - ModelWithTS: datastore.ModelWithTS{}, - }, nil - }, - verifyMarkerReturn: func() error { - return nil - }, - applyChangesReturn: func() error { - return nil - }, - getReferenceReturn: func() (*reference.Ref, error) { - return &reference.Ref{ - Hash: rootRefHash, - }, nil - }, - verifyAllocationReturn: func() (*allocation.Allocation, error) { - return &allocation.Allocation{ - ID: allocationId, - Tx: req.Allocation, - OwnerID: clientId, - OwnerPublicKey: pubKey, - }, nil - }, - getWriteMarkerEntityReturn: func() (*writemarker.WriteMarkerEntity, error) { - return nil, nil - }, - updateAllocationAndCommitChangesReturn: func() error { - return nil - }, - }, - { - description: "could not commit", - expectedError: true, - getAllocationChangesReturn: func() (*allocation.AllocationChangeCollector, error) { - return &allocation.AllocationChangeCollector{ - ConnectionID: connectionId, - AllocationID: allocationId, - ClientID: "", - Size: 0, - Changes: []*allocation.AllocationChange{&allocation.AllocationChange{ - ChangeID: 1, - Size: 0, - Operation: "insert", - ConnectionID: connectionId, - Input: "", - ModelWithTS: datastore.ModelWithTS{}, - }}, - AllocationChanges: nil, - Status: 0, - ModelWithTS: datastore.ModelWithTS{}, - }, nil - }, - verifyMarkerReturn: func() error { - return nil - }, - applyChangesReturn: func() error { - return nil - }, - getReferenceReturn: func() (*reference.Ref, error) { - return &reference.Ref{ - Hash: rootRefHash, - }, nil - }, - verifyAllocationReturn: func() (*allocation.Allocation, error) { - return &allocation.Allocation{ - ID: allocationId, - Tx: req.Allocation, - OwnerID: clientId, - OwnerPublicKey: pubKey, - }, nil - }, - getWriteMarkerEntityReturn: func() (*writemarker.WriteMarkerEntity, error) { - return nil, nil - }, - updateAllocationAndCommitChangesReturn: func() error { - return fmt.Errorf("some error") - }, - }, - { - description: "invalid marker", - expectedError: true, - getAllocationChangesReturn: func() (*allocation.AllocationChangeCollector, error) { - return &allocation.AllocationChangeCollector{ - ConnectionID: connectionId, - AllocationID: allocationId, - ClientID: "", - Size: 0, - Changes: []*allocation.AllocationChange{&allocation.AllocationChange{ - ChangeID: 1, - Size: 0, - Operation: "insert", - ConnectionID: connectionId, - Input: "", - ModelWithTS: datastore.ModelWithTS{}, - }}, - AllocationChanges: nil, - Status: 0, - ModelWithTS: datastore.ModelWithTS{}, - }, nil - }, - verifyMarkerReturn: func() error { - return fmt.Errorf("invalid marker") - }, - applyChangesReturn: func() error { - return nil - }, - getReferenceReturn: func() (*reference.Ref, error) { - return &reference.Ref{ - Hash: rootRefHash, - }, nil - }, - verifyAllocationReturn: func() (*allocation.Allocation, error) { - return &allocation.Allocation{ - ID: allocationId, - Tx: req.Allocation, - OwnerID: clientId, - OwnerPublicKey: pubKey, - }, nil - }, - getWriteMarkerEntityReturn: func() (*writemarker.WriteMarkerEntity, error) { - return nil, nil - }, - updateAllocationAndCommitChangesReturn: func() error { - return nil - }, - }, - } - - for _, tc := range testcases { - - mockStorageHandler := &storageHandlerI{} - mockPackageHandler := &mocks.PackageHandler{} - - mockPackageHandler.On("GetAllocationChanges", mock.Anything, connectionId, allocationId, mock.Anything).Return(tc.getAllocationChangesReturn()) - - mockPackageHandler.On("VerifyMarker", mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(tc.verifyMarkerReturn()) - mockPackageHandler.On("ApplyChanges", mock.Anything, mock.Anything, mock.Anything).Return(tc.applyChangesReturn()) - mockPackageHandler.On("GetReference", mock.Anything, mock.Anything, mock.Anything).Return(tc.getReferenceReturn()) - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false).Return(tc.verifyAllocationReturn()) - mockPackageHandler.On("GetWriteMarkerEntity", mock.Anything, mock.Anything).Return(tc.getWriteMarkerEntityReturn()) - mockPackageHandler.On("UpdateAllocationAndCommitChanges", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(tc.updateAllocationAndCommitChangesReturn()) - - svc := newGRPCBlobberService(mockStorageHandler, mockPackageHandler) - resp, err := svc.Commit(ctx, req) - if err != nil { - if tc.expectedError { - continue - } else { - t.Fatal("unexpected error - " + err.Error()) - } - } - - assert.Equal(t, resp.WriteMarker.AllocationID, allocationId) - } -} From 598a16386ce22af59d06286276033fbd4c270d0b Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 17:55:51 +0530 Subject: [PATCH 123/183] fixing lint --- .../blobbercore/handler/grpc_handler_integration_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 9e4574452..efd6d83c1 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -37,7 +37,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { args[arg] = true } if !args["integration"] { - //t.Skip() + t.Skip() } var conn *grpc.ClientConn From 2cefbd0cd9ed6b75cbd5a2dc3917da5d75a39c85 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 18:15:27 +0530 Subject: [PATCH 124/183] :sparkles: grpc -> http object_operation handlers --- .../blobbercore/convert/responseHandler.go | 32 +-- .../blobbercore/handler/grpc_handler.go | 9 +- .../0chain.net/blobbercore/handler/helper.go | 117 +--------- .../handler/object_operation_grpc_handler.go | 215 +++--------------- .../object_operation_grpc_handler_test.go | 197 ---------------- 5 files changed, 49 insertions(+), 521 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 6630e87b7..8c0916a75 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -5,8 +5,6 @@ import ( stats2 "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" - "github.com/0chain/blobber/code/go/0chain.net/core/common" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberHTTP" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" @@ -180,19 +178,27 @@ func CollaboratorResponse(r interface{}) *blobbergrpc.CollaboratorResponse { return &resp } -func UpdateObjectAttributesResponseHandler(updateAttributesResponse *blobbergrpc.UpdateObjectAttributesResponse) *blobberHTTP.UpdateObjectAttributesResponse { - return &blobberHTTP.UpdateObjectAttributesResponse{ - WhoPaysForReads: common.WhoPays(updateAttributesResponse.WhoPaysForReads), +func UpdateObjectAttributesResponseCreator(r interface{}) *blobbergrpc.UpdateObjectAttributesResponse { + if r != nil { + return nil } + + httpResp, _ := r.(*reference.Attributes) + return &blobbergrpc.UpdateObjectAttributesResponse{WhoPaysForReads: int64(httpResp.WhoPaysForReads)} } -func CopyObjectResponseHandler(copyObjectResponse *blobbergrpc.CopyObjectResponse) *blobberHTTP.UploadResult { - return &blobberHTTP.UploadResult{ - Filename: copyObjectResponse.Filename, - Size: copyObjectResponse.Size, - Hash: copyObjectResponse.ContentHash, - MerkleRoot: copyObjectResponse.MerkleRoot, - UploadLength: copyObjectResponse.UploadLength, - UploadOffset: copyObjectResponse.UploadOffset, +func CopyObjectResponseCreator(r interface{}) *blobbergrpc.CopyObjectResponse { + if r == nil { + return nil + } + + httpResp, _ := r.(*blobberHTTP.UploadResult) + return &blobbergrpc.CopyObjectResponse{ + Filename: httpResp.Filename, + Size: httpResp.Size, + ContentHash: httpResp.Hash, + MerkleRoot: httpResp.MerkleRoot, + UploadLength: httpResp.UploadLength, + UploadOffset: httpResp.UploadOffset, } } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 972e80643..981281994 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -10,16 +10,11 @@ import ( ) type blobberGRPCService struct { - storageHandler StorageHandlerI - packageHandler PackageHandler blobbergrpc.UnimplementedBlobberServer } -func newGRPCBlobberService(sh StorageHandlerI, r PackageHandler) *blobberGRPCService { - return &blobberGRPCService{ - storageHandler: sh, - packageHandler: r, - } +func newGRPCBlobberService() *blobberGRPCService { + return &blobberGRPCService{} } func (b *blobberGRPCService) GetAllocation(ctx context.Context, request *blobbergrpc.GetAllocationRequest) (*blobbergrpc.GetAllocationResponse, error) { diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index a1f35a7fb..0add2303e 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -3,132 +3,17 @@ package handler import ( "context" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" "github.com/gorilla/mux" "github.com/grpc-ecosystem/grpc-gateway/v2/runtime" "google.golang.org/grpc" ) func RegisterGRPCServices(r *mux.Router, server *grpc.Server) { - blobberService := newGRPCBlobberService(&storageHandler, &packageHandler{}) + blobberService := newGRPCBlobberService() grpcGatewayHandler := runtime.NewServeMux() blobbergrpc.RegisterBlobberServer(server, blobberService) _ = blobbergrpc.RegisterBlobberHandlerServer(context.Background(), grpcGatewayHandler, blobberService) r.PathPrefix("/").Handler(grpcGatewayHandler) } - -type StorageHandlerI interface { - verifyAllocation(ctx context.Context, tx string, readonly bool) (alloc *allocation.Allocation, err error) - verifyAuthTicket(ctx context.Context, authTokenString string, allocationObj *allocation.Allocation, refRequested *reference.Ref, clientID string) (bool, error) -} - -// PackageHandler is an interface for all static functions that may need to be mocked -type PackageHandler interface { - GetReference(ctx context.Context, allocationID string, newPath string) (*reference.Ref, error) - GetReferenceLookup(ctx context.Context, allocationID string, path string) string - GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) - GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) - AddCommitMetaTxn(ctx context.Context, refID int64, txnID string) error - GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) - IsACollaborator(ctx context.Context, refID int64, clientID string) bool - AddCollaborator(ctx context.Context, refID int64, clientID string) error - RemoveCollaborator(ctx context.Context, refID int64, clientID string) error - GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) - GetWriteMarkerEntity(ctx context.Context, allocation_root string) (*writemarker.WriteMarkerEntity, error) - GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) - GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) - GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) - GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) - SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error - GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) - VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx context.Context, sa *allocation.Allocation, co *allocation.AllocationChangeCollector) error - ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error - UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error -} - -type packageHandler struct{} - -func (r *packageHandler) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { - return UpdateAllocationAndCommitChanges(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) -} - -func (r *packageHandler) GetReference(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - return reference.GetReference(ctx, allocationID, path) -} - -func (r *packageHandler) ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error { - return connectionObj.ApplyChanges(ctx, allocationRoot) -} - -func (r *packageHandler) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx context.Context, sa *allocation.Allocation, co *allocation.AllocationChangeCollector) error { - return wm.VerifyMarker(ctx, sa, co) -} - -func (r *packageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { - return allocation.GetAllocationChanges(ctx, connectionID, allocationID, clientID) -} - -func (r *packageHandler) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - return reference.GetObjectTree(ctx, allocationID, path) -} - -func (r *packageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { - return reference.GetReferencePathFromPaths(ctx, allocationID, paths) -} - -func (r *packageHandler) GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - return reference.GetRefWithChildren(ctx, allocationID, path) -} - -func (r *packageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { - return reference.GetObjectPath(ctx, allocationID, blockNum) -} - -func (r *packageHandler) GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) { - return stats.GetFileStats(ctx, refID) -} - -func (r *packageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_root string) (*writemarker.WriteMarkerEntity, error) { - return writemarker.GetWriteMarkerEntity(ctx, allocation_root) -} - -func (r *packageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { - return reference.GetReferenceLookup(allocationID, path) -} - -func (r *packageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { - return reference.GetReferenceFromLookupHash(ctx, allocationID, path_hash) -} - -func (r *packageHandler) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) { - return reference.GetCommitMetaTxns(ctx, refID) -} - -func (r *packageHandler) AddCommitMetaTxn(ctx context.Context, refID int64, txnID string) error { - return reference.AddCommitMetaTxn(ctx, refID, txnID) -} - -func (r *packageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { - return reference.GetCollaborators(ctx, refID) -} - -func (r *packageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { - return reference.IsACollaborator(ctx, refID, clientID) -} - -func (r *packageHandler) AddCollaborator(ctx context.Context, refID int64, clientID string) error { - return reference.AddCollaborator(ctx, refID, clientID) -} - -func (r *packageHandler) RemoveCollaborator(ctx context.Context, refID int64, clientID string) error { - return reference.RemoveCollaborator(ctx, refID, clientID) -} - -func (r packageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { - return alloc.Save(ctx) -} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index 6cfafd7a6..9a12df35a 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -2,211 +2,50 @@ package handler import ( "context" - "encoding/json" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "net/http" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/core/common" - "github.com/0chain/blobber/code/go/0chain.net/core/lock" - "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap/ctxzap" - "go.uber.org/zap" - "path/filepath" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" ) -func (b *blobberGRPCService) UpdateObjectAttributes(ctx context.Context, r *blobbergrpc.UpdateObjectAttributesRequest) (*blobbergrpc.UpdateObjectAttributesResponse, error) { - logger := ctxzap.Extract(ctx) - - allocationTx := r.Allocation - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) - if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - - md := GetGRPCMetaDataFromCtx(ctx) - valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) - if !valid || err != nil { - return nil, common.NewError("invalid_signature", "Invalid signature") - } - - //// runtime type check - //_ = ctx.Value(constants.CLIENT_KEY_CONTEXT_KEY).(string) //why this removed? - - clientID := md.Client - if clientID == "" { - return nil, common.NewError("update_object_attributes", - "missing client ID") - } - - var attributes = r.Attributes // new attributes as string - if attributes == "" { - return nil, common.NewError("update_object_attributes", - "missing new attributes, pass at least {} for empty attributes") - } - - var attrs = new(reference.Attributes) - if err = json.Unmarshal([]byte(attributes), attrs); err != nil { - return nil, common.NewErrorf("update_object_attributes", - "decoding given attributes: %v", err) - } - - pathHash := r.PathHash - path := r.Path - if len(pathHash) == 0 { - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") - } - pathHash = b.packageHandler.GetReferenceLookup(ctx, allocationObj.ID, path) - } - - if allocationObj.OwnerID != clientID { - return nil, common.NewError( - "invalid_operation", "Operation needs to be performed by the owner of the allocation") - } - - var connID = r.ConnectionId - if connID == "" { - return nil, common.NewErrorf("update_object_attributes", - "invalid connection id passed: %s", connID) - } - - var conn *allocation.AllocationChangeCollector - conn, err = b.packageHandler.GetAllocationChanges(ctx, connID, allocationObj.ID, clientID) - if err != nil { - return nil, common.NewErrorf("update_object_attributes", - "reading metadata for connection: %v", err) - } - - var mutex = lock.GetMutex(conn.TableName(), connID) - - mutex.Lock() - defer mutex.Unlock() - - var ref *reference.Ref - ref, err = b.packageHandler.GetReferenceFromLookupHash(ctx, allocationObj.ID, pathHash) +func (b *blobberGRPCService) UpdateObjectAttributes(ctx context.Context, req *blobbergrpc.UpdateObjectAttributesRequest) (*blobbergrpc.UpdateObjectAttributesResponse, error) { + r, err := http.NewRequest("POST", "", nil) if err != nil { - return nil, common.NewErrorf("update_object_attributes", - "invalid file path: %v", err) + return nil, err } - - var change = new(allocation.AllocationChange) - change.ConnectionID = conn.ConnectionID - change.Operation = allocation.UPDATE_ATTRS_OPERATION - - var uafc = &allocation.AttributesChange{ - ConnectionID: conn.ConnectionID, - AllocationID: conn.AllocationID, - Path: ref.Path, - Attributes: attrs, + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "path_hash": {req.PathHash}, + "connection_id": {req.ConnectionId}, + "attributes": {req.Attributes}, } - conn.AddChange(change, uafc) - - err = b.packageHandler.SaveAllocationChanges(ctx, conn) + resp, err := UpdateAttributesHandler(ctx, r) if err != nil { - logger.Error("update_object_attributes: "+ - "error in writing the connection meta data", zap.Error(err)) - return nil, common.NewError("update_object_attributes", - "error writing the connection meta data") + return nil, err } - // return new attributes as result - return &blobbergrpc.UpdateObjectAttributesResponse{WhoPaysForReads: int64(attrs.WhoPaysForReads)}, nil + return convert.UpdateObjectAttributesResponseCreator(resp), nil } -func (b *blobberGRPCService) CopyObject(ctx context.Context, r *blobbergrpc.CopyObjectRequest) (*blobbergrpc.CopyObjectResponse, error) { - logger := ctxzap.Extract(ctx) - md := GetGRPCMetaDataFromCtx(ctx) - - allocationTx := r.Allocation - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) +func (b *blobberGRPCService) CopyObject(ctx context.Context, req *blobbergrpc.CopyObjectRequest) (*blobbergrpc.CopyObjectResponse, error) { + r, err := http.NewRequest("POST", "", nil) if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - - valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) - if !valid || err != nil { - return nil, common.NewError("invalid_signature", "Invalid signature") - } - - allocationID := allocationObj.ID - - clientID := md.Client - if len(clientID) == 0 { - return nil, common.NewError("invalid_operation", "Invalid client") - } - - if len(r.Dest) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid destination for operation") - } - - pathHash := r.PathHash - path := r.Path - if len(pathHash) == 0 { - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") - } - pathHash = b.packageHandler.GetReferenceLookup(ctx, allocationObj.ID, path) + return nil, err } - - if len(clientID) == 0 || allocationObj.OwnerID != clientID { //already checked clientId ? - return nil, common. - NewError("invalid_operation", "Operation needs to be performed by the owner of the allocation") + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "path_hash": {req.PathHash}, + "connection_id": {req.ConnectionId}, + "dest": {req.Dest}, } - connectionID := r.ConnectionId - if len(connectionID) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid connection id passed") - } - - connectionObj, err := b.packageHandler.GetAllocationChanges(ctx, connectionID, allocationID, clientID) + resp, err := CopyHandler(ctx, r) if err != nil { - return nil, common.NewError("meta_error", "Error reading metadata for connection") + return nil, err } - mutex := lock.GetMutex(connectionObj.TableName(), connectionID) - mutex.Lock() - defer mutex.Unlock() - - objectRef, err := b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, pathHash) - if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid file path. "+err.Error()) - } - - newPath := filepath.Join(r.Dest, objectRef.Name) - destRef, _ := b.packageHandler.GetReference(ctx, allocationID, newPath) - if destRef != nil { - return nil, common.NewError( - "invalid_parameters", "Invalid destination path. Object Already exists.") - } - - destRef, err = b.packageHandler.GetReference(ctx, allocationID, r.Dest) - if err != nil || destRef.Type != reference.DIRECTORY { - return nil, common.NewError( - "invalid_parameters", "Invalid destination path. Should be a valid directory.") - } - - allocationChange := &allocation.AllocationChange{} - allocationChange.ConnectionID = connectionObj.ConnectionID - allocationChange.Size = objectRef.Size - allocationChange.Operation = allocation.COPY_OPERATION - - dfc := &allocation.CopyFileChange{ConnectionID: connectionObj.ConnectionID, - AllocationID: connectionObj.AllocationID, DestPath: r.Dest} - dfc.SrcPath = objectRef.Path - connectionObj.Size += allocationChange.Size - connectionObj.AddChange(allocationChange, dfc) - - err = b.packageHandler.SaveAllocationChanges(ctx, connectionObj) - if err != nil { - logger.Error("Error in writing the connection meta data", zap.Error(err)) - return nil, common.NewError("connection_write_error", "Error writing the connection meta data") - } - - result := &blobbergrpc.CopyObjectResponse{} - result.Filename = objectRef.Name - result.ContentHash = objectRef.Hash - result.MerkleRoot = objectRef.MerkleRoot - result.Size = objectRef.Size - - return result, nil + return convert.CopyObjectResponseCreator(resp), nil } diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go deleted file mode 100644 index b24b6a1d0..000000000 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ /dev/null @@ -1,197 +0,0 @@ -package handler - -import ( - "context" - "errors" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/core/common" - "github.com/0chain/blobber/code/go/0chain.net/core/encryption" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/mock" - "google.golang.org/grpc/metadata" - "path/filepath" - "testing" -) - -func TestBlobberGRPCService_UpdateObjectAttributes_Success(t *testing.T) { - allocationTx := randString(32) - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - req := &blobbergrpc.UpdateObjectAttributesRequest{ - Allocation: allocationTx, - Attributes: `{"who_pays_for_reads" : 1}`, - Path: `path`, - ConnectionId: `connection_id`, - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "client_key", - common.ClientSignatureHeader: clientSignature, - })) - - resOk := &blobbergrpc.UpdateObjectAttributesResponse{WhoPaysForReads: int64(1)} - - mockStorageHandler := &storageHandlerI{} - alloc := &allocation.Allocation{ - Tx: req.Allocation, - ID: `allocation_id`, - OwnerID: `client`, - OwnerPublicKey: pubKey, - } - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). - Return(alloc, nil) - - mockReferencePackage := &mocks.PackageHandler{} - allocChange := &allocation.AllocationChangeCollector{} - mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, - req.ConnectionId, alloc.ID, `client`).Return(allocChange, nil) - mockReferencePackage.On(`SaveAllocationChanges`, mock.Anything, allocChange). - Return(nil) - - pathHash := req.Allocation + `:` + req.Path - mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). - Return(pathHash) - - mockReferencePackage.On(`GetReferenceFromLookupHash`, mock.Anything, alloc.ID, pathHash).Return( - &reference.Ref{ - Name: "test", - Type: reference.FILE, - }, nil) - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - gotResponse, err := svc.UpdateObjectAttributes(ctx, req) - if err != nil { - t.Fatal("unexpected error - " + err.Error()) - } - - assert.Equal(t, gotResponse, resOk) -} - -func TestBlobberGRPCService_UpdateObjectAttributes_InvalidAllocation(t *testing.T) { - req := &blobbergrpc.UpdateObjectAttributesRequest{ - Allocation: `invalid_allocation`, - } - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "client_key", - common.ClientSignatureHeader: "clientSignature", - })) - - mockStorageHandler := &storageHandlerI{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). - Return(nil, errors.New("some error")) - - mockReferencePackage := &mocks.PackageHandler{} - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.UpdateObjectAttributes(ctx, req) - if err == nil { - t.Fatal("expected error") - } - if err.Error() != "invalid_parameters: Invalid allocation id passed.some error" { - t.Fatal(`unexpected error - `, err) - } -} - -func TestBlobberGRPCService_CopyObject_Success(t *testing.T) { - allocationTx := randString(32) - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.CopyObjectRequest{ - Allocation: allocationTx, - Path: "path", - ConnectionId: "connection_id", - Dest: "dest", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "client_key", - common.ClientSignatureHeader: clientSignature, - })) - - mockStorageHandler := &storageHandlerI{} - alloc := &allocation.Allocation{ - Tx: req.Allocation, - ID: req.Allocation, - OwnerID: `client`, - OwnerPublicKey: pubKey, - } - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). - Return(alloc, nil) - - mockReferencePackage := &mocks.PackageHandler{} - allocChange := &allocation.AllocationChangeCollector{} - mockReferencePackage.On(`GetAllocationChanges`, mock.Anything, - req.ConnectionId, alloc.ID, alloc.OwnerID).Return(allocChange, nil) - - pathHash := req.Allocation + `:` + req.Path - mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). - Return(pathHash) - - objectRef := &reference.Ref{ - Name: "test", - ContentHash: `hash`, - MerkleRoot: `root`, - Size: 1, - } - - mockReferencePackage.On(`GetReferenceFromLookupHash`, mock.Anything, alloc.ID, pathHash). - Return(objectRef, nil) - newPath := filepath.Join(req.Dest, objectRef.Name) - mockReferencePackage.On(`GetReference`, mock.Anything, alloc.ID, newPath). - Return(nil, nil) - mockReferencePackage.On(`GetReference`, mock.Anything, alloc.ID, req.Dest). - Return(&reference.Ref{Type: `d`}, nil) - mockReferencePackage.On(`SaveAllocationChanges`, mock.Anything, allocChange). - Return(nil) - - resOk := &blobbergrpc.CopyObjectResponse{ - Filename: objectRef.Name, - Size: objectRef.Size, - ContentHash: objectRef.Hash, - MerkleRoot: objectRef.MerkleRoot, - UploadLength: 0, - UploadOffset: 0, - } - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - gotResponse, err := svc.CopyObject(ctx, req) - if err != nil { - t.Fatal("unexpected error - " + err.Error()) - } - - assert.Equal(t, gotResponse, resOk) -} - -func TestBlobberGRPCService_CopyObject_InvalidAllocation(t *testing.T) { - req := &blobbergrpc.CopyObjectRequest{ - Allocation: `invalid_allocation`, - } - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "client_key", - common.ClientSignatureHeader: "clientSignature", - })) - - mockStorageHandler := &storageHandlerI{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). - Return(nil, errors.New("some error")) - - mockReferencePackage := &mocks.PackageHandler{} - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - - _, err := svc.CopyObject(ctx, req) - if err == nil { - t.Fatal("expected error") - } - if err.Error() != "invalid_parameters: Invalid allocation id passed.some error" { - t.Fatal(`unexpected error - `, err) - } -} From 3cba91eff43b16b493fa704e8f99f0dd0712378a Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 18:17:37 +0530 Subject: [PATCH 125/183] fixing lint errors --- .../handler/grpc_handler_helper_unit_test.go | 53 ------------------- 1 file changed, 53 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 23759ea1b..e89037c5f 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -19,61 +19,8 @@ import ( "gorm.io/gorm" "github.com/0chain/gosdk/core/zcncrypto" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/stretchr/testify/mock" ) -// StorageHandlerI is an autogenerated mock type for the StorageHandlerI type -type storageHandlerI struct { - mock.Mock -} - -// verifyAllocation provides a mock function with given fields: ctx, tx, readonly -func (_m *storageHandlerI) verifyAllocation(ctx context.Context, tx string, readonly bool) (*allocation.Allocation, error) { - ret := _m.Called(ctx, tx, readonly) - - var r0 *allocation.Allocation - if rf, ok := ret.Get(0).(func(context.Context, string, bool) *allocation.Allocation); ok { - r0 = rf(ctx, tx, readonly) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*allocation.Allocation) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, bool) error); ok { - r1 = rf(ctx, tx, readonly) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// verifyAuthTicket provides a mock function with given fields: ctx, authTokenString, allocationObj, refRequested, clientID -func (_m *storageHandlerI) verifyAuthTicket(ctx context.Context, authTokenString string, allocationObj *allocation.Allocation, refRequested *reference.Ref, clientID string) (bool, error) { - ret := _m.Called(ctx, authTokenString, allocationObj, refRequested, clientID) - - var r0 bool - if rf, ok := ret.Get(0).(func(context.Context, string, *allocation.Allocation, *reference.Ref, string) bool); ok { - r0 = rf(ctx, authTokenString, allocationObj, refRequested, clientID) - } else { - r0 = ret.Get(0).(bool) - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, *allocation.Allocation, *reference.Ref, string) error); ok { - r1 = rf(ctx, authTokenString, allocationObj, refRequested, clientID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - type TestDataController struct { db *gorm.DB } From f1e82dba38c7690fc8046b5edd8a418a40421e48 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 20:11:56 +0530 Subject: [PATCH 126/183] adding missing test --- .../handler/grpc_commit_handler.go | 22 +- .../handler/grpc_handler_integration_test.go | 229 +++++++++--------- 2 files changed, 132 insertions(+), 119 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go index 362ef2a1a..3a59d797e 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go @@ -1,23 +1,35 @@ package handler import ( + "bytes" "context" + "mime/multipart" "net/http" + "strings" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" ) func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.CommitRequest) (*blobbergrpc.CommitResponse, error) { - r, err := http.NewRequest("", "", nil) + body := bytes.NewBuffer([]byte{}) + writer := multipart.NewWriter(body) + err := writer.WriteField("write_marker", req.WriteMarker) if err != nil { return nil, err } - httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) - r.Form = map[string][]string{ - "write_marker": {req.WriteMarker}, - "connection_id": {req.ConnectionId}, + err = writer.WriteField("connection_id", req.ConnectionId) + if err != nil { + return nil, err + } + writer.Close() + + r, err := http.NewRequest("POST", "", strings.NewReader(body.String())) + if err != nil { + return nil, err } + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Header.Set("Content-Type", writer.FormDataContentType()) resp, err := CommitHandler(ctx, r) if err != nil { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index efd6d83c1..a23dba7f8 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -3,6 +3,7 @@ package handler import ( "context" "encoding/hex" + "encoding/json" "fmt" "log" "math/rand" @@ -529,120 +530,120 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { }) - //t.Run("TestCommit", func(t *testing.T) { - // allocationTx := randString(32) - // - // pubKey, _, signScheme := GeneratePubPrivateKey(t) - // clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - // pubKeyBytes, _ := hex.DecodeString(pubKey) - // clientId := encryption.Hash(pubKeyBytes) - // now := common.Timestamp(time.Now().UnixNano()) - // - // blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" - // blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) - // - // fr := reference.Ref{ - // AllocationID: "exampleId", - // Type: "f", - // Name: "new_name", - // Path: "/new_name", - // ContentHash: "contentHash", - // MerkleRoot: "merkleRoot", - // ActualFileHash: "actualFileHash", - // } - // - // rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) - // - // wm := writemarker.WriteMarker{ - // AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), - // PreviousAllocationRoot: "/", - // AllocationID: "exampleId", - // Size: 1337, - // BlobberID: encryption.Hash(blobberPubKeyBytes), - // Timestamp: now, - // ClientID: clientId, - // } - // - // wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) - // if err != nil { - // t.Fatal(err) - // } - // - // wm.Signature = wmSig - // - // wmRaw, err := json.Marshal(wm) - // if err != nil { - // t.Fatal(err) - // } - // - // err = tdController.ClearDatabase() - // if err != nil { - // t.Fatal(err) - // } - // err = tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now) - // if err != nil { - // t.Fatal(err) - // } - // - // testCases := []struct { - // name string - // context metadata.MD - // input *blobbergrpc.CommitRequest - // expectedAllocation string - // expectingError bool - // }{ - // { - // name: "Success", - // context: metadata.New(map[string]string{ - // common.ClientHeader: clientId, - // common.ClientSignatureHeader: clientSignature, - // common.ClientKeyHeader: pubKey, - // }), - // input: &blobbergrpc.CommitRequest{ - // Allocation: allocationTx, - // ConnectionId: "connection_id", - // WriteMarker: string(wmRaw), - // }, - // expectedAllocation: "exampleId", - // expectingError: false, - // }, - // { - // name: "invalid write_marker", - // context: metadata.New(map[string]string{ - // common.ClientHeader: clientId, - // common.ClientSignatureHeader: clientSignature, - // common.ClientKeyHeader: pubKey, - // }), - // input: &blobbergrpc.CommitRequest{ - // Allocation: allocationTx, - // ConnectionId: "invalid", - // WriteMarker: "invalid", - // }, - // expectedAllocation: "", - // expectingError: true, - // }, - // } - // - // for _, tc := range testCases { - // ctx := context.Background() - // ctx = metadata.NewOutgoingContext(ctx, tc.context) - // getCommiteResp, err := blobberClient.Commit(ctx, tc.input) - // if err != nil { - // if !tc.expectingError { - // t.Fatal(err) - // } - // continue - // } - // - // if tc.expectingError { - // t.Fatal("expected error") - // } - // - // if getCommiteResp.WriteMarker.AllocationID != tc.expectedAllocation { - // t.Fatal("unexpected root name from GetObject") - // } - // } - //}) + t.Run("TestCommit", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().UnixNano()) + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + fr := reference.Ref{ + AllocationID: "exampleId", + Type: "f", + Name: "new_name", + Path: "/new_name", + ContentHash: "contentHash", + MerkleRoot: "merkleRoot", + ActualFileHash: "actualFileHash", + } + + rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + + wm := writemarker.WriteMarker{ + AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + PreviousAllocationRoot: "/", + AllocationID: "exampleId", + Size: 1337, + BlobberID: encryption.Hash(blobberPubKeyBytes), + Timestamp: now, + ClientID: clientId, + } + + wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + if err != nil { + t.Fatal(err) + } + + wm.Signature = wmSig + + wmRaw, err := json.Marshal(wm) + if err != nil { + t.Fatal(err) + } + + err = tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CommitRequest + expectedAllocation string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CommitRequest{ + Allocation: allocationTx, + ConnectionId: "connection_id", + WriteMarker: string(wmRaw), + }, + expectedAllocation: "exampleId", + expectingError: false, + }, + { + name: "invalid write_marker", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CommitRequest{ + Allocation: allocationTx, + ConnectionId: "invalid", + WriteMarker: "invalid", + }, + expectedAllocation: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getCommiteResp, err := blobberClient.Commit(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getCommiteResp.WriteMarker.AllocationID != tc.expectedAllocation { + t.Fatal("unexpected root name from GetObject") + } + } + }) t.Run("TestCommitMetaTxn", func(t *testing.T) { allocationTx := randString(32) From af5a317cfa01450c9961c2820833cdfc78775fc4 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 20:24:00 +0530 Subject: [PATCH 127/183] :art: renaming converter functions --- code/go/0chain.net/blobbercore/convert/responseHandler.go | 8 ++++---- .../0chain.net/blobbercore/handler/grpc_commit_handler.go | 2 +- code/go/0chain.net/blobbercore/handler/grpc_handler.go | 6 +++--- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 8c0916a75..34c14bd25 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -126,7 +126,7 @@ func GetObjectPathResponseCreator(r interface{}) *blobbergrpc.GetObjectPathRespo return &resp } -func CommitWriteResponseHandler(r interface{}) *blobbergrpc.CommitResponse { +func CommitWriteResponseCreator(r interface{}) *blobbergrpc.CommitResponse { if r == nil { return nil } @@ -141,14 +141,14 @@ func CommitWriteResponseHandler(r interface{}) *blobbergrpc.CommitResponse { } } -func GetCalculateHashResponseHandler(r interface{}) *blobbergrpc.CalculateHashResponse { +func GetCalculateHashResponseCreator(r interface{}) *blobbergrpc.CalculateHashResponse { httpResp, _ := r.(map[string]interface{}) msg, _ := httpResp["msg"].(string) return &blobbergrpc.CalculateHashResponse{Message: msg} } -func GetCommitMetaTxnHandlerResponse(r interface{}) *blobbergrpc.CommitMetaTxnResponse { +func GetCommitMetaTxnResponseCreator(r interface{}) *blobbergrpc.CommitMetaTxnResponse { msg, _ := r.(struct { Msg string `json:"msg"` }) @@ -156,7 +156,7 @@ func GetCommitMetaTxnHandlerResponse(r interface{}) *blobbergrpc.CommitMetaTxnRe return &blobbergrpc.CommitMetaTxnResponse{Message: msg.Msg} } -func CollaboratorResponse(r interface{}) *blobbergrpc.CollaboratorResponse { +func CollaboratorResponseCreator(r interface{}) *blobbergrpc.CollaboratorResponse { if r == nil { return nil } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go index 3a59d797e..3631f9cf3 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_commit_handler.go @@ -36,5 +36,5 @@ func (b *blobberGRPCService) Commit(ctx context.Context, req *blobbergrpc.Commit return nil, err } - return convert.CommitWriteResponseHandler(resp), nil + return convert.CommitWriteResponseCreator(resp), nil } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler.go b/code/go/0chain.net/blobbercore/handler/grpc_handler.go index 981281994..a02263504 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler.go @@ -164,7 +164,7 @@ func (b *blobberGRPCService) CalculateHash(ctx context.Context, req *blobbergrpc return nil, err } - return convert.GetCalculateHashResponseHandler(resp), nil + return convert.GetCalculateHashResponseCreator(resp), nil } func (b *blobberGRPCService) CommitMetaTxn(ctx context.Context, req *blobbergrpc.CommitMetaTxnRequest) (*blobbergrpc.CommitMetaTxnResponse, error) { @@ -185,7 +185,7 @@ func (b *blobberGRPCService) CommitMetaTxn(ctx context.Context, req *blobbergrpc return nil, err } - return convert.GetCommitMetaTxnHandlerResponse(resp), nil + return convert.GetCommitMetaTxnResponseCreator(resp), nil } func (b *blobberGRPCService) Collaborator(ctx context.Context, req *blobbergrpc.CollaboratorRequest) (*blobbergrpc.CollaboratorResponse, error) { @@ -205,5 +205,5 @@ func (b *blobberGRPCService) Collaborator(ctx context.Context, req *blobbergrpc. return nil, err } - return convert.CollaboratorResponse(resp), nil + return convert.CollaboratorResponseCreator(resp), nil } From f2022dce6b799e46e7548657164ab7963d833753 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Tue, 15 Jun 2021 20:27:47 +0530 Subject: [PATCH 128/183] :art: adding responsehandler functions for external dependencies --- .../blobbercore/convert/responseHandler.go | 152 ++++++++++++++++++ 1 file changed, 152 insertions(+) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 34c14bd25..c19f553c0 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -1,8 +1,11 @@ package convert import ( + "context" "encoding/json" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + stats2 "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" @@ -202,3 +205,152 @@ func CopyObjectResponseCreator(r interface{}) *blobbergrpc.CopyObjectResponse { UploadOffset: httpResp.UploadOffset, } } + +func GetAllocationResponseHandler(resp *blobbergrpc.GetAllocationResponse) *allocation.Allocation { + return GRPCAllocationToAllocation(resp.Allocation) +} + +func GetFileMetaDataResponseHandler(resp *blobbergrpc.GetFileMetaDataResponse) map[string]interface{} { + var collaborators []reference.Collaborator + for _, c := range resp.Collaborators { + collaborators = append(collaborators, *GRPCCollaboratorToCollaborator(c)) + } + + result := FileRefGRPCToFileRef(resp.MetaData).GetListingData(context.Background()) + result["collaborators"] = collaborators + return result +} + +func GetFileStatsResponseHandler(resp *blobbergrpc.GetFileStatsResponse) map[string]interface{} { + ctx := context.Background() + result := FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx) + + statsMap := make(map[string]interface{}) + statsBytes, _ := json.Marshal(FileStatsGRPCToFileStats(resp.Stats)) + _ = json.Unmarshal(statsBytes, &statsMap) + + for k, v := range statsMap { + result[k] = v + } + + return result +} + +func ListEntitesResponseHandler(resp *blobbergrpc.ListEntitiesResponse) *blobberHTTP.ListResult { + ctx := context.Background() + var entities []map[string]interface{} + for i := range resp.Entities { + entities = append(entities, FileRefGRPCToFileRef(resp.Entities[i]).GetListingData(ctx)) + } + + return &blobberHTTP.ListResult{ + AllocationRoot: resp.AllocationRoot, + Meta: FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx), + Entities: entities, + } +} + +func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetReferencePathResponse) *blobberHTTP.ReferencePathResult { + var recursionCount int + return &blobberHTTP.ReferencePathResult{ + ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getReferencePathResponse.ReferencePath), + LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWM), + } +} + +func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPathResponse) *blobberHTTP.ObjectPathResult { + ctx := context.Background() + path := FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Path).GetListingData(ctx) + var pathList []map[string]interface{} + for _, pl := range getObjectPathResponse.ObjectPath.PathList { + pathList = append(pathList, FileRefGRPCToFileRef(pl).GetListingData(ctx)) + } + path["list"] = pathList + + return &blobberHTTP.ObjectPathResult{ + ObjectPath: &reference.ObjectPath{ + RootHash: getObjectPathResponse.ObjectPath.RootHash, + Meta: FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Meta).GetListingData(ctx), + Path: path, + FileBlockNum: getObjectPathResponse.ObjectPath.FileBlockNum, + }, + LatestWM: WriteMarkerGRPCToWriteMarker(getObjectPathResponse.LatestWriteMarker), + } +} + +func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTreeResponse) *blobberHTTP.ReferencePathResult { + var recursionCount int + return &blobberHTTP.ReferencePathResult{ + ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getObjectTreeResponse.ReferencePath), + LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), + } +} + +func CommitWriteResponseHandler(resp *blobbergrpc.CommitResponse) *blobberHTTP.CommitResult { + return &blobberHTTP.CommitResult{ + AllocationRoot: resp.AllocationRoot, + WriteMarker: WriteMarkerGRPCToWriteMarker(resp.WriteMarker), + Success: resp.Success, + ErrorMessage: resp.ErrorMessage, + } +} + +func GetCalculateHashResponseHandler(response *blobbergrpc.CalculateHashResponse) interface{} { + result := make(map[string]interface{}) + if msg := response.GetMessage(); msg != "" { + result["msg"] = msg + } + + return result +} + +func GetCommitMetaTxnHandlerResponse(response *blobbergrpc.CommitMetaTxnResponse) interface{} { + msg := response.GetMessage() + if msg == "" { + return nil + } + + result := struct { + Msg string `json:"msg"` + }{ + Msg: msg, + } + + return result +} + +func CollaboratorResponse(response *blobbergrpc.CollaboratorResponse) interface{} { + if msg := response.GetMessage(); msg != "" { + return struct { + Msg string `json:"msg"` + }{Msg: msg} + } + + if collaborators := response.GetCollaborators(); collaborators != nil { + collabs := make([]reference.Collaborator, 0, len(collaborators)) + for _, c := range collaborators { + collabs = append(collabs, *GRPCCollaboratorToCollaborator(c)) + } + + return collabs + } + + return nil +} + +func UpdateObjectAttributesResponseHandler(updateAttributesResponse *blobbergrpc.UpdateObjectAttributesResponse) *blobberHTTP.UpdateObjectAttributesResponse { + return &blobberHTTP.UpdateObjectAttributesResponse{ + WhoPaysForReads: common.WhoPays(updateAttributesResponse.WhoPaysForReads), + } +} + +func CopyObjectResponseHandler(copyObjectResponse *blobbergrpc.CopyObjectResponse) *blobberHTTP.UploadResult { + return &blobberHTTP.UploadResult{ + Filename: copyObjectResponse.Filename, + Size: copyObjectResponse.Size, + Hash: copyObjectResponse.ContentHash, + MerkleRoot: copyObjectResponse.MerkleRoot, + UploadLength: copyObjectResponse.UploadLength, + UploadOffset: copyObjectResponse.UploadOffset, + } +} From 3b916bb44b51fa23f6ab89679bb7d3cee0f84300 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 15 Jun 2021 23:13:13 +0530 Subject: [PATCH 129/183] grpc -> http implemented for rename handler --- .../blobbercore/blobbergrpc/blobber.pb.go | 290 ++++++++++-------- .../blobbercore/convert/responseHandler.go | 21 +- .../0chain.net/blobbercore/handler/handler.go | 25 +- .../blobbercore/handler/handler_test.go | 2 +- .../handler/object_operation_grpc_handler.go | 21 +- .../object_operation_grpc_handler_test.go | 0 6 files changed, 203 insertions(+), 156 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 7751ff87f..753227348 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -2134,7 +2134,7 @@ type RenameObjectRequest struct { func (x *RenameObjectRequest) Reset() { *x = RenameObjectRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2147,7 +2147,7 @@ func (x *RenameObjectRequest) String() string { func (*RenameObjectRequest) ProtoMessage() {} func (x *RenameObjectRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[32] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2160,7 +2160,7 @@ func (x *RenameObjectRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use RenameObjectRequest.ProtoReflect.Descriptor instead. func (*RenameObjectRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{32} } func (x *RenameObjectRequest) GetAllocation() string { @@ -2216,7 +2216,7 @@ type RenameObjectResponse struct { func (x *RenameObjectResponse) Reset() { *x = RenameObjectResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2229,7 +2229,7 @@ func (x *RenameObjectResponse) String() string { func (*RenameObjectResponse) ProtoMessage() {} func (x *RenameObjectResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[33] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2242,7 +2242,7 @@ func (x *RenameObjectResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use RenameObjectResponse.ProtoReflect.Descriptor instead. func (*RenameObjectResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{27} + return file_blobber_proto_rawDescGZIP(), []int{33} } func (x *RenameObjectResponse) GetFilename() string { @@ -2314,7 +2314,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[32] + mi := &file_blobber_proto_msgTypes[34] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2327,7 +2327,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[32] + mi := &file_blobber_proto_msgTypes[34] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2340,7 +2340,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{32} + return file_blobber_proto_rawDescGZIP(), []int{34} } func (x *Allocation) GetID() string { @@ -2477,7 +2477,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[33] + mi := &file_blobber_proto_msgTypes[35] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2490,7 +2490,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[33] + mi := &file_blobber_proto_msgTypes[35] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2503,7 +2503,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{33} + return file_blobber_proto_rawDescGZIP(), []int{35} } func (x *Term) GetID() int64 { @@ -2554,7 +2554,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[34] + mi := &file_blobber_proto_msgTypes[36] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2567,7 +2567,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[34] + mi := &file_blobber_proto_msgTypes[36] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2580,7 +2580,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{34} + return file_blobber_proto_rawDescGZIP(), []int{36} } func (x *FileRef) GetType() string { @@ -2638,7 +2638,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[35] + mi := &file_blobber_proto_msgTypes[37] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2651,7 +2651,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[35] + mi := &file_blobber_proto_msgTypes[37] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2664,7 +2664,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{35} + return file_blobber_proto_rawDescGZIP(), []int{37} } func (x *FileMetaData) GetType() string { @@ -2855,7 +2855,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[36] + mi := &file_blobber_proto_msgTypes[38] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2868,7 +2868,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[36] + mi := &file_blobber_proto_msgTypes[38] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2881,7 +2881,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{36} + return file_blobber_proto_rawDescGZIP(), []int{38} } func (x *DirMetaData) GetType() string { @@ -3246,6 +3246,30 @@ var file_blobber_proto_rawDesc = []byte{ 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, + 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xa6, 0x01, 0x0a, 0x13, 0x52, 0x65, + 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, + 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, + 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6e, 0x65, 0x77, 0x5f, 0x6e, + 0x61, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e, 0x65, 0x77, 0x4e, 0x61, + 0x6d, 0x65, 0x22, 0xd4, 0x01, 0x0a, 0x14, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, + 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, + 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x63, + 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, + 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, + 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, + 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, + 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, @@ -3370,7 +3394,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x32, 0xdd, 0x0e, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, + 0x32, 0xea, 0x0f, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, @@ -3432,66 +3456,75 @@ var file_blobber_proto_rawDesc = []byte{ 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x7e, 0x0a, 0x06, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8a, 0x01, 0x0a, 0x0c, + 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x27, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, + 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x72, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, - 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, - 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, - 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, - 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, - 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, - 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, - 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, - 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, - 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, + 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, + 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, + 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, + 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, + 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, + 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, + 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, + 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, - 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, - 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, - 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, - 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, - 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, - 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, - 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, - 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, - 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, + 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, 0x74, 0x72, 0x69, + 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, 0x0a, 0x0c, 0x43, + 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, + 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, + 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, } var ( @@ -3506,7 +3539,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 37) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 39) var file_blobber_proto_goTypes = []interface{}{ (*CollaboratorRequest)(nil), // 0: blobber.service.v1.CollaboratorRequest (*CollaboratorResponse)(nil), // 1: blobber.service.v1.CollaboratorResponse @@ -3540,11 +3573,13 @@ var file_blobber_proto_goTypes = []interface{}{ (*UpdateObjectAttributesResponse)(nil), // 29: blobber.service.v1.UpdateObjectAttributesResponse (*CopyObjectRequest)(nil), // 30: blobber.service.v1.CopyObjectRequest (*CopyObjectResponse)(nil), // 31: blobber.service.v1.CopyObjectResponse - (*Allocation)(nil), // 32: blobber.service.v1.Allocation - (*Term)(nil), // 33: blobber.service.v1.Term - (*FileRef)(nil), // 34: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 35: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 36: blobber.service.v1.DirMetaData + (*RenameObjectRequest)(nil), // 32: blobber.service.v1.RenameObjectRequest + (*RenameObjectResponse)(nil), // 33: blobber.service.v1.RenameObjectResponse + (*Allocation)(nil), // 34: blobber.service.v1.Allocation + (*Term)(nil), // 35: blobber.service.v1.Term + (*FileRef)(nil), // 36: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 37: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 38: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 25, // 0: blobber.service.v1.CollaboratorResponse.Collaborators:type_name -> blobber.service.v1.Collaborator @@ -3553,23 +3588,23 @@ var file_blobber_proto_depIdxs = []int32{ 16, // 3: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 12, // 4: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 16, // 5: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 34, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 36, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 12, // 7: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 15, // 8: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 16, // 9: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 34, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 34, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 34, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 34, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 34, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 34, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 36, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 36, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 36, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 36, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 36, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 36, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 21, // 16: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 34, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 36, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 25, // 18: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 32, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 33, // 20: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 35, // 21: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 36, // 22: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 34, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 35, // 20: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 37, // 21: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 38, // 22: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 24, // 23: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 26, // 24: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 22, // 25: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -3578,27 +3613,29 @@ var file_blobber_proto_depIdxs = []int32{ 13, // 28: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest 10, // 29: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest 8, // 30: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 4, // 31: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest - 2, // 32: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest - 6, // 33: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest - 28, // 34: blobber.service.v1.Blobber.UpdateObjectAttributes:input_type -> blobber.service.v1.UpdateObjectAttributesRequest - 30, // 35: blobber.service.v1.Blobber.CopyObject:input_type -> blobber.service.v1.CopyObjectRequest - 0, // 36: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest - 27, // 37: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 23, // 38: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 20, // 39: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 18, // 40: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 14, // 41: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 11, // 42: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 9, // 43: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 5, // 44: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 3, // 45: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 7, // 46: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 29, // 47: blobber.service.v1.Blobber.UpdateObjectAttributes:output_type -> blobber.service.v1.UpdateObjectAttributesResponse - 31, // 48: blobber.service.v1.Blobber.CopyObject:output_type -> blobber.service.v1.CopyObjectResponse - 1, // 49: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse - 37, // [37:50] is the sub-list for method output_type - 24, // [24:37] is the sub-list for method input_type + 32, // 31: blobber.service.v1.Blobber.RenameObject:input_type -> blobber.service.v1.RenameObjectRequest + 4, // 32: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest + 2, // 33: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest + 6, // 34: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest + 28, // 35: blobber.service.v1.Blobber.UpdateObjectAttributes:input_type -> blobber.service.v1.UpdateObjectAttributesRequest + 30, // 36: blobber.service.v1.Blobber.CopyObject:input_type -> blobber.service.v1.CopyObjectRequest + 0, // 37: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest + 27, // 38: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 23, // 39: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 20, // 40: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 18, // 41: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 14, // 42: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 11, // 43: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 9, // 44: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 33, // 45: blobber.service.v1.Blobber.RenameObject:output_type -> blobber.service.v1.RenameObjectResponse + 5, // 46: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 3, // 47: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 7, // 48: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 29, // 49: blobber.service.v1.Blobber.UpdateObjectAttributes:output_type -> blobber.service.v1.UpdateObjectAttributesResponse + 31, // 50: blobber.service.v1.Blobber.CopyObject:output_type -> blobber.service.v1.CopyObjectResponse + 1, // 51: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse + 38, // [38:52] is the sub-list for method output_type + 24, // [24:38] is the sub-list for method input_type 24, // [24:24] is the sub-list for extension type_name 24, // [24:24] is the sub-list for extension extendee 0, // [0:24] is the sub-list for field type_name @@ -3995,8 +4032,6 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { - file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RenameObjectRequest); i { case 0: return &v.state @@ -4009,7 +4044,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[33].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*RenameObjectResponse); i { case 0: return &v.state case 1: @@ -4021,7 +4056,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[34].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileRef); i { + switch v := v.(*Allocation); i { case 0: return &v.state case 1: @@ -4033,7 +4068,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[35].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FileMetaData); i { + switch v := v.(*Term); i { case 0: return &v.state case 1: @@ -4044,7 +4079,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[36].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileRef); i { case 0: return &v.state @@ -4056,7 +4091,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[37].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileMetaData); i { case 0: return &v.state @@ -4068,8 +4103,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { - file_blobber_proto_msgTypes[36].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[38].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -4088,7 +4122,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 37, + NumMessages: 39, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 7bca51351..a8b1a721e 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -203,13 +203,18 @@ func CopyObjectResponseCreator(r interface{}) *blobbergrpc.CopyObjectResponse { } } -func RenameObjectResponseHandler(renameObjectResponse *blobbergrpc.RenameObjectResponse) *blobberHTTP.UploadResult { - return &blobberHTTP.UploadResult{ - Filename: renameObjectResponse.Filename, - Size: renameObjectResponse.Size, - Hash: renameObjectResponse.ContentHash, - MerkleRoot: renameObjectResponse.MerkleRoot, - UploadLength: renameObjectResponse.UploadLength, - UploadOffset: renameObjectResponse.UploadOffset, +func RenameObjectResponseCreator(r interface{}) *blobbergrpc.RenameObjectResponse { + if r == nil { + return nil + } + + httpResp, _ := r.(*blobberHTTP.UploadResult) + return &blobbergrpc.RenameObjectResponse{ + Filename: httpResp.Filename, + Size: httpResp.Size, + ContentHash: httpResp.Hash, + MerkleRoot: httpResp.MerkleRoot, + UploadLength: httpResp.UploadLength, + UploadOffset: httpResp.UploadOffset, } } diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index ecf73f3a0..45b7163fb 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -31,7 +31,7 @@ func SetupHandlers(r *mux.Router) { //object operations r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) - r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) @@ -239,23 +239,14 @@ func ObjectTreeHandler(ctx context.Context, r *http.Request) (interface{}, error return response, nil } -func RenameHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - - renameObjResponse, err := svc.RenameObject(ctx, &blobbergrpc.RenameObjectRequest{ - Allocation: mux.Vars(r)["allocation"], - Path: r.FormValue("path"), - PathHash: r.FormValue("path_hash"), - ConnectionId: r.FormValue("connection_id"), - NewName: r.FormValue("new_name"), - }) - if err != nil { - return nil, err - } - - return convert.RenameObjectResponseHandler(renameObjResponse), nil +func RenameHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) + response, err := storageHandler.RenameObject(ctx, r) + if err != nil { + return nil, err } + + return response, nil } func CopyHandler(ctx context.Context, r *http.Request) (interface{}, error) { diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go index 87715f60a..49614a930 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/handler_test.go @@ -139,7 +139,7 @@ func setupHandlers() (*mux.Router, map[string]string) { rName := "Rename" router.HandleFunc(rPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(RenameHandler(svc)), + WithReadOnlyConnection(RenameHandler), ), ), ).Name(rName) diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index 977b6ef98..151d2f146 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -50,6 +50,23 @@ func (b *blobberGRPCService) CopyObject(ctx context.Context, req *blobbergrpc.Co return convert.CopyObjectResponseCreator(resp), nil } -func (b *blobberGRPCService) RenameObject(ctx context.Context, r *blobbergrpc.RenameObjectRequest) (*blobbergrpc.RenameObjectResponse, error) { - return nil, nil +func (b *blobberGRPCService) RenameObject(ctx context.Context, req *blobbergrpc.RenameObjectRequest) (*blobbergrpc.RenameObjectResponse, error) { + r, err := http.NewRequest("POST", "", nil) + if err != nil { + return nil, err + } + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "path_hash": {req.PathHash}, + "connection_id": {req.ConnectionId}, + "new_name": {req.NewName}, + } + + resp, err := RenameHandler(ctx, r) + if err != nil { + return nil, err + } + + return convert.RenameObjectResponseCreator(resp), nil } diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go deleted file mode 100644 index e69de29bb..000000000 From 23b7a80f88a4ac070c024f6c6834489486fbbf45 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 15 Jun 2021 23:24:27 +0530 Subject: [PATCH 130/183] grpc merge resolved for rename handler --- .../0chain.net/blobbercore/convert/responseHandler.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index e8bb8e8ee..8ddd47302 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -129,7 +129,7 @@ func GetObjectPathResponseCreator(r interface{}) *blobbergrpc.GetObjectPathRespo return &resp } -func CommitWriteResponseHandler(r interface{}) *blobbergrpc.CommitResponse { +func CommitWriteResponseCreator(r interface{}) *blobbergrpc.CommitResponse { if r == nil { return nil } @@ -144,14 +144,14 @@ func CommitWriteResponseHandler(r interface{}) *blobbergrpc.CommitResponse { } } -func GetCalculateHashResponseHandler(r interface{}) *blobbergrpc.CalculateHashResponse { +func GetCalculateHashResponseCreator(r interface{}) *blobbergrpc.CalculateHashResponse { httpResp, _ := r.(map[string]interface{}) msg, _ := httpResp["msg"].(string) return &blobbergrpc.CalculateHashResponse{Message: msg} } -func GetCommitMetaTxnHandlerResponse(r interface{}) *blobbergrpc.CommitMetaTxnResponse { +func GetCommitMetaTxnResponseCreator(r interface{}) *blobbergrpc.CommitMetaTxnResponse { msg, _ := r.(struct { Msg string `json:"msg"` }) @@ -159,7 +159,7 @@ func GetCommitMetaTxnHandlerResponse(r interface{}) *blobbergrpc.CommitMetaTxnRe return &blobbergrpc.CommitMetaTxnResponse{Message: msg.Msg} } -func CollaboratorResponse(r interface{}) *blobbergrpc.CollaboratorResponse { +func CollaboratorResponseCreator(r interface{}) *blobbergrpc.CollaboratorResponse { if r == nil { return nil } @@ -369,4 +369,4 @@ func RenameObjectResponseCreator(r interface{}) *blobbergrpc.RenameObjectRespons UploadLength: httpResp.UploadLength, UploadOffset: httpResp.UploadOffset, } -} \ No newline at end of file +} From e1f2731066da6322a6d199cdde505f09dfb2a3e0 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 16 Jun 2021 08:32:49 +0530 Subject: [PATCH 131/183] missing changes from previous commit --- code/go/0chain.net/blobbercore/handler/storage_handler.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/go/0chain.net/blobbercore/handler/storage_handler.go b/code/go/0chain.net/blobbercore/handler/storage_handler.go index 978925230..2be6c9d45 100644 --- a/code/go/0chain.net/blobbercore/handler/storage_handler.go +++ b/code/go/0chain.net/blobbercore/handler/storage_handler.go @@ -702,6 +702,8 @@ func (fsh *StorageHandler) CalculateHash(ctx context.Context, r *http.Request) ( // verifySignatureFromRequest verifies signature passed as common.ClientSignatureHeader header. func verifySignatureFromRequest(allocation, sign, pbK string) (bool, error) { + sign = encryption.MiraclToHerumiSig(sign) + if len(sign) < 64 { return false, nil } From b1a5f83003c2944782dc6234735da2bc827b123b Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 16 Jun 2021 08:57:59 +0530 Subject: [PATCH 132/183] deleting mock package --- .../blobbercore/mocks/PackageHandler.go | 401 ------------------ 1 file changed, 401 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/mocks/PackageHandler.go diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go deleted file mode 100644 index 86ac709c9..000000000 --- a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go +++ /dev/null @@ -1,401 +0,0 @@ -// Code generated by mockery 2.7.5. DO NOT EDIT. - -package mocks - -import ( - context "context" - - allocation "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - - mock "github.com/stretchr/testify/mock" - - reference "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - - stats "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" - - writemarker "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" -) - -// PackageHandler is an autogenerated mock type for the PackageHandler type -type PackageHandler struct { - mock.Mock -} - -// AddCollaborator provides a mock function with given fields: ctx, refID, clientID -func (_m *PackageHandler) AddCollaborator(ctx context.Context, refID int64, clientID string) error { - ret := _m.Called(ctx, refID, clientID) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { - r0 = rf(ctx, refID, clientID) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// AddCommitMetaTxn provides a mock function with given fields: ctx, refID, txnID -func (_m *PackageHandler) AddCommitMetaTxn(ctx context.Context, refID int64, txnID string) error { - ret := _m.Called(ctx, refID, txnID) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { - r0 = rf(ctx, refID, txnID) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// ApplyChanges provides a mock function with given fields: connectionObj, ctx, allocationRoot -func (_m *PackageHandler) ApplyChanges(connectionObj *allocation.AllocationChangeCollector, ctx context.Context, allocationRoot string) error { - ret := _m.Called(connectionObj, ctx, allocationRoot) - - var r0 error - if rf, ok := ret.Get(0).(func(*allocation.AllocationChangeCollector, context.Context, string) error); ok { - r0 = rf(connectionObj, ctx, allocationRoot) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// GetAllocationChanges provides a mock function with given fields: ctx, connectionID, allocationID, clientID -func (_m *PackageHandler) GetAllocationChanges(ctx context.Context, connectionID string, allocationID string, clientID string) (*allocation.AllocationChangeCollector, error) { - ret := _m.Called(ctx, connectionID, allocationID, clientID) - - var r0 *allocation.AllocationChangeCollector - if rf, ok := ret.Get(0).(func(context.Context, string, string, string) *allocation.AllocationChangeCollector); ok { - r0 = rf(ctx, connectionID, allocationID, clientID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*allocation.AllocationChangeCollector) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { - r1 = rf(ctx, connectionID, allocationID, clientID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetCollaborators provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetCollaborators(ctx context.Context, refID int64) ([]reference.Collaborator, error) { - ret := _m.Called(ctx, refID) - - var r0 []reference.Collaborator - if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.Collaborator); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]reference.Collaborator) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetCommitMetaTxns provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetCommitMetaTxns(ctx context.Context, refID int64) ([]reference.CommitMetaTxn, error) { - ret := _m.Called(ctx, refID) - - var r0 []reference.CommitMetaTxn - if rf, ok := ret.Get(0).(func(context.Context, int64) []reference.CommitMetaTxn); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]reference.CommitMetaTxn) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetFileStats provides a mock function with given fields: ctx, refID -func (_m *PackageHandler) GetFileStats(ctx context.Context, refID int64) (*stats.FileStats, error) { - ret := _m.Called(ctx, refID) - - var r0 *stats.FileStats - if rf, ok := ret.Get(0).(func(context.Context, int64) *stats.FileStats); ok { - r0 = rf(ctx, refID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*stats.FileStats) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok { - r1 = rf(ctx, refID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetObjectPath provides a mock function with given fields: ctx, allocationID, blockNum -func (_m *PackageHandler) GetObjectPath(ctx context.Context, allocationID string, blockNum int64) (*reference.ObjectPath, error) { - ret := _m.Called(ctx, allocationID, blockNum) - - var r0 *reference.ObjectPath - if rf, ok := ret.Get(0).(func(context.Context, string, int64) *reference.ObjectPath); ok { - r0 = rf(ctx, allocationID, blockNum) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.ObjectPath) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, int64) error); ok { - r1 = rf(ctx, allocationID, blockNum) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetObjectTree provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetObjectTree(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetRefWithChildren provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetRefWithChildren(ctx context.Context, allocationID string, path string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetReference provides a mock function with given fields: ctx, allocationID, newPath -func (_m *PackageHandler) GetReference(ctx context.Context, allocationID string, newPath string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, newPath) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, newPath) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, newPath) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetReferenceFromLookupHash provides a mock function with given fields: ctx, allocationID, path_hash -func (_m *PackageHandler) GetReferenceFromLookupHash(ctx context.Context, allocationID string, path_hash string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, path_hash) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, path_hash) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { - r1 = rf(ctx, allocationID, path_hash) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetReferenceLookup provides a mock function with given fields: ctx, allocationID, path -func (_m *PackageHandler) GetReferenceLookup(ctx context.Context, allocationID string, path string) string { - ret := _m.Called(ctx, allocationID, path) - - var r0 string - if rf, ok := ret.Get(0).(func(context.Context, string, string) string); ok { - r0 = rf(ctx, allocationID, path) - } else { - r0 = ret.Get(0).(string) - } - - return r0 -} - -// GetReferencePathFromPaths provides a mock function with given fields: ctx, allocationID, paths -func (_m *PackageHandler) GetReferencePathFromPaths(ctx context.Context, allocationID string, paths []string) (*reference.Ref, error) { - ret := _m.Called(ctx, allocationID, paths) - - var r0 *reference.Ref - if rf, ok := ret.Get(0).(func(context.Context, string, []string) *reference.Ref); ok { - r0 = rf(ctx, allocationID, paths) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*reference.Ref) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string, []string) error); ok { - r1 = rf(ctx, allocationID, paths) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetWriteMarkerEntity provides a mock function with given fields: ctx, allocation_root -func (_m *PackageHandler) GetWriteMarkerEntity(ctx context.Context, allocation_root string) (*writemarker.WriteMarkerEntity, error) { - ret := _m.Called(ctx, allocation_root) - - var r0 *writemarker.WriteMarkerEntity - if rf, ok := ret.Get(0).(func(context.Context, string) *writemarker.WriteMarkerEntity); ok { - r0 = rf(ctx, allocation_root) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*writemarker.WriteMarkerEntity) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(context.Context, string) error); ok { - r1 = rf(ctx, allocation_root) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// IsACollaborator provides a mock function with given fields: ctx, refID, clientID -func (_m *PackageHandler) IsACollaborator(ctx context.Context, refID int64, clientID string) bool { - ret := _m.Called(ctx, refID, clientID) - - var r0 bool - if rf, ok := ret.Get(0).(func(context.Context, int64, string) bool); ok { - r0 = rf(ctx, refID, clientID) - } else { - r0 = ret.Get(0).(bool) - } - - return r0 -} - -// RemoveCollaborator provides a mock function with given fields: ctx, refID, clientID -func (_m *PackageHandler) RemoveCollaborator(ctx context.Context, refID int64, clientID string) error { - ret := _m.Called(ctx, refID, clientID) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, int64, string) error); ok { - r0 = rf(ctx, refID, clientID) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// SaveAllocationChanges provides a mock function with given fields: ctx, alloc -func (_m *PackageHandler) SaveAllocationChanges(ctx context.Context, alloc *allocation.AllocationChangeCollector) error { - ret := _m.Called(ctx, alloc) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *allocation.AllocationChangeCollector) error); ok { - r0 = rf(ctx, alloc) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// UpdateAllocationAndCommitChanges provides a mock function with given fields: ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot -func (_m *PackageHandler) UpdateAllocationAndCommitChanges(ctx context.Context, writemarkerObj *writemarker.WriteMarkerEntity, connectionObj *allocation.AllocationChangeCollector, allocationObj *allocation.Allocation, allocationRoot string) error { - ret := _m.Called(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *writemarker.WriteMarkerEntity, *allocation.AllocationChangeCollector, *allocation.Allocation, string) error); ok { - r0 = rf(ctx, writemarkerObj, connectionObj, allocationObj, allocationRoot) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// VerifyMarker provides a mock function with given fields: wm, ctx, sa, co -func (_m *PackageHandler) VerifyMarker(wm *writemarker.WriteMarkerEntity, ctx context.Context, sa *allocation.Allocation, co *allocation.AllocationChangeCollector) error { - ret := _m.Called(wm, ctx, sa, co) - - var r0 error - if rf, ok := ret.Get(0).(func(*writemarker.WriteMarkerEntity, context.Context, *allocation.Allocation, *allocation.AllocationChangeCollector) error); ok { - r0 = rf(wm, ctx, sa, co) - } else { - r0 = ret.Error(0) - } - - return r0 -} From a5bc5dfc2366789b28bbbf86b26b38b0cc36d9fd Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Thu, 17 Jun 2021 19:22:57 +0530 Subject: [PATCH 133/183] test file deleted --- .../object_operation_grpc_handler_test.go | 146 ------------------ 1 file changed, 146 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go deleted file mode 100644 index 7a97bacc8..000000000 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ /dev/null @@ -1,146 +0,0 @@ -package handler - -import ( - "context" - "encoding/json" - "errors" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/mocks" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/core/common" - "github.com/0chain/blobber/code/go/0chain.net/core/encryption" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/mock" - "google.golang.org/grpc/metadata" - "testing" -) - -func TestBlobberGRPCService_DownloadFile_Success(t *testing.T) { - allocationTx := randString(32) - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - req := &blobbergrpc.DownloadFileRequest{ - Allocation: allocationTx, - Path: `path`, - RxPay: "false", - NumBlocks: "5", - BlockNum: "5", - ReadMarker: `{}`, - AuthToken: "", - Content: "", - } - - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "client_key", - common.ClientSignatureHeader: clientSignature, - })) - ctx = setupGRPCHandlerContext(ctx, GetGRPCMetaDataFromCtx(ctx), req.Allocation) - - alloc := &allocation.Allocation{ - Tx: req.Allocation, - ID: `allocation_id`, - OwnerID: `client`, - OwnerPublicKey: pubKey, - } - - rm := &readmarker.ReadMarker{ - AllocationID: alloc.ID, - ClientPublicKey: `client_key`, - ClientID: `client`, - Signature: clientSignature, - OwnerID: alloc.OwnerID, - } - rmStr, _ := json.Marshal(rm) - req.ReadMarker = string(rmStr) - - //var pentBlocksNum = int64(10) - var latestRm = &readmarker.ReadMarker{} - - mockStorageHandler := &storageHandlerI{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). - Return(alloc, nil) - mockStorageHandler.On(`readPreRedeem`, mock.Anything, alloc, int64(5), int64(0), alloc.OwnerID).Return( - nil) - - mockFileStore := &mocks.FileStore{} - mockFileStore.On(`GetFileBlock`, alloc.ID, mock.Anything, int64(5), int64(5)).Return( - []byte{}, nil) - mockReferencePackage := &mocks.PackageHandler{} - pathHash := req.Allocation + `:` + req.Path - mockReferencePackage.On(`GetReferenceLookup`, mock.Anything, alloc.ID, req.Path). - Return(pathHash) - mockReferencePackage.On(`VerifyReadMarker`, mock.Anything, mock.Anything, alloc). - Return(nil) - - objectRef := &reference.Ref{ - Name: "test", - ID: 123, - ContentHash: `hash`, - MerkleRoot: `root`, - Size: 1, - Type: reference.FILE, - } - - rme := &readmarker.ReadMarkerEntity{ - RedeemRequired: false, - LatestRM: latestRm, - } - - mockReferencePackage.On(`GetReferenceFromLookupHash`, mock.Anything, alloc.ID, pathHash). - Return(objectRef, nil) - mockReferencePackage.On(`IsACollaborator`, mock.Anything, objectRef.ID, alloc.OwnerID). - Return(true) - mockReferencePackage.On(`GetLatestReadMarkerEntity`, mock.Anything, alloc.OwnerID). - Return(rme, nil) - mockReferencePackage.On(`GetFileStore`). - Return(mockFileStore) - mockReferencePackage.On(`SaveLatestReadMarker`, mock.Anything, mock.Anything, false). - Return(nil) - mockReferencePackage.On(`FileBlockDownloaded`, mock.Anything, objectRef.ID). - Return() - mockReferencePackage.On(`GetNewReadMaker`, mock.Anything).Return(rme) - - resOk := &blobbergrpc.DownloadFileResponse{ - Success: false, - LatestRm: convert.ReadMarkerToReadMarkerGRPC(latestRm), - } - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - gotResponse, err := svc.DownloadFile(ctx, req) - if err != nil { - t.Fatal("unexpected error - " + err.Error()) - } - - assert.Equal(t, gotResponse, resOk) -} - -func TestBlobberGRPCService_DownloadFile_InvalidAllocation(t *testing.T) { - req := &blobbergrpc.DownloadFileRequest{ - Allocation: `invalid_allocation`, - } - ctx := metadata.NewIncomingContext(context.Background(), metadata.New(map[string]string{ - common.ClientHeader: "client", - common.ClientKeyHeader: "client_key", - common.ClientSignatureHeader: "clientSignature", - })) - - mockStorageHandler := &storageHandlerI{} - mockStorageHandler.On("verifyAllocation", mock.Anything, req.Allocation, false). - Return(nil, errors.New("some error")) - - mockReferencePackage := &mocks.PackageHandler{} - - svc := newGRPCBlobberService(mockStorageHandler, mockReferencePackage) - _, err := svc.DownloadFile(ctx, req) - if err == nil { - t.Fatal("expected error") - } - if err.Error() != "invalid_parameters: Invalid allocation id passed.some error" { - t.Fatal(`unexpected error - `, err) - } -} From 90057e29658494fc918274ffc03acdabacfc4083 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Thu, 17 Jun 2021 20:02:09 +0530 Subject: [PATCH 134/183] grpc -> http download handler updated and resolved conflicts --- .../blobbercore/blobbergrpc/blobber.pb.go | 923 ++++++++++-------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 8 +- .../blobbergrpc/blobber_grpc.pb.go | 6 +- .../blobbercore/convert/responseHandler.go | 25 +- .../0chain.net/blobbercore/handler/handler.go | 24 +- .../handler/object_operation_grpc_handler.go | 230 +---- .../blobbercore/mocks/PackageHandler.go | 0 7 files changed, 541 insertions(+), 675 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/mocks/PackageHandler.go diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index f55df0ffc..69a7777c5 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -1844,7 +1844,7 @@ type DownloadFileRequest struct { func (x *DownloadFileRequest) Reset() { *x = DownloadFileRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1857,7 +1857,7 @@ func (x *DownloadFileRequest) String() string { func (*DownloadFileRequest) ProtoMessage() {} func (x *DownloadFileRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1870,7 +1870,7 @@ func (x *DownloadFileRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use DownloadFileRequest.ProtoReflect.Descriptor instead. func (*DownloadFileRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{28} } func (x *DownloadFileRequest) GetAllocation() string { @@ -1951,7 +1951,7 @@ type DownloadFileResponse struct { func (x *DownloadFileResponse) Reset() { *x = DownloadFileResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1964,7 +1964,7 @@ func (x *DownloadFileResponse) String() string { func (*DownloadFileResponse) ProtoMessage() {} func (x *DownloadFileResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[29] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1977,7 +1977,7 @@ func (x *DownloadFileResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use DownloadFileResponse.ProtoReflect.Descriptor instead. func (*DownloadFileResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{27} + return file_blobber_proto_rawDescGZIP(), []int{29} } func (x *DownloadFileResponse) GetSuccess() bool { @@ -2036,7 +2036,7 @@ type ReadMaker struct { func (x *ReadMaker) Reset() { *x = ReadMaker{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2049,7 +2049,7 @@ func (x *ReadMaker) String() string { func (*ReadMaker) ProtoMessage() {} func (x *ReadMaker) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[30] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2062,7 +2062,7 @@ func (x *ReadMaker) ProtoReflect() protoreflect.Message { // Deprecated: Use ReadMaker.ProtoReflect.Descriptor instead. func (*ReadMaker) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{28} + return file_blobber_proto_rawDescGZIP(), []int{30} } func (x *ReadMaker) GetClientId() string { @@ -2157,7 +2157,7 @@ type UpdateObjectAttributesRequest struct { func (x *UpdateObjectAttributesRequest) Reset() { *x = UpdateObjectAttributesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2170,7 +2170,7 @@ func (x *UpdateObjectAttributesRequest) String() string { func (*UpdateObjectAttributesRequest) ProtoMessage() {} func (x *UpdateObjectAttributesRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[28] + mi := &file_blobber_proto_msgTypes[31] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2183,7 +2183,7 @@ func (x *UpdateObjectAttributesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateObjectAttributesRequest.ProtoReflect.Descriptor instead. func (*UpdateObjectAttributesRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{28} + return file_blobber_proto_rawDescGZIP(), []int{31} } func (x *UpdateObjectAttributesRequest) GetAllocation() string { @@ -2232,7 +2232,7 @@ type UpdateObjectAttributesResponse struct { func (x *UpdateObjectAttributesResponse) Reset() { *x = UpdateObjectAttributesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2245,7 +2245,7 @@ func (x *UpdateObjectAttributesResponse) String() string { func (*UpdateObjectAttributesResponse) ProtoMessage() {} func (x *UpdateObjectAttributesResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[29] + mi := &file_blobber_proto_msgTypes[32] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2258,7 +2258,7 @@ func (x *UpdateObjectAttributesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateObjectAttributesResponse.ProtoReflect.Descriptor instead. func (*UpdateObjectAttributesResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{29} + return file_blobber_proto_rawDescGZIP(), []int{32} } func (x *UpdateObjectAttributesResponse) GetWhoPaysForReads() int64 { @@ -2283,7 +2283,7 @@ type CopyObjectRequest struct { func (x *CopyObjectRequest) Reset() { *x = CopyObjectRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2296,7 +2296,7 @@ func (x *CopyObjectRequest) String() string { func (*CopyObjectRequest) ProtoMessage() {} func (x *CopyObjectRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[30] + mi := &file_blobber_proto_msgTypes[33] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2309,7 +2309,7 @@ func (x *CopyObjectRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CopyObjectRequest.ProtoReflect.Descriptor instead. func (*CopyObjectRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{30} + return file_blobber_proto_rawDescGZIP(), []int{33} } func (x *CopyObjectRequest) GetAllocation() string { @@ -2365,7 +2365,7 @@ type CopyObjectResponse struct { func (x *CopyObjectResponse) Reset() { *x = CopyObjectResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[31] + mi := &file_blobber_proto_msgTypes[34] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2378,7 +2378,7 @@ func (x *CopyObjectResponse) String() string { func (*CopyObjectResponse) ProtoMessage() {} func (x *CopyObjectResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[31] + mi := &file_blobber_proto_msgTypes[34] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2391,7 +2391,7 @@ func (x *CopyObjectResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CopyObjectResponse.ProtoReflect.Descriptor instead. func (*CopyObjectResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{31} + return file_blobber_proto_rawDescGZIP(), []int{34} } func (x *CopyObjectResponse) GetFilename() string { @@ -2451,7 +2451,7 @@ type RenameObjectRequest struct { func (x *RenameObjectRequest) Reset() { *x = RenameObjectRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[32] + mi := &file_blobber_proto_msgTypes[35] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2464,7 +2464,7 @@ func (x *RenameObjectRequest) String() string { func (*RenameObjectRequest) ProtoMessage() {} func (x *RenameObjectRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[32] + mi := &file_blobber_proto_msgTypes[35] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2477,7 +2477,7 @@ func (x *RenameObjectRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use RenameObjectRequest.ProtoReflect.Descriptor instead. func (*RenameObjectRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{32} + return file_blobber_proto_rawDescGZIP(), []int{35} } func (x *RenameObjectRequest) GetAllocation() string { @@ -2533,7 +2533,7 @@ type RenameObjectResponse struct { func (x *RenameObjectResponse) Reset() { *x = RenameObjectResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[33] + mi := &file_blobber_proto_msgTypes[36] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2546,7 +2546,7 @@ func (x *RenameObjectResponse) String() string { func (*RenameObjectResponse) ProtoMessage() {} func (x *RenameObjectResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[33] + mi := &file_blobber_proto_msgTypes[36] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2559,7 +2559,7 @@ func (x *RenameObjectResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use RenameObjectResponse.ProtoReflect.Descriptor instead. func (*RenameObjectResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{33} + return file_blobber_proto_rawDescGZIP(), []int{36} } func (x *RenameObjectResponse) GetFilename() string { @@ -2631,7 +2631,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[34] + mi := &file_blobber_proto_msgTypes[37] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2644,7 +2644,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[34] + mi := &file_blobber_proto_msgTypes[37] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2657,7 +2657,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{34} + return file_blobber_proto_rawDescGZIP(), []int{37} } func (x *Allocation) GetID() string { @@ -2794,7 +2794,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[35] + mi := &file_blobber_proto_msgTypes[38] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2807,7 +2807,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[35] + mi := &file_blobber_proto_msgTypes[38] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2820,7 +2820,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{35} + return file_blobber_proto_rawDescGZIP(), []int{38} } func (x *Term) GetID() int64 { @@ -2871,7 +2871,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[36] + mi := &file_blobber_proto_msgTypes[39] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2884,7 +2884,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[36] + mi := &file_blobber_proto_msgTypes[39] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2897,7 +2897,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{36} + return file_blobber_proto_rawDescGZIP(), []int{39} } func (x *FileRef) GetType() string { @@ -2955,7 +2955,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[37] + mi := &file_blobber_proto_msgTypes[40] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2968,7 +2968,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[37] + mi := &file_blobber_proto_msgTypes[40] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2981,7 +2981,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{37} + return file_blobber_proto_rawDescGZIP(), []int{40} } func (x *FileMetaData) GetType() string { @@ -3172,7 +3172,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[38] + mi := &file_blobber_proto_msgTypes[41] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3185,7 +3185,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[38] + mi := &file_blobber_proto_msgTypes[41] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3198,7 +3198,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{38} + return file_blobber_proto_rawDescGZIP(), []int{41} } func (x *DirMetaData) GetType() string { @@ -3523,325 +3523,385 @@ var file_blobber_proto_rawDesc = []byte{ 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb5, 0x01, - 0x0a, 0x1d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, - 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, - 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, - 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, - 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, - 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, - 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, - 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, - 0x74, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, - 0x62, 0x75, 0x74, 0x65, 0x73, 0x22, 0x4d, 0x0a, 0x1e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2b, 0x0a, 0x12, 0x77, 0x68, 0x6f, 0x5f, 0x70, - 0x61, 0x79, 0x73, 0x5f, 0x66, 0x6f, 0x72, 0x5f, 0x72, 0x65, 0x61, 0x64, 0x73, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0f, 0x77, 0x68, 0x6f, 0x50, 0x61, 0x79, 0x73, 0x46, 0x6f, 0x72, 0x52, - 0x65, 0x61, 0x64, 0x73, 0x22, 0x9d, 0x01, 0x0a, 0x11, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, - 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, - 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, - 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, - 0x12, 0x12, 0x0a, 0x04, 0x64, 0x65, 0x73, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x64, 0x65, 0x73, 0x74, 0x22, 0xd2, 0x01, 0x0a, 0x12, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, - 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, - 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x63, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, - 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, - 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, - 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, - 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, - 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xa6, 0x01, 0x0a, 0x13, 0x52, 0x65, - 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, - 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, - 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, - 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6e, 0x65, 0x77, 0x5f, 0x6e, - 0x61, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e, 0x65, 0x77, 0x4e, 0x61, - 0x6d, 0x65, 0x22, 0xd4, 0x01, 0x0a, 0x14, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, - 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, - 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x63, - 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, - 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, - 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, - 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, - 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, - 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, - 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, - 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, - 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, - 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, - 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, - 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, - 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, - 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, - 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, - 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, - 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, - 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, - 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, - 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, - 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, - 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, - 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, - 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, - 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, - 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, - 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, - 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, - 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, - 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, - 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, - 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, - 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, - 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, - 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, - 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, - 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, - 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, - 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, - 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, - 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, - 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, - 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, - 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, - 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, - 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, - 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, - 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, - 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, - 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, - 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, - 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, - 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, - 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, - 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, - 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, - 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, - 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, - 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, - 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, - 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, - 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, - 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, - 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, - 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, - 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, - 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, - 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, - 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, - 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, - 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, - 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, - 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, - 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, - 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, - 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, - 0x32, 0xea, 0x0f, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, - 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, - 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, - 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, + 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x93, 0x02, + 0x0a, 0x13, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, + 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, + 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x15, 0x0a, 0x06, 0x72, 0x78, 0x5f, 0x70, 0x61, 0x79, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x72, 0x78, 0x50, 0x61, 0x79, 0x12, 0x1b, 0x0a, + 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x12, 0x1d, 0x0a, 0x0a, 0x6e, 0x75, + 0x6d, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x6e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1f, 0x0a, 0x0b, 0x72, 0x65, 0x61, + 0x64, 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x72, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, + 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, + 0x74, 0x65, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, + 0x65, 0x6e, 0x74, 0x22, 0xb9, 0x01, 0x0a, 0x14, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, + 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, + 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0c, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, + 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x12, 0x3a, 0x0a, 0x09, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x72, 0x6d, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x61, 0x64, + 0x4d, 0x61, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x6d, 0x22, + 0xdf, 0x02, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x6b, 0x65, 0x72, 0x12, 0x1b, 0x0a, + 0x09, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x2a, 0x0a, 0x11, 0x63, 0x6c, + 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x50, 0x75, 0x62, + 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x49, 0x64, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6f, 0x77, + 0x6e, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6f, 0x77, + 0x6e, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, + 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, + 0x61, 0x6d, 0x70, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x12, 0x1c, 0x0a, + 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, + 0x75, 0x73, 0x70, 0x65, 0x6e, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x73, 0x75, + 0x73, 0x70, 0x65, 0x6e, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x70, 0x61, 0x79, 0x65, 0x72, 0x5f, 0x69, + 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x70, 0x61, 0x79, 0x65, 0x72, 0x49, 0x64, + 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, + 0x0b, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x54, 0x69, 0x63, 0x6b, 0x65, + 0x74, 0x22, 0xb5, 0x01, 0x0a, 0x1d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, + 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, + 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, + 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x74, 0x74, + 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, + 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x22, 0x4d, 0x0a, 0x1e, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2b, 0x0a, 0x12, 0x77, + 0x68, 0x6f, 0x5f, 0x70, 0x61, 0x79, 0x73, 0x5f, 0x66, 0x6f, 0x72, 0x5f, 0x72, 0x65, 0x61, 0x64, + 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x77, 0x68, 0x6f, 0x50, 0x61, 0x79, 0x73, + 0x46, 0x6f, 0x72, 0x52, 0x65, 0x61, 0x64, 0x73, 0x22, 0x9d, 0x01, 0x0a, 0x11, 0x43, 0x6f, 0x70, + 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, + 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, + 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, + 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, + 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x65, 0x73, 0x74, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x64, 0x65, 0x73, 0x74, 0x22, 0xd2, 0x01, 0x0a, 0x12, 0x43, 0x6f, 0x70, + 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, + 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, + 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, + 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, + 0x6f, 0x6f, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, + 0x6e, 0x67, 0x74, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, + 0x61, 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, + 0x61, 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xa6, 0x01, + 0x0a, 0x13, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, + 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, + 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, + 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, + 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6e, + 0x65, 0x77, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e, + 0x65, 0x77, 0x4e, 0x61, 0x6d, 0x65, 0x22, 0xd4, 0x01, 0x0a, 0x14, 0x52, 0x65, 0x6e, 0x61, 0x6d, + 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, + 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, + 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, + 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, + 0x6f, 0x6f, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, + 0x6e, 0x67, 0x74, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, + 0x61, 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, + 0x61, 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xb6, 0x04, + 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, + 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, + 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, + 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, + 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, + 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, + 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, + 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, + 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, + 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, + 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, + 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, + 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, + 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, + 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, + 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, + 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, + 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, + 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, + 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, + 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, + 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, + 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, + 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, + 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, + 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, + 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, + 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, + 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, + 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, + 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, + 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, + 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, + 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, + 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, - 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, - 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, - 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, - 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, - 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, - 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, - 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, + 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, + 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, + 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, + 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, + 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, + 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, + 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, + 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, + 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, + 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, + 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, + 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, + 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, + 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, + 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, + 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, + 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, + 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, + 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, + 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, + 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, + 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, + 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, + 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, + 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, + 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, + 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, + 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, + 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, + 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, + 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, + 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, + 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, + 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, + 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, + 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, + 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, + 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x64, 0x41, 0x74, 0x32, 0xf9, 0x10, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, + 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, + 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, - 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, - 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, - 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, - 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, - 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8a, 0x01, 0x0a, 0x0c, - 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x27, 0x2e, 0x62, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, + 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, + 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, + 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, + 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, + 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, + 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, + 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, + 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, + 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, - 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x72, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, - 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, - 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, - 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, + 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, + 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, + 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, + 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, + 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, - 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, - 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, - 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, - 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, - 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, - 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, - 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, + 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, + 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, + 0x8c, 0x01, 0x0a, 0x0c, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, + 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, + 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, + 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x64, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x8a, + 0x01, 0x0a, 0x0c, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, + 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, + 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, + 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, + 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, + 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, + 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, + 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, + 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, + 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, - 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, 0x74, 0x72, 0x69, - 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, 0x0a, 0x0c, 0x43, - 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, - 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2f, 0x7b, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, - 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, - 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x33, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, + 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, + 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, + 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, + 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, + 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, + 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, + 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, + 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -3856,7 +3916,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 39) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 42) var file_blobber_proto_goTypes = []interface{}{ (*CollaboratorRequest)(nil), // 0: blobber.service.v1.CollaboratorRequest (*CollaboratorResponse)(nil), // 1: blobber.service.v1.CollaboratorResponse @@ -3886,17 +3946,20 @@ var file_blobber_proto_goTypes = []interface{}{ (*Collaborator)(nil), // 25: blobber.service.v1.Collaborator (*GetAllocationRequest)(nil), // 26: blobber.service.v1.GetAllocationRequest (*GetAllocationResponse)(nil), // 27: blobber.service.v1.GetAllocationResponse - (*UpdateObjectAttributesRequest)(nil), // 28: blobber.service.v1.UpdateObjectAttributesRequest - (*UpdateObjectAttributesResponse)(nil), // 29: blobber.service.v1.UpdateObjectAttributesResponse - (*CopyObjectRequest)(nil), // 30: blobber.service.v1.CopyObjectRequest - (*CopyObjectResponse)(nil), // 31: blobber.service.v1.CopyObjectResponse - (*RenameObjectRequest)(nil), // 32: blobber.service.v1.RenameObjectRequest - (*RenameObjectResponse)(nil), // 33: blobber.service.v1.RenameObjectResponse - (*Allocation)(nil), // 34: blobber.service.v1.Allocation - (*Term)(nil), // 35: blobber.service.v1.Term - (*FileRef)(nil), // 36: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 37: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 38: blobber.service.v1.DirMetaData + (*DownloadFileRequest)(nil), // 28: blobber.service.v1.DownloadFileRequest + (*DownloadFileResponse)(nil), // 29: blobber.service.v1.DownloadFileResponse + (*ReadMaker)(nil), // 30: blobber.service.v1.ReadMaker + (*UpdateObjectAttributesRequest)(nil), // 31: blobber.service.v1.UpdateObjectAttributesRequest + (*UpdateObjectAttributesResponse)(nil), // 32: blobber.service.v1.UpdateObjectAttributesResponse + (*CopyObjectRequest)(nil), // 33: blobber.service.v1.CopyObjectRequest + (*CopyObjectResponse)(nil), // 34: blobber.service.v1.CopyObjectResponse + (*RenameObjectRequest)(nil), // 35: blobber.service.v1.RenameObjectRequest + (*RenameObjectResponse)(nil), // 36: blobber.service.v1.RenameObjectResponse + (*Allocation)(nil), // 37: blobber.service.v1.Allocation + (*Term)(nil), // 38: blobber.service.v1.Term + (*FileRef)(nil), // 39: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 40: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 41: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 25, // 0: blobber.service.v1.CollaboratorResponse.Collaborators:type_name -> blobber.service.v1.Collaborator @@ -3905,57 +3968,60 @@ var file_blobber_proto_depIdxs = []int32{ 16, // 3: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 12, // 4: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 16, // 5: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 36, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 39, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 12, // 7: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 15, // 8: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 16, // 9: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 36, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 36, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 36, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 36, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 36, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 36, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 39, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 39, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 39, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 39, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 39, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 39, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 21, // 16: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 36, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 39, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 25, // 18: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 34, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation - 35, // 20: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 37, // 21: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 38, // 22: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 24, // 23: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn - 26, // 24: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest - 22, // 25: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest - 19, // 26: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest - 17, // 27: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest - 13, // 28: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest - 10, // 29: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest - 8, // 30: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest - 32, // 31: blobber.service.v1.Blobber.RenameObject:input_type -> blobber.service.v1.RenameObjectRequest - 4, // 32: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest - 2, // 33: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest - 6, // 34: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest - 28, // 35: blobber.service.v1.Blobber.UpdateObjectAttributes:input_type -> blobber.service.v1.UpdateObjectAttributesRequest - 30, // 36: blobber.service.v1.Blobber.CopyObject:input_type -> blobber.service.v1.CopyObjectRequest - 0, // 37: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest - 27, // 38: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 23, // 39: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 20, // 40: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 18, // 41: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 14, // 42: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 11, // 43: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 9, // 44: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 33, // 45: blobber.service.v1.Blobber.RenameObject:output_type -> blobber.service.v1.RenameObjectResponse - 5, // 46: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 3, // 47: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 7, // 48: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 29, // 49: blobber.service.v1.Blobber.UpdateObjectAttributes:output_type -> blobber.service.v1.UpdateObjectAttributesResponse - 31, // 50: blobber.service.v1.Blobber.CopyObject:output_type -> blobber.service.v1.CopyObjectResponse - 1, // 51: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse - 38, // [38:52] is the sub-list for method output_type - 24, // [24:38] is the sub-list for method input_type - 24, // [24:24] is the sub-list for extension type_name - 24, // [24:24] is the sub-list for extension extendee - 0, // [0:24] is the sub-list for field type_name + 37, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 30, // 20: blobber.service.v1.DownloadFileResponse.latest_rm:type_name -> blobber.service.v1.ReadMaker + 38, // 21: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 40, // 22: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 41, // 23: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 24, // 24: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 26, // 25: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest + 22, // 26: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest + 19, // 27: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest + 17, // 28: blobber.service.v1.Blobber.ListEntities:input_type -> blobber.service.v1.ListEntitiesRequest + 13, // 29: blobber.service.v1.Blobber.GetObjectPath:input_type -> blobber.service.v1.GetObjectPathRequest + 10, // 30: blobber.service.v1.Blobber.GetReferencePath:input_type -> blobber.service.v1.GetReferencePathRequest + 8, // 31: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest + 28, // 32: blobber.service.v1.Blobber.DownloadFile:input_type -> blobber.service.v1.DownloadFileRequest + 35, // 33: blobber.service.v1.Blobber.RenameObject:input_type -> blobber.service.v1.RenameObjectRequest + 4, // 34: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest + 2, // 35: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest + 6, // 36: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest + 31, // 37: blobber.service.v1.Blobber.UpdateObjectAttributes:input_type -> blobber.service.v1.UpdateObjectAttributesRequest + 33, // 38: blobber.service.v1.Blobber.CopyObject:input_type -> blobber.service.v1.CopyObjectRequest + 0, // 39: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest + 27, // 40: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 23, // 41: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 20, // 42: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 18, // 43: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 14, // 44: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 11, // 45: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 9, // 46: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 29, // 47: blobber.service.v1.Blobber.DownloadFile:output_type -> blobber.service.v1.DownloadFileResponse + 36, // 48: blobber.service.v1.Blobber.RenameObject:output_type -> blobber.service.v1.RenameObjectResponse + 5, // 49: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 3, // 50: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 7, // 51: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 32, // 52: blobber.service.v1.Blobber.UpdateObjectAttributes:output_type -> blobber.service.v1.UpdateObjectAttributesResponse + 34, // 53: blobber.service.v1.Blobber.CopyObject:output_type -> blobber.service.v1.CopyObjectResponse + 1, // 54: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse + 40, // [40:55] is the sub-list for method output_type + 25, // [25:40] is the sub-list for method input_type + 25, // [25:25] is the sub-list for extension type_name + 25, // [25:25] is the sub-list for extension extendee + 0, // [0:25] is the sub-list for field type_name } func init() { file_blobber_proto_init() } @@ -4300,7 +4366,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DownloadFileRequest); i { case 0: return &v.state @@ -4312,7 +4378,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DownloadFileResponse); i { case 0: return &v.state @@ -4324,7 +4390,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*ReadMaker); i { case 0: return &v.state @@ -4336,8 +4402,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { - file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*UpdateObjectAttributesRequest); i { case 0: return &v.state @@ -4349,7 +4414,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*UpdateObjectAttributesResponse); i { case 0: return &v.state @@ -4361,7 +4426,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[33].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*CopyObjectRequest); i { case 0: return &v.state @@ -4373,7 +4438,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[34].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*CopyObjectResponse); i { case 0: return &v.state @@ -4385,7 +4450,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[35].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RenameObjectRequest); i { case 0: return &v.state @@ -4397,7 +4462,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[33].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[36].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*RenameObjectResponse); i { case 0: return &v.state @@ -4409,7 +4474,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[34].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[37].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Allocation); i { case 0: return &v.state @@ -4421,7 +4486,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[35].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[38].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Term); i { case 0: return &v.state @@ -4433,7 +4498,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[36].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[39].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileRef); i { case 0: return &v.state @@ -4445,7 +4510,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[37].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[40].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileMetaData); i { case 0: return &v.state @@ -4457,7 +4522,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[38].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[41].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -4476,7 +4541,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 39, + NumMessages: 42, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 25df98fb1..26529fec6 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -1741,10 +1741,10 @@ var ( pattern_Blobber_GetObjectTree_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "objecttree", "allocation"}, "")) - pattern_Blobber_RenameObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "rename", "allocation"}, "")) - pattern_Blobber_DownloadFile_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "download", "allocation"}, "")) + pattern_Blobber_RenameObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "rename", "allocation"}, "")) + pattern_Blobber_Commit_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "connection", "commit", "allocation"}, "")) pattern_Blobber_CalculateHash_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "calculatehash", "allocation"}, "")) @@ -1773,10 +1773,10 @@ var ( forward_Blobber_GetObjectTree_0 = runtime.ForwardResponseMessage - forward_Blobber_RenameObject_0 = runtime.ForwardResponseMessage - forward_Blobber_DownloadFile_0 = runtime.ForwardResponseMessage + forward_Blobber_RenameObject_0 = runtime.ForwardResponseMessage + forward_Blobber_Commit_0 = runtime.ForwardResponseMessage forward_Blobber_CalculateHash_0 = runtime.ForwardResponseMessage diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 3f154e6c8..fae41df83 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -224,12 +224,12 @@ func (UnimplementedBlobberServer) GetReferencePath(context.Context, *GetReferenc func (UnimplementedBlobberServer) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetObjectTree not implemented") } -func (UnimplementedBlobberServer) RenameObject(context.Context, *RenameObjectRequest) (*RenameObjectResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method RenameObject not implemented") -} func (UnimplementedBlobberServer) DownloadFile(context.Context, *DownloadFileRequest) (*DownloadFileResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DownloadFile not implemented") } +func (UnimplementedBlobberServer) RenameObject(context.Context, *RenameObjectRequest) (*RenameObjectResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RenameObject not implemented") +} func (UnimplementedBlobberServer) Commit(context.Context, *CommitRequest) (*CommitResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Commit not implemented") } diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index c6616201f..34c99bbc3 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -319,16 +319,6 @@ func GetCommitMetaTxnHandlerResponse(response *blobbergrpc.CommitMetaTxnResponse return result } -func DownloadFileResponseHandler(downloadFileResponse *blobbergrpc.DownloadFileResponse) *blobberHTTP.DownloadResponse { - return &blobberHTTP.DownloadResponse{ - Success: downloadFileResponse.Success, - Data: downloadFileResponse.Data, - AllocationID: downloadFileResponse.AllocationId, - Path: downloadFileResponse.Path, - LatestRM: ReadMakerGRPCToReadMaker(downloadFileResponse.LatestRm), - } -} - func CollaboratorResponse(response *blobbergrpc.CollaboratorResponse) interface{} { if msg := response.GetMessage(); msg != "" { return struct { @@ -380,3 +370,18 @@ func RenameObjectResponseCreator(r interface{}) *blobbergrpc.RenameObjectRespons UploadOffset: httpResp.UploadOffset, } } + +func DownloadFileResponseCreator(r interface{}) *blobbergrpc.DownloadFileResponse { + if r == nil { + return nil + } + + httpResp, _ := r.(*blobberHTTP.DownloadResponse) + return &blobbergrpc.DownloadFileResponse{ + Success: httpResp.Success, + Data: httpResp.Data, + AllocationId: httpResp.AllocationID, + Path: httpResp.Path, + LatestRm: ReadMarkerToReadMarkerGRPC(httpResp.LatestRM), + } +} diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index 2aa653ae7..45b7163fb 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -30,7 +30,7 @@ func GetMetaDataStore() *datastore.Store { func SetupHandlers(r *mux.Router) { //object operations r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) - r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler(svc))))).Methods(http.MethodPost) + r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) r.HandleFunc("/v1/file/attributes/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UpdateAttributesHandler)))) @@ -168,23 +168,15 @@ func FileStatsHandler(ctx context.Context, r *http.Request) (interface{}, error) } /*DownloadHandler is the handler to respond to download requests from clients*/ -func DownloadHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - - downloadFileResponse, err := svc.DownloadFile(ctx, &blobbergrpc.DownloadFileRequest{ - Path: r.FormValue("path"), - PathHash: r.FormValue("path_hash"), - AuthToken: r.FormValue("auth_token"), - Allocation: mux.Vars(r)["allocation"], - }) - if err != nil { - return nil, err - } +func DownloadHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) - //handle if there are two response type from handler - return convert.DownloadFileResponseHandler(downloadFileResponse), nil + response, err := storageHandler.DownloadFile(ctx, r) + if err != nil { + return nil, err } + + return response, nil } /*ListHandler is the handler to respond to upload requests fro clients*/ diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index 7dbbe7d4d..c9d1f9cd5 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -2,10 +2,9 @@ package handler import ( "context" - "net/http" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" + "net/http" ) func (b *blobberGRPCService) UpdateObjectAttributes(ctx context.Context, req *blobbergrpc.UpdateObjectAttributesRequest) (*blobbergrpc.UpdateObjectAttributesResponse, error) { @@ -71,224 +70,29 @@ func (b *blobberGRPCService) RenameObject(ctx context.Context, req *blobbergrpc. return convert.RenameObjectResponseCreator(resp), nil } -func (b *blobberGRPCService) DownloadFile(ctx context.Context, r *blobbergrpc.DownloadFileRequest) (*blobbergrpc.DownloadFileResponse, error) { - md := GetGRPCMetaDataFromCtx(ctx) - ctx = setupGRPCHandlerContext(ctx, md, r.Allocation) - - clientID := md.Client - if len(clientID) == 0 { - return nil, common.NewError("download_file", "invalid client") - } - - allocationTx := r.Allocation - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) - if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - var allocationID = allocationObj.ID - - if len(clientID) == 0 || allocationObj.OwnerID != clientID { - return nil, common.NewError( - "invalid_operation", "Operation needs to be performed by the owner of the allocation") - } - - rxPay := r.RxPay == "true" - pathHash := r.PathHash - path := r.Path - if len(pathHash) == 0 { - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") - } - pathHash = b.packageHandler.GetReferenceLookup(ctx, allocationObj.ID, path) - } - - var blockNumStr = r.BlockNum - if len(blockNumStr) == 0 { - return nil, common.NewError("download_file", "no block number") - } - - var blockNum int64 - blockNum, err = strconv.ParseInt(blockNumStr, 10, 64) - if err != nil || blockNum < 0 { - return nil, common.NewError("download_file", "invalid block number") - } - - // we can add r.NumBlocks as int64 if len() validation is not required - var numBlocksStr = r.NumBlocks - if len(numBlocksStr) == 0 { - numBlocksStr = "1" - } - - var numBlocks int64 - numBlocks, err = strconv.ParseInt(numBlocksStr, 10, 64) - if err != nil || numBlocks < 0 { - return nil, common.NewError("download_file", - "invalid number of blocks") - } - - var ( - readMarkerString = r.ReadMarker - readMarker = &readmarker.ReadMarker{} - ) - err = json.Unmarshal([]byte(readMarkerString), readMarker) - if err != nil { - return nil, common.NewErrorf("download_file", "invalid parameters, "+ - "error parsing the readmarker for download: %v", err) - } - - var rmObj = &readmarker.ReadMarkerEntity{} - rmObj.LatestRM = readMarker - - if err = b.packageHandler.VerifyReadMarker(ctx, rmObj, allocationObj); err != nil { - return nil, common.NewErrorf("download_file", "invalid read marker, "+ - "failed to verify the read marker: %v", err) - } - - var fileref *reference.Ref - fileref, err = b.packageHandler.GetReferenceFromLookupHash(ctx, allocationID, pathHash) - if err != nil { - return nil, common.NewErrorf("download_file", - "invalid file path: %v", err) - } - if fileref.Type != reference.FILE { - return nil, common.NewErrorf("download_file", - "path is not a file: %v", err) - } - - var ( - authTokenString = r.AuthToken - clientIDForReadRedeem = clientID // default payer is client - isACollaborator = b.packageHandler.IsACollaborator(ctx, fileref.ID, clientID) - ) - // Owner will pay for collaborator - if isACollaborator { - clientIDForReadRedeem = allocationObj.OwnerID - } - - if (allocationObj.OwnerID != clientID && - allocationObj.PayerID != clientID && - !isACollaborator) || len(authTokenString) > 0 { - - var authTicketVerified bool - authTicketVerified, err = b.storageHandler.verifyAuthTicket(ctx, r.AuthToken, allocationObj, - fileref, clientID) - if err != nil { - return nil, common.NewErrorf("download_file", - "verifying auth ticket: %v", err) - } - - if !authTicketVerified { - return nil, common.NewErrorf("download_file", - "could not verify the auth ticket") - } - - var authToken = &readmarker.AuthTicket{} - err = json.Unmarshal([]byte(authTokenString), &authToken) - if err != nil { - return nil, common.NewErrorf("download_file", - "error parsing the auth ticket for download: %v", err) - } - - var attrs *reference.Attributes - if attrs, err = fileref.GetAttributes(); err != nil { - return nil, common.NewErrorf("download_file", - "error getting file attributes: %v", err) - } - - // if --rx_pay used 3rd_party pays - if rxPay { - clientIDForReadRedeem = clientID - } else if attrs.WhoPaysForReads == common.WhoPaysOwner { - clientIDForReadRedeem = allocationObj.OwnerID // owner pays - } - readMarker.AuthTicket = datatypes.JSON(authTokenString) - } - - var ( - rme *readmarker.ReadMarkerEntity - latestRM *readmarker.ReadMarker - pendNumBlocks int64 - ) - rme, err = b.packageHandler.GetLatestReadMarkerEntity(ctx, clientID) - if err != nil && !errors.Is(err, gorm.ErrRecordNotFound) { - return nil, common.NewErrorf("download_file", - "couldn't get read marker from DB: %v", err) - } - - if rme != nil { - latestRM = rme.LatestRM - if pendNumBlocks, err = rme.PendNumBlocks(); err != nil { - return nil, common.NewErrorf("download_file", - "couldn't get number of blocks pending redeeming: %v", err) - } - } - - if latestRM != nil && - latestRM.ReadCounter+(numBlocks) != readMarker.ReadCounter { - - var response = &blobbergrpc.DownloadFileResponse{ - Success: false, - LatestRm: convert.ReadMarkerToReadMarkerGRPC(latestRM), - Path: fileref.Path, - AllocationId: fileref.AllocationID, - } - return response, nil - } +func (b *blobberGRPCService) DownloadFile(ctx context.Context, req *blobbergrpc.DownloadFileRequest) (*blobbergrpc.DownloadFileResponse, error) { - // check out read pool tokens if read_price > 0 - err = b.storageHandler.readPreRedeem(ctx, allocationObj, numBlocks, pendNumBlocks, - clientIDForReadRedeem) + r, err := http.NewRequest("POST", "", nil) if err != nil { - return nil, common.NewErrorf("download_file", - "pre-redeeming read marker: %v", err) + return nil, err } - // reading allowed - var ( - downloadMode = r.Content - respData []byte - ) - if len(downloadMode) > 0 && downloadMode == DOWNLOAD_CONTENT_THUMB { - var fileData = &filestore.FileInputData{} - fileData.Name = fileref.Name - fileData.Path = fileref.Path - fileData.Hash = fileref.ThumbnailHash - fileData.OnCloud = fileref.OnCloud - respData, err = b.packageHandler.GetFileStore().GetFileBlock(allocationID, - fileData, blockNum, numBlocks) - if err != nil { - return nil, common.NewErrorf("download_file", - "couldn't get thumbnail block: %v", err) - } - } else { - var fileData = &filestore.FileInputData{} - fileData.Name = fileref.Name - fileData.Path = fileref.Path - fileData.Hash = fileref.ContentHash - fileData.OnCloud = fileref.OnCloud - respData, err = b.packageHandler.GetFileStore().GetFileBlock(allocationID, - fileData, blockNum, numBlocks) - if err != nil { - return nil, common.NewErrorf("download_file", - "couldn't get file block: %v", err) - } + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "path_hash": {req.PathHash}, + "rx_pay": {req.RxPay}, + "block_num": {req.BlockNum}, + "num_blocks": {req.NumBlocks}, + "read_marker": {req.ReadMarker}, + "auth_token": {req.AuthToken}, + "content": {req.AuthToken}, } - readMarker.PayerID = clientIDForReadRedeem - err = b.packageHandler.SaveLatestReadMarker(ctx, readMarker, latestRM == nil) + resp, err := DownloadHandler(ctx, r) if err != nil { - return nil, common.NewErrorf("download_file", - "couldn't save latest read marker: %v", err) + return nil, err } - var response = &blobbergrpc.DownloadFileResponse{} - response.Success = true - response.LatestRm = convert.ReadMarkerToReadMarkerGRPC(readMarker) - response.Data = respData - response.Path = fileref.Path - response.AllocationId = fileref.AllocationID - - b.packageHandler.FileBlockDownloaded(ctx, fileref.ID) - //originally here is respData, need to clarify - return response, nil + return convert.DownloadFileResponseCreator(resp), nil } diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go deleted file mode 100644 index e69de29bb..000000000 From 47e1fac29904d44b54f14e38591451d9fc86739e Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Thu, 17 Jun 2021 20:09:14 +0530 Subject: [PATCH 135/183] go lint error fixed on store handler --- code/go/0chain.net/blobbercore/handler/storage_handler.go | 6 ------ 1 file changed, 6 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/storage_handler.go b/code/go/0chain.net/blobbercore/handler/storage_handler.go index 9317559e2..2be6c9d45 100644 --- a/code/go/0chain.net/blobbercore/handler/storage_handler.go +++ b/code/go/0chain.net/blobbercore/handler/storage_handler.go @@ -77,12 +77,6 @@ func (fsh *StorageHandler) verifyAuthTicket(ctx context.Context, authTokenString return true, nil } -func (fsh *StorageHandler) readPreRedeem( - ctx context.Context, alloc *allocation.Allocation, numBlocks, pendNumBlocks int64, payerID string) (err error) { - - return readPreRedeem(ctx, alloc, numBlocks, pendNumBlocks, payerID) -} - func (fsh *StorageHandler) GetAllocationDetails(ctx context.Context, r *http.Request) (interface{}, error) { if r.Method != "GET" { return nil, common.NewError("invalid_method", "Invalid method used. Use GET instead") From 802a04d9146d52acb7b6f0a0729d0a9bc862646d Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Fri, 18 Jun 2021 23:14:15 +0530 Subject: [PATCH 136/183] delete mocks --- .../0chain.net/blobbercore/mocks/FileStore.go | 275 ------------------ 1 file changed, 275 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/mocks/FileStore.go diff --git a/code/go/0chain.net/blobbercore/mocks/FileStore.go b/code/go/0chain.net/blobbercore/mocks/FileStore.go deleted file mode 100644 index 49207775b..000000000 --- a/code/go/0chain.net/blobbercore/mocks/FileStore.go +++ /dev/null @@ -1,275 +0,0 @@ -// Code generated by mockery 2.7.5. DO NOT EDIT. - -package mocks - -import ( - json "encoding/json" - - filestore "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" - - mock "github.com/stretchr/testify/mock" - - multipart "mime/multipart" - - util "github.com/0chain/blobber/code/go/0chain.net/core/util" -) - -// FileStore is an autogenerated mock type for the FileStore type -type FileStore struct { - mock.Mock -} - -// CommitWrite provides a mock function with given fields: allocationID, fileData, connectionID -func (_m *FileStore) CommitWrite(allocationID string, fileData *filestore.FileInputData, connectionID string) (bool, error) { - ret := _m.Called(allocationID, fileData, connectionID) - - var r0 bool - if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, string) bool); ok { - r0 = rf(allocationID, fileData, connectionID) - } else { - r0 = ret.Get(0).(bool) - } - - var r1 error - if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, string) error); ok { - r1 = rf(allocationID, fileData, connectionID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// DeleteFile provides a mock function with given fields: allocationID, contentHash -func (_m *FileStore) DeleteFile(allocationID string, contentHash string) error { - ret := _m.Called(allocationID, contentHash) - - var r0 error - if rf, ok := ret.Get(0).(func(string, string) error); ok { - r0 = rf(allocationID, contentHash) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// DeleteTempFile provides a mock function with given fields: allocationID, fileData, connectionID -func (_m *FileStore) DeleteTempFile(allocationID string, fileData *filestore.FileInputData, connectionID string) error { - ret := _m.Called(allocationID, fileData, connectionID) - - var r0 error - if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, string) error); ok { - r0 = rf(allocationID, fileData, connectionID) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// DownloadFromCloud provides a mock function with given fields: fileHash, filePath -func (_m *FileStore) DownloadFromCloud(fileHash string, filePath string) error { - ret := _m.Called(fileHash, filePath) - - var r0 error - if rf, ok := ret.Get(0).(func(string, string) error); ok { - r0 = rf(fileHash, filePath) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// GetFileBlock provides a mock function with given fields: allocationID, fileData, blockNum, numBlocks -func (_m *FileStore) GetFileBlock(allocationID string, fileData *filestore.FileInputData, blockNum int64, numBlocks int64) ([]byte, error) { - ret := _m.Called(allocationID, fileData, blockNum, numBlocks) - - var r0 []byte - if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, int64, int64) []byte); ok { - r0 = rf(allocationID, fileData, blockNum, numBlocks) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]byte) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, int64, int64) error); ok { - r1 = rf(allocationID, fileData, blockNum, numBlocks) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetFileBlockForChallenge provides a mock function with given fields: allocationID, fileData, blockoffset -func (_m *FileStore) GetFileBlockForChallenge(allocationID string, fileData *filestore.FileInputData, blockoffset int) (json.RawMessage, util.MerkleTreeI, error) { - ret := _m.Called(allocationID, fileData, blockoffset) - - var r0 json.RawMessage - if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, int) json.RawMessage); ok { - r0 = rf(allocationID, fileData, blockoffset) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(json.RawMessage) - } - } - - var r1 util.MerkleTreeI - if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, int) util.MerkleTreeI); ok { - r1 = rf(allocationID, fileData, blockoffset) - } else { - if ret.Get(1) != nil { - r1 = ret.Get(1).(util.MerkleTreeI) - } - } - - var r2 error - if rf, ok := ret.Get(2).(func(string, *filestore.FileInputData, int) error); ok { - r2 = rf(allocationID, fileData, blockoffset) - } else { - r2 = ret.Error(2) - } - - return r0, r1, r2 -} - -// GetTempPathSize provides a mock function with given fields: allocationID -func (_m *FileStore) GetTempPathSize(allocationID string) (int64, error) { - ret := _m.Called(allocationID) - - var r0 int64 - if rf, ok := ret.Get(0).(func(string) int64); ok { - r0 = rf(allocationID) - } else { - r0 = ret.Get(0).(int64) - } - - var r1 error - if rf, ok := ret.Get(1).(func(string) error); ok { - r1 = rf(allocationID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetTotalDiskSizeUsed provides a mock function with given fields: -func (_m *FileStore) GetTotalDiskSizeUsed() (int64, error) { - ret := _m.Called() - - var r0 int64 - if rf, ok := ret.Get(0).(func() int64); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(int64) - } - - var r1 error - if rf, ok := ret.Get(1).(func() error); ok { - r1 = rf() - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetlDiskSizeUsed provides a mock function with given fields: allocationID -func (_m *FileStore) GetlDiskSizeUsed(allocationID string) (int64, error) { - ret := _m.Called(allocationID) - - var r0 int64 - if rf, ok := ret.Get(0).(func(string) int64); ok { - r0 = rf(allocationID) - } else { - r0 = ret.Get(0).(int64) - } - - var r1 error - if rf, ok := ret.Get(1).(func(string) error); ok { - r1 = rf(allocationID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// IterateObjects provides a mock function with given fields: allocationID, handler -func (_m *FileStore) IterateObjects(allocationID string, handler filestore.FileObjectHandler) error { - ret := _m.Called(allocationID, handler) - - var r0 error - if rf, ok := ret.Get(0).(func(string, filestore.FileObjectHandler) error); ok { - r0 = rf(allocationID, handler) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// SetupAllocation provides a mock function with given fields: allocationID, skipCreate -func (_m *FileStore) SetupAllocation(allocationID string, skipCreate bool) (*filestore.StoreAllocation, error) { - ret := _m.Called(allocationID, skipCreate) - - var r0 *filestore.StoreAllocation - if rf, ok := ret.Get(0).(func(string, bool) *filestore.StoreAllocation); ok { - r0 = rf(allocationID, skipCreate) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*filestore.StoreAllocation) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(string, bool) error); ok { - r1 = rf(allocationID, skipCreate) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// UploadToCloud provides a mock function with given fields: fileHash, filePath -func (_m *FileStore) UploadToCloud(fileHash string, filePath string) error { - ret := _m.Called(fileHash, filePath) - - var r0 error - if rf, ok := ret.Get(0).(func(string, string) error); ok { - r0 = rf(fileHash, filePath) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// WriteFile provides a mock function with given fields: allocationID, fileData, infile, connectionID -func (_m *FileStore) WriteFile(allocationID string, fileData *filestore.FileInputData, infile multipart.File, connectionID string) (*filestore.FileOutputData, error) { - ret := _m.Called(allocationID, fileData, infile, connectionID) - - var r0 *filestore.FileOutputData - if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, multipart.File, string) *filestore.FileOutputData); ok { - r0 = rf(allocationID, fileData, infile, connectionID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*filestore.FileOutputData) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, multipart.File, string) error); ok { - r1 = rf(allocationID, fileData, infile, connectionID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} From c6bcd743453af712491b882156e596f15f225e36 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Sun, 20 Jun 2021 20:02:04 +0530 Subject: [PATCH 137/183] grpc -> http upload handler merged grpc --- .../blobbercore/blobbergrpc/blobber.pb.go | 737 +++++++++--------- .../blobbergrpc/blobber_grpc.pb.go | 2 +- .../blobbercore/convert/responseHandler.go | 21 +- .../0chain.net/blobbercore/handler/handler.go | 54 +- .../blobbercore/handler/handler_test.go | 67 +- .../handler/object_operation_grpc_handler.go | 220 ++---- .../object_operation_grpc_handler_test.go | 1 - .../0chain.net/blobbercore/mocks/FileStore.go | 300 ------- .../blobbercore/mocks/PackageHandler.go | 0 9 files changed, 458 insertions(+), 944 deletions(-) delete mode 100644 code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go delete mode 100644 code/go/0chain.net/blobbercore/mocks/FileStore.go delete mode 100644 code/go/0chain.net/blobbercore/mocks/PackageHandler.go diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index c4f2f503e..dc79bc8ab 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -2622,7 +2622,7 @@ type UploadFileRequest struct { func (x *UploadFileRequest) Reset() { *x = UploadFileRequest{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[37] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2635,7 +2635,7 @@ func (x *UploadFileRequest) String() string { func (*UploadFileRequest) ProtoMessage() {} func (x *UploadFileRequest) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[26] + mi := &file_blobber_proto_msgTypes[37] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2648,7 +2648,7 @@ func (x *UploadFileRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use UploadFileRequest.ProtoReflect.Descriptor instead. func (*UploadFileRequest) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{26} + return file_blobber_proto_rawDescGZIP(), []int{37} } func (x *UploadFileRequest) GetAllocation() string { @@ -2725,7 +2725,7 @@ type UploadFileResponse struct { func (x *UploadFileResponse) Reset() { *x = UploadFileResponse{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[38] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2738,7 +2738,7 @@ func (x *UploadFileResponse) String() string { func (*UploadFileResponse) ProtoMessage() {} func (x *UploadFileResponse) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[27] + mi := &file_blobber_proto_msgTypes[38] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2751,7 +2751,7 @@ func (x *UploadFileResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use UploadFileResponse.ProtoReflect.Descriptor instead. func (*UploadFileResponse) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{27} + return file_blobber_proto_rawDescGZIP(), []int{38} } func (x *UploadFileResponse) GetFilename() string { @@ -2823,7 +2823,7 @@ type Allocation struct { func (x *Allocation) Reset() { *x = Allocation{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[37] + mi := &file_blobber_proto_msgTypes[39] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2836,7 +2836,7 @@ func (x *Allocation) String() string { func (*Allocation) ProtoMessage() {} func (x *Allocation) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[37] + mi := &file_blobber_proto_msgTypes[39] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2849,7 +2849,7 @@ func (x *Allocation) ProtoReflect() protoreflect.Message { // Deprecated: Use Allocation.ProtoReflect.Descriptor instead. func (*Allocation) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{37} + return file_blobber_proto_rawDescGZIP(), []int{39} } func (x *Allocation) GetID() string { @@ -2986,7 +2986,7 @@ type Term struct { func (x *Term) Reset() { *x = Term{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[38] + mi := &file_blobber_proto_msgTypes[40] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2999,7 +2999,7 @@ func (x *Term) String() string { func (*Term) ProtoMessage() {} func (x *Term) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[38] + mi := &file_blobber_proto_msgTypes[40] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3012,7 +3012,7 @@ func (x *Term) ProtoReflect() protoreflect.Message { // Deprecated: Use Term.ProtoReflect.Descriptor instead. func (*Term) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{38} + return file_blobber_proto_rawDescGZIP(), []int{40} } func (x *Term) GetID() int64 { @@ -3063,7 +3063,7 @@ type FileRef struct { func (x *FileRef) Reset() { *x = FileRef{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[39] + mi := &file_blobber_proto_msgTypes[41] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3076,7 +3076,7 @@ func (x *FileRef) String() string { func (*FileRef) ProtoMessage() {} func (x *FileRef) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[39] + mi := &file_blobber_proto_msgTypes[41] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3089,7 +3089,7 @@ func (x *FileRef) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRef.ProtoReflect.Descriptor instead. func (*FileRef) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{39} + return file_blobber_proto_rawDescGZIP(), []int{41} } func (x *FileRef) GetType() string { @@ -3147,7 +3147,7 @@ type FileMetaData struct { func (x *FileMetaData) Reset() { *x = FileMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[40] + mi := &file_blobber_proto_msgTypes[42] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3160,7 +3160,7 @@ func (x *FileMetaData) String() string { func (*FileMetaData) ProtoMessage() {} func (x *FileMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[40] + mi := &file_blobber_proto_msgTypes[42] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3173,7 +3173,7 @@ func (x *FileMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use FileMetaData.ProtoReflect.Descriptor instead. func (*FileMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{40} + return file_blobber_proto_rawDescGZIP(), []int{42} } func (x *FileMetaData) GetType() string { @@ -3364,7 +3364,7 @@ type DirMetaData struct { func (x *DirMetaData) Reset() { *x = DirMetaData{} if protoimpl.UnsafeEnabled { - mi := &file_blobber_proto_msgTypes[41] + mi := &file_blobber_proto_msgTypes[43] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3377,7 +3377,7 @@ func (x *DirMetaData) String() string { func (*DirMetaData) ProtoMessage() {} func (x *DirMetaData) ProtoReflect() protoreflect.Message { - mi := &file_blobber_proto_msgTypes[41] + mi := &file_blobber_proto_msgTypes[43] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3390,7 +3390,7 @@ func (x *DirMetaData) ProtoReflect() protoreflect.Message { // Deprecated: Use DirMetaData.ProtoReflect.Descriptor instead. func (*DirMetaData) Descriptor() ([]byte, []int) { - return file_blobber_proto_rawDescGZIP(), []int{41} + return file_blobber_proto_rawDescGZIP(), []int{43} } func (x *DirMetaData) GetType() string { @@ -3830,270 +3830,307 @@ var file_blobber_proto_rawDesc = []byte{ 0x6e, 0x67, 0x74, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xb6, 0x04, - 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, - 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, - 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, - 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x55, 0x73, - 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x55, 0x73, - 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, - 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, - 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, - 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, - 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, - 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, - 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, - 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, - 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, - 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, - 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, - 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, - 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, - 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, - 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x0e, 0x20, - 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, - 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, - 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, 0x18, 0x0a, 0x07, - 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, - 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, - 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, - 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, 0x22, 0x0a, - 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, - 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, - 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, - 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x54, - 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, - 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, 0x44, 0x69, 0x72, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, - 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, - 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, - 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, - 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, - 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, 0x6d, - 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, 0x75, - 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, - 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, - 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x65, 0x72, - 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4d, - 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, - 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, - 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, - 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x4d, 0x69, 0x6d, - 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x4d, 0x69, 0x6d, - 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, - 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, - 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, - 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, - 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, - 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, - 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, - 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, - 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x45, 0x6e, 0x63, - 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x41, 0x74, 0x74, - 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x41, - 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x6e, 0x43, - 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, 0x6e, 0x43, 0x6c, - 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, - 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1c, - 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, 0x0a, 0x0b, 0x44, - 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, - 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, - 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, - 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, - 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, 0x4e, 0x75, - 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x4e, - 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x74, 0x68, - 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x74, 0x68, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x08, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, - 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, - 0x65, 0x64, 0x41, 0x74, 0x32, 0xf9, 0x10, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, - 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x8e, - 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, + 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0x9b, 0x02, + 0x0a, 0x11, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, + 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, + 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6d, 0x65, + 0x74, 0x68, 0x6f, 0x64, 0x12, 0x1f, 0x0a, 0x0b, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6d, + 0x65, 0x74, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x75, 0x70, 0x6c, 0x6f, 0x61, + 0x64, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x1f, 0x0a, 0x0b, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x5f, + 0x6d, 0x65, 0x74, 0x61, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x1f, 0x0a, 0x0b, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, + 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x75, 0x70, 0x6c, + 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x32, 0x0a, 0x15, 0x75, 0x70, 0x6c, 0x6f, 0x61, + 0x64, 0x5f, 0x74, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x5f, 0x66, 0x69, 0x6c, 0x65, + 0x18, 0x08, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x13, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x22, 0xd2, 0x01, 0x0a, 0x12, + 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, + 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, + 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, + 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, + 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, + 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, + 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, + 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, + 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, + 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, + 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, + 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, + 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, + 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, + 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, + 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, + 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, + 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, + 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, + 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, + 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, + 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, + 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, + 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, + 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, + 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, + 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, + 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, + 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, + 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, + 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, + 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, + 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, - 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, - 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, - 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, - 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, - 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, - 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, - 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, - 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, - 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, - 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, - 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, - 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, - 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, - 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, - 0x8c, 0x01, 0x0a, 0x0c, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, - 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, - 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, - 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x64, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x8a, - 0x01, 0x0a, 0x0c, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, - 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, - 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, - 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, - 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, + 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, + 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, + 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, + 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, + 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, + 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, + 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, + 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, + 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, + 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, - 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, - 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, - 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, - 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, - 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, + 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, + 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, + 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, + 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, + 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, + 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, + 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, + 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, + 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, + 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, + 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, + 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, + 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, + 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, + 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, + 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, + 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, + 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, + 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, + 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, + 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, + 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, + 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, + 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, + 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, + 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, + 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, + 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, - 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, - 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, - 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, - 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, - 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, - 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, - 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, + 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, + 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, + 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, + 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, + 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, + 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, + 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, + 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, + 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, + 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, + 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xd7, 0x11, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, - 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, + 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, + 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, + 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, + 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, + 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, + 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, + 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, + 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, + 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, + 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x7d, 0x12, 0x8c, 0x01, 0x0a, 0x0c, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, + 0x69, 0x6c, 0x65, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, + 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x64, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, + 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, + 0x2a, 0x12, 0x8a, 0x01, 0x0a, 0x0c, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, + 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x5c, + 0x0a, 0x09, 0x57, 0x72, 0x69, 0x74, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x25, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, + 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x7e, 0x0a, 0x06, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, + 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, - 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, - 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, - 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, - 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, + 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, + 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, + 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, + 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, + 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, + 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, + 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, + 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, + 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, + 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, + 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, + 0x01, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, + 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, + 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, + 0x72, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, + 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, + 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, + 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -4108,7 +4145,7 @@ func file_blobber_proto_rawDescGZIP() []byte { return file_blobber_proto_rawDescData } -var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 42) +var file_blobber_proto_msgTypes = make([]protoimpl.MessageInfo, 44) var file_blobber_proto_goTypes = []interface{}{ (*CollaboratorRequest)(nil), // 0: blobber.service.v1.CollaboratorRequest (*CollaboratorResponse)(nil), // 1: blobber.service.v1.CollaboratorResponse @@ -4147,11 +4184,13 @@ var file_blobber_proto_goTypes = []interface{}{ (*CopyObjectResponse)(nil), // 34: blobber.service.v1.CopyObjectResponse (*RenameObjectRequest)(nil), // 35: blobber.service.v1.RenameObjectRequest (*RenameObjectResponse)(nil), // 36: blobber.service.v1.RenameObjectResponse - (*Allocation)(nil), // 37: blobber.service.v1.Allocation - (*Term)(nil), // 38: blobber.service.v1.Term - (*FileRef)(nil), // 39: blobber.service.v1.FileRef - (*FileMetaData)(nil), // 40: blobber.service.v1.FileMetaData - (*DirMetaData)(nil), // 41: blobber.service.v1.DirMetaData + (*UploadFileRequest)(nil), // 37: blobber.service.v1.UploadFileRequest + (*UploadFileResponse)(nil), // 38: blobber.service.v1.UploadFileResponse + (*Allocation)(nil), // 39: blobber.service.v1.Allocation + (*Term)(nil), // 40: blobber.service.v1.Term + (*FileRef)(nil), // 41: blobber.service.v1.FileRef + (*FileMetaData)(nil), // 42: blobber.service.v1.FileMetaData + (*DirMetaData)(nil), // 43: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ 25, // 0: blobber.service.v1.CollaboratorResponse.Collaborators:type_name -> blobber.service.v1.Collaborator @@ -4160,24 +4199,24 @@ var file_blobber_proto_depIdxs = []int32{ 16, // 3: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker 12, // 4: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath 16, // 5: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 39, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef + 41, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef 12, // 7: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath 15, // 8: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath 16, // 9: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 39, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 39, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 39, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 39, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 39, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 39, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef + 41, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef + 41, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef + 41, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef + 41, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef + 41, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef + 41, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef 21, // 16: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 39, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef + 41, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef 25, // 18: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator - 37, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation + 39, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation 30, // 20: blobber.service.v1.DownloadFileResponse.latest_rm:type_name -> blobber.service.v1.ReadMaker - 38, // 21: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 40, // 22: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 41, // 23: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData + 40, // 21: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term + 42, // 22: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData + 43, // 23: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData 24, // 24: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn 26, // 25: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 22, // 26: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest @@ -4188,29 +4227,31 @@ var file_blobber_proto_depIdxs = []int32{ 8, // 31: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest 28, // 32: blobber.service.v1.Blobber.DownloadFile:input_type -> blobber.service.v1.DownloadFileRequest 35, // 33: blobber.service.v1.Blobber.RenameObject:input_type -> blobber.service.v1.RenameObjectRequest - 4, // 34: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest - 2, // 35: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest - 6, // 36: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest - 31, // 37: blobber.service.v1.Blobber.UpdateObjectAttributes:input_type -> blobber.service.v1.UpdateObjectAttributesRequest - 33, // 38: blobber.service.v1.Blobber.CopyObject:input_type -> blobber.service.v1.CopyObjectRequest - 0, // 39: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest - 27, // 40: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse - 23, // 41: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse - 20, // 42: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse - 18, // 43: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse - 14, // 44: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse - 11, // 45: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse - 9, // 46: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse - 29, // 47: blobber.service.v1.Blobber.DownloadFile:output_type -> blobber.service.v1.DownloadFileResponse - 36, // 48: blobber.service.v1.Blobber.RenameObject:output_type -> blobber.service.v1.RenameObjectResponse - 5, // 49: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse - 3, // 50: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse - 7, // 51: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse - 32, // 52: blobber.service.v1.Blobber.UpdateObjectAttributes:output_type -> blobber.service.v1.UpdateObjectAttributesResponse - 34, // 53: blobber.service.v1.Blobber.CopyObject:output_type -> blobber.service.v1.CopyObjectResponse - 1, // 54: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse - 40, // [40:55] is the sub-list for method output_type - 25, // [25:40] is the sub-list for method input_type + 37, // 34: blobber.service.v1.Blobber.WriteFile:input_type -> blobber.service.v1.UploadFileRequest + 4, // 35: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest + 2, // 36: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest + 6, // 37: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest + 31, // 38: blobber.service.v1.Blobber.UpdateObjectAttributes:input_type -> blobber.service.v1.UpdateObjectAttributesRequest + 33, // 39: blobber.service.v1.Blobber.CopyObject:input_type -> blobber.service.v1.CopyObjectRequest + 0, // 40: blobber.service.v1.Blobber.Collaborator:input_type -> blobber.service.v1.CollaboratorRequest + 27, // 41: blobber.service.v1.Blobber.GetAllocation:output_type -> blobber.service.v1.GetAllocationResponse + 23, // 42: blobber.service.v1.Blobber.GetFileMetaData:output_type -> blobber.service.v1.GetFileMetaDataResponse + 20, // 43: blobber.service.v1.Blobber.GetFileStats:output_type -> blobber.service.v1.GetFileStatsResponse + 18, // 44: blobber.service.v1.Blobber.ListEntities:output_type -> blobber.service.v1.ListEntitiesResponse + 14, // 45: blobber.service.v1.Blobber.GetObjectPath:output_type -> blobber.service.v1.GetObjectPathResponse + 11, // 46: blobber.service.v1.Blobber.GetReferencePath:output_type -> blobber.service.v1.GetReferencePathResponse + 9, // 47: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse + 29, // 48: blobber.service.v1.Blobber.DownloadFile:output_type -> blobber.service.v1.DownloadFileResponse + 36, // 49: blobber.service.v1.Blobber.RenameObject:output_type -> blobber.service.v1.RenameObjectResponse + 38, // 50: blobber.service.v1.Blobber.WriteFile:output_type -> blobber.service.v1.UploadFileResponse + 5, // 51: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse + 3, // 52: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse + 7, // 53: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse + 32, // 54: blobber.service.v1.Blobber.UpdateObjectAttributes:output_type -> blobber.service.v1.UpdateObjectAttributesResponse + 34, // 55: blobber.service.v1.Blobber.CopyObject:output_type -> blobber.service.v1.CopyObjectResponse + 1, // 56: blobber.service.v1.Blobber.Collaborator:output_type -> blobber.service.v1.CollaboratorResponse + 41, // [41:57] is the sub-list for method output_type + 25, // [25:41] is the sub-list for method input_type 25, // [25:25] is the sub-list for extension type_name 25, // [25:25] is the sub-list for extension extendee 0, // [0:25] is the sub-list for field type_name @@ -4535,7 +4576,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UploadFileRequest); i { + switch v := v.(*GetAllocationRequest); i { case 0: return &v.state case 1: @@ -4547,7 +4588,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UploadFileResponse); i { + switch v := v.(*GetAllocationResponse); i { case 0: return &v.state case 1: @@ -4559,7 +4600,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Allocation); i { + switch v := v.(*DownloadFileRequest); i { case 0: return &v.state case 1: @@ -4571,7 +4612,7 @@ func file_blobber_proto_init() { } } file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Term); i { + switch v := v.(*DownloadFileResponse); i { case 0: return &v.state case 1: @@ -4582,8 +4623,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DownloadFileRequest); i { + file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ReadMaker); i { case 0: return &v.state case 1: @@ -4594,8 +4635,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DownloadFileResponse); i { + file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*UpdateObjectAttributesRequest); i { case 0: return &v.state case 1: @@ -4606,8 +4647,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReadMaker); i { + file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*UpdateObjectAttributesResponse); i { case 0: return &v.state case 1: @@ -4618,8 +4659,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UpdateObjectAttributesRequest); i { + file_blobber_proto_msgTypes[33].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CopyObjectRequest); i { case 0: return &v.state case 1: @@ -4630,8 +4671,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UpdateObjectAttributesResponse); i { + file_blobber_proto_msgTypes[34].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CopyObjectResponse); i { case 0: return &v.state case 1: @@ -4642,8 +4683,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[33].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CopyObjectRequest); i { + file_blobber_proto_msgTypes[35].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RenameObjectRequest); i { case 0: return &v.state case 1: @@ -4654,8 +4695,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[34].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CopyObjectResponse); i { + file_blobber_proto_msgTypes[36].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RenameObjectResponse); i { case 0: return &v.state case 1: @@ -4666,8 +4707,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[35].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RenameObjectRequest); i { + file_blobber_proto_msgTypes[37].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*UploadFileRequest); i { case 0: return &v.state case 1: @@ -4678,8 +4719,8 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[36].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RenameObjectResponse); i { + file_blobber_proto_msgTypes[38].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*UploadFileResponse); i { case 0: return &v.state case 1: @@ -4690,7 +4731,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[37].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[39].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Allocation); i { case 0: return &v.state @@ -4702,7 +4743,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[38].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[40].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Term); i { case 0: return &v.state @@ -4714,7 +4755,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[39].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[41].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileRef); i { case 0: return &v.state @@ -4726,7 +4767,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[40].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[42].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FileMetaData); i { case 0: return &v.state @@ -4738,7 +4779,7 @@ func file_blobber_proto_init() { return nil } } - file_blobber_proto_msgTypes[41].Exporter = func(v interface{}, i int) interface{} { + file_blobber_proto_msgTypes[43].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DirMetaData); i { case 0: return &v.state @@ -4757,7 +4798,7 @@ func file_blobber_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_blobber_proto_rawDesc, NumEnums: 0, - NumMessages: 42, + NumMessages: 44, NumExtensions: 0, NumServices: 1, }, diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 70a52c763..7c57b2da8 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -198,9 +198,9 @@ type BlobberServer interface { GetObjectPath(context.Context, *GetObjectPathRequest) (*GetObjectPathResponse, error) GetReferencePath(context.Context, *GetReferencePathRequest) (*GetReferencePathResponse, error) GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) - WriteFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) DownloadFile(context.Context, *DownloadFileRequest) (*DownloadFileResponse, error) RenameObject(context.Context, *RenameObjectRequest) (*RenameObjectResponse, error) + WriteFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) Commit(context.Context, *CommitRequest) (*CommitResponse, error) CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index a01195e6a..b19893369 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -386,13 +386,18 @@ func DownloadFileResponseCreator(r interface{}) *blobbergrpc.DownloadFileRespons } } -func UploadFileResponseHandler(renameObjectResponse *blobbergrpc.UploadFileResponse) *blobberHTTP.UploadResult { - return &blobberHTTP.UploadResult{ - Filename: renameObjectResponse.Filename, - Size: renameObjectResponse.Size, - Hash: renameObjectResponse.ContentHash, - MerkleRoot: renameObjectResponse.MerkleRoot, - UploadLength: renameObjectResponse.UploadLength, - UploadOffset: renameObjectResponse.UploadOffset, +func UploadFileResponseCreator(r interface{}) *blobbergrpc.UploadFileResponse { + if r == nil { + return nil + } + + httpResp, _ := r.(*blobberHTTP.UploadResult) + return &blobbergrpc.UploadFileResponse{ + Filename: httpResp.Filename, + Size: httpResp.Size, + ContentHash: httpResp.Hash, + MerkleRoot: httpResp.MerkleRoot, + UploadLength: httpResp.UploadLength, + UploadOffset: httpResp.UploadOffset, } } diff --git a/code/go/0chain.net/blobbercore/handler/handler.go b/code/go/0chain.net/blobbercore/handler/handler.go index fe1e1a6cb..45b7163fb 100644 --- a/code/go/0chain.net/blobbercore/handler/handler.go +++ b/code/go/0chain.net/blobbercore/handler/handler.go @@ -3,9 +3,7 @@ package handler import ( - "bytes" "context" - "io" "net/http" "os" "runtime/pprof" @@ -31,8 +29,7 @@ func GetMetaDataStore() *datastore.Store { /*SetupHandlers sets up the necessary API end points */ func SetupHandlers(r *mux.Router) { //object operations - r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common. - ToJSONResponse(WithConnection(UploadHandler(svc))))) + r.HandleFunc("/v1/file/upload/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(UploadHandler)))) r.HandleFunc("/v1/file/download/{allocation}", common.UserRateLimit(common.ToByteStream(WithConnection(DownloadHandler)))) r.HandleFunc("/v1/file/rename/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(RenameHandler)))) r.HandleFunc("/v1/file/copy/{allocation}", common.UserRateLimit(common.ToJSONResponse(WithConnection(CopyHandler)))) @@ -263,49 +260,14 @@ func CopyHandler(ctx context.Context, r *http.Request) (interface{}, error) { } /*UploadHandler is the handler to respond to upload requests fro clients*/ -func UploadHandler(svc *blobberGRPCService) func(ctx context.Context, r *http.Request) (interface{}, error) { - return func(ctx context.Context, r *http.Request) (interface{}, error) { - ctx = setupHandlerGRPCContext(ctx, r) - - req := &blobbergrpc.UploadFileRequest{ - Allocation: mux.Vars(r)["allocation"], - Path: r.FormValue("path"), - ConnectionId: r.FormValue("connection_id"), - Method: r.Method, - UploadMeta: r.FormValue("uploadMeta"), - UpdateMeta: r.FormValue("updateMeta"), - UploadFile: nil, - UploadThumbnailFile: nil, - } - - //set original file as []bytes - origFile, _, err := r.FormFile("uploadFile") - if err != nil { - return nil, common.NewError("invalid_parameters", "Error Reading multi parts for file."+err.Error()) - } - buf := bytes.NewBuffer(nil) - if _, err := io.Copy(buf, origFile); err != nil { - return nil, err - } - req.UploadFile = buf.Bytes() - - //set thumbnail file as []bytes - thumbFile, thumbHeader, _ := r.FormFile("uploadThumbnailFile") - if thumbHeader != nil { - buf := bytes.NewBuffer(nil) - if _, err := io.Copy(buf, thumbFile); err != nil { - return nil, err - } - req.UploadFile = buf.Bytes() - } - - uploadFileResponse, err := svc.WriteFile(ctx, req) - if err != nil { - return nil, err - } - - return convert.UploadFileResponseHandler(uploadFileResponse), nil +func UploadHandler(ctx context.Context, r *http.Request) (interface{}, error) { + ctx = setupHandlerContext(ctx, r) + response, err := storageHandler.WriteFile(ctx, r) + if err != nil { + return nil, err } + + return response, nil } func UpdateAttributesHandler(ctx context.Context, r *http.Request) (interface{}, error) { diff --git a/code/go/0chain.net/blobbercore/handler/handler_test.go b/code/go/0chain.net/blobbercore/handler/handler_test.go index 3074816e8..49614a930 100644 --- a/code/go/0chain.net/blobbercore/handler/handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/handler_test.go @@ -166,7 +166,7 @@ func setupHandlers() (*mux.Router, map[string]string) { uName := "Upload" router.HandleFunc(uPath, common.UserRateLimit( common.ToJSONResponse( - WithReadOnlyConnection(UploadHandler(svc)), + WithReadOnlyConnection(UploadHandler), ), ), ).Name(uName) @@ -270,10 +270,6 @@ func TestHandlers_Requiring_Signature(t *testing.T) { t.Fatal(err) } - if name == `Upload` { - return uploadReq(t, router, alloc, handlers, sch) - } - return r }(), }, @@ -312,10 +308,6 @@ func TestHandlers_Requiring_Signature(t *testing.T) { r.Header.Set(common.ClientSignatureHeader, sign) r.Header.Set(common.ClientHeader, alloc.OwnerID) - if name == `Upload` { - return uploadReq(t, router, alloc, handlers, sch) - } - return r }(), }, @@ -1040,60 +1032,3 @@ func TestHandlers_Requiring_Signature(t *testing.T) { t.Fatal(err) } } - -func uploadReq(t *testing.T, router *mux.Router, alloc *allocation.Allocation, handlers map[string]string, sch *zcncrypto.BLS0ChainScheme) *http.Request { - handlerName := handlers["/v1/file/upload/{allocation}"] - url, err := router.Get(handlerName).URL("allocation", alloc.Tx) - if err != nil { - t.Fatal() - } - - q := url.Query() - formFieldByt, err := json.Marshal(&allocation.UpdateFileChange{}) - if err != nil { - t.Fatal(err) - } - q.Set("uploadMeta", string(formFieldByt)) - q.Set("path", `/path`) - q.Set("new_name", `new name`) - q.Set("connection_id", `connectionID`) - url.RawQuery = q.Encode() - - body := bytes.NewBuffer(nil) - formWriter := multipart.NewWriter(body) - root, _ := os.Getwd() - file, err := os.Open(root + "/handler_test.go") - if err != nil { - t.Fatal(err) - } - fileField, err := formWriter.CreateFormFile("uploadFile", file.Name()) - if err != nil { - t.Fatal(err) - } - fileB := make([]byte, 0) - if _, err := io.ReadFull(file, fileB); err != nil { - t.Fatal(err) - } - if _, err := fileField.Write(fileB); err != nil { - t.Fatal(err) - } - if err := formWriter.Close(); err != nil { - t.Fatal(err) - } - r, err := http.NewRequest(http.MethodPost, url.String(), body) - if err != nil { - t.Fatal(err) - } - - hash := encryption.Hash("another data") - sign, err := sch.Sign(hash) - if err != nil { - t.Fatal(err) - } - - r.Header.Set("Content-Type", formWriter.FormDataContentType()) - r.Header.Set(common.ClientSignatureHeader, sign) - r.Header.Set(common.ClientHeader, alloc.OwnerID) - - return r -} diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index c133f1e51..e2c7e3dda 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -1,9 +1,14 @@ package handler import ( + "bytes" "context" + "encoding/json" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "mime/multipart" "net/http" ) @@ -97,204 +102,71 @@ func (b *blobberGRPCService) DownloadFile(ctx context.Context, req *blobbergrpc. return convert.DownloadFileResponseCreator(resp), nil } -func (b *blobberGRPCService) WriteFile(ctx context.Context, r *blobbergrpc.UploadFileRequest) (*blobbergrpc.UploadFileResponse, error) { - logger := ctxzap.Extract(ctx) - if r.Method == "GET" { - return nil, common.NewError("invalid_method", - "Invalid method used for the upload URL. Use multi-part form POST / PUT / DELETE instead") - } - - md := GetGRPCMetaDataFromCtx(ctx) - - allocationTx := r.Allocation - allocationObj, err := b.storageHandler.verifyAllocation(ctx, allocationTx, false) - if err != nil { - return nil, common.NewError("invalid_parameters", "Invalid allocation id passed."+err.Error()) - } - - valid, err := verifySignatureFromRequest(allocationTx, md.ClientSignature, allocationObj.OwnerPublicKey) - if !valid || err != nil { - return nil, common.NewError("invalid_signature", "Invalid signature") - } - allocationID := allocationObj.ID +func (b *blobberGRPCService) WriteFile(ctx context.Context, req *blobbergrpc.UploadFileRequest) (*blobbergrpc.UploadFileResponse, error) { - clientID := md.Client - if len(clientID) == 0 { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner or the payer of the allocation") + var formData allocation.UpdateFileChange + var uploadMetaString string + switch req.Method { + case `POST`: + uploadMetaString = req.UploadMeta + case `PUT`: + uploadMetaString = req.UpdateMeta } - - connectionID := r.ConnectionId - if len(connectionID) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid connection id passed") - } - - connectionObj, err := b.packageHandler.GetAllocationChanges(ctx, connectionID, allocationID, clientID) + err := json.Unmarshal([]byte(uploadMetaString), &formData) if err != nil { - return nil, common.NewError("meta_error", "Error reading metadata for connection") + return nil, common.NewError("invalid_parameters", + "Invalid parameters. Error parsing the meta data for upload."+err.Error()) } - mutex := lock.GetMutex(connectionObj.TableName(), connectionID) - mutex.Lock() - defer mutex.Unlock() - - result := &blobbergrpc.UploadFileResponse{} - mode := allocation.INSERT_OPERATION - if r.Method == "PUT" { - mode = allocation.UPDATE_OPERATION - } else if r.Method == "DELETE" { - mode = allocation.DELETE_OPERATION + r, err := http.NewRequest(req.Method, "", nil) + if err != nil { + return nil, err } - if mode == allocation.DELETE_OPERATION { - if allocationObj.OwnerID != clientID && allocationObj.PayerID != clientID { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner or the payer of the allocation") - } - result, err = b.DeleteFile(ctx, r, connectionObj) + if req.Method != `DELETE` { + body := new(bytes.Buffer) + writer := multipart.NewWriter(body) + part, err := writer.CreateFormFile(`uploadFile`, formData.Filename) if err != nil { return nil, err } - } else if mode == allocation.INSERT_OPERATION || mode == allocation.UPDATE_OPERATION { - var formData allocation.UpdateFileChange - uploadMetaString := r.UploadMeta - if mode == allocation.UPDATE_OPERATION { - uploadMetaString = r.UpdateMeta - } - err = json.Unmarshal([]byte(uploadMetaString), &formData) + _, err = part.Write(req.UploadFile) if err != nil { - return nil, common.NewError("invalid_parameters", - "Invalid parameters. Error parsing the meta data for upload."+err.Error()) - } - exisitingFileRef, _ := b.packageHandler.GetReference(ctx, allocationID, formData.Path) - existingFileRefSize := int64(0) - exisitingFileOnCloud := false - if mode == allocation.INSERT_OPERATION { - if allocationObj.OwnerID != clientID && allocationObj.PayerID != clientID { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner or the payer of the allocation") - } - - if exisitingFileRef != nil { - return nil, common.NewError("duplicate_file", "File at path already exists") - } - } else if mode == allocation.UPDATE_OPERATION { - if exisitingFileRef == nil { - return nil, common.NewError("invalid_file_update", "File at path does not exist for update") - } - - if allocationObj.OwnerID != clientID && - allocationObj.PayerID != clientID && - !reference.IsACollaborator(ctx, exisitingFileRef.ID, clientID) { - return nil, common.NewError("invalid_operation", "Operation needs to be performed by the owner, collaborator or the payer of the allocation") - } - } - - if exisitingFileRef != nil { - existingFileRefSize = exisitingFileRef.Size - exisitingFileOnCloud = exisitingFileRef.OnCloud + return nil, err } - //Files read from grpc bytes. Need to consider about file size and client side implementation for this - //This is a grpc equivalent implementation for http multi-part form file. Need a proper review on this - grpcOrgFile := bytes.NewReader(r.UploadFile) - thumb := r.UploadThumbnailFile - thumbnailPresent := thumb != nil - - fileInputData := &filestore.FileInputData{Name: formData.Filename, Path: formData.Path, OnCloud: exisitingFileOnCloud} - fileOutputData, err := b.packageHandler.GetFileStore().WriteFileGRPC(allocationID, fileInputData, grpcOrgFile, connectionObj.ConnectionID) + thumbPart, err := writer.CreateFormFile(`uploadThumbnailFile`, formData.ThumbnailFilename) if err != nil { - return nil, common.NewError("upload_error", "Failed to upload the file. "+err.Error()) - } - - result.Filename = formData.Filename - result.ContentHash = fileOutputData.ContentHash - result.MerkleRoot = fileOutputData.MerkleRoot - result.Size = fileOutputData.Size - - if len(formData.Hash) > 0 && formData.Hash != fileOutputData.ContentHash { - return nil, common.NewError("content_hash_mismatch", "Content hash provided in the meta data does not match the file content") - } - if len(formData.MerkleRoot) > 0 && formData.MerkleRoot != fileOutputData.MerkleRoot { - return nil, common.NewError("content_merkle_root_mismatch", "Merkle root provided in the meta data does not match the file content") - } - if fileOutputData.Size > config.Configuration.MaxFileSize { - return nil, common.NewError("file_size_limit_exceeded", "Size for the given file is larger than the max limit") + return nil, err } - - formData.Hash = fileOutputData.ContentHash - formData.MerkleRoot = fileOutputData.MerkleRoot - formData.AllocationID = allocationID - formData.Size = fileOutputData.Size - - allocationSize := fileOutputData.Size - if thumbnailPresent { - thumbFile := bytes.NewReader(thumb) - thumbInputData := &filestore.FileInputData{Name: formData.ThumbnailFilename, Path: formData.Path} - thumbOutputData, err := b.packageHandler.GetFileStore().WriteFileGRPC(allocationID, thumbInputData, thumbFile, connectionObj.ConnectionID) - if err != nil { - return nil, common.NewError("upload_error", "Failed to upload the thumbnail. "+err.Error()) - } - if len(formData.ThumbnailHash) > 0 && formData.ThumbnailHash != thumbOutputData.ContentHash { - return nil, common.NewError("content_hash_mismatch", "Content hash provided in the meta data does not match the thumbnail content") - } - formData.ThumbnailHash = thumbOutputData.ContentHash - formData.ThumbnailSize = thumbOutputData.Size - formData.ThumbnailFilename = thumbInputData.Name + _, err = thumbPart.Write(req.UploadThumbnailFile) + if err != nil { + return nil, err } - if allocationObj.BlobberSizeUsed+(allocationSize-existingFileRefSize) > allocationObj.BlobberSize { - return nil, common.NewError("max_allocation_size", "Max size reached for the allocation with this blobber") + err = writer.Close() + if err != nil { + return nil, err } - allocationChange := &allocation.AllocationChange{} - allocationChange.ConnectionID = connectionObj.ConnectionID - allocationChange.Size = allocationSize - existingFileRefSize - allocationChange.Operation = mode - - connectionObj.Size += allocationChange.Size - if mode == allocation.INSERT_OPERATION { - connectionObj.AddChange(allocationChange, &formData.NewFileChange) - } else if mode == allocation.UPDATE_OPERATION { - connectionObj.AddChange(allocationChange, &formData) + r, err = http.NewRequest(req.Method, "", body) + if err != nil { + return nil, err } } - err = b.packageHandler.SaveAllocationChanges(ctx, connectionObj) - if err != nil { - logger.Error("Error in writing the connection meta data", zap.Error(err)) - return nil, common.NewError("connection_write_error", "Error writing the connection meta data") - } - - return result, nil -} - -func (b *blobberGRPCService) DeleteFile(ctx context.Context, r *blobbergrpc.UploadFileRequest, connectionObj *allocation.AllocationChangeCollector) (*blobbergrpc.UploadFileResponse, error) { - path := r.Path - if len(path) == 0 { - return nil, common.NewError("invalid_parameters", "Invalid path") + httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) + r.Form = map[string][]string{ + "path": {req.Path}, + "connection_id": {req.ConnectionId}, + "uploadMeta": {req.UploadMeta}, + "updateMeta": {req.UpdateMeta}, } - fileRef, _ := b.packageHandler.GetReference(ctx, connectionObj.AllocationID, path) - if fileRef != nil { - deleteSize := fileRef.Size - - allocationChange := &allocation.AllocationChange{} - allocationChange.ConnectionID = connectionObj.ConnectionID - allocationChange.Size = 0 - deleteSize - allocationChange.Operation = allocation.DELETE_OPERATION - dfc := &allocation.DeleteFileChange{ConnectionID: connectionObj.ConnectionID, - AllocationID: connectionObj.AllocationID, Name: fileRef.Name, - Hash: fileRef.Hash, Path: fileRef.Path, Size: deleteSize} - - connectionObj.Size += allocationChange.Size - connectionObj.AddChange(allocationChange, dfc) - - result := &blobbergrpc.UploadFileResponse{} - result.Filename = fileRef.Name - result.ContentHash = fileRef.Hash - result.MerkleRoot = fileRef.MerkleRoot - result.Size = fileRef.Size - - return result, nil + resp, err := UploadHandler(ctx, r) + if err != nil { + return nil, err } - return nil, common.NewError("invalid_file", "File does not exist at path") + return convert.UploadFileResponseCreator(resp), nil } diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go deleted file mode 100644 index abeebd162..000000000 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler_test.go +++ /dev/null @@ -1 +0,0 @@ -package handler diff --git a/code/go/0chain.net/blobbercore/mocks/FileStore.go b/code/go/0chain.net/blobbercore/mocks/FileStore.go deleted file mode 100644 index 27ff86003..000000000 --- a/code/go/0chain.net/blobbercore/mocks/FileStore.go +++ /dev/null @@ -1,300 +0,0 @@ -// Code generated by mockery 2.7.5. DO NOT EDIT. - -package mocks - -import ( - io "io" - - filestore "github.com/0chain/blobber/code/go/0chain.net/blobbercore/filestore" - - json "encoding/json" - - mock "github.com/stretchr/testify/mock" - - multipart "mime/multipart" - - util "github.com/0chain/blobber/code/go/0chain.net/core/util" -) - -// FileStore is an autogenerated mock type for the FileStore type -type FileStore struct { - mock.Mock -} - -// CommitWrite provides a mock function with given fields: allocationID, fileData, connectionID -func (_m *FileStore) CommitWrite(allocationID string, fileData *filestore.FileInputData, connectionID string) (bool, error) { - ret := _m.Called(allocationID, fileData, connectionID) - - var r0 bool - if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, string) bool); ok { - r0 = rf(allocationID, fileData, connectionID) - } else { - r0 = ret.Get(0).(bool) - } - - var r1 error - if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, string) error); ok { - r1 = rf(allocationID, fileData, connectionID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// DeleteFile provides a mock function with given fields: allocationID, contentHash -func (_m *FileStore) DeleteFile(allocationID string, contentHash string) error { - ret := _m.Called(allocationID, contentHash) - - var r0 error - if rf, ok := ret.Get(0).(func(string, string) error); ok { - r0 = rf(allocationID, contentHash) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// DeleteTempFile provides a mock function with given fields: allocationID, fileData, connectionID -func (_m *FileStore) DeleteTempFile(allocationID string, fileData *filestore.FileInputData, connectionID string) error { - ret := _m.Called(allocationID, fileData, connectionID) - - var r0 error - if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, string) error); ok { - r0 = rf(allocationID, fileData, connectionID) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// DownloadFromCloud provides a mock function with given fields: fileHash, filePath -func (_m *FileStore) DownloadFromCloud(fileHash string, filePath string) error { - ret := _m.Called(fileHash, filePath) - - var r0 error - if rf, ok := ret.Get(0).(func(string, string) error); ok { - r0 = rf(fileHash, filePath) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// GetFileBlock provides a mock function with given fields: allocationID, fileData, blockNum, numBlocks -func (_m *FileStore) GetFileBlock(allocationID string, fileData *filestore.FileInputData, blockNum int64, numBlocks int64) ([]byte, error) { - ret := _m.Called(allocationID, fileData, blockNum, numBlocks) - - var r0 []byte - if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, int64, int64) []byte); ok { - r0 = rf(allocationID, fileData, blockNum, numBlocks) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]byte) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, int64, int64) error); ok { - r1 = rf(allocationID, fileData, blockNum, numBlocks) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetFileBlockForChallenge provides a mock function with given fields: allocationID, fileData, blockoffset -func (_m *FileStore) GetFileBlockForChallenge(allocationID string, fileData *filestore.FileInputData, blockoffset int) (json.RawMessage, util.MerkleTreeI, error) { - ret := _m.Called(allocationID, fileData, blockoffset) - - var r0 json.RawMessage - if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, int) json.RawMessage); ok { - r0 = rf(allocationID, fileData, blockoffset) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(json.RawMessage) - } - } - - var r1 util.MerkleTreeI - if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, int) util.MerkleTreeI); ok { - r1 = rf(allocationID, fileData, blockoffset) - } else { - if ret.Get(1) != nil { - r1 = ret.Get(1).(util.MerkleTreeI) - } - } - - var r2 error - if rf, ok := ret.Get(2).(func(string, *filestore.FileInputData, int) error); ok { - r2 = rf(allocationID, fileData, blockoffset) - } else { - r2 = ret.Error(2) - } - - return r0, r1, r2 -} - -// GetTempPathSize provides a mock function with given fields: allocationID -func (_m *FileStore) GetTempPathSize(allocationID string) (int64, error) { - ret := _m.Called(allocationID) - - var r0 int64 - if rf, ok := ret.Get(0).(func(string) int64); ok { - r0 = rf(allocationID) - } else { - r0 = ret.Get(0).(int64) - } - - var r1 error - if rf, ok := ret.Get(1).(func(string) error); ok { - r1 = rf(allocationID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetTotalDiskSizeUsed provides a mock function with given fields: -func (_m *FileStore) GetTotalDiskSizeUsed() (int64, error) { - ret := _m.Called() - - var r0 int64 - if rf, ok := ret.Get(0).(func() int64); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(int64) - } - - var r1 error - if rf, ok := ret.Get(1).(func() error); ok { - r1 = rf() - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// GetlDiskSizeUsed provides a mock function with given fields: allocationID -func (_m *FileStore) GetlDiskSizeUsed(allocationID string) (int64, error) { - ret := _m.Called(allocationID) - - var r0 int64 - if rf, ok := ret.Get(0).(func(string) int64); ok { - r0 = rf(allocationID) - } else { - r0 = ret.Get(0).(int64) - } - - var r1 error - if rf, ok := ret.Get(1).(func(string) error); ok { - r1 = rf(allocationID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// IterateObjects provides a mock function with given fields: allocationID, handler -func (_m *FileStore) IterateObjects(allocationID string, handler filestore.FileObjectHandler) error { - ret := _m.Called(allocationID, handler) - - var r0 error - if rf, ok := ret.Get(0).(func(string, filestore.FileObjectHandler) error); ok { - r0 = rf(allocationID, handler) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// SetupAllocation provides a mock function with given fields: allocationID, skipCreate -func (_m *FileStore) SetupAllocation(allocationID string, skipCreate bool) (*filestore.StoreAllocation, error) { - ret := _m.Called(allocationID, skipCreate) - - var r0 *filestore.StoreAllocation - if rf, ok := ret.Get(0).(func(string, bool) *filestore.StoreAllocation); ok { - r0 = rf(allocationID, skipCreate) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*filestore.StoreAllocation) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(string, bool) error); ok { - r1 = rf(allocationID, skipCreate) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// UploadToCloud provides a mock function with given fields: fileHash, filePath -func (_m *FileStore) UploadToCloud(fileHash string, filePath string) error { - ret := _m.Called(fileHash, filePath) - - var r0 error - if rf, ok := ret.Get(0).(func(string, string) error); ok { - r0 = rf(fileHash, filePath) - } else { - r0 = ret.Error(0) - } - - return r0 -} - -// WriteFile provides a mock function with given fields: allocationID, fileData, infile, connectionID -func (_m *FileStore) WriteFile(allocationID string, fileData *filestore.FileInputData, infile multipart.File, connectionID string) (*filestore.FileOutputData, error) { - ret := _m.Called(allocationID, fileData, infile, connectionID) - - var r0 *filestore.FileOutputData - if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, multipart.File, string) *filestore.FileOutputData); ok { - r0 = rf(allocationID, fileData, infile, connectionID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*filestore.FileOutputData) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, multipart.File, string) error); ok { - r1 = rf(allocationID, fileData, infile, connectionID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - -// WriteFileGRPC provides a mock function with given fields: allocationID, fileData, fileReader, connectionID -func (_m *FileStore) WriteFileGRPC(allocationID string, fileData *filestore.FileInputData, fileReader io.Reader, connectionID string) (*filestore.FileOutputData, error) { - ret := _m.Called(allocationID, fileData, fileReader, connectionID) - - var r0 *filestore.FileOutputData - if rf, ok := ret.Get(0).(func(string, *filestore.FileInputData, io.Reader, string) *filestore.FileOutputData); ok { - r0 = rf(allocationID, fileData, fileReader, connectionID) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(*filestore.FileOutputData) - } - } - - var r1 error - if rf, ok := ret.Get(1).(func(string, *filestore.FileInputData, io.Reader, string) error); ok { - r1 = rf(allocationID, fileData, fileReader, connectionID) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} diff --git a/code/go/0chain.net/blobbercore/mocks/PackageHandler.go b/code/go/0chain.net/blobbercore/mocks/PackageHandler.go deleted file mode 100644 index e69de29bb..000000000 From 23817e46584d8a90309491546d790a12e5354445 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 21 Jun 2021 19:50:09 +0530 Subject: [PATCH 138/183] :white_check_mark: added tests for getcalculatehash --- .../blobbergrpc/blobber_grpc.pb.go | 1 + .../handler/grpc_handler_integration_test.go | 54 +++++++++++++++++++ 2 files changed, 55 insertions(+) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index fae41df83..99947c481 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -4,6 +4,7 @@ package blobbergrpc import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index a23dba7f8..8361e34dc 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -851,6 +851,60 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } } }) + + t.Run("TestCalculateHash", func(t *testing.T) { + allocationTx := randString(32) + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetReferencePathTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CalculateHashRequest + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CalculateHashRequest{ + Paths: "", + Path: "/", + Allocation: allocationTx, + }, + expectingError: false, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + _, err := blobberClient.CalculateHash(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + } + }) } func randString(n int) string { From ab33a2c461be4dce24e41f2e7bbb432400819cd1 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 21 Jun 2021 20:10:26 +0530 Subject: [PATCH 139/183] :green_heart: fixing ci --- code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go | 1 - 1 file changed, 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 99947c481..fae41df83 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -4,7 +4,6 @@ package blobbergrpc import ( context "context" - grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" From dbb7befffd7ea6335346167129d09230a5255f4c Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Mon, 21 Jun 2021 21:56:53 +0530 Subject: [PATCH 140/183] readding server reflection --- code/go/0chain.net/blobber/main.go | 7 +++++++ code/go/0chain.net/blobbercore/blobbergrpc/README.md | 3 ++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobber/main.go b/code/go/0chain.net/blobber/main.go index 188b4a173..b2eb6309d 100644 --- a/code/go/0chain.net/blobber/main.go +++ b/code/go/0chain.net/blobber/main.go @@ -13,6 +13,8 @@ import ( "strconv" "time" + "google.golang.org/grpc/reflection" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/challenge" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" @@ -351,6 +353,10 @@ func main() { grpcServer := handler.NewServerWithMiddlewares(common.NewGRPCRateLimiter()) handler.RegisterGRPCServices(r, grpcServer) + if config.Development() { + reflection.Register(grpcServer) + } + rHandler := handlers.CORS(originsOk, headersOk, methodsOk)(r) if config.Development() { // No WriteTimeout setup to enable pprof @@ -376,6 +382,7 @@ func main() { Logger.Info("Ready to listen to the requests") startTime = time.Now().UTC() go func(grpcPort string) { + Logger.Info("listening too grpc requests on port - " + grpcPort) lis, err := net.Listen("tcp", fmt.Sprintf(":%s", grpcPort)) if err != nil { log.Fatalf("failed to listen: %v", err) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/README.md b/code/go/0chain.net/blobbercore/blobbergrpc/README.md index d45b4a594..5ac239d6a 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/README.md +++ b/code/go/0chain.net/blobbercore/blobbergrpc/README.md @@ -31,7 +31,8 @@ plugin is being used to expose a REST api for grpc incompatible clients. ## Testing The current grpc implementation supports server reflection in development environment. -You can interact with the api using https://github.com/gusaul/grpcox. +You can interact with the api using https://github.com/gusaul/grpcox. While running locally make sure +to use docker network ip and not localhost. Make sure the server is running on `--deployment_mode 0` to use server reflection. From 1530df8beb94d8bb913d1ad5f843f89eb536d90b Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 21 Jun 2021 23:34:30 +0530 Subject: [PATCH 141/183] grpc_gateway implementation --- .../blobbercore/blobbergrpc/blobber.pb.go | 141 +++---- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 345 ++++++++++++++++++ .../blobbergrpc/proto/blobber.proto | 15 +- .../0chain.net/blobbercore/convert/convert.go | 59 +++ .../blobbercore/filestore/fs_store.go | 103 ------ .../0chain.net/blobbercore/filestore/store.go | 2 - .../handler/object_operation_grpc_handler.go | 53 +-- .../blobbercore/openapi/blobber.swagger.json | 141 +++++++ scripts/generate-grpc.sh | 2 +- 9 files changed, 635 insertions(+), 226 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index dc79bc8ab..298637c34 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -3985,7 +3985,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xd7, 0x11, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xc5, 0x12, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, @@ -4065,72 +4065,79 @@ var file_blobber_proto_rawDesc = []byte{ 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x5c, - 0x0a, 0x09, 0x57, 0x72, 0x69, 0x74, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x25, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, - 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x7e, 0x0a, 0x06, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, - 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, - 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, - 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, - 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, - 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, - 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, - 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, - 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, - 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, - 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, - 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, - 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, - 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, - 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, - 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, - 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, - 0x01, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, - 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, - 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, - 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, - 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, - 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, - 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xc9, + 0x01, 0x0a, 0x09, 0x57, 0x72, 0x69, 0x74, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x25, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, + 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x6d, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x67, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, + 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, 0x1a, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, 0x2a, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, + 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, + 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, + 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, + 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, + 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, + 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, + 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, + 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, + 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, 0x74, + 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, 0x79, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, 0x2f, + 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, 0x0a, + 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, + 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, + 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, + 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, + 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 26529fec6..775218e0b 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -623,6 +623,210 @@ func local_request_Blobber_RenameObject_0(ctx context.Context, marshaler runtime } +func request_Blobber_WriteFile_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UploadFileRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := client.WriteFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_WriteFile_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UploadFileRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := server.WriteFile(ctx, &protoReq) + return msg, metadata, err + +} + +func request_Blobber_WriteFile_1(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UploadFileRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := client.WriteFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_WriteFile_1(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UploadFileRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := server.WriteFile(ctx, &protoReq) + return msg, metadata, err + +} + +func request_Blobber_WriteFile_2(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UploadFileRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := client.WriteFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Blobber_WriteFile_2(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UploadFileRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + var ( + val string + ok bool + err error + _ = err + ) + + val, ok = pathParams["allocation"] + if !ok { + return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "allocation") + } + + protoReq.Allocation, err = runtime.String(val) + if err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) + } + + msg, err := server.WriteFile(ctx, &protoReq) + return msg, metadata, err + +} + func request_Blobber_Commit_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CommitRequest var metadata runtime.ServerMetadata @@ -1244,6 +1448,75 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) + mux.Handle("POST", pattern_Blobber_WriteFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_WriteFile_0(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_WriteFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PUT", pattern_Blobber_WriteFile_1, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_WriteFile_1(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_WriteFile_1(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_Blobber_WriteFile_2, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + var stream runtime.ServerTransportStream + ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Blobber_WriteFile_2(rctx, inboundMarshaler, server, req, pathParams) + md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_WriteFile_2(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() @@ -1603,6 +1876,66 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) + mux.Handle("POST", pattern_Blobber_WriteFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_WriteFile_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_WriteFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PUT", pattern_Blobber_WriteFile_1, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_WriteFile_1(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_WriteFile_1(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_Blobber_WriteFile_2, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Blobber_WriteFile_2(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Blobber_WriteFile_2(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + mux.Handle("POST", pattern_Blobber_Commit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() @@ -1745,6 +2078,12 @@ var ( pattern_Blobber_RenameObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "rename", "allocation"}, "")) + pattern_Blobber_WriteFile_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "upload", "allocation"}, "")) + + pattern_Blobber_WriteFile_1 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "upload", "allocation"}, "")) + + pattern_Blobber_WriteFile_2 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "upload", "allocation"}, "")) + pattern_Blobber_Commit_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "connection", "commit", "allocation"}, "")) pattern_Blobber_CalculateHash_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "calculatehash", "allocation"}, "")) @@ -1777,6 +2116,12 @@ var ( forward_Blobber_RenameObject_0 = runtime.ForwardResponseMessage + forward_Blobber_WriteFile_0 = runtime.ForwardResponseMessage + + forward_Blobber_WriteFile_1 = runtime.ForwardResponseMessage + + forward_Blobber_WriteFile_2 = runtime.ForwardResponseMessage + forward_Blobber_Commit_0 = runtime.ForwardResponseMessage forward_Blobber_CalculateHash_0 = runtime.ForwardResponseMessage diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 602371275..1b00f07c8 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -54,7 +54,20 @@ service Blobber { body: "*" }; } - rpc WriteFile(UploadFileRequest) returns (UploadFileResponse) {} + rpc WriteFile(UploadFileRequest) returns (UploadFileResponse) { + option (google.api.http) = { + post: "/v2/file/upload/{allocation}" + body: "*" + additional_bindings: { + put: "/v2/file/upload/{allocation}" + body: "*" + } + additional_bindings: { + delete: "/v2/file/upload/{allocation}" + body: "*" + } + }; + } rpc Commit(CommitRequest) returns (CommitResponse) { option (google.api.http) = { diff --git a/code/go/0chain.net/blobbercore/convert/convert.go b/code/go/0chain.net/blobbercore/convert/convert.go index 308ef6c87..4c261fc04 100644 --- a/code/go/0chain.net/blobbercore/convert/convert.go +++ b/code/go/0chain.net/blobbercore/convert/convert.go @@ -1,8 +1,12 @@ package convert import ( + "bytes" "context" + "encoding/json" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "mime/multipart" + "net/http" "time" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" @@ -419,3 +423,58 @@ func convertDirMetaDataGRPCToDirRef(dirref *blobbergrpc.DirMetaData) *reference. UpdatedAt: time.Unix(0, dirref.UpdatedAt), } } + +func WriteFileGRPCToHTTP(req *blobbergrpc.UploadFileRequest) (*http.Request, error) { + var formData allocation.UpdateFileChange + var uploadMetaString string + switch req.Method { + case `POST`: + uploadMetaString = req.UploadMeta + case `PUT`: + uploadMetaString = req.UpdateMeta + } + err := json.Unmarshal([]byte(uploadMetaString), &formData) + if err != nil { + return nil, common.NewError("invalid_parameters", + "Invalid parameters. Error parsing the meta data for upload."+err.Error()) + } + + r, err := http.NewRequest(req.Method, "", nil) + if err != nil { + return nil, err + } + + if req.Method != `DELETE` { + body := new(bytes.Buffer) + writer := multipart.NewWriter(body) + part, err := writer.CreateFormFile(`uploadFile`, formData.Filename) + if err != nil { + return nil, err + } + _, err = part.Write(req.UploadFile) + if err != nil { + return nil, err + } + + thumbPart, err := writer.CreateFormFile(`uploadThumbnailFile`, formData.ThumbnailFilename) + if err != nil { + return nil, err + } + _, err = thumbPart.Write(req.UploadThumbnailFile) + if err != nil { + return nil, err + } + + err = writer.Close() + if err != nil { + return nil, err + } + + r, err = http.NewRequest(req.Method, "", body) + if err != nil { + return nil, err + } + } + + return r, nil +} diff --git a/code/go/0chain.net/blobbercore/filestore/fs_store.go b/code/go/0chain.net/blobbercore/filestore/fs_store.go index d8ee762bd..84b30b7d1 100644 --- a/code/go/0chain.net/blobbercore/filestore/fs_store.go +++ b/code/go/0chain.net/blobbercore/filestore/fs_store.go @@ -578,109 +578,6 @@ func (fs *FileFSStore) WriteFile(allocationID string, fileData *FileInputData, return fileRef, nil } -func (fs *FileFSStore) WriteFileGRPC(allocationID string, fileData *FileInputData, - fileReader io.Reader, connectionID string) (*FileOutputData, error) { - - allocation, err := fs.SetupAllocation(allocationID, false) - if err != nil { - return nil, common.NewError("filestore_setup_error", "Error setting the fs store. "+err.Error()) - } - - tempFilePath := fs.generateTempPath(allocation, fileData, connectionID) - dest, err := NewChunkWriter(tempFilePath) - if err != nil { - return nil, common.NewError("file_creation_error", err.Error()) - } - defer dest.Close() - - fileRef := &FileOutputData{} - //var fileReader io.Reader = infile - - if fileData.IsResumable { - h := sha1.New() - offset, err := dest.WriteChunk(context.TODO(), fileData.UploadOffset, io.TeeReader(fileReader, h)) - - if err != nil { - return nil, common.NewError("file_write_error", err.Error()) - } - - fileRef.ContentHash = hex.EncodeToString(h.Sum(nil)) - fileRef.Size = dest.Size() - fileRef.Name = fileData.Name - fileRef.Path = fileData.Path - fileRef.UploadOffset = fileData.UploadOffset + offset - fileRef.UploadLength = fileData.UploadLength - - if !fileData.IsFinal { - //skip to compute hash until the last chunk is uploaded - return fileRef, nil - } - - fileReader = dest - } - - h := sha1.New() - bytesBuffer := bytes.NewBuffer(nil) - multiHashWriter := io.MultiWriter(h, bytesBuffer) - tReader := io.TeeReader(fileReader, multiHashWriter) - merkleHashes := make([]hash.Hash, 1024) - merkleLeaves := make([]util.Hashable, 1024) - for idx := range merkleHashes { - merkleHashes[idx] = sha3.New256() - } - fileSize := int64(0) - for { - var written int64 - - if fileData.IsResumable { - //all chunks have been written, only read bytes from local file , and compute hash - written, err = io.CopyN(ioutil.Discard, tReader, CHUNK_SIZE) - } else { - written, err = io.CopyN(dest, tReader, CHUNK_SIZE) - } - - if err != io.EOF && err != nil { - return nil, common.NewError("file_write_error", err.Error()) - } - fileSize += written - dataBytes := bytesBuffer.Bytes() - merkleChunkSize := 64 - for i := 0; i < len(dataBytes); i += merkleChunkSize { - end := i + merkleChunkSize - if end > len(dataBytes) { - end = len(dataBytes) - } - offset := i / merkleChunkSize - merkleHashes[offset].Write(dataBytes[i:end]) - } - - bytesBuffer.Reset() - if err != nil && err == io.EOF { - break - } - } - for idx := range merkleHashes { - merkleLeaves[idx] = util.NewStringHashable(hex.EncodeToString(merkleHashes[idx].Sum(nil))) - } - - var mt util.MerkleTreeI = &util.MerkleTree{} - mt.ComputeTree(merkleLeaves) - - //only update hash for whole file when it is not a resumable upload or is final chunk. - if !fileData.IsResumable || fileData.IsFinal { - fileRef.ContentHash = hex.EncodeToString(h.Sum(nil)) - } - - fileRef.Size = fileSize - fileRef.Name = fileData.Name - fileRef.Path = fileData.Path - fileRef.MerkleRoot = mt.GetRoot() - fileRef.UploadOffset = fileSize - fileRef.UploadLength = fileData.UploadLength - - return fileRef, nil -} - func (fs *FileFSStore) IterateObjects(allocationID string, handler FileObjectHandler) error { allocation, err := fs.SetupAllocation(allocationID, true) if err != nil { diff --git a/code/go/0chain.net/blobbercore/filestore/store.go b/code/go/0chain.net/blobbercore/filestore/store.go index ab6898143..4d98a5136 100644 --- a/code/go/0chain.net/blobbercore/filestore/store.go +++ b/code/go/0chain.net/blobbercore/filestore/store.go @@ -2,7 +2,6 @@ package filestore import ( "encoding/json" - "io" "mime/multipart" "github.com/0chain/blobber/code/go/0chain.net/core/util" @@ -56,7 +55,6 @@ type FileStore interface { UploadToCloud(fileHash, filePath string) error DownloadFromCloud(fileHash, filePath string) error SetupAllocation(allocationID string, skipCreate bool) (*StoreAllocation, error) - WriteFileGRPC(allocationID string, fileData *FileInputData, fileReader io.Reader, connectionID string) (*FileOutputData, error) } var fsStore FileStore diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index e2c7e3dda..4811b0bcc 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -1,14 +1,9 @@ package handler import ( - "bytes" "context" - "encoding/json" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/convert" - "github.com/0chain/blobber/code/go/0chain.net/core/common" - "mime/multipart" "net/http" ) @@ -104,57 +99,11 @@ func (b *blobberGRPCService) DownloadFile(ctx context.Context, req *blobbergrpc. func (b *blobberGRPCService) WriteFile(ctx context.Context, req *blobbergrpc.UploadFileRequest) (*blobbergrpc.UploadFileResponse, error) { - var formData allocation.UpdateFileChange - var uploadMetaString string - switch req.Method { - case `POST`: - uploadMetaString = req.UploadMeta - case `PUT`: - uploadMetaString = req.UpdateMeta - } - err := json.Unmarshal([]byte(uploadMetaString), &formData) - if err != nil { - return nil, common.NewError("invalid_parameters", - "Invalid parameters. Error parsing the meta data for upload."+err.Error()) - } - - r, err := http.NewRequest(req.Method, "", nil) + r, err := convert.WriteFileGRPCToHTTP(req) if err != nil { return nil, err } - if req.Method != `DELETE` { - body := new(bytes.Buffer) - writer := multipart.NewWriter(body) - part, err := writer.CreateFormFile(`uploadFile`, formData.Filename) - if err != nil { - return nil, err - } - _, err = part.Write(req.UploadFile) - if err != nil { - return nil, err - } - - thumbPart, err := writer.CreateFormFile(`uploadThumbnailFile`, formData.ThumbnailFilename) - if err != nil { - return nil, err - } - _, err = thumbPart.Write(req.UploadThumbnailFile) - if err != nil { - return nil, err - } - - err = writer.Close() - if err != nil { - return nil, err - } - - r, err = http.NewRequest(req.Method, "", body) - if err != nil { - return nil, err - } - } - httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) r.Form = map[string][]string{ "path": {req.Path}, diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 1dbea80f7..9e7b070ad 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -607,6 +607,116 @@ "Blobber" ] } + }, + "/v2/file/upload/{allocation}": { + "delete": { + "operationId": "Blobber_WriteFile3", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1UploadFileResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1UploadFileRequest" + } + } + ], + "tags": [ + "Blobber" + ] + }, + "post": { + "operationId": "Blobber_WriteFile", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1UploadFileResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1UploadFileRequest" + } + } + ], + "tags": [ + "Blobber" + ] + }, + "put": { + "operationId": "Blobber_WriteFile2", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1UploadFileResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "allocation", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1UploadFileRequest" + } + } + ], + "tags": [ + "Blobber" + ] + } } }, "definitions": { @@ -1400,6 +1510,37 @@ } } }, + "v1UploadFileRequest": { + "type": "object", + "properties": { + "allocation": { + "type": "string" + }, + "path": { + "type": "string" + }, + "connectionId": { + "type": "string" + }, + "method": { + "type": "string" + }, + "uploadMeta": { + "type": "string" + }, + "updateMeta": { + "type": "string" + }, + "uploadFile": { + "type": "string", + "format": "byte" + }, + "uploadThumbnailFile": { + "type": "string", + "format": "byte" + } + } + }, "v1UploadFileResponse": { "type": "object", "properties": { diff --git a/scripts/generate-grpc.sh b/scripts/generate-grpc.sh index e3a9e679a..c03fa71a1 100755 --- a/scripts/generate-grpc.sh +++ b/scripts/generate-grpc.sh @@ -1,3 +1,3 @@ #!/usr/bin/env bash -protoc -I ./code/go/0chain.net/blobbercore/blobbergrpc/proto --go-grpc_out=. --go_out=. --grpc-gateway_out=. --openapiv2_out=./code/go/0chain.net/blobbercore/openapi ./code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto \ No newline at end of file +protoc -I ./code/go/0chain.net/blobbercore/blobbergrpc/proto --go-grpc_out=. --go_out=. --grpc-gateway_out=allow_delete_body=true:. --openapiv2_opt allow_delete_body=true --openapiv2_out=./code/go/0chain.net/blobbercore/openapi ./code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto \ No newline at end of file From e280e3447acc2f9633d56e14c0bc147b6b3a1aa3 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 28 Jun 2021 00:54:38 +0530 Subject: [PATCH 142/183] integration tests inited for upload --- .../0chain.net/blobbercore/convert/convert.go | 5 + .../handler/grpc_handler_helper_unit_test.go | 76 +++++++++++ .../handler/grpc_handler_integration_test.go | 121 ++++++++++++++++++ 3 files changed, 202 insertions(+) diff --git a/code/go/0chain.net/blobbercore/convert/convert.go b/code/go/0chain.net/blobbercore/convert/convert.go index 4c261fc04..4d834e0fb 100644 --- a/code/go/0chain.net/blobbercore/convert/convert.go +++ b/code/go/0chain.net/blobbercore/convert/convert.go @@ -4,6 +4,7 @@ import ( "bytes" "context" "encoding/json" + "fmt" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" "mime/multipart" "net/http" @@ -474,7 +475,11 @@ func WriteFileGRPCToHTTP(req *blobbergrpc.UploadFileRequest) (*http.Request, err if err != nil { return nil, err } + r.Header.Set("Content-Type", writer.FormDataContentType()) + + fmt.Println(`111111111111`) } + fmt.Println(`22222222222`) return r, nil } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index e89037c5f..63f5d7719 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -544,3 +544,79 @@ VALUES return nil } + +func (c *TestDataController) AddUploadTestData(allocationTx, pubkey, clientId, wmSig string, now common.Timestamp) error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO allocation_connections (connection_id, allocation_id, client_id, size, status) +VALUES ('connection_id' ,'exampleId','` + clientId + `', 1337, 1); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO allocation_changes (id, connection_id, operation, size, input) +VALUES (1 ,'connection_id','rename', 1200, '{"allocation_id":"exampleId","path":"/some_file","new_name":"new_name"}'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO write_markers(prev_allocation_root, allocation_root, status, allocation_id, size, client_id, signature, blobber_id, timestamp, connection_id, client_key) +VALUES ('/', '/', 2,'exampleId', 1337, '` + clientId + `','` + wmSig + `','blobber_id', ` + fmt.Sprint(now) + `, 'connection_id', '` + pubkey + `'); +`) + if err != nil { + return err + } + + // _, err = tx.Exec(` + //INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash, parent_path) + //VALUES + //(1234,'exampleId','exampleId:examplePath','exampleId:examplePath','d','root','/','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'), + //(123,'exampleId','exampleId:examplePath','exampleId:examplePath','f','some_file','/some_file','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'); + //`) + // if err != nil { + // return err + // } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index a23dba7f8..d01aa80d8 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -5,6 +5,7 @@ import ( "encoding/hex" "encoding/json" "fmt" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "log" "math/rand" "net/http" @@ -851,6 +852,126 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } } }) + + t.Run("TestUpload", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().UnixNano()) + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + fr := reference.Ref{ + AllocationID: "exampleId", + } + + formFieldByt, err := json.Marshal(&allocation.UpdateFileChange{}) + if err != nil { + t.Fatal(err) + } + + rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + + wm := writemarker.WriteMarker{ + AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + PreviousAllocationRoot: "/", + AllocationID: "exampleId", + Size: 1337, + BlobberID: encryption.Hash(blobberPubKeyBytes), + Timestamp: now, + ClientID: clientId, + } + + wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + if err != nil { + t.Fatal(err) + } + + wm.Signature = wmSig + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddUploadTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.UploadFileRequest + expectedFileName string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + + input: &blobbergrpc.UploadFileRequest{ + Allocation: allocationTx, + Path: "/some_file", + ConnectionId: "connection_id", + Method: "POST", + UploadMeta: string(formFieldByt), + UpdateMeta: "", + UploadFile: []byte{}, + UploadThumbnailFile: []byte{}, + }, + expectedFileName: "/some_file", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.UploadFileRequest{ + Allocation: "", + Path: "", + ConnectionId: "", + Method: "", + UploadMeta: "", + UpdateMeta: "", + UploadFile: nil, + UploadThumbnailFile: nil, + }, + expectedFileName: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := blobberClient.WriteFile(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Log(err.Error()) + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetFilename() != tc.expectedFileName { + t.Fatal("failed!") + } + } + }) } func randString(n int) string { From c2978ef142d9e4be58bdf05d7d094a3a208c5256 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 28 Jun 2021 01:22:37 +0530 Subject: [PATCH 143/183] resolve conflicts with grpc test read file updated --- code/go/0chain.net/blobbercore/convert/convert.go | 2 +- .../handler/grpc_handler_integration_test.go | 13 ++++++++++++- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/convert.go b/code/go/0chain.net/blobbercore/convert/convert.go index 4d834e0fb..01f588e8d 100644 --- a/code/go/0chain.net/blobbercore/convert/convert.go +++ b/code/go/0chain.net/blobbercore/convert/convert.go @@ -446,7 +446,7 @@ func WriteFileGRPCToHTTP(req *blobbergrpc.UploadFileRequest) (*http.Request, err } if req.Method != `DELETE` { - body := new(bytes.Buffer) + body := bytes.NewBuffer(nil) writer := multipart.NewWriter(body) part, err := writer.CreateFormFile(`uploadFile`, formData.Filename) if err != nil { diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 0de121463..166bb3de0 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -6,6 +6,7 @@ import ( "encoding/json" "fmt" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "io" "log" "math/rand" "net/http" @@ -954,6 +955,16 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { t.Fatal(err) } + root, _ := os.Getwd() + file, err := os.Open(root + "/grpc_handler_integration_test.go") + if err != nil { + t.Fatal(err) + } + fileB := make([]byte, 0) + if _, err := io.ReadFull(file, fileB); err != nil { + t.Fatal(err) + } + testCases := []struct { name string context metadata.MD @@ -976,7 +987,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { Method: "POST", UploadMeta: string(formFieldByt), UpdateMeta: "", - UploadFile: []byte{}, + UploadFile: fileB, UploadThumbnailFile: []byte{}, }, expectedFileName: "/some_file", From d3e7720fe97015c780e48580b7a2d4e6e895180a Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 28 Jun 2021 02:08:34 +0530 Subject: [PATCH 144/183] integrated tests WIP --- code/go/0chain.net/blobbercore/convert/convert.go | 4 ++-- .../blobbercore/handler/grpc_handler_integration_test.go | 6 +++++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/convert.go b/code/go/0chain.net/blobbercore/convert/convert.go index 01f588e8d..7a6bb38a6 100644 --- a/code/go/0chain.net/blobbercore/convert/convert.go +++ b/code/go/0chain.net/blobbercore/convert/convert.go @@ -477,9 +477,9 @@ func WriteFileGRPCToHTTP(req *blobbergrpc.UploadFileRequest) (*http.Request, err } r.Header.Set("Content-Type", writer.FormDataContentType()) - fmt.Println(`111111111111`) + fmt.Println(string(req.UploadFile)) + } - fmt.Println(`22222222222`) return r, nil } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 166bb3de0..9b2bb824e 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -960,7 +960,11 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { if err != nil { t.Fatal(err) } - fileB := make([]byte, 0) + //stats, err := file.Stat() + //if err != nil { + // panic(err) + //} + fileB := make([]byte, 1000) if _, err := io.ReadFull(file, fileB); err != nil { t.Fatal(err) } From 266ad76c6f771ffb357af962210a1ad7a68f8ca8 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 28 Jun 2021 02:23:10 +0530 Subject: [PATCH 145/183] upload handler integrated tests implemented --- code/go/0chain.net/blobbercore/convert/convert.go | 3 --- .../handler/grpc_handler_integration_test.go | 14 +++++++------- 2 files changed, 7 insertions(+), 10 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/convert.go b/code/go/0chain.net/blobbercore/convert/convert.go index 7a6bb38a6..1e600464f 100644 --- a/code/go/0chain.net/blobbercore/convert/convert.go +++ b/code/go/0chain.net/blobbercore/convert/convert.go @@ -4,7 +4,6 @@ import ( "bytes" "context" "encoding/json" - "fmt" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" "mime/multipart" "net/http" @@ -477,8 +476,6 @@ func WriteFileGRPCToHTTP(req *blobbergrpc.UploadFileRequest) (*http.Request, err } r.Header.Set("Content-Type", writer.FormDataContentType()) - fmt.Println(string(req.UploadFile)) - } return r, nil diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 9b2bb824e..aba50bc35 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -924,7 +924,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { AllocationID: "exampleId", } - formFieldByt, err := json.Marshal(&allocation.UpdateFileChange{}) + formFieldByt, err := json.Marshal(&allocation.UpdateFileChange{NewFileChange: allocation.NewFileChange{Filename: `grpc_handler_integration_test.go`}}) if err != nil { t.Fatal(err) } @@ -960,11 +960,11 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { if err != nil { t.Fatal(err) } - //stats, err := file.Stat() - //if err != nil { - // panic(err) - //} - fileB := make([]byte, 1000) + stats, err := file.Stat() + if err != nil { + panic(err) + } + fileB := make([]byte, stats.Size()) if _, err := io.ReadFull(file, fileB); err != nil { t.Fatal(err) } @@ -994,7 +994,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { UploadFile: fileB, UploadThumbnailFile: []byte{}, }, - expectedFileName: "/some_file", + expectedFileName: "grpc_handler_integration_test.go", expectingError: false, }, { From 5327565069ba060f84665a7c42fae9f47f93f8fe Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 28 Jun 2021 03:09:44 +0530 Subject: [PATCH 146/183] upload handler integrated tests implemented --- .../handler/grpc_handler_helper_unit_test.go | 36 +------------------ .../handler/grpc_handler_integration_test.go | 30 +--------------- 2 files changed, 2 insertions(+), 64 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 63f5d7719..e86adbc77 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -545,7 +545,7 @@ VALUES return nil } -func (c *TestDataController) AddUploadTestData(allocationTx, pubkey, clientId, wmSig string, now common.Timestamp) error { +func (c *TestDataController) AddUploadTestData(allocationTx, pubkey, clientId string) error { var err error var tx *sql.Tx defer func() { @@ -579,40 +579,6 @@ VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `', return err } - _, err = tx.Exec(` -INSERT INTO allocation_connections (connection_id, allocation_id, client_id, size, status) -VALUES ('connection_id' ,'exampleId','` + clientId + `', 1337, 1); -`) - if err != nil { - return err - } - - _, err = tx.Exec(` -INSERT INTO allocation_changes (id, connection_id, operation, size, input) -VALUES (1 ,'connection_id','rename', 1200, '{"allocation_id":"exampleId","path":"/some_file","new_name":"new_name"}'); -`) - if err != nil { - return err - } - - _, err = tx.Exec(` -INSERT INTO write_markers(prev_allocation_root, allocation_root, status, allocation_id, size, client_id, signature, blobber_id, timestamp, connection_id, client_key) -VALUES ('/', '/', 2,'exampleId', 1337, '` + clientId + `','` + wmSig + `','blobber_id', ` + fmt.Sprint(now) + `, 'connection_id', '` + pubkey + `'); -`) - if err != nil { - return err - } - - // _, err = tx.Exec(` - //INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash, parent_path) - //VALUES - //(1234,'exampleId','exampleId:examplePath','exampleId:examplePath','d','root','/','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'), - //(123,'exampleId','exampleId:examplePath','exampleId:examplePath','f','some_file','/some_file','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'); - //`) - // if err != nil { - // return err - // } - err = tx.Commit() if err != nil { return err diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index aba50bc35..493be6112 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -915,43 +915,16 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) pubKeyBytes, _ := hex.DecodeString(pubKey) clientId := encryption.Hash(pubKeyBytes) - now := common.Timestamp(time.Now().UnixNano()) - - blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" - blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) - - fr := reference.Ref{ - AllocationID: "exampleId", - } formFieldByt, err := json.Marshal(&allocation.UpdateFileChange{NewFileChange: allocation.NewFileChange{Filename: `grpc_handler_integration_test.go`}}) if err != nil { t.Fatal(err) } - rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) - - wm := writemarker.WriteMarker{ - AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), - PreviousAllocationRoot: "/", - AllocationID: "exampleId", - Size: 1337, - BlobberID: encryption.Hash(blobberPubKeyBytes), - Timestamp: now, - ClientID: clientId, - } - - wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) - if err != nil { - t.Fatal(err) - } - - wm.Signature = wmSig - if err := tdController.ClearDatabase(); err != nil { t.Fatal(err) } - if err := tdController.AddUploadTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { + if err := tdController.AddUploadTestData(allocationTx, pubKey, clientId); err != nil { t.Fatal(err) } @@ -1025,7 +998,6 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { response, err := blobberClient.WriteFile(ctx, tc.input) if err != nil { if !tc.expectingError { - t.Log(err.Error()) t.Fatal(err) } From 3c600d3f80157c15d9727c679f3d05e30c0641fa Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 28 Jun 2021 21:58:10 +0530 Subject: [PATCH 147/183] upload attributes handler integrated tests implemented --- .../blobbercore/convert/responseHandler.go | 9 +- .../handler/grpc_handler_helper_unit_test.go | 60 +++++++++++++ .../handler/grpc_handler_integration_test.go | 86 +++++++++++++++++++ .../handler/object_operation_handler.go | 3 + 4 files changed, 157 insertions(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 34c99bbc3..20242218d 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -3,6 +3,7 @@ package convert import ( "context" "encoding/json" + "fmt" "github.com/0chain/blobber/code/go/0chain.net/core/common" @@ -182,11 +183,17 @@ func CollaboratorResponseCreator(r interface{}) *blobbergrpc.CollaboratorRespons } func UpdateObjectAttributesResponseCreator(r interface{}) *blobbergrpc.UpdateObjectAttributesResponse { + + fmt.Println(`response - `, r) + if r != nil { return nil } - httpResp, _ := r.(*reference.Attributes) + httpResp, ok := r.(*reference.Attributes) + if !ok { + fmt.Println(`response not okay - `, r) + } return &blobbergrpc.UpdateObjectAttributesResponse{WhoPaysForReads: int64(httpResp.WhoPaysForReads)} } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index e89037c5f..305385728 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -544,3 +544,63 @@ VALUES return nil } + +func (c *TestDataController) AddAttributesTestData(allocationTx, pubkey, clientId string) error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO allocation_connections (connection_id, allocation_id, client_id, size, status) +VALUES ('connection_id' ,'exampleId','` + clientId + `', 1337, 1); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash, parent_path) +VALUES +(1234,'exampleId','exampleId:examplePath','exampleId:examplePath','d','root','/','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'), +(123,'exampleId','exampleId:examplePath','exampleId:examplePath','f','some_file','/some_file','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 8361e34dc..0d8de03b0 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -905,6 +905,92 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } } }) + + t.Run("TestUpdateAttributes", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddAttributesTestData(allocationTx, pubKey, clientId); err != nil { + t.Fatal(err) + } + + attr := &reference.Attributes{WhoPaysForReads: common.WhoPaysOwner} + attrBytes, err := json.Marshal(attr) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.UpdateObjectAttributesRequest + expectedMessage int + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.UpdateObjectAttributesRequest{ + Allocation: allocationTx, + Path: "/some_file", + PathHash: "exampleId:examplePath", + ConnectionId: "connection_id", + Attributes: string(attrBytes), + }, + expectedMessage: int(attr.WhoPaysForReads), + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.UpdateObjectAttributesRequest{ + Allocation: "", + Path: "", + PathHash: "", + ConnectionId: "", + Attributes: "", + }, + expectedMessage: 0, + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := blobberClient.UpdateObjectAttributes(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetWhoPaysForReads() != int64(tc.expectedMessage) { + t.Fatal("failed!") + } + } + }) } func randString(n int) string { diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go index 7ccc89fe3..ed220050e 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go @@ -5,6 +5,7 @@ import ( "encoding/hex" "encoding/json" "errors" + "fmt" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberHTTP" @@ -704,6 +705,8 @@ func (fsh *StorageHandler) UpdateObjectAttributes(ctx context.Context, "missing new attributes, pass at least {} for empty attributes") } + fmt.Println(`attributes --- `, attributes) + var attrs = new(reference.Attributes) if err = json.Unmarshal([]byte(attributes), attrs); err != nil { return nil, common.NewErrorf("update_object_attributes", From ad10f776832ffed5d2f6dd527c5cc310671257f8 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 28 Jun 2021 22:20:39 +0530 Subject: [PATCH 148/183] update attributes handler integrated tests implemented --- .../blobbercore/convert/responseHandler.go | 13 +++---------- .../handler/grpc_handler_integration_test.go | 2 +- .../blobbercore/handler/object_operation_handler.go | 4 ---- 3 files changed, 4 insertions(+), 15 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 20242218d..a2f72e208 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -3,8 +3,6 @@ package convert import ( "context" "encoding/json" - "fmt" - "github.com/0chain/blobber/code/go/0chain.net/core/common" stats2 "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" @@ -183,17 +181,12 @@ func CollaboratorResponseCreator(r interface{}) *blobbergrpc.CollaboratorRespons } func UpdateObjectAttributesResponseCreator(r interface{}) *blobbergrpc.UpdateObjectAttributesResponse { - - fmt.Println(`response - `, r) - - if r != nil { + if r == nil { return nil } - httpResp, ok := r.(*reference.Attributes) - if !ok { - fmt.Println(`response not okay - `, r) - } + httpResp, _ := r.(*reference.Attributes) + return &blobbergrpc.UpdateObjectAttributesResponse{WhoPaysForReads: int64(httpResp.WhoPaysForReads)} } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 0d8de03b0..f0158cb5b 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -921,7 +921,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { t.Fatal(err) } - attr := &reference.Attributes{WhoPaysForReads: common.WhoPaysOwner} + attr := &reference.Attributes{WhoPaysForReads: common.WhoPays3rdParty} attrBytes, err := json.Marshal(attr) if err != nil { t.Fatal(err) diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go index ed220050e..ec91938a0 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go @@ -5,8 +5,6 @@ import ( "encoding/hex" "encoding/json" "errors" - "fmt" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberHTTP" "net/http" @@ -705,8 +703,6 @@ func (fsh *StorageHandler) UpdateObjectAttributes(ctx context.Context, "missing new attributes, pass at least {} for empty attributes") } - fmt.Println(`attributes --- `, attributes) - var attrs = new(reference.Attributes) if err = json.Unmarshal([]byte(attributes), attrs); err != nil { return nil, common.NewErrorf("update_object_attributes", From f217228fd42f2f7e79e556e3b56df3e2ce88e29a Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 28 Jun 2021 22:47:06 +0530 Subject: [PATCH 149/183] copy object handler integrated tests implemented --- .../handler/grpc_handler_helper_unit_test.go | 60 ++++++++++++++ .../handler/grpc_handler_integration_test.go | 80 +++++++++++++++++++ 2 files changed, 140 insertions(+) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 305385728..da189506d 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -604,3 +604,63 @@ VALUES return nil } + +func (c *TestDataController) AddCopyObjectData(allocationTx, pubkey, clientId string) error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO allocation_connections (connection_id, allocation_id, client_id, size, status) +VALUES ('connection_id' ,'exampleId','` + clientId + `', 1337, 1); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash, parent_path) +VALUES +(1234,'exampleId','exampleId:examplePath','exampleId:examplePath','d','root','/copy','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'), +(123,'exampleId','exampleId:examplePath','exampleId:examplePath','f','some_file','/some_file','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index f0158cb5b..b84cc13a3 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -991,6 +991,86 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } } }) + + t.Run("TestCopyObject", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddCopyObjectData(allocationTx, pubKey, clientId); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CopyObjectRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CopyObjectRequest{ + Allocation: allocationTx, + Path: "/some_file", + PathHash: "exampleId:examplePath", + ConnectionId: "connection_id", + Dest: "/copy", + }, + expectedMessage: "some_file", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CopyObjectRequest{ + Allocation: "", + Path: "", + PathHash: "", + ConnectionId: "", + Dest: "", + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := blobberClient.CopyObject(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetFilename() != tc.expectedMessage { + t.Fatal("failed!") + } + } + }) } func randString(n int) string { From 77f6db76bcfd769eb70ddcb1fe0c86d60d475752 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Mon, 28 Jun 2021 23:03:08 +0530 Subject: [PATCH 150/183] rename object handler integrated tests implemented --- .../handler/grpc_handler_helper_unit_test.go | 60 ++++++++++++++ .../handler/grpc_handler_integration_test.go | 80 +++++++++++++++++++ 2 files changed, 140 insertions(+) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index da189506d..4a0f9cac3 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -664,3 +664,63 @@ VALUES return nil } + +func (c *TestDataController) AddRenameTestData(allocationTx, pubkey, clientId string) error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO allocation_connections (connection_id, allocation_id, client_id, size, status) +VALUES ('connection_id' ,'exampleId','` + clientId + `', 1337, 1); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash, parent_path) +VALUES +(1234,'exampleId','exampleId:examplePath','exampleId:examplePath','d','root','/','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'), +(123,'exampleId','exampleId:examplePath','exampleId:examplePath','f','some_file','/some_file','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index b84cc13a3..bb4f97ebe 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -1071,6 +1071,86 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } } }) + + t.Run("TestRenameObject", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddRenameTestData(allocationTx, pubKey, clientId); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.RenameObjectRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.RenameObjectRequest{ + Allocation: allocationTx, + Path: "/some_file", + PathHash: "exampleId:examplePath", + ConnectionId: "connection_id", + NewName: "some_new_file", + }, + expectedMessage: "some_new_file", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.RenameObjectRequest{ + Allocation: "", + Path: "", + PathHash: "", + ConnectionId: "", + NewName: "", + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := blobberClient.RenameObject(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetFilename() != tc.expectedMessage { + t.Fatal("failed!") + } + } + }) } func randString(n int) string { From 25229dd9cb0e33d2adeed9492151c754318dd2e3 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 29 Jun 2021 00:14:59 +0530 Subject: [PATCH 151/183] download handler request multipart implemented --- .../0chain.net/blobbercore/convert/convert.go | 58 ++++++++++ .../handler/grpc_handler_integration_test.go | 106 ++++++++++++++++++ .../handler/object_operation_grpc_handler.go | 13 +-- 3 files changed, 165 insertions(+), 12 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/convert.go b/code/go/0chain.net/blobbercore/convert/convert.go index 308ef6c87..09b39f04b 100644 --- a/code/go/0chain.net/blobbercore/convert/convert.go +++ b/code/go/0chain.net/blobbercore/convert/convert.go @@ -1,8 +1,12 @@ package convert import ( + "bytes" "context" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "mime/multipart" + "net/http" + "strings" "time" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" @@ -419,3 +423,57 @@ func convertDirMetaDataGRPCToDirRef(dirref *blobbergrpc.DirMetaData) *reference. UpdatedAt: time.Unix(0, dirref.UpdatedAt), } } + +func DownloadFileGRPCToHTTP(req *blobbergrpc.DownloadFileRequest) (*http.Request, error) { + body := bytes.NewBuffer([]byte{}) + writer := multipart.NewWriter(body) + + err := writer.WriteField("path", req.Path) + if err != nil { + return nil, err + } + + err = writer.WriteField("path_hash", req.PathHash) + if err != nil { + return nil, err + } + + err = writer.WriteField("rx_pay", req.RxPay) + if err != nil { + return nil, err + } + + err = writer.WriteField("block_num", req.BlockNum) + if err != nil { + return nil, err + } + + err = writer.WriteField("num_blocks", req.NumBlocks) + if err != nil { + return nil, err + } + + err = writer.WriteField("read_marker", req.ReadMarker) + if err != nil { + return nil, err + } + + err = writer.WriteField("auth_token", req.AuthToken) + if err != nil { + return nil, err + } + + err = writer.WriteField("content", req.Content) + if err != nil { + return nil, err + } + + r, err := http.NewRequest("POST", "", strings.NewReader(body.String())) + if err != nil { + return nil, err + } + + r.Header.Set("Content-Type", writer.FormDataContentType()) + + return r, nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index bb4f97ebe..9c68f2cab 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -5,6 +5,7 @@ import ( "encoding/hex" "encoding/json" "fmt" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" "log" "math/rand" "net/http" @@ -1151,6 +1152,111 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { } } }) + + t.Run("TestDownload", func(t *testing.T) { + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddRenameTestData(allocationTx, pubKey, clientId); err != nil { + t.Fatal(err) + } + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + rm := readmarker.ReadMarker{ + ClientID: "", + ClientPublicKey: "", + BlobberID: encryption.Hash(blobberPubKeyBytes), + AllocationID: "", + OwnerID: "", + Timestamp: 0, + ReadCounter: 0, + Signature: "", + Suspend: 0, + PayerID: "", + AuthTicket: nil, + } + + rmString, err := json.Marshal(rm) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.DownloadFileRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.DownloadFileRequest{ + Allocation: allocationTx, + Path: "/some_file", + PathHash: "exampleId:examplePath", + ReadMarker: string(rmString), + }, + expectedMessage: "some_new_file", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.DownloadFileRequest{ + Allocation: "", + Path: "", + PathHash: "", + RxPay: "", + BlockNum: "", + NumBlocks: "", + ReadMarker: "", + AuthToken: "", + Content: "", + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := blobberClient.DownloadFile(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetPath() != tc.expectedMessage { + t.Fatal("failed!") + } + } + }) } func randString(n int) string { diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index c9d1f9cd5..83b748ac6 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -71,23 +71,12 @@ func (b *blobberGRPCService) RenameObject(ctx context.Context, req *blobbergrpc. } func (b *blobberGRPCService) DownloadFile(ctx context.Context, req *blobbergrpc.DownloadFileRequest) (*blobbergrpc.DownloadFileResponse, error) { - - r, err := http.NewRequest("POST", "", nil) + r, err := convert.DownloadFileGRPCToHTTP(req) if err != nil { return nil, err } httpRequestWithMetaData(r, GetGRPCMetaDataFromCtx(ctx), req.Allocation) - r.Form = map[string][]string{ - "path": {req.Path}, - "path_hash": {req.PathHash}, - "rx_pay": {req.RxPay}, - "block_num": {req.BlockNum}, - "num_blocks": {req.NumBlocks}, - "read_marker": {req.ReadMarker}, - "auth_token": {req.AuthToken}, - "content": {req.AuthToken}, - } resp, err := DownloadHandler(ctx, r) if err != nil { From 5852f507c2a072d54fdc1f837099df0e5428539c Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 29 Jun 2021 00:25:39 +0530 Subject: [PATCH 152/183] download handler request multipart writer closed --- code/go/0chain.net/blobbercore/convert/convert.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/go/0chain.net/blobbercore/convert/convert.go b/code/go/0chain.net/blobbercore/convert/convert.go index 09b39f04b..45122609e 100644 --- a/code/go/0chain.net/blobbercore/convert/convert.go +++ b/code/go/0chain.net/blobbercore/convert/convert.go @@ -468,6 +468,8 @@ func DownloadFileGRPCToHTTP(req *blobbergrpc.DownloadFileRequest) (*http.Request return nil, err } + writer.Close() + r, err := http.NewRequest("POST", "", strings.NewReader(body.String())) if err != nil { return nil, err From 8f1028a1066819ddd405e3202215aa653f488073 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 29 Jun 2021 02:46:47 +0530 Subject: [PATCH 153/183] download handler integration tests WIP --- .../handler/grpc_handler_helper_unit_test.go | 76 +++++++++++++++++++ .../handler/grpc_handler_integration_test.go | 38 ++++++---- 2 files changed, 101 insertions(+), 13 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index 4a0f9cac3..d7842c8e8 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -724,3 +724,79 @@ VALUES return nil } + +func (c *TestDataController) AddDownloadTestData(allocationTx, pubkey, clientId, wmSig string, now common.Timestamp) error { + var err error + var tx *sql.Tx + defer func() { + if err != nil { + if tx != nil { + errRollback := tx.Rollback() + if errRollback != nil { + log.Println(errRollback) + } + } + } + }() + + db, err := c.db.DB() + if err != nil { + return err + } + + tx, err = db.BeginTx(context.Background(), &sql.TxOptions{}) + if err != nil { + return err + } + + expTime := time.Now().Add(time.Hour * 100000).UnixNano() + + _, err = tx.Exec(` +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO allocation_connections (connection_id, allocation_id, client_id, size, status) +VALUES ('connection_id' ,'exampleId','` + clientId + `', 1337, 1); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO allocation_changes (id, connection_id, operation, size, input) +VALUES (1 ,'connection_id','rename', 1200, '{"allocation_id":"exampleId","path":"/some_file","new_name":"new_name"}'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO write_markers(prev_allocation_root, allocation_root, status, allocation_id, size, client_id, signature, blobber_id, timestamp, connection_id, client_key) +VALUES ('/', '/', 2,'exampleId', 1337, '` + clientId + `','` + wmSig + `','blobber_id', ` + fmt.Sprint(now) + `, 'connection_id', '` + pubkey + `'); +`) + if err != nil { + return err + } + + _, err = tx.Exec(` +INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash, parent_path) +VALUES +(1234,'exampleId','exampleId:examplePath','exampleId:examplePath','d','root','/','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'), +(123,'exampleId','exampleId:examplePath','exampleId:examplePath','f','some_file','/some_file','someHash','customMeta','sonMonWenMyFile','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'); +`) + if err != nil { + return err + } + + err = tx.Commit() + if err != nil { + return err + } + + return nil +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 9c68f2cab..9d9e95143 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -1156,40 +1156,51 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { t.Run("TestDownload", func(t *testing.T) { allocationTx := randString(32) + _, err := os.Create(`example`) + if err != nil { + t.Fatal(err) + } + defer os.Remove(`example`) + pubKey, _, signScheme := GeneratePubPrivateKey(t) clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) pubKeyBytes, _ := hex.DecodeString(pubKey) clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().Unix()) + allocationId := `exampleId` if err := tdController.ClearDatabase(); err != nil { t.Fatal(err) } - if err := tdController.AddRenameTestData(allocationTx, pubKey, clientId); err != nil { - t.Fatal(err) - } blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) rm := readmarker.ReadMarker{ - ClientID: "", - ClientPublicKey: "", BlobberID: encryption.Hash(blobberPubKeyBytes), - AllocationID: "", - OwnerID: "", - Timestamp: 0, - ReadCounter: 0, - Signature: "", - Suspend: 0, - PayerID: "", - AuthTicket: nil, + AllocationID: allocationId, + ClientPublicKey: pubKey, + ClientID: clientId, + OwnerID: clientId, + Timestamp: now, + ReadCounter: 1337, } + rmSig, err := signScheme.Sign(encryption.Hash(rm.GetHashData())) + if err != nil { + t.Fatal(err) + } + rm.Signature = rmSig + rmString, err := json.Marshal(rm) if err != nil { t.Fatal(err) } + if err := tdController.AddDownloadTestData(allocationTx, pubKey, clientId, rmSig, now); err != nil { + t.Fatal(err) + } + testCases := []struct { name string context metadata.MD @@ -1209,6 +1220,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { Path: "/some_file", PathHash: "exampleId:examplePath", ReadMarker: string(rmString), + BlockNum: "10", }, expectedMessage: "some_new_file", expectingError: false, From 1d29d5a02f1da63be7f13807477a542378b891d3 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 29 Jun 2021 04:14:38 +0530 Subject: [PATCH 154/183] download handler integration tests WIP --- .../blobbercore/convert/responseHandler.go | 22 +++++--- .../handler/grpc_handler_helper_unit_test.go | 10 +--- .../handler/grpc_handler_integration_test.go | 56 ++++++++++++++++--- 3 files changed, 63 insertions(+), 25 deletions(-) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index a2f72e208..3d2cd4a6b 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -376,12 +376,20 @@ func DownloadFileResponseCreator(r interface{}) *blobbergrpc.DownloadFileRespons return nil } - httpResp, _ := r.(*blobberHTTP.DownloadResponse) - return &blobbergrpc.DownloadFileResponse{ - Success: httpResp.Success, - Data: httpResp.Data, - AllocationId: httpResp.AllocationID, - Path: httpResp.Path, - LatestRm: ReadMarkerToReadMarkerGRPC(httpResp.LatestRM), + switch httpResp := r.(type) { + case []byte: + return &blobbergrpc.DownloadFileResponse{ + Data: httpResp, + } + case *blobberHTTP.DownloadResponse: + return &blobbergrpc.DownloadFileResponse{ + Success: httpResp.Success, + Data: httpResp.Data, + AllocationId: httpResp.AllocationID, + Path: httpResp.Path, + LatestRm: ReadMarkerToReadMarkerGRPC(httpResp.LatestRM), + } } + + return nil } diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index d7842c8e8..72a20d28a 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -775,19 +775,11 @@ VALUES (1 ,'connection_id','rename', 1200, '{"allocation_id":"exampleId","path": return err } - _, err = tx.Exec(` -INSERT INTO write_markers(prev_allocation_root, allocation_root, status, allocation_id, size, client_id, signature, blobber_id, timestamp, connection_id, client_key) -VALUES ('/', '/', 2,'exampleId', 1337, '` + clientId + `','` + wmSig + `','blobber_id', ` + fmt.Sprint(now) + `, 'connection_id', '` + pubkey + `'); -`) - if err != nil { - return err - } - _, err = tx.Exec(` INSERT INTO reference_objects (id, allocation_id, path_hash,lookup_hash,type,name,path,hash,custom_meta,content_hash,merkle_root,actual_file_hash,mimetype,write_marker,thumbnail_hash, actual_thumbnail_hash, parent_path) VALUES (1234,'exampleId','exampleId:examplePath','exampleId:examplePath','d','root','/','someHash','customMeta','contentHash','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'), -(123,'exampleId','exampleId:examplePath','exampleId:examplePath','f','some_file','/some_file','someHash','customMeta','sonMonWenMyFile','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'); +(123,'exampleId','exampleId:examplePath','exampleId:examplePath','f','some_file','/some_file','someHash','customMeta','tmpMonWenMyFile','merkleRoot','actualFileHash','mimetype','writeMarker','thumbnailHash','actualThumbnailHash','/'); `) if err != nil { return err diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 9d9e95143..b312da48b 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -6,6 +6,7 @@ import ( "encoding/json" "fmt" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "io" "log" "math/rand" "net/http" @@ -1156,11 +1157,52 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { t.Run("TestDownload", func(t *testing.T) { allocationTx := randString(32) - _, err := os.Create(`example`) + root, _ := os.Getwd() + path := strings.Split(root, `code`) + err := os.Mkdir(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon`, 0700) if err != nil { t.Fatal(err) } - defer os.Remove(`example`) + err = os.Mkdir(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`, 0700) + if err != nil { + t.Fatal(err) + } + f, err := os.Create(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen/MyFile`) + if err != nil { + t.Fatal(err) + } + file, err := os.Open(root + "/grpc_handler_integration_test.go") + if err != nil { + t.Fatal(err) + } + stat, err := file.Stat() + if err != nil { + t.Fatal(err) + } + fileB := make([]byte, stat.Size()) + if _, err := io.ReadFull(file, fileB); err != nil { + t.Fatal(err) + } + _, err = f.Write(fileB) + if err != nil { + t.Fatal(err) + } + _, err = f.Write(fileB) + if err != nil { + t.Fatal(err) + } + _, err = f.Write(fileB) + if err != nil { + t.Fatal(err) + } + fmt.Println(`file size`, stat.Size()) + file.Close() + f.Close() + defer func() { + os.Remove(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen/MyFile`) + os.Remove(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`) + os.Remove(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon`) + }() pubKey, _, signScheme := GeneratePubPrivateKey(t) clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) @@ -1183,7 +1225,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { ClientID: clientId, OwnerID: clientId, Timestamp: now, - ReadCounter: 1337, + //ReadCounter: 1337, } rmSig, err := signScheme.Sign(encryption.Hash(rm.GetHashData())) @@ -1220,7 +1262,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { Path: "/some_file", PathHash: "exampleId:examplePath", ReadMarker: string(rmString), - BlockNum: "10", + BlockNum: "2", }, expectedMessage: "some_new_file", expectingError: false, @@ -1251,7 +1293,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { for _, tc := range testCases { ctx := context.Background() ctx = metadata.NewOutgoingContext(ctx, tc.context) - response, err := blobberClient.DownloadFile(ctx, tc.input) + _, err := blobberClient.DownloadFile(ctx, tc.input) if err != nil { if !tc.expectingError { t.Fatal(err) @@ -1263,10 +1305,6 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { if tc.expectingError { t.Fatal("expected error") } - - if response.GetPath() != tc.expectedMessage { - t.Fatal("failed!") - } } }) } From 0cadb698fb239d7887c28d51a95399631ff94702 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Tue, 29 Jun 2021 04:35:55 +0530 Subject: [PATCH 155/183] download handler integration tests edit makefile --- Makefile | 4 +++- .../handler/grpc_handler_integration_test.go | 14 +------------- 2 files changed, 4 insertions(+), 14 deletions(-) diff --git a/Makefile b/Makefile index dc1cdf24d..1110730da 100644 --- a/Makefile +++ b/Makefile @@ -7,4 +7,6 @@ lint: golangci-lint run --timeout 2m0s; integration-tests: - go test ./... -args integration; \ No newline at end of file + mkdir -p docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen + go test ./... -args integration; + rm -r docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon \ No newline at end of file diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index b312da48b..14b2e5386 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -1159,14 +1159,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { root, _ := os.Getwd() path := strings.Split(root, `code`) - err := os.Mkdir(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon`, 0700) - if err != nil { - t.Fatal(err) - } - err = os.Mkdir(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`, 0700) - if err != nil { - t.Fatal(err) - } + f, err := os.Create(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen/MyFile`) if err != nil { t.Fatal(err) @@ -1198,11 +1191,6 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { fmt.Println(`file size`, stat.Size()) file.Close() f.Close() - defer func() { - os.Remove(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen/MyFile`) - os.Remove(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`) - os.Remove(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon`) - }() pubKey, _, signScheme := GeneratePubPrivateKey(t) clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) From 5ba861742b6a076afc5e6adffeaa3b63dbf3b25b Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 30 Jun 2021 08:56:00 +0530 Subject: [PATCH 156/183] upload handler grpc method name changed --- .../blobbercore/blobbergrpc/blobber.pb.go | 148 +++++++++--------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 84 +++++----- .../blobbergrpc/blobber_grpc.pb.go | 24 +-- .../blobbergrpc/proto/blobber.proto | 2 +- .../handler/grpc_handler_integration_test.go | 2 +- .../handler/object_operation_grpc_handler.go | 2 +- .../blobbercore/openapi/blobber.swagger.json | 6 +- 7 files changed, 134 insertions(+), 134 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 298637c34..3ae0e2816 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -3985,7 +3985,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xc5, 0x12, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xc6, 0x12, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, @@ -4065,79 +4065,79 @@ var file_blobber_proto_rawDesc = []byte{ 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xc9, - 0x01, 0x0a, 0x09, 0x57, 0x72, 0x69, 0x74, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x25, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, - 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x6d, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x67, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, - 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, 0x1a, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, 0x2a, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, - 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, - 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, - 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, - 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, - 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, - 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, - 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, - 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xca, + 0x01, 0x0a, 0x0a, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, - 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, - 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, - 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, - 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, 0x74, - 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, 0x79, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, 0x0a, - 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, 0x2e, + 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x6d, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x67, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, + 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, 0x1a, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, 0x2a, 0x1c, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, + 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, + 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, - 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, - 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2f, - 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, - 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, - 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, - 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, + 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, + 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, + 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, + 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, + 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, + 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, + 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, + 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, + 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, + 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, + 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, + 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, + 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -4234,7 +4234,7 @@ var file_blobber_proto_depIdxs = []int32{ 8, // 31: blobber.service.v1.Blobber.GetObjectTree:input_type -> blobber.service.v1.GetObjectTreeRequest 28, // 32: blobber.service.v1.Blobber.DownloadFile:input_type -> blobber.service.v1.DownloadFileRequest 35, // 33: blobber.service.v1.Blobber.RenameObject:input_type -> blobber.service.v1.RenameObjectRequest - 37, // 34: blobber.service.v1.Blobber.WriteFile:input_type -> blobber.service.v1.UploadFileRequest + 37, // 34: blobber.service.v1.Blobber.UploadFile:input_type -> blobber.service.v1.UploadFileRequest 4, // 35: blobber.service.v1.Blobber.Commit:input_type -> blobber.service.v1.CommitRequest 2, // 36: blobber.service.v1.Blobber.CalculateHash:input_type -> blobber.service.v1.CalculateHashRequest 6, // 37: blobber.service.v1.Blobber.CommitMetaTxn:input_type -> blobber.service.v1.CommitMetaTxnRequest @@ -4250,7 +4250,7 @@ var file_blobber_proto_depIdxs = []int32{ 9, // 47: blobber.service.v1.Blobber.GetObjectTree:output_type -> blobber.service.v1.GetObjectTreeResponse 29, // 48: blobber.service.v1.Blobber.DownloadFile:output_type -> blobber.service.v1.DownloadFileResponse 36, // 49: blobber.service.v1.Blobber.RenameObject:output_type -> blobber.service.v1.RenameObjectResponse - 38, // 50: blobber.service.v1.Blobber.WriteFile:output_type -> blobber.service.v1.UploadFileResponse + 38, // 50: blobber.service.v1.Blobber.UploadFile:output_type -> blobber.service.v1.UploadFileResponse 5, // 51: blobber.service.v1.Blobber.Commit:output_type -> blobber.service.v1.CommitResponse 3, // 52: blobber.service.v1.Blobber.CalculateHash:output_type -> blobber.service.v1.CalculateHashResponse 7, // 53: blobber.service.v1.Blobber.CommitMetaTxn:output_type -> blobber.service.v1.CommitMetaTxnResponse diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 775218e0b..597e47a28 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -623,7 +623,7 @@ func local_request_Blobber_RenameObject_0(ctx context.Context, marshaler runtime } -func request_Blobber_WriteFile_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { +func request_Blobber_UploadFile_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq UploadFileRequest var metadata runtime.ServerMetadata @@ -652,12 +652,12 @@ func request_Blobber_WriteFile_0(ctx context.Context, marshaler runtime.Marshale return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.WriteFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.UploadFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_WriteFile_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { +func local_request_Blobber_UploadFile_0(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq UploadFileRequest var metadata runtime.ServerMetadata @@ -686,12 +686,12 @@ func local_request_Blobber_WriteFile_0(ctx context.Context, marshaler runtime.Ma return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.WriteFile(ctx, &protoReq) + msg, err := server.UploadFile(ctx, &protoReq) return msg, metadata, err } -func request_Blobber_WriteFile_1(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { +func request_Blobber_UploadFile_1(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq UploadFileRequest var metadata runtime.ServerMetadata @@ -720,12 +720,12 @@ func request_Blobber_WriteFile_1(ctx context.Context, marshaler runtime.Marshale return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.WriteFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.UploadFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_WriteFile_1(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { +func local_request_Blobber_UploadFile_1(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq UploadFileRequest var metadata runtime.ServerMetadata @@ -754,12 +754,12 @@ func local_request_Blobber_WriteFile_1(ctx context.Context, marshaler runtime.Ma return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.WriteFile(ctx, &protoReq) + msg, err := server.UploadFile(ctx, &protoReq) return msg, metadata, err } -func request_Blobber_WriteFile_2(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { +func request_Blobber_UploadFile_2(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq UploadFileRequest var metadata runtime.ServerMetadata @@ -788,12 +788,12 @@ func request_Blobber_WriteFile_2(ctx context.Context, marshaler runtime.Marshale return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := client.WriteFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.UploadFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func local_request_Blobber_WriteFile_2(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { +func local_request_Blobber_UploadFile_2(ctx context.Context, marshaler runtime.Marshaler, server BlobberServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq UploadFileRequest var metadata runtime.ServerMetadata @@ -822,7 +822,7 @@ func local_request_Blobber_WriteFile_2(ctx context.Context, marshaler runtime.Ma return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - msg, err := server.WriteFile(ctx, &protoReq) + msg, err := server.UploadFile(ctx, &protoReq) return msg, metadata, err } @@ -1448,18 +1448,18 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) - mux.Handle("POST", pattern_Blobber_WriteFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_UploadFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/UploadFile") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_WriteFile_0(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_UploadFile_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -1467,22 +1467,22 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_WriteFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_UploadFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("PUT", pattern_Blobber_WriteFile_1, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("PUT", pattern_Blobber_UploadFile_1, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/UploadFile") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_WriteFile_1(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_UploadFile_1(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -1490,22 +1490,22 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_WriteFile_1(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_UploadFile_1(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("DELETE", pattern_Blobber_WriteFile_2, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("DELETE", pattern_Blobber_UploadFile_2, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/blobber.service.v1.Blobber/UploadFile") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := local_request_Blobber_WriteFile_2(rctx, inboundMarshaler, server, req, pathParams) + resp, md, err := local_request_Blobber_UploadFile_2(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { @@ -1513,7 +1513,7 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se return } - forward_Blobber_WriteFile_2(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_UploadFile_2(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) @@ -1876,63 +1876,63 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) - mux.Handle("POST", pattern_Blobber_WriteFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_UploadFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/UploadFile") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_WriteFile_0(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_UploadFile_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_WriteFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_UploadFile_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("PUT", pattern_Blobber_WriteFile_1, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("PUT", pattern_Blobber_UploadFile_1, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/UploadFile") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_WriteFile_1(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_UploadFile_1(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_WriteFile_1(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_UploadFile_1(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) - mux.Handle("DELETE", pattern_Blobber_WriteFile_2, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("DELETE", pattern_Blobber_UploadFile_2, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/WriteFile") + rctx, err := runtime.AnnotateContext(ctx, mux, req, "/blobber.service.v1.Blobber/UploadFile") if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_Blobber_WriteFile_2(rctx, inboundMarshaler, client, req, pathParams) + resp, md, err := request_Blobber_UploadFile_2(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - forward_Blobber_WriteFile_2(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + forward_Blobber_UploadFile_2(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) @@ -2078,11 +2078,11 @@ var ( pattern_Blobber_RenameObject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "rename", "allocation"}, "")) - pattern_Blobber_WriteFile_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "upload", "allocation"}, "")) + pattern_Blobber_UploadFile_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "upload", "allocation"}, "")) - pattern_Blobber_WriteFile_1 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "upload", "allocation"}, "")) + pattern_Blobber_UploadFile_1 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "upload", "allocation"}, "")) - pattern_Blobber_WriteFile_2 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "upload", "allocation"}, "")) + pattern_Blobber_UploadFile_2 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "file", "upload", "allocation"}, "")) pattern_Blobber_Commit_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"v2", "connection", "commit", "allocation"}, "")) @@ -2116,11 +2116,11 @@ var ( forward_Blobber_RenameObject_0 = runtime.ForwardResponseMessage - forward_Blobber_WriteFile_0 = runtime.ForwardResponseMessage + forward_Blobber_UploadFile_0 = runtime.ForwardResponseMessage - forward_Blobber_WriteFile_1 = runtime.ForwardResponseMessage + forward_Blobber_UploadFile_1 = runtime.ForwardResponseMessage - forward_Blobber_WriteFile_2 = runtime.ForwardResponseMessage + forward_Blobber_UploadFile_2 = runtime.ForwardResponseMessage forward_Blobber_Commit_0 = runtime.ForwardResponseMessage diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go index 7c57b2da8..692be278d 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber_grpc.pb.go @@ -26,7 +26,7 @@ type BlobberClient interface { GetObjectTree(ctx context.Context, in *GetObjectTreeRequest, opts ...grpc.CallOption) (*GetObjectTreeResponse, error) DownloadFile(ctx context.Context, in *DownloadFileRequest, opts ...grpc.CallOption) (*DownloadFileResponse, error) RenameObject(ctx context.Context, in *RenameObjectRequest, opts ...grpc.CallOption) (*RenameObjectResponse, error) - WriteFile(ctx context.Context, in *UploadFileRequest, opts ...grpc.CallOption) (*UploadFileResponse, error) + UploadFile(ctx context.Context, in *UploadFileRequest, opts ...grpc.CallOption) (*UploadFileResponse, error) Commit(ctx context.Context, in *CommitRequest, opts ...grpc.CallOption) (*CommitResponse, error) CalculateHash(ctx context.Context, in *CalculateHashRequest, opts ...grpc.CallOption) (*CalculateHashResponse, error) CommitMetaTxn(ctx context.Context, in *CommitMetaTxnRequest, opts ...grpc.CallOption) (*CommitMetaTxnResponse, error) @@ -124,9 +124,9 @@ func (c *blobberClient) RenameObject(ctx context.Context, in *RenameObjectReques return out, nil } -func (c *blobberClient) WriteFile(ctx context.Context, in *UploadFileRequest, opts ...grpc.CallOption) (*UploadFileResponse, error) { +func (c *blobberClient) UploadFile(ctx context.Context, in *UploadFileRequest, opts ...grpc.CallOption) (*UploadFileResponse, error) { out := new(UploadFileResponse) - err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/WriteFile", in, out, opts...) + err := c.cc.Invoke(ctx, "/blobber.service.v1.Blobber/UploadFile", in, out, opts...) if err != nil { return nil, err } @@ -200,7 +200,7 @@ type BlobberServer interface { GetObjectTree(context.Context, *GetObjectTreeRequest) (*GetObjectTreeResponse, error) DownloadFile(context.Context, *DownloadFileRequest) (*DownloadFileResponse, error) RenameObject(context.Context, *RenameObjectRequest) (*RenameObjectResponse, error) - WriteFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) + UploadFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) Commit(context.Context, *CommitRequest) (*CommitResponse, error) CalculateHash(context.Context, *CalculateHashRequest) (*CalculateHashResponse, error) CommitMetaTxn(context.Context, *CommitMetaTxnRequest) (*CommitMetaTxnResponse, error) @@ -241,8 +241,8 @@ func (UnimplementedBlobberServer) DownloadFile(context.Context, *DownloadFileReq func (UnimplementedBlobberServer) RenameObject(context.Context, *RenameObjectRequest) (*RenameObjectResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method RenameObject not implemented") } -func (UnimplementedBlobberServer) WriteFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method WriteFile not implemented") +func (UnimplementedBlobberServer) UploadFile(context.Context, *UploadFileRequest) (*UploadFileResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UploadFile not implemented") } func (UnimplementedBlobberServer) Commit(context.Context, *CommitRequest) (*CommitResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Commit not implemented") @@ -437,20 +437,20 @@ func _Blobber_RenameObject_Handler(srv interface{}, ctx context.Context, dec fun return interceptor(ctx, in, info, handler) } -func _Blobber_WriteFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { +func _Blobber_UploadFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(UploadFileRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { - return srv.(BlobberServer).WriteFile(ctx, in) + return srv.(BlobberServer).UploadFile(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/blobber.service.v1.Blobber/WriteFile", + FullMethod: "/blobber.service.v1.Blobber/UploadFile", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(BlobberServer).WriteFile(ctx, req.(*UploadFileRequest)) + return srv.(BlobberServer).UploadFile(ctx, req.(*UploadFileRequest)) } return interceptor(ctx, in, info, handler) } @@ -604,8 +604,8 @@ var _Blobber_serviceDesc = grpc.ServiceDesc{ Handler: _Blobber_RenameObject_Handler, }, { - MethodName: "WriteFile", - Handler: _Blobber_WriteFile_Handler, + MethodName: "UploadFile", + Handler: _Blobber_UploadFile_Handler, }, { MethodName: "Commit", diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 1b00f07c8..81bd2d8b1 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -54,7 +54,7 @@ service Blobber { body: "*" }; } - rpc WriteFile(UploadFileRequest) returns (UploadFileResponse) { + rpc UploadFile(UploadFileRequest) returns (UploadFileResponse) { option (google.api.http) = { post: "/v2/file/upload/{allocation}" body: "*" diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 493be6112..767f2db50 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -995,7 +995,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { for _, tc := range testCases { ctx := context.Background() ctx = metadata.NewOutgoingContext(ctx, tc.context) - response, err := blobberClient.WriteFile(ctx, tc.input) + response, err := blobberClient.UploadFile(ctx, tc.input) if err != nil { if !tc.expectingError { t.Fatal(err) diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go index 4811b0bcc..ad697f1ce 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_grpc_handler.go @@ -97,7 +97,7 @@ func (b *blobberGRPCService) DownloadFile(ctx context.Context, req *blobbergrpc. return convert.DownloadFileResponseCreator(resp), nil } -func (b *blobberGRPCService) WriteFile(ctx context.Context, req *blobbergrpc.UploadFileRequest) (*blobbergrpc.UploadFileResponse, error) { +func (b *blobberGRPCService) UploadFile(ctx context.Context, req *blobbergrpc.UploadFileRequest) (*blobbergrpc.UploadFileResponse, error) { r, err := convert.WriteFileGRPCToHTTP(req) if err != nil { diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 9e7b070ad..196aed58e 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -610,7 +610,7 @@ }, "/v2/file/upload/{allocation}": { "delete": { - "operationId": "Blobber_WriteFile3", + "operationId": "Blobber_UploadFile3", "responses": { "200": { "description": "A successful response.", @@ -646,7 +646,7 @@ ] }, "post": { - "operationId": "Blobber_WriteFile", + "operationId": "Blobber_UploadFile", "responses": { "200": { "description": "A successful response.", @@ -682,7 +682,7 @@ ] }, "put": { - "operationId": "Blobber_WriteFile2", + "operationId": "Blobber_UploadFile2", "responses": { "200": { "description": "A successful response.", From 05433ac79a3794fd8b6ddb7e66f44ef91e7d4ef8 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 30 Jun 2021 19:28:27 +0530 Subject: [PATCH 157/183] :zap: added support for gzip compression --- code/go/0chain.net/blobbercore/handler/grpcMiddleware.go | 1 + 1 file changed, 1 insertion(+) diff --git a/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go b/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go index 497160099..5f0ab286a 100644 --- a/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go +++ b/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go @@ -12,6 +12,7 @@ import ( grpc_recovery "github.com/grpc-ecosystem/go-grpc-middleware/recovery" "go.uber.org/zap" "google.golang.org/grpc" + _ "google.golang.org/grpc/encoding/gzip" ) const ( From 62dd5f47cb5364d3d653f8923db74392b145ee8b Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 30 Jun 2021 19:42:36 +0530 Subject: [PATCH 158/183] :bug: grpc port is now optional --- code/go/0chain.net/blobber/main.go | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/code/go/0chain.net/blobber/main.go b/code/go/0chain.net/blobber/main.go index b2eb6309d..9eb924520 100644 --- a/code/go/0chain.net/blobber/main.go +++ b/code/go/0chain.net/blobber/main.go @@ -258,10 +258,6 @@ func main() { panic("Please specify --port which is the port on which requests are accepted") } - if *grpcPortString == "" { - panic("Please specify --grpc_port which is the grpc port on which requests are accepted") - } - reader, err := os.Open(*keysFile) if err != nil { panic(err) @@ -381,14 +377,25 @@ func main() { Logger.Info("Ready to listen to the requests") startTime = time.Now().UTC() - go func(grpcPort string) { + go func(gp *string) { + var grpcPort string + if gp != nil { + grpcPort = *gp + } + + if grpcPort == "" { + Logger.Error("Could not start grpc server since grpc port has not been specified." + + " Please specify the grpc port in the --grpc_port build arguement to start the grpc server") + return + } + Logger.Info("listening too grpc requests on port - " + grpcPort) lis, err := net.Listen("tcp", fmt.Sprintf(":%s", grpcPort)) if err != nil { log.Fatalf("failed to listen: %v", err) } log.Fatal(grpcServer.Serve(lis)) - }(*grpcPortString) + }(grpcPortString) log.Fatal(server.ListenAndServe()) } From 2c81950f3e893e61fe35e3c9e9839829caf12955 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 30 Jun 2021 19:50:51 +0530 Subject: [PATCH 159/183] make file mkdir removed and added to test file --- Makefile | 2 - .../handler/grpc_handler_integration_test.go | 56 +++++++++++-------- 2 files changed, 34 insertions(+), 24 deletions(-) diff --git a/Makefile b/Makefile index 1110730da..642ae15ed 100644 --- a/Makefile +++ b/Makefile @@ -7,6 +7,4 @@ lint: golangci-lint run --timeout 2m0s; integration-tests: - mkdir -p docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen go test ./... -args integration; - rm -r docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon \ No newline at end of file diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 61b9ed42e..fae61a532 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -6,8 +6,8 @@ import ( "encoding/json" "fmt" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "io" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "io" "log" "math/rand" "net/http" @@ -1161,37 +1161,49 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { root, _ := os.Getwd() path := strings.Split(root, `code`) + err := os.MkdirAll(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`, os.ModePerm) + f, err := os.Create(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen/MyFile`) if err != nil { t.Fatal(err) } + defer f.Close() + defer func() { + err := os.RemoveAll(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon`) + if err != nil { + t.Fatal(err) + } + }() file, err := os.Open(root + "/grpc_handler_integration_test.go") if err != nil { t.Fatal(err) } - stat, err := file.Stat() - if err != nil { - t.Fatal(err) - } - fileB := make([]byte, stat.Size()) - if _, err := io.ReadFull(file, fileB); err != nil { - t.Fatal(err) - } - _, err = f.Write(fileB) - if err != nil { - t.Fatal(err) - } - _, err = f.Write(fileB) - if err != nil { - t.Fatal(err) - } - _, err = f.Write(fileB) + defer file.Close() + + _, err = io.Copy(f, file) if err != nil { t.Fatal(err) } - fmt.Println(`file size`, stat.Size()) - file.Close() - f.Close() + //stat, err := file.Stat() + //if err != nil { + // t.Fatal(err) + //} + //fileB := make([]byte, stat.Size()) + //if _, err := io.ReadFull(file, fileB); err != nil { + // t.Fatal(err) + //} + //_, err = f.Write(fileB) + //if err != nil { + // t.Fatal(err) + //} + //_, err = f.Write(fileB) + //if err != nil { + // t.Fatal(err) + //} + //_, err = f.Write(fileB) + //if err != nil { + // t.Fatal(err) + //} pubKey, _, signScheme := GeneratePubPrivateKey(t) clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) @@ -1251,7 +1263,7 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { Path: "/some_file", PathHash: "exampleId:examplePath", ReadMarker: string(rmString), - BlockNum: "2", + BlockNum: "1", }, expectedMessage: "some_new_file", expectingError: false, From 5ec54818f8737195c128c24238db25fc8d130cc8 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 30 Jun 2021 19:59:27 +0530 Subject: [PATCH 160/183] lint fixed --- .../handler/grpc_handler_integration_test.go | 25 +++---------------- 1 file changed, 4 insertions(+), 21 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index fae61a532..f7e999c3b 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -1161,7 +1161,10 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { root, _ := os.Getwd() path := strings.Split(root, `code`) - err := os.MkdirAll(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`, os.ModePerm) + err = os.MkdirAll(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`, os.ModePerm) + if err != nil { + t.Fatal(err) + } f, err := os.Create(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen/MyFile`) if err != nil { @@ -1184,26 +1187,6 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { if err != nil { t.Fatal(err) } - //stat, err := file.Stat() - //if err != nil { - // t.Fatal(err) - //} - //fileB := make([]byte, stat.Size()) - //if _, err := io.ReadFull(file, fileB); err != nil { - // t.Fatal(err) - //} - //_, err = f.Write(fileB) - //if err != nil { - // t.Fatal(err) - //} - //_, err = f.Write(fileB) - //if err != nil { - // t.Fatal(err) - //} - //_, err = f.Write(fileB) - //if err != nil { - // t.Fatal(err) - //} pubKey, _, signScheme := GeneratePubPrivateKey(t) clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) From 7381c2df1ded63016545619845bae8f26d85355e Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 30 Jun 2021 20:12:39 +0530 Subject: [PATCH 161/183] permission changes added --- .../handler/grpc_handler_integration_test.go | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index f7e999c3b..c8a9ffbb3 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -1161,22 +1161,28 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { root, _ := os.Getwd() path := strings.Split(root, `code`) - err = os.MkdirAll(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`, os.ModePerm) + err = os.Chmod(path[0]+`docker.local/blobber1/files/files`, 0777) if err != nil { t.Fatal(err) } - f, err := os.Create(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen/MyFile`) + err = os.MkdirAll(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`, os.ModePerm) if err != nil { t.Fatal(err) } - defer f.Close() defer func() { err := os.RemoveAll(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon`) if err != nil { t.Fatal(err) } }() + + f, err := os.Create(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen/MyFile`) + if err != nil { + t.Fatal(err) + } + defer f.Close() + file, err := os.Open(root + "/grpc_handler_integration_test.go") if err != nil { t.Fatal(err) From 5ddf11c4693ae5b3825ff3be04868d85039859d4 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 30 Jun 2021 20:21:05 +0530 Subject: [PATCH 162/183] :bug: added correct http methods to some of the grpc methods for grpc gateway --- .../0chain.net/blobbercore/blobbergrpc/proto/blobber.proto | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 81bd2d8b1..95c6b8252 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -14,12 +14,14 @@ service Blobber { } rpc GetFileMetaData(GetFileMetaDataRequest) returns (GetFileMetaDataResponse) { option (google.api.http) = { - get: "/v2/file/meta/{allocation}" + post: "/v2/file/meta/{allocation}" + body: "*" }; } rpc GetFileStats(GetFileStatsRequest) returns (GetFileStatsResponse) { option (google.api.http) = { - get: "/v2/file/stats/{allocation}" + post: "/v2/file/stats/{allocation}" + body: "*" }; } rpc ListEntities(ListEntitiesRequest) returns (ListEntitiesResponse) { From 4f4d560574bd6310eb79bcc0d8abd3d7f16e92da Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 30 Jun 2021 20:34:43 +0530 Subject: [PATCH 163/183] add permission to test workflow --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a60c0d996..e0e1be791 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -36,7 +36,7 @@ jobs: cd docker.local/blobber1 ../bin/blobber.start_bls.sh /dev/null & cd ../.. - make integration-tests + sudo make integration-tests lint: runs-on: ubuntu-20.04 steps: From edf127a54edb3255c362fe3a96312e0d8beed289 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 30 Jun 2021 20:38:13 +0530 Subject: [PATCH 164/183] :bug: added tools package to track tool dependency and updated grpc related tools, also regenerated grpc files to resolve build issues --- .../blobbercore/blobbergrpc/blobber.pb.go | 262 +++++++++--------- .../blobbercore/blobbergrpc/blobber.pb.gw.go | 76 +++-- .../blobbercore/openapi/blobber.swagger.json | 73 +++-- code/go/0chain.net/tools/tool.go | 10 + go.mod | 4 +- go.sum | 3 +- 6 files changed, 226 insertions(+), 202 deletions(-) create mode 100644 code/go/0chain.net/tools/tool.go diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 3ae0e2816..5418fa01f 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -3985,7 +3985,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xc6, 0x12, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xcc, 0x12, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, @@ -3994,150 +3994,150 @@ var file_blobber_proto_rawDesc = []byte{ 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x8e, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, + 0x6e, 0x12, 0x91, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, - 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x12, 0x1b, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x85, 0x01, 0x0a, 0x0c, - 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, - 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x89, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, + 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, + 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x26, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x20, 0x22, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, + 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, + 0x2a, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, + 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, + 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, + 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, + 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, - 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, + 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, + 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, + 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, + 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, + 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, - 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, - 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, - 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x12, 0x8c, 0x01, 0x0a, 0x0c, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, - 0x69, 0x6c, 0x65, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, - 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x64, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, + 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, + 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8c, 0x01, 0x0a, 0x0c, 0x44, 0x6f, 0x77, + 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, + 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x29, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x64, + 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x8a, 0x01, 0x0a, 0x0c, 0x52, 0x65, 0x6e, 0x61, + 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, + 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, + 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xca, 0x01, 0x0a, 0x0a, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, + 0x69, 0x6c, 0x65, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, + 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x6d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x67, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, 0x1a, 0x1c, 0x2f, + 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, + 0x2a, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, - 0x2a, 0x12, 0x8a, 0x01, 0x0a, 0x0c, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, + 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xca, - 0x01, 0x0a, 0x0a, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x25, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x6d, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x67, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, - 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, 0x1a, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, 0x2a, 0x1c, 0x2f, 0x76, 0x32, 0x2f, - 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, - 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, - 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, + 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, + 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, + 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, + 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, + 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, - 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, - 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, - 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, - 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, - 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, + 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, + 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, - 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, - 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, - 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, - 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, - 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, - 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, - 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, - 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, - 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, - 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, - 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, - 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, - 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, - 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, + 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, + 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, + 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, + 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, + 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, + 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, + 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, + 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, + 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go index 597e47a28..95062556c 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.gw.go @@ -67,14 +67,18 @@ func local_request_Blobber_GetAllocation_0(ctx context.Context, marshaler runtim } -var ( - filter_Blobber_GetFileMetaData_0 = &utilities.DoubleArray{Encoding: map[string]int{"allocation": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}} -) - func request_Blobber_GetFileMetaData_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq GetFileMetaDataRequest var metadata runtime.ServerMetadata + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + var ( val string ok bool @@ -92,13 +96,6 @@ func request_Blobber_GetFileMetaData_0(ctx context.Context, marshaler runtime.Ma return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - if err := req.ParseForm(); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Blobber_GetFileMetaData_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - msg, err := client.GetFileMetaData(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err @@ -108,6 +105,14 @@ func local_request_Blobber_GetFileMetaData_0(ctx context.Context, marshaler runt var protoReq GetFileMetaDataRequest var metadata runtime.ServerMetadata + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + var ( val string ok bool @@ -125,26 +130,23 @@ func local_request_Blobber_GetFileMetaData_0(ctx context.Context, marshaler runt return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - if err := req.ParseForm(); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Blobber_GetFileMetaData_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - msg, err := server.GetFileMetaData(ctx, &protoReq) return msg, metadata, err } -var ( - filter_Blobber_GetFileStats_0 = &utilities.DoubleArray{Encoding: map[string]int{"allocation": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}} -) - func request_Blobber_GetFileStats_0(ctx context.Context, marshaler runtime.Marshaler, client BlobberClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq GetFileStatsRequest var metadata runtime.ServerMetadata + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + var ( val string ok bool @@ -162,13 +164,6 @@ func request_Blobber_GetFileStats_0(ctx context.Context, marshaler runtime.Marsh return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - if err := req.ParseForm(); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Blobber_GetFileStats_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - msg, err := client.GetFileStats(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err @@ -178,6 +173,14 @@ func local_request_Blobber_GetFileStats_0(ctx context.Context, marshaler runtime var protoReq GetFileStatsRequest var metadata runtime.ServerMetadata + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + var ( val string ok bool @@ -195,13 +198,6 @@ func local_request_Blobber_GetFileStats_0(ctx context.Context, marshaler runtime return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "allocation", err) } - if err := req.ParseForm(); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Blobber_GetFileStats_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - msg, err := server.GetFileStats(ctx, &protoReq) return msg, metadata, err @@ -1264,7 +1260,7 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) - mux.Handle("GET", pattern_Blobber_GetFileMetaData_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_GetFileMetaData_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream @@ -1287,7 +1283,7 @@ func RegisterBlobberHandlerServer(ctx context.Context, mux *runtime.ServeMux, se }) - mux.Handle("GET", pattern_Blobber_GetFileStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_GetFileStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream @@ -1716,7 +1712,7 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) - mux.Handle("GET", pattern_Blobber_GetFileMetaData_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_GetFileMetaData_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) @@ -1736,7 +1732,7 @@ func RegisterBlobberHandlerClient(ctx context.Context, mux *runtime.ServeMux, cl }) - mux.Handle("GET", pattern_Blobber_GetFileStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_Blobber_GetFileStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 196aed58e..b45fca12c 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -361,7 +361,7 @@ } }, "/v2/file/meta/{allocation}": { - "get": { + "post": { "operationId": "Blobber_GetFileMetaData", "responses": { "200": { @@ -385,22 +385,12 @@ "type": "string" }, { - "name": "path", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "pathHash", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "authToken", - "in": "query", - "required": false, - "type": "string" + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1GetFileMetaDataRequest" + } } ], "tags": [ @@ -567,7 +557,7 @@ } }, "/v2/file/stats/{allocation}": { - "get": { + "post": { "operationId": "Blobber_GetFileStats", "responses": { "200": { @@ -591,16 +581,12 @@ "type": "string" }, { - "name": "path", - "in": "query", - "required": false, - "type": "string" - }, - { - "name": "pathHash", - "in": "query", - "required": false, - "type": "string" + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1GetFileStatsRequest" + } } ], "tags": [ @@ -1255,6 +1241,23 @@ } } }, + "v1GetFileMetaDataRequest": { + "type": "object", + "properties": { + "path": { + "type": "string" + }, + "pathHash": { + "type": "string" + }, + "authToken": { + "type": "string" + }, + "allocation": { + "type": "string" + } + } + }, "v1GetFileMetaDataResponse": { "type": "object", "properties": { @@ -1269,6 +1272,20 @@ } } }, + "v1GetFileStatsRequest": { + "type": "object", + "properties": { + "path": { + "type": "string" + }, + "pathHash": { + "type": "string" + }, + "allocation": { + "type": "string" + } + } + }, "v1GetFileStatsResponse": { "type": "object", "properties": { diff --git a/code/go/0chain.net/tools/tool.go b/code/go/0chain.net/tools/tool.go new file mode 100644 index 000000000..5d7fa0ee8 --- /dev/null +++ b/code/go/0chain.net/tools/tool.go @@ -0,0 +1,10 @@ +// +build tools + +package tools + +import ( + _ "github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-grpc-gateway" + _ "github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2" + _ "google.golang.org/grpc/cmd/protoc-gen-go-grpc" + _ "google.golang.org/protobuf/cmd/protoc-gen-go" +) diff --git a/go.mod b/go.mod index d19467b5c..9101490b8 100644 --- a/go.mod +++ b/go.mod @@ -9,10 +9,9 @@ require ( github.com/gorilla/mux v1.7.3 github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 github.com/grpc-ecosystem/grpc-gateway/v2 v2.3.0 - github.com/herumi/bls-go-binary v0.0.0-20191119080710-898950e1a520 // indirect + github.com/herumi/bls-go-binary v0.0.0-20191119080710-898950e1a520 github.com/jackc/pgproto3/v2 v2.0.4 // indirect github.com/koding/cache v0.0.0-20161222233015-e8a81b0b3f20 - github.com/magiconair/properties v1.8.1 github.com/minio/minio-go v6.0.14+incompatible github.com/mitchellh/mapstructure v1.3.1 github.com/patrickmn/go-cache v2.1.0+incompatible // indirect @@ -24,6 +23,7 @@ require ( golang.org/x/crypto v0.0.0-20200820211705-5c72a883971a google.golang.org/genproto v0.0.0-20210224155714-063164c882e6 google.golang.org/grpc v1.36.0 + google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.0.0 google.golang.org/protobuf v1.26.0 gopkg.in/ini.v1 v1.61.0 // indirect gopkg.in/mgo.v2 v2.0.0-20180705113604-9856a29383ce // indirect diff --git a/go.sum b/go.sum index dec840020..633f9a35e 100644 --- a/go.sum +++ b/go.sum @@ -94,6 +94,7 @@ github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5Kwzbycv github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/gedex/inflector v0.0.0-20170307190818-16278e9db813/go.mod h1:P+oSoE9yhSRvsmYyZsshflcR6ePWYLql6UU1amW13IM= +github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= @@ -405,7 +406,6 @@ github.com/spf13/viper v1.7.0 h1:xVKxvI7ouOI5I+U9s2eeiUfMaWBVoXA3AWskkrqK0VM= github.com/spf13/viper v1.7.0/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/objx v0.2.0 h1:Hbg2NidpLE8veEBkEZTL3CvlkUIVzuU9jDplZO54c48= github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= @@ -742,6 +742,7 @@ google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv google.golang.org/grpc v1.35.0-dev.0.20201218190559-666aea1fb34c/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.0 h1:o1bcQ6imQMIOpdrO3SWf2z5RV72WbDwdXuK0MDlc8As= google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= +google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.0.0 h1:lQ+dE99pFsb8osbJB3oRfE5eW4Hx6a/lZQr8Jh+eoT4= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.0.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= From 33903b07da40bc459e9513d25a5b2def596d69d0 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 30 Jun 2021 20:51:23 +0530 Subject: [PATCH 165/183] remove permission to test workflow --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e0e1be791..a60c0d996 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -36,7 +36,7 @@ jobs: cd docker.local/blobber1 ../bin/blobber.start_bls.sh /dev/null & cd ../.. - sudo make integration-tests + make integration-tests lint: runs-on: ubuntu-20.04 steps: From 8e2f479f26e0d3e61e80bed5d141dca2a209ec26 Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 30 Jun 2021 20:57:24 +0530 Subject: [PATCH 166/183] add permission to test workflow makefile --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 642ae15ed..ba3dd4b74 100644 --- a/Makefile +++ b/Makefile @@ -7,4 +7,4 @@ lint: golangci-lint run --timeout 2m0s; integration-tests: - go test ./... -args integration; + sudo go test ./... -args integration; From 718247d4bce14781e3f5f4e0c1770cf4dd203e1a Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 30 Jun 2021 22:12:51 +0530 Subject: [PATCH 167/183] add permission to test --- Makefile | 2 +- .../blobbercore/handler/grpc_handler_integration_test.go | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index ba3dd4b74..642ae15ed 100644 --- a/Makefile +++ b/Makefile @@ -7,4 +7,4 @@ lint: golangci-lint run --timeout 2m0s; integration-tests: - sudo go test ./... -args integration; + go test ./... -args integration; diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index c8a9ffbb3..afcdf8934 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -1161,6 +1161,11 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { root, _ := os.Getwd() path := strings.Split(root, `code`) + err = os.Chown(path[0]+`docker.local/blobber1/files/files`, os.Getuid(), os.Getgid()) + if err != nil { + t.Fatal(err) + } + err = os.Chmod(path[0]+`docker.local/blobber1/files/files`, 0777) if err != nil { t.Fatal(err) From ac85f3e6b0ab580418d542ef57ad5607b411e26c Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 30 Jun 2021 22:37:58 +0530 Subject: [PATCH 168/183] add sudo permission to test in makefile --- Makefile | 2 +- .../blobbercore/handler/grpc_handler_integration_test.go | 5 ----- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 642ae15ed..ba3dd4b74 100644 --- a/Makefile +++ b/Makefile @@ -7,4 +7,4 @@ lint: golangci-lint run --timeout 2m0s; integration-tests: - go test ./... -args integration; + sudo go test ./... -args integration; diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index afcdf8934..c8a9ffbb3 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -1161,11 +1161,6 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { root, _ := os.Getwd() path := strings.Split(root, `code`) - err = os.Chown(path[0]+`docker.local/blobber1/files/files`, os.Getuid(), os.Getgid()) - if err != nil { - t.Fatal(err) - } - err = os.Chmod(path[0]+`docker.local/blobber1/files/files`, 0777) if err != nil { t.Fatal(err) From fa1999e0b6e18e598ea169279e7ab28e940c5dbf Mon Sep 17 00:00:00 2001 From: nipunapathirana Date: Wed, 30 Jun 2021 22:48:44 +0530 Subject: [PATCH 169/183] remove chmod in test file --- .../blobbercore/handler/grpc_handler_integration_test.go | 5 ----- 1 file changed, 5 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index c8a9ffbb3..401f2717b 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -1161,11 +1161,6 @@ func TestBlobberGRPCService_IntegrationTest(t *testing.T) { root, _ := os.Getwd() path := strings.Split(root, `code`) - err = os.Chmod(path[0]+`docker.local/blobber1/files/files`, 0777) - if err != nil { - t.Fatal(err) - } - err = os.MkdirAll(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`, os.ModePerm) if err != nil { t.Fatal(err) From 4f7c2be5e67c7b0161d80455074e8e6e9c11fac0 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Fri, 2 Jul 2021 18:38:52 +0530 Subject: [PATCH 170/183] updated grpc files --- .../blobbercore/blobbergrpc/blobber.pb.go | 56 ++++++++++--------- .../blobbercore/openapi/blobber.swagger.json | 3 - 2 files changed, 29 insertions(+), 30 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 4a3ebea20..5d294e6b1 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -3870,7 +3870,7 @@ var file_blobber_proto_rawDesc = []byte{ 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, - 0x22, 0xb6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, + 0x22, 0xd6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, @@ -3880,32 +3880,34 @@ var file_blobber_proto_rawDesc = []byte{ 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, - 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x45, - 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x08, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, - 0x7a, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, - 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, - 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, - 0x64, 0x57, 0x4d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, - 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, - 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, - 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, - 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, - 0x6e, 0x69, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, - 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, - 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, - 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x0f, - 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, - 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x12, - 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x07, 0x50, 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, + 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x52, + 0x65, 0x70, 0x61, 0x69, 0x72, 0x65, 0x72, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x52, 0x65, 0x70, 0x61, 0x69, 0x72, 0x65, 0x72, 0x49, 0x44, 0x12, 0x18, 0x0a, 0x07, 0x50, + 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, + 0x79, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, + 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0b, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, + 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, + 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0d, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, + 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0f, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, + 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x10, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, + 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x11, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, + 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, + 0x6d, 0x73, 0x18, 0x12, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, + 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index 51e11e632..e144b150c 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -801,9 +801,6 @@ "items": { "$ref": "#/definitions/v1Term" } - }, - "PayerID": { - "type": "string" } } }, From a410534556b46273e33a7026bbab46dba2c359b2 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Fri, 2 Jul 2021 18:58:32 +0530 Subject: [PATCH 171/183] :bug: fixed broken tests --- .../handler/grpc_handler_helper_unit_test.go | 52 +++++++++---------- .../handler/grpc_handler_integration_test.go | 5 +- 2 files changed, 29 insertions(+), 28 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go index af5063f49..4fd9d7936 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go @@ -124,8 +124,8 @@ func (c *TestDataController) AddGetAllocationTestData() error { expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, repairer_id, is_immutable) +VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId', 'repairer_id', false); `) if err != nil { return err @@ -166,8 +166,8 @@ func (c *TestDataController) AddGetFileMetaDataTestData() error { expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, repairer_id, is_immutable) +VALUES ('exampleId' ,'exampleTransaction','exampleOwnerId','exampleOwnerPublicKey',` + fmt.Sprint(expTime) + `,'examplePayerId', 'repairer_id', false); `) if err != nil { return err @@ -232,8 +232,8 @@ func (c *TestDataController) AddGetFileStatsTestData(allocationTx, pubKey string expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubKey + `',` + fmt.Sprint(expTime) + `,'examplePayerId'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, repairer_id, is_immutable) +VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubKey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 'repairer_id', false); `) if err != nil { return err @@ -282,8 +282,8 @@ func (c *TestDataController) AddListEntitiesTestData(allocationTx, pubkey string expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, repairer_id, is_immutable) +VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 'repairer_id', false); `) if err != nil { return err @@ -332,8 +332,8 @@ func (c *TestDataController) AddGetObjectPathTestData(allocationTx, pubKey strin expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubKey + `',` + fmt.Sprint(expTime) + `,'examplePayerId'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, repairer_id, is_immutable) +VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubKey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 'repairer_id', false); `) if err != nil { return err @@ -374,8 +374,8 @@ func (c *TestDataController) AddGetReferencePathTestData(allocationTx, pubkey st expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, repairer_id, is_immutable) +VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 'repairer_id', false); `) if err != nil { return err @@ -416,8 +416,8 @@ func (c *TestDataController) AddGetObjectTreeTestData(allocationTx, pubkey strin expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id) -VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, repairer_id, is_immutable) +VALUES ('exampleId' ,'` + allocationTx + `','exampleOwnerId','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 'repairer_id', false); `) if err != nil { return err @@ -496,8 +496,8 @@ func (c *TestDataController) AddCommitTestData(allocationTx, pubkey, clientId, w expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) -VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root, repairer_id, is_immutable) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/', 'repairer_id', false); `) if err != nil { return err @@ -572,8 +572,8 @@ func (c *TestDataController) AddAttributesTestData(allocationTx, pubkey, clientI expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) -VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root, repairer_id, is_immutable) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/', 'repairer_id', false); `) if err != nil { return err @@ -632,8 +632,8 @@ func (c *TestDataController) AddCopyObjectData(allocationTx, pubkey, clientId st expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) -VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root, repairer_id, is_immutable) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/', 'repairer_id', false); `) if err != nil { return err @@ -692,8 +692,8 @@ func (c *TestDataController) AddRenameTestData(allocationTx, pubkey, clientId st expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) -VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root, repairer_id, is_immutable) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/', 'repairer_id', false); `) if err != nil { return err @@ -752,8 +752,8 @@ func (c *TestDataController) AddDownloadTestData(allocationTx, pubkey, clientId, expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) -VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root, repairer_id, is_immutable) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/', 'repairer_id', false); `) if err != nil { return err @@ -820,8 +820,8 @@ func (c *TestDataController) AddUploadTestData(allocationTx, pubkey, clientId st expTime := time.Now().Add(time.Hour * 100000).UnixNano() _, err = tx.Exec(` -INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root) -VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/'); +INSERT INTO allocations (id, tx, owner_id, owner_public_key, expiration_date, payer_id, blobber_size, allocation_root, repairer_id, is_immutable) +VALUES ('exampleId' ,'` + allocationTx + `','` + clientId + `','` + pubkey + `',` + fmt.Sprint(expTime) + `,'examplePayerId', 99999999, '/', 'repairer_id', false); `) if err != nil { return err diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 401f2717b..79e929f57 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -5,8 +5,6 @@ import ( "encoding/hex" "encoding/json" "fmt" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" "io" "log" "math/rand" @@ -17,6 +15,9 @@ import ( "testing" "time" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" From a4b937a52f28f4a5bd628eb234897524c03f2dd5 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 16:09:51 +0530 Subject: [PATCH 172/183] :art: fixed package naming convention --- .../{blobberHTTP => blobberhttp}/response.go | 2 +- .../blobbercore/convert/responseHandler.go | 48 +++++++++---------- .../handler/object_operation_handler.go | 27 +++++------ .../blobbercore/handler/storage_handler.go | 27 +++++------ 4 files changed, 51 insertions(+), 53 deletions(-) rename code/go/0chain.net/blobbercore/{blobberHTTP => blobberhttp}/response.go (99%) diff --git a/code/go/0chain.net/blobbercore/blobberHTTP/response.go b/code/go/0chain.net/blobbercore/blobberhttp/response.go similarity index 99% rename from code/go/0chain.net/blobbercore/blobberHTTP/response.go rename to code/go/0chain.net/blobbercore/blobberhttp/response.go index d6c72baf9..e09b4430a 100644 --- a/code/go/0chain.net/blobbercore/blobberHTTP/response.go +++ b/code/go/0chain.net/blobbercore/blobberhttp/response.go @@ -1,4 +1,4 @@ -package blobberHTTP +package blobberhttp import ( "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 800bee170..aeba4f122 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -3,12 +3,12 @@ package convert import ( "context" "encoding/json" + "github.com/0chain/blobber/code/go/0chain.net/core/common" stats2 "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberHTTP" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" ) @@ -62,7 +62,7 @@ func ListEntitesResponseCreator(r interface{}) *blobbergrpc.ListEntitiesResponse return nil } - httpResp, _ := r.(*blobberHTTP.ListResult) + httpResp, _ := r.(*blobberhttp.ListResult) var resp blobbergrpc.ListEntitiesResponse for i := range httpResp.Entities { @@ -79,7 +79,7 @@ func GetReferencePathResponseCreator(r interface{}) *blobbergrpc.GetReferencePat return nil } - httpResp, _ := r.(*blobberHTTP.ReferencePathResult) + httpResp, _ := r.(*blobberhttp.ReferencePathResult) var resp blobbergrpc.GetReferencePathResponse var recursionCount int @@ -93,7 +93,7 @@ func GetObjectTreeResponseCreator(r interface{}) *blobbergrpc.GetObjectTreeRespo return nil } - httpResp, _ := r.(*blobberHTTP.ReferencePathResult) + httpResp, _ := r.(*blobberhttp.ReferencePathResult) var resp blobbergrpc.GetObjectTreeResponse var recursionCount int @@ -107,7 +107,7 @@ func GetObjectPathResponseCreator(r interface{}) *blobbergrpc.GetObjectPathRespo return nil } - httpResp, _ := r.(*blobberHTTP.ObjectPathResult) + httpResp, _ := r.(*blobberhttp.ObjectPathResult) var resp blobbergrpc.GetObjectPathResponse var pathList []*blobbergrpc.FileRef @@ -133,7 +133,7 @@ func CommitWriteResponseCreator(r interface{}) *blobbergrpc.CommitResponse { return nil } - httpResp, _ := r.(*blobberHTTP.CommitResult) + httpResp, _ := r.(*blobberhttp.CommitResult) return &blobbergrpc.CommitResponse{ AllocationRoot: httpResp.AllocationRoot, @@ -195,7 +195,7 @@ func CopyObjectResponseCreator(r interface{}) *blobbergrpc.CopyObjectResponse { return nil } - httpResp, _ := r.(*blobberHTTP.UploadResult) + httpResp, _ := r.(*blobberhttp.UploadResult) return &blobbergrpc.CopyObjectResponse{ Filename: httpResp.Filename, Size: httpResp.Size, @@ -236,29 +236,29 @@ func GetFileStatsResponseHandler(resp *blobbergrpc.GetFileStatsResponse) map[str return result } -func ListEntitesResponseHandler(resp *blobbergrpc.ListEntitiesResponse) *blobberHTTP.ListResult { +func ListEntitesResponseHandler(resp *blobbergrpc.ListEntitiesResponse) *blobberhttp.ListResult { ctx := context.Background() var entities []map[string]interface{} for i := range resp.Entities { entities = append(entities, FileRefGRPCToFileRef(resp.Entities[i]).GetListingData(ctx)) } - return &blobberHTTP.ListResult{ + return &blobberhttp.ListResult{ AllocationRoot: resp.AllocationRoot, Meta: FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx), Entities: entities, } } -func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetReferencePathResponse) *blobberHTTP.ReferencePathResult { +func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetReferencePathResponse) *blobberhttp.ReferencePathResult { var recursionCount int - return &blobberHTTP.ReferencePathResult{ + return &blobberhttp.ReferencePathResult{ ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getReferencePathResponse.ReferencePath), LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWM), } } -func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPathResponse) *blobberHTTP.ObjectPathResult { +func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPathResponse) *blobberhttp.ObjectPathResult { ctx := context.Background() path := FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Path).GetListingData(ctx) var pathList []map[string]interface{} @@ -267,7 +267,7 @@ func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPa } path["list"] = pathList - return &blobberHTTP.ObjectPathResult{ + return &blobberhttp.ObjectPathResult{ ObjectPath: &reference.ObjectPath{ RootHash: getObjectPathResponse.ObjectPath.RootHash, Meta: FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Meta).GetListingData(ctx), @@ -278,16 +278,16 @@ func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPa } } -func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTreeResponse) *blobberHTTP.ReferencePathResult { +func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTreeResponse) *blobberhttp.ReferencePathResult { var recursionCount int - return &blobberHTTP.ReferencePathResult{ + return &blobberhttp.ReferencePathResult{ ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getObjectTreeResponse.ReferencePath), LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), } } -func CommitWriteResponseHandler(resp *blobbergrpc.CommitResponse) *blobberHTTP.CommitResult { - return &blobberHTTP.CommitResult{ +func CommitWriteResponseHandler(resp *blobbergrpc.CommitResponse) *blobberhttp.CommitResult { + return &blobberhttp.CommitResult{ AllocationRoot: resp.AllocationRoot, WriteMarker: WriteMarkerGRPCToWriteMarker(resp.WriteMarker), Success: resp.Success, @@ -338,14 +338,14 @@ func CollaboratorResponse(response *blobbergrpc.CollaboratorResponse) interface{ return nil } -func UpdateObjectAttributesResponseHandler(updateAttributesResponse *blobbergrpc.UpdateObjectAttributesResponse) *blobberHTTP.UpdateObjectAttributesResponse { - return &blobberHTTP.UpdateObjectAttributesResponse{ +func UpdateObjectAttributesResponseHandler(updateAttributesResponse *blobbergrpc.UpdateObjectAttributesResponse) *blobberhttp.UpdateObjectAttributesResponse { + return &blobberhttp.UpdateObjectAttributesResponse{ WhoPaysForReads: common.WhoPays(updateAttributesResponse.WhoPaysForReads), } } -func CopyObjectResponseHandler(copyObjectResponse *blobbergrpc.CopyObjectResponse) *blobberHTTP.UploadResult { - return &blobberHTTP.UploadResult{ +func CopyObjectResponseHandler(copyObjectResponse *blobbergrpc.CopyObjectResponse) *blobberhttp.UploadResult { + return &blobberhttp.UploadResult{ Filename: copyObjectResponse.Filename, Size: copyObjectResponse.Size, Hash: copyObjectResponse.ContentHash, @@ -360,7 +360,7 @@ func RenameObjectResponseCreator(r interface{}) *blobbergrpc.RenameObjectRespons return nil } - httpResp, _ := r.(*blobberHTTP.UploadResult) + httpResp, _ := r.(*blobberhttp.UploadResult) return &blobbergrpc.RenameObjectResponse{ Filename: httpResp.Filename, Size: httpResp.Size, @@ -381,7 +381,7 @@ func DownloadFileResponseCreator(r interface{}) *blobbergrpc.DownloadFileRespons return &blobbergrpc.DownloadFileResponse{ Data: httpResp, } - case *blobberHTTP.DownloadResponse: + case *blobberhttp.DownloadResponse: return &blobbergrpc.DownloadFileResponse{ Success: httpResp.Success, Data: httpResp.Data, @@ -399,7 +399,7 @@ func UploadFileResponseCreator(r interface{}) *blobbergrpc.UploadFileResponse { return nil } - httpResp, _ := r.(*blobberHTTP.UploadResult) + httpResp, _ := r.(*blobberhttp.UploadResult) return &blobbergrpc.UploadFileResponse{ Filename: httpResp.Filename, Size: httpResp.Size, diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go index 15913b6a9..87dac1f3b 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go @@ -5,7 +5,6 @@ import ( "encoding/hex" "encoding/json" "errors" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberHTTP" "net/http" "path/filepath" @@ -282,9 +281,9 @@ func (fsh *StorageHandler) DownloadFile(ctx context.Context, r *http.Request) ( // authorize file access var ( - isOwner = clientID == alloc.OwnerID - isRepairer = clientID == alloc.RepairerID - isCollaborator = reference.IsACollaborator(ctx, fileref.ID, clientID) + isOwner = clientID == alloc.OwnerID + isRepairer = clientID == alloc.RepairerID + isCollaborator = reference.IsACollaborator(ctx, fileref.ID, clientID) ) if !isOwner && !isRepairer && !isCollaborator { @@ -340,7 +339,7 @@ func (fsh *StorageHandler) DownloadFile(ctx context.Context, r *http.Request) ( if latestRM != nil && latestRM.ReadCounter+(numBlocks) != readMarker.ReadCounter { - var response = &blobberHTTP.DownloadResponse{ + var response = &blobberhttp.DownloadResponse{ Success: false, LatestRM: latestRM, Path: fileref.Path, @@ -394,7 +393,7 @@ func (fsh *StorageHandler) DownloadFile(ctx context.Context, r *http.Request) ( "couldn't save latest read marker: %v", err) } - var response = &blobberHTTP.DownloadResponse{} + var response = &blobberhttp.DownloadResponse{} response.Success = true response.LatestRM = readMarker response.Data = respData @@ -405,7 +404,7 @@ func (fsh *StorageHandler) DownloadFile(ctx context.Context, r *http.Request) ( return respData, nil } -func (fsh *StorageHandler) CommitWrite(ctx context.Context, r *http.Request) (*blobberHTTP.CommitResult, error) { +func (fsh *StorageHandler) CommitWrite(ctx context.Context, r *http.Request) (*blobberhttp.CommitResult, error) { if r.Method == "GET" { return nil, common.NewError("invalid_method", "Invalid method used for the upload URL. Use POST instead") @@ -488,7 +487,7 @@ func (fsh *StorageHandler) CommitWrite(ctx context.Context, r *http.Request) (*b err) } - var result blobberHTTP.CommitResult + var result blobberhttp.CommitResult var latestWM *writemarker.WriteMarkerEntity if len(allocationObj.AllocationRoot) == 0 { latestWM = nil @@ -659,7 +658,7 @@ func (fsh *StorageHandler) RenameObject(ctx context.Context, r *http.Request) (i return nil, common.NewError("connection_write_error", "Error writing the connection meta data") } - result := &blobberHTTP.UploadResult{} + result := &blobberhttp.UploadResult{} result.Filename = new_name result.Hash = objectRef.Hash result.MerkleRoot = objectRef.MerkleRoot @@ -866,7 +865,7 @@ func (fsh *StorageHandler) CopyObject(ctx context.Context, r *http.Request) (int return nil, common.NewError("connection_write_error", "Error writing the connection meta data") } - result := &blobberHTTP.UploadResult{} + result := &blobberhttp.UploadResult{} result.Filename = objectRef.Name result.Hash = objectRef.Hash result.MerkleRoot = objectRef.MerkleRoot @@ -875,7 +874,7 @@ func (fsh *StorageHandler) CopyObject(ctx context.Context, r *http.Request) (int return result, nil } -func (fsh *StorageHandler) DeleteFile(ctx context.Context, r *http.Request, connectionObj *allocation.AllocationChangeCollector) (*blobberHTTP.UploadResult, error) { +func (fsh *StorageHandler) DeleteFile(ctx context.Context, r *http.Request, connectionObj *allocation.AllocationChangeCollector) (*blobberhttp.UploadResult, error) { path := r.FormValue("path") if len(path) == 0 { return nil, common.NewError("invalid_parameters", "Invalid path") @@ -897,7 +896,7 @@ func (fsh *StorageHandler) DeleteFile(ctx context.Context, r *http.Request, conn connectionObj.Size += allocationChange.Size connectionObj.AddChange(allocationChange, dfc) - result := &blobberHTTP.UploadResult{} + result := &blobberhttp.UploadResult{} result.Filename = fileRef.Name result.Hash = fileRef.Hash result.MerkleRoot = fileRef.MerkleRoot @@ -910,7 +909,7 @@ func (fsh *StorageHandler) DeleteFile(ctx context.Context, r *http.Request, conn } //WriteFile stores the file into the blobber files system from the HTTP request -func (fsh *StorageHandler) WriteFile(ctx context.Context, r *http.Request) (*blobberHTTP.UploadResult, error) { +func (fsh *StorageHandler) WriteFile(ctx context.Context, r *http.Request) (*blobberhttp.UploadResult, error) { if r.Method == "GET" { return nil, common.NewError("invalid_method", "Invalid method used for the upload URL. Use multi-part form POST / PUT / DELETE instead") @@ -958,7 +957,7 @@ func (fsh *StorageHandler) WriteFile(ctx context.Context, r *http.Request) (*blo mutex.Lock() defer mutex.Unlock() - result := &blobberHTTP.UploadResult{} + result := &blobberhttp.UploadResult{} mode := allocation.INSERT_OPERATION if r.Method == "PUT" { mode = allocation.UPDATE_OPERATION diff --git a/code/go/0chain.net/blobbercore/handler/storage_handler.go b/code/go/0chain.net/blobbercore/handler/storage_handler.go index 0258c50a0..7fc9a328d 100644 --- a/code/go/0chain.net/blobbercore/handler/storage_handler.go +++ b/code/go/0chain.net/blobbercore/handler/storage_handler.go @@ -8,7 +8,6 @@ import ( "strings" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberHTTP" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" @@ -167,9 +166,9 @@ func (fsh *StorageHandler) GetFileMeta(ctx context.Context, r *http.Request) (in // authorize file access var ( - isOwner = clientID == alloc.OwnerID - isRepairer = clientID == alloc.RepairerID - isCollaborator = reference.IsACollaborator(ctx, fileref.ID, clientID) + isOwner = clientID == alloc.OwnerID + isRepairer = clientID == alloc.RepairerID + isCollaborator = reference.IsACollaborator(ctx, fileref.ID, clientID) ) if !isOwner && !isRepairer && !isCollaborator { @@ -392,7 +391,7 @@ func (fsh *StorageHandler) GetFileStats(ctx context.Context, r *http.Request) (i return result, nil } -func (fsh *StorageHandler) ListEntities(ctx context.Context, r *http.Request) (*blobberHTTP.ListResult, error) { +func (fsh *StorageHandler) ListEntities(ctx context.Context, r *http.Request) (*blobberhttp.ListResult, error) { if r.Method == "POST" { return nil, common.NewError("invalid_method", "Invalid method used. Use GET instead") @@ -437,7 +436,7 @@ func (fsh *StorageHandler) ListEntities(ctx context.Context, r *http.Request) (* return nil, common.NewError("invalid_parameters", "Invalid path. "+err.Error()) } - var result blobberHTTP.ListResult + var result blobberhttp.ListResult result.AllocationRoot = allocationObj.AllocationRoot result.Meta = dirref.GetListingData(ctx) if clientID != allocationObj.OwnerID { @@ -454,8 +453,8 @@ func (fsh *StorageHandler) ListEntities(ctx context.Context, r *http.Request) (* return &result, nil } -func (fsh *StorageHandler) GetReferencePath(ctx context.Context, r *http.Request) (*blobberHTTP.ReferencePathResult, error) { - resCh := make(chan *blobberHTTP.ReferencePathResult) +func (fsh *StorageHandler) GetReferencePath(ctx context.Context, r *http.Request) (*blobberhttp.ReferencePathResult, error) { + resCh := make(chan *blobberhttp.ReferencePathResult) errCh := make(chan error) go fsh.getReferencePath(ctx, r, resCh, errCh) @@ -471,7 +470,7 @@ func (fsh *StorageHandler) GetReferencePath(ctx context.Context, r *http.Request } } -func (fsh *StorageHandler) getReferencePath(ctx context.Context, r *http.Request, resCh chan<- *blobberHTTP.ReferencePathResult, errCh chan<- error) { +func (fsh *StorageHandler) getReferencePath(ctx context.Context, r *http.Request, resCh chan<- *blobberhttp.ReferencePathResult, errCh chan<- error) { if r.Method == "POST" { errCh <- common.NewError("invalid_method", "Invalid method used. Use GET instead") return @@ -537,7 +536,7 @@ func (fsh *StorageHandler) getReferencePath(ctx context.Context, r *http.Request return } } - var refPathResult blobberHTTP.ReferencePathResult + var refPathResult blobberhttp.ReferencePathResult refPathResult.ReferencePath = refPath if latestWM != nil { refPathResult.LatestWM = &latestWM.WM @@ -546,7 +545,7 @@ func (fsh *StorageHandler) getReferencePath(ctx context.Context, r *http.Request resCh <- &refPathResult } -func (fsh *StorageHandler) GetObjectPath(ctx context.Context, r *http.Request) (*blobberHTTP.ObjectPathResult, error) { +func (fsh *StorageHandler) GetObjectPath(ctx context.Context, r *http.Request) (*blobberhttp.ObjectPathResult, error) { if r.Method == "POST" { return nil, common.NewError("invalid_method", "Invalid method used. Use GET instead") } @@ -596,7 +595,7 @@ func (fsh *StorageHandler) GetObjectPath(ctx context.Context, r *http.Request) ( return nil, common.NewError("latest_write_marker_read_error", "Error reading the latest write marker for allocation."+err.Error()) } } - var objPathResult blobberHTTP.ObjectPathResult + var objPathResult blobberhttp.ObjectPathResult objPathResult.ObjectPath = objectPath if latestWM != nil { objPathResult.LatestWM = &latestWM.WM @@ -604,7 +603,7 @@ func (fsh *StorageHandler) GetObjectPath(ctx context.Context, r *http.Request) ( return &objPathResult, nil } -func (fsh *StorageHandler) GetObjectTree(ctx context.Context, r *http.Request) (*blobberHTTP.ReferencePathResult, error) { +func (fsh *StorageHandler) GetObjectTree(ctx context.Context, r *http.Request) (*blobberhttp.ReferencePathResult, error) { if r.Method == "POST" { return nil, common.NewError("invalid_method", "Invalid method used. Use GET instead") } @@ -662,7 +661,7 @@ func (fsh *StorageHandler) GetObjectTree(ctx context.Context, r *http.Request) ( return nil, common.NewError("latest_write_marker_read_error", "Error reading the latest write marker for allocation."+err.Error()) } } - var refPathResult blobberHTTP.ReferencePathResult + var refPathResult blobberhttp.ReferencePathResult refPathResult.ReferencePath = refPath if latestWM != nil { refPathResult.LatestWM = &latestWM.WM From a88f7aa80037e3ca08b18eb08303b2a3f8c22ab2 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 16:15:00 +0530 Subject: [PATCH 173/183] :bug: fixed compile errors --- code/go/0chain.net/blobbercore/convert/responseHandler.go | 1 + .../0chain.net/blobbercore/handler/object_operation_handler.go | 2 ++ code/go/0chain.net/blobbercore/handler/storage_handler.go | 2 ++ 3 files changed, 5 insertions(+) diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index aeba4f122..602a21dbb 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -10,6 +10,7 @@ import ( "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberhttp" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" ) diff --git a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go index 87dac1f3b..3f3357d0b 100644 --- a/code/go/0chain.net/blobbercore/handler/object_operation_handler.go +++ b/code/go/0chain.net/blobbercore/handler/object_operation_handler.go @@ -6,6 +6,8 @@ import ( "encoding/json" "errors" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberhttp" + "net/http" "path/filepath" "strconv" diff --git a/code/go/0chain.net/blobbercore/handler/storage_handler.go b/code/go/0chain.net/blobbercore/handler/storage_handler.go index 7fc9a328d..002f3ad3c 100644 --- a/code/go/0chain.net/blobbercore/handler/storage_handler.go +++ b/code/go/0chain.net/blobbercore/handler/storage_handler.go @@ -7,6 +7,8 @@ import ( "strconv" "strings" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberhttp" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/constants" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" From eed3e4e9d9f9b12c84a33e64c1fccb1cba8bbbe1 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 16:49:10 +0530 Subject: [PATCH 174/183] :art: seperated integration tests into different files --- .../handler/getallocation_integration_test.go | 64 + .../handler/grpc_handler_integration_test.go | 1413 ----------------- ...nit_test.go => helper_integration_test.go} | 61 + 3 files changed, 125 insertions(+), 1413 deletions(-) create mode 100644 code/go/0chain.net/blobbercore/handler/getallocation_integration_test.go delete mode 100644 code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go rename code/go/0chain.net/blobbercore/handler/{grpc_handler_helper_unit_test.go => helper_integration_test.go} (93%) diff --git a/code/go/0chain.net/blobbercore/handler/getallocation_integration_test.go b/code/go/0chain.net/blobbercore/handler/getallocation_integration_test.go new file mode 100644 index 000000000..8fe1fb7fa --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/getallocation_integration_test.go @@ -0,0 +1,64 @@ +package handler + +import ( + "context" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" +) + +func TestGetAllocation_IntegrationTest(t *testing.T) { + + bClient, tdController := setupHandlerIntegrationTests(t) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetAllocationTestData() + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + input *blobbergrpc.GetAllocationRequest + expectedTx string + expectingError bool + }{ + { + name: "Success", + input: &blobbergrpc.GetAllocationRequest{ + Id: "exampleTransaction", + }, + expectedTx: "exampleTransaction", + expectingError: false, + }, + { + name: "UnknownAllocation", + input: &blobbergrpc.GetAllocationRequest{ + Id: "exampleTransaction1", + }, + expectedTx: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + getAllocationResp, err := bClient.GetAllocation(context.Background(), tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getAllocationResp.Allocation.Tx != tc.expectedTx { + t.Fatal("response with wrong allocation transaction") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go deleted file mode 100644 index 79e929f57..000000000 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ /dev/null @@ -1,1413 +0,0 @@ -package handler - -import ( - "context" - "encoding/hex" - "encoding/json" - "fmt" - "io" - "log" - "math/rand" - "net/http" - "os" - "strconv" - "strings" - "testing" - "time" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" - - "github.com/0chain/blobber/code/go/0chain.net/core/common" - "github.com/0chain/blobber/code/go/0chain.net/core/encryption" - "google.golang.org/grpc/metadata" - - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" - "google.golang.org/grpc" - "gorm.io/driver/postgres" - "gorm.io/gorm" -) - -const BlobberTestAddr = "localhost:7031" -const RetryAttempts = 8 -const RetryTimeout = 3 - -func TestBlobberGRPCService_IntegrationTest(t *testing.T) { - args := make(map[string]bool) - for _, arg := range os.Args { - args[arg] = true - } - if !args["integration"] { - t.Skip() - } - - var conn *grpc.ClientConn - var err error - for i := 0; i < RetryAttempts; i++ { - log.Println("Connection attempt - " + fmt.Sprint(i+1)) - conn, err = grpc.Dial(BlobberTestAddr, grpc.WithInsecure()) - if err != nil { - log.Println(err) - <-time.After(time.Second * RetryTimeout) - continue - } - break - } - if err != nil { - t.Fatal(err) - } - defer conn.Close() - blobberClient := blobbergrpc.NewBlobberClient(conn) - - setupIntegrationTestConfig(t) - db, err := gorm.Open(postgres.Open(fmt.Sprintf( - "host=%v port=%v user=%v dbname=%v password=%v sslmode=disable", - config.Configuration.DBHost, config.Configuration.DBPort, - config.Configuration.DBUserName, config.Configuration.DBName, - config.Configuration.DBPassword)), &gorm.Config{}) - if err != nil { - t.Fatal(err) - } - tdController := NewTestDataController(db) - - t.Run("TestGetAllocation", func(t *testing.T) { - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetAllocationTestData() - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - input *blobbergrpc.GetAllocationRequest - expectedTx string - expectingError bool - }{ - { - name: "Success", - input: &blobbergrpc.GetAllocationRequest{ - Id: "exampleTransaction", - }, - expectedTx: "exampleTransaction", - expectingError: false, - }, - { - name: "UnknownAllocation", - input: &blobbergrpc.GetAllocationRequest{ - Id: "exampleTransaction1", - }, - expectedTx: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - getAllocationResp, err := blobberClient.GetAllocation(context.Background(), tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getAllocationResp.Allocation.Tx != tc.expectedTx { - t.Fatal("response with wrong allocation transaction") - } - } - }) - - t.Run("TestGetFileMetaData", func(t *testing.T) { - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetFileMetaDataTestData() - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.GetFileMetaDataRequest - expectedFileName string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - }), - input: &blobbergrpc.GetFileMetaDataRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath", - Allocation: "exampleTransaction", - }, - expectedFileName: "filename", - expectingError: false, - }, - { - name: "Unknown file path", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - }), - input: &blobbergrpc.GetFileMetaDataRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath123", - Allocation: "exampleTransaction", - }, - expectedFileName: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getFileMetaDataResp, err := blobberClient.GetFileMetaData(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getFileMetaDataResp.MetaData.FileMetaData.Name != tc.expectedFileName { - t.Fatal("unexpected file name from GetFileMetaData rpc") - } - } - }) - - t.Run("TestGetFileStats", func(t *testing.T) { - - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetFileStatsTestData(allocationTx, pubKey) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.GetFileStatsRequest - expectedFileName string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetFileStatsRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath", - Allocation: allocationTx, - }, - expectedFileName: "filename", - expectingError: false, - }, - { - name: "Unknown Path", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetFileStatsRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath123", - Allocation: allocationTx, - }, - expectedFileName: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getFileStatsResp, err := blobberClient.GetFileStats(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getFileStatsResp.MetaData.FileMetaData.Name != tc.expectedFileName { - t.Fatal("unexpected file name from GetFileStats rpc") - } - } - - }) - - t.Run("TestListEntities", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddListEntitiesTestData(allocationTx, pubKey) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.ListEntitiesRequest - expectedPath string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.ListEntitiesRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath", - AuthToken: "", - Allocation: allocationTx, - }, - expectedPath: "examplePath", - expectingError: false, - }, - { - name: "bad path", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.ListEntitiesRequest{ - Path: "examplePath", - PathHash: "exampleId:examplePath123", - AuthToken: "", - Allocation: allocationTx, - }, - expectedPath: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - listEntitiesResp, err := blobberClient.ListEntities(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if listEntitiesResp.MetaData.DirMetaData.Path != tc.expectedPath { - t.Fatal("unexpected path from ListEntities rpc") - } - } - - }) - - t.Run("TestGetObjectPath", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetObjectPathTestData(allocationTx, pubKey) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.GetObjectPathRequest - expectedPath string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetObjectPathRequest{ - Allocation: allocationTx, - Path: "examplePath", - BlockNum: "0", - }, - expectedPath: "/", - expectingError: false, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getObjectPathResp, err := blobberClient.GetObjectPath(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getObjectPathResp.ObjectPath.Path.DirMetaData.Path != tc.expectedPath { - t.Fatal("unexpected root hash from GetObjectPath rpc") - } - } - }) - - t.Run("TestGetReferencePath", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetReferencePathTestData(allocationTx, pubKey) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.GetReferencePathRequest - expectedPath string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetReferencePathRequest{ - Paths: "", - Path: "/", - Allocation: allocationTx, - }, - expectedPath: "/", - expectingError: false, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getReferencePathResp, err := blobberClient.GetReferencePath(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getReferencePathResp.ReferencePath.MetaData.DirMetaData.Path != tc.expectedPath { - t.Fatal("unexpected path from GetReferencePath rpc") - } - } - }) - - t.Run("TestGetObjectTree", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetObjectTreeTestData(allocationTx, pubKey) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.GetObjectTreeRequest - expectedFileName string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetObjectTreeRequest{ - Path: "/", - Allocation: allocationTx, - }, - expectedFileName: "root", - expectingError: false, - }, - { - name: "bad path", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - }), - input: &blobbergrpc.GetObjectTreeRequest{ - Path: "/2", - Allocation: "", - }, - expectedFileName: "root", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getObjectTreeResp, err := blobberClient.GetObjectTree(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getObjectTreeResp.ReferencePath.MetaData.DirMetaData.Name != tc.expectedFileName { - t.Fatal("unexpected root name from GetObject") - } - } - - }) - - t.Run("TestCommit", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - pubKeyBytes, _ := hex.DecodeString(pubKey) - clientId := encryption.Hash(pubKeyBytes) - now := common.Timestamp(time.Now().UnixNano()) - - blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" - blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) - - fr := reference.Ref{ - AllocationID: "exampleId", - Type: "f", - Name: "new_name", - Path: "/new_name", - ContentHash: "contentHash", - MerkleRoot: "merkleRoot", - ActualFileHash: "actualFileHash", - } - - rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) - - wm := writemarker.WriteMarker{ - AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), - PreviousAllocationRoot: "/", - AllocationID: "exampleId", - Size: 1337, - BlobberID: encryption.Hash(blobberPubKeyBytes), - Timestamp: now, - ClientID: clientId, - } - - wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) - if err != nil { - t.Fatal(err) - } - - wm.Signature = wmSig - - wmRaw, err := json.Marshal(wm) - if err != nil { - t.Fatal(err) - } - - err = tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.CommitRequest - expectedAllocation string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.CommitRequest{ - Allocation: allocationTx, - ConnectionId: "connection_id", - WriteMarker: string(wmRaw), - }, - expectedAllocation: "exampleId", - expectingError: false, - }, - { - name: "invalid write_marker", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.CommitRequest{ - Allocation: allocationTx, - ConnectionId: "invalid", - WriteMarker: "invalid", - }, - expectedAllocation: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - getCommiteResp, err := blobberClient.Commit(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if getCommiteResp.WriteMarker.AllocationID != tc.expectedAllocation { - t.Fatal("unexpected root name from GetObject") - } - } - }) - - t.Run("TestCommitMetaTxn", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - pubKeyBytes, _ := hex.DecodeString(pubKey) - clientId := encryption.Hash(pubKeyBytes) - now := common.Timestamp(time.Now().UnixNano()) - - blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" - blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) - - fr := reference.Ref{ - AllocationID: "exampleId", - } - - rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) - - wm := writemarker.WriteMarker{ - AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), - PreviousAllocationRoot: "/", - AllocationID: "exampleId", - Size: 1337, - BlobberID: encryption.Hash(blobberPubKeyBytes), - Timestamp: now, - ClientID: clientId, - } - - wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) - if err != nil { - t.Fatal(err) - } - - wm.Signature = wmSig - - if err := tdController.ClearDatabase(); err != nil { - t.Fatal(err) - } - if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.CommitMetaTxnRequest - expectedMessage string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - }), - input: &blobbergrpc.CommitMetaTxnRequest{ - Path: "/some_file", - PathHash: "exampleId:examplePath", - AuthToken: "", - Allocation: allocationTx, - TxnId: "8", - }, - expectedMessage: "Added commitMetaTxn successfully", - expectingError: false, - }, - { - name: "Fail", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - }), - input: &blobbergrpc.CommitMetaTxnRequest{ - Path: "/some_file", - PathHash: "exampleId:examplePath", - AuthToken: "", - Allocation: allocationTx, - TxnId: "", - }, - expectedMessage: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - commitMetaTxnResponse, err := blobberClient.CommitMetaTxn(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if commitMetaTxnResponse.GetMessage() != tc.expectedMessage { - t.Fatal("failed!") - } - } - }) - - t.Run("TestCollaborator", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - pubKeyBytes, _ := hex.DecodeString(pubKey) - clientId := encryption.Hash(pubKeyBytes) - now := common.Timestamp(time.Now().UnixNano()) - - blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" - blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) - - fr := reference.Ref{ - AllocationID: "exampleId", - } - - rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) - - wm := writemarker.WriteMarker{ - AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), - PreviousAllocationRoot: "/", - AllocationID: "exampleId", - Size: 1337, - BlobberID: encryption.Hash(blobberPubKeyBytes), - Timestamp: now, - ClientID: clientId, - } - - wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) - if err != nil { - t.Fatal(err) - } - - wm.Signature = wmSig - - if err := tdController.ClearDatabase(); err != nil { - t.Fatal(err) - } - if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.CollaboratorRequest - expectedMessage string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.CollaboratorRequest{ - Path: "/some_file", - PathHash: "exampleId:examplePath", - Allocation: allocationTx, - Method: http.MethodPost, - CollabId: "10", - }, - expectedMessage: "Added collaborator successfully", - expectingError: false, - }, - { - name: "Fail", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.CollaboratorRequest{ - Path: "/some_file", - PathHash: "exampleId:examplePath", - Allocation: allocationTx, - Method: http.MethodPost, - }, - expectedMessage: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - response, err := blobberClient.Collaborator(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if response.GetMessage() != tc.expectedMessage { - t.Fatal("failed!") - } - } - }) - - t.Run("TestCalculateHash", func(t *testing.T) { - allocationTx := randString(32) - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - - err := tdController.ClearDatabase() - if err != nil { - t.Fatal(err) - } - err = tdController.AddGetReferencePathTestData(allocationTx, pubKey) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.CalculateHashRequest - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: "exampleOwnerId", - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.CalculateHashRequest{ - Paths: "", - Path: "/", - Allocation: allocationTx, - }, - expectingError: false, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - _, err := blobberClient.CalculateHash(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - } - }) - - t.Run("TestUpdateAttributes", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - pubKeyBytes, _ := hex.DecodeString(pubKey) - clientId := encryption.Hash(pubKeyBytes) - - if err := tdController.ClearDatabase(); err != nil { - t.Fatal(err) - } - if err := tdController.AddAttributesTestData(allocationTx, pubKey, clientId); err != nil { - t.Fatal(err) - } - - attr := &reference.Attributes{WhoPaysForReads: common.WhoPays3rdParty} - attrBytes, err := json.Marshal(attr) - if err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.UpdateObjectAttributesRequest - expectedMessage int - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.UpdateObjectAttributesRequest{ - Allocation: allocationTx, - Path: "/some_file", - PathHash: "exampleId:examplePath", - ConnectionId: "connection_id", - Attributes: string(attrBytes), - }, - expectedMessage: int(attr.WhoPaysForReads), - expectingError: false, - }, - { - name: "Fail", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.UpdateObjectAttributesRequest{ - Allocation: "", - Path: "", - PathHash: "", - ConnectionId: "", - Attributes: "", - }, - expectedMessage: 0, - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - response, err := blobberClient.UpdateObjectAttributes(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if response.GetWhoPaysForReads() != int64(tc.expectedMessage) { - t.Fatal("failed!") - } - } - }) - - t.Run("TestCopyObject", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - pubKeyBytes, _ := hex.DecodeString(pubKey) - clientId := encryption.Hash(pubKeyBytes) - - if err := tdController.ClearDatabase(); err != nil { - t.Fatal(err) - } - if err := tdController.AddCopyObjectData(allocationTx, pubKey, clientId); err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.CopyObjectRequest - expectedMessage string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.CopyObjectRequest{ - Allocation: allocationTx, - Path: "/some_file", - PathHash: "exampleId:examplePath", - ConnectionId: "connection_id", - Dest: "/copy", - }, - expectedMessage: "some_file", - expectingError: false, - }, - { - name: "Fail", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.CopyObjectRequest{ - Allocation: "", - Path: "", - PathHash: "", - ConnectionId: "", - Dest: "", - }, - expectedMessage: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - response, err := blobberClient.CopyObject(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if response.GetFilename() != tc.expectedMessage { - t.Fatal("failed!") - } - } - }) - - t.Run("TestRenameObject", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - pubKeyBytes, _ := hex.DecodeString(pubKey) - clientId := encryption.Hash(pubKeyBytes) - - if err := tdController.ClearDatabase(); err != nil { - t.Fatal(err) - } - if err := tdController.AddRenameTestData(allocationTx, pubKey, clientId); err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.RenameObjectRequest - expectedMessage string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.RenameObjectRequest{ - Allocation: allocationTx, - Path: "/some_file", - PathHash: "exampleId:examplePath", - ConnectionId: "connection_id", - NewName: "some_new_file", - }, - expectedMessage: "some_new_file", - expectingError: false, - }, - { - name: "Fail", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.RenameObjectRequest{ - Allocation: "", - Path: "", - PathHash: "", - ConnectionId: "", - NewName: "", - }, - expectedMessage: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - response, err := blobberClient.RenameObject(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if response.GetFilename() != tc.expectedMessage { - t.Fatal("failed!") - } - } - }) - - t.Run("TestDownload", func(t *testing.T) { - allocationTx := randString(32) - - root, _ := os.Getwd() - path := strings.Split(root, `code`) - - err = os.MkdirAll(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`, os.ModePerm) - if err != nil { - t.Fatal(err) - } - defer func() { - err := os.RemoveAll(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon`) - if err != nil { - t.Fatal(err) - } - }() - - f, err := os.Create(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen/MyFile`) - if err != nil { - t.Fatal(err) - } - defer f.Close() - - file, err := os.Open(root + "/grpc_handler_integration_test.go") - if err != nil { - t.Fatal(err) - } - defer file.Close() - - _, err = io.Copy(f, file) - if err != nil { - t.Fatal(err) - } - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - pubKeyBytes, _ := hex.DecodeString(pubKey) - clientId := encryption.Hash(pubKeyBytes) - now := common.Timestamp(time.Now().Unix()) - allocationId := `exampleId` - - if err := tdController.ClearDatabase(); err != nil { - t.Fatal(err) - } - - blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" - blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) - - rm := readmarker.ReadMarker{ - BlobberID: encryption.Hash(blobberPubKeyBytes), - AllocationID: allocationId, - ClientPublicKey: pubKey, - ClientID: clientId, - OwnerID: clientId, - Timestamp: now, - //ReadCounter: 1337, - } - - rmSig, err := signScheme.Sign(encryption.Hash(rm.GetHashData())) - if err != nil { - t.Fatal(err) - } - rm.Signature = rmSig - - rmString, err := json.Marshal(rm) - if err != nil { - t.Fatal(err) - } - - if err := tdController.AddDownloadTestData(allocationTx, pubKey, clientId, rmSig, now); err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.DownloadFileRequest - expectedMessage string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.DownloadFileRequest{ - Allocation: allocationTx, - Path: "/some_file", - PathHash: "exampleId:examplePath", - ReadMarker: string(rmString), - BlockNum: "1", - }, - expectedMessage: "some_new_file", - expectingError: false, - }, - { - name: "Fail", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.DownloadFileRequest{ - Allocation: "", - Path: "", - PathHash: "", - RxPay: "", - BlockNum: "", - NumBlocks: "", - ReadMarker: "", - AuthToken: "", - Content: "", - }, - expectedMessage: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - _, err := blobberClient.DownloadFile(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - } - }) - - t.Run("TestUpload", func(t *testing.T) { - allocationTx := randString(32) - - pubKey, _, signScheme := GeneratePubPrivateKey(t) - clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) - pubKeyBytes, _ := hex.DecodeString(pubKey) - clientId := encryption.Hash(pubKeyBytes) - - formFieldByt, err := json.Marshal(&allocation.UpdateFileChange{NewFileChange: allocation.NewFileChange{Filename: `grpc_handler_integration_test.go`}}) - if err != nil { - t.Fatal(err) - } - - if err := tdController.ClearDatabase(); err != nil { - t.Fatal(err) - } - if err := tdController.AddUploadTestData(allocationTx, pubKey, clientId); err != nil { - t.Fatal(err) - } - - root, _ := os.Getwd() - file, err := os.Open(root + "/grpc_handler_integration_test.go") - if err != nil { - t.Fatal(err) - } - stats, err := file.Stat() - if err != nil { - panic(err) - } - fileB := make([]byte, stats.Size()) - if _, err := io.ReadFull(file, fileB); err != nil { - t.Fatal(err) - } - - testCases := []struct { - name string - context metadata.MD - input *blobbergrpc.UploadFileRequest - expectedFileName string - expectingError bool - }{ - { - name: "Success", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - - input: &blobbergrpc.UploadFileRequest{ - Allocation: allocationTx, - Path: "/some_file", - ConnectionId: "connection_id", - Method: "POST", - UploadMeta: string(formFieldByt), - UpdateMeta: "", - UploadFile: fileB, - UploadThumbnailFile: []byte{}, - }, - expectedFileName: "grpc_handler_integration_test.go", - expectingError: false, - }, - { - name: "Fail", - context: metadata.New(map[string]string{ - common.ClientHeader: clientId, - common.ClientSignatureHeader: clientSignature, - common.ClientKeyHeader: pubKey, - }), - input: &blobbergrpc.UploadFileRequest{ - Allocation: "", - Path: "", - ConnectionId: "", - Method: "", - UploadMeta: "", - UpdateMeta: "", - UploadFile: nil, - UploadThumbnailFile: nil, - }, - expectedFileName: "", - expectingError: true, - }, - } - - for _, tc := range testCases { - ctx := context.Background() - ctx = metadata.NewOutgoingContext(ctx, tc.context) - response, err := blobberClient.UploadFile(ctx, tc.input) - if err != nil { - if !tc.expectingError { - t.Fatal(err) - } - - continue - } - - if tc.expectingError { - t.Fatal("expected error") - } - - if response.GetFilename() != tc.expectedFileName { - t.Fatal("failed!") - } - } - }) -} - -func randString(n int) string { - - const hexLetters = "abcdef0123456789" - - var sb strings.Builder - for i := 0; i < n; i++ { - sb.WriteByte(hexLetters[rand.Intn(len(hexLetters))]) - } - return sb.String() -} diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go b/code/go/0chain.net/blobbercore/handler/helper_integration_test.go similarity index 93% rename from code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go rename to code/go/0chain.net/blobbercore/handler/helper_integration_test.go index 4fd9d7936..643bad3c4 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_helper_unit_test.go +++ b/code/go/0chain.net/blobbercore/handler/helper_integration_test.go @@ -5,10 +5,15 @@ import ( "database/sql" "fmt" "log" + "math/rand" "os" "strings" "time" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "google.golang.org/grpc" + "gorm.io/driver/postgres" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/config" @@ -21,6 +26,62 @@ import ( "github.com/0chain/gosdk/core/zcncrypto" ) +const BlobberTestAddr = "localhost:7031" +const RetryAttempts = 8 +const RetryTimeout = 3 + +func randString(n int) string { + + const hexLetters = "abcdef0123456789" + + var sb strings.Builder + for i := 0; i < n; i++ { + sb.WriteByte(hexLetters[rand.Intn(len(hexLetters))]) + } + return sb.String() +} + +func setupHandlerIntegrationTests(t *testing.T) (blobbergrpc.BlobberClient, *TestDataController) { + args := make(map[string]bool) + for _, arg := range os.Args { + args[arg] = true + } + if !args["integration"] { + t.Skip() + } + + var conn *grpc.ClientConn + var err error + for i := 0; i < RetryAttempts; i++ { + log.Println("Connection attempt - " + fmt.Sprint(i+1)) + conn, err = grpc.Dial(BlobberTestAddr, grpc.WithInsecure()) + if err != nil { + log.Println(err) + <-time.After(time.Second * RetryTimeout) + continue + } + break + } + if err != nil { + t.Fatal(err) + } + defer conn.Close() + bClient := blobbergrpc.NewBlobberClient(conn) + + setupIntegrationTestConfig(t) + db, err := gorm.Open(postgres.Open(fmt.Sprintf( + "host=%v port=%v user=%v dbname=%v password=%v sslmode=disable", + config.Configuration.DBHost, config.Configuration.DBPort, + config.Configuration.DBUserName, config.Configuration.DBName, + config.Configuration.DBPassword)), &gorm.Config{}) + if err != nil { + t.Fatal(err) + } + tdController := NewTestDataController(db) + + return bClient, tdController +} + type TestDataController struct { db *gorm.DB } From 2712e8ce97e6675a941ab6432aea6df3fd5fb22f Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 16:49:25 +0530 Subject: [PATCH 175/183] missing files from previous commit --- .../calculate_hash_integration_test.go | 66 ++++++++ .../handler/collaborator_integration_test.go | 124 ++++++++++++++ .../handler/commit_integration_test.go | 133 +++++++++++++++ .../commit_meta_txn_integration_test.go | 118 +++++++++++++ .../handler/copy_object_integration_test.go | 93 +++++++++++ .../handler/download_integration_test.go | 157 ++++++++++++++++++ .../getfilemetadata_integration_test.go | 78 +++++++++ .../handler/getfilestats_integration_test.go | 86 ++++++++++ .../handler/getobjectpath_integration_test.go | 71 ++++++++ .../handler/getobjecttree_integration_test.go | 84 ++++++++++ .../getreferencepath_integration_test.go | 72 ++++++++ .../handler/listentities_integration_test.go | 89 ++++++++++ .../handler/renameobject_integration_test.go | 93 +++++++++++ .../updateattributes_integration_test.go | 101 +++++++++++ .../handler/upload_integration_test.go | 123 ++++++++++++++ 15 files changed, 1488 insertions(+) create mode 100644 code/go/0chain.net/blobbercore/handler/calculate_hash_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/collaborator_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/commit_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/commit_meta_txn_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/copy_object_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/download_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/getfilemetadata_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/getfilestats_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/getobjectpath_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/getobjecttree_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/getreferencepath_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/listentities_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/renameobject_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/updateattributes_integration_test.go create mode 100644 code/go/0chain.net/blobbercore/handler/upload_integration_test.go diff --git a/code/go/0chain.net/blobbercore/handler/calculate_hash_integration_test.go b/code/go/0chain.net/blobbercore/handler/calculate_hash_integration_test.go new file mode 100644 index 000000000..a4d273c3e --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/calculate_hash_integration_test.go @@ -0,0 +1,66 @@ +package handler + +import ( + "context" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_CalculateHash(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetReferencePathTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CalculateHashRequest + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CalculateHashRequest{ + Paths: "", + Path: "/", + Allocation: allocationTx, + }, + expectingError: false, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + _, err := bClient.CalculateHash(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/collaborator_integration_test.go b/code/go/0chain.net/blobbercore/handler/collaborator_integration_test.go new file mode 100644 index 000000000..f03c7e36c --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/collaborator_integration_test.go @@ -0,0 +1,124 @@ +package handler + +import ( + "context" + "encoding/hex" + "net/http" + "strconv" + "testing" + "time" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_Collaborator(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().UnixNano()) + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + fr := reference.Ref{ + AllocationID: "exampleId", + } + + rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + + wm := writemarker.WriteMarker{ + AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + PreviousAllocationRoot: "/", + AllocationID: "exampleId", + Size: 1337, + BlobberID: encryption.Hash(blobberPubKeyBytes), + Timestamp: now, + ClientID: clientId, + } + + wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + if err != nil { + t.Fatal(err) + } + + wm.Signature = wmSig + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CollaboratorRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CollaboratorRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + Allocation: allocationTx, + Method: http.MethodPost, + CollabId: "10", + }, + expectedMessage: "Added collaborator successfully", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CollaboratorRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + Allocation: allocationTx, + Method: http.MethodPost, + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := bClient.Collaborator(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetMessage() != tc.expectedMessage { + t.Fatal("failed!") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/commit_integration_test.go b/code/go/0chain.net/blobbercore/handler/commit_integration_test.go new file mode 100644 index 000000000..e782d8097 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/commit_integration_test.go @@ -0,0 +1,133 @@ +package handler + +import ( + "context" + "encoding/hex" + "encoding/json" + "strconv" + "testing" + "time" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_Commit(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().UnixNano()) + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + fr := reference.Ref{ + AllocationID: "exampleId", + Type: "f", + Name: "new_name", + Path: "/new_name", + ContentHash: "contentHash", + MerkleRoot: "merkleRoot", + ActualFileHash: "actualFileHash", + } + + rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + + wm := writemarker.WriteMarker{ + AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + PreviousAllocationRoot: "/", + AllocationID: "exampleId", + Size: 1337, + BlobberID: encryption.Hash(blobberPubKeyBytes), + Timestamp: now, + ClientID: clientId, + } + + wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + if err != nil { + t.Fatal(err) + } + + wm.Signature = wmSig + + wmRaw, err := json.Marshal(wm) + if err != nil { + t.Fatal(err) + } + + err = tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CommitRequest + expectedAllocation string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CommitRequest{ + Allocation: allocationTx, + ConnectionId: "connection_id", + WriteMarker: string(wmRaw), + }, + expectedAllocation: "exampleId", + expectingError: false, + }, + { + name: "invalid write_marker", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CommitRequest{ + Allocation: allocationTx, + ConnectionId: "invalid", + WriteMarker: "invalid", + }, + expectedAllocation: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getCommiteResp, err := bClient.Commit(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getCommiteResp.WriteMarker.AllocationID != tc.expectedAllocation { + t.Fatal("unexpected root name from GetObject") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/commit_meta_txn_integration_test.go b/code/go/0chain.net/blobbercore/handler/commit_meta_txn_integration_test.go new file mode 100644 index 000000000..20c238c8a --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/commit_meta_txn_integration_test.go @@ -0,0 +1,118 @@ +package handler + +import ( + "context" + "encoding/hex" + "strconv" + "testing" + "time" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/writemarker" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_CommitMetaTxn(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().UnixNano()) + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + fr := reference.Ref{ + AllocationID: "exampleId", + } + + rootRefHash := encryption.Hash(encryption.Hash(fr.GetFileHashData())) + + wm := writemarker.WriteMarker{ + AllocationRoot: encryption.Hash(rootRefHash + ":" + strconv.FormatInt(int64(now), 10)), + PreviousAllocationRoot: "/", + AllocationID: "exampleId", + Size: 1337, + BlobberID: encryption.Hash(blobberPubKeyBytes), + Timestamp: now, + ClientID: clientId, + } + + wmSig, err := signScheme.Sign(encryption.Hash(wm.GetHashData())) + if err != nil { + t.Fatal(err) + } + + wm.Signature = wmSig + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddCommitTestData(allocationTx, pubKey, clientId, wmSig, now); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CommitMetaTxnRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + }), + input: &blobbergrpc.CommitMetaTxnRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: allocationTx, + TxnId: "8", + }, + expectedMessage: "Added commitMetaTxn successfully", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + }), + input: &blobbergrpc.CommitMetaTxnRequest{ + Path: "/some_file", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: allocationTx, + TxnId: "", + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + commitMetaTxnResponse, err := bClient.CommitMetaTxn(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if commitMetaTxnResponse.GetMessage() != tc.expectedMessage { + t.Fatal("failed!") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/copy_object_integration_test.go b/code/go/0chain.net/blobbercore/handler/copy_object_integration_test.go new file mode 100644 index 000000000..8b1a26062 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/copy_object_integration_test.go @@ -0,0 +1,93 @@ +package handler + +import ( + "context" + "encoding/hex" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_CopyObject(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddCopyObjectData(allocationTx, pubKey, clientId); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.CopyObjectRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CopyObjectRequest{ + Allocation: allocationTx, + Path: "/some_file", + PathHash: "exampleId:examplePath", + ConnectionId: "connection_id", + Dest: "/copy", + }, + expectedMessage: "some_file", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.CopyObjectRequest{ + Allocation: "", + Path: "", + PathHash: "", + ConnectionId: "", + Dest: "", + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := bClient.CopyObject(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetFilename() != tc.expectedMessage { + t.Fatal("failed!") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/download_integration_test.go b/code/go/0chain.net/blobbercore/handler/download_integration_test.go new file mode 100644 index 000000000..5792abb6e --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/download_integration_test.go @@ -0,0 +1,157 @@ +package handler + +import ( + "context" + "encoding/hex" + "encoding/json" + "io" + "os" + "strings" + "testing" + "time" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_DownloadFile(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + root, _ := os.Getwd() + path := strings.Split(root, `code`) + + err := os.MkdirAll(path[0]+`docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen`, os.ModePerm) + if err != nil { + t.Fatal(err) + } + defer func() { + err := os.RemoveAll(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon`) + if err != nil { + t.Fatal(err) + } + }() + + f, err := os.Create(path[0] + `docker.local/blobber1/files/files/exa/mpl/eId/objects/tmp/Mon/Wen/MyFile`) + if err != nil { + t.Fatal(err) + } + defer f.Close() + + file, err := os.Open(root + "/grpc_handler_integration_test.go") + if err != nil { + t.Fatal(err) + } + defer file.Close() + + _, err = io.Copy(f, file) + if err != nil { + t.Fatal(err) + } + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + now := common.Timestamp(time.Now().Unix()) + allocationId := `exampleId` + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + + blobberPubKey := "de52c0a51872d5d2ec04dbc15a6f0696cba22657b80520e1d070e72de64c9b04e19ce3223cae3c743a20184158457582ffe9c369ca9218c04bfe83a26a62d88d" + blobberPubKeyBytes, _ := hex.DecodeString(blobberPubKey) + + rm := readmarker.ReadMarker{ + BlobberID: encryption.Hash(blobberPubKeyBytes), + AllocationID: allocationId, + ClientPublicKey: pubKey, + ClientID: clientId, + OwnerID: clientId, + Timestamp: now, + //ReadCounter: 1337, + } + + rmSig, err := signScheme.Sign(encryption.Hash(rm.GetHashData())) + if err != nil { + t.Fatal(err) + } + rm.Signature = rmSig + + rmString, err := json.Marshal(rm) + if err != nil { + t.Fatal(err) + } + + if err := tdController.AddDownloadTestData(allocationTx, pubKey, clientId, rmSig, now); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.DownloadFileRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.DownloadFileRequest{ + Allocation: allocationTx, + Path: "/some_file", + PathHash: "exampleId:examplePath", + ReadMarker: string(rmString), + BlockNum: "1", + }, + expectedMessage: "some_new_file", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.DownloadFileRequest{ + Allocation: "", + Path: "", + PathHash: "", + RxPay: "", + BlockNum: "", + NumBlocks: "", + ReadMarker: "", + AuthToken: "", + Content: "", + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + _, err := bClient.DownloadFile(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/getfilemetadata_integration_test.go b/code/go/0chain.net/blobbercore/handler/getfilemetadata_integration_test.go new file mode 100644 index 000000000..436da99c5 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/getfilemetadata_integration_test.go @@ -0,0 +1,78 @@ +package handler + +import ( + "context" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "google.golang.org/grpc/metadata" +) + +func TestGetFileMetaData_IntegrationTest(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetFileMetaDataTestData() + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.GetFileMetaDataRequest + expectedFileName string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + }), + input: &blobbergrpc.GetFileMetaDataRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath", + Allocation: "exampleTransaction", + }, + expectedFileName: "filename", + expectingError: false, + }, + { + name: "Unknown file path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + }), + input: &blobbergrpc.GetFileMetaDataRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath123", + Allocation: "exampleTransaction", + }, + expectedFileName: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getFileMetaDataResp, err := bClient.GetFileMetaData(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getFileMetaDataResp.MetaData.FileMetaData.Name != tc.expectedFileName { + t.Fatal("unexpected file name from GetFileMetaData rpc") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/getfilestats_integration_test.go b/code/go/0chain.net/blobbercore/handler/getfilestats_integration_test.go new file mode 100644 index 000000000..a018e735c --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/getfilestats_integration_test.go @@ -0,0 +1,86 @@ +package handler + +import ( + "context" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestGetFilestats_IntegrationTest(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetFileStatsTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.GetFileStatsRequest + expectedFileName string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetFileStatsRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath", + Allocation: allocationTx, + }, + expectedFileName: "filename", + expectingError: false, + }, + { + name: "Unknown Path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetFileStatsRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath123", + Allocation: allocationTx, + }, + expectedFileName: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getFileStatsResp, err := bClient.GetFileStats(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getFileStatsResp.MetaData.FileMetaData.Name != tc.expectedFileName { + t.Fatal("unexpected file name from GetFileStats rpc") + } + } + +} diff --git a/code/go/0chain.net/blobbercore/handler/getobjectpath_integration_test.go b/code/go/0chain.net/blobbercore/handler/getobjectpath_integration_test.go new file mode 100644 index 000000000..e16bf27cd --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/getobjectpath_integration_test.go @@ -0,0 +1,71 @@ +package handler + +import ( + "context" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_GetObjectPath(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetObjectPathTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.GetObjectPathRequest + expectedPath string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetObjectPathRequest{ + Allocation: allocationTx, + Path: "examplePath", + BlockNum: "0", + }, + expectedPath: "/", + expectingError: false, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getObjectPathResp, err := bClient.GetObjectPath(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getObjectPathResp.ObjectPath.Path.DirMetaData.Path != tc.expectedPath { + t.Fatal("unexpected root hash from GetObjectPath rpc") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/getobjecttree_integration_test.go b/code/go/0chain.net/blobbercore/handler/getobjecttree_integration_test.go new file mode 100644 index 000000000..223697c8b --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/getobjecttree_integration_test.go @@ -0,0 +1,84 @@ +package handler + +import ( + "context" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_GetObjectTree(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetObjectTreeTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.GetObjectTreeRequest + expectedFileName string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetObjectTreeRequest{ + Path: "/", + Allocation: allocationTx, + }, + expectedFileName: "root", + expectingError: false, + }, + { + name: "bad path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetObjectTreeRequest{ + Path: "/2", + Allocation: "", + }, + expectedFileName: "root", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getObjectTreeResp, err := bClient.GetObjectTree(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getObjectTreeResp.ReferencePath.MetaData.DirMetaData.Name != tc.expectedFileName { + t.Fatal("unexpected root name from GetObject") + } + } + +} diff --git a/code/go/0chain.net/blobbercore/handler/getreferencepath_integration_test.go b/code/go/0chain.net/blobbercore/handler/getreferencepath_integration_test.go new file mode 100644 index 000000000..f12ffaaef --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/getreferencepath_integration_test.go @@ -0,0 +1,72 @@ +package handler + +import ( + "context" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_GetReferencePath(t *testing.T) { + + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddGetReferencePathTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.GetReferencePathRequest + expectedPath string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.GetReferencePathRequest{ + Paths: "", + Path: "/", + Allocation: allocationTx, + }, + expectedPath: "/", + expectingError: false, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + getReferencePathResp, err := bClient.GetReferencePath(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if getReferencePathResp.ReferencePath.MetaData.DirMetaData.Path != tc.expectedPath { + t.Fatal("unexpected path from GetReferencePath rpc") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/listentities_integration_test.go b/code/go/0chain.net/blobbercore/handler/listentities_integration_test.go new file mode 100644 index 000000000..f0a83e4b0 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/listentities_integration_test.go @@ -0,0 +1,89 @@ +package handler + +import ( + "context" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_ListEntities(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + + err := tdController.ClearDatabase() + if err != nil { + t.Fatal(err) + } + err = tdController.AddListEntitiesTestData(allocationTx, pubKey) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.ListEntitiesRequest + expectedPath string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.ListEntitiesRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath", + AuthToken: "", + Allocation: allocationTx, + }, + expectedPath: "examplePath", + expectingError: false, + }, + { + name: "bad path", + context: metadata.New(map[string]string{ + common.ClientHeader: "exampleOwnerId", + common.ClientSignatureHeader: clientSignature, + }), + input: &blobbergrpc.ListEntitiesRequest{ + Path: "examplePath", + PathHash: "exampleId:examplePath123", + AuthToken: "", + Allocation: allocationTx, + }, + expectedPath: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + listEntitiesResp, err := bClient.ListEntities(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if listEntitiesResp.MetaData.DirMetaData.Path != tc.expectedPath { + t.Fatal("unexpected path from ListEntities rpc") + } + } + +} diff --git a/code/go/0chain.net/blobbercore/handler/renameobject_integration_test.go b/code/go/0chain.net/blobbercore/handler/renameobject_integration_test.go new file mode 100644 index 000000000..bbbd2233e --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/renameobject_integration_test.go @@ -0,0 +1,93 @@ +package handler + +import ( + "context" + "encoding/hex" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_RenameObject(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddRenameTestData(allocationTx, pubKey, clientId); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.RenameObjectRequest + expectedMessage string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.RenameObjectRequest{ + Allocation: allocationTx, + Path: "/some_file", + PathHash: "exampleId:examplePath", + ConnectionId: "connection_id", + NewName: "some_new_file", + }, + expectedMessage: "some_new_file", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.RenameObjectRequest{ + Allocation: "", + Path: "", + PathHash: "", + ConnectionId: "", + NewName: "", + }, + expectedMessage: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := bClient.RenameObject(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetFilename() != tc.expectedMessage { + t.Fatal("failed!") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/updateattributes_integration_test.go b/code/go/0chain.net/blobbercore/handler/updateattributes_integration_test.go new file mode 100644 index 000000000..be10a3c74 --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/updateattributes_integration_test.go @@ -0,0 +1,101 @@ +package handler + +import ( + "context" + "encoding/hex" + "encoding/json" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_UpdateObjectAttributes(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddAttributesTestData(allocationTx, pubKey, clientId); err != nil { + t.Fatal(err) + } + + attr := &reference.Attributes{WhoPaysForReads: common.WhoPays3rdParty} + attrBytes, err := json.Marshal(attr) + if err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.UpdateObjectAttributesRequest + expectedMessage int + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.UpdateObjectAttributesRequest{ + Allocation: allocationTx, + Path: "/some_file", + PathHash: "exampleId:examplePath", + ConnectionId: "connection_id", + Attributes: string(attrBytes), + }, + expectedMessage: int(attr.WhoPaysForReads), + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.UpdateObjectAttributesRequest{ + Allocation: "", + Path: "", + PathHash: "", + ConnectionId: "", + Attributes: "", + }, + expectedMessage: 0, + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := bClient.UpdateObjectAttributes(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetWhoPaysForReads() != int64(tc.expectedMessage) { + t.Fatal("failed!") + } + } +} diff --git a/code/go/0chain.net/blobbercore/handler/upload_integration_test.go b/code/go/0chain.net/blobbercore/handler/upload_integration_test.go new file mode 100644 index 000000000..3bf5bef7e --- /dev/null +++ b/code/go/0chain.net/blobbercore/handler/upload_integration_test.go @@ -0,0 +1,123 @@ +package handler + +import ( + "context" + "encoding/hex" + "encoding/json" + "io" + "os" + "testing" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/core/common" + "github.com/0chain/blobber/code/go/0chain.net/core/encryption" + "google.golang.org/grpc/metadata" +) + +func TestBlobberGRPCService_UploadFile(t *testing.T) { + bClient, tdController := setupHandlerIntegrationTests(t) + allocationTx := randString(32) + + pubKey, _, signScheme := GeneratePubPrivateKey(t) + clientSignature, _ := signScheme.Sign(encryption.Hash(allocationTx)) + pubKeyBytes, _ := hex.DecodeString(pubKey) + clientId := encryption.Hash(pubKeyBytes) + + formFieldByt, err := json.Marshal(&allocation.UpdateFileChange{NewFileChange: allocation.NewFileChange{Filename: `grpc_handler_integration_test.go`}}) + if err != nil { + t.Fatal(err) + } + + if err := tdController.ClearDatabase(); err != nil { + t.Fatal(err) + } + if err := tdController.AddUploadTestData(allocationTx, pubKey, clientId); err != nil { + t.Fatal(err) + } + + root, _ := os.Getwd() + file, err := os.Open(root + "/grpc_handler_integration_test.go") + if err != nil { + t.Fatal(err) + } + stats, err := file.Stat() + if err != nil { + panic(err) + } + fileB := make([]byte, stats.Size()) + if _, err := io.ReadFull(file, fileB); err != nil { + t.Fatal(err) + } + + testCases := []struct { + name string + context metadata.MD + input *blobbergrpc.UploadFileRequest + expectedFileName string + expectingError bool + }{ + { + name: "Success", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + + input: &blobbergrpc.UploadFileRequest{ + Allocation: allocationTx, + Path: "/some_file", + ConnectionId: "connection_id", + Method: "POST", + UploadMeta: string(formFieldByt), + UpdateMeta: "", + UploadFile: fileB, + UploadThumbnailFile: []byte{}, + }, + expectedFileName: "grpc_handler_integration_test.go", + expectingError: false, + }, + { + name: "Fail", + context: metadata.New(map[string]string{ + common.ClientHeader: clientId, + common.ClientSignatureHeader: clientSignature, + common.ClientKeyHeader: pubKey, + }), + input: &blobbergrpc.UploadFileRequest{ + Allocation: "", + Path: "", + ConnectionId: "", + Method: "", + UploadMeta: "", + UpdateMeta: "", + UploadFile: nil, + UploadThumbnailFile: nil, + }, + expectedFileName: "", + expectingError: true, + }, + } + + for _, tc := range testCases { + ctx := context.Background() + ctx = metadata.NewOutgoingContext(ctx, tc.context) + response, err := bClient.UploadFile(ctx, tc.input) + if err != nil { + if !tc.expectingError { + t.Fatal(err) + } + + continue + } + + if tc.expectingError { + t.Fatal("expected error") + } + + if response.GetFilename() != tc.expectedFileName { + t.Fatal("failed!") + } + } +} From a2480a5343bcb21e3c8f873d07c9a3a0179be40f Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 16:59:48 +0530 Subject: [PATCH 176/183] :bug: fixing tests --- .../blobbercore/handler/helper_integration_test.go | 1 - .../blobbercore/handler/upload_integration_test.go | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/helper_integration_test.go b/code/go/0chain.net/blobbercore/handler/helper_integration_test.go index 643bad3c4..0ebc8375f 100644 --- a/code/go/0chain.net/blobbercore/handler/helper_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/helper_integration_test.go @@ -65,7 +65,6 @@ func setupHandlerIntegrationTests(t *testing.T) (blobbergrpc.BlobberClient, *Tes if err != nil { t.Fatal(err) } - defer conn.Close() bClient := blobbergrpc.NewBlobberClient(conn) setupIntegrationTestConfig(t) diff --git a/code/go/0chain.net/blobbercore/handler/upload_integration_test.go b/code/go/0chain.net/blobbercore/handler/upload_integration_test.go index 3bf5bef7e..479a8ceac 100644 --- a/code/go/0chain.net/blobbercore/handler/upload_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/upload_integration_test.go @@ -24,7 +24,7 @@ func TestBlobberGRPCService_UploadFile(t *testing.T) { pubKeyBytes, _ := hex.DecodeString(pubKey) clientId := encryption.Hash(pubKeyBytes) - formFieldByt, err := json.Marshal(&allocation.UpdateFileChange{NewFileChange: allocation.NewFileChange{Filename: `grpc_handler_integration_test.go`}}) + formFieldByt, err := json.Marshal(&allocation.UpdateFileChange{NewFileChange: allocation.NewFileChange{Filename: `helper_integration_test.go`}}) if err != nil { t.Fatal(err) } @@ -37,7 +37,7 @@ func TestBlobberGRPCService_UploadFile(t *testing.T) { } root, _ := os.Getwd() - file, err := os.Open(root + "/grpc_handler_integration_test.go") + file, err := os.Open(root + "/helper_integration_test.go") if err != nil { t.Fatal(err) } @@ -75,7 +75,7 @@ func TestBlobberGRPCService_UploadFile(t *testing.T) { UploadFile: fileB, UploadThumbnailFile: []byte{}, }, - expectedFileName: "grpc_handler_integration_test.go", + expectedFileName: "helper_integration_test.go", expectingError: false, }, { From e6e2c1b1e0039c3d255174814e356d43b462887c Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 17:12:06 +0530 Subject: [PATCH 177/183] :green_heart: fixing tests --- .../0chain.net/blobbercore/handler/download_integration_test.go | 2 +- .../0chain.net/blobbercore/handler/helper_integration_test.go | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/download_integration_test.go b/code/go/0chain.net/blobbercore/handler/download_integration_test.go index 5792abb6e..af32f9b2e 100644 --- a/code/go/0chain.net/blobbercore/handler/download_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/download_integration_test.go @@ -41,7 +41,7 @@ func TestBlobberGRPCService_DownloadFile(t *testing.T) { } defer f.Close() - file, err := os.Open(root + "/grpc_handler_integration_test.go") + file, err := os.Open(root + "/helper_integration_test.go") if err != nil { t.Fatal(err) } diff --git a/code/go/0chain.net/blobbercore/handler/helper_integration_test.go b/code/go/0chain.net/blobbercore/handler/helper_integration_test.go index 0ebc8375f..ceaeede39 100644 --- a/code/go/0chain.net/blobbercore/handler/helper_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/helper_integration_test.go @@ -53,7 +53,6 @@ func setupHandlerIntegrationTests(t *testing.T) (blobbergrpc.BlobberClient, *Tes var conn *grpc.ClientConn var err error for i := 0; i < RetryAttempts; i++ { - log.Println("Connection attempt - " + fmt.Sprint(i+1)) conn, err = grpc.Dial(BlobberTestAddr, grpc.WithInsecure()) if err != nil { log.Println(err) From 2650d79a8810f3d3fac4976dc20e3fac4e997151 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 17:55:46 +0530 Subject: [PATCH 178/183] :art: reformatted proto file according to convention --- .../blobbercore/blobbergrpc/blobber.pb.go | 1508 +++++++++-------- .../blobbergrpc/proto/blobber.proto | 218 +-- .../0chain.net/blobbercore/convert/convert.go | 51 +- .../blobbercore/convert/responseHandler.go | 8 +- .../blobbercore/openapi/blobber.swagger.json | 218 +-- 5 files changed, 1005 insertions(+), 998 deletions(-) diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go index 5d294e6b1..c5723434b 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go +++ b/code/go/0chain.net/blobbercore/blobbergrpc/blobber.pb.go @@ -106,7 +106,7 @@ type CollaboratorResponse struct { unknownFields protoimpl.UnknownFields Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` - Collaborators []*Collaborator `protobuf:"bytes,2,rep,name=Collaborators,proto3" json:"Collaborators,omitempty"` + Collaborators []*Collaborator `protobuf:"bytes,2,rep,name=collaborators,proto3" json:"collaborators,omitempty"` } func (x *CollaboratorResponse) Reset() { @@ -585,8 +585,8 @@ type GetObjectTreeResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ReferencePath *ReferencePath `protobuf:"bytes,1,opt,name=ReferencePath,proto3" json:"ReferencePath,omitempty"` - LatestWM *WriteMarker `protobuf:"bytes,2,opt,name=LatestWM,proto3" json:"LatestWM,omitempty"` + ReferencePath *ReferencePath `protobuf:"bytes,1,opt,name=reference_path,json=referencePath,proto3" json:"reference_path,omitempty"` + LatestWm *WriteMarker `protobuf:"bytes,2,opt,name=latest_wm,json=latestWm,proto3" json:"latest_wm,omitempty"` } func (x *GetObjectTreeResponse) Reset() { @@ -628,9 +628,9 @@ func (x *GetObjectTreeResponse) GetReferencePath() *ReferencePath { return nil } -func (x *GetObjectTreeResponse) GetLatestWM() *WriteMarker { +func (x *GetObjectTreeResponse) GetLatestWm() *WriteMarker { if x != nil { - return x.LatestWM + return x.LatestWm } return nil } @@ -640,8 +640,8 @@ type GetReferencePathRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Paths string `protobuf:"bytes,1,opt,name=Paths,proto3" json:"Paths,omitempty"` - Path string `protobuf:"bytes,2,opt,name=Path,proto3" json:"Path,omitempty"` + Paths string `protobuf:"bytes,1,opt,name=paths,proto3" json:"paths,omitempty"` + Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` Allocation string `protobuf:"bytes,3,opt,name=allocation,proto3" json:"allocation,omitempty"` } @@ -703,8 +703,8 @@ type GetReferencePathResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ReferencePath *ReferencePath `protobuf:"bytes,1,opt,name=ReferencePath,proto3" json:"ReferencePath,omitempty"` - LatestWM *WriteMarker `protobuf:"bytes,2,opt,name=LatestWM,proto3" json:"LatestWM,omitempty"` + ReferencePath *ReferencePath `protobuf:"bytes,1,opt,name=reference_path,json=referencePath,proto3" json:"reference_path,omitempty"` + LatestWm *WriteMarker `protobuf:"bytes,2,opt,name=latest_wm,json=latestWm,proto3" json:"latest_wm,omitempty"` } func (x *GetReferencePathResponse) Reset() { @@ -746,9 +746,9 @@ func (x *GetReferencePathResponse) GetReferencePath() *ReferencePath { return nil } -func (x *GetReferencePathResponse) GetLatestWM() *WriteMarker { +func (x *GetReferencePathResponse) GetLatestWm() *WriteMarker { if x != nil { - return x.LatestWM + return x.LatestWm } return nil } @@ -758,8 +758,8 @@ type ReferencePath struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - List []*ReferencePath `protobuf:"bytes,2,rep,name=List,proto3" json:"List,omitempty"` + MetaData *FileRef `protobuf:"bytes,1,opt,name=meta_data,json=metaData,proto3" json:"meta_data,omitempty"` + List []*ReferencePath `protobuf:"bytes,2,rep,name=list,proto3" json:"list,omitempty"` } func (x *ReferencePath) Reset() { @@ -814,8 +814,8 @@ type GetObjectPathRequest struct { unknownFields protoimpl.UnknownFields Allocation string `protobuf:"bytes,1,opt,name=allocation,proto3" json:"allocation,omitempty"` - Path string `protobuf:"bytes,2,opt,name=Path,proto3" json:"Path,omitempty"` - BlockNum string `protobuf:"bytes,3,opt,name=BlockNum,proto3" json:"BlockNum,omitempty"` + Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` + BlockNum string `protobuf:"bytes,3,opt,name=block_num,json=blockNum,proto3" json:"block_num,omitempty"` } func (x *GetObjectPathRequest) Reset() { @@ -876,8 +876,8 @@ type GetObjectPathResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ObjectPath *ObjectPath `protobuf:"bytes,1,opt,name=ObjectPath,proto3" json:"ObjectPath,omitempty"` - LatestWriteMarker *WriteMarker `protobuf:"bytes,2,opt,name=LatestWriteMarker,proto3" json:"LatestWriteMarker,omitempty"` + ObjectPath *ObjectPath `protobuf:"bytes,1,opt,name=object_path,json=objectPath,proto3" json:"object_path,omitempty"` + LatestWriteMarker *WriteMarker `protobuf:"bytes,2,opt,name=latest_write_marker,json=latestWriteMarker,proto3" json:"latest_write_marker,omitempty"` } func (x *GetObjectPathResponse) Reset() { @@ -931,11 +931,11 @@ type ObjectPath struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RootHash string `protobuf:"bytes,1,opt,name=RootHash,proto3" json:"RootHash,omitempty"` - Meta *FileRef `protobuf:"bytes,2,opt,name=Meta,proto3" json:"Meta,omitempty"` - Path *FileRef `protobuf:"bytes,3,opt,name=Path,proto3" json:"Path,omitempty"` - PathList []*FileRef `protobuf:"bytes,4,rep,name=PathList,proto3" json:"PathList,omitempty"` - FileBlockNum int64 `protobuf:"varint,5,opt,name=FileBlockNum,proto3" json:"FileBlockNum,omitempty"` + RootHash string `protobuf:"bytes,1,opt,name=root_hash,json=rootHash,proto3" json:"root_hash,omitempty"` + Meta *FileRef `protobuf:"bytes,2,opt,name=meta,proto3" json:"meta,omitempty"` + Path *FileRef `protobuf:"bytes,3,opt,name=path,proto3" json:"path,omitempty"` + PathList []*FileRef `protobuf:"bytes,4,rep,name=path_list,json=pathList,proto3" json:"path_list,omitempty"` + FileBlockNum int64 `protobuf:"varint,5,opt,name=file_block_num,json=fileBlockNum,proto3" json:"file_block_num,omitempty"` } func (x *ObjectPath) Reset() { @@ -1010,14 +1010,14 @@ type WriteMarker struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` - PreviousAllocationRoot string `protobuf:"bytes,2,opt,name=PreviousAllocationRoot,proto3" json:"PreviousAllocationRoot,omitempty"` - AllocationID string `protobuf:"bytes,3,opt,name=AllocationID,proto3" json:"AllocationID,omitempty"` - Size int64 `protobuf:"varint,4,opt,name=Size,proto3" json:"Size,omitempty"` - BlobberID string `protobuf:"bytes,5,opt,name=BlobberID,proto3" json:"BlobberID,omitempty"` - Timestamp int64 `protobuf:"varint,6,opt,name=Timestamp,proto3" json:"Timestamp,omitempty"` - ClientID string `protobuf:"bytes,7,opt,name=ClientID,proto3" json:"ClientID,omitempty"` - Signature string `protobuf:"bytes,8,opt,name=Signature,proto3" json:"Signature,omitempty"` + AllocationRoot string `protobuf:"bytes,1,opt,name=allocation_root,json=allocationRoot,proto3" json:"allocation_root,omitempty"` + PreviousAllocationRoot string `protobuf:"bytes,2,opt,name=previous_allocation_root,json=previousAllocationRoot,proto3" json:"previous_allocation_root,omitempty"` + AllocationId string `protobuf:"bytes,3,opt,name=allocation_id,json=allocationId,proto3" json:"allocation_id,omitempty"` + Size int64 `protobuf:"varint,4,opt,name=size,proto3" json:"size,omitempty"` + BlobberId string `protobuf:"bytes,5,opt,name=blobber_id,json=blobberId,proto3" json:"blobber_id,omitempty"` + Timestamp int64 `protobuf:"varint,6,opt,name=timestamp,proto3" json:"timestamp,omitempty"` + ClientId string `protobuf:"bytes,7,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` + Signature string `protobuf:"bytes,8,opt,name=signature,proto3" json:"signature,omitempty"` } func (x *WriteMarker) Reset() { @@ -1066,9 +1066,9 @@ func (x *WriteMarker) GetPreviousAllocationRoot() string { return "" } -func (x *WriteMarker) GetAllocationID() string { +func (x *WriteMarker) GetAllocationId() string { if x != nil { - return x.AllocationID + return x.AllocationId } return "" } @@ -1080,9 +1080,9 @@ func (x *WriteMarker) GetSize() int64 { return 0 } -func (x *WriteMarker) GetBlobberID() string { +func (x *WriteMarker) GetBlobberId() string { if x != nil { - return x.BlobberID + return x.BlobberId } return "" } @@ -1094,9 +1094,9 @@ func (x *WriteMarker) GetTimestamp() int64 { return 0 } -func (x *WriteMarker) GetClientID() string { +func (x *WriteMarker) GetClientId() string { if x != nil { - return x.ClientID + return x.ClientId } return "" } @@ -1184,9 +1184,9 @@ type ListEntitiesResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - AllocationRoot string `protobuf:"bytes,1,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` - MetaData *FileRef `protobuf:"bytes,2,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - Entities []*FileRef `protobuf:"bytes,3,rep,name=Entities,proto3" json:"Entities,omitempty"` + AllocationRoot string `protobuf:"bytes,1,opt,name=allocation_root,json=allocationRoot,proto3" json:"allocation_root,omitempty"` + MetaData *FileRef `protobuf:"bytes,2,opt,name=meta_data,json=metaData,proto3" json:"meta_data,omitempty"` + Entities []*FileRef `protobuf:"bytes,3,rep,name=entities,proto3" json:"entities,omitempty"` } func (x *ListEntitiesResponse) Reset() { @@ -1310,8 +1310,8 @@ type GetFileStatsResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - Stats *FileStats `protobuf:"bytes,2,opt,name=Stats,proto3" json:"Stats,omitempty"` + MetaData *FileRef `protobuf:"bytes,1,opt,name=meta_data,json=metaData,proto3" json:"meta_data,omitempty"` + Stats *FileStats `protobuf:"bytes,2,opt,name=stats,proto3" json:"stats,omitempty"` } func (x *GetFileStatsResponse) Reset() { @@ -1365,16 +1365,16 @@ type FileStats struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ID int64 `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"` - RefID int64 `protobuf:"varint,2,opt,name=RefID,proto3" json:"RefID,omitempty"` - NumUpdates int64 `protobuf:"varint,3,opt,name=NumUpdates,proto3" json:"NumUpdates,omitempty"` - NumBlockDownloads int64 `protobuf:"varint,4,opt,name=NumBlockDownloads,proto3" json:"NumBlockDownloads,omitempty"` - SuccessChallenges int64 `protobuf:"varint,5,opt,name=SuccessChallenges,proto3" json:"SuccessChallenges,omitempty"` - FailedChallenges int64 `protobuf:"varint,6,opt,name=FailedChallenges,proto3" json:"FailedChallenges,omitempty"` - LastChallengeResponseTxn string `protobuf:"bytes,7,opt,name=LastChallengeResponseTxn,proto3" json:"LastChallengeResponseTxn,omitempty"` - WriteMarkerRedeemTxn string `protobuf:"bytes,8,opt,name=WriteMarkerRedeemTxn,proto3" json:"WriteMarkerRedeemTxn,omitempty"` - CreatedAt int64 `protobuf:"varint,9,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` - UpdatedAt int64 `protobuf:"varint,10,opt,name=UpdatedAt,proto3" json:"UpdatedAt,omitempty"` + Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` + RefId int64 `protobuf:"varint,2,opt,name=ref_id,json=refId,proto3" json:"ref_id,omitempty"` + NumUpdates int64 `protobuf:"varint,3,opt,name=num_updates,json=numUpdates,proto3" json:"num_updates,omitempty"` + NumBlockDownloads int64 `protobuf:"varint,4,opt,name=num_block_downloads,json=numBlockDownloads,proto3" json:"num_block_downloads,omitempty"` + SuccessChallenges int64 `protobuf:"varint,5,opt,name=success_challenges,json=successChallenges,proto3" json:"success_challenges,omitempty"` + FailedChallenges int64 `protobuf:"varint,6,opt,name=failed_challenges,json=failedChallenges,proto3" json:"failed_challenges,omitempty"` + LastChallengeResponseTxn string `protobuf:"bytes,7,opt,name=last_challenge_response_txn,json=lastChallengeResponseTxn,proto3" json:"last_challenge_response_txn,omitempty"` + WriteMarkerRedeemTxn string `protobuf:"bytes,8,opt,name=write_marker_redeem_txn,json=writeMarkerRedeemTxn,proto3" json:"write_marker_redeem_txn,omitempty"` + CreatedAt int64 `protobuf:"varint,9,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` + UpdatedAt int64 `protobuf:"varint,10,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"` } func (x *FileStats) Reset() { @@ -1409,16 +1409,16 @@ func (*FileStats) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{21} } -func (x *FileStats) GetID() int64 { +func (x *FileStats) GetId() int64 { if x != nil { - return x.ID + return x.Id } return 0 } -func (x *FileStats) GetRefID() int64 { +func (x *FileStats) GetRefId() int64 { if x != nil { - return x.RefID + return x.RefId } return 0 } @@ -1555,8 +1555,8 @@ type GetFileMetaDataResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - MetaData *FileRef `protobuf:"bytes,1,opt,name=MetaData,proto3" json:"MetaData,omitempty"` - Collaborators []*Collaborator `protobuf:"bytes,2,rep,name=Collaborators,proto3" json:"Collaborators,omitempty"` + MetaData *FileRef `protobuf:"bytes,1,opt,name=meta_data,json=metaData,proto3" json:"meta_data,omitempty"` + Collaborators []*Collaborator `protobuf:"bytes,2,rep,name=collaborators,proto3" json:"collaborators,omitempty"` } func (x *GetFileMetaDataResponse) Reset() { @@ -1610,9 +1610,9 @@ type CommitMetaTxn struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RefId int64 `protobuf:"varint,1,opt,name=RefId,proto3" json:"RefId,omitempty"` - TxnId string `protobuf:"bytes,2,opt,name=TxnId,proto3" json:"TxnId,omitempty"` - CreatedAt int64 `protobuf:"varint,3,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` + RefId int64 `protobuf:"varint,1,opt,name=ref_id,json=refId,proto3" json:"ref_id,omitempty"` + TxnId string `protobuf:"bytes,2,opt,name=txn_id,json=txnId,proto3" json:"txn_id,omitempty"` + CreatedAt int64 `protobuf:"varint,3,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` } func (x *CommitMetaTxn) Reset() { @@ -1673,9 +1673,9 @@ type Collaborator struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RefId int64 `protobuf:"varint,1,opt,name=RefId,proto3" json:"RefId,omitempty"` - ClientId string `protobuf:"bytes,2,opt,name=ClientId,proto3" json:"ClientId,omitempty"` - CreatedAt int64 `protobuf:"varint,3,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` + RefId int64 `protobuf:"varint,1,opt,name=ref_id,json=refId,proto3" json:"ref_id,omitempty"` + ClientId string `protobuf:"bytes,2,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` + CreatedAt int64 `protobuf:"varint,3,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` } func (x *Collaborator) Reset() { @@ -2801,24 +2801,24 @@ type Allocation struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ID string `protobuf:"bytes,1,opt,name=ID,proto3" json:"ID,omitempty"` - Tx string `protobuf:"bytes,2,opt,name=Tx,proto3" json:"Tx,omitempty"` - TotalSize int64 `protobuf:"varint,3,opt,name=TotalSize,proto3" json:"TotalSize,omitempty"` - UsedSize int64 `protobuf:"varint,4,opt,name=UsedSize,proto3" json:"UsedSize,omitempty"` - OwnerID string `protobuf:"bytes,5,opt,name=OwnerID,proto3" json:"OwnerID,omitempty"` - OwnerPublicKey string `protobuf:"bytes,6,opt,name=OwnerPublicKey,proto3" json:"OwnerPublicKey,omitempty"` - RepairerID string `protobuf:"bytes,7,opt,name=RepairerID,proto3" json:"RepairerID,omitempty"` - PayerID string `protobuf:"bytes,8,opt,name=PayerID,proto3" json:"PayerID,omitempty"` - Expiration int64 `protobuf:"varint,9,opt,name=Expiration,proto3" json:"Expiration,omitempty"` - AllocationRoot string `protobuf:"bytes,10,opt,name=AllocationRoot,proto3" json:"AllocationRoot,omitempty"` - BlobberSize int64 `protobuf:"varint,11,opt,name=BlobberSize,proto3" json:"BlobberSize,omitempty"` - BlobberSizeUsed int64 `protobuf:"varint,12,opt,name=BlobberSizeUsed,proto3" json:"BlobberSizeUsed,omitempty"` - LatestRedeemedWM string `protobuf:"bytes,13,opt,name=LatestRedeemedWM,proto3" json:"LatestRedeemedWM,omitempty"` - IsRedeemRequired bool `protobuf:"varint,14,opt,name=IsRedeemRequired,proto3" json:"IsRedeemRequired,omitempty"` - TimeUnit int64 `protobuf:"varint,15,opt,name=TimeUnit,proto3" json:"TimeUnit,omitempty"` - CleanedUp bool `protobuf:"varint,16,opt,name=CleanedUp,proto3" json:"CleanedUp,omitempty"` - Finalized bool `protobuf:"varint,17,opt,name=Finalized,proto3" json:"Finalized,omitempty"` - Terms []*Term `protobuf:"bytes,18,rep,name=Terms,proto3" json:"Terms,omitempty"` + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + Tx string `protobuf:"bytes,2,opt,name=tx,proto3" json:"tx,omitempty"` + TotalSize int64 `protobuf:"varint,3,opt,name=total_size,json=totalSize,proto3" json:"total_size,omitempty"` + UsedSize int64 `protobuf:"varint,4,opt,name=used_size,json=usedSize,proto3" json:"used_size,omitempty"` + OwnerId string `protobuf:"bytes,5,opt,name=owner_id,json=ownerId,proto3" json:"owner_id,omitempty"` + OwnerPublicKey string `protobuf:"bytes,6,opt,name=owner_public_key,json=ownerPublicKey,proto3" json:"owner_public_key,omitempty"` + RepairerId string `protobuf:"bytes,7,opt,name=repairer_id,json=repairerId,proto3" json:"repairer_id,omitempty"` + PayerId string `protobuf:"bytes,8,opt,name=payer_id,json=payerId,proto3" json:"payer_id,omitempty"` + Expiration int64 `protobuf:"varint,9,opt,name=expiration,proto3" json:"expiration,omitempty"` + AllocationRoot string `protobuf:"bytes,10,opt,name=allocation_root,json=allocationRoot,proto3" json:"allocation_root,omitempty"` + BlobberSize int64 `protobuf:"varint,11,opt,name=blobber_size,json=blobberSize,proto3" json:"blobber_size,omitempty"` + BlobberSizeUsed int64 `protobuf:"varint,12,opt,name=blobber_size_used,json=blobberSizeUsed,proto3" json:"blobber_size_used,omitempty"` + LatestRedeemedWm string `protobuf:"bytes,13,opt,name=latest_redeemed_wm,json=latestRedeemedWm,proto3" json:"latest_redeemed_wm,omitempty"` + IsRedeemRequired bool `protobuf:"varint,14,opt,name=is_redeem_required,json=isRedeemRequired,proto3" json:"is_redeem_required,omitempty"` + TimeUnit int64 `protobuf:"varint,15,opt,name=time_unit,json=timeUnit,proto3" json:"time_unit,omitempty"` + CleanedUp bool `protobuf:"varint,16,opt,name=cleaned_up,json=cleanedUp,proto3" json:"cleaned_up,omitempty"` + Finalized bool `protobuf:"varint,17,opt,name=finalized,proto3" json:"finalized,omitempty"` + Terms []*Term `protobuf:"bytes,18,rep,name=terms,proto3" json:"terms,omitempty"` } func (x *Allocation) Reset() { @@ -2853,9 +2853,9 @@ func (*Allocation) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{39} } -func (x *Allocation) GetID() string { +func (x *Allocation) GetId() string { if x != nil { - return x.ID + return x.Id } return "" } @@ -2881,9 +2881,9 @@ func (x *Allocation) GetUsedSize() int64 { return 0 } -func (x *Allocation) GetOwnerID() string { +func (x *Allocation) GetOwnerId() string { if x != nil { - return x.OwnerID + return x.OwnerId } return "" } @@ -2895,16 +2895,16 @@ func (x *Allocation) GetOwnerPublicKey() string { return "" } -func (x *Allocation) GetRepairerID() string { +func (x *Allocation) GetRepairerId() string { if x != nil { - return x.RepairerID + return x.RepairerId } return "" } -func (x *Allocation) GetPayerID() string { +func (x *Allocation) GetPayerId() string { if x != nil { - return x.PayerID + return x.PayerId } return "" } @@ -2937,9 +2937,9 @@ func (x *Allocation) GetBlobberSizeUsed() int64 { return 0 } -func (x *Allocation) GetLatestRedeemedWM() string { +func (x *Allocation) GetLatestRedeemedWm() string { if x != nil { - return x.LatestRedeemedWM + return x.LatestRedeemedWm } return "" } @@ -2984,11 +2984,11 @@ type Term struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ID int64 `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"` - BlobberID string `protobuf:"bytes,2,opt,name=BlobberID,proto3" json:"BlobberID,omitempty"` - AllocationID string `protobuf:"bytes,3,opt,name=AllocationID,proto3" json:"AllocationID,omitempty"` - ReadPrice int64 `protobuf:"varint,4,opt,name=ReadPrice,proto3" json:"ReadPrice,omitempty"` - WritePrice int64 `protobuf:"varint,5,opt,name=WritePrice,proto3" json:"WritePrice,omitempty"` + Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` + BlobberId string `protobuf:"bytes,2,opt,name=blobber_id,json=blobberId,proto3" json:"blobber_id,omitempty"` + AllocationId string `protobuf:"bytes,3,opt,name=allocation_id,json=allocationId,proto3" json:"allocation_id,omitempty"` + ReadPrice int64 `protobuf:"varint,4,opt,name=read_price,json=readPrice,proto3" json:"read_price,omitempty"` + WritePrice int64 `protobuf:"varint,5,opt,name=write_price,json=writePrice,proto3" json:"write_price,omitempty"` } func (x *Term) Reset() { @@ -3023,23 +3023,23 @@ func (*Term) Descriptor() ([]byte, []int) { return file_blobber_proto_rawDescGZIP(), []int{40} } -func (x *Term) GetID() int64 { +func (x *Term) GetId() int64 { if x != nil { - return x.ID + return x.Id } return 0 } -func (x *Term) GetBlobberID() string { +func (x *Term) GetBlobberId() string { if x != nil { - return x.BlobberID + return x.BlobberId } return "" } -func (x *Term) GetAllocationID() string { +func (x *Term) GetAllocationId() string { if x != nil { - return x.AllocationID + return x.AllocationId } return "" } @@ -3063,9 +3063,9 @@ type FileRef struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Type string `protobuf:"bytes,1,opt,name=Type,proto3" json:"Type,omitempty"` - FileMetaData *FileMetaData `protobuf:"bytes,2,opt,name=FileMetaData,proto3" json:"FileMetaData,omitempty"` - DirMetaData *DirMetaData `protobuf:"bytes,3,opt,name=DirMetaData,proto3" json:"DirMetaData,omitempty"` + Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"` + FileMetaData *FileMetaData `protobuf:"bytes,2,opt,name=file_meta_data,json=fileMetaData,proto3" json:"file_meta_data,omitempty"` + DirMetaData *DirMetaData `protobuf:"bytes,3,opt,name=dir_meta_data,json=dirMetaData,proto3" json:"dir_meta_data,omitempty"` } func (x *FileRef) Reset() { @@ -3126,30 +3126,30 @@ type FileMetaData struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Type string `protobuf:"bytes,1,opt,name=Type,proto3" json:"Type,omitempty"` - LookupHash string `protobuf:"bytes,2,opt,name=LookupHash,proto3" json:"LookupHash,omitempty"` - Name string `protobuf:"bytes,3,opt,name=Name,proto3" json:"Name,omitempty"` - Path string `protobuf:"bytes,4,opt,name=Path,proto3" json:"Path,omitempty"` - Hash string `protobuf:"bytes,5,opt,name=Hash,proto3" json:"Hash,omitempty"` - NumBlocks int64 `protobuf:"varint,6,opt,name=NumBlocks,proto3" json:"NumBlocks,omitempty"` - PathHash string `protobuf:"bytes,7,opt,name=PathHash,proto3" json:"PathHash,omitempty"` - CustomMeta string `protobuf:"bytes,8,opt,name=CustomMeta,proto3" json:"CustomMeta,omitempty"` - ContentHash string `protobuf:"bytes,9,opt,name=ContentHash,proto3" json:"ContentHash,omitempty"` - Size int64 `protobuf:"varint,10,opt,name=Size,proto3" json:"Size,omitempty"` - MerkleRoot string `protobuf:"bytes,11,opt,name=MerkleRoot,proto3" json:"MerkleRoot,omitempty"` - ActualFileSize int64 `protobuf:"varint,12,opt,name=ActualFileSize,proto3" json:"ActualFileSize,omitempty"` - ActualFileHash string `protobuf:"bytes,13,opt,name=ActualFileHash,proto3" json:"ActualFileHash,omitempty"` - MimeType string `protobuf:"bytes,14,opt,name=MimeType,proto3" json:"MimeType,omitempty"` - ThumbnailSize int64 `protobuf:"varint,15,opt,name=ThumbnailSize,proto3" json:"ThumbnailSize,omitempty"` - ThumbnailHash string `protobuf:"bytes,16,opt,name=ThumbnailHash,proto3" json:"ThumbnailHash,omitempty"` - ActualThumbnailSize int64 `protobuf:"varint,17,opt,name=ActualThumbnailSize,proto3" json:"ActualThumbnailSize,omitempty"` - ActualThumbnailHash string `protobuf:"bytes,18,opt,name=ActualThumbnailHash,proto3" json:"ActualThumbnailHash,omitempty"` - EncryptedKey string `protobuf:"bytes,19,opt,name=EncryptedKey,proto3" json:"EncryptedKey,omitempty"` - Attributes []byte `protobuf:"bytes,20,opt,name=Attributes,proto3" json:"Attributes,omitempty"` - OnCloud bool `protobuf:"varint,21,opt,name=OnCloud,proto3" json:"OnCloud,omitempty"` - CommitMetaTxns []*CommitMetaTxn `protobuf:"bytes,22,rep,name=CommitMetaTxns,proto3" json:"CommitMetaTxns,omitempty"` - CreatedAt int64 `protobuf:"varint,23,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` - UpdatedAt int64 `protobuf:"varint,24,opt,name=UpdatedAt,proto3" json:"UpdatedAt,omitempty"` + Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"` + LookupHash string `protobuf:"bytes,2,opt,name=lookup_hash,json=lookupHash,proto3" json:"lookup_hash,omitempty"` + Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"` + Path string `protobuf:"bytes,4,opt,name=path,proto3" json:"path,omitempty"` + Hash string `protobuf:"bytes,5,opt,name=hash,proto3" json:"hash,omitempty"` + NumBlocks int64 `protobuf:"varint,6,opt,name=num_blocks,json=numBlocks,proto3" json:"num_blocks,omitempty"` + PathHash string `protobuf:"bytes,7,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + CustomMeta string `protobuf:"bytes,8,opt,name=custom_meta,json=customMeta,proto3" json:"custom_meta,omitempty"` + ContentHash string `protobuf:"bytes,9,opt,name=content_hash,json=contentHash,proto3" json:"content_hash,omitempty"` + Size int64 `protobuf:"varint,10,opt,name=size,proto3" json:"size,omitempty"` + MerkleRoot string `protobuf:"bytes,11,opt,name=merkle_root,json=merkleRoot,proto3" json:"merkle_root,omitempty"` + ActualFileSize int64 `protobuf:"varint,12,opt,name=actual_file_size,json=actualFileSize,proto3" json:"actual_file_size,omitempty"` + ActualFileHash string `protobuf:"bytes,13,opt,name=actual_file_hash,json=actualFileHash,proto3" json:"actual_file_hash,omitempty"` + MimeType string `protobuf:"bytes,14,opt,name=mime_type,json=mimeType,proto3" json:"mime_type,omitempty"` + ThumbnailSize int64 `protobuf:"varint,15,opt,name=thumbnail_size,json=thumbnailSize,proto3" json:"thumbnail_size,omitempty"` + ThumbnailHash string `protobuf:"bytes,16,opt,name=thumbnail_hash,json=thumbnailHash,proto3" json:"thumbnail_hash,omitempty"` + ActualThumbnailSize int64 `protobuf:"varint,17,opt,name=actual_thumbnail_size,json=actualThumbnailSize,proto3" json:"actual_thumbnail_size,omitempty"` + ActualThumbnailHash string `protobuf:"bytes,18,opt,name=actual_thumbnail_hash,json=actualThumbnailHash,proto3" json:"actual_thumbnail_hash,omitempty"` + EncryptedKey string `protobuf:"bytes,19,opt,name=encrypted_key,json=encryptedKey,proto3" json:"encrypted_key,omitempty"` + Attributes []byte `protobuf:"bytes,20,opt,name=attributes,proto3" json:"attributes,omitempty"` + OnCloud bool `protobuf:"varint,21,opt,name=on_cloud,json=onCloud,proto3" json:"on_cloud,omitempty"` + CommitMetaTxns []*CommitMetaTxn `protobuf:"bytes,22,rep,name=commit_meta_txns,json=commitMetaTxns,proto3" json:"commit_meta_txns,omitempty"` + CreatedAt int64 `protobuf:"varint,23,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` + UpdatedAt int64 `protobuf:"varint,24,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"` } func (x *FileMetaData) Reset() { @@ -3357,16 +3357,16 @@ type DirMetaData struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Type string `protobuf:"bytes,1,opt,name=Type,proto3" json:"Type,omitempty"` - LookupHash string `protobuf:"bytes,2,opt,name=LookupHash,proto3" json:"LookupHash,omitempty"` - Name string `protobuf:"bytes,3,opt,name=Name,proto3" json:"Name,omitempty"` - Path string `protobuf:"bytes,4,opt,name=Path,proto3" json:"Path,omitempty"` - Hash string `protobuf:"bytes,5,opt,name=Hash,proto3" json:"Hash,omitempty"` - NumBlocks int64 `protobuf:"varint,6,opt,name=NumBlocks,proto3" json:"NumBlocks,omitempty"` - PathHash string `protobuf:"bytes,7,opt,name=PathHash,proto3" json:"PathHash,omitempty"` - Size int64 `protobuf:"varint,8,opt,name=Size,proto3" json:"Size,omitempty"` - CreatedAt int64 `protobuf:"varint,9,opt,name=CreatedAt,proto3" json:"CreatedAt,omitempty"` - UpdatedAt int64 `protobuf:"varint,10,opt,name=UpdatedAt,proto3" json:"UpdatedAt,omitempty"` + Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"` + LookupHash string `protobuf:"bytes,2,opt,name=lookup_hash,json=lookupHash,proto3" json:"lookup_hash,omitempty"` + Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"` + Path string `protobuf:"bytes,4,opt,name=path,proto3" json:"path,omitempty"` + Hash string `protobuf:"bytes,5,opt,name=hash,proto3" json:"hash,omitempty"` + NumBlocks int64 `protobuf:"varint,6,opt,name=num_blocks,json=numBlocks,proto3" json:"num_blocks,omitempty"` + PathHash string `protobuf:"bytes,7,opt,name=path_hash,json=pathHash,proto3" json:"path_hash,omitempty"` + Size int64 `protobuf:"varint,8,opt,name=size,proto3" json:"size,omitempty"` + CreatedAt int64 `protobuf:"varint,9,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` + UpdatedAt int64 `protobuf:"varint,10,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"` } func (x *DirMetaData) Reset() { @@ -3491,10 +3491,10 @@ var file_blobber_proto_rawDesc = []byte{ 0x78, 0x0a, 0x14, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, - 0x65, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, + 0x65, 0x12, 0x46, 0x0a, 0x0d, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, + 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x60, 0x0a, 0x14, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, @@ -3542,612 +3542,618 @@ var file_blobber_proto_rawDesc = []byte{ 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9f, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, - 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, - 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa0, 0x01, 0x0a, 0x18, 0x47, - 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, - 0x68, 0x52, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, - 0x12, 0x3b, 0x0a, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, - 0x6b, 0x65, 0x72, 0x52, 0x08, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x4d, 0x22, 0x7f, 0x0a, - 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, - 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, - 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x66, - 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x6c, - 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x42, 0x6c, - 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa6, 0x01, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x3e, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, - 0x12, 0x4d, 0x0a, 0x11, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, - 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, + 0x48, 0x0a, 0x0e, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x5f, 0x70, 0x61, 0x74, + 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, + 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x72, 0x65, 0x66, 0x65, + 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3c, 0x0a, 0x09, 0x6c, 0x61, 0x74, + 0x65, 0x73, 0x74, 0x5f, 0x77, 0x6d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x6c, + 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x6d, 0x22, 0x63, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x52, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x61, 0x74, 0x68, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x05, 0x70, 0x61, 0x74, 0x68, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1e, 0x0a, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa2, 0x01, 0x0a, + 0x18, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, + 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x48, 0x0a, 0x0e, 0x72, 0x65, 0x66, + 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x5f, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, + 0x50, 0x61, 0x74, 0x68, 0x52, 0x0d, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x3c, 0x0a, 0x09, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x77, 0x6d, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, + 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, + 0x6d, 0x22, 0x80, 0x01, 0x0a, 0x0d, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x12, 0x38, 0x0a, 0x09, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x64, 0x61, 0x74, 0x61, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, + 0x52, 0x65, 0x66, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x35, 0x0a, + 0x04, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x4c, 0x61, - 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, - 0xe7, 0x01, 0x0a, 0x0a, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1a, - 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x4d, 0x65, + 0x2e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x04, + 0x6c, 0x69, 0x73, 0x74, 0x22, 0x67, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, + 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, + 0x12, 0x1b, 0x0a, 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa9, 0x01, + 0x0a, 0x15, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3f, 0x0a, 0x0b, 0x6f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x5f, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x0a, 0x6f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4f, 0x0a, 0x13, 0x6c, 0x61, 0x74, 0x65, + 0x73, 0x74, 0x5f, 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x11, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x57, 0x72, + 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x22, 0xeb, 0x01, 0x0a, 0x0a, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x72, 0x6f, 0x6f, 0x74, + 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x72, 0x6f, 0x6f, + 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x2f, 0x0a, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, + 0x52, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, + 0x66, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x38, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, + 0x6c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, + 0x74, 0x12, 0x24, 0x0a, 0x0e, 0x66, 0x69, 0x6c, 0x65, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, + 0x6e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x66, 0x69, 0x6c, 0x65, 0x42, + 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0xa1, 0x02, 0x0a, 0x0b, 0x57, 0x72, 0x69, 0x74, + 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x27, 0x0a, 0x0f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0e, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, + 0x12, 0x38, 0x0a, 0x18, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x5f, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x16, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0c, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, + 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, + 0x69, 0x7a, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x5f, 0x69, + 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, + 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, + 0x12, 0x1b, 0x0a, 0x09, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x07, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, 0x0a, + 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, 0x13, + 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, + 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, + 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, + 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x22, 0xb2, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, + 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x27, 0x0a, 0x0f, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x38, 0x0a, 0x09, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, - 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x50, - 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, - 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x08, - 0x50, 0x61, 0x74, 0x68, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x50, 0x61, 0x74, - 0x68, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x42, 0x6c, 0x6f, - 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x46, 0x69, 0x6c, - 0x65, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, 0x72, - 0x69, 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, - 0x74, 0x12, 0x36, 0x0a, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x16, 0x50, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, - 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x12, - 0x1c, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1a, 0x0a, - 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x69, 0x67, - 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x69, - 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0x85, 0x01, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, - 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x37, 0x0a, 0x08, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, + 0x65, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, + 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, - 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, - 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0xb0, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, - 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, - 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x74, - 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, - 0x65, 0x73, 0x22, 0x66, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, + 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x22, 0x85, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x38, 0x0a, 0x09, 0x6d, 0x65, 0x74, + 0x61, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, + 0x73, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x73, 0x22, 0x93, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, + 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x15, 0x0a, 0x06, 0x72, 0x65, 0x66, 0x5f, 0x69, 0x64, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x72, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1f, 0x0a, + 0x0b, 0x6e, 0x75, 0x6d, 0x5f, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0a, 0x6e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2e, + 0x0a, 0x13, 0x6e, 0x75, 0x6d, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x64, 0x6f, 0x77, 0x6e, + 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x6e, 0x75, 0x6d, + 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x12, 0x2d, + 0x0a, 0x12, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x5f, 0x63, 0x68, 0x61, 0x6c, 0x6c, 0x65, + 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, 0x73, 0x75, 0x63, 0x63, + 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x2b, 0x0a, + 0x11, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x5f, 0x63, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, + 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, + 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3d, 0x0a, 0x1b, 0x6c, 0x61, + 0x73, 0x74, 0x5f, 0x63, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x5f, 0x72, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x5f, 0x74, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x18, 0x6c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x35, 0x0a, 0x17, 0x77, 0x72, 0x69, + 0x74, 0x65, 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x5f, 0x72, 0x65, 0x64, 0x65, 0x65, 0x6d, + 0x5f, 0x74, 0x78, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x77, 0x72, 0x69, 0x74, + 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, + 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, + 0x1d, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x0a, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, + 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, + 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x84, 0x01, 0x0a, 0x14, 0x47, - 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, - 0x65, 0x66, 0x52, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x05, - 0x53, 0x74, 0x61, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, - 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, - 0x73, 0x22, 0x85, 0x03, 0x0a, 0x09, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, - 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x44, 0x12, - 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, - 0x52, 0x65, 0x66, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, 0x64, 0x61, - 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, - 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x11, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, - 0x61, 0x64, 0x73, 0x12, 0x2c, 0x0a, 0x11, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, - 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x11, - 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, - 0x73, 0x12, 0x2a, 0x0a, 0x10, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, - 0x65, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x46, 0x61, 0x69, - 0x6c, 0x65, 0x64, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3a, 0x0a, - 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x18, 0x4c, 0x61, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6c, 0x6c, 0x65, 0x6e, 0x67, 0x65, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x54, 0x78, 0x6e, 0x12, 0x32, 0x0a, 0x14, 0x57, 0x72, 0x69, - 0x74, 0x65, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, - 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4d, 0x61, - 0x72, 0x6b, 0x65, 0x72, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x54, 0x78, 0x6e, 0x12, 0x1c, 0x0a, - 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x88, 0x01, 0x0a, 0x16, 0x47, 0x65, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, - 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, - 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x6f, - 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x54, - 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9a, 0x01, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x37, 0x0a, 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, - 0x08, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x6f, 0x6c, - 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, - 0x6f, 0x72, 0x52, 0x0d, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x73, 0x22, 0x59, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, - 0x78, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x78, 0x6e, 0x49, - 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1c, - 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x5e, 0x0a, 0x0c, - 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, - 0x52, 0x65, 0x66, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x52, 0x65, 0x66, - 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1c, - 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, - 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x02, 0x69, 0x64, 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, - 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x93, 0x02, - 0x0a, 0x13, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, - 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, - 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x15, 0x0a, 0x06, 0x72, 0x78, 0x5f, 0x70, 0x61, 0x79, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x72, 0x78, 0x50, 0x61, 0x79, 0x12, 0x1b, 0x0a, - 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x12, 0x1d, 0x0a, 0x0a, 0x6e, 0x75, - 0x6d, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, - 0x6e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1f, 0x0a, 0x0b, 0x72, 0x65, 0x61, - 0x64, 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x72, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, - 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, - 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, - 0x74, 0x65, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, - 0x65, 0x6e, 0x74, 0x22, 0xb9, 0x01, 0x0a, 0x14, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, - 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, - 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0c, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, - 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, - 0x61, 0x74, 0x68, 0x12, 0x3a, 0x0a, 0x09, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x72, 0x6d, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x61, 0x64, - 0x4d, 0x61, 0x6b, 0x65, 0x72, 0x52, 0x08, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x6d, 0x22, - 0xdf, 0x02, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x6b, 0x65, 0x72, 0x12, 0x1b, 0x0a, - 0x09, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x2a, 0x0a, 0x11, 0x63, 0x6c, - 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x50, 0x75, 0x62, - 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x49, 0x64, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6f, 0x77, - 0x6e, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6f, 0x77, - 0x6e, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, - 0x61, 0x6d, 0x70, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x12, 0x1c, 0x0a, - 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, - 0x75, 0x73, 0x70, 0x65, 0x6e, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x73, 0x75, - 0x73, 0x70, 0x65, 0x6e, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x70, 0x61, 0x79, 0x65, 0x72, 0x5f, 0x69, - 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x70, 0x61, 0x79, 0x65, 0x72, 0x49, 0x64, - 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x54, 0x69, 0x63, 0x6b, 0x65, - 0x74, 0x22, 0xb5, 0x01, 0x0a, 0x1d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, - 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, - 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, - 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x74, 0x74, - 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, - 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x22, 0x4d, 0x0a, 0x1e, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, - 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2b, 0x0a, 0x12, 0x77, - 0x68, 0x6f, 0x5f, 0x70, 0x61, 0x79, 0x73, 0x5f, 0x66, 0x6f, 0x72, 0x5f, 0x72, 0x65, 0x61, 0x64, - 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x77, 0x68, 0x6f, 0x50, 0x61, 0x79, 0x73, - 0x46, 0x6f, 0x72, 0x52, 0x65, 0x61, 0x64, 0x73, 0x22, 0x9d, 0x01, 0x0a, 0x11, 0x43, 0x6f, 0x70, - 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, - 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, - 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, - 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, - 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, - 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x65, 0x73, 0x74, 0x18, 0x05, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x64, 0x65, 0x73, 0x74, 0x22, 0xd2, 0x01, 0x0a, 0x12, 0x43, 0x6f, 0x70, - 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, - 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, - 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, - 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, - 0x6f, 0x6f, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, - 0x6e, 0x67, 0x74, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, - 0x61, 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, - 0x61, 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xa6, 0x01, - 0x0a, 0x13, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, - 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, - 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, - 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6e, - 0x65, 0x77, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e, - 0x65, 0x77, 0x4e, 0x61, 0x6d, 0x65, 0x22, 0xd4, 0x01, 0x0a, 0x14, 0x52, 0x65, 0x6e, 0x61, 0x6d, - 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, - 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, - 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, - 0x73, 0x68, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, - 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, - 0x6f, 0x6f, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, - 0x6e, 0x67, 0x74, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, - 0x61, 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, - 0x61, 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0x9b, 0x02, - 0x0a, 0x11, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, - 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, - 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, - 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6d, 0x65, - 0x74, 0x68, 0x6f, 0x64, 0x12, 0x1f, 0x0a, 0x0b, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6d, - 0x65, 0x74, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x75, 0x70, 0x6c, 0x6f, 0x61, - 0x64, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x1f, 0x0a, 0x0b, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x5f, - 0x6d, 0x65, 0x74, 0x61, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, - 0x74, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x1f, 0x0a, 0x0b, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, - 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x75, 0x70, 0x6c, - 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x32, 0x0a, 0x15, 0x75, 0x70, 0x6c, 0x6f, 0x61, - 0x64, 0x5f, 0x74, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x5f, 0x66, 0x69, 0x6c, 0x65, - 0x18, 0x08, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x13, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x22, 0xd2, 0x01, 0x0a, 0x12, - 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, - 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, - 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, - 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, - 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, - 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, - 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, - 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, - 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, - 0x22, 0xd6, 0x04, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, - 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x44, 0x12, - 0x0e, 0x0a, 0x02, 0x54, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x54, 0x78, 0x12, - 0x1c, 0x0a, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, - 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x08, 0x55, 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x4f, 0x77, 0x6e, - 0x65, 0x72, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x4f, 0x77, 0x6e, 0x65, - 0x72, 0x49, 0x44, 0x12, 0x26, 0x0a, 0x0e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, - 0x69, 0x63, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x77, 0x6e, - 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x52, - 0x65, 0x70, 0x61, 0x69, 0x72, 0x65, 0x72, 0x49, 0x44, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x52, 0x65, 0x70, 0x61, 0x69, 0x72, 0x65, 0x72, 0x49, 0x44, 0x12, 0x18, 0x0a, 0x07, 0x50, - 0x61, 0x79, 0x65, 0x72, 0x49, 0x44, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, - 0x79, 0x65, 0x72, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x45, 0x78, 0x70, 0x69, 0x72, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x20, 0x0a, - 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0b, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x0b, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x12, - 0x28, 0x0a, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, - 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0f, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, - 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x2a, 0x0a, 0x10, 0x4c, 0x61, 0x74, - 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x18, 0x0d, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x10, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, - 0x6d, 0x65, 0x64, 0x57, 0x4d, 0x12, 0x2a, 0x0a, 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, - 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, - 0x10, 0x49, 0x73, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, - 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x0f, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x08, 0x54, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1c, 0x0a, - 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x18, 0x10, 0x20, 0x01, 0x28, 0x08, - 0x52, 0x09, 0x43, 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x46, - 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x11, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, - 0x46, 0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x54, 0x65, 0x72, - 0x6d, 0x73, 0x18, 0x12, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, - 0x72, 0x6d, 0x52, 0x05, 0x54, 0x65, 0x72, 0x6d, 0x73, 0x22, 0x96, 0x01, 0x0a, 0x04, 0x54, 0x65, - 0x72, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, - 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x42, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x44, - 0x12, 0x22, 0x0a, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x44, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1c, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, 0x63, - 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x52, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, - 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x57, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, 0x69, - 0x63, 0x65, 0x22, 0xa6, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, 0x12, - 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, - 0x70, 0x65, 0x12, 0x44, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, - 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, + 0x74, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x61, 0x75, 0x74, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9b, 0x01, 0x0a, 0x17, 0x47, 0x65, + 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x38, 0x0a, 0x09, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x64, 0x61, + 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x46, 0x69, 0x6c, 0x65, - 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, - 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, + 0x6c, 0x65, 0x52, 0x65, 0x66, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x46, 0x0a, 0x0d, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, + 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, + 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, + 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x5c, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x15, 0x0a, 0x06, 0x72, 0x65, 0x66, 0x5f, + 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x72, 0x65, 0x66, 0x49, 0x64, 0x12, + 0x15, 0x0a, 0x06, 0x74, 0x78, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x05, 0x74, 0x78, 0x6e, 0x49, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x5f, 0x61, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x63, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x61, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, + 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x15, 0x0a, 0x06, 0x72, 0x65, 0x66, 0x5f, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x72, 0x65, 0x66, 0x49, 0x64, 0x12, 0x1b, 0x0a, 0x09, + 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x08, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x63, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x26, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, + 0x22, 0x57, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0b, - 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x22, 0xaf, 0x06, 0x0a, 0x0c, - 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, - 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, - 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, - 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, 0x68, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, 0x09, - 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, - 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, - 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, - 0x4d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x75, 0x73, 0x74, - 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x48, 0x61, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, - 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, - 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1e, 0x0a, 0x0a, - 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0a, 0x4d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x0e, - 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0c, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, - 0x53, 0x69, 0x7a, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, - 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x41, 0x63, - 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, - 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x4d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, - 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x24, - 0x0a, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, - 0x48, 0x61, 0x73, 0x68, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, - 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, - 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x13, 0x41, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, - 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x22, 0x0a, 0x0c, 0x45, 0x6e, 0x63, 0x72, - 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, - 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, - 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, - 0x52, 0x0a, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, - 0x4f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x4f, - 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x49, 0x0a, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, - 0x6e, 0x52, 0x0e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, - 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x17, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, - 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x18, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x87, 0x02, - 0x0a, 0x0b, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x54, 0x79, 0x70, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, - 0x68, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x61, 0x73, - 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1c, 0x0a, - 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x4e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x50, - 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, - 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xcc, 0x12, 0x0a, 0x07, 0x42, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, - 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x91, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, - 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, - 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x89, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, - 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x76, 0x31, 0x2e, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x93, 0x02, 0x0a, 0x13, 0x44, 0x6f, + 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, + 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x15, 0x0a, 0x06, 0x72, 0x78, 0x5f, 0x70, 0x61, 0x79, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x05, 0x72, 0x78, 0x50, 0x61, 0x79, 0x12, 0x1b, 0x0a, 0x09, 0x62, 0x6c, 0x6f, + 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x6c, + 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x12, 0x1d, 0x0a, 0x0a, 0x6e, 0x75, 0x6d, 0x5f, 0x62, 0x6c, + 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x6e, 0x75, 0x6d, 0x42, + 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1f, 0x0a, 0x0b, 0x72, 0x65, 0x61, 0x64, 0x5f, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x72, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x72, 0x65, 0x61, 0x64, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, + 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, + 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, + 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x22, + 0xb9, 0x01, 0x0a, 0x14, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x63, 0x63, + 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, + 0x73, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, + 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, + 0x3a, 0x0a, 0x09, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x72, 0x6d, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x6b, 0x65, + 0x72, 0x52, 0x08, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x6d, 0x22, 0xdf, 0x02, 0x0a, 0x09, + 0x52, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x6b, 0x65, 0x72, 0x12, 0x1b, 0x0a, 0x09, 0x63, 0x6c, 0x69, + 0x65, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, 0x6c, + 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x2a, 0x0a, 0x11, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, + 0x5f, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, + 0x65, 0x79, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x5f, 0x69, 0x64, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, + 0x64, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, + 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x5f, + 0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x49, + 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, + 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x07, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x69, + 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x73, 0x70, 0x65, + 0x6e, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x73, 0x75, 0x73, 0x70, 0x65, 0x6e, + 0x64, 0x12, 0x19, 0x0a, 0x08, 0x70, 0x61, 0x79, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x0a, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x07, 0x70, 0x61, 0x79, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1f, 0x0a, 0x0b, + 0x61, 0x75, 0x74, 0x68, 0x5f, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, + 0x0c, 0x52, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x22, 0xb5, 0x01, + 0x0a, 0x1d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, + 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, + 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, + 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, + 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, + 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, + 0x62, 0x75, 0x74, 0x65, 0x73, 0x22, 0x4d, 0x0a, 0x1e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2b, 0x0a, 0x12, 0x77, 0x68, 0x6f, 0x5f, 0x70, + 0x61, 0x79, 0x73, 0x5f, 0x66, 0x6f, 0x72, 0x5f, 0x72, 0x65, 0x61, 0x64, 0x73, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0f, 0x77, 0x68, 0x6f, 0x50, 0x61, 0x79, 0x73, 0x46, 0x6f, 0x72, 0x52, + 0x65, 0x61, 0x64, 0x73, 0x22, 0x9d, 0x01, 0x0a, 0x11, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, + 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, + 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, + 0x12, 0x12, 0x0a, 0x04, 0x64, 0x65, 0x73, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x64, 0x65, 0x73, 0x74, 0x22, 0xd2, 0x01, 0x0a, 0x12, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, + 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, + 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x63, + 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, + 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, + 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, + 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, + 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, + 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xa6, 0x01, 0x0a, 0x13, 0x52, 0x65, + 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, + 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, + 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, 0x65, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6e, 0x65, 0x77, 0x5f, 0x6e, + 0x61, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e, 0x65, 0x77, 0x4e, 0x61, + 0x6d, 0x65, 0x22, 0xd4, 0x01, 0x0a, 0x14, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, + 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, + 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x63, + 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, + 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, + 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4c, 0x65, + 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6f, + 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, + 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0x9b, 0x02, 0x0a, 0x11, 0x55, 0x70, + 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x1e, 0x0a, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, + 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, + 0x61, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, + 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x6e, + 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x6d, 0x65, 0x74, 0x68, + 0x6f, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, + 0x12, 0x1f, 0x0a, 0x0b, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4d, 0x65, 0x74, + 0x61, 0x12, 0x1f, 0x0a, 0x0b, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x6d, 0x65, 0x74, 0x61, + 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x12, 0x1f, 0x0a, 0x0b, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x66, 0x69, 0x6c, + 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, + 0x69, 0x6c, 0x65, 0x12, 0x32, 0x0a, 0x15, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x74, 0x68, + 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x08, 0x20, 0x01, + 0x28, 0x0c, 0x52, 0x13, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, + 0x61, 0x69, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x22, 0xd2, 0x01, 0x0a, 0x12, 0x55, 0x70, 0x6c, 0x6f, + 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, + 0x0a, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x66, 0x69, 0x6c, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, + 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x21, + 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, + 0x68, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x5f, 0x72, 0x6f, 0x6f, 0x74, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, 0x52, 0x6f, + 0x6f, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x6c, 0x65, 0x6e, + 0x67, 0x74, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x75, 0x70, 0x6c, 0x6f, 0x61, + 0x64, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, + 0x64, 0x5f, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, + 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x4f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0xe7, 0x04, 0x0a, + 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x69, + 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x74, + 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x74, 0x78, 0x12, 0x1d, 0x0a, 0x0a, 0x74, + 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x75, 0x73, + 0x65, 0x64, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x75, + 0x73, 0x65, 0x64, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x19, 0x0a, 0x08, 0x6f, 0x77, 0x6e, 0x65, 0x72, + 0x5f, 0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6f, 0x77, 0x6e, 0x65, 0x72, + 0x49, 0x64, 0x12, 0x28, 0x0a, 0x10, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x5f, 0x70, 0x75, 0x62, 0x6c, + 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x6f, 0x77, + 0x6e, 0x65, 0x72, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x1f, 0x0a, 0x0b, + 0x72, 0x65, 0x70, 0x61, 0x69, 0x72, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x72, 0x65, 0x70, 0x61, 0x69, 0x72, 0x65, 0x72, 0x49, 0x64, 0x12, 0x19, 0x0a, + 0x08, 0x70, 0x61, 0x79, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x07, 0x70, 0x61, 0x79, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x65, 0x78, 0x70, 0x69, + 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x65, 0x78, + 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x27, 0x0a, 0x0f, 0x61, 0x6c, 0x6c, 0x6f, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0e, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, + 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x5f, 0x73, 0x69, 0x7a, + 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x53, 0x69, 0x7a, 0x65, 0x12, 0x2a, 0x0a, 0x11, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x5f, + 0x73, 0x69, 0x7a, 0x65, 0x5f, 0x75, 0x73, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x53, 0x69, 0x7a, 0x65, 0x55, 0x73, 0x65, 0x64, + 0x12, 0x2c, 0x0a, 0x12, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x72, 0x65, 0x64, 0x65, 0x65, + 0x6d, 0x65, 0x64, 0x5f, 0x77, 0x6d, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x6c, 0x61, + 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x65, 0x64, 0x57, 0x6d, 0x12, 0x2c, + 0x0a, 0x12, 0x69, 0x73, 0x5f, 0x72, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x5f, 0x72, 0x65, 0x71, 0x75, + 0x69, 0x72, 0x65, 0x64, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x10, 0x69, 0x73, 0x52, 0x65, + 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x64, 0x12, 0x1b, 0x0a, 0x09, + 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x75, 0x6e, 0x69, 0x74, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x08, 0x74, 0x69, 0x6d, 0x65, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x6c, 0x65, + 0x61, 0x6e, 0x65, 0x64, 0x5f, 0x75, 0x70, 0x18, 0x10, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x63, + 0x6c, 0x65, 0x61, 0x6e, 0x65, 0x64, 0x55, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x66, 0x69, 0x6e, 0x61, + 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x18, 0x11, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x66, 0x69, 0x6e, + 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x74, 0x65, 0x72, 0x6d, 0x73, 0x18, + 0x12, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x65, 0x72, 0x6d, 0x52, + 0x05, 0x74, 0x65, 0x72, 0x6d, 0x73, 0x22, 0x9a, 0x01, 0x0a, 0x04, 0x54, 0x65, 0x72, 0x6d, 0x12, + 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, + 0x1d, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x49, 0x64, 0x12, 0x23, + 0x0a, 0x0d, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x49, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x72, 0x65, 0x61, 0x64, 0x5f, 0x70, 0x72, 0x69, 0x63, + 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x72, 0x65, 0x61, 0x64, 0x50, 0x72, 0x69, + 0x63, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, 0x70, 0x72, 0x69, 0x63, + 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x77, 0x72, 0x69, 0x74, 0x65, 0x50, 0x72, + 0x69, 0x63, 0x65, 0x22, 0xaa, 0x01, 0x0a, 0x07, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x66, 0x12, + 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, + 0x79, 0x70, 0x65, 0x12, 0x46, 0x0a, 0x0e, 0x66, 0x69, 0x6c, 0x65, 0x5f, 0x6d, 0x65, 0x74, 0x61, + 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0c, 0x66, + 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x43, 0x0a, 0x0d, 0x64, + 0x69, 0x72, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, + 0x61, 0x74, 0x61, 0x52, 0x0b, 0x64, 0x69, 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x22, 0xc6, 0x06, 0x0a, 0x0c, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x6c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x5f, + 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6c, 0x6f, 0x6f, 0x6b, + 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x12, + 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x68, 0x61, + 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x6e, 0x75, 0x6d, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x73, + 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x6e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1f, + 0x0a, 0x0b, 0x63, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x08, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x4d, 0x65, 0x74, 0x61, 0x12, + 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x48, 0x61, + 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x65, 0x72, 0x6b, 0x6c, 0x65, + 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x72, + 0x6b, 0x6c, 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x28, 0x0a, 0x10, 0x61, 0x63, 0x74, 0x75, 0x61, + 0x6c, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0e, 0x61, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x69, 0x7a, + 0x65, 0x12, 0x28, 0x0a, 0x10, 0x61, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x5f, 0x66, 0x69, 0x6c, 0x65, + 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x61, 0x63, 0x74, + 0x75, 0x61, 0x6c, 0x46, 0x69, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1b, 0x0a, 0x09, 0x6d, + 0x69, 0x6d, 0x65, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x6d, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x25, 0x0a, 0x0e, 0x74, 0x68, 0x75, 0x6d, + 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0d, 0x74, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, + 0x25, 0x0a, 0x0e, 0x74, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x5f, 0x68, 0x61, 0x73, + 0x68, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x74, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, + 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x32, 0x0a, 0x15, 0x61, 0x63, 0x74, 0x75, 0x61, 0x6c, + 0x5f, 0x74, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, + 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x13, 0x61, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x54, 0x68, 0x75, + 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x32, 0x0a, 0x15, 0x61, 0x63, + 0x74, 0x75, 0x61, 0x6c, 0x5f, 0x74, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x5f, 0x68, + 0x61, 0x73, 0x68, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x61, 0x63, 0x74, 0x75, 0x61, + 0x6c, 0x54, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, + 0x0a, 0x0d, 0x65, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, 0x5f, 0x6b, 0x65, 0x79, 0x18, + 0x13, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x65, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x65, 0x64, + 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, + 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, + 0x74, 0x65, 0x73, 0x12, 0x19, 0x0a, 0x08, 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x18, + 0x15, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x6f, 0x6e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x12, 0x4b, + 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x74, 0x78, + 0x6e, 0x73, 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, + 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x0e, 0x63, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x63, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x75, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x8c, 0x02, 0x0a, 0x0b, 0x44, 0x69, + 0x72, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, + 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1f, 0x0a, + 0x0b, 0x6c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x6c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, + 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, + 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x68, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x6e, 0x75, + 0x6d, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x6e, 0x75, 0x6d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x74, + 0x68, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, + 0x74, 0x68, 0x48, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x75, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x75, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x32, 0xcc, 0x12, 0x0a, 0x07, 0x42, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x12, 0x7c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x10, 0x12, 0x0e, 0x2f, 0x76, 0x32, 0x2f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x12, 0x91, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2a, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, - 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x26, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x20, 0x22, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x74, - 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, - 0x2a, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, - 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, - 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, + 0x69, 0x6c, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x89, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x26, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x20, 0x22, 0x1b, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x73, 0x74, 0x61, + 0x74, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, + 0x01, 0x2a, 0x12, 0x85, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, + 0x69, 0x65, 0x73, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, + 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, + 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, + 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, + 0x69, 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, + 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, + 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, + 0x12, 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, + 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, + 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, + 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, + 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, + 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8c, 0x01, 0x0a, 0x0c, 0x44, 0x6f, + 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, + 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, + 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x29, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, + 0x64, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x8a, 0x01, 0x0a, 0x0c, 0x52, 0x65, 0x6e, + 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, + 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, + 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, + 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xca, 0x01, 0x0a, 0x0a, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, + 0x46, 0x69, 0x6c, 0x65, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, + 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x12, 0x1a, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x2f, 0x7b, 0x61, 0x6c, - 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, - 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, + 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x6d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x67, 0x22, 0x1c, 0x2f, 0x76, 0x32, + 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, 0x1a, 0x1c, + 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, + 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, + 0x21, 0x2a, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, + 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, + 0x01, 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, + 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x22, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, + 0x2f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, + 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, + 0x48, 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, + 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, + 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, + 0x75, 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, + 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x28, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, - 0x6c, 0x65, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, - 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x9a, 0x01, 0x0a, 0x10, 0x47, - 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x74, 0x68, 0x12, - 0x2b, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, - 0x65, 0x50, 0x61, 0x74, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x62, - 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, - 0x74, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x25, 0x12, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, 0x66, - 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x70, 0x61, 0x74, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, - 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x4f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x74, 0x72, 0x65, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x12, 0x8c, 0x01, 0x0a, 0x0c, 0x44, 0x6f, 0x77, - 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, - 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, - 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, - 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x29, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x64, - 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x8a, 0x01, 0x0a, 0x0c, 0x52, 0x65, 0x6e, 0x61, - 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, - 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, - 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6e, 0x61, 0x6d, 0x65, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x21, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x72, 0x65, - 0x6e, 0x61, 0x6d, 0x65, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0xca, 0x01, 0x0a, 0x0a, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, - 0x69, 0x6c, 0x65, 0x12, 0x25, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, - 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x6d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x67, 0x22, 0x1c, 0x2f, 0x76, 0x32, 0x2f, - 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, - 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, 0x1a, 0x1c, 0x2f, - 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x5a, 0x21, - 0x2a, 0x1c, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x75, 0x70, 0x6c, 0x6f, 0x61, - 0x64, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, - 0x2a, 0x12, 0x7e, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x2e, 0x62, 0x6c, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, + 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, + 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, + 0x12, 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, + 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, + 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, - 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, - 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, - 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6c, 0x63, 0x75, 0x6c, 0x61, 0x74, 0x65, 0x48, 0x61, 0x73, 0x68, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, - 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x61, 0x6c, 0x63, 0x75, - 0x6c, 0x61, 0x74, 0x65, 0x68, 0x61, 0x73, 0x68, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x94, 0x01, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x12, 0x28, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x4d, 0x65, 0x74, 0x61, 0x54, 0x78, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, 0x22, 0x23, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, - 0x65, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74, 0x78, 0x6e, 0x2f, + 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, + 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, - 0xac, 0x01, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x31, 0x2e, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, - 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x41, - 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x76, 0x32, 0x2f, 0x66, - 0x69, 0x6c, 0x65, 0x2f, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x2f, 0x7b, - 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x82, - 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, - 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, - 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x7d, - 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, - 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, - 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, - 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, - 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x62, - 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, 0x67, - 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, 0x6f, - 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, - 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x82, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x25, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x70, 0x79, 0x4f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x22, 0x1a, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, + 0x63, 0x6f, 0x70, 0x79, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x7d, 0x3a, 0x01, 0x2a, 0x12, 0x90, 0x01, 0x0a, 0x0c, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, + 0x72, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x27, 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, + 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, + 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, + 0x2e, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, 0x72, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, + 0x22, 0x22, 0x2f, 0x76, 0x32, 0x2f, 0x66, 0x69, 0x6c, 0x65, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, + 0x62, 0x6f, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2f, 0x7b, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x7d, 0x3a, 0x01, 0x2a, 0x42, 0x2c, 0x5a, 0x2a, 0x63, 0x6f, 0x64, 0x65, 0x2f, + 0x67, 0x6f, 0x2f, 0x30, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x6e, 0x65, 0x74, 0x2f, 0x62, 0x6c, + 0x6f, 0x62, 0x62, 0x65, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x62, 0x6c, 0x6f, 0x62, 0x62, 0x65, + 0x72, 0x67, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -4210,31 +4216,31 @@ var file_blobber_proto_goTypes = []interface{}{ (*DirMetaData)(nil), // 43: blobber.service.v1.DirMetaData } var file_blobber_proto_depIdxs = []int32{ - 25, // 0: blobber.service.v1.CollaboratorResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 25, // 0: blobber.service.v1.CollaboratorResponse.collaborators:type_name -> blobber.service.v1.Collaborator 16, // 1: blobber.service.v1.CommitResponse.write_marker:type_name -> blobber.service.v1.WriteMarker - 12, // 2: blobber.service.v1.GetObjectTreeResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 16, // 3: blobber.service.v1.GetObjectTreeResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 12, // 4: blobber.service.v1.GetReferencePathResponse.ReferencePath:type_name -> blobber.service.v1.ReferencePath - 16, // 5: blobber.service.v1.GetReferencePathResponse.LatestWM:type_name -> blobber.service.v1.WriteMarker - 41, // 6: blobber.service.v1.ReferencePath.MetaData:type_name -> blobber.service.v1.FileRef - 12, // 7: blobber.service.v1.ReferencePath.List:type_name -> blobber.service.v1.ReferencePath - 15, // 8: blobber.service.v1.GetObjectPathResponse.ObjectPath:type_name -> blobber.service.v1.ObjectPath - 16, // 9: blobber.service.v1.GetObjectPathResponse.LatestWriteMarker:type_name -> blobber.service.v1.WriteMarker - 41, // 10: blobber.service.v1.ObjectPath.Meta:type_name -> blobber.service.v1.FileRef - 41, // 11: blobber.service.v1.ObjectPath.Path:type_name -> blobber.service.v1.FileRef - 41, // 12: blobber.service.v1.ObjectPath.PathList:type_name -> blobber.service.v1.FileRef - 41, // 13: blobber.service.v1.ListEntitiesResponse.MetaData:type_name -> blobber.service.v1.FileRef - 41, // 14: blobber.service.v1.ListEntitiesResponse.Entities:type_name -> blobber.service.v1.FileRef - 41, // 15: blobber.service.v1.GetFileStatsResponse.MetaData:type_name -> blobber.service.v1.FileRef - 21, // 16: blobber.service.v1.GetFileStatsResponse.Stats:type_name -> blobber.service.v1.FileStats - 41, // 17: blobber.service.v1.GetFileMetaDataResponse.MetaData:type_name -> blobber.service.v1.FileRef - 25, // 18: blobber.service.v1.GetFileMetaDataResponse.Collaborators:type_name -> blobber.service.v1.Collaborator + 12, // 2: blobber.service.v1.GetObjectTreeResponse.reference_path:type_name -> blobber.service.v1.ReferencePath + 16, // 3: blobber.service.v1.GetObjectTreeResponse.latest_wm:type_name -> blobber.service.v1.WriteMarker + 12, // 4: blobber.service.v1.GetReferencePathResponse.reference_path:type_name -> blobber.service.v1.ReferencePath + 16, // 5: blobber.service.v1.GetReferencePathResponse.latest_wm:type_name -> blobber.service.v1.WriteMarker + 41, // 6: blobber.service.v1.ReferencePath.meta_data:type_name -> blobber.service.v1.FileRef + 12, // 7: blobber.service.v1.ReferencePath.list:type_name -> blobber.service.v1.ReferencePath + 15, // 8: blobber.service.v1.GetObjectPathResponse.object_path:type_name -> blobber.service.v1.ObjectPath + 16, // 9: blobber.service.v1.GetObjectPathResponse.latest_write_marker:type_name -> blobber.service.v1.WriteMarker + 41, // 10: blobber.service.v1.ObjectPath.meta:type_name -> blobber.service.v1.FileRef + 41, // 11: blobber.service.v1.ObjectPath.path:type_name -> blobber.service.v1.FileRef + 41, // 12: blobber.service.v1.ObjectPath.path_list:type_name -> blobber.service.v1.FileRef + 41, // 13: blobber.service.v1.ListEntitiesResponse.meta_data:type_name -> blobber.service.v1.FileRef + 41, // 14: blobber.service.v1.ListEntitiesResponse.entities:type_name -> blobber.service.v1.FileRef + 41, // 15: blobber.service.v1.GetFileStatsResponse.meta_data:type_name -> blobber.service.v1.FileRef + 21, // 16: blobber.service.v1.GetFileStatsResponse.stats:type_name -> blobber.service.v1.FileStats + 41, // 17: blobber.service.v1.GetFileMetaDataResponse.meta_data:type_name -> blobber.service.v1.FileRef + 25, // 18: blobber.service.v1.GetFileMetaDataResponse.collaborators:type_name -> blobber.service.v1.Collaborator 39, // 19: blobber.service.v1.GetAllocationResponse.allocation:type_name -> blobber.service.v1.Allocation 30, // 20: blobber.service.v1.DownloadFileResponse.latest_rm:type_name -> blobber.service.v1.ReadMaker - 40, // 21: blobber.service.v1.Allocation.Terms:type_name -> blobber.service.v1.Term - 42, // 22: blobber.service.v1.FileRef.FileMetaData:type_name -> blobber.service.v1.FileMetaData - 43, // 23: blobber.service.v1.FileRef.DirMetaData:type_name -> blobber.service.v1.DirMetaData - 24, // 24: blobber.service.v1.FileMetaData.CommitMetaTxns:type_name -> blobber.service.v1.CommitMetaTxn + 40, // 21: blobber.service.v1.Allocation.terms:type_name -> blobber.service.v1.Term + 42, // 22: blobber.service.v1.FileRef.file_meta_data:type_name -> blobber.service.v1.FileMetaData + 43, // 23: blobber.service.v1.FileRef.dir_meta_data:type_name -> blobber.service.v1.DirMetaData + 24, // 24: blobber.service.v1.FileMetaData.commit_meta_txns:type_name -> blobber.service.v1.CommitMetaTxn 26, // 25: blobber.service.v1.Blobber.GetAllocation:input_type -> blobber.service.v1.GetAllocationRequest 22, // 26: blobber.service.v1.Blobber.GetFileMetaData:input_type -> blobber.service.v1.GetFileMetaDataRequest 19, // 27: blobber.service.v1.Blobber.GetFileStats:input_type -> blobber.service.v1.GetFileStatsRequest diff --git a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto index 387832b98..96cfa07c1 100644 --- a/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto +++ b/code/go/0chain.net/blobbercore/blobbergrpc/proto/blobber.proto @@ -124,7 +124,7 @@ message CollaboratorRequest { message CollaboratorResponse { string message = 1; - repeated Collaborator Collaborators = 2; + repeated Collaborator collaborators = 2; } message CalculateHashRequest { @@ -168,52 +168,52 @@ message GetObjectTreeRequest { string allocation = 2; } message GetObjectTreeResponse { - ReferencePath ReferencePath = 1; - WriteMarker LatestWM = 2; + ReferencePath reference_path = 1; + WriteMarker latest_wm = 2; } message GetReferencePathRequest { - string Paths = 1; - string Path = 2; + string paths = 1; + string path = 2; string allocation = 3; } message GetReferencePathResponse { - ReferencePath ReferencePath = 1; - WriteMarker LatestWM = 2; + ReferencePath reference_path = 1; + WriteMarker latest_wm = 2; } message ReferencePath { - FileRef MetaData = 1; - repeated ReferencePath List = 2; + FileRef meta_data = 1; + repeated ReferencePath list = 2; } message GetObjectPathRequest { string allocation = 1; - string Path = 2; - string BlockNum = 3; + string path = 2; + string block_num = 3; } message GetObjectPathResponse { - ObjectPath ObjectPath = 1; - WriteMarker LatestWriteMarker = 2; + ObjectPath object_path = 1; + WriteMarker latest_write_marker = 2; } message ObjectPath { - string RootHash = 1; - FileRef Meta = 2; - FileRef Path = 3; - repeated FileRef PathList = 4; - int64 FileBlockNum = 5; + string root_hash = 1; + FileRef meta = 2; + FileRef path = 3; + repeated FileRef path_list = 4; + int64 file_block_num = 5; } message WriteMarker { - string AllocationRoot = 1; - string PreviousAllocationRoot = 2; - string AllocationID = 3; - int64 Size = 4; - string BlobberID = 5; - int64 Timestamp = 6; - string ClientID = 7; - string Signature = 8; + string allocation_root = 1; + string previous_allocation_root = 2; + string allocation_id = 3; + int64 size = 4; + string blobber_id = 5; + int64 timestamp = 6; + string client_id = 7; + string signature = 8; } message ListEntitiesRequest { @@ -224,9 +224,9 @@ message ListEntitiesRequest { } message ListEntitiesResponse { - string AllocationRoot = 1; - FileRef MetaData = 2; - repeated FileRef Entities = 3; + string allocation_root = 1; + FileRef meta_data = 2; + repeated FileRef entities = 3; } message GetFileStatsRequest { @@ -236,21 +236,21 @@ message GetFileStatsRequest { } message GetFileStatsResponse { - FileRef MetaData = 1; - FileStats Stats = 2; + FileRef meta_data = 1; + FileStats stats = 2; } message FileStats { - int64 ID = 1; - int64 RefID = 2; - int64 NumUpdates = 3; - int64 NumBlockDownloads = 4; - int64 SuccessChallenges = 5; - int64 FailedChallenges = 6; - string LastChallengeResponseTxn = 7; - string WriteMarkerRedeemTxn = 8; - int64 CreatedAt = 9; - int64 UpdatedAt = 10; + int64 id = 1; + int64 ref_id = 2; + int64 num_updates = 3; + int64 num_block_downloads = 4; + int64 success_challenges = 5; + int64 failed_challenges = 6; + string last_challenge_response_txn = 7; + string write_marker_redeem_txn = 8; + int64 created_at = 9; + int64 updated_at = 10; } message GetFileMetaDataRequest { @@ -261,20 +261,20 @@ message GetFileMetaDataRequest { } message GetFileMetaDataResponse { - FileRef MetaData = 1; - repeated Collaborator Collaborators = 2; + FileRef meta_data = 1; + repeated Collaborator collaborators = 2; } message CommitMetaTxn { - int64 RefId = 1; - string TxnId = 2; - int64 CreatedAt = 3; + int64 ref_id = 1; + string txn_id = 2; + int64 created_at = 3; } message Collaborator { - int64 RefId = 1; - string ClientId = 2; - int64 CreatedAt = 3; + int64 ref_id = 1; + string client_id = 2; + int64 created_at = 3; } message GetAllocationRequest { @@ -387,76 +387,76 @@ message UploadFileResponse { } message Allocation { - string ID = 1; - string Tx = 2; - int64 TotalSize = 3; - int64 UsedSize = 4; - string OwnerID = 5; - string OwnerPublicKey = 6; - string RepairerID = 7; - string PayerID = 8; - int64 Expiration = 9; - string AllocationRoot = 10; - int64 BlobberSize = 11; - int64 BlobberSizeUsed = 12; - string LatestRedeemedWM = 13; - bool IsRedeemRequired = 14; - int64 TimeUnit = 15; - bool CleanedUp = 16; - bool Finalized = 17; - repeated Term Terms = 18; + string id = 1; + string tx = 2; + int64 total_size = 3; + int64 used_size = 4; + string owner_id = 5; + string owner_public_key = 6; + string repairer_id = 7; + string payer_id = 8; + int64 expiration = 9; + string allocation_root = 10; + int64 blobber_size = 11; + int64 blobber_size_used = 12; + string latest_redeemed_wm = 13; + bool is_redeem_required = 14; + int64 time_unit = 15; + bool cleaned_up = 16; + bool finalized = 17; + repeated Term terms = 18; } message Term { - int64 ID = 1; - string BlobberID = 2; - string AllocationID = 3; - int64 ReadPrice = 4; - int64 WritePrice = 5; + int64 id = 1; + string blobber_id = 2; + string allocation_id = 3; + int64 read_price = 4; + int64 write_price = 5; } message FileRef { - string Type = 1; - FileMetaData FileMetaData = 2; - DirMetaData DirMetaData = 3; + string type = 1; + FileMetaData file_meta_data = 2; + DirMetaData dir_meta_data = 3; } message FileMetaData { - string Type = 1; - string LookupHash = 2; - string Name = 3; - string Path = 4; - string Hash = 5; - int64 NumBlocks = 6; - string PathHash = 7; - string CustomMeta = 8; - string ContentHash = 9; - int64 Size = 10; - string MerkleRoot = 11; - int64 ActualFileSize = 12; - string ActualFileHash = 13; - string MimeType = 14; - int64 ThumbnailSize = 15; - string ThumbnailHash = 16; - int64 ActualThumbnailSize = 17; - string ActualThumbnailHash = 18; - string EncryptedKey = 19; - bytes Attributes = 20; - bool OnCloud = 21; - repeated CommitMetaTxn CommitMetaTxns = 22; - int64 CreatedAt = 23; - int64 UpdatedAt = 24; + string type = 1; + string lookup_hash = 2; + string name = 3; + string path = 4; + string hash = 5; + int64 num_blocks = 6; + string path_hash = 7; + string custom_meta = 8; + string content_hash = 9; + int64 size = 10; + string merkle_root = 11; + int64 actual_file_size = 12; + string actual_file_hash = 13; + string mime_type = 14; + int64 thumbnail_size = 15; + string thumbnail_hash = 16; + int64 actual_thumbnail_size = 17; + string actual_thumbnail_hash = 18; + string encrypted_key = 19; + bytes attributes = 20; + bool on_cloud = 21; + repeated CommitMetaTxn commit_meta_txns = 22; + int64 created_at = 23; + int64 updated_at = 24; } message DirMetaData { - string Type = 1; - string LookupHash = 2; - string Name = 3; - string Path = 4; - string Hash = 5; - int64 NumBlocks = 6; - string PathHash = 7; - int64 Size = 8; - int64 CreatedAt = 9; - int64 UpdatedAt = 10; + string type = 1; + string lookup_hash = 2; + string name = 3; + string path = 4; + string hash = 5; + int64 num_blocks = 6; + string path_hash = 7; + int64 size = 8; + int64 created_at = 9; + int64 updated_at = 10; } \ No newline at end of file diff --git a/code/go/0chain.net/blobbercore/convert/convert.go b/code/go/0chain.net/blobbercore/convert/convert.go index 4670703cd..7e5867596 100644 --- a/code/go/0chain.net/blobbercore/convert/convert.go +++ b/code/go/0chain.net/blobbercore/convert/convert.go @@ -4,12 +4,13 @@ import ( "bytes" "context" "encoding/json" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" "mime/multipart" "net/http" "strings" "time" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/readmarker" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/datastore" @@ -27,31 +28,31 @@ func AllocationToGRPCAllocation(alloc *allocation.Allocation) *blobbergrpc.Alloc terms := make([]*blobbergrpc.Term, 0, len(alloc.Terms)) for _, t := range alloc.Terms { terms = append(terms, &blobbergrpc.Term{ - ID: t.ID, - BlobberID: t.BlobberID, - AllocationID: t.AllocationID, + Id: t.ID, + BlobberId: t.BlobberID, + AllocationId: t.AllocationID, ReadPrice: t.ReadPrice, WritePrice: t.WritePrice, }) } return &blobbergrpc.Allocation{ - ID: alloc.ID, + Id: alloc.ID, Tx: alloc.Tx, TotalSize: alloc.TotalSize, UsedSize: alloc.UsedSize, - OwnerID: alloc.OwnerID, + OwnerId: alloc.OwnerID, OwnerPublicKey: alloc.OwnerPublicKey, Expiration: int64(alloc.Expiration), AllocationRoot: alloc.AllocationRoot, BlobberSize: alloc.BlobberSize, BlobberSizeUsed: alloc.BlobberSizeUsed, - LatestRedeemedWM: alloc.LatestRedeemedWM, + LatestRedeemedWm: alloc.LatestRedeemedWM, IsRedeemRequired: alloc.IsRedeemRequired, TimeUnit: int64(alloc.TimeUnit), CleanedUp: alloc.CleanedUp, Finalized: alloc.Finalized, Terms: terms, - PayerID: alloc.PayerID, + PayerId: alloc.PayerID, } } @@ -63,31 +64,31 @@ func GRPCAllocationToAllocation(alloc *blobbergrpc.Allocation) *allocation.Alloc terms := make([]*allocation.Terms, 0, len(alloc.Terms)) for _, t := range alloc.Terms { terms = append(terms, &allocation.Terms{ - ID: t.ID, - BlobberID: t.BlobberID, - AllocationID: t.AllocationID, + ID: t.Id, + BlobberID: t.BlobberId, + AllocationID: t.AllocationId, ReadPrice: t.ReadPrice, WritePrice: t.WritePrice, }) } return &allocation.Allocation{ - ID: alloc.ID, + ID: alloc.Id, Tx: alloc.Tx, TotalSize: alloc.TotalSize, UsedSize: alloc.UsedSize, - OwnerID: alloc.OwnerID, + OwnerID: alloc.OwnerId, OwnerPublicKey: alloc.OwnerPublicKey, Expiration: common.Timestamp(alloc.Expiration), AllocationRoot: alloc.AllocationRoot, BlobberSize: alloc.BlobberSize, BlobberSizeUsed: alloc.BlobberSizeUsed, - LatestRedeemedWM: alloc.LatestRedeemedWM, + LatestRedeemedWM: alloc.LatestRedeemedWm, IsRedeemRequired: alloc.IsRedeemRequired, TimeUnit: time.Duration(alloc.TimeUnit), CleanedUp: alloc.CleanedUp, Finalized: alloc.Finalized, Terms: terms, - PayerID: alloc.PayerID, + PayerID: alloc.PayerId, } } @@ -97,8 +98,8 @@ func FileStatsToFileStatsGRPC(fileStats *stats.FileStats) *blobbergrpc.FileStats } return &blobbergrpc.FileStats{ - ID: fileStats.ID, - RefID: fileStats.RefID, + Id: fileStats.ID, + RefId: fileStats.RefID, NumUpdates: fileStats.NumUpdates, NumBlockDownloads: fileStats.NumBlockDownloads, SuccessChallenges: fileStats.SuccessChallenges, @@ -118,11 +119,11 @@ func WriteMarkerToWriteMarkerGRPC(wm *writemarker.WriteMarker) *blobbergrpc.Writ return &blobbergrpc.WriteMarker{ AllocationRoot: wm.AllocationRoot, PreviousAllocationRoot: wm.PreviousAllocationRoot, - AllocationID: wm.AllocationID, + AllocationId: wm.AllocationID, Size: wm.Size, - BlobberID: wm.BlobberID, + BlobberId: wm.BlobberID, Timestamp: int64(wm.Timestamp), - ClientID: wm.ClientID, + ClientId: wm.ClientID, Signature: wm.Signature, } } @@ -135,11 +136,11 @@ func WriteMarkerGRPCToWriteMarker(wm *blobbergrpc.WriteMarker) *writemarker.Writ return &writemarker.WriteMarker{ AllocationRoot: wm.AllocationRoot, PreviousAllocationRoot: wm.PreviousAllocationRoot, - AllocationID: wm.AllocationID, + AllocationID: wm.AllocationId, Size: wm.Size, - BlobberID: wm.BlobberID, + BlobberID: wm.BlobberId, Timestamp: common.Timestamp(wm.Timestamp), - ClientID: wm.ClientID, + ClientID: wm.ClientId, Signature: wm.Signature, } } @@ -190,8 +191,8 @@ func FileStatsGRPCToFileStats(fileStats *blobbergrpc.FileStats) *stats.FileStats } return &stats.FileStats{ - ID: fileStats.ID, - RefID: fileStats.RefID, + ID: fileStats.Id, + RefID: fileStats.RefId, NumUpdates: fileStats.NumUpdates, NumBlockDownloads: fileStats.NumBlockDownloads, SuccessChallenges: fileStats.SuccessChallenges, diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/responseHandler.go index 602a21dbb..951fbdb0b 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/responseHandler.go @@ -84,7 +84,7 @@ func GetReferencePathResponseCreator(r interface{}) *blobbergrpc.GetReferencePat var resp blobbergrpc.GetReferencePathResponse var recursionCount int - resp.LatestWM = WriteMarkerToWriteMarkerGRPC(httpResp.LatestWM) + resp.LatestWm = WriteMarkerToWriteMarkerGRPC(httpResp.LatestWM) resp.ReferencePath = ReferencePathToReferencePathGRPC(&recursionCount, httpResp.ReferencePath) return &resp } @@ -98,7 +98,7 @@ func GetObjectTreeResponseCreator(r interface{}) *blobbergrpc.GetObjectTreeRespo var resp blobbergrpc.GetObjectTreeResponse var recursionCount int - resp.LatestWM = WriteMarkerToWriteMarkerGRPC(httpResp.LatestWM) + resp.LatestWm = WriteMarkerToWriteMarkerGRPC(httpResp.LatestWM) resp.ReferencePath = ReferencePathToReferencePathGRPC(&recursionCount, httpResp.ReferencePath) return &resp } @@ -255,7 +255,7 @@ func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetRe var recursionCount int return &blobberhttp.ReferencePathResult{ ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getReferencePathResponse.ReferencePath), - LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWM), + LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWm), } } @@ -283,7 +283,7 @@ func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTr var recursionCount int return &blobberhttp.ReferencePathResult{ ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getObjectTreeResponse.ReferencePath), - LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWM), + LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWm), } } diff --git a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json index e144b150c..782dac581 100644 --- a/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json +++ b/code/go/0chain.net/blobbercore/openapi/blobber.swagger.json @@ -423,13 +423,13 @@ "type": "string" }, { - "name": "Path", + "name": "path", "in": "query", "required": false, "type": "string" }, { - "name": "BlockNum", + "name": "blockNum", "in": "query", "required": false, "type": "string" @@ -501,13 +501,13 @@ "type": "string" }, { - "name": "Paths", + "name": "paths", "in": "query", "required": false, "type": "string" }, { - "name": "Path", + "name": "path", "in": "query", "required": false, "type": "string" @@ -739,64 +739,64 @@ "v1Allocation": { "type": "object", "properties": { - "ID": { + "id": { "type": "string" }, - "Tx": { + "tx": { "type": "string" }, - "TotalSize": { + "totalSize": { "type": "string", "format": "int64" }, - "UsedSize": { + "usedSize": { "type": "string", "format": "int64" }, - "OwnerID": { + "ownerId": { "type": "string" }, - "OwnerPublicKey": { + "ownerPublicKey": { "type": "string" }, - "RepairerID": { + "repairerId": { "type": "string" }, - "PayerID": { + "payerId": { "type": "string" }, - "Expiration": { + "expiration": { "type": "string", "format": "int64" }, - "AllocationRoot": { + "allocationRoot": { "type": "string" }, - "BlobberSize": { + "blobberSize": { "type": "string", "format": "int64" }, - "BlobberSizeUsed": { + "blobberSizeUsed": { "type": "string", "format": "int64" }, - "LatestRedeemedWM": { + "latestRedeemedWm": { "type": "string" }, - "IsRedeemRequired": { + "isRedeemRequired": { "type": "boolean" }, - "TimeUnit": { + "timeUnit": { "type": "string", "format": "int64" }, - "CleanedUp": { + "cleanedUp": { "type": "boolean" }, - "Finalized": { + "finalized": { "type": "boolean" }, - "Terms": { + "terms": { "type": "array", "items": { "$ref": "#/definitions/v1Term" @@ -829,14 +829,14 @@ "v1Collaborator": { "type": "object", "properties": { - "RefId": { + "refId": { "type": "string", "format": "int64" }, - "ClientId": { + "clientId": { "type": "string" }, - "CreatedAt": { + "createdAt": { "type": "string", "format": "int64" } @@ -868,7 +868,7 @@ "message": { "type": "string" }, - "Collaborators": { + "collaborators": { "type": "array", "items": { "$ref": "#/definitions/v1Collaborator" @@ -879,14 +879,14 @@ "v1CommitMetaTxn": { "type": "object", "properties": { - "RefId": { + "refId": { "type": "string", "format": "int64" }, - "TxnId": { + "txnId": { "type": "string" }, - "CreatedAt": { + "createdAt": { "type": "string", "format": "int64" } @@ -1002,37 +1002,37 @@ "v1DirMetaData": { "type": "object", "properties": { - "Type": { + "type": { "type": "string" }, - "LookupHash": { + "lookupHash": { "type": "string" }, - "Name": { + "name": { "type": "string" }, - "Path": { + "path": { "type": "string" }, - "Hash": { + "hash": { "type": "string" }, - "NumBlocks": { + "numBlocks": { "type": "string", "format": "int64" }, - "PathHash": { + "pathHash": { "type": "string" }, - "Size": { + "size": { "type": "string", "format": "int64" }, - "CreatedAt": { + "createdAt": { "type": "string", "format": "int64" }, - "UpdatedAt": { + "updatedAt": { "type": "string", "format": "int64" } @@ -1094,86 +1094,86 @@ "v1FileMetaData": { "type": "object", "properties": { - "Type": { + "type": { "type": "string" }, - "LookupHash": { + "lookupHash": { "type": "string" }, - "Name": { + "name": { "type": "string" }, - "Path": { + "path": { "type": "string" }, - "Hash": { + "hash": { "type": "string" }, - "NumBlocks": { + "numBlocks": { "type": "string", "format": "int64" }, - "PathHash": { + "pathHash": { "type": "string" }, - "CustomMeta": { + "customMeta": { "type": "string" }, - "ContentHash": { + "contentHash": { "type": "string" }, - "Size": { + "size": { "type": "string", "format": "int64" }, - "MerkleRoot": { + "merkleRoot": { "type": "string" }, - "ActualFileSize": { + "actualFileSize": { "type": "string", "format": "int64" }, - "ActualFileHash": { + "actualFileHash": { "type": "string" }, - "MimeType": { + "mimeType": { "type": "string" }, - "ThumbnailSize": { + "thumbnailSize": { "type": "string", "format": "int64" }, - "ThumbnailHash": { + "thumbnailHash": { "type": "string" }, - "ActualThumbnailSize": { + "actualThumbnailSize": { "type": "string", "format": "int64" }, - "ActualThumbnailHash": { + "actualThumbnailHash": { "type": "string" }, - "EncryptedKey": { + "encryptedKey": { "type": "string" }, - "Attributes": { + "attributes": { "type": "string", "format": "byte" }, - "OnCloud": { + "onCloud": { "type": "boolean" }, - "CommitMetaTxns": { + "commitMetaTxns": { "type": "array", "items": { "$ref": "#/definitions/v1CommitMetaTxn" } }, - "CreatedAt": { + "createdAt": { "type": "string", "format": "int64" }, - "UpdatedAt": { + "updatedAt": { "type": "string", "format": "int64" } @@ -1182,13 +1182,13 @@ "v1FileRef": { "type": "object", "properties": { - "Type": { + "type": { "type": "string" }, - "FileMetaData": { + "fileMetaData": { "$ref": "#/definitions/v1FileMetaData" }, - "DirMetaData": { + "dirMetaData": { "$ref": "#/definitions/v1DirMetaData" } } @@ -1196,41 +1196,41 @@ "v1FileStats": { "type": "object", "properties": { - "ID": { + "id": { "type": "string", "format": "int64" }, - "RefID": { + "refId": { "type": "string", "format": "int64" }, - "NumUpdates": { + "numUpdates": { "type": "string", "format": "int64" }, - "NumBlockDownloads": { + "numBlockDownloads": { "type": "string", "format": "int64" }, - "SuccessChallenges": { + "successChallenges": { "type": "string", "format": "int64" }, - "FailedChallenges": { + "failedChallenges": { "type": "string", "format": "int64" }, - "LastChallengeResponseTxn": { + "lastChallengeResponseTxn": { "type": "string" }, - "WriteMarkerRedeemTxn": { + "writeMarkerRedeemTxn": { "type": "string" }, - "CreatedAt": { + "createdAt": { "type": "string", "format": "int64" }, - "UpdatedAt": { + "updatedAt": { "type": "string", "format": "int64" } @@ -1264,10 +1264,10 @@ "v1GetFileMetaDataResponse": { "type": "object", "properties": { - "MetaData": { + "metaData": { "$ref": "#/definitions/v1FileRef" }, - "Collaborators": { + "collaborators": { "type": "array", "items": { "$ref": "#/definitions/v1Collaborator" @@ -1292,10 +1292,10 @@ "v1GetFileStatsResponse": { "type": "object", "properties": { - "MetaData": { + "metaData": { "$ref": "#/definitions/v1FileRef" }, - "Stats": { + "stats": { "$ref": "#/definitions/v1FileStats" } } @@ -1303,10 +1303,10 @@ "v1GetObjectPathResponse": { "type": "object", "properties": { - "ObjectPath": { + "objectPath": { "$ref": "#/definitions/v1ObjectPath" }, - "LatestWriteMarker": { + "latestWriteMarker": { "$ref": "#/definitions/v1WriteMarker" } } @@ -1314,10 +1314,10 @@ "v1GetObjectTreeResponse": { "type": "object", "properties": { - "ReferencePath": { + "referencePath": { "$ref": "#/definitions/v1ReferencePath" }, - "LatestWM": { + "latestWm": { "$ref": "#/definitions/v1WriteMarker" } } @@ -1325,10 +1325,10 @@ "v1GetReferencePathResponse": { "type": "object", "properties": { - "ReferencePath": { + "referencePath": { "$ref": "#/definitions/v1ReferencePath" }, - "LatestWM": { + "latestWm": { "$ref": "#/definitions/v1WriteMarker" } } @@ -1336,13 +1336,13 @@ "v1ListEntitiesResponse": { "type": "object", "properties": { - "AllocationRoot": { + "allocationRoot": { "type": "string" }, - "MetaData": { + "metaData": { "$ref": "#/definitions/v1FileRef" }, - "Entities": { + "entities": { "type": "array", "items": { "$ref": "#/definitions/v1FileRef" @@ -1353,22 +1353,22 @@ "v1ObjectPath": { "type": "object", "properties": { - "RootHash": { + "rootHash": { "type": "string" }, - "Meta": { + "meta": { "$ref": "#/definitions/v1FileRef" }, - "Path": { + "path": { "$ref": "#/definitions/v1FileRef" }, - "PathList": { + "pathList": { "type": "array", "items": { "$ref": "#/definitions/v1FileRef" } }, - "FileBlockNum": { + "fileBlockNum": { "type": "string", "format": "int64" } @@ -1419,10 +1419,10 @@ "v1ReferencePath": { "type": "object", "properties": { - "MetaData": { + "metaData": { "$ref": "#/definitions/v1FileRef" }, - "List": { + "list": { "type": "array", "items": { "$ref": "#/definitions/v1ReferencePath" @@ -1481,21 +1481,21 @@ "v1Term": { "type": "object", "properties": { - "ID": { + "id": { "type": "string", "format": "int64" }, - "BlobberID": { + "blobberId": { "type": "string" }, - "AllocationID": { + "allocationId": { "type": "string" }, - "ReadPrice": { + "readPrice": { "type": "string", "format": "int64" }, - "WritePrice": { + "writePrice": { "type": "string", "format": "int64" } @@ -1592,30 +1592,30 @@ "v1WriteMarker": { "type": "object", "properties": { - "AllocationRoot": { + "allocationRoot": { "type": "string" }, - "PreviousAllocationRoot": { + "previousAllocationRoot": { "type": "string" }, - "AllocationID": { + "allocationId": { "type": "string" }, - "Size": { + "size": { "type": "string", "format": "int64" }, - "BlobberID": { + "blobberId": { "type": "string" }, - "Timestamp": { + "timestamp": { "type": "string", "format": "int64" }, - "ClientID": { + "clientId": { "type": "string" }, - "Signature": { + "signature": { "type": "string" } } From 70cb70a37d1ac00963c8a39596ba69d18a219570 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 17:59:26 +0530 Subject: [PATCH 179/183] :art: created new file for response creator functions --- ...responseHandler.go => response_creator.go} | 155 +---------------- .../blobbercore/convert/response_handler.go | 162 ++++++++++++++++++ 2 files changed, 163 insertions(+), 154 deletions(-) rename code/go/0chain.net/blobbercore/convert/{responseHandler.go => response_creator.go} (58%) create mode 100644 code/go/0chain.net/blobbercore/convert/response_handler.go diff --git a/code/go/0chain.net/blobbercore/convert/responseHandler.go b/code/go/0chain.net/blobbercore/convert/response_creator.go similarity index 58% rename from code/go/0chain.net/blobbercore/convert/responseHandler.go rename to code/go/0chain.net/blobbercore/convert/response_creator.go index 951fbdb0b..74e98f320 100644 --- a/code/go/0chain.net/blobbercore/convert/responseHandler.go +++ b/code/go/0chain.net/blobbercore/convert/response_creator.go @@ -1,17 +1,13 @@ package convert import ( - "context" "encoding/json" - "github.com/0chain/blobber/code/go/0chain.net/core/common" - - stats2 "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" - "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberhttp" "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" + stats2 "github.com/0chain/blobber/code/go/0chain.net/blobbercore/stats" ) func GetAllocationResponseCreator(resp interface{}) *blobbergrpc.GetAllocationResponse { @@ -207,155 +203,6 @@ func CopyObjectResponseCreator(r interface{}) *blobbergrpc.CopyObjectResponse { } } -func GetAllocationResponseHandler(resp *blobbergrpc.GetAllocationResponse) *allocation.Allocation { - return GRPCAllocationToAllocation(resp.Allocation) -} - -func GetFileMetaDataResponseHandler(resp *blobbergrpc.GetFileMetaDataResponse) map[string]interface{} { - var collaborators []reference.Collaborator - for _, c := range resp.Collaborators { - collaborators = append(collaborators, *GRPCCollaboratorToCollaborator(c)) - } - - result := FileRefGRPCToFileRef(resp.MetaData).GetListingData(context.Background()) - result["collaborators"] = collaborators - return result -} - -func GetFileStatsResponseHandler(resp *blobbergrpc.GetFileStatsResponse) map[string]interface{} { - ctx := context.Background() - result := FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx) - - statsMap := make(map[string]interface{}) - statsBytes, _ := json.Marshal(FileStatsGRPCToFileStats(resp.Stats)) - _ = json.Unmarshal(statsBytes, &statsMap) - - for k, v := range statsMap { - result[k] = v - } - - return result -} - -func ListEntitesResponseHandler(resp *blobbergrpc.ListEntitiesResponse) *blobberhttp.ListResult { - ctx := context.Background() - var entities []map[string]interface{} - for i := range resp.Entities { - entities = append(entities, FileRefGRPCToFileRef(resp.Entities[i]).GetListingData(ctx)) - } - - return &blobberhttp.ListResult{ - AllocationRoot: resp.AllocationRoot, - Meta: FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx), - Entities: entities, - } -} - -func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetReferencePathResponse) *blobberhttp.ReferencePathResult { - var recursionCount int - return &blobberhttp.ReferencePathResult{ - ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getReferencePathResponse.ReferencePath), - LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWm), - } -} - -func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPathResponse) *blobberhttp.ObjectPathResult { - ctx := context.Background() - path := FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Path).GetListingData(ctx) - var pathList []map[string]interface{} - for _, pl := range getObjectPathResponse.ObjectPath.PathList { - pathList = append(pathList, FileRefGRPCToFileRef(pl).GetListingData(ctx)) - } - path["list"] = pathList - - return &blobberhttp.ObjectPathResult{ - ObjectPath: &reference.ObjectPath{ - RootHash: getObjectPathResponse.ObjectPath.RootHash, - Meta: FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Meta).GetListingData(ctx), - Path: path, - FileBlockNum: getObjectPathResponse.ObjectPath.FileBlockNum, - }, - LatestWM: WriteMarkerGRPCToWriteMarker(getObjectPathResponse.LatestWriteMarker), - } -} - -func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTreeResponse) *blobberhttp.ReferencePathResult { - var recursionCount int - return &blobberhttp.ReferencePathResult{ - ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getObjectTreeResponse.ReferencePath), - LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWm), - } -} - -func CommitWriteResponseHandler(resp *blobbergrpc.CommitResponse) *blobberhttp.CommitResult { - return &blobberhttp.CommitResult{ - AllocationRoot: resp.AllocationRoot, - WriteMarker: WriteMarkerGRPCToWriteMarker(resp.WriteMarker), - Success: resp.Success, - ErrorMessage: resp.ErrorMessage, - } -} - -func GetCalculateHashResponseHandler(response *blobbergrpc.CalculateHashResponse) interface{} { - result := make(map[string]interface{}) - if msg := response.GetMessage(); msg != "" { - result["msg"] = msg - } - - return result -} - -func GetCommitMetaTxnHandlerResponse(response *blobbergrpc.CommitMetaTxnResponse) interface{} { - msg := response.GetMessage() - if msg == "" { - return nil - } - - result := struct { - Msg string `json:"msg"` - }{ - Msg: msg, - } - - return result -} - -func CollaboratorResponse(response *blobbergrpc.CollaboratorResponse) interface{} { - if msg := response.GetMessage(); msg != "" { - return struct { - Msg string `json:"msg"` - }{Msg: msg} - } - - if collaborators := response.GetCollaborators(); collaborators != nil { - collabs := make([]reference.Collaborator, 0, len(collaborators)) - for _, c := range collaborators { - collabs = append(collabs, *GRPCCollaboratorToCollaborator(c)) - } - - return collabs - } - - return nil -} - -func UpdateObjectAttributesResponseHandler(updateAttributesResponse *blobbergrpc.UpdateObjectAttributesResponse) *blobberhttp.UpdateObjectAttributesResponse { - return &blobberhttp.UpdateObjectAttributesResponse{ - WhoPaysForReads: common.WhoPays(updateAttributesResponse.WhoPaysForReads), - } -} - -func CopyObjectResponseHandler(copyObjectResponse *blobbergrpc.CopyObjectResponse) *blobberhttp.UploadResult { - return &blobberhttp.UploadResult{ - Filename: copyObjectResponse.Filename, - Size: copyObjectResponse.Size, - Hash: copyObjectResponse.ContentHash, - MerkleRoot: copyObjectResponse.MerkleRoot, - UploadLength: copyObjectResponse.UploadLength, - UploadOffset: copyObjectResponse.UploadOffset, - } -} - func RenameObjectResponseCreator(r interface{}) *blobbergrpc.RenameObjectResponse { if r == nil { return nil diff --git a/code/go/0chain.net/blobbercore/convert/response_handler.go b/code/go/0chain.net/blobbercore/convert/response_handler.go new file mode 100644 index 000000000..88f5f3b8f --- /dev/null +++ b/code/go/0chain.net/blobbercore/convert/response_handler.go @@ -0,0 +1,162 @@ +package convert + +import ( + "context" + "encoding/json" + + "github.com/0chain/blobber/code/go/0chain.net/core/common" + + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/allocation" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobbergrpc" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/blobberhttp" + "github.com/0chain/blobber/code/go/0chain.net/blobbercore/reference" +) + +func GetAllocationResponseHandler(resp *blobbergrpc.GetAllocationResponse) *allocation.Allocation { + return GRPCAllocationToAllocation(resp.Allocation) +} + +func GetFileMetaDataResponseHandler(resp *blobbergrpc.GetFileMetaDataResponse) map[string]interface{} { + var collaborators []reference.Collaborator + for _, c := range resp.Collaborators { + collaborators = append(collaborators, *GRPCCollaboratorToCollaborator(c)) + } + + result := FileRefGRPCToFileRef(resp.MetaData).GetListingData(context.Background()) + result["collaborators"] = collaborators + return result +} + +func GetFileStatsResponseHandler(resp *blobbergrpc.GetFileStatsResponse) map[string]interface{} { + ctx := context.Background() + result := FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx) + + statsMap := make(map[string]interface{}) + statsBytes, _ := json.Marshal(FileStatsGRPCToFileStats(resp.Stats)) + _ = json.Unmarshal(statsBytes, &statsMap) + + for k, v := range statsMap { + result[k] = v + } + + return result +} + +func ListEntitesResponseHandler(resp *blobbergrpc.ListEntitiesResponse) *blobberhttp.ListResult { + ctx := context.Background() + var entities []map[string]interface{} + for i := range resp.Entities { + entities = append(entities, FileRefGRPCToFileRef(resp.Entities[i]).GetListingData(ctx)) + } + + return &blobberhttp.ListResult{ + AllocationRoot: resp.AllocationRoot, + Meta: FileRefGRPCToFileRef(resp.MetaData).GetListingData(ctx), + Entities: entities, + } +} + +func GetReferencePathResponseHandler(getReferencePathResponse *blobbergrpc.GetReferencePathResponse) *blobberhttp.ReferencePathResult { + var recursionCount int + return &blobberhttp.ReferencePathResult{ + ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getReferencePathResponse.ReferencePath), + LatestWM: WriteMarkerGRPCToWriteMarker(getReferencePathResponse.LatestWm), + } +} + +func GetObjectPathResponseHandler(getObjectPathResponse *blobbergrpc.GetObjectPathResponse) *blobberhttp.ObjectPathResult { + ctx := context.Background() + path := FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Path).GetListingData(ctx) + var pathList []map[string]interface{} + for _, pl := range getObjectPathResponse.ObjectPath.PathList { + pathList = append(pathList, FileRefGRPCToFileRef(pl).GetListingData(ctx)) + } + path["list"] = pathList + + return &blobberhttp.ObjectPathResult{ + ObjectPath: &reference.ObjectPath{ + RootHash: getObjectPathResponse.ObjectPath.RootHash, + Meta: FileRefGRPCToFileRef(getObjectPathResponse.ObjectPath.Meta).GetListingData(ctx), + Path: path, + FileBlockNum: getObjectPathResponse.ObjectPath.FileBlockNum, + }, + LatestWM: WriteMarkerGRPCToWriteMarker(getObjectPathResponse.LatestWriteMarker), + } +} + +func GetObjectTreeResponseHandler(getObjectTreeResponse *blobbergrpc.GetObjectTreeResponse) *blobberhttp.ReferencePathResult { + var recursionCount int + return &blobberhttp.ReferencePathResult{ + ReferencePath: ReferencePathGRPCToReferencePath(&recursionCount, getObjectTreeResponse.ReferencePath), + LatestWM: WriteMarkerGRPCToWriteMarker(getObjectTreeResponse.LatestWm), + } +} + +func CommitWriteResponseHandler(resp *blobbergrpc.CommitResponse) *blobberhttp.CommitResult { + return &blobberhttp.CommitResult{ + AllocationRoot: resp.AllocationRoot, + WriteMarker: WriteMarkerGRPCToWriteMarker(resp.WriteMarker), + Success: resp.Success, + ErrorMessage: resp.ErrorMessage, + } +} + +func GetCalculateHashResponseHandler(response *blobbergrpc.CalculateHashResponse) interface{} { + result := make(map[string]interface{}) + if msg := response.GetMessage(); msg != "" { + result["msg"] = msg + } + + return result +} + +func GetCommitMetaTxnHandlerResponse(response *blobbergrpc.CommitMetaTxnResponse) interface{} { + msg := response.GetMessage() + if msg == "" { + return nil + } + + result := struct { + Msg string `json:"msg"` + }{ + Msg: msg, + } + + return result +} + +func CollaboratorResponse(response *blobbergrpc.CollaboratorResponse) interface{} { + if msg := response.GetMessage(); msg != "" { + return struct { + Msg string `json:"msg"` + }{Msg: msg} + } + + if collaborators := response.GetCollaborators(); collaborators != nil { + collabs := make([]reference.Collaborator, 0, len(collaborators)) + for _, c := range collaborators { + collabs = append(collabs, *GRPCCollaboratorToCollaborator(c)) + } + + return collabs + } + + return nil +} + +func UpdateObjectAttributesResponseHandler(updateAttributesResponse *blobbergrpc.UpdateObjectAttributesResponse) *blobberhttp.UpdateObjectAttributesResponse { + return &blobberhttp.UpdateObjectAttributesResponse{ + WhoPaysForReads: common.WhoPays(updateAttributesResponse.WhoPaysForReads), + } +} + +func CopyObjectResponseHandler(copyObjectResponse *blobbergrpc.CopyObjectResponse) *blobberhttp.UploadResult { + return &blobberhttp.UploadResult{ + Filename: copyObjectResponse.Filename, + Size: copyObjectResponse.Size, + Hash: copyObjectResponse.ContentHash, + MerkleRoot: copyObjectResponse.MerkleRoot, + UploadLength: copyObjectResponse.UploadLength, + UploadOffset: copyObjectResponse.UploadOffset, + } +} From 09fdce5e792ad18f65eaa4c2ee0161922bfd8a05 Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 18:03:53 +0530 Subject: [PATCH 180/183] fix lint errors --- .../0chain.net/blobbercore/handler/commit_integration_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/handler/commit_integration_test.go b/code/go/0chain.net/blobbercore/handler/commit_integration_test.go index e782d8097..36d840f5b 100644 --- a/code/go/0chain.net/blobbercore/handler/commit_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/commit_integration_test.go @@ -126,7 +126,7 @@ func TestBlobberGRPCService_Commit(t *testing.T) { t.Fatal("expected error") } - if getCommiteResp.WriteMarker.AllocationID != tc.expectedAllocation { + if getCommiteResp.WriteMarker.AllocationId != tc.expectedAllocation { t.Fatal("unexpected root name from GetObject") } } From 34d5438faa482ce754c6c82d81ad49f7177d0b4a Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 22:22:34 +0530 Subject: [PATCH 181/183] :sparkles: changing default grpc port to 31501 --- .../blobbercore/handler/grpc_handler_integration_test.go | 2 +- docker.local/b0docker-compose-debug.yml | 4 ++-- docker.local/b0docker-compose.yml | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go index 79e929f57..acd3a40b9 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_integration_test.go @@ -32,7 +32,7 @@ import ( "gorm.io/gorm" ) -const BlobberTestAddr = "localhost:7031" +const BlobberTestAddr = "localhost:31501" const RetryAttempts = 8 const RetryTimeout = 3 diff --git a/docker.local/b0docker-compose-debug.yml b/docker.local/b0docker-compose-debug.yml index f25c128cc..d185d0b3d 100644 --- a/docker.local/b0docker-compose-debug.yml +++ b/docker.local/b0docker-compose-debug.yml @@ -63,9 +63,9 @@ services: - ./blobber${BLOBBER}/data/tmp:/tmp ports: - "505${BLOBBER}:505${BLOBBER}" - - "703${BLOBBER}:703${BLOBBER}" + - "3150${BLOBBER}:3150${BLOBBER}" - "236${BLOBBER}:236${BLOBBER}" - command: dlv --listen=:236${BLOBBER} --headless=true --api-version=2 --accept-multiclient exec ./bin/blobber -- --port 505${BLOBBER} --grpc_port 703${BLOBBER} --hostname localhost --deployment_mode 0 --keys_file keysconfig/b0bnode${BLOBBER}_keys.txt --files_dir /blobber/files --log_dir /blobber/log --db_dir /blobber/data --minio_file keysconfig/minio_config.txt + command: dlv --listen=:236${BLOBBER} --headless=true --api-version=2 --accept-multiclient exec ./bin/blobber -- --port 505${BLOBBER} --grpc_port 3150${BLOBBER} --hostname localhost --deployment_mode 0 --keys_file keysconfig/b0bnode${BLOBBER}_keys.txt --files_dir /blobber/files --log_dir /blobber/log --db_dir /blobber/data --minio_file keysconfig/minio_config.txt networks: default: testnet0: diff --git a/docker.local/b0docker-compose.yml b/docker.local/b0docker-compose.yml index 63f7d2a1c..c574276b3 100644 --- a/docker.local/b0docker-compose.yml +++ b/docker.local/b0docker-compose.yml @@ -63,8 +63,8 @@ services: - ./blobber${BLOBBER}/data/tmp:/tmp ports: - "505${BLOBBER}:505${BLOBBER}" - - "703${BLOBBER}:703${BLOBBER}" - command: ./bin/blobber --port 505${BLOBBER} --grpc_port 703${BLOBBER} --hostname 198.18.0.9${BLOBBER} --deployment_mode 0 --keys_file keysconfig/b0bnode${BLOBBER}_keys.txt --files_dir /blobber/files --log_dir /blobber/log --db_dir /blobber/data --minio_file keysconfig/minio_config.txt + - "3150${BLOBBER}:3150${BLOBBER}" + command: ./bin/blobber --port 505${BLOBBER} --grpc_port 3150${BLOBBER} --hostname 198.18.0.9${BLOBBER} --deployment_mode 0 --keys_file keysconfig/b0bnode${BLOBBER}_keys.txt --files_dir /blobber/files --log_dir /blobber/log --db_dir /blobber/data --minio_file keysconfig/minio_config.txt networks: default: testnet0: From 8534f3bbf649d5822e08be08d54951139913530f Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 22:25:06 +0530 Subject: [PATCH 182/183] fixing grpc port in test --- .../0chain.net/blobbercore/handler/helper_integration_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/go/0chain.net/blobbercore/handler/helper_integration_test.go b/code/go/0chain.net/blobbercore/handler/helper_integration_test.go index ceaeede39..52fb4ea48 100644 --- a/code/go/0chain.net/blobbercore/handler/helper_integration_test.go +++ b/code/go/0chain.net/blobbercore/handler/helper_integration_test.go @@ -26,7 +26,7 @@ import ( "github.com/0chain/gosdk/core/zcncrypto" ) -const BlobberTestAddr = "localhost:7031" +const BlobberTestAddr = "localhost:31501" const RetryAttempts = 8 const RetryTimeout = 3 From 11235840724199c233e3e186b4ac53532e0e5b3a Mon Sep 17 00:00:00 2001 From: Shravan Shetty Date: Wed, 7 Jul 2021 22:51:19 +0530 Subject: [PATCH 183/183] :sparkles: server now handles grpc-web requests --- code/go/0chain.net/blobber/main.go | 7 ++-- .../blobbercore/handler/grpc_handler_test.go | 3 +- .../{grpcMiddleware.go => grpc_middleware.go} | 26 ++++++++++++-- .../0chain.net/blobbercore/handler/helper.go | 3 +- go.mod | 4 +++ go.sum | 35 +++++++++++++++++++ 6 files changed, 69 insertions(+), 9 deletions(-) rename code/go/0chain.net/blobbercore/handler/{grpcMiddleware.go => grpc_middleware.go} (79%) diff --git a/code/go/0chain.net/blobber/main.go b/code/go/0chain.net/blobber/main.go index 374e078e9..071d0229b 100644 --- a/code/go/0chain.net/blobber/main.go +++ b/code/go/0chain.net/blobber/main.go @@ -44,7 +44,7 @@ var filesDir *string var metadataDB *string func initHandlers(r *mux.Router) { - r.HandleFunc("/", func (w http.ResponseWriter, r *http.Request) { + r.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) { mc := chain.GetServerChain() fmt.Fprintf(w, "
Running since %v ...\n", startTime) @@ -288,7 +288,7 @@ func healthCheckOnChainWorker() { func setup(logDir string) error { // init blockchain related stuff - zcncore.SetLogFile(logDir + "/0chainBlobber.log", false) + zcncore.SetLogFile(logDir+"/0chainBlobber.log", false) zcncore.SetLogLevel(3) if err := zcncore.InitZCNSDK(serverChain.BlockWorker, config.Configuration.SignatureScheme); err != nil { return err @@ -454,8 +454,7 @@ func main() { common.ConfigRateLimits() initHandlers(r) - grpcServer := handler.NewServerWithMiddlewares(common.NewGRPCRateLimiter()) - handler.RegisterGRPCServices(r, grpcServer) + grpcServer := handler.NewGRPCServerWithMiddlewares(common.NewGRPCRateLimiter(), r) if config.Development() { reflection.Register(grpcServer) diff --git a/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go b/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go index 0eb542802..4069295b0 100644 --- a/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_handler_test.go @@ -32,8 +32,7 @@ var ( func startGRPCServer(t *testing.T) { lis = bufconn.Listen(1024 * 1024) - grpcS := NewServerWithMiddlewares(&common.GRPCRateLimiter{Limiter: rl.New(1000)}) - RegisterGRPCServices(mux.NewRouter(), grpcS) + grpcS := NewGRPCServerWithMiddlewares(&common.GRPCRateLimiter{Limiter: rl.New(1000)}, mux.NewRouter()) go func() { if err := grpcS.Serve(lis); err != nil { t.Errorf("Server exited with error: %v", err) diff --git a/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go b/code/go/0chain.net/blobbercore/handler/grpc_middleware.go similarity index 79% rename from code/go/0chain.net/blobbercore/handler/grpcMiddleware.go rename to code/go/0chain.net/blobbercore/handler/grpc_middleware.go index 5f0ab286a..ec027b6fd 100644 --- a/code/go/0chain.net/blobbercore/handler/grpcMiddleware.go +++ b/code/go/0chain.net/blobbercore/handler/grpc_middleware.go @@ -2,8 +2,13 @@ package handler import ( "context" + "net/http" "time" + "github.com/improbable-eng/grpc-web/go/grpcweb" + + "github.com/gorilla/mux" + "github.com/0chain/blobber/code/go/0chain.net/core/common" "github.com/0chain/blobber/code/go/0chain.net/core/logging" grpc_zap "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap" @@ -53,8 +58,8 @@ func unaryTimeoutInterceptor() grpc.UnaryServerInterceptor { } } -func NewServerWithMiddlewares(limiter grpc_ratelimit.Limiter) *grpc.Server { - return grpc.NewServer( +func NewGRPCServerWithMiddlewares(limiter grpc_ratelimit.Limiter, r *mux.Router) *grpc.Server { + srv := grpc.NewServer( grpc.ChainStreamInterceptor( grpc_zap.StreamServerInterceptor(logging.Logger), grpc_recovery.StreamServerInterceptor(), @@ -67,4 +72,21 @@ func NewServerWithMiddlewares(limiter grpc_ratelimit.Limiter) *grpc.Server { unaryTimeoutInterceptor(), // should always be the lastest, to be "innermost" ), ) + + registerGRPCServices(r, srv) + + // adds grpc-web middleware + wrappedServer := grpcweb.WrapServer(srv) + r.Use(func(h http.Handler) http.Handler { + return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { + if wrappedServer.IsGrpcWebRequest(r) { + wrappedServer.ServeHTTP(w, r) + return + } + + h.ServeHTTP(w, r) + }) + }) + + return srv } diff --git a/code/go/0chain.net/blobbercore/handler/helper.go b/code/go/0chain.net/blobbercore/handler/helper.go index 0add2303e..c0b32be6b 100644 --- a/code/go/0chain.net/blobbercore/handler/helper.go +++ b/code/go/0chain.net/blobbercore/handler/helper.go @@ -9,11 +9,12 @@ import ( "google.golang.org/grpc" ) -func RegisterGRPCServices(r *mux.Router, server *grpc.Server) { +func registerGRPCServices(r *mux.Router, server *grpc.Server) { blobberService := newGRPCBlobberService() grpcGatewayHandler := runtime.NewServeMux() blobbergrpc.RegisterBlobberServer(server, blobberService) _ = blobbergrpc.RegisterBlobberHandlerServer(context.Background(), grpcGatewayHandler, blobberService) r.PathPrefix("/").Handler(grpcGatewayHandler) + } diff --git a/go.mod b/go.mod index 9101490b8..d2f2fdee8 100644 --- a/go.mod +++ b/go.mod @@ -3,6 +3,7 @@ module github.com/0chain/blobber require ( github.com/0chain/gosdk v1.1.6 github.com/DATA-DOG/go-sqlmock v1.5.0 + github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f // indirect github.com/didip/tollbooth v4.0.2+incompatible github.com/go-ini/ini v1.55.0 // indirect github.com/gorilla/handlers v1.4.2 @@ -10,12 +11,14 @@ require ( github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 github.com/grpc-ecosystem/grpc-gateway/v2 v2.3.0 github.com/herumi/bls-go-binary v0.0.0-20191119080710-898950e1a520 + github.com/improbable-eng/grpc-web v0.14.0 // indirect github.com/jackc/pgproto3/v2 v2.0.4 // indirect github.com/koding/cache v0.0.0-20161222233015-e8a81b0b3f20 github.com/minio/minio-go v6.0.14+incompatible github.com/mitchellh/mapstructure v1.3.1 github.com/patrickmn/go-cache v2.1.0+incompatible // indirect github.com/remeh/sizedwaitgroup v0.0.0-20180822144253-5e7302b12cce + github.com/rs/cors v1.8.0 // indirect github.com/spf13/viper v1.7.0 github.com/stretchr/testify v1.7.0 go.uber.org/ratelimit v0.2.0 @@ -31,6 +34,7 @@ require ( gorm.io/datatypes v0.0.0-20200806042100-bc394008dd0d gorm.io/driver/postgres v1.0.0 gorm.io/gorm v1.20.4 + nhooyr.io/websocket v1.8.7 // indirect ) go 1.13 diff --git a/go.sum b/go.sum index 633f9a35e..9f457be40 100644 --- a/go.sum +++ b/go.sum @@ -81,6 +81,8 @@ github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/denisenkom/go-mssqldb v0.0.0-20200428022330-06a60b6afbbc h1:VRRKCwnzqk8QCaRC4os14xoKDdbHqqlJtJA0oc1ZAjg= github.com/denisenkom/go-mssqldb v0.0.0-20200428022330-06a60b6afbbc/go.mod h1:xbL0rPBG9cCiLr28tMa8zpbdarY27NDyej4t/EjAShU= +github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f h1:U5y3Y5UE0w7amNe7Z5G/twsBW0KEalRQXZzf8ufSh9I= +github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f/go.mod h1:xH/i4TFMt8koVQZ6WFms69WAsDWr2XsYL3Hkl7jkoLE= github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= github.com/didip/tollbooth v4.0.2+incompatible h1:fVSa33JzSz0hoh2NxpwZtksAzAgd7zjmGO20HCZtF4M= @@ -96,6 +98,9 @@ github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMo github.com/gedex/inflector v0.0.0-20170307190818-16278e9db813/go.mod h1:P+oSoE9yhSRvsmYyZsshflcR6ePWYLql6UU1amW13IM= github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= +github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI= +github.com/gin-gonic/gin v1.5.0/go.mod h1:Nd6IXA8m5kNZdNEHMBd93KT+mdY3+bewLgRvmCsR2Do= +github.com/gin-gonic/gin v1.6.3/go.mod h1:75u5sXoLsGZoRN5Sgbi1eraJ4GU3++wFwWzhwvtwp4M= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= @@ -105,9 +110,18 @@ github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2 github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= +github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= +github.com/go-playground/locales v0.12.1/go.mod h1:IUMDtCfWo/w/mtMfIE/IG2K+Ey3ygWanZIBtBW0W2TM= +github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8= +github.com/go-playground/universal-translator v0.16.0/go.mod h1:1AnU7NaIRDWWzGEKwgtJRd2xk99HeFyHw3yid4rvQIY= +github.com/go-playground/universal-translator v0.17.0/go.mod h1:UkSxE5sNxxRwHyU+Scu5vgOQjsIJAF8j9muTVoKLVtA= +github.com/go-playground/validator/v10 v10.2.0/go.mod h1:uOYAAleCW8F/7oMFd6aG0GOhaH6EGOAJShg8Id5JGkI= github.com/go-sql-driver/mysql v1.5.0 h1:ozyZYNQW3x3HtqT1jira07DN2PArx2v7/mN66gGcHOs= github.com/go-sql-driver/mysql v1.5.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= +github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= +github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= +github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= github.com/gofrs/flock v0.8.0/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/uuid v3.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gofrs/uuid v4.0.0+incompatible h1:1SD/1F5pU8p29ybwgQSwpQk+mwdRrXCYuPhW6m+TnJw= @@ -160,6 +174,7 @@ github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5 h1:Khx7svrCpmxxtHBq5j2mp/xVjsi8hQMfNLvJFAlrGgU= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= @@ -180,6 +195,7 @@ github.com/gorilla/handlers v1.4.2 h1:0QniY0USkHQ1RGCLfKxeNHK9bkDHGRYGNDFBCS+YAR github.com/gorilla/handlers v1.4.2/go.mod h1:Qkdc/uu4tH4g6mTK6auzZ766c4CA0Ng8+o/OAirnOIQ= github.com/gorilla/mux v1.7.3 h1:gnP5JzjVOuiZD07fKKToCAOjS0yOpj/qPETTXCCS6hw= github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= +github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 h1:+9834+KizmvFV7pXQGSXQTsaWhq2GjuNUt0aUU0YBYw= @@ -216,6 +232,8 @@ github.com/herumi/bls-go-binary v0.0.0-20191119080710-898950e1a520 h1:3ek8BJos3J github.com/herumi/bls-go-binary v0.0.0-20191119080710-898950e1a520/go.mod h1:uTBfU/n3h1aOYIl5nNTbLn5dUfNkF1P97JTaz3bdvro= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/idubinskiy/schematyper v0.0.0-20190118213059-f71b40dac30d/go.mod h1:xVHEhsiSJJnT0jlcQpQUg+GyoLf0i0xciM1kqWTGT58= +github.com/improbable-eng/grpc-web v0.14.0 h1:GdoK+cXABdB+1keuqsV1drSFO2XLYIxqt/4Rj8SWGBk= +github.com/improbable-eng/grpc-web v0.14.0/go.mod h1:6hRR09jOEG81ADP5wCQju1z71g6OL4eEvELdran/3cs= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/jackc/chunkreader v1.0.0 h1:4s39bBR8ByfqH+DKm8rQA3E1LHZWB9XWcrz8fqaZbe0= github.com/jackc/chunkreader v1.0.0/go.mod h1:RT6O25fNZIuasFJRyZ4R/Y2BbhasbmZXF9QQ7T3kePo= @@ -279,6 +297,8 @@ github.com/jinzhu/now v1.1.1 h1:g39TucaRWyV3dwDO++eEc6qf8TVIQ/Da48WmqjZ3i7E= github.com/jinzhu/now v1.1.1/go.mod h1:d3SSVoowX0Lcu0IBviAWJpolVfI5UJVZZ7cO71lE/z8= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= +github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= +github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= github.com/jtolds/gls v4.20.0+incompatible h1:xdiiI2gbIgH/gLH7ADydsJ1uDOEzR8yvV7C0MuV77Wo= @@ -287,6 +307,8 @@ github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7V github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= +github.com/klauspost/compress v1.10.3/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= +github.com/klauspost/compress v1.11.7 h1:0hzRabrMN4tSTvMfnL3SCv1ZGeAP23ynzodBgaHeMeg= github.com/klauspost/compress v1.11.7/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/cpuid v1.2.0 h1:NMpwD2G9JSFOE1/TJjGSo5zG7Yb2bTe7eq1jH+irmeE= github.com/klauspost/cpuid v1.2.0/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= @@ -304,6 +326,8 @@ github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/pty v1.1.8/go.mod h1:O1sed60cT9XZ5uDucP5qwvh+TE3NnUj51EiZO/lmSfw= github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= +github.com/leodido/go-urn v1.1.0/go.mod h1:+cyI34gQWZcE1eQU7NVgKkkzdXDQHr1dBMtdAPozLkw= +github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII= github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.1.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.2.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= @@ -338,7 +362,9 @@ github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:F github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.3.1 h1:cCBH2gTD2K0OtLlv/Y5H01VQCqmlDxz30kS5Y5bqfLA= github.com/mitchellh/mapstructure v1.3.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= +github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= +github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/nishanths/predeclared v0.0.0-20200524104333-86fad755b4d3/go.mod h1:nt3d53pc1VYcphSCIaYAJtnPYnr3Zyn8fMq2wvPGPso= @@ -372,6 +398,8 @@ github.com/remeh/sizedwaitgroup v0.0.0-20180822144253-5e7302b12cce/go.mod h1:3j2 github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= +github.com/rs/cors v1.8.0 h1:P2KMzcFwrPoSjkF1WLRPsp3UMLyql8L4v9hQpVeK5so= +github.com/rs/cors v1.8.0/go.mod h1:EBwu+T5AvHOcXwvZIkQFjUN6s8Czyqw12GL/Y0tUyRM= github.com/rs/xid v1.2.1/go.mod h1:+uKXf+4Djp6Md1KODXJxgGQPKngRmWyn10oCKFzNHOQ= github.com/rs/zerolog v1.13.0/go.mod h1:YbFCdg8HfsridGWAh22vktObvhZbQsZXe4/zB0OKkWU= github.com/rs/zerolog v1.15.0/go.mod h1:xYTKnLHcpfU2225ny5qZjxnj9NvkumZYjJHlAThCjNc= @@ -420,6 +448,8 @@ github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1 github.com/twitchtv/twirp v7.1.0+incompatible/go.mod h1:RRJoFSAmTEh2weEqWtpPE3vFK5YBhA6bqp2l1kfCC5A= github.com/tyler-smith/go-bip39 v1.0.0 h1:FOHg9gaQLeBBRbHE/QrTLfEiBHy5pQ/yXzf9JG5pYFM= github.com/tyler-smith/go-bip39 v1.0.0/go.mod h1:sJ5fKU0s6JVwZjjcUEX2zFOnvq0ASQ2K9Zr6cf67kNs= +github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw= +github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= @@ -764,6 +794,8 @@ gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8 gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 h1:qIbj1fsPNlZgppZ+VLlY7N33q108Sa+fhmuc+sWQYwY= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= +gopkg.in/go-playground/assert.v1 v1.2.1/go.mod h1:9RXL0bg/zibRAgZUYszZSwO/z8Y/a8bDuhia5mkpMnE= +gopkg.in/go-playground/validator.v9 v9.29.1/go.mod h1:+c9/zcJMFNgbLvly1L1V+PpxWdVbfP1avr/N00E2vyQ= gopkg.in/inconshreveable/log15.v2 v2.0.0-20180818164646-67afb5ed74ec/go.mod h1:aPpfJ7XW+gOuirDoZ8gHhLh3kZ1B08FtV2bbmy7Jv3s= gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/ini.v1 v1.61.0 h1:LBCdW4FmFYL4s/vDZD1RQYX7oAR6IjujCYgMdbHBR10= @@ -777,6 +809,7 @@ gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bl gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= @@ -807,6 +840,8 @@ honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4 h1:UoveltGrhghAA7ePc+e+QYDHXrBps2PqFZiHkGR/xK8= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= +nhooyr.io/websocket v1.8.7 h1:usjR2uOr/zjjkVMy0lW+PPohFok7PCow5sDjLgX4P4g= +nhooyr.io/websocket v1.8.7/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA=