diff --git a/go.mod b/go.mod index 045d7ad7..574cdd8c 100644 --- a/go.mod +++ b/go.mod @@ -8,23 +8,23 @@ require ( github.com/hyperledger/fabric-x-common v0.0.0-20250702121055-42b021047999 github.com/onsi/ginkgo/v2 v2.20.2 github.com/pkg/errors v0.9.1 - github.com/stretchr/testify v1.9.0 + github.com/stretchr/testify v1.10.0 go.uber.org/zap v1.27.0 - golang.org/x/sync v0.12.0 + golang.org/x/sync v0.13.0 google.golang.org/grpc v1.72.0 ) require ( github.com/alecthomas/kingpin v2.2.6+incompatible github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 - github.com/hyperledger-labs/SmartBFT v0.0.0-20240916013553-852e5be5889b - github.com/hyperledger/fabric v1.4.0-rc1.0.20240918034325-94590aa4332b // commit 94590aa4332b20350e8aee5572a8cfd29164221c (tag: v3.0.0-rc1, tag: v3.0.0) + github.com/hyperledger-labs/SmartBFT v0.0.0-20250503203013-eb005eef8866 + github.com/hyperledger/fabric v1.4.0-rc1.0.20250510200036-435a7f1a780a // commit 435a7f1a780a128756fb2f72bf4cad164bf13fbb (tag: v3.1.1) github.com/hyperledger/fabric-config v0.3.0 github.com/hyperledger/fabric-lib-go v1.1.3-0.20240523144151-25edd1eaf5f5 - github.com/hyperledger/fabric-protos-go-apiv2 v0.3.3 + github.com/hyperledger/fabric-protos-go-apiv2 v0.3.7 github.com/onsi/gomega v1.34.2 - github.com/syndtr/goleveldb v1.0.1-0.20210305035536-64b5b1c73954 - google.golang.org/protobuf v1.36.5 + github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d + google.golang.org/protobuf v1.36.6 gopkg.in/alecthomas/kingpin.v2 v2.2.6 gopkg.in/yaml.v3 v3.0.1 ) @@ -38,7 +38,7 @@ require ( github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible // indirect github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751 // indirect github.com/alecthomas/units v0.0.0-20240626203959-61d1e3462e30 // indirect - github.com/bits-and-blooms/bitset v1.13.0 // indirect + github.com/bits-and-blooms/bitset v1.14.3 // indirect github.com/consensys/bavard v0.1.13 // indirect github.com/consensys/gnark-crypto v0.13.0 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect @@ -47,7 +47,7 @@ require ( github.com/go-viper/mapstructure/v2 v2.4.0 // indirect github.com/golang/snappy v0.0.4 // indirect github.com/google/go-cmp v0.6.0 // indirect - github.com/google/pprof v0.0.0-20240827171923-fa2c70bbbfe5 // indirect + github.com/google/pprof v0.0.0-20241001023024-f4c0cfd0cf1d // indirect github.com/hyperledger/aries-bbs-go v0.0.0-20240528084656-761671ea73bc // indirect github.com/hyperledger/fabric-amcl v0.0.0-20230602173724-9e02669dceb2 // indirect github.com/kilic/bls12-381 v0.1.0 // indirect @@ -66,11 +66,11 @@ require ( github.com/subosito/gotenv v1.6.0 // indirect github.com/sykesm/zap-logfmt v0.0.4 // indirect go.uber.org/multierr v1.11.0 // indirect - golang.org/x/crypto v0.36.0 // indirect - golang.org/x/net v0.38.0 // indirect - golang.org/x/sys v0.31.0 // indirect - golang.org/x/text v0.23.0 // indirect - golang.org/x/tools v0.24.0 // indirect + golang.org/x/crypto v0.37.0 // indirect + golang.org/x/net v0.39.0 // indirect + golang.org/x/sys v0.32.0 // indirect + golang.org/x/text v0.24.0 // indirect + golang.org/x/tools v0.26.0 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20250218202821-56aae31c358a // indirect gopkg.in/yaml.v2 v2.4.0 // indirect rsc.io/tmplfunc v0.0.3 // indirect diff --git a/go.sum b/go.sum index 11ac4222..9e695f40 100644 --- a/go.sum +++ b/go.sum @@ -19,11 +19,14 @@ github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuy github.com/alecthomas/units v0.0.0-20240626203959-61d1e3462e30 h1:t3eaIm0rUkzbrIewtiFmMK5RXHej2XnoXNhxVsAYUfg= github.com/alecthomas/units v0.0.0-20240626203959-61d1e3462e30/go.mod h1:fvzegU4vN3H1qMT+8wDmzjAcDONcgo2/SZ/TyfdUOFs= github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= -github.com/bits-and-blooms/bitset v1.13.0 h1:bAQ9OPNFYbGHV6Nez0tmNI0RiEu7/hxlYJRUA0wFAVE= -github.com/bits-and-blooms/bitset v1.13.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= +github.com/bits-and-blooms/bitset v1.14.3 h1:Gd2c8lSNf9pKXom5JtD7AaKO8o7fGQ2LtFj1436qilA= +github.com/bits-and-blooms/bitset v1.14.3/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= github.com/btcsuite/btcutil v1.0.3-0.20201208143702-a53e38424cce h1:YtWJF7RHm2pYCvA5t0RPmAaLUhREsKuKd+SLhxFbFeQ= github.com/btcsuite/btcutil v1.0.3-0.20201208143702-a53e38424cce/go.mod h1:0DVlHczLPewLcPGEIeUEzfOJhqGPQ0mJJRDBtD307+o= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= +github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= +github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= +github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/consensys/bavard v0.1.13 h1:oLhMLOFGTLdlda/kma4VOJazblc7IM5y5QPd2A/YjhQ= @@ -41,6 +44,7 @@ github.com/frankban/quicktest v1.14.6 h1:7Xjx+VpznH+oBnejlPUj8oUpdxnVs4f8XU8WnHk github.com/frankban/quicktest v1.14.6/go.mod h1:4ptaffx2x8+WTWXmUCuVU6aPUX1/Mz7zb5vbUoiM6w0= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= +github.com/fsnotify/fsnotify v1.5.4/go.mod h1:OVB6XrOHzAwXMpEM7uPOzcehqUV2UqJxmVXmkdnm1bU= github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nosvA= github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY= @@ -50,6 +54,7 @@ github.com/go-logr/logr v1.4.2/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ4 github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= +github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= github.com/go-task/slim-sprig/v3 v3.0.0 h1:sUs3vkvUymDpBKi3qH1YSqBQk9+9D/8M2mN1vB6EwHI= github.com/go-task/slim-sprig/v3 v3.0.0/go.mod h1:W848ghGpv3Qj3dhTPRyJypKRiqCdHZiAzKg9hl15HA8= github.com/go-viper/mapstructure/v2 v2.4.0 h1:EBsztssimR/CONLSZZ04E8qAkxNYq4Qp9LvH92wZUgs= @@ -66,19 +71,22 @@ github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrU github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= +github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= +github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= -github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/google/pprof v0.0.0-20240827171923-fa2c70bbbfe5 h1:5iH8iuqE5apketRbSFBy+X1V0o+l+8NF1avt4HWl7cA= -github.com/google/pprof v0.0.0-20240827171923-fa2c70bbbfe5/go.mod h1:vavhavw2zAxS5dIdcRluK6cSGGPlZynqzFM8NdvU144= +github.com/google/pprof v0.0.0-20210407192527-94a9f03dee38/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20241001023024-f4c0cfd0cf1d h1:Jaz2JzpQaQXyET0AjLBXShrthbpqMkhGiEfkcQAiAUs= +github.com/google/pprof v0.0.0-20241001023024-f4c0cfd0cf1d/go.mod h1:vavhavw2zAxS5dIdcRluK6cSGGPlZynqzFM8NdvU144= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/subcommands v1.2.0/go.mod h1:ZjhPrFU+Olkh9WazFPsl27BQ4UPiG37m3yTrtFlrHVk= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= @@ -86,22 +94,23 @@ github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+ github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 h1:UH//fgunKIs4JdUbpDl1VZCDaL56wXCB/5+wF6uHfaI= github.com/grpc-ecosystem/go-grpc-middleware v1.4.0/go.mod h1:g5qyo/la0ALbONm6Vbp88Yd8NsDy6rZz+RcrMPxvld8= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= -github.com/hyperledger-labs/SmartBFT v0.0.0-20240916013553-852e5be5889b h1:HihCDs7Hy69lykrPJP7Uc54DIWlTCYg4m/+kHRqxUk0= -github.com/hyperledger-labs/SmartBFT v0.0.0-20240916013553-852e5be5889b/go.mod h1:54hysiDJViMzhT0mJIqt8aUvkQ+yHj4RIdiGZzuosQs= +github.com/hyperledger-labs/SmartBFT v0.0.0-20250503203013-eb005eef8866 h1:Mu/6NJsfl9g3wM15Ue7hqPq4LtgYDoABh8MO4u8aW4g= +github.com/hyperledger-labs/SmartBFT v0.0.0-20250503203013-eb005eef8866/go.mod h1:9aNHNXsCVy/leGz2gpTC1eOL5QecxbSAGjqsLh4T1LM= github.com/hyperledger/aries-bbs-go v0.0.0-20240528084656-761671ea73bc h1:3Ykk6MtyfnlzMOQry9zkxsoLWpCWZwDPqehO/BJwArM= github.com/hyperledger/aries-bbs-go v0.0.0-20240528084656-761671ea73bc/go.mod h1:Kofn6A6WWea1ZM8Rys5aBW9dszwJ7Ywa0kyyYL0TPYw= -github.com/hyperledger/fabric v1.4.0-rc1.0.20240918034325-94590aa4332b h1:OzSgIDx5owx8InPK/w/tLNajLOedYwFbKqe5QQUz7jw= -github.com/hyperledger/fabric v1.4.0-rc1.0.20240918034325-94590aa4332b/go.mod h1:YTYvaVg6DFLvvEnUMUNnXlpQx4LCaXnme/l6g1ukHTM= +github.com/hyperledger/fabric v1.4.0-rc1.0.20250510200036-435a7f1a780a h1:l9dE3iuE+mKj7K8Tcx904cF8zJpaNQONh3GNZdXnnyc= +github.com/hyperledger/fabric v1.4.0-rc1.0.20250510200036-435a7f1a780a/go.mod h1:JBt+AXS2O6MTid78WNKd3fn4b0+EXWv+M56DxiX/qP4= github.com/hyperledger/fabric-amcl v0.0.0-20230602173724-9e02669dceb2 h1:B1Nt8hKb//KvgGRprk0h1t4lCnwhE9/ryb1WqfZbV+M= github.com/hyperledger/fabric-amcl v0.0.0-20230602173724-9e02669dceb2/go.mod h1:X+DIyUsaTmalOpmpQfIvFZjKHQedrURQ5t4YqquX7lE= github.com/hyperledger/fabric-config v0.3.0 h1:FS5/dc9GAniljP6RYxQRG92AaiBVoN2vTvtOvnWqeQs= github.com/hyperledger/fabric-config v0.3.0/go.mod h1:kSevTn78K83Suc++JsEo7Nt1tYIPqDajW+ORz3OhWlg= github.com/hyperledger/fabric-lib-go v1.1.3-0.20240523144151-25edd1eaf5f5 h1:RPWTL5wxAb+xDOrsCU3QYZP65305F8v3PaOyzdbPVMU= github.com/hyperledger/fabric-lib-go v1.1.3-0.20240523144151-25edd1eaf5f5/go.mod h1:SHNCq8AB0VpHAmvJEtdbzabv6NNV1F48JdmDihasBjc= -github.com/hyperledger/fabric-protos-go-apiv2 v0.3.3 h1:Xpd6fzG/KjAOHJsq7EQXY2l+qi/y8muxBaY7R6QWABk= -github.com/hyperledger/fabric-protos-go-apiv2 v0.3.3/go.mod h1:2pq0ui6ZWA0cC8J+eCErgnMDCS1kPOEYVY+06ZAK0qE= +github.com/hyperledger/fabric-protos-go-apiv2 v0.3.7 h1:sQ5qv8vQQfwewa1JlCiSCC8dLElmaU2/frLolpgibEY= +github.com/hyperledger/fabric-protos-go-apiv2 v0.3.7/go.mod h1:bJnwzfv03oZQeCc863pdGTDgf5nmCy6Za3RAE7d2XsQ= github.com/hyperledger/fabric-x-common v0.0.0-20250702121055-42b021047999 h1:xTDIzpZsKjQ7ID70hyqzw2q8So3RqbFhNcx7TWqu3gs= github.com/hyperledger/fabric-x-common v0.0.0-20250702121055-42b021047999/go.mod h1:xO5q1ytO5d5/DeWkDKMGAgoaWBnhmLIjT/ZS2BZfFVs= +github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/kilic/bls12-381 v0.1.0 h1:encrdjqKMEvabVQ7qYOKu1OvhqpK4s47wDYtNiPtlp4= github.com/kilic/bls12-381 v0.1.0/go.mod h1:vDTTHJONJ6G+P2R74EhnyotQDTliQDnFEwhdmfzw1ig= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= @@ -123,16 +132,21 @@ github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RR github.com/mmcloughlin/addchain v0.4.0 h1:SobOdjm2xLj1KkXN5/n0xTIWyZA2+s99UCY1iPfkHRY= github.com/mmcloughlin/addchain v0.4.0/go.mod h1:A86O+tHqZLMNO4w6ZZ4FlVQEadcoqkyU72HC5wJ4RlU= github.com/mmcloughlin/profile v0.1.1/go.mod h1:IhHD7q1ooxgwTgjxQYkACGA77oFTDdFVejUS1/tS/qU= -github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= +github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= +github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= -github.com/onsi/ginkgo v1.14.0 h1:2mOpI4JVVPBN+WQRa0WKH2eXR+Ey+uK4n7Zj0aYpIQA= -github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= +github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= +github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE= +github.com/onsi/ginkgo v1.16.5/go.mod h1:+E8gABHa3K6zRBolWtd+ROzc/U5bkGt0FwiG042wbpU= +github.com/onsi/ginkgo/v2 v2.1.3/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c= github.com/onsi/ginkgo/v2 v2.20.2 h1:7NVCeyIWROIAheY21RLS+3j2bb52W0W82tkberYytp4= github.com/onsi/ginkgo/v2 v2.20.2/go.mod h1:K9gyxPIlb+aIvnZ8bd9Ak+YP18w3APlR+5coaZoE2ag= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= +github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= +github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9yPro= github.com/onsi/gomega v1.34.2 h1:pNCwDkzrsv7MS9kpaQvVb1aVLahQXyJ/Tv5oAZMI3i8= github.com/onsi/gomega v1.34.2/go.mod h1:v1xfxRgk0KIsG+QOdm7p8UosrOzPYRo60fd3B/1Dukc= github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= @@ -169,18 +183,21 @@ github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/ 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/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= +github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= -github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= +github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA= +github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/subosito/gotenv v1.6.0 h1:9NlTDc1FTs4qu0DDq7AEtTPNw6SVm7uBMsUCUjABIf8= github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= github.com/sykesm/zap-logfmt v0.0.4 h1:U2WzRvmIWG1wDLCFY3sz8UeEmsdHQjHFNlIdmroVFaI= github.com/sykesm/zap-logfmt v0.0.4/go.mod h1:AuBd9xQjAe3URrWT1BBDk2v2onAZHkZkWRMiYZXiZWA= -github.com/syndtr/goleveldb v1.0.1-0.20210305035536-64b5b1c73954 h1:xQdMZ1WLrgkkvOZ/LDQxjVxMLdby7osSh4ZEVa5sIjs= -github.com/syndtr/goleveldb v1.0.1-0.20210305035536-64b5b1c73954/go.mod h1:u2MKkTVTVJWe5D1rCvame8WqhBd88EuIwODJZ1VHCPM= +github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d h1:vfofYNRScrDdvS342BElfbETmL1Aiz3i2t0zfRj16Hs= +github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d/go.mod h1:RRCYJbIwD5jmqPI9XoAFR0OcDxqUctll6zUj/+B4S48= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= go.opentelemetry.io/auto/sdk v1.1.0 h1:cH53jehLUN6UFLY71z+NDOiNJqDdPRaXzTel0sJySYA= @@ -213,8 +230,8 @@ golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACk golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.36.0 h1:AnAEvhDddvBdpY+uR+MyHmuZzzNqXSe/GvuDeob5L34= -golang.org/x/crypto v0.36.0/go.mod h1:Y4J0ReaxCR1IMaabaSMugxJES1EpwhBHhv2bDHklZvc= +golang.org/x/crypto v0.37.0 h1:kJNSjF/Xp7kU0iB2Z+9viTPMW4EqqsrywMXLJOOsXSE= +golang.org/x/crypto v0.37.0/go.mod h1:vg+k43peMZ0pUMhYmVAWysMK35e6ioLh3wB8ZCAfbVc= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= @@ -232,18 +249,20 @@ golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= -golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.38.0 h1:vRMAPTMaeGqVhG5QyLJHqNDwecKTomGeqbnfZyKlBI8= -golang.org/x/net v0.38.0/go.mod h1:ivrbrMbzFq5J41QOQh0siUuly180yBYtLp+CKbEaFx8= +golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= +golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220607020251-c690dde0001d/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/net v0.39.0 h1:ZCu7HMWDxpXpaiKdhzIfaltL9Lp31x/3fCP11bc6/fY= +golang.org/x/net v0.39.0/go.mod h1:X7NRbYVEA+ewNkCNyJ513WmMdQ3BineSwVtN2zD/d+E= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.12.0 h1:MHc5BpPuC30uJk597Ri8TV3CNZcTLu6B6z4lJy+g6Jw= -golang.org/x/sync v0.12.0/go.mod h1:1dzgHSNfp02xaA81J2MS99Qcpr2w7fw1gpm99rleRqA= +golang.org/x/sync v0.13.0 h1:AauUjRAJ9OSnvULf/ARrrVywoJDy0YS2AwQ98I37610= +golang.org/x/sync v0.13.0/go.mod h1:1dzgHSNfp02xaA81J2MS99Qcpr2w7fw1gpm99rleRqA= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -252,19 +271,28 @@ golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200814200057-3d37ad5750ed/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201101102859-da207088b7d1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.31.0 h1:ioabZlmFYtWhL+TRYpcnNlLwhyxaM9kWTDEmfnprqik= -golang.org/x/sys v0.31.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k= +golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.32.0 h1:s77OFDvIQeibCmezSnk/q6iAfkdiQaJi4VzroCFrN20= +golang.org/x/sys v0.32.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k= +golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= +golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -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.23.0 h1:D71I7dUrlY+VX0gQShAThNGHFxZ13dGLBHQLVl1mJlY= -golang.org/x/text v0.23.0/go.mod h1:/BLNzu4aZCJ1+kcD0DNRotWKage4q2rGVAg4o22unh4= +golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= +golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= +golang.org/x/text v0.24.0 h1:dd5Bzh4yt5KYA8f9CJHCP4FB4D51c2c6JvN37xJJkJ0= +golang.org/x/text v0.24.0/go.mod h1:L8rBsPeo2pSS+xqN0d5u2ikmjtmoJbDBT1b7nHvFCdU= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= @@ -276,13 +304,15 @@ golang.org/x/tools v0.0.0-20191029190741-b9c20aec41a5/go.mod h1:b+2E5dAYhXwXZwtn golang.org/x/tools v0.0.0-20191108193012-7d206e10da11/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= +golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.24.0 h1:J1shsA93PJUEVaUSaay7UXAyE8aimq3GW0pjlolpa24= -golang.org/x/tools v0.24.0/go.mod h1:YhNqVBIfWHdzvTLs0d8LCuMhkKUgSUKldakyV7W/WDQ= +golang.org/x/tools v0.26.0 h1:v/60pFQmzmT9ExmjDv2gGIfi3OqfKoEP6I5+umXlbnQ= +golang.org/x/tools v0.26.0/go.mod h1:TPVVj70c7JJ3WCazhD8OdXcZg/og+b9+tH/KxylGwH0= 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/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= @@ -303,8 +333,10 @@ google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQ google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.36.5 h1:tPhr+woSbjfYvY6/GPufUoYizxw1cF/yFoxJ2fmpwlM= -google.golang.org/protobuf v1.36.5/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE= +google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= +google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= +google.golang.org/protobuf v1.36.6 h1:z1NpPI8ku2WgiWnf+t9wTPsn6eP1L7ksHUlkfLvd9xY= +google.golang.org/protobuf v1.36.6/go.mod h1:jduwjTPXsFjZGTmRluh+L6NjiWu7pchiJ2/5YcXBHnY= gopkg.in/alecthomas/kingpin.v2 v2.2.6 h1:jMFz6MfLP0/4fUyZle81rXUoxOBFi19VUFKVDOQfozc= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= diff --git a/vendor/github.com/bits-and-blooms/bitset/bitset.go b/vendor/github.com/bits-and-blooms/bitset/bitset.go index 9f38ed3a..2e8d9cef 100644 --- a/vendor/github.com/bits-and-blooms/bitset/bitset.go +++ b/vendor/github.com/bits-and-blooms/bitset/bitset.go @@ -68,9 +68,16 @@ var base64Encoding = base64.URLEncoding // Base64StdEncoding Marshal/Unmarshal BitSet with base64.StdEncoding(Default: base64.URLEncoding) func Base64StdEncoding() { base64Encoding = base64.StdEncoding } -// LittleEndian Marshal/Unmarshal Binary as Little Endian(Default: binary.BigEndian) +// LittleEndian sets Marshal/Unmarshal Binary as Little Endian (Default: binary.BigEndian) func LittleEndian() { binaryOrder = binary.LittleEndian } +// BigEndian sets Marshal/Unmarshal Binary as Big Endian (Default: binary.BigEndian) +func BigEndian() { binaryOrder = binary.BigEndian } + +// BinaryOrder returns the current binary order, see also LittleEndian() +// and BigEndian() to change the order. +func BinaryOrder() binary.ByteOrder { return binaryOrder } + // A BitSet is a set of bits. The zero value of a BitSet is an empty set of length 0. type BitSet struct { length uint @@ -104,7 +111,9 @@ func FromWithLength(len uint, set []uint64) *BitSet { return &BitSet{len, set} } -// Bytes returns the bitset as array of words +// Bytes returns the bitset as array of 64-bit words, giving direct access to the internal representation. +// It is not a copy, so changes to the returned slice will affect the bitset. +// It is meant for advanced users. func (b *BitSet) Bytes() []uint64 { return b.set } @@ -118,7 +127,7 @@ func wordsNeeded(i uint) int { } // wordsNeededUnbound calculates the number of words needed for i bits, possibly exceeding the capacity. -// This function is useful if you know that the capacity cannot be exceeded (e.g., you have an existing bitmap). +// This function is useful if you know that the capacity cannot be exceeded (e.g., you have an existing BitSet). func wordsNeededUnbound(i uint) int { return int((i + (wordSize - 1)) >> log2WordSize) } @@ -148,12 +157,16 @@ func New(length uint) (bset *BitSet) { } // Cap returns the total possible capacity, or number of bits +// that can be stored in the BitSet theoretically. Under 32-bit system, +// it is 4294967295 and under 64-bit system, it is 18446744073709551615. +// Note that this is further limited by the maximum allocation size in Go, +// and your available memory, as any Go data structure. func Cap() uint { return ^uint(0) } // Len returns the number of bits in the BitSet. -// Note the difference to method Count, see example. +// Note that it differ from Count function. func (b *BitSet) Len() uint { return b.length } @@ -186,10 +199,10 @@ func (b *BitSet) Test(i uint) bool { // Set bit i to 1, the capacity of the bitset is automatically // increased accordingly. -// If i>= Cap(), this function will panic. // Warning: using a very large value for 'i' // may lead to a memory shortage and a panic: the caller is responsible // for providing sensible parameters in line with their memory capacity. +// The memory usage is at least slightly over i/8 bytes. func (b *BitSet) Set(i uint) *BitSet { if i >= b.length { // if we need more bits, make 'em b.extendSet(i) @@ -198,7 +211,7 @@ func (b *BitSet) Set(i uint) *BitSet { return b } -// Clear bit i to 0 +// Clear bit i to 0. This never cause a memory allocation. It is always safe. func (b *BitSet) Clear(i uint) *BitSet { if i >= b.length { return b @@ -208,7 +221,6 @@ func (b *BitSet) Clear(i uint) *BitSet { } // SetTo sets bit i to value. -// If i>= Cap(), this function will panic. // Warning: using a very large value for 'i' // may lead to a memory shortage and a panic: the caller is responsible // for providing sensible parameters in line with their memory capacity. @@ -220,7 +232,6 @@ func (b *BitSet) SetTo(i uint, value bool) *BitSet { } // Flip bit at i. -// If i>= Cap(), this function will panic. // Warning: using a very large value for 'i' // may lead to a memory shortage and a panic: the caller is responsible // for providing sensible parameters in line with their memory capacity. @@ -233,7 +244,6 @@ func (b *BitSet) Flip(i uint) *BitSet { } // FlipRange bit in [start, end). -// If end>= Cap(), this function will panic. // Warning: using a very large value for 'end' // may lead to a memory shortage and a panic: the caller is responsible // for providing sensible parameters in line with their memory capacity. @@ -275,6 +285,7 @@ func (b *BitSet) FlipRange(start, end uint) *BitSet { // memory usage until the GC runs. Normally this should not be a problem, but if you // have an extremely large BitSet its important to understand that the old BitSet will // remain in memory until the GC frees it. +// If you are memory constrained, this function may cause a panic. func (b *BitSet) Shrink(lastbitindex uint) *BitSet { length := lastbitindex + 1 idx := wordsNeeded(length) @@ -294,6 +305,11 @@ func (b *BitSet) Shrink(lastbitindex uint) *BitSet { // Compact shrinks BitSet to so that we preserve all set bits, while minimizing // memory usage. Compact calls Shrink. +// A new slice is allocated to store the new bits, so you may see an increase in +// memory usage until the GC runs. Normally this should not be a problem, but if you +// have an extremely large BitSet its important to understand that the old BitSet will +// remain in memory until the GC frees it. +// If you are memory constrained, this function may cause a panic. func (b *BitSet) Compact() *BitSet { idx := len(b.set) - 1 for ; idx >= 0 && b.set[idx] == 0; idx-- { @@ -353,7 +369,8 @@ func (b *BitSet) InsertAt(idx uint) *BitSet { return b } -// String creates a string representation of the Bitmap +// String creates a string representation of the BitSet. It is only intended for +// human-readable output and not for serialization. func (b *BitSet) String() string { // follows code from https://github.com/RoaringBitmap/roaring var buffer bytes.Buffer @@ -541,7 +558,8 @@ func (b *BitSet) NextClear(i uint) (uint, bool) { return 0, false } -// ClearAll clears the entire BitSet +// ClearAll clears the entire BitSet. +// It does not free the memory. func (b *BitSet) ClearAll() *BitSet { if b != nil && b.set != nil { for i := range b.set { @@ -737,7 +755,7 @@ func (b *BitSet) Intersection(compare *BitSet) (result *BitSet) { return } -// IntersectionCardinality computes the cardinality of the union +// IntersectionCardinality computes the cardinality of the intersection func (b *BitSet) IntersectionCardinality(compare *BitSet) uint { panicIfNull(b) panicIfNull(compare) @@ -958,6 +976,7 @@ func (b *BitSet) IsStrictSuperSet(other *BitSet) bool { // DumpAsBits dumps a bit set as a string of bits. Following the usual convention in Go, // the least significant bits are printed last (index 0 is at the end of the string). +// This is useful for debugging and testing. It is not suitable for serialization. func (b *BitSet) DumpAsBits() string { if b.set == nil { return "." @@ -1020,6 +1039,15 @@ func writeUint64Array(writer io.Writer, data []uint64) error { // WriteTo writes a BitSet to a stream. The format is: // 1. uint64 length // 2. []uint64 set +// The length is the number of bits in the BitSet. +// +// The set is a slice of uint64s containing between length and length + 63 bits. +// It is interpreted as a big-endian array of uint64s by default (see BinaryOrder()) +// meaning that the first 8 bits are stored at byte index 7, the next 8 bits are stored +// at byte index 6... the bits 64 to 71 are stored at byte index 8, etc. +// If you change the binary order, you need to do so for both reading and writing. +// We recommend using the default binary order. +// // Upon success, the number of bytes written is returned. // // Performance: if this function is used to write to a disk or network @@ -1050,6 +1078,7 @@ func (b *BitSet) WriteTo(stream io.Writer) (int64, error) { // The format is: // 1. uint64 length // 2. []uint64 set +// See WriteTo for details. // Upon success, the number of bytes read is returned. // If the current BitSet is not large enough to hold the data, // it is extended. In case of error, the BitSet is either @@ -1101,6 +1130,7 @@ func (b *BitSet) ReadFrom(stream io.Reader) (int64, error) { } // MarshalBinary encodes a BitSet into a binary form and returns the result. +// Please see WriteTo for details. func (b *BitSet) MarshalBinary() ([]byte, error) { var buf bytes.Buffer _, err := b.WriteTo(&buf) @@ -1112,6 +1142,7 @@ func (b *BitSet) MarshalBinary() ([]byte, error) { } // UnmarshalBinary decodes the binary form generated by MarshalBinary. +// Please see WriteTo for details. func (b *BitSet) UnmarshalBinary(data []byte) error { buf := bytes.NewReader(data) _, err := b.ReadFrom(buf) @@ -1182,3 +1213,121 @@ func (b *BitSet) Select(index uint) uint { } return b.length } + +// top detects the top bit set +func (b *BitSet) top() (uint, bool) { + panicIfNull(b) + + idx := len(b.set) - 1 + for ; idx >= 0 && b.set[idx] == 0; idx-- { + } + + // no set bits + if idx < 0 { + return 0, false + } + + return uint(idx)*wordSize + len64(b.set[idx]) - 1, true +} + +// ShiftLeft shifts the bitset like << operation would do. +// +// Left shift may require bitset size extension. We try to avoid the +// unnecessary memory operations by detecting the leftmost set bit. +// The function will panic if shift causes excess of capacity. +func (b *BitSet) ShiftLeft(bits uint) { + panicIfNull(b) + + if bits == 0 { + return + } + + top, ok := b.top() + if !ok { + return + } + + // capacity check + if top+bits < bits { + panic("You are exceeding the capacity") + } + + // destination set + dst := b.set + + // not using extendSet() to avoid unneeded data copying + nsize := wordsNeeded(top + bits) + if len(b.set) < nsize { + dst = make([]uint64, nsize) + } + if top+bits >= b.length { + b.length = top + bits + 1 + } + + pad, idx := top%wordSize, top>>log2WordSize + shift, pages := bits%wordSize, bits>>log2WordSize + if bits%wordSize == 0 { // happy case: just add pages + copy(dst[pages:nsize], b.set) + } else { + if pad+shift >= wordSize { + dst[idx+pages+1] = b.set[idx] >> (wordSize - shift) + } + + for i := int(idx); i >= 0; i-- { + if i > 0 { + dst[i+int(pages)] = (b.set[i] << shift) | (b.set[i-1] >> (wordSize - shift)) + } else { + dst[i+int(pages)] = b.set[i] << shift + } + } + } + + // zeroing extra pages + for i := 0; i < int(pages); i++ { + dst[i] = 0 + } + + b.set = dst +} + +// ShiftRight shifts the bitset like >> operation would do. +func (b *BitSet) ShiftRight(bits uint) { + panicIfNull(b) + + if bits == 0 { + return + } + + top, ok := b.top() + if !ok { + return + } + + if bits >= top { + b.set = make([]uint64, wordsNeeded(b.length)) + return + } + + pad, idx := top%wordSize, top>>log2WordSize + shift, pages := bits%wordSize, bits>>log2WordSize + if bits%wordSize == 0 { // happy case: just clear pages + b.set = b.set[pages:] + b.length -= pages * wordSize + } else { + for i := 0; i <= int(idx-pages); i++ { + if i < int(idx-pages) { + b.set[i] = (b.set[i+int(pages)] >> shift) | (b.set[i+int(pages)+1] << (wordSize - shift)) + } else { + b.set[i] = b.set[i+int(pages)] >> shift + } + } + + if pad < shift { + b.set[int(idx-pages)] = 0 + } + } + + for i := int(idx-pages) + 1; i <= int(idx); i++ { + b.set[i] = 0 + } +} diff --git a/vendor/github.com/bits-and-blooms/bitset/leading_zeros_18.go b/vendor/github.com/bits-and-blooms/bitset/leading_zeros_18.go new file mode 100644 index 00000000..72af1d6f --- /dev/null +++ b/vendor/github.com/bits-and-blooms/bitset/leading_zeros_18.go @@ -0,0 +1,43 @@ +//go:build !go1.9 +// +build !go1.9 + +package bitset + +var len8tab = "" + + "\x00\x01\x02\x02\x03\x03\x03\x03\x04\x04\x04\x04\x04\x04\x04\x04" + + "\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05" + + "\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06" + + "\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06\x06" + + "\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07" + + "\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07" + + "\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07" + + "\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07" + + "\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08" + + "\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08" + + "\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08" + + "\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08" + + "\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08" + + "\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08" + + "\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08" + + "\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08\x08" + +// len64 returns the minimum number of bits required to represent x; the result is 0 for x == 0. +func len64(x uint64) (n uint) { + if x >= 1<<32 { + x >>= 32 + n = 32 + } + if x >= 1<<16 { + x >>= 16 + n += 16 + } + if x >= 1<<8 { + x >>= 8 + n += 8 + } + return n + uint(len8tab[x]) +} + +func leadingZeroes64(v uint64) uint { + return 64 - len64(v) +} diff --git a/vendor/github.com/bits-and-blooms/bitset/leading_zeros_19.go b/vendor/github.com/bits-and-blooms/bitset/leading_zeros_19.go new file mode 100644 index 00000000..74a79424 --- /dev/null +++ b/vendor/github.com/bits-and-blooms/bitset/leading_zeros_19.go @@ -0,0 +1,14 @@ +//go:build go1.9 +// +build go1.9 + +package bitset + +import "math/bits" + +func len64(v uint64) uint { + return uint(bits.Len64(v)) +} + +func leadingZeroes64(v uint64) uint { + return uint(bits.LeadingZeros64(v)) +} diff --git a/vendor/github.com/google/pprof/profile/encode.go b/vendor/github.com/google/pprof/profile/encode.go index 860bb304..8ce9d3cf 100644 --- a/vendor/github.com/google/pprof/profile/encode.go +++ b/vendor/github.com/google/pprof/profile/encode.go @@ -122,6 +122,7 @@ func (p *Profile) preEncode() { } p.defaultSampleTypeX = addString(strings, p.DefaultSampleType) + p.docURLX = addString(strings, p.DocURL) p.stringTable = make([]string, len(strings)) for s, i := range strings { @@ -156,6 +157,7 @@ func (p *Profile) encode(b *buffer) { encodeInt64Opt(b, 12, p.Period) encodeInt64s(b, 13, p.commentX) encodeInt64(b, 14, p.defaultSampleTypeX) + encodeInt64Opt(b, 15, p.docURLX) } var profileDecoder = []decoder{ @@ -237,6 +239,8 @@ var profileDecoder = []decoder{ func(b *buffer, m message) error { return decodeInt64s(b, &m.(*Profile).commentX) }, // int64 defaultSampleType = 14 func(b *buffer, m message) error { return decodeInt64(b, &m.(*Profile).defaultSampleTypeX) }, + // string doc_link = 15; + func(b *buffer, m message) error { return decodeInt64(b, &m.(*Profile).docURLX) }, } // postDecode takes the unexported fields populated by decode (with @@ -384,6 +388,7 @@ func (p *Profile) postDecode() error { p.commentX = nil p.DefaultSampleType, err = getString(p.stringTable, &p.defaultSampleTypeX, err) + p.DocURL, err = getString(p.stringTable, &p.docURLX, err) p.stringTable = nil return err } diff --git a/vendor/github.com/google/pprof/profile/merge.go b/vendor/github.com/google/pprof/profile/merge.go index eee0132e..ba4d7464 100644 --- a/vendor/github.com/google/pprof/profile/merge.go +++ b/vendor/github.com/google/pprof/profile/merge.go @@ -476,6 +476,7 @@ func combineHeaders(srcs []*Profile) (*Profile, error) { var timeNanos, durationNanos, period int64 var comments []string seenComments := map[string]bool{} + var docURL string var defaultSampleType string for _, s := range srcs { if timeNanos == 0 || s.TimeNanos < timeNanos { @@ -494,6 +495,9 @@ func combineHeaders(srcs []*Profile) (*Profile, error) { if defaultSampleType == "" { defaultSampleType = s.DefaultSampleType } + if docURL == "" { + docURL = s.DocURL + } } p := &Profile{ @@ -509,6 +513,7 @@ func combineHeaders(srcs []*Profile) (*Profile, error) { Comments: comments, DefaultSampleType: defaultSampleType, + DocURL: docURL, } copy(p.SampleType, srcs[0].SampleType) return p, nil diff --git a/vendor/github.com/google/pprof/profile/profile.go b/vendor/github.com/google/pprof/profile/profile.go index 5551eb0b..f47a2439 100644 --- a/vendor/github.com/google/pprof/profile/profile.go +++ b/vendor/github.com/google/pprof/profile/profile.go @@ -39,6 +39,7 @@ type Profile struct { Location []*Location Function []*Function Comments []string + DocURL string DropFrames string KeepFrames string @@ -53,6 +54,7 @@ type Profile struct { encodeMu sync.Mutex commentX []int64 + docURLX int64 dropFramesX int64 keepFramesX int64 stringTable []string @@ -555,6 +557,9 @@ func (p *Profile) String() string { for _, c := range p.Comments { ss = append(ss, "Comment: "+c) } + if url := p.DocURL; url != "" { + ss = append(ss, fmt.Sprintf("Doc: %s", url)) + } if pt := p.PeriodType; pt != nil { ss = append(ss, fmt.Sprintf("PeriodType: %s %s", pt.Type, pt.Unit)) } @@ -844,7 +849,7 @@ func (p *Profile) HasFileLines() bool { // Unsymbolizable returns true if a mapping points to a binary for which // locations can't be symbolized in principle, at least now. Examples are -// "[vdso]", [vsyscall]" and some others, see the code. +// "[vdso]", "[vsyscall]" and some others, see the code. func (m *Mapping) Unsymbolizable() bool { name := filepath.Base(m.File) return strings.HasPrefix(name, "[") || strings.HasPrefix(name, "linux-vdso") || strings.HasPrefix(m.File, "/dev/dri/") || m.File == "//anon" diff --git a/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/controller.go b/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/controller.go index 9ced3bb4..df9b73bb 100644 --- a/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/controller.go +++ b/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/controller.go @@ -72,6 +72,7 @@ type Proposer interface { Start() Abort() Stopped() bool + AbortChan() <-chan struct{} GetLeaderID() uint64 GetMetadata() []byte HandleMessage(sender uint64, m *protos.Message) @@ -171,6 +172,14 @@ func (c *Controller) currentViewStopped() bool { return view.Stopped() } +func (c *Controller) currentViewAbortChan() <-chan struct{} { + c.currViewLock.RLock() + view := c.currView + c.currViewLock.RUnlock() + + return view.AbortChan() +} + func (c *Controller) currentViewLeader() uint64 { c.currViewLock.RLock() view := c.currView @@ -785,7 +794,7 @@ func (c *Controller) Start(startViewNumber uint64, startProposalSequence uint64, c.syncChan = make(chan struct{}, 1) c.stopChan = make(chan struct{}) c.leaderToken = make(chan struct{}, 1) - c.decisionChan = make(chan decision) + c.decisionChan = make(chan decision, 1) c.deliverChan = make(chan struct{}) c.viewChange = make(chan viewInfo, 1) c.abortViewChan = make(chan uint64, 1) @@ -886,6 +895,7 @@ func (c *Controller) Decide(proposal types.Proposal, signatures []types.Signatur select { case <-c.deliverChan: // wait for the delivery of the decision to the application case <-c.stopChan: // If we stopped the controller, abort delivery + case <-c.currentViewAbortChan(): // If we stopped the view, abort delivery } } diff --git a/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/requestpool.go b/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/requestpool.go index 5b4242cc..d53e31d1 100644 --- a/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/requestpool.go +++ b/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/requestpool.go @@ -304,7 +304,7 @@ func (rp *Pool) NextRequests(maxCount int, maxSizeBytes uint64, check bool) (bat } } - count := minInt(rp.fifo.Len(), maxCount) + count := min(rp.fifo.Len(), maxCount) var totalSize uint64 batch = make([][]byte, 0, count) element := rp.fifo.Front() diff --git a/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/util.go b/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/util.go index 195b7f42..b8698386 100644 --- a/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/util.go +++ b/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/util.go @@ -60,13 +60,6 @@ func proposalSequence(m *protos.Message) uint64 { return math.MaxUint64 } -func minInt(a, b int) int { - if a < b { - return a - } - return b -} - // MarshalOrPanic marshals or panics when an error occurs func MarshalOrPanic(msg proto.Message) []byte { b, err := proto.Marshal(msg) diff --git a/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/view.go b/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/view.go index 76477d86..16878efe 100644 --- a/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/view.go +++ b/vendor/github.com/hyperledger-labs/SmartBFT/internal/bft/view.go @@ -949,7 +949,10 @@ func (v *View) metadataWithUpdatedBlacklist(metadata *protos.ViewMetadata, verif // Propose broadcasts a prePrepare message with the given proposal func (v *View) Propose(proposal types.Proposal) { - _, prevSigs := v.RetrieveCheckpoint() + var prevSigs []*protos.Signature + if v.DecisionsPerLeader > 0 { + _, prevSigs = v.RetrieveCheckpoint() + } seq := v.ProposalSequence msg := &protos.Message{ @@ -1012,6 +1015,10 @@ func (v *View) Stopped() bool { } } +func (v *View) AbortChan() <-chan struct{} { + return v.abortChan +} + func (v *View) GetLeaderID() uint64 { return v.LeaderID } diff --git a/vendor/github.com/hyperledger-labs/SmartBFT/pkg/types/config.go b/vendor/github.com/hyperledger-labs/SmartBFT/pkg/types/config.go index 86144daf..55e14902 100644 --- a/vendor/github.com/hyperledger-labs/SmartBFT/pkg/types/config.go +++ b/vendor/github.com/hyperledger-labs/SmartBFT/pkg/types/config.go @@ -161,6 +161,9 @@ func (c Configuration) Validate() error { if c.RequestBatchMaxCount > c.RequestBatchMaxBytes { return errors.New("RequestBatchMaxCount is bigger than RequestBatchMaxBytes") } + if c.RequestMaxBytes > c.RequestBatchMaxBytes { + return errors.New("RequestMaxBytes is bigger than RequestBatchMaxBytes") + } if c.RequestForwardTimeout > c.RequestComplainTimeout { return errors.New("RequestForwardTimeout is bigger than RequestComplainTimeout") } diff --git a/vendor/github.com/hyperledger-labs/SmartBFT/smartbftprotos/logrecord.pb.go b/vendor/github.com/hyperledger-labs/SmartBFT/smartbftprotos/logrecord.pb.go index b94c7bea..49715638 100644 --- a/vendor/github.com/hyperledger-labs/SmartBFT/smartbftprotos/logrecord.pb.go +++ b/vendor/github.com/hyperledger-labs/SmartBFT/smartbftprotos/logrecord.pb.go @@ -5,9 +5,9 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.29.1 -// protoc v3.21.12 -// source: logrecord.proto +// protoc-gen-go v1.36.5 +// protoc v5.29.3 +// source: smartbftprotos/logrecord.proto package smartbftprotos @@ -16,6 +16,7 @@ import ( protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + unsafe "unsafe" ) const ( @@ -58,11 +59,11 @@ func (x LogRecord_Type) String() string { } func (LogRecord_Type) Descriptor() protoreflect.EnumDescriptor { - return file_logrecord_proto_enumTypes[0].Descriptor() + return file_smartbftprotos_logrecord_proto_enumTypes[0].Descriptor() } func (LogRecord_Type) Type() protoreflect.EnumType { - return &file_logrecord_proto_enumTypes[0] + return &file_smartbftprotos_logrecord_proto_enumTypes[0] } func (x LogRecord_Type) Number() protoreflect.EnumNumber { @@ -71,26 +72,23 @@ func (x LogRecord_Type) Number() protoreflect.EnumNumber { // Deprecated: Use LogRecord_Type.Descriptor instead. func (LogRecord_Type) EnumDescriptor() ([]byte, []int) { - return file_logrecord_proto_rawDescGZIP(), []int{0, 0} + return file_smartbftprotos_logrecord_proto_rawDescGZIP(), []int{0, 0} } type LogRecord struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + Type LogRecord_Type `protobuf:"varint,1,opt,name=type,proto3,enum=smartbftprotos.LogRecord_Type" json:"type,omitempty"` + TruncateTo bool `protobuf:"varint,2,opt,name=truncate_to,json=truncateTo,proto3" json:"truncate_to,omitempty"` + Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` unknownFields protoimpl.UnknownFields - - Type LogRecord_Type `protobuf:"varint,1,opt,name=type,proto3,enum=smartbftprotos.LogRecord_Type" json:"type,omitempty"` - TruncateTo bool `protobuf:"varint,2,opt,name=truncate_to,json=truncateTo,proto3" json:"truncate_to,omitempty"` - Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` + sizeCache protoimpl.SizeCache } func (x *LogRecord) Reset() { *x = LogRecord{} - if protoimpl.UnsafeEnabled { - mi := &file_logrecord_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_logrecord_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LogRecord) String() string { @@ -100,8 +98,8 @@ func (x *LogRecord) String() string { func (*LogRecord) ProtoMessage() {} func (x *LogRecord) ProtoReflect() protoreflect.Message { - mi := &file_logrecord_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_logrecord_proto_msgTypes[0] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -113,7 +111,7 @@ func (x *LogRecord) ProtoReflect() protoreflect.Message { // Deprecated: Use LogRecord.ProtoReflect.Descriptor instead. func (*LogRecord) Descriptor() ([]byte, []int) { - return file_logrecord_proto_rawDescGZIP(), []int{0} + return file_smartbftprotos_logrecord_proto_rawDescGZIP(), []int{0} } func (x *LogRecord) GetType() LogRecord_Type { @@ -137,47 +135,48 @@ func (x *LogRecord) GetData() []byte { return nil } -var File_logrecord_proto protoreflect.FileDescriptor - -var file_logrecord_proto_rawDesc = []byte{ - 0x0a, 0x0f, 0x6c, 0x6f, 0x67, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x12, 0x0e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x73, 0x22, 0xa4, 0x01, 0x0a, 0x09, 0x4c, 0x6f, 0x67, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12, - 0x32, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1e, 0x2e, - 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x4c, - 0x6f, 0x67, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, - 0x79, 0x70, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x74, 0x72, 0x75, 0x6e, 0x63, 0x61, 0x74, 0x65, 0x5f, - 0x74, 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x74, 0x72, 0x75, 0x6e, 0x63, 0x61, - 0x74, 0x65, 0x54, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0x2e, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, - 0x12, 0x09, 0x0a, 0x05, 0x45, 0x4e, 0x54, 0x52, 0x59, 0x10, 0x00, 0x12, 0x0b, 0x0a, 0x07, 0x43, - 0x4f, 0x4e, 0x54, 0x52, 0x4f, 0x4c, 0x10, 0x01, 0x12, 0x0e, 0x0a, 0x0a, 0x43, 0x52, 0x43, 0x5f, - 0x41, 0x4e, 0x43, 0x48, 0x4f, 0x52, 0x10, 0x02, 0x42, 0x31, 0x5a, 0x2f, 0x67, 0x69, 0x74, 0x68, - 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x53, 0x6d, 0x61, 0x72, 0x74, 0x42, 0x46, 0x54, 0x2d, - 0x47, 0x6f, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2f, 0x73, 0x6d, 0x61, - 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x33, -} +var File_smartbftprotos_logrecord_proto protoreflect.FileDescriptor + +var file_smartbftprotos_logrecord_proto_rawDesc = string([]byte{ + 0x0a, 0x1e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, + 0x2f, 0x6c, 0x6f, 0x67, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x12, 0x0e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, + 0x22, 0xa4, 0x01, 0x0a, 0x09, 0x4c, 0x6f, 0x67, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12, 0x32, + 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1e, 0x2e, 0x73, + 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x4c, 0x6f, + 0x67, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, 0x79, + 0x70, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x74, 0x72, 0x75, 0x6e, 0x63, 0x61, 0x74, 0x65, 0x5f, 0x74, + 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x74, 0x72, 0x75, 0x6e, 0x63, 0x61, 0x74, + 0x65, 0x54, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0x2e, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, + 0x09, 0x0a, 0x05, 0x45, 0x4e, 0x54, 0x52, 0x59, 0x10, 0x00, 0x12, 0x0b, 0x0a, 0x07, 0x43, 0x4f, + 0x4e, 0x54, 0x52, 0x4f, 0x4c, 0x10, 0x01, 0x12, 0x0e, 0x0a, 0x0a, 0x43, 0x52, 0x43, 0x5f, 0x41, + 0x4e, 0x43, 0x48, 0x4f, 0x52, 0x10, 0x02, 0x42, 0x35, 0x5a, 0x33, 0x67, 0x69, 0x74, 0x68, 0x75, + 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x68, 0x79, 0x70, 0x65, 0x72, 0x6c, 0x65, 0x64, 0x67, 0x65, + 0x72, 0x2d, 0x6c, 0x61, 0x62, 0x73, 0x2f, 0x53, 0x6d, 0x61, 0x72, 0x74, 0x42, 0x46, 0x54, 0x2f, + 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +}) var ( - file_logrecord_proto_rawDescOnce sync.Once - file_logrecord_proto_rawDescData = file_logrecord_proto_rawDesc + file_smartbftprotos_logrecord_proto_rawDescOnce sync.Once + file_smartbftprotos_logrecord_proto_rawDescData []byte ) -func file_logrecord_proto_rawDescGZIP() []byte { - file_logrecord_proto_rawDescOnce.Do(func() { - file_logrecord_proto_rawDescData = protoimpl.X.CompressGZIP(file_logrecord_proto_rawDescData) +func file_smartbftprotos_logrecord_proto_rawDescGZIP() []byte { + file_smartbftprotos_logrecord_proto_rawDescOnce.Do(func() { + file_smartbftprotos_logrecord_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_smartbftprotos_logrecord_proto_rawDesc), len(file_smartbftprotos_logrecord_proto_rawDesc))) }) - return file_logrecord_proto_rawDescData + return file_smartbftprotos_logrecord_proto_rawDescData } -var file_logrecord_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_logrecord_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_logrecord_proto_goTypes = []interface{}{ +var file_smartbftprotos_logrecord_proto_enumTypes = make([]protoimpl.EnumInfo, 1) +var file_smartbftprotos_logrecord_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_smartbftprotos_logrecord_proto_goTypes = []any{ (LogRecord_Type)(0), // 0: smartbftprotos.LogRecord.Type (*LogRecord)(nil), // 1: smartbftprotos.LogRecord } -var file_logrecord_proto_depIdxs = []int32{ +var file_smartbftprotos_logrecord_proto_depIdxs = []int32{ 0, // 0: smartbftprotos.LogRecord.type:type_name -> smartbftprotos.LogRecord.Type 1, // [1:1] is the sub-list for method output_type 1, // [1:1] is the sub-list for method input_type @@ -186,42 +185,27 @@ var file_logrecord_proto_depIdxs = []int32{ 0, // [0:1] is the sub-list for field type_name } -func init() { file_logrecord_proto_init() } -func file_logrecord_proto_init() { - if File_logrecord_proto != nil { +func init() { file_smartbftprotos_logrecord_proto_init() } +func file_smartbftprotos_logrecord_proto_init() { + if File_smartbftprotos_logrecord_proto != nil { return } - if !protoimpl.UnsafeEnabled { - file_logrecord_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*LogRecord); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: file_logrecord_proto_rawDesc, + RawDescriptor: unsafe.Slice(unsafe.StringData(file_smartbftprotos_logrecord_proto_rawDesc), len(file_smartbftprotos_logrecord_proto_rawDesc)), NumEnums: 1, NumMessages: 1, NumExtensions: 0, NumServices: 0, }, - GoTypes: file_logrecord_proto_goTypes, - DependencyIndexes: file_logrecord_proto_depIdxs, - EnumInfos: file_logrecord_proto_enumTypes, - MessageInfos: file_logrecord_proto_msgTypes, + GoTypes: file_smartbftprotos_logrecord_proto_goTypes, + DependencyIndexes: file_smartbftprotos_logrecord_proto_depIdxs, + EnumInfos: file_smartbftprotos_logrecord_proto_enumTypes, + MessageInfos: file_smartbftprotos_logrecord_proto_msgTypes, }.Build() - File_logrecord_proto = out.File - file_logrecord_proto_rawDesc = nil - file_logrecord_proto_goTypes = nil - file_logrecord_proto_depIdxs = nil + File_smartbftprotos_logrecord_proto = out.File + file_smartbftprotos_logrecord_proto_goTypes = nil + file_smartbftprotos_logrecord_proto_depIdxs = nil } diff --git a/vendor/github.com/hyperledger-labs/SmartBFT/smartbftprotos/messages.pb.go b/vendor/github.com/hyperledger-labs/SmartBFT/smartbftprotos/messages.pb.go index a9e2244a..b9abdc19 100644 --- a/vendor/github.com/hyperledger-labs/SmartBFT/smartbftprotos/messages.pb.go +++ b/vendor/github.com/hyperledger-labs/SmartBFT/smartbftprotos/messages.pb.go @@ -5,9 +5,9 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.29.1 -// protoc v3.21.12 -// source: messages.proto +// protoc-gen-go v1.36.5 +// protoc v5.29.3 +// source: smartbftprotos/messages.proto package smartbftprotos @@ -16,6 +16,7 @@ import ( protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + unsafe "unsafe" ) const ( @@ -26,11 +27,9 @@ const ( ) type Message struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // Types that are assignable to Content: + state protoimpl.MessageState `protogen:"open.v1"` + // Types that are valid to be assigned to Content: + // // *Message_PrePrepare // *Message_Prepare // *Message_Commit @@ -41,16 +40,16 @@ type Message struct { // *Message_HeartBeatResponse // *Message_StateTransferRequest // *Message_StateTransferResponse - Content isMessage_Content `protobuf_oneof:"content"` + Content isMessage_Content `protobuf_oneof:"content"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } func (x *Message) Reset() { *x = Message{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Message) String() string { @@ -60,8 +59,8 @@ func (x *Message) String() string { func (*Message) ProtoMessage() {} func (x *Message) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[0] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -73,82 +72,102 @@ func (x *Message) ProtoReflect() protoreflect.Message { // Deprecated: Use Message.ProtoReflect.Descriptor instead. func (*Message) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{0} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{0} } -func (m *Message) GetContent() isMessage_Content { - if m != nil { - return m.Content +func (x *Message) GetContent() isMessage_Content { + if x != nil { + return x.Content } return nil } func (x *Message) GetPrePrepare() *PrePrepare { - if x, ok := x.GetContent().(*Message_PrePrepare); ok { - return x.PrePrepare + if x != nil { + if x, ok := x.Content.(*Message_PrePrepare); ok { + return x.PrePrepare + } } return nil } func (x *Message) GetPrepare() *Prepare { - if x, ok := x.GetContent().(*Message_Prepare); ok { - return x.Prepare + if x != nil { + if x, ok := x.Content.(*Message_Prepare); ok { + return x.Prepare + } } return nil } func (x *Message) GetCommit() *Commit { - if x, ok := x.GetContent().(*Message_Commit); ok { - return x.Commit + if x != nil { + if x, ok := x.Content.(*Message_Commit); ok { + return x.Commit + } } return nil } func (x *Message) GetViewChange() *ViewChange { - if x, ok := x.GetContent().(*Message_ViewChange); ok { - return x.ViewChange + if x != nil { + if x, ok := x.Content.(*Message_ViewChange); ok { + return x.ViewChange + } } return nil } func (x *Message) GetViewData() *SignedViewData { - if x, ok := x.GetContent().(*Message_ViewData); ok { - return x.ViewData + if x != nil { + if x, ok := x.Content.(*Message_ViewData); ok { + return x.ViewData + } } return nil } func (x *Message) GetNewView() *NewView { - if x, ok := x.GetContent().(*Message_NewView); ok { - return x.NewView + if x != nil { + if x, ok := x.Content.(*Message_NewView); ok { + return x.NewView + } } return nil } func (x *Message) GetHeartBeat() *HeartBeat { - if x, ok := x.GetContent().(*Message_HeartBeat); ok { - return x.HeartBeat + if x != nil { + if x, ok := x.Content.(*Message_HeartBeat); ok { + return x.HeartBeat + } } return nil } func (x *Message) GetHeartBeatResponse() *HeartBeatResponse { - if x, ok := x.GetContent().(*Message_HeartBeatResponse); ok { - return x.HeartBeatResponse + if x != nil { + if x, ok := x.Content.(*Message_HeartBeatResponse); ok { + return x.HeartBeatResponse + } } return nil } func (x *Message) GetStateTransferRequest() *StateTransferRequest { - if x, ok := x.GetContent().(*Message_StateTransferRequest); ok { - return x.StateTransferRequest + if x != nil { + if x, ok := x.Content.(*Message_StateTransferRequest); ok { + return x.StateTransferRequest + } } return nil } func (x *Message) GetStateTransferResponse() *StateTransferResponse { - if x, ok := x.GetContent().(*Message_StateTransferResponse); ok { - return x.StateTransferResponse + if x != nil { + if x, ok := x.Content.(*Message_StateTransferResponse); ok { + return x.StateTransferResponse + } } return nil } @@ -218,23 +237,20 @@ func (*Message_StateTransferRequest) isMessage_Content() {} func (*Message_StateTransferResponse) isMessage_Content() {} type PrePrepare struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - View uint64 `protobuf:"varint,1,opt,name=view,proto3" json:"view,omitempty"` - Seq uint64 `protobuf:"varint,2,opt,name=seq,proto3" json:"seq,omitempty"` - Proposal *Proposal `protobuf:"bytes,3,opt,name=proposal,proto3" json:"proposal,omitempty"` - PrevCommitSignatures []*Signature `protobuf:"bytes,4,rep,name=prev_commit_signatures,json=prevCommitSignatures,proto3" json:"prev_commit_signatures,omitempty"` + state protoimpl.MessageState `protogen:"open.v1"` + View uint64 `protobuf:"varint,1,opt,name=view,proto3" json:"view,omitempty"` + Seq uint64 `protobuf:"varint,2,opt,name=seq,proto3" json:"seq,omitempty"` + Proposal *Proposal `protobuf:"bytes,3,opt,name=proposal,proto3" json:"proposal,omitempty"` + PrevCommitSignatures []*Signature `protobuf:"bytes,4,rep,name=prev_commit_signatures,json=prevCommitSignatures,proto3" json:"prev_commit_signatures,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } func (x *PrePrepare) Reset() { *x = PrePrepare{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PrePrepare) String() string { @@ -244,8 +260,8 @@ func (x *PrePrepare) String() string { func (*PrePrepare) ProtoMessage() {} func (x *PrePrepare) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[1] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -257,7 +273,7 @@ func (x *PrePrepare) ProtoReflect() protoreflect.Message { // Deprecated: Use PrePrepare.ProtoReflect.Descriptor instead. func (*PrePrepare) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{1} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{1} } func (x *PrePrepare) GetView() uint64 { @@ -289,23 +305,20 @@ func (x *PrePrepare) GetPrevCommitSignatures() []*Signature { } type Prepare struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + View uint64 `protobuf:"varint,1,opt,name=view,proto3" json:"view,omitempty"` + Seq uint64 `protobuf:"varint,2,opt,name=seq,proto3" json:"seq,omitempty"` + Digest string `protobuf:"bytes,3,opt,name=digest,proto3" json:"digest,omitempty"` + Assist bool `protobuf:"varint,4,opt,name=assist,proto3" json:"assist,omitempty"` unknownFields protoimpl.UnknownFields - - View uint64 `protobuf:"varint,1,opt,name=view,proto3" json:"view,omitempty"` - Seq uint64 `protobuf:"varint,2,opt,name=seq,proto3" json:"seq,omitempty"` - Digest string `protobuf:"bytes,3,opt,name=digest,proto3" json:"digest,omitempty"` - Assist bool `protobuf:"varint,4,opt,name=assist,proto3" json:"assist,omitempty"` + sizeCache protoimpl.SizeCache } func (x *Prepare) Reset() { *x = Prepare{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Prepare) String() string { @@ -315,8 +328,8 @@ func (x *Prepare) String() string { func (*Prepare) ProtoMessage() {} func (x *Prepare) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[2] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -328,7 +341,7 @@ func (x *Prepare) ProtoReflect() protoreflect.Message { // Deprecated: Use Prepare.ProtoReflect.Descriptor instead. func (*Prepare) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{2} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{2} } func (x *Prepare) GetView() uint64 { @@ -360,21 +373,18 @@ func (x *Prepare) GetAssist() bool { } type ProposedRecord struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + PrePrepare *PrePrepare `protobuf:"bytes,1,opt,name=pre_prepare,json=prePrepare,proto3" json:"pre_prepare,omitempty"` + Prepare *Prepare `protobuf:"bytes,2,opt,name=prepare,proto3" json:"prepare,omitempty"` unknownFields protoimpl.UnknownFields - - PrePrepare *PrePrepare `protobuf:"bytes,1,opt,name=pre_prepare,json=prePrepare,proto3" json:"pre_prepare,omitempty"` - Prepare *Prepare `protobuf:"bytes,2,opt,name=prepare,proto3" json:"prepare,omitempty"` + sizeCache protoimpl.SizeCache } func (x *ProposedRecord) Reset() { *x = ProposedRecord{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProposedRecord) String() string { @@ -384,8 +394,8 @@ func (x *ProposedRecord) String() string { func (*ProposedRecord) ProtoMessage() {} func (x *ProposedRecord) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[3] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -397,7 +407,7 @@ func (x *ProposedRecord) ProtoReflect() protoreflect.Message { // Deprecated: Use ProposedRecord.ProtoReflect.Descriptor instead. func (*ProposedRecord) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{3} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{3} } func (x *ProposedRecord) GetPrePrepare() *PrePrepare { @@ -415,24 +425,21 @@ func (x *ProposedRecord) GetPrepare() *Prepare { } type Commit struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + View uint64 `protobuf:"varint,1,opt,name=view,proto3" json:"view,omitempty"` + Seq uint64 `protobuf:"varint,2,opt,name=seq,proto3" json:"seq,omitempty"` + Digest string `protobuf:"bytes,3,opt,name=digest,proto3" json:"digest,omitempty"` + Signature *Signature `protobuf:"bytes,4,opt,name=signature,proto3" json:"signature,omitempty"` + Assist bool `protobuf:"varint,5,opt,name=assist,proto3" json:"assist,omitempty"` unknownFields protoimpl.UnknownFields - - View uint64 `protobuf:"varint,1,opt,name=view,proto3" json:"view,omitempty"` - Seq uint64 `protobuf:"varint,2,opt,name=seq,proto3" json:"seq,omitempty"` - Digest string `protobuf:"bytes,3,opt,name=digest,proto3" json:"digest,omitempty"` - Signature *Signature `protobuf:"bytes,4,opt,name=signature,proto3" json:"signature,omitempty"` - Assist bool `protobuf:"varint,5,opt,name=assist,proto3" json:"assist,omitempty"` + sizeCache protoimpl.SizeCache } func (x *Commit) Reset() { *x = Commit{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Commit) String() string { @@ -442,8 +449,8 @@ func (x *Commit) String() string { func (*Commit) ProtoMessage() {} func (x *Commit) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[4] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -455,7 +462,7 @@ func (x *Commit) ProtoReflect() protoreflect.Message { // Deprecated: Use Commit.ProtoReflect.Descriptor instead. func (*Commit) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{4} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{4} } func (x *Commit) GetView() uint64 { @@ -494,20 +501,17 @@ func (x *Commit) GetAssist() bool { } type PreparesFrom struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + Ids []uint64 `protobuf:"varint,1,rep,packed,name=ids,proto3" json:"ids,omitempty"` unknownFields protoimpl.UnknownFields - - Ids []uint64 `protobuf:"varint,1,rep,packed,name=ids,proto3" json:"ids,omitempty"` + sizeCache protoimpl.SizeCache } func (x *PreparesFrom) Reset() { *x = PreparesFrom{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PreparesFrom) String() string { @@ -517,8 +521,8 @@ func (x *PreparesFrom) String() string { func (*PreparesFrom) ProtoMessage() {} func (x *PreparesFrom) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[5] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -530,7 +534,7 @@ func (x *PreparesFrom) ProtoReflect() protoreflect.Message { // Deprecated: Use PreparesFrom.ProtoReflect.Descriptor instead. func (*PreparesFrom) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{5} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{5} } func (x *PreparesFrom) GetIds() []uint64 { @@ -541,21 +545,18 @@ func (x *PreparesFrom) GetIds() []uint64 { } type ViewChange struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + NextView uint64 `protobuf:"varint,1,opt,name=next_view,json=nextView,proto3" json:"next_view,omitempty"` + Reason string `protobuf:"bytes,2,opt,name=reason,proto3" json:"reason,omitempty"` unknownFields protoimpl.UnknownFields - - NextView uint64 `protobuf:"varint,1,opt,name=next_view,json=nextView,proto3" json:"next_view,omitempty"` - Reason string `protobuf:"bytes,2,opt,name=reason,proto3" json:"reason,omitempty"` + sizeCache protoimpl.SizeCache } func (x *ViewChange) Reset() { *x = ViewChange{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ViewChange) String() string { @@ -565,8 +566,8 @@ func (x *ViewChange) String() string { func (*ViewChange) ProtoMessage() {} func (x *ViewChange) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[6] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -578,7 +579,7 @@ func (x *ViewChange) ProtoReflect() protoreflect.Message { // Deprecated: Use ViewChange.ProtoReflect.Descriptor instead. func (*ViewChange) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{6} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{6} } func (x *ViewChange) GetNextView() uint64 { @@ -596,24 +597,21 @@ func (x *ViewChange) GetReason() string { } type ViewData struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - NextView uint64 `protobuf:"varint,1,opt,name=next_view,json=nextView,proto3" json:"next_view,omitempty"` - LastDecision *Proposal `protobuf:"bytes,2,opt,name=last_decision,json=lastDecision,proto3" json:"last_decision,omitempty"` - LastDecisionSignatures []*Signature `protobuf:"bytes,3,rep,name=last_decision_signatures,json=lastDecisionSignatures,proto3" json:"last_decision_signatures,omitempty"` - InFlightProposal *Proposal `protobuf:"bytes,4,opt,name=in_flight_proposal,json=inFlightProposal,proto3" json:"in_flight_proposal,omitempty"` - InFlightPrepared bool `protobuf:"varint,5,opt,name=in_flight_prepared,json=inFlightPrepared,proto3" json:"in_flight_prepared,omitempty"` + state protoimpl.MessageState `protogen:"open.v1"` + NextView uint64 `protobuf:"varint,1,opt,name=next_view,json=nextView,proto3" json:"next_view,omitempty"` + LastDecision *Proposal `protobuf:"bytes,2,opt,name=last_decision,json=lastDecision,proto3" json:"last_decision,omitempty"` + LastDecisionSignatures []*Signature `protobuf:"bytes,3,rep,name=last_decision_signatures,json=lastDecisionSignatures,proto3" json:"last_decision_signatures,omitempty"` + InFlightProposal *Proposal `protobuf:"bytes,4,opt,name=in_flight_proposal,json=inFlightProposal,proto3" json:"in_flight_proposal,omitempty"` + InFlightPrepared bool `protobuf:"varint,5,opt,name=in_flight_prepared,json=inFlightPrepared,proto3" json:"in_flight_prepared,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } func (x *ViewData) Reset() { *x = ViewData{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ViewData) String() string { @@ -623,8 +621,8 @@ func (x *ViewData) String() string { func (*ViewData) ProtoMessage() {} func (x *ViewData) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[7] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -636,7 +634,7 @@ func (x *ViewData) ProtoReflect() protoreflect.Message { // Deprecated: Use ViewData.ProtoReflect.Descriptor instead. func (*ViewData) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{7} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{7} } func (x *ViewData) GetNextView() uint64 { @@ -675,22 +673,19 @@ func (x *ViewData) GetInFlightPrepared() bool { } type SignedViewData struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + RawViewData []byte `protobuf:"bytes,1,opt,name=raw_view_data,json=rawViewData,proto3" json:"raw_view_data,omitempty"` + Signer uint64 `protobuf:"varint,2,opt,name=signer,proto3" json:"signer,omitempty"` + Signature []byte `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"` unknownFields protoimpl.UnknownFields - - RawViewData []byte `protobuf:"bytes,1,opt,name=raw_view_data,json=rawViewData,proto3" json:"raw_view_data,omitempty"` - Signer uint64 `protobuf:"varint,2,opt,name=signer,proto3" json:"signer,omitempty"` - Signature []byte `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"` + sizeCache protoimpl.SizeCache } func (x *SignedViewData) Reset() { *x = SignedViewData{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SignedViewData) String() string { @@ -700,8 +695,8 @@ func (x *SignedViewData) String() string { func (*SignedViewData) ProtoMessage() {} func (x *SignedViewData) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[8] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -713,7 +708,7 @@ func (x *SignedViewData) ProtoReflect() protoreflect.Message { // Deprecated: Use SignedViewData.ProtoReflect.Descriptor instead. func (*SignedViewData) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{8} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{8} } func (x *SignedViewData) GetRawViewData() []byte { @@ -738,20 +733,17 @@ func (x *SignedViewData) GetSignature() []byte { } type NewView struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - SignedViewData []*SignedViewData `protobuf:"bytes,2,rep,name=signed_view_data,json=signedViewData,proto3" json:"signed_view_data,omitempty"` + state protoimpl.MessageState `protogen:"open.v1"` + SignedViewData []*SignedViewData `protobuf:"bytes,2,rep,name=signed_view_data,json=signedViewData,proto3" json:"signed_view_data,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } func (x *NewView) Reset() { *x = NewView{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *NewView) String() string { @@ -761,8 +753,8 @@ func (x *NewView) String() string { func (*NewView) ProtoMessage() {} func (x *NewView) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[9] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -774,7 +766,7 @@ func (x *NewView) ProtoReflect() protoreflect.Message { // Deprecated: Use NewView.ProtoReflect.Descriptor instead. func (*NewView) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{9} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{9} } func (x *NewView) GetSignedViewData() []*SignedViewData { @@ -785,21 +777,18 @@ func (x *NewView) GetSignedViewData() []*SignedViewData { } type HeartBeat struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + View uint64 `protobuf:"varint,1,opt,name=view,proto3" json:"view,omitempty"` + Seq uint64 `protobuf:"varint,2,opt,name=seq,proto3" json:"seq,omitempty"` unknownFields protoimpl.UnknownFields - - View uint64 `protobuf:"varint,1,opt,name=view,proto3" json:"view,omitempty"` - Seq uint64 `protobuf:"varint,2,opt,name=seq,proto3" json:"seq,omitempty"` + sizeCache protoimpl.SizeCache } func (x *HeartBeat) Reset() { *x = HeartBeat{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *HeartBeat) String() string { @@ -809,8 +798,8 @@ func (x *HeartBeat) String() string { func (*HeartBeat) ProtoMessage() {} func (x *HeartBeat) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[10] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -822,7 +811,7 @@ func (x *HeartBeat) ProtoReflect() protoreflect.Message { // Deprecated: Use HeartBeat.ProtoReflect.Descriptor instead. func (*HeartBeat) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{10} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{10} } func (x *HeartBeat) GetView() uint64 { @@ -840,20 +829,17 @@ func (x *HeartBeat) GetSeq() uint64 { } type HeartBeatResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + View uint64 `protobuf:"varint,1,opt,name=view,proto3" json:"view,omitempty"` unknownFields protoimpl.UnknownFields - - View uint64 `protobuf:"varint,1,opt,name=view,proto3" json:"view,omitempty"` + sizeCache protoimpl.SizeCache } func (x *HeartBeatResponse) Reset() { *x = HeartBeatResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *HeartBeatResponse) String() string { @@ -863,8 +849,8 @@ func (x *HeartBeatResponse) String() string { func (*HeartBeatResponse) ProtoMessage() {} func (x *HeartBeatResponse) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[11] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -876,7 +862,7 @@ func (x *HeartBeatResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use HeartBeatResponse.ProtoReflect.Descriptor instead. func (*HeartBeatResponse) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{11} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{11} } func (x *HeartBeatResponse) GetView() uint64 { @@ -887,22 +873,19 @@ func (x *HeartBeatResponse) GetView() uint64 { } type Signature struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + Signer uint64 `protobuf:"varint,1,opt,name=signer,proto3" json:"signer,omitempty"` + Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` + Msg []byte `protobuf:"bytes,3,opt,name=msg,proto3" json:"msg,omitempty"` unknownFields protoimpl.UnknownFields - - Signer uint64 `protobuf:"varint,1,opt,name=signer,proto3" json:"signer,omitempty"` - Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` - Msg []byte `protobuf:"bytes,3,opt,name=msg,proto3" json:"msg,omitempty"` + sizeCache protoimpl.SizeCache } func (x *Signature) Reset() { *x = Signature{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Signature) String() string { @@ -912,8 +895,8 @@ func (x *Signature) String() string { func (*Signature) ProtoMessage() {} func (x *Signature) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[12] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -925,7 +908,7 @@ func (x *Signature) ProtoReflect() protoreflect.Message { // Deprecated: Use Signature.ProtoReflect.Descriptor instead. func (*Signature) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{12} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{12} } func (x *Signature) GetSigner() uint64 { @@ -950,23 +933,20 @@ func (x *Signature) GetMsg() []byte { } type Proposal struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Header []byte `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"` - Payload []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"` - Metadata []byte `protobuf:"bytes,3,opt,name=metadata,proto3" json:"metadata,omitempty"` - VerificationSequence uint64 `protobuf:"varint,4,opt,name=verification_sequence,json=verificationSequence,proto3" json:"verification_sequence,omitempty"` + state protoimpl.MessageState `protogen:"open.v1"` + Header []byte `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"` + Payload []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"` + Metadata []byte `protobuf:"bytes,3,opt,name=metadata,proto3" json:"metadata,omitempty"` + VerificationSequence uint64 `protobuf:"varint,4,opt,name=verification_sequence,json=verificationSequence,proto3" json:"verification_sequence,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } func (x *Proposal) Reset() { *x = Proposal{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Proposal) String() string { @@ -976,8 +956,8 @@ func (x *Proposal) String() string { func (*Proposal) ProtoMessage() {} func (x *Proposal) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[13] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -989,7 +969,7 @@ func (x *Proposal) ProtoReflect() protoreflect.Message { // Deprecated: Use Proposal.ProtoReflect.Descriptor instead. func (*Proposal) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{13} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{13} } func (x *Proposal) GetHeader() []byte { @@ -1021,24 +1001,21 @@ func (x *Proposal) GetVerificationSequence() uint64 { } type ViewMetadata struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - ViewId uint64 `protobuf:"varint,1,opt,name=view_id,json=viewId,proto3" json:"view_id,omitempty"` - LatestSequence uint64 `protobuf:"varint,2,opt,name=latest_sequence,json=latestSequence,proto3" json:"latest_sequence,omitempty"` - DecisionsInView uint64 `protobuf:"varint,3,opt,name=decisions_in_view,json=decisionsInView,proto3" json:"decisions_in_view,omitempty"` - BlackList []uint64 `protobuf:"varint,4,rep,packed,name=black_list,json=blackList,proto3" json:"black_list,omitempty"` - PrevCommitSignatureDigest []byte `protobuf:"bytes,5,opt,name=prev_commit_signature_digest,json=prevCommitSignatureDigest,proto3" json:"prev_commit_signature_digest,omitempty"` + state protoimpl.MessageState `protogen:"open.v1"` + ViewId uint64 `protobuf:"varint,1,opt,name=view_id,json=viewId,proto3" json:"view_id,omitempty"` + LatestSequence uint64 `protobuf:"varint,2,opt,name=latest_sequence,json=latestSequence,proto3" json:"latest_sequence,omitempty"` + DecisionsInView uint64 `protobuf:"varint,3,opt,name=decisions_in_view,json=decisionsInView,proto3" json:"decisions_in_view,omitempty"` + BlackList []uint64 `protobuf:"varint,4,rep,packed,name=black_list,json=blackList,proto3" json:"black_list,omitempty"` + PrevCommitSignatureDigest []byte `protobuf:"bytes,5,opt,name=prev_commit_signature_digest,json=prevCommitSignatureDigest,proto3" json:"prev_commit_signature_digest,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } func (x *ViewMetadata) Reset() { *x = ViewMetadata{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ViewMetadata) String() string { @@ -1048,8 +1025,8 @@ func (x *ViewMetadata) String() string { func (*ViewMetadata) ProtoMessage() {} func (x *ViewMetadata) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[14] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1061,7 +1038,7 @@ func (x *ViewMetadata) ProtoReflect() protoreflect.Message { // Deprecated: Use ViewMetadata.ProtoReflect.Descriptor instead. func (*ViewMetadata) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{14} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{14} } func (x *ViewMetadata) GetViewId() uint64 { @@ -1100,25 +1077,23 @@ func (x *ViewMetadata) GetPrevCommitSignatureDigest() []byte { } type SavedMessage struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // Types that are assignable to Content: + state protoimpl.MessageState `protogen:"open.v1"` + // Types that are valid to be assigned to Content: + // // *SavedMessage_ProposedRecord // *SavedMessage_Commit // *SavedMessage_NewView // *SavedMessage_ViewChange - Content isSavedMessage_Content `protobuf_oneof:"content"` + Content isSavedMessage_Content `protobuf_oneof:"content"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } func (x *SavedMessage) Reset() { *x = SavedMessage{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SavedMessage) String() string { @@ -1128,8 +1103,8 @@ func (x *SavedMessage) String() string { func (*SavedMessage) ProtoMessage() {} func (x *SavedMessage) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[15] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1141,40 +1116,48 @@ func (x *SavedMessage) ProtoReflect() protoreflect.Message { // Deprecated: Use SavedMessage.ProtoReflect.Descriptor instead. func (*SavedMessage) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{15} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{15} } -func (m *SavedMessage) GetContent() isSavedMessage_Content { - if m != nil { - return m.Content +func (x *SavedMessage) GetContent() isSavedMessage_Content { + if x != nil { + return x.Content } return nil } func (x *SavedMessage) GetProposedRecord() *ProposedRecord { - if x, ok := x.GetContent().(*SavedMessage_ProposedRecord); ok { - return x.ProposedRecord + if x != nil { + if x, ok := x.Content.(*SavedMessage_ProposedRecord); ok { + return x.ProposedRecord + } } return nil } func (x *SavedMessage) GetCommit() *Message { - if x, ok := x.GetContent().(*SavedMessage_Commit); ok { - return x.Commit + if x != nil { + if x, ok := x.Content.(*SavedMessage_Commit); ok { + return x.Commit + } } return nil } func (x *SavedMessage) GetNewView() *ViewMetadata { - if x, ok := x.GetContent().(*SavedMessage_NewView); ok { - return x.NewView + if x != nil { + if x, ok := x.Content.(*SavedMessage_NewView); ok { + return x.NewView + } } return nil } func (x *SavedMessage) GetViewChange() *ViewChange { - if x, ok := x.GetContent().(*SavedMessage_ViewChange); ok { - return x.ViewChange + if x != nil { + if x, ok := x.Content.(*SavedMessage_ViewChange); ok { + return x.ViewChange + } } return nil } @@ -1208,18 +1191,16 @@ func (*SavedMessage_NewView) isSavedMessage_Content() {} func (*SavedMessage_ViewChange) isSavedMessage_Content() {} type StateTransferRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } func (x *StateTransferRequest) Reset() { *x = StateTransferRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StateTransferRequest) String() string { @@ -1229,8 +1210,8 @@ func (x *StateTransferRequest) String() string { func (*StateTransferRequest) ProtoMessage() {} func (x *StateTransferRequest) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[16] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1242,25 +1223,22 @@ func (x *StateTransferRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use StateTransferRequest.ProtoReflect.Descriptor instead. func (*StateTransferRequest) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{16} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{16} } type StateTransferResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + ViewNum uint64 `protobuf:"varint,1,opt,name=view_num,json=viewNum,proto3" json:"view_num,omitempty"` + Sequence uint64 `protobuf:"varint,2,opt,name=sequence,proto3" json:"sequence,omitempty"` unknownFields protoimpl.UnknownFields - - ViewNum uint64 `protobuf:"varint,1,opt,name=view_num,json=viewNum,proto3" json:"view_num,omitempty"` - Sequence uint64 `protobuf:"varint,2,opt,name=sequence,proto3" json:"sequence,omitempty"` + sizeCache protoimpl.SizeCache } func (x *StateTransferResponse) Reset() { *x = StateTransferResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_messages_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_smartbftprotos_messages_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StateTransferResponse) String() string { @@ -1270,8 +1248,8 @@ func (x *StateTransferResponse) String() string { func (*StateTransferResponse) ProtoMessage() {} func (x *StateTransferResponse) ProtoReflect() protoreflect.Message { - mi := &file_messages_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + mi := &file_smartbftprotos_messages_proto_msgTypes[17] + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1283,7 +1261,7 @@ func (x *StateTransferResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use StateTransferResponse.ProtoReflect.Descriptor instead. func (*StateTransferResponse) Descriptor() ([]byte, []int) { - return file_messages_proto_rawDescGZIP(), []int{17} + return file_smartbftprotos_messages_proto_rawDescGZIP(), []int{17} } func (x *StateTransferResponse) GetViewNum() uint64 { @@ -1300,206 +1278,207 @@ func (x *StateTransferResponse) GetSequence() uint64 { return 0 } -var File_messages_proto protoreflect.FileDescriptor - -var file_messages_proto_rawDesc = []byte{ - 0x0a, 0x0e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x12, 0x0e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, - 0x22, 0xbe, 0x05, 0x0a, 0x07, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x3d, 0x0a, 0x0b, - 0x70, 0x72, 0x65, 0x5f, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x65, 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x48, 0x00, 0x52, - 0x0a, 0x70, 0x72, 0x65, 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x12, 0x33, 0x0a, 0x07, 0x70, - 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x73, - 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x50, 0x72, - 0x65, 0x70, 0x61, 0x72, 0x65, 0x48, 0x00, 0x52, 0x07, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, - 0x12, 0x30, 0x0a, 0x06, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x16, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x73, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x48, 0x00, 0x52, 0x06, 0x63, 0x6f, 0x6d, 0x6d, - 0x69, 0x74, 0x12, 0x3d, 0x0a, 0x0b, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, - 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, - 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x56, 0x69, 0x65, 0x77, 0x43, 0x68, 0x61, - 0x6e, 0x67, 0x65, 0x48, 0x00, 0x52, 0x0a, 0x76, 0x69, 0x65, 0x77, 0x43, 0x68, 0x61, 0x6e, 0x67, - 0x65, 0x12, 0x3d, 0x0a, 0x09, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x56, 0x69, 0x65, 0x77, - 0x44, 0x61, 0x74, 0x61, 0x48, 0x00, 0x52, 0x08, 0x76, 0x69, 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, - 0x12, 0x34, 0x0a, 0x08, 0x6e, 0x65, 0x77, 0x5f, 0x76, 0x69, 0x65, 0x77, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x73, 0x2e, 0x4e, 0x65, 0x77, 0x56, 0x69, 0x65, 0x77, 0x48, 0x00, 0x52, 0x07, 0x6e, - 0x65, 0x77, 0x56, 0x69, 0x65, 0x77, 0x12, 0x3a, 0x0a, 0x0a, 0x68, 0x65, 0x61, 0x72, 0x74, 0x5f, - 0x62, 0x65, 0x61, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x73, 0x6d, 0x61, - 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x48, 0x65, 0x61, 0x72, - 0x74, 0x42, 0x65, 0x61, 0x74, 0x48, 0x00, 0x52, 0x09, 0x68, 0x65, 0x61, 0x72, 0x74, 0x42, 0x65, - 0x61, 0x74, 0x12, 0x53, 0x0a, 0x13, 0x68, 0x65, 0x61, 0x72, 0x74, 0x5f, 0x62, 0x65, 0x61, 0x74, - 0x5f, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x21, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, - 0x2e, 0x48, 0x65, 0x61, 0x72, 0x74, 0x42, 0x65, 0x61, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x48, 0x00, 0x52, 0x11, 0x68, 0x65, 0x61, 0x72, 0x74, 0x42, 0x65, 0x61, 0x74, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x5c, 0x0a, 0x16, 0x73, 0x74, 0x61, 0x74, 0x65, - 0x5f, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, - 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x54, 0x72, - 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x48, 0x00, 0x52, - 0x14, 0x73, 0x74, 0x61, 0x74, 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x5f, 0x0a, 0x17, 0x73, 0x74, 0x61, 0x74, 0x65, 0x5f, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x5f, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, +var File_smartbftprotos_messages_proto protoreflect.FileDescriptor + +var file_smartbftprotos_messages_proto_rawDesc = string([]byte{ + 0x0a, 0x1d, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, + 0x2f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, + 0x0e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x22, + 0xbe, 0x05, 0x0a, 0x07, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x3d, 0x0a, 0x0b, 0x70, + 0x72, 0x65, 0x5f, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x1a, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x73, 0x2e, 0x50, 0x72, 0x65, 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x48, 0x00, 0x52, 0x0a, + 0x70, 0x72, 0x65, 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x12, 0x33, 0x0a, 0x07, 0x70, 0x72, + 0x65, 0x70, 0x61, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x73, 0x6d, + 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x65, + 0x70, 0x61, 0x72, 0x65, 0x48, 0x00, 0x52, 0x07, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x12, + 0x30, 0x0a, 0x06, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x16, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, + 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x48, 0x00, 0x52, 0x06, 0x63, 0x6f, 0x6d, 0x6d, 0x69, + 0x74, 0x12, 0x3d, 0x0a, 0x0b, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, + 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x56, 0x69, 0x65, 0x77, 0x43, 0x68, 0x61, 0x6e, + 0x67, 0x65, 0x48, 0x00, 0x52, 0x0a, 0x76, 0x69, 0x65, 0x77, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, + 0x12, 0x3d, 0x0a, 0x09, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x56, 0x69, 0x65, 0x77, 0x44, + 0x61, 0x74, 0x61, 0x48, 0x00, 0x52, 0x08, 0x76, 0x69, 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x34, 0x0a, 0x08, 0x6e, 0x65, 0x77, 0x5f, 0x76, 0x69, 0x65, 0x77, 0x18, 0x06, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x17, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x73, 0x2e, 0x4e, 0x65, 0x77, 0x56, 0x69, 0x65, 0x77, 0x48, 0x00, 0x52, 0x07, 0x6e, 0x65, + 0x77, 0x56, 0x69, 0x65, 0x77, 0x12, 0x3a, 0x0a, 0x0a, 0x68, 0x65, 0x61, 0x72, 0x74, 0x5f, 0x62, + 0x65, 0x61, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x73, 0x6d, 0x61, 0x72, + 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x48, 0x65, 0x61, 0x72, 0x74, + 0x42, 0x65, 0x61, 0x74, 0x48, 0x00, 0x52, 0x09, 0x68, 0x65, 0x61, 0x72, 0x74, 0x42, 0x65, 0x61, + 0x74, 0x12, 0x53, 0x0a, 0x13, 0x68, 0x65, 0x61, 0x72, 0x74, 0x5f, 0x62, 0x65, 0x61, 0x74, 0x5f, + 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, + 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, + 0x48, 0x65, 0x61, 0x72, 0x74, 0x42, 0x65, 0x61, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x48, 0x00, 0x52, 0x11, 0x68, 0x65, 0x61, 0x72, 0x74, 0x42, 0x65, 0x61, 0x74, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x5c, 0x0a, 0x16, 0x73, 0x74, 0x61, 0x74, 0x65, 0x5f, + 0x74, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x54, 0x72, 0x61, - 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x48, 0x00, 0x52, - 0x15, 0x73, 0x74, 0x61, 0x74, 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x09, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x22, 0xb9, 0x01, 0x0a, 0x0a, 0x50, 0x72, 0x65, 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, - 0x12, 0x12, 0x0a, 0x04, 0x76, 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, - 0x76, 0x69, 0x65, 0x77, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, 0x71, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x04, 0x52, 0x03, 0x73, 0x65, 0x71, 0x12, 0x34, 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, - 0x61, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, - 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, - 0x61, 0x6c, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x4f, 0x0a, 0x16, - 0x70, 0x72, 0x65, 0x76, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x5f, 0x73, 0x69, 0x67, 0x6e, - 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x73, - 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x69, - 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x14, 0x70, 0x72, 0x65, 0x76, 0x43, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x22, 0x5f, 0x0a, - 0x07, 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x76, 0x69, 0x65, 0x77, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, 0x76, 0x69, 0x65, 0x77, 0x12, 0x10, 0x0a, 0x03, - 0x73, 0x65, 0x71, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x73, 0x65, 0x71, 0x12, 0x16, - 0x0a, 0x06, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, - 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x73, 0x73, 0x69, 0x73, 0x74, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x61, 0x73, 0x73, 0x69, 0x73, 0x74, 0x22, 0x80, - 0x01, 0x0a, 0x0e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x64, 0x52, 0x65, 0x63, 0x6f, 0x72, - 0x64, 0x12, 0x3b, 0x0a, 0x0b, 0x70, 0x72, 0x65, 0x5f, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, - 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x65, 0x50, 0x72, 0x65, 0x70, 0x61, - 0x72, 0x65, 0x52, 0x0a, 0x70, 0x72, 0x65, 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x12, 0x31, - 0x0a, 0x07, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x17, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, - 0x2e, 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x52, 0x07, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, - 0x65, 0x22, 0x97, 0x01, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x12, 0x0a, 0x04, - 0x76, 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, 0x76, 0x69, 0x65, 0x77, - 0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, 0x71, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x73, - 0x65, 0x71, 0x12, 0x16, 0x0a, 0x06, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x06, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x12, 0x37, 0x0a, 0x09, 0x73, 0x69, - 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, - 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, - 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, - 0x75, 0x72, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x73, 0x73, 0x69, 0x73, 0x74, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x08, 0x52, 0x06, 0x61, 0x73, 0x73, 0x69, 0x73, 0x74, 0x22, 0x20, 0x0a, 0x0c, 0x50, - 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x73, 0x46, 0x72, 0x6f, 0x6d, 0x12, 0x10, 0x0a, 0x03, 0x69, - 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x04, 0x52, 0x03, 0x69, 0x64, 0x73, 0x22, 0x41, 0x0a, - 0x0a, 0x56, 0x69, 0x65, 0x77, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x6e, - 0x65, 0x78, 0x74, 0x5f, 0x76, 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, - 0x6e, 0x65, 0x78, 0x74, 0x56, 0x69, 0x65, 0x77, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x61, 0x73, - 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e, - 0x22, 0xb1, 0x02, 0x0a, 0x08, 0x56, 0x69, 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, 0x12, 0x1b, 0x0a, - 0x09, 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x76, 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, - 0x52, 0x08, 0x6e, 0x65, 0x78, 0x74, 0x56, 0x69, 0x65, 0x77, 0x12, 0x3d, 0x0a, 0x0d, 0x6c, 0x61, - 0x73, 0x74, 0x5f, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x18, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x0c, 0x6c, 0x61, 0x73, - 0x74, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x53, 0x0a, 0x18, 0x6c, 0x61, 0x73, - 0x74, 0x5f, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, - 0x74, 0x75, 0x72, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x73, 0x6d, + 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x48, 0x00, 0x52, 0x14, + 0x73, 0x74, 0x61, 0x74, 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x5f, 0x0a, 0x17, 0x73, 0x74, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x72, + 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x5f, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x18, + 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x54, 0x72, 0x61, 0x6e, + 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x48, 0x00, 0x52, 0x15, + 0x73, 0x74, 0x61, 0x74, 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x09, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, + 0x22, 0xb9, 0x01, 0x0a, 0x0a, 0x50, 0x72, 0x65, 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x12, + 0x12, 0x0a, 0x04, 0x76, 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, 0x76, + 0x69, 0x65, 0x77, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, 0x71, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, + 0x52, 0x03, 0x73, 0x65, 0x71, 0x12, 0x34, 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, + 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, + 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, + 0x6c, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x4f, 0x0a, 0x16, 0x70, + 0x72, 0x65, 0x76, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, + 0x74, 0x75, 0x72, 0x65, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x69, 0x67, - 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x16, 0x6c, 0x61, 0x73, 0x74, 0x44, 0x65, 0x63, 0x69, - 0x73, 0x69, 0x6f, 0x6e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0x46, - 0x0a, 0x12, 0x69, 0x6e, 0x5f, 0x66, 0x6c, 0x69, 0x67, 0x68, 0x74, 0x5f, 0x70, 0x72, 0x6f, 0x70, - 0x6f, 0x73, 0x61, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x73, 0x6d, 0x61, - 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x70, - 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x10, 0x69, 0x6e, 0x46, 0x6c, 0x69, 0x67, 0x68, 0x74, 0x50, 0x72, - 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x2c, 0x0a, 0x12, 0x69, 0x6e, 0x5f, 0x66, 0x6c, 0x69, - 0x67, 0x68, 0x74, 0x5f, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x10, 0x69, 0x6e, 0x46, 0x6c, 0x69, 0x67, 0x68, 0x74, 0x50, 0x72, 0x65, 0x70, - 0x61, 0x72, 0x65, 0x64, 0x22, 0x6a, 0x0a, 0x0e, 0x53, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x56, 0x69, - 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, 0x12, 0x22, 0x0a, 0x0d, 0x72, 0x61, 0x77, 0x5f, 0x76, 0x69, - 0x65, 0x77, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0b, 0x72, - 0x61, 0x77, 0x56, 0x69, 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x69, - 0x67, 0x6e, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x73, 0x69, 0x67, 0x6e, - 0x65, 0x72, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x22, 0x53, 0x0a, 0x07, 0x4e, 0x65, 0x77, 0x56, 0x69, 0x65, 0x77, 0x12, 0x48, 0x0a, 0x10, 0x73, - 0x69, 0x67, 0x6e, 0x65, 0x64, 0x5f, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, - 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x56, 0x69, 0x65, - 0x77, 0x44, 0x61, 0x74, 0x61, 0x52, 0x0e, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x56, 0x69, 0x65, - 0x77, 0x44, 0x61, 0x74, 0x61, 0x22, 0x31, 0x0a, 0x09, 0x48, 0x65, 0x61, 0x72, 0x74, 0x42, 0x65, - 0x61, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x76, 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, - 0x52, 0x04, 0x76, 0x69, 0x65, 0x77, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, 0x71, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x04, 0x52, 0x03, 0x73, 0x65, 0x71, 0x22, 0x27, 0x0a, 0x11, 0x48, 0x65, 0x61, 0x72, - 0x74, 0x42, 0x65, 0x61, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, - 0x04, 0x76, 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, 0x76, 0x69, 0x65, - 0x77, 0x22, 0x4b, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x16, - 0x0a, 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, - 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x10, 0x0a, 0x03, - 0x6d, 0x73, 0x67, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x22, 0x8d, - 0x01, 0x0a, 0x08, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x16, 0x0a, 0x06, 0x68, - 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x68, 0x65, 0x61, - 0x64, 0x65, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x1a, 0x0a, - 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, - 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x15, 0x76, 0x65, 0x72, - 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, - 0x63, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x14, 0x76, 0x65, 0x72, 0x69, 0x66, 0x69, - 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x53, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x22, 0xdc, - 0x01, 0x0a, 0x0c, 0x56, 0x69, 0x65, 0x77, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, - 0x17, 0x0a, 0x07, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, - 0x52, 0x06, 0x76, 0x69, 0x65, 0x77, 0x49, 0x64, 0x12, 0x27, 0x0a, 0x0f, 0x6c, 0x61, 0x74, 0x65, - 0x73, 0x74, 0x5f, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x04, 0x52, 0x0e, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x53, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, - 0x65, 0x12, 0x2a, 0x0a, 0x11, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x5f, 0x69, - 0x6e, 0x5f, 0x76, 0x69, 0x65, 0x77, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0f, 0x64, 0x65, - 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x49, 0x6e, 0x56, 0x69, 0x65, 0x77, 0x12, 0x1d, 0x0a, - 0x0a, 0x62, 0x6c, 0x61, 0x63, 0x6b, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, - 0x04, 0x52, 0x09, 0x62, 0x6c, 0x61, 0x63, 0x6b, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x3f, 0x0a, 0x1c, - 0x70, 0x72, 0x65, 0x76, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x5f, 0x73, 0x69, 0x67, 0x6e, - 0x61, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x05, 0x20, 0x01, - 0x28, 0x0c, 0x52, 0x19, 0x70, 0x72, 0x65, 0x76, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x53, 0x69, - 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x22, 0x91, 0x02, - 0x0a, 0x0c, 0x53, 0x61, 0x76, 0x65, 0x64, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x49, - 0x0a, 0x0f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x64, 0x5f, 0x72, 0x65, 0x63, 0x6f, 0x72, - 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, - 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, - 0x64, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x48, 0x00, 0x52, 0x0e, 0x70, 0x72, 0x6f, 0x70, 0x6f, - 0x73, 0x65, 0x64, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12, 0x31, 0x0a, 0x06, 0x63, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x73, 0x6d, 0x61, 0x72, - 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x4d, 0x65, 0x73, 0x73, 0x61, - 0x67, 0x65, 0x48, 0x00, 0x52, 0x06, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x39, 0x0a, 0x08, - 0x6e, 0x65, 0x77, 0x5f, 0x76, 0x69, 0x65, 0x77, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x14, 0x70, 0x72, 0x65, 0x76, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x22, 0x5f, 0x0a, 0x07, + 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x76, 0x69, 0x65, 0x77, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, 0x76, 0x69, 0x65, 0x77, 0x12, 0x10, 0x0a, 0x03, 0x73, + 0x65, 0x71, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x73, 0x65, 0x71, 0x12, 0x16, 0x0a, + 0x06, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x64, + 0x69, 0x67, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x73, 0x73, 0x69, 0x73, 0x74, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x61, 0x73, 0x73, 0x69, 0x73, 0x74, 0x22, 0x80, 0x01, + 0x0a, 0x0e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x64, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, + 0x12, 0x3b, 0x0a, 0x0b, 0x70, 0x72, 0x65, 0x5f, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x65, 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, + 0x65, 0x52, 0x0a, 0x70, 0x72, 0x65, 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x12, 0x31, 0x0a, + 0x07, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, - 0x56, 0x69, 0x65, 0x77, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x48, 0x00, 0x52, 0x07, - 0x6e, 0x65, 0x77, 0x56, 0x69, 0x65, 0x77, 0x12, 0x3d, 0x0a, 0x0b, 0x76, 0x69, 0x65, 0x77, 0x5f, - 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, - 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x56, 0x69, - 0x65, 0x77, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x48, 0x00, 0x52, 0x0a, 0x76, 0x69, 0x65, 0x77, - 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x42, 0x09, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x22, 0x16, 0x0a, 0x14, 0x53, 0x74, 0x61, 0x74, 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, - 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x4e, 0x0a, 0x15, 0x53, 0x74, 0x61, - 0x74, 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x19, 0x0a, 0x08, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x6e, 0x75, 0x6d, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x76, 0x69, 0x65, 0x77, 0x4e, 0x75, 0x6d, 0x12, 0x1a, 0x0a, - 0x08, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, - 0x08, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x42, 0x31, 0x5a, 0x2f, 0x67, 0x69, 0x74, - 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x53, 0x6d, 0x61, 0x72, 0x74, 0x42, 0x46, 0x54, - 0x2d, 0x47, 0x6f, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2f, 0x73, 0x6d, - 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x62, 0x06, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x33, -} + 0x50, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x52, 0x07, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, + 0x22, 0x97, 0x01, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x76, + 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, 0x76, 0x69, 0x65, 0x77, 0x12, + 0x10, 0x0a, 0x03, 0x73, 0x65, 0x71, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x73, 0x65, + 0x71, 0x12, 0x16, 0x0a, 0x06, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x06, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x12, 0x37, 0x0a, 0x09, 0x73, 0x69, 0x67, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x73, + 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x69, + 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, + 0x72, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x73, 0x73, 0x69, 0x73, 0x74, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x06, 0x61, 0x73, 0x73, 0x69, 0x73, 0x74, 0x22, 0x20, 0x0a, 0x0c, 0x50, 0x72, + 0x65, 0x70, 0x61, 0x72, 0x65, 0x73, 0x46, 0x72, 0x6f, 0x6d, 0x12, 0x10, 0x0a, 0x03, 0x69, 0x64, + 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x04, 0x52, 0x03, 0x69, 0x64, 0x73, 0x22, 0x41, 0x0a, 0x0a, + 0x56, 0x69, 0x65, 0x77, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x6e, 0x65, + 0x78, 0x74, 0x5f, 0x76, 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x6e, + 0x65, 0x78, 0x74, 0x56, 0x69, 0x65, 0x77, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, + 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x22, + 0xb1, 0x02, 0x0a, 0x08, 0x56, 0x69, 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, 0x12, 0x1b, 0x0a, 0x09, + 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x76, 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, + 0x08, 0x6e, 0x65, 0x78, 0x74, 0x56, 0x69, 0x65, 0x77, 0x12, 0x3d, 0x0a, 0x0d, 0x6c, 0x61, 0x73, + 0x74, 0x5f, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x18, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x0c, 0x6c, 0x61, 0x73, 0x74, + 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x53, 0x0a, 0x18, 0x6c, 0x61, 0x73, 0x74, + 0x5f, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, + 0x75, 0x72, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x73, 0x6d, 0x61, + 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, + 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x16, 0x6c, 0x61, 0x73, 0x74, 0x44, 0x65, 0x63, 0x69, 0x73, + 0x69, 0x6f, 0x6e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0x46, 0x0a, + 0x12, 0x69, 0x6e, 0x5f, 0x66, 0x6c, 0x69, 0x67, 0x68, 0x74, 0x5f, 0x70, 0x72, 0x6f, 0x70, 0x6f, + 0x73, 0x61, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x73, 0x6d, 0x61, 0x72, + 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, + 0x73, 0x61, 0x6c, 0x52, 0x10, 0x69, 0x6e, 0x46, 0x6c, 0x69, 0x67, 0x68, 0x74, 0x50, 0x72, 0x6f, + 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x2c, 0x0a, 0x12, 0x69, 0x6e, 0x5f, 0x66, 0x6c, 0x69, 0x67, + 0x68, 0x74, 0x5f, 0x70, 0x72, 0x65, 0x70, 0x61, 0x72, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x10, 0x69, 0x6e, 0x46, 0x6c, 0x69, 0x67, 0x68, 0x74, 0x50, 0x72, 0x65, 0x70, 0x61, + 0x72, 0x65, 0x64, 0x22, 0x6a, 0x0a, 0x0e, 0x53, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x56, 0x69, 0x65, + 0x77, 0x44, 0x61, 0x74, 0x61, 0x12, 0x22, 0x0a, 0x0d, 0x72, 0x61, 0x77, 0x5f, 0x76, 0x69, 0x65, + 0x77, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0b, 0x72, 0x61, + 0x77, 0x56, 0x69, 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x69, 0x67, + 0x6e, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, + 0x72, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, + 0x53, 0x0a, 0x07, 0x4e, 0x65, 0x77, 0x56, 0x69, 0x65, 0x77, 0x12, 0x48, 0x0a, 0x10, 0x73, 0x69, + 0x67, 0x6e, 0x65, 0x64, 0x5f, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x56, 0x69, 0x65, 0x77, + 0x44, 0x61, 0x74, 0x61, 0x52, 0x0e, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x56, 0x69, 0x65, 0x77, + 0x44, 0x61, 0x74, 0x61, 0x22, 0x31, 0x0a, 0x09, 0x48, 0x65, 0x61, 0x72, 0x74, 0x42, 0x65, 0x61, + 0x74, 0x12, 0x12, 0x0a, 0x04, 0x76, 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, + 0x04, 0x76, 0x69, 0x65, 0x77, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x65, 0x71, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x04, 0x52, 0x03, 0x73, 0x65, 0x71, 0x22, 0x27, 0x0a, 0x11, 0x48, 0x65, 0x61, 0x72, 0x74, + 0x42, 0x65, 0x61, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, + 0x76, 0x69, 0x65, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, 0x76, 0x69, 0x65, 0x77, + 0x22, 0x4b, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x16, 0x0a, + 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x73, + 0x69, 0x67, 0x6e, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6d, + 0x73, 0x67, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x22, 0x8d, 0x01, + 0x0a, 0x08, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x16, 0x0a, 0x06, 0x68, 0x65, + 0x61, 0x64, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x68, 0x65, 0x61, 0x64, + 0x65, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0c, 0x52, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x1a, 0x0a, 0x08, + 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08, + 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x33, 0x0a, 0x15, 0x76, 0x65, 0x72, 0x69, + 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, + 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x14, 0x76, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x53, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x22, 0xdc, 0x01, + 0x0a, 0x0c, 0x56, 0x69, 0x65, 0x77, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x17, + 0x0a, 0x07, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, + 0x06, 0x76, 0x69, 0x65, 0x77, 0x49, 0x64, 0x12, 0x27, 0x0a, 0x0f, 0x6c, 0x61, 0x74, 0x65, 0x73, + 0x74, 0x5f, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, + 0x52, 0x0e, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x53, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, + 0x12, 0x2a, 0x0a, 0x11, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x5f, 0x69, 0x6e, + 0x5f, 0x76, 0x69, 0x65, 0x77, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0f, 0x64, 0x65, 0x63, + 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x49, 0x6e, 0x56, 0x69, 0x65, 0x77, 0x12, 0x1d, 0x0a, 0x0a, + 0x62, 0x6c, 0x61, 0x63, 0x6b, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x04, + 0x52, 0x09, 0x62, 0x6c, 0x61, 0x63, 0x6b, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x3f, 0x0a, 0x1c, 0x70, + 0x72, 0x65, 0x76, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, + 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x0c, 0x52, 0x19, 0x70, 0x72, 0x65, 0x76, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x53, 0x69, 0x67, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x22, 0x91, 0x02, 0x0a, + 0x0c, 0x53, 0x61, 0x76, 0x65, 0x64, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x49, 0x0a, + 0x0f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x64, 0x5f, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, + 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x64, + 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x48, 0x00, 0x52, 0x0e, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, + 0x65, 0x64, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12, 0x31, 0x0a, 0x06, 0x63, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x73, 0x6d, 0x61, 0x72, 0x74, + 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, + 0x65, 0x48, 0x00, 0x52, 0x06, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x39, 0x0a, 0x08, 0x6e, + 0x65, 0x77, 0x5f, 0x76, 0x69, 0x65, 0x77, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c, 0x2e, + 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x56, + 0x69, 0x65, 0x77, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x48, 0x00, 0x52, 0x07, 0x6e, + 0x65, 0x77, 0x56, 0x69, 0x65, 0x77, 0x12, 0x3d, 0x0a, 0x0b, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x63, + 0x68, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x6d, + 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x56, 0x69, 0x65, + 0x77, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x48, 0x00, 0x52, 0x0a, 0x76, 0x69, 0x65, 0x77, 0x43, + 0x68, 0x61, 0x6e, 0x67, 0x65, 0x42, 0x09, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, + 0x22, 0x16, 0x0a, 0x14, 0x53, 0x74, 0x61, 0x74, 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, + 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x4e, 0x0a, 0x15, 0x53, 0x74, 0x61, 0x74, + 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x19, 0x0a, 0x08, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x6e, 0x75, 0x6d, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x04, 0x52, 0x07, 0x76, 0x69, 0x65, 0x77, 0x4e, 0x75, 0x6d, 0x12, 0x1a, 0x0a, 0x08, + 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, + 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x42, 0x35, 0x5a, 0x33, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x68, 0x79, 0x70, 0x65, 0x72, 0x6c, 0x65, 0x64, 0x67, + 0x65, 0x72, 0x2d, 0x6c, 0x61, 0x62, 0x73, 0x2f, 0x53, 0x6d, 0x61, 0x72, 0x74, 0x42, 0x46, 0x54, + 0x2f, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x62, 0x66, 0x74, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +}) var ( - file_messages_proto_rawDescOnce sync.Once - file_messages_proto_rawDescData = file_messages_proto_rawDesc + file_smartbftprotos_messages_proto_rawDescOnce sync.Once + file_smartbftprotos_messages_proto_rawDescData []byte ) -func file_messages_proto_rawDescGZIP() []byte { - file_messages_proto_rawDescOnce.Do(func() { - file_messages_proto_rawDescData = protoimpl.X.CompressGZIP(file_messages_proto_rawDescData) +func file_smartbftprotos_messages_proto_rawDescGZIP() []byte { + file_smartbftprotos_messages_proto_rawDescOnce.Do(func() { + file_smartbftprotos_messages_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_smartbftprotos_messages_proto_rawDesc), len(file_smartbftprotos_messages_proto_rawDesc))) }) - return file_messages_proto_rawDescData + return file_smartbftprotos_messages_proto_rawDescData } -var file_messages_proto_msgTypes = make([]protoimpl.MessageInfo, 18) -var file_messages_proto_goTypes = []interface{}{ +var file_smartbftprotos_messages_proto_msgTypes = make([]protoimpl.MessageInfo, 18) +var file_smartbftprotos_messages_proto_goTypes = []any{ (*Message)(nil), // 0: smartbftprotos.Message (*PrePrepare)(nil), // 1: smartbftprotos.PrePrepare (*Prepare)(nil), // 2: smartbftprotos.Prepare @@ -1519,7 +1498,7 @@ var file_messages_proto_goTypes = []interface{}{ (*StateTransferRequest)(nil), // 16: smartbftprotos.StateTransferRequest (*StateTransferResponse)(nil), // 17: smartbftprotos.StateTransferResponse } -var file_messages_proto_depIdxs = []int32{ +var file_smartbftprotos_messages_proto_depIdxs = []int32{ 1, // 0: smartbftprotos.Message.pre_prepare:type_name -> smartbftprotos.PrePrepare 2, // 1: smartbftprotos.Message.prepare:type_name -> smartbftprotos.Prepare 4, // 2: smartbftprotos.Message.commit:type_name -> smartbftprotos.Commit @@ -1550,230 +1529,12 @@ var file_messages_proto_depIdxs = []int32{ 0, // [0:23] is the sub-list for field type_name } -func init() { file_messages_proto_init() } -func file_messages_proto_init() { - if File_messages_proto != nil { +func init() { file_smartbftprotos_messages_proto_init() } +func file_smartbftprotos_messages_proto_init() { + if File_smartbftprotos_messages_proto != nil { return } - if !protoimpl.UnsafeEnabled { - file_messages_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Message); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*PrePrepare); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Prepare); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ProposedRecord); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Commit); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*PreparesFrom); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ViewChange); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ViewData); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SignedViewData); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*NewView); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*HeartBeat); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*HeartBeatResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Signature); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Proposal); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ViewMetadata); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SavedMessage); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StateTransferRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_messages_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StateTransferResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } - file_messages_proto_msgTypes[0].OneofWrappers = []interface{}{ + file_smartbftprotos_messages_proto_msgTypes[0].OneofWrappers = []any{ (*Message_PrePrepare)(nil), (*Message_Prepare)(nil), (*Message_Commit)(nil), @@ -1785,7 +1546,7 @@ func file_messages_proto_init() { (*Message_StateTransferRequest)(nil), (*Message_StateTransferResponse)(nil), } - file_messages_proto_msgTypes[15].OneofWrappers = []interface{}{ + file_smartbftprotos_messages_proto_msgTypes[15].OneofWrappers = []any{ (*SavedMessage_ProposedRecord)(nil), (*SavedMessage_Commit)(nil), (*SavedMessage_NewView)(nil), @@ -1795,18 +1556,17 @@ func file_messages_proto_init() { out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: file_messages_proto_rawDesc, + RawDescriptor: unsafe.Slice(unsafe.StringData(file_smartbftprotos_messages_proto_rawDesc), len(file_smartbftprotos_messages_proto_rawDesc)), NumEnums: 0, NumMessages: 18, NumExtensions: 0, NumServices: 0, }, - GoTypes: file_messages_proto_goTypes, - DependencyIndexes: file_messages_proto_depIdxs, - MessageInfos: file_messages_proto_msgTypes, + GoTypes: file_smartbftprotos_messages_proto_goTypes, + DependencyIndexes: file_smartbftprotos_messages_proto_depIdxs, + MessageInfos: file_smartbftprotos_messages_proto_msgTypes, }.Build() - File_messages_proto = out.File - file_messages_proto_rawDesc = nil - file_messages_proto_goTypes = nil - file_messages_proto_depIdxs = nil + File_smartbftprotos_messages_proto = out.File + file_smartbftprotos_messages_proto_goTypes = nil + file_smartbftprotos_messages_proto_depIdxs = nil } diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/collection.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/collection.pb.go index 9fbca16a..04ad009a 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/collection.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/collection.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: common/collection.proto @@ -432,7 +432,7 @@ func file_common_collection_proto_rawDescGZIP() []byte { } var file_common_collection_proto_msgTypes = make([]protoimpl.MessageInfo, 4) -var file_common_collection_proto_goTypes = []interface{}{ +var file_common_collection_proto_goTypes = []any{ (*CollectionConfigPackage)(nil), // 0: common.CollectionConfigPackage (*CollectionConfig)(nil), // 1: common.CollectionConfig (*StaticCollectionConfig)(nil), // 2: common.StaticCollectionConfig @@ -460,7 +460,7 @@ func file_common_collection_proto_init() { } file_common_policies_proto_init() if !protoimpl.UnsafeEnabled { - file_common_collection_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_common_collection_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*CollectionConfigPackage); i { case 0: return &v.state @@ -472,7 +472,7 @@ func file_common_collection_proto_init() { return nil } } - file_common_collection_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_common_collection_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*CollectionConfig); i { case 0: return &v.state @@ -484,7 +484,7 @@ func file_common_collection_proto_init() { return nil } } - file_common_collection_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_common_collection_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*StaticCollectionConfig); i { case 0: return &v.state @@ -496,7 +496,7 @@ func file_common_collection_proto_init() { return nil } } - file_common_collection_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_common_collection_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*CollectionPolicyConfig); i { case 0: return &v.state @@ -509,10 +509,10 @@ func file_common_collection_proto_init() { } } } - file_common_collection_proto_msgTypes[1].OneofWrappers = []interface{}{ + file_common_collection_proto_msgTypes[1].OneofWrappers = []any{ (*CollectionConfig_StaticCollectionConfig)(nil), } - file_common_collection_proto_msgTypes[3].OneofWrappers = []interface{}{ + file_common_collection_proto_msgTypes[3].OneofWrappers = []any{ (*CollectionPolicyConfig_SignaturePolicy)(nil), } type x struct{} diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/common.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/common.pb.go index 51d7d540..4718005d 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/common.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/common.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: common/common.proto @@ -1224,7 +1224,7 @@ func file_common_common_proto_rawDescGZIP() []byte { var file_common_common_proto_enumTypes = make([]protoimpl.EnumInfo, 3) var file_common_common_proto_msgTypes = make([]protoimpl.MessageInfo, 14) -var file_common_common_proto_goTypes = []interface{}{ +var file_common_common_proto_goTypes = []any{ (Status)(0), // 0: common.Status (HeaderType)(0), // 1: common.HeaderType (BlockMetadataIndex)(0), // 2: common.BlockMetadataIndex @@ -1265,7 +1265,7 @@ func file_common_common_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_common_common_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*LastConfig); i { case 0: return &v.state @@ -1277,7 +1277,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*Metadata); i { case 0: return &v.state @@ -1289,7 +1289,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*MetadataSignature); i { case 0: return &v.state @@ -1301,7 +1301,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*IdentifierHeader); i { case 0: return &v.state @@ -1313,7 +1313,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*Header); i { case 0: return &v.state @@ -1325,7 +1325,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*ChannelHeader); i { case 0: return &v.state @@ -1337,7 +1337,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[6].Exporter = func(v any, i int) any { switch v := v.(*SignatureHeader); i { case 0: return &v.state @@ -1349,7 +1349,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[7].Exporter = func(v any, i int) any { switch v := v.(*Payload); i { case 0: return &v.state @@ -1361,7 +1361,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[8].Exporter = func(v any, i int) any { switch v := v.(*Envelope); i { case 0: return &v.state @@ -1373,7 +1373,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[9].Exporter = func(v any, i int) any { switch v := v.(*Block); i { case 0: return &v.state @@ -1385,7 +1385,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[10].Exporter = func(v any, i int) any { switch v := v.(*BlockHeader); i { case 0: return &v.state @@ -1397,7 +1397,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[11].Exporter = func(v any, i int) any { switch v := v.(*BlockData); i { case 0: return &v.state @@ -1409,7 +1409,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[12].Exporter = func(v any, i int) any { switch v := v.(*BlockMetadata); i { case 0: return &v.state @@ -1421,7 +1421,7 @@ func file_common_common_proto_init() { return nil } } - file_common_common_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + file_common_common_proto_msgTypes[13].Exporter = func(v any, i int) any { switch v := v.(*OrdererBlockMetadata); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/configtx.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/configtx.pb.go index b9772724..cdbf40d9 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/configtx.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/configtx.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: common/configtx.proto @@ -676,7 +676,7 @@ func file_common_configtx_proto_rawDescGZIP() []byte { } var file_common_configtx_proto_msgTypes = make([]protoimpl.MessageInfo, 12) -var file_common_configtx_proto_goTypes = []interface{}{ +var file_common_configtx_proto_goTypes = []any{ (*ConfigEnvelope)(nil), // 0: common.ConfigEnvelope (*Config)(nil), // 1: common.Config (*ConfigUpdateEnvelope)(nil), // 2: common.ConfigUpdateEnvelope @@ -722,7 +722,7 @@ func file_common_configtx_proto_init() { file_common_common_proto_init() file_common_policies_proto_init() if !protoimpl.UnsafeEnabled { - file_common_configtx_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_common_configtx_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ConfigEnvelope); i { case 0: return &v.state @@ -734,7 +734,7 @@ func file_common_configtx_proto_init() { return nil } } - file_common_configtx_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_common_configtx_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*Config); i { case 0: return &v.state @@ -746,7 +746,7 @@ func file_common_configtx_proto_init() { return nil } } - file_common_configtx_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_common_configtx_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*ConfigUpdateEnvelope); i { case 0: return &v.state @@ -758,7 +758,7 @@ func file_common_configtx_proto_init() { return nil } } - file_common_configtx_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_common_configtx_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*ConfigUpdate); i { case 0: return &v.state @@ -770,7 +770,7 @@ func file_common_configtx_proto_init() { return nil } } - file_common_configtx_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_common_configtx_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*ConfigGroup); i { case 0: return &v.state @@ -782,7 +782,7 @@ func file_common_configtx_proto_init() { return nil } } - file_common_configtx_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_common_configtx_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*ConfigValue); i { case 0: return &v.state @@ -794,7 +794,7 @@ func file_common_configtx_proto_init() { return nil } } - file_common_configtx_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + file_common_configtx_proto_msgTypes[6].Exporter = func(v any, i int) any { switch v := v.(*ConfigPolicy); i { case 0: return &v.state @@ -806,7 +806,7 @@ func file_common_configtx_proto_init() { return nil } } - file_common_configtx_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + file_common_configtx_proto_msgTypes[7].Exporter = func(v any, i int) any { switch v := v.(*ConfigSignature); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/configuration.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/configuration.pb.go index 927ebcf6..103779a2 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/configuration.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/configuration.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: common/configuration.proto @@ -559,7 +559,7 @@ func file_common_configuration_proto_rawDescGZIP() []byte { } var file_common_configuration_proto_msgTypes = make([]protoimpl.MessageInfo, 9) -var file_common_configuration_proto_goTypes = []interface{}{ +var file_common_configuration_proto_goTypes = []any{ (*HashingAlgorithm)(nil), // 0: common.HashingAlgorithm (*BlockDataHashingStructure)(nil), // 1: common.BlockDataHashingStructure (*OrdererAddresses)(nil), // 2: common.OrdererAddresses @@ -587,7 +587,7 @@ func file_common_configuration_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_common_configuration_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_common_configuration_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*HashingAlgorithm); i { case 0: return &v.state @@ -599,7 +599,7 @@ func file_common_configuration_proto_init() { return nil } } - file_common_configuration_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_common_configuration_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*BlockDataHashingStructure); i { case 0: return &v.state @@ -611,7 +611,7 @@ func file_common_configuration_proto_init() { return nil } } - file_common_configuration_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_common_configuration_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*OrdererAddresses); i { case 0: return &v.state @@ -623,7 +623,7 @@ func file_common_configuration_proto_init() { return nil } } - file_common_configuration_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_common_configuration_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*Consenter); i { case 0: return &v.state @@ -635,7 +635,7 @@ func file_common_configuration_proto_init() { return nil } } - file_common_configuration_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_common_configuration_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*Orderers); i { case 0: return &v.state @@ -647,7 +647,7 @@ func file_common_configuration_proto_init() { return nil } } - file_common_configuration_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_common_configuration_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*Consortium); i { case 0: return &v.state @@ -659,7 +659,7 @@ func file_common_configuration_proto_init() { return nil } } - file_common_configuration_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + file_common_configuration_proto_msgTypes[6].Exporter = func(v any, i int) any { switch v := v.(*Capabilities); i { case 0: return &v.state @@ -671,7 +671,7 @@ func file_common_configuration_proto_init() { return nil } } - file_common_configuration_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + file_common_configuration_proto_msgTypes[7].Exporter = func(v any, i int) any { switch v := v.(*Capability); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/ledger.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/ledger.pb.go index e486f78d..2a243d13 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/ledger.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/ledger.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: common/ledger.proto @@ -197,7 +197,7 @@ func file_common_ledger_proto_rawDescGZIP() []byte { } var file_common_ledger_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_common_ledger_proto_goTypes = []interface{}{ +var file_common_ledger_proto_goTypes = []any{ (*BlockchainInfo)(nil), // 0: common.BlockchainInfo (*BootstrappingSnapshotInfo)(nil), // 1: common.BootstrappingSnapshotInfo } @@ -216,7 +216,7 @@ func file_common_ledger_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_common_ledger_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_common_ledger_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*BlockchainInfo); i { case 0: return &v.state @@ -228,7 +228,7 @@ func file_common_ledger_proto_init() { return nil } } - file_common_ledger_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_common_ledger_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*BootstrappingSnapshotInfo); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/policies.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/policies.pb.go index 3f2b35b3..4cb39e3d 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/policies.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/common/policies.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: common/policies.proto @@ -627,7 +627,7 @@ func file_common_policies_proto_rawDescGZIP() []byte { var file_common_policies_proto_enumTypes = make([]protoimpl.EnumInfo, 2) var file_common_policies_proto_msgTypes = make([]protoimpl.MessageInfo, 6) -var file_common_policies_proto_goTypes = []interface{}{ +var file_common_policies_proto_goTypes = []any{ (Policy_PolicyType)(0), // 0: common.Policy.PolicyType (ImplicitMetaPolicy_Rule)(0), // 1: common.ImplicitMetaPolicy.Rule (*Policy)(nil), // 2: common.Policy @@ -658,7 +658,7 @@ func file_common_policies_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_common_policies_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_common_policies_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*Policy); i { case 0: return &v.state @@ -670,7 +670,7 @@ func file_common_policies_proto_init() { return nil } } - file_common_policies_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_common_policies_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*SignaturePolicyEnvelope); i { case 0: return &v.state @@ -682,7 +682,7 @@ func file_common_policies_proto_init() { return nil } } - file_common_policies_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_common_policies_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*SignaturePolicy); i { case 0: return &v.state @@ -694,7 +694,7 @@ func file_common_policies_proto_init() { return nil } } - file_common_policies_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_common_policies_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*ImplicitMetaPolicy); i { case 0: return &v.state @@ -706,7 +706,7 @@ func file_common_policies_proto_init() { return nil } } - file_common_policies_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_common_policies_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*ApplicationPolicy); i { case 0: return &v.state @@ -718,7 +718,7 @@ func file_common_policies_proto_init() { return nil } } - file_common_policies_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_common_policies_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*SignaturePolicy_NOutOf); i { case 0: return &v.state @@ -731,11 +731,11 @@ func file_common_policies_proto_init() { } } } - file_common_policies_proto_msgTypes[2].OneofWrappers = []interface{}{ + file_common_policies_proto_msgTypes[2].OneofWrappers = []any{ (*SignaturePolicy_SignedBy)(nil), (*SignaturePolicy_NOutOf_)(nil), } - file_common_policies_proto_msgTypes[4].OneofWrappers = []interface{}{ + file_common_policies_proto_msgTypes[4].OneofWrappers = []any{ (*ApplicationPolicy_SignaturePolicy)(nil), (*ApplicationPolicy_ChannelConfigPolicyReference)(nil), } diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/ledger/rwset/kvrwset/kv_rwset.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/ledger/rwset/kvrwset/kv_rwset.pb.go index bee28b46..49e885ce 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/ledger/rwset/kvrwset/kv_rwset.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/ledger/rwset/kvrwset/kv_rwset.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: ledger/rwset/kvrwset/kv_rwset.proto @@ -998,7 +998,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_rawDescGZIP() []byte { } var file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes = make([]protoimpl.MessageInfo, 13) -var file_ledger_rwset_kvrwset_kv_rwset_proto_goTypes = []interface{}{ +var file_ledger_rwset_kvrwset_kv_rwset_proto_goTypes = []any{ (*KVRWSet)(nil), // 0: kvrwset.KVRWSet (*HashedRWSet)(nil), // 1: kvrwset.HashedRWSet (*KVRead)(nil), // 2: kvrwset.KVRead @@ -1041,7 +1041,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*KVRWSet); i { case 0: return &v.state @@ -1053,7 +1053,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*HashedRWSet); i { case 0: return &v.state @@ -1065,7 +1065,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*KVRead); i { case 0: return &v.state @@ -1077,7 +1077,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*KVWrite); i { case 0: return &v.state @@ -1089,7 +1089,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*KVMetadataWrite); i { case 0: return &v.state @@ -1101,7 +1101,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*KVReadHash); i { case 0: return &v.state @@ -1113,7 +1113,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[6].Exporter = func(v any, i int) any { switch v := v.(*KVWriteHash); i { case 0: return &v.state @@ -1125,7 +1125,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[7].Exporter = func(v any, i int) any { switch v := v.(*KVMetadataWriteHash); i { case 0: return &v.state @@ -1137,7 +1137,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[8].Exporter = func(v any, i int) any { switch v := v.(*KVMetadataEntry); i { case 0: return &v.state @@ -1149,7 +1149,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[9].Exporter = func(v any, i int) any { switch v := v.(*Version); i { case 0: return &v.state @@ -1161,7 +1161,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[10].Exporter = func(v any, i int) any { switch v := v.(*RangeQueryInfo); i { case 0: return &v.state @@ -1173,7 +1173,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[11].Exporter = func(v any, i int) any { switch v := v.(*QueryReads); i { case 0: return &v.state @@ -1185,7 +1185,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { return nil } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[12].Exporter = func(v any, i int) any { switch v := v.(*QueryReadsMerkleSummary); i { case 0: return &v.state @@ -1198,7 +1198,7 @@ func file_ledger_rwset_kvrwset_kv_rwset_proto_init() { } } } - file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[10].OneofWrappers = []interface{}{ + file_ledger_rwset_kvrwset_kv_rwset_proto_msgTypes[10].OneofWrappers = []any{ (*RangeQueryInfo_RawReads)(nil), (*RangeQueryInfo_ReadsMerkleHashes)(nil), } diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/ledger/rwset/rwset.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/ledger/rwset/rwset.pb.go index 5f13260a..e67b19cb 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/ledger/rwset/rwset.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/ledger/rwset/rwset.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: ledger/rwset/rwset.proto @@ -506,7 +506,7 @@ func file_ledger_rwset_rwset_proto_rawDescGZIP() []byte { var file_ledger_rwset_rwset_proto_enumTypes = make([]protoimpl.EnumInfo, 1) var file_ledger_rwset_rwset_proto_msgTypes = make([]protoimpl.MessageInfo, 6) -var file_ledger_rwset_rwset_proto_goTypes = []interface{}{ +var file_ledger_rwset_rwset_proto_goTypes = []any{ (TxReadWriteSet_DataModel)(0), // 0: rwset.TxReadWriteSet.DataModel (*TxReadWriteSet)(nil), // 1: rwset.TxReadWriteSet (*NsReadWriteSet)(nil), // 2: rwset.NsReadWriteSet @@ -535,7 +535,7 @@ func file_ledger_rwset_rwset_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_ledger_rwset_rwset_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_rwset_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*TxReadWriteSet); i { case 0: return &v.state @@ -547,7 +547,7 @@ func file_ledger_rwset_rwset_proto_init() { return nil } } - file_ledger_rwset_rwset_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_rwset_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*NsReadWriteSet); i { case 0: return &v.state @@ -559,7 +559,7 @@ func file_ledger_rwset_rwset_proto_init() { return nil } } - file_ledger_rwset_rwset_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_rwset_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*CollectionHashedReadWriteSet); i { case 0: return &v.state @@ -571,7 +571,7 @@ func file_ledger_rwset_rwset_proto_init() { return nil } } - file_ledger_rwset_rwset_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_rwset_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*TxPvtReadWriteSet); i { case 0: return &v.state @@ -583,7 +583,7 @@ func file_ledger_rwset_rwset_proto_init() { return nil } } - file_ledger_rwset_rwset_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_rwset_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*NsPvtReadWriteSet); i { case 0: return &v.state @@ -595,7 +595,7 @@ func file_ledger_rwset_rwset_proto_init() { return nil } } - file_ledger_rwset_rwset_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_ledger_rwset_rwset_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*CollectionPvtReadWriteSet); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/identities.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/identities.pb.go index 7b906b36..d06aece0 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/identities.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/identities.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: msp/identities.proto @@ -218,7 +218,7 @@ func file_msp_identities_proto_rawDescGZIP() []byte { } var file_msp_identities_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_msp_identities_proto_goTypes = []interface{}{ +var file_msp_identities_proto_goTypes = []any{ (*SerializedIdentity)(nil), // 0: msp.SerializedIdentity (*SerializedIdemixIdentity)(nil), // 1: msp.SerializedIdemixIdentity } @@ -236,7 +236,7 @@ func file_msp_identities_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_msp_identities_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_msp_identities_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*SerializedIdentity); i { case 0: return &v.state @@ -248,7 +248,7 @@ func file_msp_identities_proto_init() { return nil } } - file_msp_identities_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_msp_identities_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*SerializedIdemixIdentity); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/msp_config.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/msp_config.pb.go index 1001ae9f..f0eb5b7d 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/msp_config.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/msp_config.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: msp/msp_config.proto @@ -923,7 +923,7 @@ func file_msp_msp_config_proto_rawDescGZIP() []byte { } var file_msp_msp_config_proto_msgTypes = make([]protoimpl.MessageInfo, 9) -var file_msp_msp_config_proto_goTypes = []interface{}{ +var file_msp_msp_config_proto_goTypes = []any{ (*MSPConfig)(nil), // 0: msp.MSPConfig (*FabricMSPConfig)(nil), // 1: msp.FabricMSPConfig (*FabricCryptoConfig)(nil), // 2: msp.FabricCryptoConfig @@ -958,7 +958,7 @@ func file_msp_msp_config_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_msp_msp_config_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_config_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*MSPConfig); i { case 0: return &v.state @@ -970,7 +970,7 @@ func file_msp_msp_config_proto_init() { return nil } } - file_msp_msp_config_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_config_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*FabricMSPConfig); i { case 0: return &v.state @@ -982,7 +982,7 @@ func file_msp_msp_config_proto_init() { return nil } } - file_msp_msp_config_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_config_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*FabricCryptoConfig); i { case 0: return &v.state @@ -994,7 +994,7 @@ func file_msp_msp_config_proto_init() { return nil } } - file_msp_msp_config_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_config_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*IdemixMSPConfig); i { case 0: return &v.state @@ -1006,7 +1006,7 @@ func file_msp_msp_config_proto_init() { return nil } } - file_msp_msp_config_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_config_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*IdemixMSPSignerConfig); i { case 0: return &v.state @@ -1018,7 +1018,7 @@ func file_msp_msp_config_proto_init() { return nil } } - file_msp_msp_config_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_config_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*SigningIdentityInfo); i { case 0: return &v.state @@ -1030,7 +1030,7 @@ func file_msp_msp_config_proto_init() { return nil } } - file_msp_msp_config_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_config_proto_msgTypes[6].Exporter = func(v any, i int) any { switch v := v.(*KeyInfo); i { case 0: return &v.state @@ -1042,7 +1042,7 @@ func file_msp_msp_config_proto_init() { return nil } } - file_msp_msp_config_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_config_proto_msgTypes[7].Exporter = func(v any, i int) any { switch v := v.(*FabricOUIdentifier); i { case 0: return &v.state @@ -1054,7 +1054,7 @@ func file_msp_msp_config_proto_init() { return nil } } - file_msp_msp_config_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_config_proto_msgTypes[8].Exporter = func(v any, i int) any { switch v := v.(*FabricNodeOUs); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/msp_principal.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/msp_principal.pb.go index 1dd13289..d9ca77e3 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/msp_principal.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/msp/msp_principal.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: msp/msp_principal.proto @@ -593,7 +593,7 @@ func file_msp_msp_principal_proto_rawDescGZIP() []byte { var file_msp_msp_principal_proto_enumTypes = make([]protoimpl.EnumInfo, 3) var file_msp_msp_principal_proto_msgTypes = make([]protoimpl.MessageInfo, 5) -var file_msp_msp_principal_proto_goTypes = []interface{}{ +var file_msp_msp_principal_proto_goTypes = []any{ (MSPPrincipal_Classification)(0), // 0: common.MSPPrincipal.Classification (MSPRole_MSPRoleType)(0), // 1: common.MSPRole.MSPRoleType (MSPIdentityAnonymity_MSPIdentityAnonymityType)(0), // 2: common.MSPIdentityAnonymity.MSPIdentityAnonymityType @@ -621,7 +621,7 @@ func file_msp_msp_principal_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_msp_msp_principal_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_principal_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*MSPPrincipal); i { case 0: return &v.state @@ -633,7 +633,7 @@ func file_msp_msp_principal_proto_init() { return nil } } - file_msp_msp_principal_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_principal_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*OrganizationUnit); i { case 0: return &v.state @@ -645,7 +645,7 @@ func file_msp_msp_principal_proto_init() { return nil } } - file_msp_msp_principal_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_principal_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*MSPRole); i { case 0: return &v.state @@ -657,7 +657,7 @@ func file_msp_msp_principal_proto_init() { return nil } } - file_msp_msp_principal_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_principal_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*MSPIdentityAnonymity); i { case 0: return &v.state @@ -669,7 +669,7 @@ func file_msp_msp_principal_proto_init() { return nil } } - file_msp_msp_principal_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_msp_msp_principal_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*CombinedPrincipal); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/ab.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/ab.pb.go index efbd5a1f..7ce79093 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/ab.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/ab.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: orderer/ab.proto @@ -775,7 +775,7 @@ func file_orderer_ab_proto_rawDescGZIP() []byte { var file_orderer_ab_proto_enumTypes = make([]protoimpl.EnumInfo, 3) var file_orderer_ab_proto_msgTypes = make([]protoimpl.MessageInfo, 8) -var file_orderer_ab_proto_goTypes = []interface{}{ +var file_orderer_ab_proto_goTypes = []any{ (SeekInfo_SeekBehavior)(0), // 0: orderer.SeekInfo.SeekBehavior (SeekInfo_SeekErrorResponse)(0), // 1: orderer.SeekInfo.SeekErrorResponse (SeekInfo_SeekContentType)(0), // 2: orderer.SeekInfo.SeekContentType @@ -821,7 +821,7 @@ func file_orderer_ab_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_orderer_ab_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_orderer_ab_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*BroadcastResponse); i { case 0: return &v.state @@ -833,7 +833,7 @@ func file_orderer_ab_proto_init() { return nil } } - file_orderer_ab_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_orderer_ab_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*SeekNewest); i { case 0: return &v.state @@ -845,7 +845,7 @@ func file_orderer_ab_proto_init() { return nil } } - file_orderer_ab_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_orderer_ab_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*SeekOldest); i { case 0: return &v.state @@ -857,7 +857,7 @@ func file_orderer_ab_proto_init() { return nil } } - file_orderer_ab_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_orderer_ab_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*SeekSpecified); i { case 0: return &v.state @@ -869,7 +869,7 @@ func file_orderer_ab_proto_init() { return nil } } - file_orderer_ab_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_orderer_ab_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*SeekNextCommit); i { case 0: return &v.state @@ -881,7 +881,7 @@ func file_orderer_ab_proto_init() { return nil } } - file_orderer_ab_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_orderer_ab_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*SeekPosition); i { case 0: return &v.state @@ -893,7 +893,7 @@ func file_orderer_ab_proto_init() { return nil } } - file_orderer_ab_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + file_orderer_ab_proto_msgTypes[6].Exporter = func(v any, i int) any { switch v := v.(*SeekInfo); i { case 0: return &v.state @@ -905,7 +905,7 @@ func file_orderer_ab_proto_init() { return nil } } - file_orderer_ab_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + file_orderer_ab_proto_msgTypes[7].Exporter = func(v any, i int) any { switch v := v.(*DeliverResponse); i { case 0: return &v.state @@ -918,13 +918,13 @@ func file_orderer_ab_proto_init() { } } } - file_orderer_ab_proto_msgTypes[5].OneofWrappers = []interface{}{ + file_orderer_ab_proto_msgTypes[5].OneofWrappers = []any{ (*SeekPosition_Newest)(nil), (*SeekPosition_Oldest)(nil), (*SeekPosition_Specified)(nil), (*SeekPosition_NextCommit)(nil), } - file_orderer_ab_proto_msgTypes[7].OneofWrappers = []interface{}{ + file_orderer_ab_proto_msgTypes[7].OneofWrappers = []any{ (*DeliverResponse_Status)(nil), (*DeliverResponse_Block)(nil), } diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/ab_grpc.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/ab_grpc.pb.go index 6ceea60b..ae4de726 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/ab_grpc.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/ab_grpc.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: -// - protoc-gen-go-grpc v1.3.0 +// - protoc-gen-go-grpc v1.5.1 // - protoc (unknown) // source: orderer/ab.proto @@ -20,8 +20,8 @@ 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 +// Requires gRPC-Go v1.64.0 or later. +const _ = grpc.SupportPackageIsVersion9 const ( AtomicBroadcast_Broadcast_FullMethodName = "/orderer.AtomicBroadcast/Broadcast" @@ -33,9 +33,9 @@ const ( // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. type AtomicBroadcastClient interface { // broadcast receives a reply of Acknowledgement for each common.Envelope in order, indicating success or type of failure - Broadcast(ctx context.Context, opts ...grpc.CallOption) (AtomicBroadcast_BroadcastClient, error) + Broadcast(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[common.Envelope, BroadcastResponse], error) // deliver first requires an Envelope of type DELIVER_SEEK_INFO with Payload data as a mashaled SeekInfo message, then a stream of block replies is received. - Deliver(ctx context.Context, opts ...grpc.CallOption) (AtomicBroadcast_DeliverClient, error) + Deliver(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[common.Envelope, DeliverResponse], error) } type atomicBroadcastClient struct { @@ -46,88 +46,56 @@ func NewAtomicBroadcastClient(cc grpc.ClientConnInterface) AtomicBroadcastClient return &atomicBroadcastClient{cc} } -func (c *atomicBroadcastClient) Broadcast(ctx context.Context, opts ...grpc.CallOption) (AtomicBroadcast_BroadcastClient, error) { - stream, err := c.cc.NewStream(ctx, &AtomicBroadcast_ServiceDesc.Streams[0], AtomicBroadcast_Broadcast_FullMethodName, opts...) +func (c *atomicBroadcastClient) Broadcast(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[common.Envelope, BroadcastResponse], error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) + stream, err := c.cc.NewStream(ctx, &AtomicBroadcast_ServiceDesc.Streams[0], AtomicBroadcast_Broadcast_FullMethodName, cOpts...) if err != nil { return nil, err } - x := &atomicBroadcastBroadcastClient{stream} + x := &grpc.GenericClientStream[common.Envelope, BroadcastResponse]{ClientStream: stream} return x, nil } -type AtomicBroadcast_BroadcastClient interface { - Send(*common.Envelope) error - Recv() (*BroadcastResponse, error) - grpc.ClientStream -} - -type atomicBroadcastBroadcastClient struct { - grpc.ClientStream -} - -func (x *atomicBroadcastBroadcastClient) Send(m *common.Envelope) error { - return x.ClientStream.SendMsg(m) -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type AtomicBroadcast_BroadcastClient = grpc.BidiStreamingClient[common.Envelope, BroadcastResponse] -func (x *atomicBroadcastBroadcastClient) Recv() (*BroadcastResponse, error) { - m := new(BroadcastResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *atomicBroadcastClient) Deliver(ctx context.Context, opts ...grpc.CallOption) (AtomicBroadcast_DeliverClient, error) { - stream, err := c.cc.NewStream(ctx, &AtomicBroadcast_ServiceDesc.Streams[1], AtomicBroadcast_Deliver_FullMethodName, opts...) +func (c *atomicBroadcastClient) Deliver(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[common.Envelope, DeliverResponse], error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) + stream, err := c.cc.NewStream(ctx, &AtomicBroadcast_ServiceDesc.Streams[1], AtomicBroadcast_Deliver_FullMethodName, cOpts...) if err != nil { return nil, err } - x := &atomicBroadcastDeliverClient{stream} + x := &grpc.GenericClientStream[common.Envelope, DeliverResponse]{ClientStream: stream} return x, nil } -type AtomicBroadcast_DeliverClient interface { - Send(*common.Envelope) error - Recv() (*DeliverResponse, error) - grpc.ClientStream -} - -type atomicBroadcastDeliverClient struct { - grpc.ClientStream -} - -func (x *atomicBroadcastDeliverClient) Send(m *common.Envelope) error { - return x.ClientStream.SendMsg(m) -} - -func (x *atomicBroadcastDeliverClient) Recv() (*DeliverResponse, error) { - m := new(DeliverResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type AtomicBroadcast_DeliverClient = grpc.BidiStreamingClient[common.Envelope, DeliverResponse] // AtomicBroadcastServer is the server API for AtomicBroadcast service. // All implementations should embed UnimplementedAtomicBroadcastServer -// for forward compatibility +// for forward compatibility. type AtomicBroadcastServer interface { // broadcast receives a reply of Acknowledgement for each common.Envelope in order, indicating success or type of failure - Broadcast(AtomicBroadcast_BroadcastServer) error + Broadcast(grpc.BidiStreamingServer[common.Envelope, BroadcastResponse]) error // deliver first requires an Envelope of type DELIVER_SEEK_INFO with Payload data as a mashaled SeekInfo message, then a stream of block replies is received. - Deliver(AtomicBroadcast_DeliverServer) error + Deliver(grpc.BidiStreamingServer[common.Envelope, DeliverResponse]) error } -// UnimplementedAtomicBroadcastServer should be embedded to have forward compatible implementations. -type UnimplementedAtomicBroadcastServer struct { -} +// UnimplementedAtomicBroadcastServer should be embedded to have +// forward compatible implementations. +// +// NOTE: this should be embedded by value instead of pointer to avoid a nil +// pointer dereference when methods are called. +type UnimplementedAtomicBroadcastServer struct{} -func (UnimplementedAtomicBroadcastServer) Broadcast(AtomicBroadcast_BroadcastServer) error { +func (UnimplementedAtomicBroadcastServer) Broadcast(grpc.BidiStreamingServer[common.Envelope, BroadcastResponse]) error { return status.Errorf(codes.Unimplemented, "method Broadcast not implemented") } -func (UnimplementedAtomicBroadcastServer) Deliver(AtomicBroadcast_DeliverServer) error { +func (UnimplementedAtomicBroadcastServer) Deliver(grpc.BidiStreamingServer[common.Envelope, DeliverResponse]) error { return status.Errorf(codes.Unimplemented, "method Deliver not implemented") } +func (UnimplementedAtomicBroadcastServer) testEmbeddedByValue() {} // UnsafeAtomicBroadcastServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to AtomicBroadcastServer will @@ -137,60 +105,29 @@ type UnsafeAtomicBroadcastServer interface { } func RegisterAtomicBroadcastServer(s grpc.ServiceRegistrar, srv AtomicBroadcastServer) { + // If the following call pancis, it indicates UnimplementedAtomicBroadcastServer was + // embedded by pointer and is nil. This will cause panics if an + // unimplemented method is ever invoked, so we test this at initialization + // time to prevent it from happening at runtime later due to I/O. + if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { + t.testEmbeddedByValue() + } s.RegisterService(&AtomicBroadcast_ServiceDesc, srv) } func _AtomicBroadcast_Broadcast_Handler(srv interface{}, stream grpc.ServerStream) error { - return srv.(AtomicBroadcastServer).Broadcast(&atomicBroadcastBroadcastServer{stream}) -} - -type AtomicBroadcast_BroadcastServer interface { - Send(*BroadcastResponse) error - Recv() (*common.Envelope, error) - grpc.ServerStream -} - -type atomicBroadcastBroadcastServer struct { - grpc.ServerStream + return srv.(AtomicBroadcastServer).Broadcast(&grpc.GenericServerStream[common.Envelope, BroadcastResponse]{ServerStream: stream}) } -func (x *atomicBroadcastBroadcastServer) Send(m *BroadcastResponse) error { - return x.ServerStream.SendMsg(m) -} - -func (x *atomicBroadcastBroadcastServer) Recv() (*common.Envelope, error) { - m := new(common.Envelope) - if err := x.ServerStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type AtomicBroadcast_BroadcastServer = grpc.BidiStreamingServer[common.Envelope, BroadcastResponse] func _AtomicBroadcast_Deliver_Handler(srv interface{}, stream grpc.ServerStream) error { - return srv.(AtomicBroadcastServer).Deliver(&atomicBroadcastDeliverServer{stream}) + return srv.(AtomicBroadcastServer).Deliver(&grpc.GenericServerStream[common.Envelope, DeliverResponse]{ServerStream: stream}) } -type AtomicBroadcast_DeliverServer interface { - Send(*DeliverResponse) error - Recv() (*common.Envelope, error) - grpc.ServerStream -} - -type atomicBroadcastDeliverServer struct { - grpc.ServerStream -} - -func (x *atomicBroadcastDeliverServer) Send(m *DeliverResponse) error { - return x.ServerStream.SendMsg(m) -} - -func (x *atomicBroadcastDeliverServer) Recv() (*common.Envelope, error) { - m := new(common.Envelope) - if err := x.ServerStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type AtomicBroadcast_DeliverServer = grpc.BidiStreamingServer[common.Envelope, DeliverResponse] // AtomicBroadcast_ServiceDesc is the grpc.ServiceDesc for AtomicBroadcast service. // It's only intended for direct use with grpc.RegisterService, diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/blockattestation.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/blockattestation.pb.go deleted file mode 100644 index c286ddbd..00000000 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/blockattestation.pb.go +++ /dev/null @@ -1,296 +0,0 @@ -// Copyright the Hyperledger Fabric contributors. All rights reserved. -// -// SPDX-License-Identifier: Apache-2.0 - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.31.0 -// protoc (unknown) -// source: orderer/blockattestation.proto - -package orderer - -import ( - common "github.com/hyperledger/fabric-protos-go-apiv2/common" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -type BlockAttestation struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Header *common.BlockHeader `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"` - Metadata *common.BlockMetadata `protobuf:"bytes,2,opt,name=metadata,proto3" json:"metadata,omitempty"` -} - -func (x *BlockAttestation) Reset() { - *x = BlockAttestation{} - if protoimpl.UnsafeEnabled { - mi := &file_orderer_blockattestation_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *BlockAttestation) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BlockAttestation) ProtoMessage() {} - -func (x *BlockAttestation) ProtoReflect() protoreflect.Message { - mi := &file_orderer_blockattestation_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 BlockAttestation.ProtoReflect.Descriptor instead. -func (*BlockAttestation) Descriptor() ([]byte, []int) { - return file_orderer_blockattestation_proto_rawDescGZIP(), []int{0} -} - -func (x *BlockAttestation) GetHeader() *common.BlockHeader { - if x != nil { - return x.Header - } - return nil -} - -func (x *BlockAttestation) GetMetadata() *common.BlockMetadata { - if x != nil { - return x.Metadata - } - return nil -} - -type BlockAttestationResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // Types that are assignable to Type: - // - // *BlockAttestationResponse_Status - // *BlockAttestationResponse_BlockAttestation - Type isBlockAttestationResponse_Type `protobuf_oneof:"Type"` -} - -func (x *BlockAttestationResponse) Reset() { - *x = BlockAttestationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_orderer_blockattestation_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *BlockAttestationResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BlockAttestationResponse) ProtoMessage() {} - -func (x *BlockAttestationResponse) ProtoReflect() protoreflect.Message { - mi := &file_orderer_blockattestation_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 BlockAttestationResponse.ProtoReflect.Descriptor instead. -func (*BlockAttestationResponse) Descriptor() ([]byte, []int) { - return file_orderer_blockattestation_proto_rawDescGZIP(), []int{1} -} - -func (m *BlockAttestationResponse) GetType() isBlockAttestationResponse_Type { - if m != nil { - return m.Type - } - return nil -} - -func (x *BlockAttestationResponse) GetStatus() common.Status { - if x, ok := x.GetType().(*BlockAttestationResponse_Status); ok { - return x.Status - } - return common.Status(0) -} - -func (x *BlockAttestationResponse) GetBlockAttestation() *BlockAttestation { - if x, ok := x.GetType().(*BlockAttestationResponse_BlockAttestation); ok { - return x.BlockAttestation - } - return nil -} - -type isBlockAttestationResponse_Type interface { - isBlockAttestationResponse_Type() -} - -type BlockAttestationResponse_Status struct { - Status common.Status `protobuf:"varint,1,opt,name=status,proto3,enum=common.Status,oneof"` -} - -type BlockAttestationResponse_BlockAttestation struct { - BlockAttestation *BlockAttestation `protobuf:"bytes,2,opt,name=block_attestation,json=blockAttestation,proto3,oneof"` -} - -func (*BlockAttestationResponse_Status) isBlockAttestationResponse_Type() {} - -func (*BlockAttestationResponse_BlockAttestation) isBlockAttestationResponse_Type() {} - -var File_orderer_blockattestation_proto protoreflect.FileDescriptor - -var file_orderer_blockattestation_proto_rawDesc = []byte{ - 0x0a, 0x1e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x65, 0x72, 0x2f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x61, - 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x12, 0x07, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x65, 0x72, 0x1a, 0x13, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, - 0x6e, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x72, - 0x0a, 0x10, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x12, 0x2b, 0x0a, 0x06, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x13, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x42, 0x6c, 0x6f, 0x63, - 0x6b, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x06, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, - 0x31, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x15, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, - 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, - 0x74, 0x61, 0x22, 0x96, 0x01, 0x0a, 0x18, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x41, 0x74, 0x74, 0x65, - 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x28, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, - 0x0e, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x48, - 0x00, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x48, 0x0a, 0x11, 0x62, 0x6c, 0x6f, - 0x63, 0x6b, 0x5f, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x65, 0x72, 0x2e, 0x42, - 0x6c, 0x6f, 0x63, 0x6b, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, - 0x00, 0x52, 0x10, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x42, 0x06, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x32, 0x5f, 0x0a, 0x11, 0x42, - 0x6c, 0x6f, 0x63, 0x6b, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, - 0x12, 0x4a, 0x0a, 0x11, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x10, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x45, - 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x1a, 0x21, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x65, - 0x72, 0x2e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x30, 0x01, 0x42, 0xb1, 0x01, 0x0a, - 0x25, 0x6f, 0x72, 0x67, 0x2e, 0x68, 0x79, 0x70, 0x65, 0x72, 0x6c, 0x65, 0x64, 0x67, 0x65, 0x72, - 0x2e, 0x66, 0x61, 0x62, 0x72, 0x69, 0x63, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x6f, - 0x72, 0x64, 0x65, 0x72, 0x65, 0x72, 0x42, 0x15, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x61, 0x74, 0x74, - 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, - 0x35, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x68, 0x79, 0x70, 0x65, - 0x72, 0x6c, 0x65, 0x64, 0x67, 0x65, 0x72, 0x2f, 0x66, 0x61, 0x62, 0x72, 0x69, 0x63, 0x2d, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2d, 0x67, 0x6f, 0x2d, 0x61, 0x70, 0x69, 0x76, 0x32, 0x2f, 0x6f, - 0x72, 0x64, 0x65, 0x72, 0x65, 0x72, 0xa2, 0x02, 0x03, 0x4f, 0x58, 0x58, 0xaa, 0x02, 0x07, 0x4f, - 0x72, 0x64, 0x65, 0x72, 0x65, 0x72, 0xca, 0x02, 0x07, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x65, 0x72, - 0xe2, 0x02, 0x13, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x65, 0x72, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, - 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x07, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x65, 0x72, - 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, -} - -var ( - file_orderer_blockattestation_proto_rawDescOnce sync.Once - file_orderer_blockattestation_proto_rawDescData = file_orderer_blockattestation_proto_rawDesc -) - -func file_orderer_blockattestation_proto_rawDescGZIP() []byte { - file_orderer_blockattestation_proto_rawDescOnce.Do(func() { - file_orderer_blockattestation_proto_rawDescData = protoimpl.X.CompressGZIP(file_orderer_blockattestation_proto_rawDescData) - }) - return file_orderer_blockattestation_proto_rawDescData -} - -var file_orderer_blockattestation_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_orderer_blockattestation_proto_goTypes = []interface{}{ - (*BlockAttestation)(nil), // 0: orderer.BlockAttestation - (*BlockAttestationResponse)(nil), // 1: orderer.BlockAttestationResponse - (*common.BlockHeader)(nil), // 2: common.BlockHeader - (*common.BlockMetadata)(nil), // 3: common.BlockMetadata - (common.Status)(0), // 4: common.Status - (*common.Envelope)(nil), // 5: common.Envelope -} -var file_orderer_blockattestation_proto_depIdxs = []int32{ - 2, // 0: orderer.BlockAttestation.header:type_name -> common.BlockHeader - 3, // 1: orderer.BlockAttestation.metadata:type_name -> common.BlockMetadata - 4, // 2: orderer.BlockAttestationResponse.status:type_name -> common.Status - 0, // 3: orderer.BlockAttestationResponse.block_attestation:type_name -> orderer.BlockAttestation - 5, // 4: orderer.BlockAttestations.BlockAttestations:input_type -> common.Envelope - 1, // 5: orderer.BlockAttestations.BlockAttestations:output_type -> orderer.BlockAttestationResponse - 5, // [5:6] is the sub-list for method output_type - 4, // [4:5] is the sub-list for method input_type - 4, // [4:4] is the sub-list for extension type_name - 4, // [4:4] is the sub-list for extension extendee - 0, // [0:4] is the sub-list for field type_name -} - -func init() { file_orderer_blockattestation_proto_init() } -func file_orderer_blockattestation_proto_init() { - if File_orderer_blockattestation_proto != nil { - return - } - if !protoimpl.UnsafeEnabled { - file_orderer_blockattestation_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*BlockAttestation); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_orderer_blockattestation_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*BlockAttestationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } - file_orderer_blockattestation_proto_msgTypes[1].OneofWrappers = []interface{}{ - (*BlockAttestationResponse_Status)(nil), - (*BlockAttestationResponse_BlockAttestation)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: file_orderer_blockattestation_proto_rawDesc, - NumEnums: 0, - NumMessages: 2, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_orderer_blockattestation_proto_goTypes, - DependencyIndexes: file_orderer_blockattestation_proto_depIdxs, - MessageInfos: file_orderer_blockattestation_proto_msgTypes, - }.Build() - File_orderer_blockattestation_proto = out.File - file_orderer_blockattestation_proto_rawDesc = nil - file_orderer_blockattestation_proto_goTypes = nil - file_orderer_blockattestation_proto_depIdxs = nil -} diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/blockattestation_grpc.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/blockattestation_grpc.pb.go deleted file mode 100644 index f79406a7..00000000 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/blockattestation_grpc.pb.go +++ /dev/null @@ -1,141 +0,0 @@ -// Copyright the Hyperledger Fabric contributors. All rights reserved. -// -// SPDX-License-Identifier: Apache-2.0 - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: orderer/blockattestation.proto - -package orderer - -import ( - context "context" - common "github.com/hyperledger/fabric-protos-go-apiv2/common" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" -) - -// 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 - -const ( - BlockAttestations_BlockAttestations_FullMethodName = "/orderer.BlockAttestations/BlockAttestations" -) - -// BlockAttestationsClient is the client API for BlockAttestations service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. -type BlockAttestationsClient interface { - // BlockAttestations receives an Envelope of type DELIVER_SEEK_INFO , then sends back a stream of BlockAttestations. - BlockAttestations(ctx context.Context, in *common.Envelope, opts ...grpc.CallOption) (BlockAttestations_BlockAttestationsClient, error) -} - -type blockAttestationsClient struct { - cc grpc.ClientConnInterface -} - -func NewBlockAttestationsClient(cc grpc.ClientConnInterface) BlockAttestationsClient { - return &blockAttestationsClient{cc} -} - -func (c *blockAttestationsClient) BlockAttestations(ctx context.Context, in *common.Envelope, opts ...grpc.CallOption) (BlockAttestations_BlockAttestationsClient, error) { - stream, err := c.cc.NewStream(ctx, &BlockAttestations_ServiceDesc.Streams[0], BlockAttestations_BlockAttestations_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &blockAttestationsBlockAttestationsClient{stream} - if err := x.ClientStream.SendMsg(in); err != nil { - return nil, err - } - if err := x.ClientStream.CloseSend(); err != nil { - return nil, err - } - return x, nil -} - -type BlockAttestations_BlockAttestationsClient interface { - Recv() (*BlockAttestationResponse, error) - grpc.ClientStream -} - -type blockAttestationsBlockAttestationsClient struct { - grpc.ClientStream -} - -func (x *blockAttestationsBlockAttestationsClient) Recv() (*BlockAttestationResponse, error) { - m := new(BlockAttestationResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -// BlockAttestationsServer is the server API for BlockAttestations service. -// All implementations should embed UnimplementedBlockAttestationsServer -// for forward compatibility -type BlockAttestationsServer interface { - // BlockAttestations receives an Envelope of type DELIVER_SEEK_INFO , then sends back a stream of BlockAttestations. - BlockAttestations(*common.Envelope, BlockAttestations_BlockAttestationsServer) error -} - -// UnimplementedBlockAttestationsServer should be embedded to have forward compatible implementations. -type UnimplementedBlockAttestationsServer struct { -} - -func (UnimplementedBlockAttestationsServer) BlockAttestations(*common.Envelope, BlockAttestations_BlockAttestationsServer) error { - return status.Errorf(codes.Unimplemented, "method BlockAttestations not implemented") -} - -// UnsafeBlockAttestationsServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to BlockAttestationsServer will -// result in compilation errors. -type UnsafeBlockAttestationsServer interface { - mustEmbedUnimplementedBlockAttestationsServer() -} - -func RegisterBlockAttestationsServer(s grpc.ServiceRegistrar, srv BlockAttestationsServer) { - s.RegisterService(&BlockAttestations_ServiceDesc, srv) -} - -func _BlockAttestations_BlockAttestations_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(common.Envelope) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(BlockAttestationsServer).BlockAttestations(m, &blockAttestationsBlockAttestationsServer{stream}) -} - -type BlockAttestations_BlockAttestationsServer interface { - Send(*BlockAttestationResponse) error - grpc.ServerStream -} - -type blockAttestationsBlockAttestationsServer struct { - grpc.ServerStream -} - -func (x *blockAttestationsBlockAttestationsServer) Send(m *BlockAttestationResponse) error { - return x.ServerStream.SendMsg(m) -} - -// BlockAttestations_ServiceDesc is the grpc.ServiceDesc for BlockAttestations service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var BlockAttestations_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "orderer.BlockAttestations", - HandlerType: (*BlockAttestationsServer)(nil), - Methods: []grpc.MethodDesc{}, - Streams: []grpc.StreamDesc{ - { - StreamName: "BlockAttestations", - Handler: _BlockAttestations_BlockAttestations_Handler, - ServerStreams: true, - }, - }, - Metadata: "orderer/blockattestation.proto", -} diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/cluster.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/cluster.pb.go index 52ce6936..01b6ddc8 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/cluster.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/cluster.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: orderer/cluster.proto @@ -451,7 +451,7 @@ func file_orderer_cluster_proto_rawDescGZIP() []byte { } var file_orderer_cluster_proto_msgTypes = make([]protoimpl.MessageInfo, 5) -var file_orderer_cluster_proto_goTypes = []interface{}{ +var file_orderer_cluster_proto_goTypes = []any{ (*StepRequest)(nil), // 0: orderer.StepRequest (*StepResponse)(nil), // 1: orderer.StepResponse (*ConsensusRequest)(nil), // 2: orderer.ConsensusRequest @@ -481,7 +481,7 @@ func file_orderer_cluster_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_orderer_cluster_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_orderer_cluster_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*StepRequest); i { case 0: return &v.state @@ -493,7 +493,7 @@ func file_orderer_cluster_proto_init() { return nil } } - file_orderer_cluster_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_orderer_cluster_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*StepResponse); i { case 0: return &v.state @@ -505,7 +505,7 @@ func file_orderer_cluster_proto_init() { return nil } } - file_orderer_cluster_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_orderer_cluster_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*ConsensusRequest); i { case 0: return &v.state @@ -517,7 +517,7 @@ func file_orderer_cluster_proto_init() { return nil } } - file_orderer_cluster_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_orderer_cluster_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*SubmitRequest); i { case 0: return &v.state @@ -529,7 +529,7 @@ func file_orderer_cluster_proto_init() { return nil } } - file_orderer_cluster_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_orderer_cluster_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*SubmitResponse); i { case 0: return &v.state @@ -542,11 +542,11 @@ func file_orderer_cluster_proto_init() { } } } - file_orderer_cluster_proto_msgTypes[0].OneofWrappers = []interface{}{ + file_orderer_cluster_proto_msgTypes[0].OneofWrappers = []any{ (*StepRequest_ConsensusRequest)(nil), (*StepRequest_SubmitRequest)(nil), } - file_orderer_cluster_proto_msgTypes[1].OneofWrappers = []interface{}{ + file_orderer_cluster_proto_msgTypes[1].OneofWrappers = []any{ (*StepResponse_SubmitRes)(nil), } type x struct{} diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/cluster_grpc.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/cluster_grpc.pb.go index 1b62225d..cef1af28 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/cluster_grpc.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/cluster_grpc.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: -// - protoc-gen-go-grpc v1.3.0 +// - protoc-gen-go-grpc v1.5.1 // - protoc (unknown) // source: orderer/cluster.proto @@ -19,8 +19,8 @@ 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 +// Requires gRPC-Go v1.64.0 or later. +const _ = grpc.SupportPackageIsVersion9 const ( Cluster_Step_FullMethodName = "/orderer.Cluster/Step" @@ -29,9 +29,11 @@ const ( // ClusterClient is the client API for Cluster service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +// +// Cluster defines communication between cluster members. type ClusterClient interface { // Step passes an implementation-specific message to another cluster member. - Step(ctx context.Context, opts ...grpc.CallOption) (Cluster_StepClient, error) + Step(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[StepRequest, StepResponse], error) } type clusterClient struct { @@ -42,52 +44,40 @@ func NewClusterClient(cc grpc.ClientConnInterface) ClusterClient { return &clusterClient{cc} } -func (c *clusterClient) Step(ctx context.Context, opts ...grpc.CallOption) (Cluster_StepClient, error) { - stream, err := c.cc.NewStream(ctx, &Cluster_ServiceDesc.Streams[0], Cluster_Step_FullMethodName, opts...) +func (c *clusterClient) Step(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[StepRequest, StepResponse], error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) + stream, err := c.cc.NewStream(ctx, &Cluster_ServiceDesc.Streams[0], Cluster_Step_FullMethodName, cOpts...) if err != nil { return nil, err } - x := &clusterStepClient{stream} + x := &grpc.GenericClientStream[StepRequest, StepResponse]{ClientStream: stream} return x, nil } -type Cluster_StepClient interface { - Send(*StepRequest) error - Recv() (*StepResponse, error) - grpc.ClientStream -} - -type clusterStepClient struct { - grpc.ClientStream -} - -func (x *clusterStepClient) Send(m *StepRequest) error { - return x.ClientStream.SendMsg(m) -} - -func (x *clusterStepClient) Recv() (*StepResponse, error) { - m := new(StepResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type Cluster_StepClient = grpc.BidiStreamingClient[StepRequest, StepResponse] // ClusterServer is the server API for Cluster service. // All implementations should embed UnimplementedClusterServer -// for forward compatibility +// for forward compatibility. +// +// Cluster defines communication between cluster members. type ClusterServer interface { // Step passes an implementation-specific message to another cluster member. - Step(Cluster_StepServer) error + Step(grpc.BidiStreamingServer[StepRequest, StepResponse]) error } -// UnimplementedClusterServer should be embedded to have forward compatible implementations. -type UnimplementedClusterServer struct { -} +// UnimplementedClusterServer should be embedded to have +// forward compatible implementations. +// +// NOTE: this should be embedded by value instead of pointer to avoid a nil +// pointer dereference when methods are called. +type UnimplementedClusterServer struct{} -func (UnimplementedClusterServer) Step(Cluster_StepServer) error { +func (UnimplementedClusterServer) Step(grpc.BidiStreamingServer[StepRequest, StepResponse]) error { return status.Errorf(codes.Unimplemented, "method Step not implemented") } +func (UnimplementedClusterServer) testEmbeddedByValue() {} // UnsafeClusterServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to ClusterServer will @@ -97,34 +87,22 @@ type UnsafeClusterServer interface { } func RegisterClusterServer(s grpc.ServiceRegistrar, srv ClusterServer) { + // If the following call pancis, it indicates UnimplementedClusterServer was + // embedded by pointer and is nil. This will cause panics if an + // unimplemented method is ever invoked, so we test this at initialization + // time to prevent it from happening at runtime later due to I/O. + if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { + t.testEmbeddedByValue() + } s.RegisterService(&Cluster_ServiceDesc, srv) } func _Cluster_Step_Handler(srv interface{}, stream grpc.ServerStream) error { - return srv.(ClusterServer).Step(&clusterStepServer{stream}) -} - -type Cluster_StepServer interface { - Send(*StepResponse) error - Recv() (*StepRequest, error) - grpc.ServerStream -} - -type clusterStepServer struct { - grpc.ServerStream + return srv.(ClusterServer).Step(&grpc.GenericServerStream[StepRequest, StepResponse]{ServerStream: stream}) } -func (x *clusterStepServer) Send(m *StepResponse) error { - return x.ServerStream.SendMsg(m) -} - -func (x *clusterStepServer) Recv() (*StepRequest, error) { - m := new(StepRequest) - if err := x.ServerStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type Cluster_StepServer = grpc.BidiStreamingServer[StepRequest, StepResponse] // Cluster_ServiceDesc is the grpc.ServiceDesc for Cluster service. // It's only intended for direct use with grpc.RegisterService, diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/clusterserver.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/clusterserver.pb.go index 6012de41..eb75a832 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/clusterserver.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/clusterserver.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: orderer/clusterserver.proto @@ -592,7 +592,7 @@ func file_orderer_clusterserver_proto_rawDescGZIP() []byte { } var file_orderer_clusterserver_proto_msgTypes = make([]protoimpl.MessageInfo, 6) -var file_orderer_clusterserver_proto_goTypes = []interface{}{ +var file_orderer_clusterserver_proto_goTypes = []any{ (*ClusterNodeServiceStepRequest)(nil), // 0: orderer.ClusterNodeServiceStepRequest (*ClusterNodeServiceStepResponse)(nil), // 1: orderer.ClusterNodeServiceStepResponse (*NodeConsensusRequest)(nil), // 2: orderer.NodeConsensusRequest @@ -626,7 +626,7 @@ func file_orderer_clusterserver_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_orderer_clusterserver_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_orderer_clusterserver_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ClusterNodeServiceStepRequest); i { case 0: return &v.state @@ -638,7 +638,7 @@ func file_orderer_clusterserver_proto_init() { return nil } } - file_orderer_clusterserver_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_orderer_clusterserver_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*ClusterNodeServiceStepResponse); i { case 0: return &v.state @@ -650,7 +650,7 @@ func file_orderer_clusterserver_proto_init() { return nil } } - file_orderer_clusterserver_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_orderer_clusterserver_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*NodeConsensusRequest); i { case 0: return &v.state @@ -662,7 +662,7 @@ func file_orderer_clusterserver_proto_init() { return nil } } - file_orderer_clusterserver_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_orderer_clusterserver_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*NodeTransactionOrderRequest); i { case 0: return &v.state @@ -674,7 +674,7 @@ func file_orderer_clusterserver_proto_init() { return nil } } - file_orderer_clusterserver_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_orderer_clusterserver_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*TransactionOrderResponse); i { case 0: return &v.state @@ -686,7 +686,7 @@ func file_orderer_clusterserver_proto_init() { return nil } } - file_orderer_clusterserver_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_orderer_clusterserver_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*NodeAuthRequest); i { case 0: return &v.state @@ -699,12 +699,12 @@ func file_orderer_clusterserver_proto_init() { } } } - file_orderer_clusterserver_proto_msgTypes[0].OneofWrappers = []interface{}{ + file_orderer_clusterserver_proto_msgTypes[0].OneofWrappers = []any{ (*ClusterNodeServiceStepRequest_NodeConrequest)(nil), (*ClusterNodeServiceStepRequest_NodeTranrequest)(nil), (*ClusterNodeServiceStepRequest_NodeAuthrequest)(nil), } - file_orderer_clusterserver_proto_msgTypes[1].OneofWrappers = []interface{}{ + file_orderer_clusterserver_proto_msgTypes[1].OneofWrappers = []any{ (*ClusterNodeServiceStepResponse_TranorderRes)(nil), } type x struct{} diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/clusterserver_grpc.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/clusterserver_grpc.pb.go index d4c8fa58..bb2ac2e3 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/clusterserver_grpc.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/clusterserver_grpc.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: -// - protoc-gen-go-grpc v1.3.0 +// - protoc-gen-go-grpc v1.5.1 // - protoc (unknown) // source: orderer/clusterserver.proto @@ -19,8 +19,8 @@ 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 +// Requires gRPC-Go v1.64.0 or later. +const _ = grpc.SupportPackageIsVersion9 const ( ClusterNodeService_Step_FullMethodName = "/orderer.ClusterNodeService/Step" @@ -29,9 +29,11 @@ const ( // ClusterNodeServiceClient is the client API for ClusterNodeService service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +// +// Service ClusterNodeService defines communication between cluster members. type ClusterNodeServiceClient interface { // Step passes an implementation-specific message to another cluster member. - Step(ctx context.Context, opts ...grpc.CallOption) (ClusterNodeService_StepClient, error) + Step(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[ClusterNodeServiceStepRequest, ClusterNodeServiceStepResponse], error) } type clusterNodeServiceClient struct { @@ -42,52 +44,40 @@ func NewClusterNodeServiceClient(cc grpc.ClientConnInterface) ClusterNodeService return &clusterNodeServiceClient{cc} } -func (c *clusterNodeServiceClient) Step(ctx context.Context, opts ...grpc.CallOption) (ClusterNodeService_StepClient, error) { - stream, err := c.cc.NewStream(ctx, &ClusterNodeService_ServiceDesc.Streams[0], ClusterNodeService_Step_FullMethodName, opts...) +func (c *clusterNodeServiceClient) Step(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[ClusterNodeServiceStepRequest, ClusterNodeServiceStepResponse], error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) + stream, err := c.cc.NewStream(ctx, &ClusterNodeService_ServiceDesc.Streams[0], ClusterNodeService_Step_FullMethodName, cOpts...) if err != nil { return nil, err } - x := &clusterNodeServiceStepClient{stream} + x := &grpc.GenericClientStream[ClusterNodeServiceStepRequest, ClusterNodeServiceStepResponse]{ClientStream: stream} return x, nil } -type ClusterNodeService_StepClient interface { - Send(*ClusterNodeServiceStepRequest) error - Recv() (*ClusterNodeServiceStepResponse, error) - grpc.ClientStream -} - -type clusterNodeServiceStepClient struct { - grpc.ClientStream -} - -func (x *clusterNodeServiceStepClient) Send(m *ClusterNodeServiceStepRequest) error { - return x.ClientStream.SendMsg(m) -} - -func (x *clusterNodeServiceStepClient) Recv() (*ClusterNodeServiceStepResponse, error) { - m := new(ClusterNodeServiceStepResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type ClusterNodeService_StepClient = grpc.BidiStreamingClient[ClusterNodeServiceStepRequest, ClusterNodeServiceStepResponse] // ClusterNodeServiceServer is the server API for ClusterNodeService service. // All implementations should embed UnimplementedClusterNodeServiceServer -// for forward compatibility +// for forward compatibility. +// +// Service ClusterNodeService defines communication between cluster members. type ClusterNodeServiceServer interface { // Step passes an implementation-specific message to another cluster member. - Step(ClusterNodeService_StepServer) error + Step(grpc.BidiStreamingServer[ClusterNodeServiceStepRequest, ClusterNodeServiceStepResponse]) error } -// UnimplementedClusterNodeServiceServer should be embedded to have forward compatible implementations. -type UnimplementedClusterNodeServiceServer struct { -} +// UnimplementedClusterNodeServiceServer should be embedded to have +// forward compatible implementations. +// +// NOTE: this should be embedded by value instead of pointer to avoid a nil +// pointer dereference when methods are called. +type UnimplementedClusterNodeServiceServer struct{} -func (UnimplementedClusterNodeServiceServer) Step(ClusterNodeService_StepServer) error { +func (UnimplementedClusterNodeServiceServer) Step(grpc.BidiStreamingServer[ClusterNodeServiceStepRequest, ClusterNodeServiceStepResponse]) error { return status.Errorf(codes.Unimplemented, "method Step not implemented") } +func (UnimplementedClusterNodeServiceServer) testEmbeddedByValue() {} // UnsafeClusterNodeServiceServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to ClusterNodeServiceServer will @@ -97,34 +87,22 @@ type UnsafeClusterNodeServiceServer interface { } func RegisterClusterNodeServiceServer(s grpc.ServiceRegistrar, srv ClusterNodeServiceServer) { + // If the following call pancis, it indicates UnimplementedClusterNodeServiceServer was + // embedded by pointer and is nil. This will cause panics if an + // unimplemented method is ever invoked, so we test this at initialization + // time to prevent it from happening at runtime later due to I/O. + if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { + t.testEmbeddedByValue() + } s.RegisterService(&ClusterNodeService_ServiceDesc, srv) } func _ClusterNodeService_Step_Handler(srv interface{}, stream grpc.ServerStream) error { - return srv.(ClusterNodeServiceServer).Step(&clusterNodeServiceStepServer{stream}) -} - -type ClusterNodeService_StepServer interface { - Send(*ClusterNodeServiceStepResponse) error - Recv() (*ClusterNodeServiceStepRequest, error) - grpc.ServerStream -} - -type clusterNodeServiceStepServer struct { - grpc.ServerStream + return srv.(ClusterNodeServiceServer).Step(&grpc.GenericServerStream[ClusterNodeServiceStepRequest, ClusterNodeServiceStepResponse]{ServerStream: stream}) } -func (x *clusterNodeServiceStepServer) Send(m *ClusterNodeServiceStepResponse) error { - return x.ServerStream.SendMsg(m) -} - -func (x *clusterNodeServiceStepServer) Recv() (*ClusterNodeServiceStepRequest, error) { - m := new(ClusterNodeServiceStepRequest) - if err := x.ServerStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type ClusterNodeService_StepServer = grpc.BidiStreamingServer[ClusterNodeServiceStepRequest, ClusterNodeServiceStepResponse] // ClusterNodeService_ServiceDesc is the grpc.ServiceDesc for ClusterNodeService service. // It's only intended for direct use with grpc.RegisterService, diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/configuration.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/configuration.pb.go index 58f2f6a5..f35e688c 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/configuration.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/configuration.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: orderer/configuration.proto @@ -420,7 +420,7 @@ func file_orderer_configuration_proto_rawDescGZIP() []byte { var file_orderer_configuration_proto_enumTypes = make([]protoimpl.EnumInfo, 1) var file_orderer_configuration_proto_msgTypes = make([]protoimpl.MessageInfo, 5) -var file_orderer_configuration_proto_goTypes = []interface{}{ +var file_orderer_configuration_proto_goTypes = []any{ (ConsensusType_State)(0), // 0: orderer.ConsensusType.State (*ConsensusType)(nil), // 1: orderer.ConsensusType (*BatchSize)(nil), // 2: orderer.BatchSize @@ -443,7 +443,7 @@ func file_orderer_configuration_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_orderer_configuration_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_orderer_configuration_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ConsensusType); i { case 0: return &v.state @@ -455,7 +455,7 @@ func file_orderer_configuration_proto_init() { return nil } } - file_orderer_configuration_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_orderer_configuration_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*BatchSize); i { case 0: return &v.state @@ -467,7 +467,7 @@ func file_orderer_configuration_proto_init() { return nil } } - file_orderer_configuration_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_orderer_configuration_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*BatchTimeout); i { case 0: return &v.state @@ -479,7 +479,7 @@ func file_orderer_configuration_proto_init() { return nil } } - file_orderer_configuration_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_orderer_configuration_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*KafkaBrokers); i { case 0: return &v.state @@ -491,7 +491,7 @@ func file_orderer_configuration_proto_init() { return nil } } - file_orderer_configuration_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_orderer_configuration_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*ChannelRestrictions); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/etcdraft/configuration.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/etcdraft/configuration.pb.go index e0b0b857..c64f3d4e 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/etcdraft/configuration.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/etcdraft/configuration.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: orderer/etcdraft/configuration.proto @@ -299,7 +299,7 @@ func file_orderer_etcdraft_configuration_proto_rawDescGZIP() []byte { } var file_orderer_etcdraft_configuration_proto_msgTypes = make([]protoimpl.MessageInfo, 3) -var file_orderer_etcdraft_configuration_proto_goTypes = []interface{}{ +var file_orderer_etcdraft_configuration_proto_goTypes = []any{ (*ConfigMetadata)(nil), // 0: etcdraft.ConfigMetadata (*Consenter)(nil), // 1: etcdraft.Consenter (*Options)(nil), // 2: etcdraft.Options @@ -320,7 +320,7 @@ func file_orderer_etcdraft_configuration_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_orderer_etcdraft_configuration_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_orderer_etcdraft_configuration_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ConfigMetadata); i { case 0: return &v.state @@ -332,7 +332,7 @@ func file_orderer_etcdraft_configuration_proto_init() { return nil } } - file_orderer_etcdraft_configuration_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_orderer_etcdraft_configuration_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*Consenter); i { case 0: return &v.state @@ -344,7 +344,7 @@ func file_orderer_etcdraft_configuration_proto_init() { return nil } } - file_orderer_etcdraft_configuration_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_orderer_etcdraft_configuration_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*Options); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/etcdraft/metadata.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/etcdraft/metadata.pb.go index 821265cb..75dc9ba6 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/etcdraft/metadata.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/etcdraft/metadata.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: orderer/etcdraft/metadata.proto @@ -189,7 +189,7 @@ func file_orderer_etcdraft_metadata_proto_rawDescGZIP() []byte { } var file_orderer_etcdraft_metadata_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_orderer_etcdraft_metadata_proto_goTypes = []interface{}{ +var file_orderer_etcdraft_metadata_proto_goTypes = []any{ (*BlockMetadata)(nil), // 0: etcdraft.BlockMetadata (*ClusterMetadata)(nil), // 1: etcdraft.ClusterMetadata } @@ -207,7 +207,7 @@ func file_orderer_etcdraft_metadata_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_orderer_etcdraft_metadata_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_orderer_etcdraft_metadata_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*BlockMetadata); i { case 0: return &v.state @@ -219,7 +219,7 @@ func file_orderer_etcdraft_metadata_proto_init() { return nil } } - file_orderer_etcdraft_metadata_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_orderer_etcdraft_metadata_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*ClusterMetadata); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/smartbft/configuration.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/smartbft/configuration.pb.go index 9660b0b1..1f6d0b94 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/smartbft/configuration.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/orderer/smartbft/configuration.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: orderer/smartbft/configuration.proto @@ -362,7 +362,7 @@ func file_orderer_smartbft_configuration_proto_rawDescGZIP() []byte { var file_orderer_smartbft_configuration_proto_enumTypes = make([]protoimpl.EnumInfo, 1) var file_orderer_smartbft_configuration_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_orderer_smartbft_configuration_proto_goTypes = []interface{}{ +var file_orderer_smartbft_configuration_proto_goTypes = []any{ (Options_Rotation)(0), // 0: orderer.smartbft.Options.Rotation (*Options)(nil), // 1: orderer.smartbft.Options } @@ -381,7 +381,7 @@ func file_orderer_smartbft_configuration_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_orderer_smartbft_configuration_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_orderer_smartbft_configuration_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*Options); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode.pb.go index 6e0c2724..094a54d2 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/chaincode.proto @@ -623,6 +623,78 @@ func (x *ChaincodeData) GetInstantiationPolicy() *common.SignaturePolicyEnvelope return nil } +// ChaincodeAdditionalParams - parameters passed to chaincode to notify about peer capabilities +type ChaincodeAdditionalParams struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + UseWriteBatch bool `protobuf:"varint,1,opt,name=use_write_batch,json=useWriteBatch,proto3" json:"use_write_batch,omitempty"` // an indication that the peer can handle state write batches + MaxSizeWriteBatch uint32 `protobuf:"varint,2,opt,name=max_size_write_batch,json=maxSizeWriteBatch,proto3" json:"max_size_write_batch,omitempty"` // maximum size of batches with write state + UseGetMultipleKeys bool `protobuf:"varint,3,opt,name=use_get_multiple_keys,json=useGetMultipleKeys,proto3" json:"use_get_multiple_keys,omitempty"` // an indication that the peer can handle get multiple keys + MaxSizeGetMultipleKeys uint32 `protobuf:"varint,4,opt,name=max_size_get_multiple_keys,json=maxSizeGetMultipleKeys,proto3" json:"max_size_get_multiple_keys,omitempty"` // maximum size of batches with get multiple keys +} + +func (x *ChaincodeAdditionalParams) Reset() { + *x = ChaincodeAdditionalParams{} + if protoimpl.UnsafeEnabled { + mi := &file_peer_chaincode_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChaincodeAdditionalParams) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChaincodeAdditionalParams) ProtoMessage() {} + +func (x *ChaincodeAdditionalParams) ProtoReflect() protoreflect.Message { + mi := &file_peer_chaincode_proto_msgTypes[8] + 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 ChaincodeAdditionalParams.ProtoReflect.Descriptor instead. +func (*ChaincodeAdditionalParams) Descriptor() ([]byte, []int) { + return file_peer_chaincode_proto_rawDescGZIP(), []int{8} +} + +func (x *ChaincodeAdditionalParams) GetUseWriteBatch() bool { + if x != nil { + return x.UseWriteBatch + } + return false +} + +func (x *ChaincodeAdditionalParams) GetMaxSizeWriteBatch() uint32 { + if x != nil { + return x.MaxSizeWriteBatch + } + return 0 +} + +func (x *ChaincodeAdditionalParams) GetUseGetMultipleKeys() bool { + if x != nil { + return x.UseGetMultipleKeys + } + return false +} + +func (x *ChaincodeAdditionalParams) GetMaxSizeGetMultipleKeys() uint32 { + if x != nil { + return x.MaxSizeGetMultipleKeys + } + return 0 +} + var File_peer_chaincode_proto protoreflect.FileDescriptor var file_peer_chaincode_proto_rawDesc = []byte{ @@ -705,18 +777,32 @@ var file_peer_chaincode_proto_rawDesc = []byte{ 0x79, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x52, 0x13, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, - 0x74, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x42, 0xa0, 0x01, - 0x0a, 0x22, 0x6f, 0x72, 0x67, 0x2e, 0x68, 0x79, 0x70, 0x65, 0x72, 0x6c, 0x65, 0x64, 0x67, 0x65, - 0x72, 0x2e, 0x66, 0x61, 0x62, 0x72, 0x69, 0x63, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, - 0x70, 0x65, 0x65, 0x72, 0x42, 0x0e, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x50, - 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x32, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, - 0x6f, 0x6d, 0x2f, 0x68, 0x79, 0x70, 0x65, 0x72, 0x6c, 0x65, 0x64, 0x67, 0x65, 0x72, 0x2f, 0x66, - 0x61, 0x62, 0x72, 0x69, 0x63, 0x2d, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2d, 0x67, 0x6f, 0x2d, - 0x61, 0x70, 0x69, 0x76, 0x32, 0x2f, 0x70, 0x65, 0x65, 0x72, 0xa2, 0x02, 0x03, 0x50, 0x58, 0x58, - 0xaa, 0x02, 0x06, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0xca, 0x02, 0x06, 0x50, 0x72, 0x6f, 0x74, - 0x6f, 0x73, 0xe2, 0x02, 0x12, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x5c, 0x47, 0x50, 0x42, 0x4d, - 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x06, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, - 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x74, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x22, 0xe3, 0x01, + 0x0a, 0x19, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x41, 0x64, 0x64, 0x69, 0x74, + 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x26, 0x0a, 0x0f, 0x75, + 0x73, 0x65, 0x5f, 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, 0x62, 0x61, 0x74, 0x63, 0x68, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x08, 0x52, 0x0d, 0x75, 0x73, 0x65, 0x57, 0x72, 0x69, 0x74, 0x65, 0x42, 0x61, + 0x74, 0x63, 0x68, 0x12, 0x2f, 0x0a, 0x14, 0x6d, 0x61, 0x78, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x5f, + 0x77, 0x72, 0x69, 0x74, 0x65, 0x5f, 0x62, 0x61, 0x74, 0x63, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0d, 0x52, 0x11, 0x6d, 0x61, 0x78, 0x53, 0x69, 0x7a, 0x65, 0x57, 0x72, 0x69, 0x74, 0x65, 0x42, + 0x61, 0x74, 0x63, 0x68, 0x12, 0x31, 0x0a, 0x15, 0x75, 0x73, 0x65, 0x5f, 0x67, 0x65, 0x74, 0x5f, + 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x65, 0x5f, 0x6b, 0x65, 0x79, 0x73, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x08, 0x52, 0x12, 0x75, 0x73, 0x65, 0x47, 0x65, 0x74, 0x4d, 0x75, 0x6c, 0x74, 0x69, + 0x70, 0x6c, 0x65, 0x4b, 0x65, 0x79, 0x73, 0x12, 0x3a, 0x0a, 0x1a, 0x6d, 0x61, 0x78, 0x5f, 0x73, + 0x69, 0x7a, 0x65, 0x5f, 0x67, 0x65, 0x74, 0x5f, 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x65, + 0x5f, 0x6b, 0x65, 0x79, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x16, 0x6d, 0x61, 0x78, + 0x53, 0x69, 0x7a, 0x65, 0x47, 0x65, 0x74, 0x4d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x65, 0x4b, + 0x65, 0x79, 0x73, 0x42, 0xa0, 0x01, 0x0a, 0x22, 0x6f, 0x72, 0x67, 0x2e, 0x68, 0x79, 0x70, 0x65, + 0x72, 0x6c, 0x65, 0x64, 0x67, 0x65, 0x72, 0x2e, 0x66, 0x61, 0x62, 0x72, 0x69, 0x63, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x70, 0x65, 0x65, 0x72, 0x42, 0x0e, 0x43, 0x68, 0x61, 0x69, + 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x32, 0x67, 0x69, + 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x68, 0x79, 0x70, 0x65, 0x72, 0x6c, 0x65, + 0x64, 0x67, 0x65, 0x72, 0x2f, 0x66, 0x61, 0x62, 0x72, 0x69, 0x63, 0x2d, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x73, 0x2d, 0x67, 0x6f, 0x2d, 0x61, 0x70, 0x69, 0x76, 0x32, 0x2f, 0x70, 0x65, 0x65, 0x72, + 0xa2, 0x02, 0x03, 0x50, 0x58, 0x58, 0xaa, 0x02, 0x06, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0xca, + 0x02, 0x06, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0xe2, 0x02, 0x12, 0x50, 0x72, 0x6f, 0x74, 0x6f, + 0x73, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x06, + 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -732,8 +818,8 @@ func file_peer_chaincode_proto_rawDescGZIP() []byte { } var file_peer_chaincode_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_peer_chaincode_proto_msgTypes = make([]protoimpl.MessageInfo, 9) -var file_peer_chaincode_proto_goTypes = []interface{}{ +var file_peer_chaincode_proto_msgTypes = make([]protoimpl.MessageInfo, 10) +var file_peer_chaincode_proto_goTypes = []any{ (ChaincodeSpec_Type)(0), // 0: protos.ChaincodeSpec.Type (*ChaincodeID)(nil), // 1: protos.ChaincodeID (*ChaincodeInput)(nil), // 2: protos.ChaincodeInput @@ -743,18 +829,19 @@ var file_peer_chaincode_proto_goTypes = []interface{}{ (*LifecycleEvent)(nil), // 6: protos.LifecycleEvent (*CDSData)(nil), // 7: protos.CDSData (*ChaincodeData)(nil), // 8: protos.ChaincodeData - nil, // 9: protos.ChaincodeInput.DecorationsEntry - (*common.SignaturePolicyEnvelope)(nil), // 10: common.SignaturePolicyEnvelope + (*ChaincodeAdditionalParams)(nil), // 9: protos.ChaincodeAdditionalParams + nil, // 10: protos.ChaincodeInput.DecorationsEntry + (*common.SignaturePolicyEnvelope)(nil), // 11: common.SignaturePolicyEnvelope } var file_peer_chaincode_proto_depIdxs = []int32{ - 9, // 0: protos.ChaincodeInput.decorations:type_name -> protos.ChaincodeInput.DecorationsEntry + 10, // 0: protos.ChaincodeInput.decorations:type_name -> protos.ChaincodeInput.DecorationsEntry 0, // 1: protos.ChaincodeSpec.type:type_name -> protos.ChaincodeSpec.Type 1, // 2: protos.ChaincodeSpec.chaincode_id:type_name -> protos.ChaincodeID 2, // 3: protos.ChaincodeSpec.input:type_name -> protos.ChaincodeInput 3, // 4: protos.ChaincodeDeploymentSpec.chaincode_spec:type_name -> protos.ChaincodeSpec 3, // 5: protos.ChaincodeInvocationSpec.chaincode_spec:type_name -> protos.ChaincodeSpec - 10, // 6: protos.ChaincodeData.policy:type_name -> common.SignaturePolicyEnvelope - 10, // 7: protos.ChaincodeData.instantiation_policy:type_name -> common.SignaturePolicyEnvelope + 11, // 6: protos.ChaincodeData.policy:type_name -> common.SignaturePolicyEnvelope + 11, // 7: protos.ChaincodeData.instantiation_policy:type_name -> common.SignaturePolicyEnvelope 8, // [8:8] is the sub-list for method output_type 8, // [8:8] is the sub-list for method input_type 8, // [8:8] is the sub-list for extension type_name @@ -768,7 +855,7 @@ func file_peer_chaincode_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_peer_chaincode_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeID); i { case 0: return &v.state @@ -780,7 +867,7 @@ func file_peer_chaincode_proto_init() { return nil } } - file_peer_chaincode_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeInput); i { case 0: return &v.state @@ -792,7 +879,7 @@ func file_peer_chaincode_proto_init() { return nil } } - file_peer_chaincode_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeSpec); i { case 0: return &v.state @@ -804,7 +891,7 @@ func file_peer_chaincode_proto_init() { return nil } } - file_peer_chaincode_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeDeploymentSpec); i { case 0: return &v.state @@ -816,7 +903,7 @@ func file_peer_chaincode_proto_init() { return nil } } - file_peer_chaincode_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeInvocationSpec); i { case 0: return &v.state @@ -828,7 +915,7 @@ func file_peer_chaincode_proto_init() { return nil } } - file_peer_chaincode_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*LifecycleEvent); i { case 0: return &v.state @@ -840,7 +927,7 @@ func file_peer_chaincode_proto_init() { return nil } } - file_peer_chaincode_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_proto_msgTypes[6].Exporter = func(v any, i int) any { switch v := v.(*CDSData); i { case 0: return &v.state @@ -852,7 +939,7 @@ func file_peer_chaincode_proto_init() { return nil } } - file_peer_chaincode_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_proto_msgTypes[7].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeData); i { case 0: return &v.state @@ -864,6 +951,18 @@ func file_peer_chaincode_proto_init() { return nil } } + file_peer_chaincode_proto_msgTypes[8].Exporter = func(v any, i int) any { + switch v := v.(*ChaincodeAdditionalParams); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } } type x struct{} out := protoimpl.TypeBuilder{ @@ -871,7 +970,7 @@ func file_peer_chaincode_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_peer_chaincode_proto_rawDesc, NumEnums: 1, - NumMessages: 9, + NumMessages: 10, NumExtensions: 0, NumServices: 0, }, diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_event.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_event.pb.go index ab856c7a..0eb0d03f 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_event.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_event.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/chaincode_event.proto @@ -137,7 +137,7 @@ func file_peer_chaincode_event_proto_rawDescGZIP() []byte { } var file_peer_chaincode_event_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_peer_chaincode_event_proto_goTypes = []interface{}{ +var file_peer_chaincode_event_proto_goTypes = []any{ (*ChaincodeEvent)(nil), // 0: protos.ChaincodeEvent } var file_peer_chaincode_event_proto_depIdxs = []int32{ @@ -154,7 +154,7 @@ func file_peer_chaincode_event_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_peer_chaincode_event_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_event_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeEvent); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_shim.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_shim.pb.go index 69566871..3f7a2443 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_shim.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_shim.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/chaincode_shim.proto @@ -51,6 +51,8 @@ const ( ChaincodeMessage_PUT_STATE_METADATA ChaincodeMessage_Type = 21 ChaincodeMessage_GET_PRIVATE_DATA_HASH ChaincodeMessage_Type = 22 ChaincodeMessage_PURGE_PRIVATE_DATA ChaincodeMessage_Type = 23 + ChaincodeMessage_WRITE_BATCH_STATE ChaincodeMessage_Type = 24 + ChaincodeMessage_GET_STATE_MULTIPLE ChaincodeMessage_Type = 25 ) // Enum value maps for ChaincodeMessage_Type. @@ -79,6 +81,8 @@ var ( 21: "PUT_STATE_METADATA", 22: "GET_PRIVATE_DATA_HASH", 23: "PURGE_PRIVATE_DATA", + 24: "WRITE_BATCH_STATE", + 25: "GET_STATE_MULTIPLE", } ChaincodeMessage_Type_value = map[string]int32{ "UNDEFINED": 0, @@ -104,6 +108,8 @@ var ( "PUT_STATE_METADATA": 21, "GET_PRIVATE_DATA_HASH": 22, "PURGE_PRIVATE_DATA": 23, + "WRITE_BATCH_STATE": 24, + "GET_STATE_MULTIPLE": 25, } ) @@ -134,6 +140,61 @@ func (ChaincodeMessage_Type) EnumDescriptor() ([]byte, []int) { return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{0, 0} } +type WriteRecord_Type int32 + +const ( + WriteRecord_UNDEFINED WriteRecord_Type = 0 + WriteRecord_PUT_STATE WriteRecord_Type = 9 + WriteRecord_DEL_STATE WriteRecord_Type = 10 + WriteRecord_PUT_STATE_METADATA WriteRecord_Type = 21 + WriteRecord_PURGE_PRIVATE_DATA WriteRecord_Type = 23 +) + +// Enum value maps for WriteRecord_Type. +var ( + WriteRecord_Type_name = map[int32]string{ + 0: "UNDEFINED", + 9: "PUT_STATE", + 10: "DEL_STATE", + 21: "PUT_STATE_METADATA", + 23: "PURGE_PRIVATE_DATA", + } + WriteRecord_Type_value = map[string]int32{ + "UNDEFINED": 0, + "PUT_STATE": 9, + "DEL_STATE": 10, + "PUT_STATE_METADATA": 21, + "PURGE_PRIVATE_DATA": 23, + } +) + +func (x WriteRecord_Type) Enum() *WriteRecord_Type { + p := new(WriteRecord_Type) + *p = x + return p +} + +func (x WriteRecord_Type) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (WriteRecord_Type) Descriptor() protoreflect.EnumDescriptor { + return file_peer_chaincode_shim_proto_enumTypes[1].Descriptor() +} + +func (WriteRecord_Type) Type() protoreflect.EnumType { + return &file_peer_chaincode_shim_proto_enumTypes[1] +} + +func (x WriteRecord_Type) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use WriteRecord_Type.Descriptor instead. +func (WriteRecord_Type) EnumDescriptor() ([]byte, []int) { + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{8, 0} +} + type ChaincodeMessage struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -346,6 +407,113 @@ func (x *GetStateMetadata) GetCollection() string { return "" } +// GetStateMultiple is the payload of the ChaincodeMessage. +// It contains the keys to be retrieved from the ledger. +// If a collection is specified, the keys will be retrieved +// from the collection (i.e., the private state). +type GetStateMultiple struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Keys []string `protobuf:"bytes,1,rep,name=keys,proto3" json:"keys,omitempty"` + Collection string `protobuf:"bytes,2,opt,name=collection,proto3" json:"collection,omitempty"` +} + +func (x *GetStateMultiple) Reset() { + *x = GetStateMultiple{} + if protoimpl.UnsafeEnabled { + mi := &file_peer_chaincode_shim_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetStateMultiple) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetStateMultiple) ProtoMessage() {} + +func (x *GetStateMultiple) ProtoReflect() protoreflect.Message { + mi := &file_peer_chaincode_shim_proto_msgTypes[3] + 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 GetStateMultiple.ProtoReflect.Descriptor instead. +func (*GetStateMultiple) Descriptor() ([]byte, []int) { + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{3} +} + +func (x *GetStateMultiple) GetKeys() []string { + if x != nil { + return x.Keys + } + return nil +} + +func (x *GetStateMultiple) GetCollection() string { + if x != nil { + return x.Collection + } + return "" +} + +// GetStateMultipleResult is result of executing the GetStateMiltiple request +type GetStateMultipleResult struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Values [][]byte `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"` +} + +func (x *GetStateMultipleResult) Reset() { + *x = GetStateMultipleResult{} + if protoimpl.UnsafeEnabled { + mi := &file_peer_chaincode_shim_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetStateMultipleResult) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetStateMultipleResult) ProtoMessage() {} + +func (x *GetStateMultipleResult) ProtoReflect() protoreflect.Message { + mi := &file_peer_chaincode_shim_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 GetStateMultipleResult.ProtoReflect.Descriptor instead. +func (*GetStateMultipleResult) Descriptor() ([]byte, []int) { + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{4} +} + +func (x *GetStateMultipleResult) GetValues() [][]byte { + if x != nil { + return x.Values + } + return nil +} + // PutState is the payload of a ChaincodeMessage. It contains a key and value // which needs to be written to the transaction's write set. If the collection is // specified, the key and value would be written to the transaction's private @@ -363,7 +531,7 @@ type PutState struct { func (x *PutState) Reset() { *x = PutState{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[3] + mi := &file_peer_chaincode_shim_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -376,7 +544,7 @@ func (x *PutState) String() string { func (*PutState) ProtoMessage() {} func (x *PutState) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[3] + mi := &file_peer_chaincode_shim_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -389,7 +557,7 @@ func (x *PutState) ProtoReflect() protoreflect.Message { // Deprecated: Use PutState.ProtoReflect.Descriptor instead. func (*PutState) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{3} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{5} } func (x *PutState) GetKey() string { @@ -426,7 +594,7 @@ type PutStateMetadata struct { func (x *PutStateMetadata) Reset() { *x = PutStateMetadata{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[4] + mi := &file_peer_chaincode_shim_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -439,7 +607,7 @@ func (x *PutStateMetadata) String() string { func (*PutStateMetadata) ProtoMessage() {} func (x *PutStateMetadata) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[4] + mi := &file_peer_chaincode_shim_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -452,7 +620,7 @@ func (x *PutStateMetadata) ProtoReflect() protoreflect.Message { // Deprecated: Use PutStateMetadata.ProtoReflect.Descriptor instead. func (*PutStateMetadata) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{4} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{6} } func (x *PutStateMetadata) GetKey() string { @@ -476,6 +644,135 @@ func (x *PutStateMetadata) GetMetadata() *StateMetadata { return nil } +// WriteBatchState - set of records for state changes sent by the batch +type WriteBatchState struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Rec []*WriteRecord `protobuf:"bytes,1,rep,name=rec,proto3" json:"rec,omitempty"` +} + +func (x *WriteBatchState) Reset() { + *x = WriteBatchState{} + if protoimpl.UnsafeEnabled { + mi := &file_peer_chaincode_shim_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WriteBatchState) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WriteBatchState) ProtoMessage() {} + +func (x *WriteBatchState) ProtoReflect() protoreflect.Message { + mi := &file_peer_chaincode_shim_proto_msgTypes[7] + 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 WriteBatchState.ProtoReflect.Descriptor instead. +func (*WriteBatchState) Descriptor() ([]byte, []int) { + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{7} +} + +func (x *WriteBatchState) GetRec() []*WriteRecord { + if x != nil { + return x.Rec + } + return nil +} + +// WriteRecord - single record with changes in the state of different types. +// Filled in depending on the type. +type WriteRecord struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` + Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` + Collection string `protobuf:"bytes,3,opt,name=collection,proto3" json:"collection,omitempty"` + Metadata *StateMetadata `protobuf:"bytes,4,opt,name=metadata,proto3" json:"metadata,omitempty"` + Type WriteRecord_Type `protobuf:"varint,5,opt,name=type,proto3,enum=protos.WriteRecord_Type" json:"type,omitempty"` +} + +func (x *WriteRecord) Reset() { + *x = WriteRecord{} + if protoimpl.UnsafeEnabled { + mi := &file_peer_chaincode_shim_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WriteRecord) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WriteRecord) ProtoMessage() {} + +func (x *WriteRecord) ProtoReflect() protoreflect.Message { + mi := &file_peer_chaincode_shim_proto_msgTypes[8] + 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 WriteRecord.ProtoReflect.Descriptor instead. +func (*WriteRecord) Descriptor() ([]byte, []int) { + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{8} +} + +func (x *WriteRecord) GetKey() string { + if x != nil { + return x.Key + } + return "" +} + +func (x *WriteRecord) GetValue() []byte { + if x != nil { + return x.Value + } + return nil +} + +func (x *WriteRecord) GetCollection() string { + if x != nil { + return x.Collection + } + return "" +} + +func (x *WriteRecord) GetMetadata() *StateMetadata { + if x != nil { + return x.Metadata + } + return nil +} + +func (x *WriteRecord) GetType() WriteRecord_Type { + if x != nil { + return x.Type + } + return WriteRecord_UNDEFINED +} + // DelState is the payload of a ChaincodeMessage. It contains a key which // needs to be recorded in the transaction's write set as a delete operation. // If the collection is specified, the key needs to be recorded in the @@ -492,7 +789,7 @@ type DelState struct { func (x *DelState) Reset() { *x = DelState{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[5] + mi := &file_peer_chaincode_shim_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -505,7 +802,7 @@ func (x *DelState) String() string { func (*DelState) ProtoMessage() {} func (x *DelState) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[5] + mi := &file_peer_chaincode_shim_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -518,7 +815,7 @@ func (x *DelState) ProtoReflect() protoreflect.Message { // Deprecated: Use DelState.ProtoReflect.Descriptor instead. func (*DelState) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{5} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{9} } func (x *DelState) GetKey() string { @@ -547,7 +844,7 @@ type PurgePrivateState struct { func (x *PurgePrivateState) Reset() { *x = PurgePrivateState{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[6] + mi := &file_peer_chaincode_shim_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -560,7 +857,7 @@ func (x *PurgePrivateState) String() string { func (*PurgePrivateState) ProtoMessage() {} func (x *PurgePrivateState) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[6] + mi := &file_peer_chaincode_shim_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -573,7 +870,7 @@ func (x *PurgePrivateState) ProtoReflect() protoreflect.Message { // Deprecated: Use PurgePrivateState.ProtoReflect.Descriptor instead. func (*PurgePrivateState) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{6} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{10} } func (x *PurgePrivateState) GetKey() string { @@ -608,7 +905,7 @@ type GetStateByRange struct { func (x *GetStateByRange) Reset() { *x = GetStateByRange{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[7] + mi := &file_peer_chaincode_shim_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -621,7 +918,7 @@ func (x *GetStateByRange) String() string { func (*GetStateByRange) ProtoMessage() {} func (x *GetStateByRange) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[7] + mi := &file_peer_chaincode_shim_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -634,7 +931,7 @@ func (x *GetStateByRange) ProtoReflect() protoreflect.Message { // Deprecated: Use GetStateByRange.ProtoReflect.Descriptor instead. func (*GetStateByRange) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{7} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{11} } func (x *GetStateByRange) GetStartKey() string { @@ -682,7 +979,7 @@ type GetQueryResult struct { func (x *GetQueryResult) Reset() { *x = GetQueryResult{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[8] + mi := &file_peer_chaincode_shim_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -695,7 +992,7 @@ func (x *GetQueryResult) String() string { func (*GetQueryResult) ProtoMessage() {} func (x *GetQueryResult) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[8] + mi := &file_peer_chaincode_shim_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -708,7 +1005,7 @@ func (x *GetQueryResult) ProtoReflect() protoreflect.Message { // Deprecated: Use GetQueryResult.ProtoReflect.Descriptor instead. func (*GetQueryResult) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{8} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{12} } func (x *GetQueryResult) GetQuery() string { @@ -747,7 +1044,7 @@ type QueryMetadata struct { func (x *QueryMetadata) Reset() { *x = QueryMetadata{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[9] + mi := &file_peer_chaincode_shim_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -760,7 +1057,7 @@ func (x *QueryMetadata) String() string { func (*QueryMetadata) ProtoMessage() {} func (x *QueryMetadata) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[9] + mi := &file_peer_chaincode_shim_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -773,7 +1070,7 @@ func (x *QueryMetadata) ProtoReflect() protoreflect.Message { // Deprecated: Use QueryMetadata.ProtoReflect.Descriptor instead. func (*QueryMetadata) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{9} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{13} } func (x *QueryMetadata) GetPageSize() int32 { @@ -803,7 +1100,7 @@ type GetHistoryForKey struct { func (x *GetHistoryForKey) Reset() { *x = GetHistoryForKey{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[10] + mi := &file_peer_chaincode_shim_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -816,7 +1113,7 @@ func (x *GetHistoryForKey) String() string { func (*GetHistoryForKey) ProtoMessage() {} func (x *GetHistoryForKey) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[10] + mi := &file_peer_chaincode_shim_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -829,7 +1126,7 @@ func (x *GetHistoryForKey) ProtoReflect() protoreflect.Message { // Deprecated: Use GetHistoryForKey.ProtoReflect.Descriptor instead. func (*GetHistoryForKey) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{10} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{14} } func (x *GetHistoryForKey) GetKey() string { @@ -850,7 +1147,7 @@ type QueryStateNext struct { func (x *QueryStateNext) Reset() { *x = QueryStateNext{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[11] + mi := &file_peer_chaincode_shim_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -863,7 +1160,7 @@ func (x *QueryStateNext) String() string { func (*QueryStateNext) ProtoMessage() {} func (x *QueryStateNext) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[11] + mi := &file_peer_chaincode_shim_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -876,7 +1173,7 @@ func (x *QueryStateNext) ProtoReflect() protoreflect.Message { // Deprecated: Use QueryStateNext.ProtoReflect.Descriptor instead. func (*QueryStateNext) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{11} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{15} } func (x *QueryStateNext) GetId() string { @@ -897,7 +1194,7 @@ type QueryStateClose struct { func (x *QueryStateClose) Reset() { *x = QueryStateClose{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[12] + mi := &file_peer_chaincode_shim_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -910,7 +1207,7 @@ func (x *QueryStateClose) String() string { func (*QueryStateClose) ProtoMessage() {} func (x *QueryStateClose) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[12] + mi := &file_peer_chaincode_shim_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -923,7 +1220,7 @@ func (x *QueryStateClose) ProtoReflect() protoreflect.Message { // Deprecated: Use QueryStateClose.ProtoReflect.Descriptor instead. func (*QueryStateClose) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{12} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{16} } func (x *QueryStateClose) GetId() string { @@ -945,7 +1242,7 @@ type QueryResultBytes struct { func (x *QueryResultBytes) Reset() { *x = QueryResultBytes{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[13] + mi := &file_peer_chaincode_shim_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -958,7 +1255,7 @@ func (x *QueryResultBytes) String() string { func (*QueryResultBytes) ProtoMessage() {} func (x *QueryResultBytes) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[13] + mi := &file_peer_chaincode_shim_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -971,7 +1268,7 @@ func (x *QueryResultBytes) ProtoReflect() protoreflect.Message { // Deprecated: Use QueryResultBytes.ProtoReflect.Descriptor instead. func (*QueryResultBytes) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{13} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{17} } func (x *QueryResultBytes) GetResultBytes() []byte { @@ -1000,7 +1297,7 @@ type QueryResponse struct { func (x *QueryResponse) Reset() { *x = QueryResponse{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[14] + mi := &file_peer_chaincode_shim_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1013,7 +1310,7 @@ func (x *QueryResponse) String() string { func (*QueryResponse) ProtoMessage() {} func (x *QueryResponse) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[14] + mi := &file_peer_chaincode_shim_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1026,7 +1323,7 @@ func (x *QueryResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use QueryResponse.ProtoReflect.Descriptor instead. func (*QueryResponse) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{14} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{18} } func (x *QueryResponse) GetResults() []*QueryResultBytes { @@ -1071,7 +1368,7 @@ type QueryResponseMetadata struct { func (x *QueryResponseMetadata) Reset() { *x = QueryResponseMetadata{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[15] + mi := &file_peer_chaincode_shim_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1084,7 +1381,7 @@ func (x *QueryResponseMetadata) String() string { func (*QueryResponseMetadata) ProtoMessage() {} func (x *QueryResponseMetadata) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[15] + mi := &file_peer_chaincode_shim_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1097,7 +1394,7 @@ func (x *QueryResponseMetadata) ProtoReflect() protoreflect.Message { // Deprecated: Use QueryResponseMetadata.ProtoReflect.Descriptor instead. func (*QueryResponseMetadata) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{15} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{19} } func (x *QueryResponseMetadata) GetFetchedRecordsCount() int32 { @@ -1126,7 +1423,7 @@ type StateMetadata struct { func (x *StateMetadata) Reset() { *x = StateMetadata{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[16] + mi := &file_peer_chaincode_shim_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1139,7 +1436,7 @@ func (x *StateMetadata) String() string { func (*StateMetadata) ProtoMessage() {} func (x *StateMetadata) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[16] + mi := &file_peer_chaincode_shim_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1152,7 +1449,7 @@ func (x *StateMetadata) ProtoReflect() protoreflect.Message { // Deprecated: Use StateMetadata.ProtoReflect.Descriptor instead. func (*StateMetadata) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{16} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{20} } func (x *StateMetadata) GetMetakey() string { @@ -1180,7 +1477,7 @@ type StateMetadataResult struct { func (x *StateMetadataResult) Reset() { *x = StateMetadataResult{} if protoimpl.UnsafeEnabled { - mi := &file_peer_chaincode_shim_proto_msgTypes[17] + mi := &file_peer_chaincode_shim_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1193,7 +1490,7 @@ func (x *StateMetadataResult) String() string { func (*StateMetadataResult) ProtoMessage() {} func (x *StateMetadataResult) ProtoReflect() protoreflect.Message { - mi := &file_peer_chaincode_shim_proto_msgTypes[17] + mi := &file_peer_chaincode_shim_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1206,7 +1503,7 @@ func (x *StateMetadataResult) ProtoReflect() protoreflect.Message { // Deprecated: Use StateMetadataResult.ProtoReflect.Descriptor instead. func (*StateMetadataResult) Descriptor() ([]byte, []int) { - return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{17} + return file_peer_chaincode_shim_proto_rawDescGZIP(), []int{21} } func (x *StateMetadataResult) GetEntries() []*StateMetadata { @@ -1226,7 +1523,7 @@ var file_peer_chaincode_shim_proto_rawDesc = []byte{ 0x13, 0x70, 0x65, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xee, 0x05, 0x0a, 0x10, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x9d, 0x06, 0x0a, 0x10, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x31, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, @@ -1246,7 +1543,7 @@ var file_peer_chaincode_shim_proto_rawDesc = []byte{ 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x52, 0x0e, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x5f, 0x69, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, - 0x63, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x49, 0x64, 0x22, 0xaa, 0x03, 0x0a, 0x04, 0x54, 0x79, + 0x63, 0x68, 0x61, 0x6e, 0x6e, 0x65, 0x6c, 0x49, 0x64, 0x22, 0xd9, 0x03, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0d, 0x0a, 0x09, 0x55, 0x4e, 0x44, 0x45, 0x46, 0x49, 0x4e, 0x45, 0x44, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x52, 0x45, 0x47, 0x49, 0x53, 0x54, 0x45, 0x52, 0x10, 0x01, 0x12, 0x0e, 0x0a, 0x0a, 0x52, 0x45, 0x47, 0x49, 0x53, 0x54, 0x45, 0x52, 0x45, 0x44, 0x10, 0x02, 0x12, @@ -1273,111 +1570,143 @@ var file_peer_chaincode_shim_proto_rawDesc = []byte{ 0x41, 0x10, 0x15, 0x12, 0x19, 0x0a, 0x15, 0x47, 0x45, 0x54, 0x5f, 0x50, 0x52, 0x49, 0x56, 0x41, 0x54, 0x45, 0x5f, 0x44, 0x41, 0x54, 0x41, 0x5f, 0x48, 0x41, 0x53, 0x48, 0x10, 0x16, 0x12, 0x16, 0x0a, 0x12, 0x50, 0x55, 0x52, 0x47, 0x45, 0x5f, 0x50, 0x52, 0x49, 0x56, 0x41, 0x54, 0x45, 0x5f, - 0x44, 0x41, 0x54, 0x41, 0x10, 0x17, 0x22, 0x3c, 0x0a, 0x08, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, - 0x74, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x44, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, - 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, - 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x52, 0x0a, 0x08, 0x50, 0x75, - 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, - 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x1e, - 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x77, - 0x0a, 0x10, 0x50, 0x75, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, - 0x74, 0x61, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x31, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, - 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x08, 0x6d, - 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x22, 0x3c, 0x0a, 0x08, 0x44, 0x65, 0x6c, 0x53, 0x74, - 0x61, 0x74, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, - 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x45, 0x0a, 0x11, 0x50, 0x75, 0x72, 0x67, 0x65, 0x50, 0x72, - 0x69, 0x76, 0x61, 0x74, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, - 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, - 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x81, 0x01, 0x0a, - 0x0f, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x42, 0x79, 0x52, 0x61, 0x6e, 0x67, 0x65, - 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x4b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x4b, 0x65, 0x79, 0x12, 0x16, 0x0a, 0x06, - 0x65, 0x6e, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x65, 0x6e, - 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0x22, 0x62, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x73, 0x75, - 0x6c, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, - 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, - 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, - 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, - 0x64, 0x61, 0x74, 0x61, 0x22, 0x47, 0x0a, 0x0d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, 0x65, 0x74, - 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, - 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x6f, 0x6f, 0x6b, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x6f, 0x6f, 0x6b, 0x6d, 0x61, 0x72, 0x6b, 0x22, 0x24, 0x0a, - 0x10, 0x47, 0x65, 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x46, 0x6f, 0x72, 0x4b, 0x65, - 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, - 0x6b, 0x65, 0x79, 0x22, 0x20, 0x0a, 0x0e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x74, 0x61, 0x74, - 0x65, 0x4e, 0x65, 0x78, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x21, 0x0a, 0x0f, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x74, - 0x61, 0x74, 0x65, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x34, 0x0a, 0x10, 0x51, 0x75, 0x65, 0x72, - 0x79, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x20, 0x0a, 0x0b, - 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x42, 0x79, 0x74, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x0b, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x42, 0x79, 0x74, 0x65, 0x73, 0x22, 0x8a, - 0x01, 0x0a, 0x0d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x32, 0x0a, 0x07, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, - 0x0b, 0x32, 0x18, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, - 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x42, 0x79, 0x74, 0x65, 0x73, 0x52, 0x07, 0x72, 0x65, 0x73, - 0x75, 0x6c, 0x74, 0x73, 0x12, 0x19, 0x0a, 0x08, 0x68, 0x61, 0x73, 0x5f, 0x6d, 0x6f, 0x72, 0x65, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x68, 0x61, 0x73, 0x4d, 0x6f, 0x72, 0x65, 0x12, - 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, - 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x22, 0x67, 0x0a, 0x15, 0x51, - 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4d, 0x65, 0x74, 0x61, - 0x64, 0x61, 0x74, 0x61, 0x12, 0x32, 0x0a, 0x15, 0x66, 0x65, 0x74, 0x63, 0x68, 0x65, 0x64, 0x5f, - 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x73, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x13, 0x66, 0x65, 0x74, 0x63, 0x68, 0x65, 0x64, 0x52, 0x65, 0x63, 0x6f, - 0x72, 0x64, 0x73, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x6f, 0x6f, 0x6b, - 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x6f, 0x6f, 0x6b, - 0x6d, 0x61, 0x72, 0x6b, 0x22, 0x3f, 0x0a, 0x0d, 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, 0x65, 0x74, - 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x74, 0x61, 0x6b, 0x65, 0x79, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x74, 0x61, 0x6b, 0x65, 0x79, 0x12, - 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, - 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x46, 0x0a, 0x13, 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, 0x65, - 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x2f, 0x0a, 0x07, - 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x15, 0x2e, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, 0x65, 0x74, 0x61, - 0x64, 0x61, 0x74, 0x61, 0x52, 0x07, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x32, 0x56, 0x0a, - 0x10, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x53, 0x75, 0x70, 0x70, 0x6f, 0x72, - 0x74, 0x12, 0x42, 0x0a, 0x08, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x12, 0x18, 0x2e, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, - 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, 0x18, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, - 0x2e, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, - 0x65, 0x28, 0x01, 0x30, 0x01, 0x32, 0x4e, 0x0a, 0x09, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, - 0x64, 0x65, 0x12, 0x41, 0x0a, 0x07, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x12, 0x18, 0x2e, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, - 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, 0x18, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, - 0x2e, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, - 0x65, 0x28, 0x01, 0x30, 0x01, 0x42, 0xa4, 0x01, 0x0a, 0x22, 0x6f, 0x72, 0x67, 0x2e, 0x68, 0x79, - 0x70, 0x65, 0x72, 0x6c, 0x65, 0x64, 0x67, 0x65, 0x72, 0x2e, 0x66, 0x61, 0x62, 0x72, 0x69, 0x63, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x70, 0x65, 0x65, 0x72, 0x42, 0x12, 0x43, 0x68, - 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x53, 0x68, 0x69, 0x6d, 0x50, 0x72, 0x6f, 0x74, 0x6f, - 0x50, 0x01, 0x5a, 0x32, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x68, - 0x79, 0x70, 0x65, 0x72, 0x6c, 0x65, 0x64, 0x67, 0x65, 0x72, 0x2f, 0x66, 0x61, 0x62, 0x72, 0x69, - 0x63, 0x2d, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2d, 0x67, 0x6f, 0x2d, 0x61, 0x70, 0x69, 0x76, - 0x32, 0x2f, 0x70, 0x65, 0x65, 0x72, 0xa2, 0x02, 0x03, 0x50, 0x58, 0x58, 0xaa, 0x02, 0x06, 0x50, - 0x72, 0x6f, 0x74, 0x6f, 0x73, 0xca, 0x02, 0x06, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0xe2, 0x02, - 0x12, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, - 0x61, 0x74, 0x61, 0xea, 0x02, 0x06, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x62, 0x06, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x33, + 0x44, 0x41, 0x54, 0x41, 0x10, 0x17, 0x12, 0x15, 0x0a, 0x11, 0x57, 0x52, 0x49, 0x54, 0x45, 0x5f, + 0x42, 0x41, 0x54, 0x43, 0x48, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x45, 0x10, 0x18, 0x12, 0x16, 0x0a, + 0x12, 0x47, 0x45, 0x54, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x45, 0x5f, 0x4d, 0x55, 0x4c, 0x54, 0x49, + 0x50, 0x4c, 0x45, 0x10, 0x19, 0x22, 0x3c, 0x0a, 0x08, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, + 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, + 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, + 0x69, 0x6f, 0x6e, 0x22, 0x44, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, + 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, + 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x46, 0x0a, 0x10, 0x47, 0x65, 0x74, + 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x65, 0x12, 0x12, 0x0a, + 0x04, 0x6b, 0x65, 0x79, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x04, 0x6b, 0x65, 0x79, + 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, + 0x6e, 0x22, 0x30, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, 0x75, 0x6c, + 0x74, 0x69, 0x70, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x76, + 0x61, 0x6c, 0x75, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0c, 0x52, 0x06, 0x76, 0x61, 0x6c, + 0x75, 0x65, 0x73, 0x22, 0x52, 0x0a, 0x08, 0x50, 0x75, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, + 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, + 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, + 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, + 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x77, 0x0a, 0x10, 0x50, 0x75, 0x74, 0x53, 0x74, + 0x61, 0x74, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x10, 0x0a, 0x03, 0x6b, + 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, + 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x31, 0x0a, + 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x15, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0x22, 0x38, 0x0a, 0x0f, 0x57, 0x72, 0x69, 0x74, 0x65, 0x42, 0x61, 0x74, 0x63, 0x68, 0x53, 0x74, + 0x61, 0x74, 0x65, 0x12, 0x25, 0x0a, 0x03, 0x72, 0x65, 0x63, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x13, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x57, 0x72, 0x69, 0x74, 0x65, 0x52, + 0x65, 0x63, 0x6f, 0x72, 0x64, 0x52, 0x03, 0x72, 0x65, 0x63, 0x22, 0x9b, 0x02, 0x0a, 0x0b, 0x57, + 0x72, 0x69, 0x74, 0x65, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, + 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, + 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x76, 0x61, 0x6c, + 0x75, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, + 0x6f, 0x6e, 0x12, 0x31, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x74, + 0x61, 0x74, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x08, 0x6d, 0x65, 0x74, + 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x2c, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x57, 0x72, 0x69, + 0x74, 0x65, 0x52, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, + 0x79, 0x70, 0x65, 0x22, 0x63, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0d, 0x0a, 0x09, 0x55, + 0x4e, 0x44, 0x45, 0x46, 0x49, 0x4e, 0x45, 0x44, 0x10, 0x00, 0x12, 0x0d, 0x0a, 0x09, 0x50, 0x55, + 0x54, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x45, 0x10, 0x09, 0x12, 0x0d, 0x0a, 0x09, 0x44, 0x45, 0x4c, + 0x5f, 0x53, 0x54, 0x41, 0x54, 0x45, 0x10, 0x0a, 0x12, 0x16, 0x0a, 0x12, 0x50, 0x55, 0x54, 0x5f, + 0x53, 0x54, 0x41, 0x54, 0x45, 0x5f, 0x4d, 0x45, 0x54, 0x41, 0x44, 0x41, 0x54, 0x41, 0x10, 0x15, + 0x12, 0x16, 0x0a, 0x12, 0x50, 0x55, 0x52, 0x47, 0x45, 0x5f, 0x50, 0x52, 0x49, 0x56, 0x41, 0x54, + 0x45, 0x5f, 0x44, 0x41, 0x54, 0x41, 0x10, 0x17, 0x22, 0x3c, 0x0a, 0x08, 0x44, 0x65, 0x6c, 0x53, + 0x74, 0x61, 0x74, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, + 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, + 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x45, 0x0a, 0x11, 0x50, 0x75, 0x72, 0x67, 0x65, 0x50, + 0x72, 0x69, 0x76, 0x61, 0x74, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6b, + 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, + 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x81, 0x01, + 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x42, 0x79, 0x52, 0x61, 0x6e, 0x67, + 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x4b, 0x65, 0x79, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x4b, 0x65, 0x79, 0x12, 0x16, 0x0a, + 0x06, 0x65, 0x6e, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x65, + 0x6e, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, + 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, + 0x61, 0x22, 0x62, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x73, + 0x75, 0x6c, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x6f, 0x6c, + 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, + 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, + 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08, 0x6d, 0x65, 0x74, + 0x61, 0x64, 0x61, 0x74, 0x61, 0x22, 0x47, 0x0a, 0x0d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, + 0x7a, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, + 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x6f, 0x6f, 0x6b, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x6f, 0x6f, 0x6b, 0x6d, 0x61, 0x72, 0x6b, 0x22, 0x24, + 0x0a, 0x10, 0x47, 0x65, 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x46, 0x6f, 0x72, 0x4b, + 0x65, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x03, 0x6b, 0x65, 0x79, 0x22, 0x20, 0x0a, 0x0e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x74, 0x61, + 0x74, 0x65, 0x4e, 0x65, 0x78, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x21, 0x0a, 0x0f, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, + 0x74, 0x61, 0x74, 0x65, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x34, 0x0a, 0x10, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x20, 0x0a, + 0x0b, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x42, 0x79, 0x74, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x0c, 0x52, 0x0b, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x42, 0x79, 0x74, 0x65, 0x73, 0x22, + 0x8a, 0x01, 0x0a, 0x0d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x32, 0x0a, 0x07, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x42, 0x79, 0x74, 0x65, 0x73, 0x52, 0x07, 0x72, 0x65, + 0x73, 0x75, 0x6c, 0x74, 0x73, 0x12, 0x19, 0x0a, 0x08, 0x68, 0x61, 0x73, 0x5f, 0x6d, 0x6f, 0x72, + 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x68, 0x61, 0x73, 0x4d, 0x6f, 0x72, 0x65, + 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, + 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x0c, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x22, 0x67, 0x0a, 0x15, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x32, 0x0a, 0x15, 0x66, 0x65, 0x74, 0x63, 0x68, 0x65, 0x64, + 0x5f, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x73, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x13, 0x66, 0x65, 0x74, 0x63, 0x68, 0x65, 0x64, 0x52, 0x65, 0x63, + 0x6f, 0x72, 0x64, 0x73, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x6f, 0x6f, + 0x6b, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x6f, 0x6f, + 0x6b, 0x6d, 0x61, 0x72, 0x6b, 0x22, 0x3f, 0x0a, 0x0d, 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x74, 0x61, 0x6b, 0x65, + 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x74, 0x61, 0x6b, 0x65, 0x79, + 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, + 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x46, 0x0a, 0x13, 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, + 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x2f, 0x0a, + 0x07, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x15, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x4d, 0x65, 0x74, + 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x07, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x32, 0x56, + 0x0a, 0x10, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x53, 0x75, 0x70, 0x70, 0x6f, + 0x72, 0x74, 0x12, 0x42, 0x0a, 0x08, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x12, 0x18, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, + 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, 0x18, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x73, 0x2e, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, + 0x67, 0x65, 0x28, 0x01, 0x30, 0x01, 0x32, 0x4e, 0x0a, 0x09, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, + 0x6f, 0x64, 0x65, 0x12, 0x41, 0x0a, 0x07, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x12, 0x18, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, + 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, 0x18, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x73, 0x2e, 0x43, 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, + 0x67, 0x65, 0x28, 0x01, 0x30, 0x01, 0x42, 0xa4, 0x01, 0x0a, 0x22, 0x6f, 0x72, 0x67, 0x2e, 0x68, + 0x79, 0x70, 0x65, 0x72, 0x6c, 0x65, 0x64, 0x67, 0x65, 0x72, 0x2e, 0x66, 0x61, 0x62, 0x72, 0x69, + 0x63, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2e, 0x70, 0x65, 0x65, 0x72, 0x42, 0x12, 0x43, + 0x68, 0x61, 0x69, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x53, 0x68, 0x69, 0x6d, 0x50, 0x72, 0x6f, 0x74, + 0x6f, 0x50, 0x01, 0x5a, 0x32, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, + 0x68, 0x79, 0x70, 0x65, 0x72, 0x6c, 0x65, 0x64, 0x67, 0x65, 0x72, 0x2f, 0x66, 0x61, 0x62, 0x72, + 0x69, 0x63, 0x2d, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2d, 0x67, 0x6f, 0x2d, 0x61, 0x70, 0x69, + 0x76, 0x32, 0x2f, 0x70, 0x65, 0x65, 0x72, 0xa2, 0x02, 0x03, 0x50, 0x58, 0x58, 0xaa, 0x02, 0x06, + 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0xca, 0x02, 0x06, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0xe2, + 0x02, 0x12, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, + 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x06, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -1392,49 +1721,57 @@ func file_peer_chaincode_shim_proto_rawDescGZIP() []byte { return file_peer_chaincode_shim_proto_rawDescData } -var file_peer_chaincode_shim_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_peer_chaincode_shim_proto_msgTypes = make([]protoimpl.MessageInfo, 18) -var file_peer_chaincode_shim_proto_goTypes = []interface{}{ - (ChaincodeMessage_Type)(0), // 0: protos.ChaincodeMessage.Type - (*ChaincodeMessage)(nil), // 1: protos.ChaincodeMessage - (*GetState)(nil), // 2: protos.GetState - (*GetStateMetadata)(nil), // 3: protos.GetStateMetadata - (*PutState)(nil), // 4: protos.PutState - (*PutStateMetadata)(nil), // 5: protos.PutStateMetadata - (*DelState)(nil), // 6: protos.DelState - (*PurgePrivateState)(nil), // 7: protos.PurgePrivateState - (*GetStateByRange)(nil), // 8: protos.GetStateByRange - (*GetQueryResult)(nil), // 9: protos.GetQueryResult - (*QueryMetadata)(nil), // 10: protos.QueryMetadata - (*GetHistoryForKey)(nil), // 11: protos.GetHistoryForKey - (*QueryStateNext)(nil), // 12: protos.QueryStateNext - (*QueryStateClose)(nil), // 13: protos.QueryStateClose - (*QueryResultBytes)(nil), // 14: protos.QueryResultBytes - (*QueryResponse)(nil), // 15: protos.QueryResponse - (*QueryResponseMetadata)(nil), // 16: protos.QueryResponseMetadata - (*StateMetadata)(nil), // 17: protos.StateMetadata - (*StateMetadataResult)(nil), // 18: protos.StateMetadataResult - (*timestamppb.Timestamp)(nil), // 19: google.protobuf.Timestamp - (*SignedProposal)(nil), // 20: protos.SignedProposal - (*ChaincodeEvent)(nil), // 21: protos.ChaincodeEvent +var file_peer_chaincode_shim_proto_enumTypes = make([]protoimpl.EnumInfo, 2) +var file_peer_chaincode_shim_proto_msgTypes = make([]protoimpl.MessageInfo, 22) +var file_peer_chaincode_shim_proto_goTypes = []any{ + (ChaincodeMessage_Type)(0), // 0: protos.ChaincodeMessage.Type + (WriteRecord_Type)(0), // 1: protos.WriteRecord.Type + (*ChaincodeMessage)(nil), // 2: protos.ChaincodeMessage + (*GetState)(nil), // 3: protos.GetState + (*GetStateMetadata)(nil), // 4: protos.GetStateMetadata + (*GetStateMultiple)(nil), // 5: protos.GetStateMultiple + (*GetStateMultipleResult)(nil), // 6: protos.GetStateMultipleResult + (*PutState)(nil), // 7: protos.PutState + (*PutStateMetadata)(nil), // 8: protos.PutStateMetadata + (*WriteBatchState)(nil), // 9: protos.WriteBatchState + (*WriteRecord)(nil), // 10: protos.WriteRecord + (*DelState)(nil), // 11: protos.DelState + (*PurgePrivateState)(nil), // 12: protos.PurgePrivateState + (*GetStateByRange)(nil), // 13: protos.GetStateByRange + (*GetQueryResult)(nil), // 14: protos.GetQueryResult + (*QueryMetadata)(nil), // 15: protos.QueryMetadata + (*GetHistoryForKey)(nil), // 16: protos.GetHistoryForKey + (*QueryStateNext)(nil), // 17: protos.QueryStateNext + (*QueryStateClose)(nil), // 18: protos.QueryStateClose + (*QueryResultBytes)(nil), // 19: protos.QueryResultBytes + (*QueryResponse)(nil), // 20: protos.QueryResponse + (*QueryResponseMetadata)(nil), // 21: protos.QueryResponseMetadata + (*StateMetadata)(nil), // 22: protos.StateMetadata + (*StateMetadataResult)(nil), // 23: protos.StateMetadataResult + (*timestamppb.Timestamp)(nil), // 24: google.protobuf.Timestamp + (*SignedProposal)(nil), // 25: protos.SignedProposal + (*ChaincodeEvent)(nil), // 26: protos.ChaincodeEvent } var file_peer_chaincode_shim_proto_depIdxs = []int32{ 0, // 0: protos.ChaincodeMessage.type:type_name -> protos.ChaincodeMessage.Type - 19, // 1: protos.ChaincodeMessage.timestamp:type_name -> google.protobuf.Timestamp - 20, // 2: protos.ChaincodeMessage.proposal:type_name -> protos.SignedProposal - 21, // 3: protos.ChaincodeMessage.chaincode_event:type_name -> protos.ChaincodeEvent - 17, // 4: protos.PutStateMetadata.metadata:type_name -> protos.StateMetadata - 14, // 5: protos.QueryResponse.results:type_name -> protos.QueryResultBytes - 17, // 6: protos.StateMetadataResult.entries:type_name -> protos.StateMetadata - 1, // 7: protos.ChaincodeSupport.Register:input_type -> protos.ChaincodeMessage - 1, // 8: protos.Chaincode.Connect:input_type -> protos.ChaincodeMessage - 1, // 9: protos.ChaincodeSupport.Register:output_type -> protos.ChaincodeMessage - 1, // 10: protos.Chaincode.Connect:output_type -> protos.ChaincodeMessage - 9, // [9:11] is the sub-list for method output_type - 7, // [7:9] is the sub-list for method input_type - 7, // [7:7] is the sub-list for extension type_name - 7, // [7:7] is the sub-list for extension extendee - 0, // [0:7] is the sub-list for field type_name + 24, // 1: protos.ChaincodeMessage.timestamp:type_name -> google.protobuf.Timestamp + 25, // 2: protos.ChaincodeMessage.proposal:type_name -> protos.SignedProposal + 26, // 3: protos.ChaincodeMessage.chaincode_event:type_name -> protos.ChaincodeEvent + 22, // 4: protos.PutStateMetadata.metadata:type_name -> protos.StateMetadata + 10, // 5: protos.WriteBatchState.rec:type_name -> protos.WriteRecord + 22, // 6: protos.WriteRecord.metadata:type_name -> protos.StateMetadata + 1, // 7: protos.WriteRecord.type:type_name -> protos.WriteRecord.Type + 19, // 8: protos.QueryResponse.results:type_name -> protos.QueryResultBytes + 22, // 9: protos.StateMetadataResult.entries:type_name -> protos.StateMetadata + 2, // 10: protos.ChaincodeSupport.Register:input_type -> protos.ChaincodeMessage + 2, // 11: protos.Chaincode.Connect:input_type -> protos.ChaincodeMessage + 2, // 12: protos.ChaincodeSupport.Register:output_type -> protos.ChaincodeMessage + 2, // 13: protos.Chaincode.Connect:output_type -> protos.ChaincodeMessage + 12, // [12:14] is the sub-list for method output_type + 10, // [10:12] is the sub-list for method input_type + 10, // [10:10] is the sub-list for extension type_name + 10, // [10:10] is the sub-list for extension extendee + 0, // [0:10] is the sub-list for field type_name } func init() { file_peer_chaincode_shim_proto_init() } @@ -1445,7 +1782,7 @@ func file_peer_chaincode_shim_proto_init() { file_peer_chaincode_event_proto_init() file_peer_proposal_proto_init() if !protoimpl.UnsafeEnabled { - file_peer_chaincode_shim_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeMessage); i { case 0: return &v.state @@ -1457,7 +1794,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*GetState); i { case 0: return &v.state @@ -1469,7 +1806,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*GetStateMetadata); i { case 0: return &v.state @@ -1481,7 +1818,31 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[3].Exporter = func(v any, i int) any { + switch v := v.(*GetStateMultiple); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_peer_chaincode_shim_proto_msgTypes[4].Exporter = func(v any, i int) any { + switch v := v.(*GetStateMultipleResult); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_peer_chaincode_shim_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*PutState); i { case 0: return &v.state @@ -1493,7 +1854,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[6].Exporter = func(v any, i int) any { switch v := v.(*PutStateMetadata); i { case 0: return &v.state @@ -1505,7 +1866,31 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[7].Exporter = func(v any, i int) any { + switch v := v.(*WriteBatchState); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_peer_chaincode_shim_proto_msgTypes[8].Exporter = func(v any, i int) any { + switch v := v.(*WriteRecord); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_peer_chaincode_shim_proto_msgTypes[9].Exporter = func(v any, i int) any { switch v := v.(*DelState); i { case 0: return &v.state @@ -1517,7 +1902,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[10].Exporter = func(v any, i int) any { switch v := v.(*PurgePrivateState); i { case 0: return &v.state @@ -1529,7 +1914,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[11].Exporter = func(v any, i int) any { switch v := v.(*GetStateByRange); i { case 0: return &v.state @@ -1541,7 +1926,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[12].Exporter = func(v any, i int) any { switch v := v.(*GetQueryResult); i { case 0: return &v.state @@ -1553,7 +1938,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[13].Exporter = func(v any, i int) any { switch v := v.(*QueryMetadata); i { case 0: return &v.state @@ -1565,7 +1950,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[14].Exporter = func(v any, i int) any { switch v := v.(*GetHistoryForKey); i { case 0: return &v.state @@ -1577,7 +1962,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[15].Exporter = func(v any, i int) any { switch v := v.(*QueryStateNext); i { case 0: return &v.state @@ -1589,7 +1974,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[16].Exporter = func(v any, i int) any { switch v := v.(*QueryStateClose); i { case 0: return &v.state @@ -1601,7 +1986,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[17].Exporter = func(v any, i int) any { switch v := v.(*QueryResultBytes); i { case 0: return &v.state @@ -1613,7 +1998,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[18].Exporter = func(v any, i int) any { switch v := v.(*QueryResponse); i { case 0: return &v.state @@ -1625,7 +2010,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[19].Exporter = func(v any, i int) any { switch v := v.(*QueryResponseMetadata); i { case 0: return &v.state @@ -1637,7 +2022,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[20].Exporter = func(v any, i int) any { switch v := v.(*StateMetadata); i { case 0: return &v.state @@ -1649,7 +2034,7 @@ func file_peer_chaincode_shim_proto_init() { return nil } } - file_peer_chaincode_shim_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { + file_peer_chaincode_shim_proto_msgTypes[21].Exporter = func(v any, i int) any { switch v := v.(*StateMetadataResult); i { case 0: return &v.state @@ -1667,8 +2052,8 @@ func file_peer_chaincode_shim_proto_init() { File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_peer_chaincode_shim_proto_rawDesc, - NumEnums: 1, - NumMessages: 18, + NumEnums: 2, + NumMessages: 22, NumExtensions: 0, NumServices: 2, }, diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_shim_grpc.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_shim_grpc.pb.go index c7baf050..01b08061 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_shim_grpc.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/chaincode_shim_grpc.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: -// - protoc-gen-go-grpc v1.3.0 +// - protoc-gen-go-grpc v1.5.1 // - protoc (unknown) // source: peer/chaincode_shim.proto @@ -19,8 +19,8 @@ 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 +// Requires gRPC-Go v1.64.0 or later. +const _ = grpc.SupportPackageIsVersion9 const ( ChaincodeSupport_Register_FullMethodName = "/protos.ChaincodeSupport/Register" @@ -29,8 +29,11 @@ const ( // ChaincodeSupportClient is the client API for ChaincodeSupport service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +// +// Interface that provides support to chaincode execution. ChaincodeContext +// provides the context necessary for the server to respond appropriately. type ChaincodeSupportClient interface { - Register(ctx context.Context, opts ...grpc.CallOption) (ChaincodeSupport_RegisterClient, error) + Register(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[ChaincodeMessage, ChaincodeMessage], error) } type chaincodeSupportClient struct { @@ -41,51 +44,40 @@ func NewChaincodeSupportClient(cc grpc.ClientConnInterface) ChaincodeSupportClie return &chaincodeSupportClient{cc} } -func (c *chaincodeSupportClient) Register(ctx context.Context, opts ...grpc.CallOption) (ChaincodeSupport_RegisterClient, error) { - stream, err := c.cc.NewStream(ctx, &ChaincodeSupport_ServiceDesc.Streams[0], ChaincodeSupport_Register_FullMethodName, opts...) +func (c *chaincodeSupportClient) Register(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[ChaincodeMessage, ChaincodeMessage], error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) + stream, err := c.cc.NewStream(ctx, &ChaincodeSupport_ServiceDesc.Streams[0], ChaincodeSupport_Register_FullMethodName, cOpts...) if err != nil { return nil, err } - x := &chaincodeSupportRegisterClient{stream} + x := &grpc.GenericClientStream[ChaincodeMessage, ChaincodeMessage]{ClientStream: stream} return x, nil } -type ChaincodeSupport_RegisterClient interface { - Send(*ChaincodeMessage) error - Recv() (*ChaincodeMessage, error) - grpc.ClientStream -} - -type chaincodeSupportRegisterClient struct { - grpc.ClientStream -} - -func (x *chaincodeSupportRegisterClient) Send(m *ChaincodeMessage) error { - return x.ClientStream.SendMsg(m) -} - -func (x *chaincodeSupportRegisterClient) Recv() (*ChaincodeMessage, error) { - m := new(ChaincodeMessage) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type ChaincodeSupport_RegisterClient = grpc.BidiStreamingClient[ChaincodeMessage, ChaincodeMessage] // ChaincodeSupportServer is the server API for ChaincodeSupport service. // All implementations should embed UnimplementedChaincodeSupportServer -// for forward compatibility +// for forward compatibility. +// +// Interface that provides support to chaincode execution. ChaincodeContext +// provides the context necessary for the server to respond appropriately. type ChaincodeSupportServer interface { - Register(ChaincodeSupport_RegisterServer) error + Register(grpc.BidiStreamingServer[ChaincodeMessage, ChaincodeMessage]) error } -// UnimplementedChaincodeSupportServer should be embedded to have forward compatible implementations. -type UnimplementedChaincodeSupportServer struct { -} +// UnimplementedChaincodeSupportServer should be embedded to have +// forward compatible implementations. +// +// NOTE: this should be embedded by value instead of pointer to avoid a nil +// pointer dereference when methods are called. +type UnimplementedChaincodeSupportServer struct{} -func (UnimplementedChaincodeSupportServer) Register(ChaincodeSupport_RegisterServer) error { +func (UnimplementedChaincodeSupportServer) Register(grpc.BidiStreamingServer[ChaincodeMessage, ChaincodeMessage]) error { return status.Errorf(codes.Unimplemented, "method Register not implemented") } +func (UnimplementedChaincodeSupportServer) testEmbeddedByValue() {} // UnsafeChaincodeSupportServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to ChaincodeSupportServer will @@ -95,34 +87,22 @@ type UnsafeChaincodeSupportServer interface { } func RegisterChaincodeSupportServer(s grpc.ServiceRegistrar, srv ChaincodeSupportServer) { + // If the following call pancis, it indicates UnimplementedChaincodeSupportServer was + // embedded by pointer and is nil. This will cause panics if an + // unimplemented method is ever invoked, so we test this at initialization + // time to prevent it from happening at runtime later due to I/O. + if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { + t.testEmbeddedByValue() + } s.RegisterService(&ChaincodeSupport_ServiceDesc, srv) } func _ChaincodeSupport_Register_Handler(srv interface{}, stream grpc.ServerStream) error { - return srv.(ChaincodeSupportServer).Register(&chaincodeSupportRegisterServer{stream}) -} - -type ChaincodeSupport_RegisterServer interface { - Send(*ChaincodeMessage) error - Recv() (*ChaincodeMessage, error) - grpc.ServerStream -} - -type chaincodeSupportRegisterServer struct { - grpc.ServerStream + return srv.(ChaincodeSupportServer).Register(&grpc.GenericServerStream[ChaincodeMessage, ChaincodeMessage]{ServerStream: stream}) } -func (x *chaincodeSupportRegisterServer) Send(m *ChaincodeMessage) error { - return x.ServerStream.SendMsg(m) -} - -func (x *chaincodeSupportRegisterServer) Recv() (*ChaincodeMessage, error) { - m := new(ChaincodeMessage) - if err := x.ServerStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type ChaincodeSupport_RegisterServer = grpc.BidiStreamingServer[ChaincodeMessage, ChaincodeMessage] // ChaincodeSupport_ServiceDesc is the grpc.ServiceDesc for ChaincodeSupport service. // It's only intended for direct use with grpc.RegisterService, @@ -149,8 +129,11 @@ const ( // ChaincodeClient is the client API for Chaincode service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +// +// Chaincode as a server - peer establishes a connection to the chaincode as a client +// Currently only supports a stream connection. type ChaincodeClient interface { - Connect(ctx context.Context, opts ...grpc.CallOption) (Chaincode_ConnectClient, error) + Connect(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[ChaincodeMessage, ChaincodeMessage], error) } type chaincodeClient struct { @@ -161,51 +144,40 @@ func NewChaincodeClient(cc grpc.ClientConnInterface) ChaincodeClient { return &chaincodeClient{cc} } -func (c *chaincodeClient) Connect(ctx context.Context, opts ...grpc.CallOption) (Chaincode_ConnectClient, error) { - stream, err := c.cc.NewStream(ctx, &Chaincode_ServiceDesc.Streams[0], Chaincode_Connect_FullMethodName, opts...) +func (c *chaincodeClient) Connect(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[ChaincodeMessage, ChaincodeMessage], error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) + stream, err := c.cc.NewStream(ctx, &Chaincode_ServiceDesc.Streams[0], Chaincode_Connect_FullMethodName, cOpts...) if err != nil { return nil, err } - x := &chaincodeConnectClient{stream} + x := &grpc.GenericClientStream[ChaincodeMessage, ChaincodeMessage]{ClientStream: stream} return x, nil } -type Chaincode_ConnectClient interface { - Send(*ChaincodeMessage) error - Recv() (*ChaincodeMessage, error) - grpc.ClientStream -} - -type chaincodeConnectClient struct { - grpc.ClientStream -} - -func (x *chaincodeConnectClient) Send(m *ChaincodeMessage) error { - return x.ClientStream.SendMsg(m) -} - -func (x *chaincodeConnectClient) Recv() (*ChaincodeMessage, error) { - m := new(ChaincodeMessage) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type Chaincode_ConnectClient = grpc.BidiStreamingClient[ChaincodeMessage, ChaincodeMessage] // ChaincodeServer is the server API for Chaincode service. // All implementations should embed UnimplementedChaincodeServer -// for forward compatibility +// for forward compatibility. +// +// Chaincode as a server - peer establishes a connection to the chaincode as a client +// Currently only supports a stream connection. type ChaincodeServer interface { - Connect(Chaincode_ConnectServer) error + Connect(grpc.BidiStreamingServer[ChaincodeMessage, ChaincodeMessage]) error } -// UnimplementedChaincodeServer should be embedded to have forward compatible implementations. -type UnimplementedChaincodeServer struct { -} +// UnimplementedChaincodeServer should be embedded to have +// forward compatible implementations. +// +// NOTE: this should be embedded by value instead of pointer to avoid a nil +// pointer dereference when methods are called. +type UnimplementedChaincodeServer struct{} -func (UnimplementedChaincodeServer) Connect(Chaincode_ConnectServer) error { +func (UnimplementedChaincodeServer) Connect(grpc.BidiStreamingServer[ChaincodeMessage, ChaincodeMessage]) error { return status.Errorf(codes.Unimplemented, "method Connect not implemented") } +func (UnimplementedChaincodeServer) testEmbeddedByValue() {} // UnsafeChaincodeServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to ChaincodeServer will @@ -215,34 +187,22 @@ type UnsafeChaincodeServer interface { } func RegisterChaincodeServer(s grpc.ServiceRegistrar, srv ChaincodeServer) { + // If the following call pancis, it indicates UnimplementedChaincodeServer was + // embedded by pointer and is nil. This will cause panics if an + // unimplemented method is ever invoked, so we test this at initialization + // time to prevent it from happening at runtime later due to I/O. + if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { + t.testEmbeddedByValue() + } s.RegisterService(&Chaincode_ServiceDesc, srv) } func _Chaincode_Connect_Handler(srv interface{}, stream grpc.ServerStream) error { - return srv.(ChaincodeServer).Connect(&chaincodeConnectServer{stream}) -} - -type Chaincode_ConnectServer interface { - Send(*ChaincodeMessage) error - Recv() (*ChaincodeMessage, error) - grpc.ServerStream -} - -type chaincodeConnectServer struct { - grpc.ServerStream + return srv.(ChaincodeServer).Connect(&grpc.GenericServerStream[ChaincodeMessage, ChaincodeMessage]{ServerStream: stream}) } -func (x *chaincodeConnectServer) Send(m *ChaincodeMessage) error { - return x.ServerStream.SendMsg(m) -} - -func (x *chaincodeConnectServer) Recv() (*ChaincodeMessage, error) { - m := new(ChaincodeMessage) - if err := x.ServerStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type Chaincode_ConnectServer = grpc.BidiStreamingServer[ChaincodeMessage, ChaincodeMessage] // Chaincode_ServiceDesc is the grpc.ServiceDesc for Chaincode service. // It's only intended for direct use with grpc.RegisterService, diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/collection.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/collection.pb.go index c55fa1a2..49d304cf 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/collection.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/collection.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/collection.proto @@ -424,7 +424,7 @@ func file_peer_collection_proto_rawDescGZIP() []byte { } var file_peer_collection_proto_msgTypes = make([]protoimpl.MessageInfo, 4) -var file_peer_collection_proto_goTypes = []interface{}{ +var file_peer_collection_proto_goTypes = []any{ (*CollectionConfigPackage)(nil), // 0: protos.CollectionConfigPackage (*CollectionConfig)(nil), // 1: protos.CollectionConfig (*StaticCollectionConfig)(nil), // 2: protos.StaticCollectionConfig @@ -452,7 +452,7 @@ func file_peer_collection_proto_init() { } file_peer_policy_proto_init() if !protoimpl.UnsafeEnabled { - file_peer_collection_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_collection_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*CollectionConfigPackage); i { case 0: return &v.state @@ -464,7 +464,7 @@ func file_peer_collection_proto_init() { return nil } } - file_peer_collection_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_peer_collection_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*CollectionConfig); i { case 0: return &v.state @@ -476,7 +476,7 @@ func file_peer_collection_proto_init() { return nil } } - file_peer_collection_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_peer_collection_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*StaticCollectionConfig); i { case 0: return &v.state @@ -488,7 +488,7 @@ func file_peer_collection_proto_init() { return nil } } - file_peer_collection_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_peer_collection_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*CollectionPolicyConfig); i { case 0: return &v.state @@ -501,10 +501,10 @@ func file_peer_collection_proto_init() { } } } - file_peer_collection_proto_msgTypes[1].OneofWrappers = []interface{}{ + file_peer_collection_proto_msgTypes[1].OneofWrappers = []any{ (*CollectionConfig_StaticCollectionConfig)(nil), } - file_peer_collection_proto_msgTypes[3].OneofWrappers = []interface{}{ + file_peer_collection_proto_msgTypes[3].OneofWrappers = []any{ (*CollectionPolicyConfig_SignaturePolicy)(nil), } type x struct{} diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/configuration.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/configuration.pb.go index 238b3e48..c052ee64 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/configuration.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/configuration.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/configuration.proto @@ -277,7 +277,7 @@ func file_peer_configuration_proto_rawDescGZIP() []byte { } var file_peer_configuration_proto_msgTypes = make([]protoimpl.MessageInfo, 5) -var file_peer_configuration_proto_goTypes = []interface{}{ +var file_peer_configuration_proto_goTypes = []any{ (*AnchorPeers)(nil), // 0: protos.AnchorPeers (*AnchorPeer)(nil), // 1: protos.AnchorPeer (*APIResource)(nil), // 2: protos.APIResource @@ -301,7 +301,7 @@ func file_peer_configuration_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_peer_configuration_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_configuration_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*AnchorPeers); i { case 0: return &v.state @@ -313,7 +313,7 @@ func file_peer_configuration_proto_init() { return nil } } - file_peer_configuration_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_peer_configuration_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*AnchorPeer); i { case 0: return &v.state @@ -325,7 +325,7 @@ func file_peer_configuration_proto_init() { return nil } } - file_peer_configuration_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_peer_configuration_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*APIResource); i { case 0: return &v.state @@ -337,7 +337,7 @@ func file_peer_configuration_proto_init() { return nil } } - file_peer_configuration_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_peer_configuration_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*ACLs); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/events.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/events.pb.go index 27c810d4..75f8db6d 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/events.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/events.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/events.proto @@ -568,7 +568,7 @@ func file_peer_events_proto_rawDescGZIP() []byte { } var file_peer_events_proto_msgTypes = make([]protoimpl.MessageInfo, 7) -var file_peer_events_proto_goTypes = []interface{}{ +var file_peer_events_proto_goTypes = []any{ (*FilteredBlock)(nil), // 0: protos.FilteredBlock (*FilteredTransaction)(nil), // 1: protos.FilteredTransaction (*FilteredTransactionActions)(nil), // 2: protos.FilteredTransactionActions @@ -619,7 +619,7 @@ func file_peer_events_proto_init() { file_peer_chaincode_event_proto_init() file_peer_transaction_proto_init() if !protoimpl.UnsafeEnabled { - file_peer_events_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_events_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*FilteredBlock); i { case 0: return &v.state @@ -631,7 +631,7 @@ func file_peer_events_proto_init() { return nil } } - file_peer_events_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_peer_events_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*FilteredTransaction); i { case 0: return &v.state @@ -643,7 +643,7 @@ func file_peer_events_proto_init() { return nil } } - file_peer_events_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_peer_events_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*FilteredTransactionActions); i { case 0: return &v.state @@ -655,7 +655,7 @@ func file_peer_events_proto_init() { return nil } } - file_peer_events_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_peer_events_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*FilteredChaincodeAction); i { case 0: return &v.state @@ -667,7 +667,7 @@ func file_peer_events_proto_init() { return nil } } - file_peer_events_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_peer_events_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*BlockAndPrivateData); i { case 0: return &v.state @@ -679,7 +679,7 @@ func file_peer_events_proto_init() { return nil } } - file_peer_events_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_peer_events_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*DeliverResponse); i { case 0: return &v.state @@ -692,10 +692,10 @@ func file_peer_events_proto_init() { } } } - file_peer_events_proto_msgTypes[1].OneofWrappers = []interface{}{ + file_peer_events_proto_msgTypes[1].OneofWrappers = []any{ (*FilteredTransaction_TransactionActions)(nil), } - file_peer_events_proto_msgTypes[5].OneofWrappers = []interface{}{ + file_peer_events_proto_msgTypes[5].OneofWrappers = []any{ (*DeliverResponse_Status)(nil), (*DeliverResponse_Block)(nil), (*DeliverResponse_FilteredBlock)(nil), diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/events_grpc.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/events_grpc.pb.go index 4b4b09ce..bfbf3f58 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/events_grpc.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/events_grpc.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: -// - protoc-gen-go-grpc v1.3.0 +// - protoc-gen-go-grpc v1.5.1 // - protoc (unknown) // source: peer/events.proto @@ -20,8 +20,8 @@ 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 +// Requires gRPC-Go v1.64.0 or later. +const _ = grpc.SupportPackageIsVersion9 const ( Deliver_Deliver_FullMethodName = "/protos.Deliver/Deliver" @@ -36,15 +36,15 @@ type DeliverClient interface { // Deliver first requires an Envelope of type ab.DELIVER_SEEK_INFO with // Payload data as a marshaled orderer.SeekInfo message, // then a stream of block replies is received - Deliver(ctx context.Context, opts ...grpc.CallOption) (Deliver_DeliverClient, error) + Deliver(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[common.Envelope, DeliverResponse], error) // DeliverFiltered first requires an Envelope of type ab.DELIVER_SEEK_INFO with // Payload data as a marshaled orderer.SeekInfo message, // then a stream of **filtered** block replies is received - DeliverFiltered(ctx context.Context, opts ...grpc.CallOption) (Deliver_DeliverFilteredClient, error) + DeliverFiltered(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[common.Envelope, DeliverResponse], error) // DeliverWithPrivateData first requires an Envelope of type ab.DELIVER_SEEK_INFO with // Payload data as a marshaled orderer.SeekInfo message, // then a stream of block and private data replies is received - DeliverWithPrivateData(ctx context.Context, opts ...grpc.CallOption) (Deliver_DeliverWithPrivateDataClient, error) + DeliverWithPrivateData(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[common.Envelope, DeliverResponse], error) } type deliverClient struct { @@ -55,130 +55,80 @@ func NewDeliverClient(cc grpc.ClientConnInterface) DeliverClient { return &deliverClient{cc} } -func (c *deliverClient) Deliver(ctx context.Context, opts ...grpc.CallOption) (Deliver_DeliverClient, error) { - stream, err := c.cc.NewStream(ctx, &Deliver_ServiceDesc.Streams[0], Deliver_Deliver_FullMethodName, opts...) +func (c *deliverClient) Deliver(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[common.Envelope, DeliverResponse], error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) + stream, err := c.cc.NewStream(ctx, &Deliver_ServiceDesc.Streams[0], Deliver_Deliver_FullMethodName, cOpts...) if err != nil { return nil, err } - x := &deliverDeliverClient{stream} + x := &grpc.GenericClientStream[common.Envelope, DeliverResponse]{ClientStream: stream} return x, nil } -type Deliver_DeliverClient interface { - Send(*common.Envelope) error - Recv() (*DeliverResponse, error) - grpc.ClientStream -} - -type deliverDeliverClient struct { - grpc.ClientStream -} - -func (x *deliverDeliverClient) Send(m *common.Envelope) error { - return x.ClientStream.SendMsg(m) -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type Deliver_DeliverClient = grpc.BidiStreamingClient[common.Envelope, DeliverResponse] -func (x *deliverDeliverClient) Recv() (*DeliverResponse, error) { - m := new(DeliverResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *deliverClient) DeliverFiltered(ctx context.Context, opts ...grpc.CallOption) (Deliver_DeliverFilteredClient, error) { - stream, err := c.cc.NewStream(ctx, &Deliver_ServiceDesc.Streams[1], Deliver_DeliverFiltered_FullMethodName, opts...) +func (c *deliverClient) DeliverFiltered(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[common.Envelope, DeliverResponse], error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) + stream, err := c.cc.NewStream(ctx, &Deliver_ServiceDesc.Streams[1], Deliver_DeliverFiltered_FullMethodName, cOpts...) if err != nil { return nil, err } - x := &deliverDeliverFilteredClient{stream} + x := &grpc.GenericClientStream[common.Envelope, DeliverResponse]{ClientStream: stream} return x, nil } -type Deliver_DeliverFilteredClient interface { - Send(*common.Envelope) error - Recv() (*DeliverResponse, error) - grpc.ClientStream -} - -type deliverDeliverFilteredClient struct { - grpc.ClientStream -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type Deliver_DeliverFilteredClient = grpc.BidiStreamingClient[common.Envelope, DeliverResponse] -func (x *deliverDeliverFilteredClient) Send(m *common.Envelope) error { - return x.ClientStream.SendMsg(m) -} - -func (x *deliverDeliverFilteredClient) Recv() (*DeliverResponse, error) { - m := new(DeliverResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *deliverClient) DeliverWithPrivateData(ctx context.Context, opts ...grpc.CallOption) (Deliver_DeliverWithPrivateDataClient, error) { - stream, err := c.cc.NewStream(ctx, &Deliver_ServiceDesc.Streams[2], Deliver_DeliverWithPrivateData_FullMethodName, opts...) +func (c *deliverClient) DeliverWithPrivateData(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[common.Envelope, DeliverResponse], error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) + stream, err := c.cc.NewStream(ctx, &Deliver_ServiceDesc.Streams[2], Deliver_DeliverWithPrivateData_FullMethodName, cOpts...) if err != nil { return nil, err } - x := &deliverDeliverWithPrivateDataClient{stream} + x := &grpc.GenericClientStream[common.Envelope, DeliverResponse]{ClientStream: stream} return x, nil } -type Deliver_DeliverWithPrivateDataClient interface { - Send(*common.Envelope) error - Recv() (*DeliverResponse, error) - grpc.ClientStream -} - -type deliverDeliverWithPrivateDataClient struct { - grpc.ClientStream -} - -func (x *deliverDeliverWithPrivateDataClient) Send(m *common.Envelope) error { - return x.ClientStream.SendMsg(m) -} - -func (x *deliverDeliverWithPrivateDataClient) Recv() (*DeliverResponse, error) { - m := new(DeliverResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type Deliver_DeliverWithPrivateDataClient = grpc.BidiStreamingClient[common.Envelope, DeliverResponse] // DeliverServer is the server API for Deliver service. // All implementations should embed UnimplementedDeliverServer -// for forward compatibility +// for forward compatibility. type DeliverServer interface { // Deliver first requires an Envelope of type ab.DELIVER_SEEK_INFO with // Payload data as a marshaled orderer.SeekInfo message, // then a stream of block replies is received - Deliver(Deliver_DeliverServer) error + Deliver(grpc.BidiStreamingServer[common.Envelope, DeliverResponse]) error // DeliverFiltered first requires an Envelope of type ab.DELIVER_SEEK_INFO with // Payload data as a marshaled orderer.SeekInfo message, // then a stream of **filtered** block replies is received - DeliverFiltered(Deliver_DeliverFilteredServer) error + DeliverFiltered(grpc.BidiStreamingServer[common.Envelope, DeliverResponse]) error // DeliverWithPrivateData first requires an Envelope of type ab.DELIVER_SEEK_INFO with // Payload data as a marshaled orderer.SeekInfo message, // then a stream of block and private data replies is received - DeliverWithPrivateData(Deliver_DeliverWithPrivateDataServer) error + DeliverWithPrivateData(grpc.BidiStreamingServer[common.Envelope, DeliverResponse]) error } -// UnimplementedDeliverServer should be embedded to have forward compatible implementations. -type UnimplementedDeliverServer struct { -} +// UnimplementedDeliverServer should be embedded to have +// forward compatible implementations. +// +// NOTE: this should be embedded by value instead of pointer to avoid a nil +// pointer dereference when methods are called. +type UnimplementedDeliverServer struct{} -func (UnimplementedDeliverServer) Deliver(Deliver_DeliverServer) error { +func (UnimplementedDeliverServer) Deliver(grpc.BidiStreamingServer[common.Envelope, DeliverResponse]) error { return status.Errorf(codes.Unimplemented, "method Deliver not implemented") } -func (UnimplementedDeliverServer) DeliverFiltered(Deliver_DeliverFilteredServer) error { +func (UnimplementedDeliverServer) DeliverFiltered(grpc.BidiStreamingServer[common.Envelope, DeliverResponse]) error { return status.Errorf(codes.Unimplemented, "method DeliverFiltered not implemented") } -func (UnimplementedDeliverServer) DeliverWithPrivateData(Deliver_DeliverWithPrivateDataServer) error { +func (UnimplementedDeliverServer) DeliverWithPrivateData(grpc.BidiStreamingServer[common.Envelope, DeliverResponse]) error { return status.Errorf(codes.Unimplemented, "method DeliverWithPrivateData not implemented") } +func (UnimplementedDeliverServer) testEmbeddedByValue() {} // UnsafeDeliverServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to DeliverServer will @@ -188,86 +138,36 @@ type UnsafeDeliverServer interface { } func RegisterDeliverServer(s grpc.ServiceRegistrar, srv DeliverServer) { + // If the following call pancis, it indicates UnimplementedDeliverServer was + // embedded by pointer and is nil. This will cause panics if an + // unimplemented method is ever invoked, so we test this at initialization + // time to prevent it from happening at runtime later due to I/O. + if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { + t.testEmbeddedByValue() + } s.RegisterService(&Deliver_ServiceDesc, srv) } func _Deliver_Deliver_Handler(srv interface{}, stream grpc.ServerStream) error { - return srv.(DeliverServer).Deliver(&deliverDeliverServer{stream}) -} - -type Deliver_DeliverServer interface { - Send(*DeliverResponse) error - Recv() (*common.Envelope, error) - grpc.ServerStream -} - -type deliverDeliverServer struct { - grpc.ServerStream -} - -func (x *deliverDeliverServer) Send(m *DeliverResponse) error { - return x.ServerStream.SendMsg(m) + return srv.(DeliverServer).Deliver(&grpc.GenericServerStream[common.Envelope, DeliverResponse]{ServerStream: stream}) } -func (x *deliverDeliverServer) Recv() (*common.Envelope, error) { - m := new(common.Envelope) - if err := x.ServerStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type Deliver_DeliverServer = grpc.BidiStreamingServer[common.Envelope, DeliverResponse] func _Deliver_DeliverFiltered_Handler(srv interface{}, stream grpc.ServerStream) error { - return srv.(DeliverServer).DeliverFiltered(&deliverDeliverFilteredServer{stream}) -} - -type Deliver_DeliverFilteredServer interface { - Send(*DeliverResponse) error - Recv() (*common.Envelope, error) - grpc.ServerStream -} - -type deliverDeliverFilteredServer struct { - grpc.ServerStream + return srv.(DeliverServer).DeliverFiltered(&grpc.GenericServerStream[common.Envelope, DeliverResponse]{ServerStream: stream}) } -func (x *deliverDeliverFilteredServer) Send(m *DeliverResponse) error { - return x.ServerStream.SendMsg(m) -} - -func (x *deliverDeliverFilteredServer) Recv() (*common.Envelope, error) { - m := new(common.Envelope) - if err := x.ServerStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type Deliver_DeliverFilteredServer = grpc.BidiStreamingServer[common.Envelope, DeliverResponse] func _Deliver_DeliverWithPrivateData_Handler(srv interface{}, stream grpc.ServerStream) error { - return srv.(DeliverServer).DeliverWithPrivateData(&deliverDeliverWithPrivateDataServer{stream}) -} - -type Deliver_DeliverWithPrivateDataServer interface { - Send(*DeliverResponse) error - Recv() (*common.Envelope, error) - grpc.ServerStream + return srv.(DeliverServer).DeliverWithPrivateData(&grpc.GenericServerStream[common.Envelope, DeliverResponse]{ServerStream: stream}) } -type deliverDeliverWithPrivateDataServer struct { - grpc.ServerStream -} - -func (x *deliverDeliverWithPrivateDataServer) Send(m *DeliverResponse) error { - return x.ServerStream.SendMsg(m) -} - -func (x *deliverDeliverWithPrivateDataServer) Recv() (*common.Envelope, error) { - m := new(common.Envelope) - if err := x.ServerStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} +// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name. +type Deliver_DeliverWithPrivateDataServer = grpc.BidiStreamingServer[common.Envelope, DeliverResponse] // Deliver_ServiceDesc is the grpc.ServiceDesc for Deliver service. // It's only intended for direct use with grpc.RegisterService, diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/peer.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/peer.pb.go index b8172e65..1577fb03 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/peer.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/peer.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/peer.proto @@ -49,7 +49,7 @@ var file_peer_peer_proto_rawDesc = []byte{ 0x74, 0x6f, 0x33, } -var file_peer_peer_proto_goTypes = []interface{}{ +var file_peer_peer_proto_goTypes = []any{ (*SignedProposal)(nil), // 0: protos.SignedProposal (*ProposalResponse)(nil), // 1: protos.ProposalResponse } diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/peer_grpc.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/peer_grpc.pb.go index f3fd5657..ac99beb1 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/peer_grpc.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/peer_grpc.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: -// - protoc-gen-go-grpc v1.3.0 +// - protoc-gen-go-grpc v1.5.1 // - protoc (unknown) // source: peer/peer.proto @@ -19,8 +19,8 @@ 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 +// Requires gRPC-Go v1.64.0 or later. +const _ = grpc.SupportPackageIsVersion9 const ( Endorser_ProcessProposal_FullMethodName = "/protos.Endorser/ProcessProposal" @@ -42,8 +42,9 @@ func NewEndorserClient(cc grpc.ClientConnInterface) EndorserClient { } func (c *endorserClient) ProcessProposal(ctx context.Context, in *SignedProposal, opts ...grpc.CallOption) (*ProposalResponse, error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(ProposalResponse) - err := c.cc.Invoke(ctx, Endorser_ProcessProposal_FullMethodName, in, out, opts...) + err := c.cc.Invoke(ctx, Endorser_ProcessProposal_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } @@ -52,18 +53,22 @@ func (c *endorserClient) ProcessProposal(ctx context.Context, in *SignedProposal // EndorserServer is the server API for Endorser service. // All implementations should embed UnimplementedEndorserServer -// for forward compatibility +// for forward compatibility. type EndorserServer interface { ProcessProposal(context.Context, *SignedProposal) (*ProposalResponse, error) } -// UnimplementedEndorserServer should be embedded to have forward compatible implementations. -type UnimplementedEndorserServer struct { -} +// UnimplementedEndorserServer should be embedded to have +// forward compatible implementations. +// +// NOTE: this should be embedded by value instead of pointer to avoid a nil +// pointer dereference when methods are called. +type UnimplementedEndorserServer struct{} func (UnimplementedEndorserServer) ProcessProposal(context.Context, *SignedProposal) (*ProposalResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ProcessProposal not implemented") } +func (UnimplementedEndorserServer) testEmbeddedByValue() {} // UnsafeEndorserServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to EndorserServer will @@ -73,6 +78,13 @@ type UnsafeEndorserServer interface { } func RegisterEndorserServer(s grpc.ServiceRegistrar, srv EndorserServer) { + // If the following call pancis, it indicates UnimplementedEndorserServer was + // embedded by pointer and is nil. This will cause panics if an + // unimplemented method is ever invoked, so we test this at initialization + // time to prevent it from happening at runtime later due to I/O. + if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { + t.testEmbeddedByValue() + } s.RegisterService(&Endorser_ServiceDesc, srv) } diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/policy.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/policy.pb.go index 38a220f5..72a80941 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/policy.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/policy.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/policy.proto @@ -157,7 +157,7 @@ func file_peer_policy_proto_rawDescGZIP() []byte { } var file_peer_policy_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_peer_policy_proto_goTypes = []interface{}{ +var file_peer_policy_proto_goTypes = []any{ (*ApplicationPolicy)(nil), // 0: protos.ApplicationPolicy (*common.SignaturePolicyEnvelope)(nil), // 1: common.SignaturePolicyEnvelope } @@ -176,7 +176,7 @@ func file_peer_policy_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_peer_policy_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_policy_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ApplicationPolicy); i { case 0: return &v.state @@ -189,7 +189,7 @@ func file_peer_policy_proto_init() { } } } - file_peer_policy_proto_msgTypes[0].OneofWrappers = []interface{}{ + file_peer_policy_proto_msgTypes[0].OneofWrappers = []any{ (*ApplicationPolicy_SignaturePolicy)(nil), (*ApplicationPolicy_ChannelConfigPolicyReference)(nil), } diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/proposal.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/proposal.pb.go index c737a9da..4283b522 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/proposal.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/proposal.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/proposal.proto @@ -470,7 +470,7 @@ func file_peer_proposal_proto_rawDescGZIP() []byte { } var file_peer_proposal_proto_msgTypes = make([]protoimpl.MessageInfo, 6) -var file_peer_proposal_proto_goTypes = []interface{}{ +var file_peer_proposal_proto_goTypes = []any{ (*SignedProposal)(nil), // 0: protos.SignedProposal (*Proposal)(nil), // 1: protos.Proposal (*ChaincodeHeaderExtension)(nil), // 2: protos.ChaincodeHeaderExtension @@ -500,7 +500,7 @@ func file_peer_proposal_proto_init() { file_peer_chaincode_proto_init() file_peer_proposal_response_proto_init() if !protoimpl.UnsafeEnabled { - file_peer_proposal_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_proposal_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*SignedProposal); i { case 0: return &v.state @@ -512,7 +512,7 @@ func file_peer_proposal_proto_init() { return nil } } - file_peer_proposal_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_peer_proposal_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*Proposal); i { case 0: return &v.state @@ -524,7 +524,7 @@ func file_peer_proposal_proto_init() { return nil } } - file_peer_proposal_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_peer_proposal_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeHeaderExtension); i { case 0: return &v.state @@ -536,7 +536,7 @@ func file_peer_proposal_proto_init() { return nil } } - file_peer_proposal_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_peer_proposal_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeProposalPayload); i { case 0: return &v.state @@ -548,7 +548,7 @@ func file_peer_proposal_proto_init() { return nil } } - file_peer_proposal_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_peer_proposal_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeAction); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/proposal_response.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/proposal_response.pb.go index 40a48d3a..2ce05de8 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/proposal_response.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/proposal_response.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/proposal_response.proto @@ -570,7 +570,7 @@ func file_peer_proposal_response_proto_rawDescGZIP() []byte { } var file_peer_proposal_response_proto_msgTypes = make([]protoimpl.MessageInfo, 6) -var file_peer_proposal_response_proto_goTypes = []interface{}{ +var file_peer_proposal_response_proto_goTypes = []any{ (*ProposalResponse)(nil), // 0: protos.ProposalResponse (*Response)(nil), // 1: protos.Response (*ProposalResponsePayload)(nil), // 2: protos.ProposalResponsePayload @@ -600,7 +600,7 @@ func file_peer_proposal_response_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_peer_proposal_response_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_proposal_response_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ProposalResponse); i { case 0: return &v.state @@ -612,7 +612,7 @@ func file_peer_proposal_response_proto_init() { return nil } } - file_peer_proposal_response_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_peer_proposal_response_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*Response); i { case 0: return &v.state @@ -624,7 +624,7 @@ func file_peer_proposal_response_proto_init() { return nil } } - file_peer_proposal_response_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_peer_proposal_response_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*ProposalResponsePayload); i { case 0: return &v.state @@ -636,7 +636,7 @@ func file_peer_proposal_response_proto_init() { return nil } } - file_peer_proposal_response_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_peer_proposal_response_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*Endorsement); i { case 0: return &v.state @@ -648,7 +648,7 @@ func file_peer_proposal_response_proto_init() { return nil } } - file_peer_proposal_response_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_peer_proposal_response_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeInterest); i { case 0: return &v.state @@ -660,7 +660,7 @@ func file_peer_proposal_response_proto_init() { return nil } } - file_peer_proposal_response_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_peer_proposal_response_proto_msgTypes[5].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeCall); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/query.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/query.pb.go index fc263cdd..b17a5de8 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/query.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/query.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/query.proto @@ -401,7 +401,7 @@ func file_peer_query_proto_rawDescGZIP() []byte { } var file_peer_query_proto_msgTypes = make([]protoimpl.MessageInfo, 5) -var file_peer_query_proto_goTypes = []interface{}{ +var file_peer_query_proto_goTypes = []any{ (*ChaincodeQueryResponse)(nil), // 0: protos.ChaincodeQueryResponse (*ChaincodeInfo)(nil), // 1: protos.ChaincodeInfo (*ChannelQueryResponse)(nil), // 2: protos.ChannelQueryResponse @@ -424,7 +424,7 @@ func file_peer_query_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_peer_query_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_query_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeQueryResponse); i { case 0: return &v.state @@ -436,7 +436,7 @@ func file_peer_query_proto_init() { return nil } } - file_peer_query_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_peer_query_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeInfo); i { case 0: return &v.state @@ -448,7 +448,7 @@ func file_peer_query_proto_init() { return nil } } - file_peer_query_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_peer_query_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*ChannelQueryResponse); i { case 0: return &v.state @@ -460,7 +460,7 @@ func file_peer_query_proto_init() { return nil } } - file_peer_query_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_peer_query_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*ChannelInfo); i { case 0: return &v.state @@ -472,7 +472,7 @@ func file_peer_query_proto_init() { return nil } } - file_peer_query_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_peer_query_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*JoinBySnapshotStatus); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/resources.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/resources.pb.go index a7c2eef3..08e484b5 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/resources.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/resources.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/resources.proto @@ -356,7 +356,7 @@ func file_peer_resources_proto_rawDescGZIP() []byte { } var file_peer_resources_proto_msgTypes = make([]protoimpl.MessageInfo, 5) -var file_peer_resources_proto_goTypes = []interface{}{ +var file_peer_resources_proto_goTypes = []any{ (*ChaincodeIdentifier)(nil), // 0: protos.ChaincodeIdentifier (*ChaincodeValidation)(nil), // 1: protos.ChaincodeValidation (*VSCCArgs)(nil), // 2: protos.VSCCArgs @@ -380,7 +380,7 @@ func file_peer_resources_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_peer_resources_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_resources_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeIdentifier); i { case 0: return &v.state @@ -392,7 +392,7 @@ func file_peer_resources_proto_init() { return nil } } - file_peer_resources_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_peer_resources_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeValidation); i { case 0: return &v.state @@ -404,7 +404,7 @@ func file_peer_resources_proto_init() { return nil } } - file_peer_resources_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_peer_resources_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*VSCCArgs); i { case 0: return &v.state @@ -416,7 +416,7 @@ func file_peer_resources_proto_init() { return nil } } - file_peer_resources_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_peer_resources_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeEndorsement); i { case 0: return &v.state @@ -428,7 +428,7 @@ func file_peer_resources_proto_init() { return nil } } - file_peer_resources_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_peer_resources_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*ConfigTree); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/signed_cc_dep_spec.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/signed_cc_dep_spec.pb.go index 4c31baa7..e8d66b39 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/signed_cc_dep_spec.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/signed_cc_dep_spec.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/signed_cc_dep_spec.proto @@ -143,7 +143,7 @@ func file_peer_signed_cc_dep_spec_proto_rawDescGZIP() []byte { } var file_peer_signed_cc_dep_spec_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_peer_signed_cc_dep_spec_proto_goTypes = []interface{}{ +var file_peer_signed_cc_dep_spec_proto_goTypes = []any{ (*SignedChaincodeDeploymentSpec)(nil), // 0: protos.SignedChaincodeDeploymentSpec (*Endorsement)(nil), // 1: protos.Endorsement } @@ -163,7 +163,7 @@ func file_peer_signed_cc_dep_spec_proto_init() { } file_peer_proposal_response_proto_init() if !protoimpl.UnsafeEnabled { - file_peer_signed_cc_dep_spec_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_signed_cc_dep_spec_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*SignedChaincodeDeploymentSpec); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/snapshot.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/snapshot.pb.go index 4f9494c9..00b52c2b 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/snapshot.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/snapshot.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/snapshot.proto @@ -332,7 +332,7 @@ func file_peer_snapshot_proto_rawDescGZIP() []byte { } var file_peer_snapshot_proto_msgTypes = make([]protoimpl.MessageInfo, 4) -var file_peer_snapshot_proto_goTypes = []interface{}{ +var file_peer_snapshot_proto_goTypes = []any{ (*SnapshotRequest)(nil), // 0: protos.SnapshotRequest (*SnapshotQuery)(nil), // 1: protos.SnapshotQuery (*SignedSnapshotRequest)(nil), // 2: protos.SignedSnapshotRequest @@ -362,7 +362,7 @@ func file_peer_snapshot_proto_init() { return } if !protoimpl.UnsafeEnabled { - file_peer_snapshot_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_snapshot_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*SnapshotRequest); i { case 0: return &v.state @@ -374,7 +374,7 @@ func file_peer_snapshot_proto_init() { return nil } } - file_peer_snapshot_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_peer_snapshot_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*SnapshotQuery); i { case 0: return &v.state @@ -386,7 +386,7 @@ func file_peer_snapshot_proto_init() { return nil } } - file_peer_snapshot_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_peer_snapshot_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*SignedSnapshotRequest); i { case 0: return &v.state @@ -398,7 +398,7 @@ func file_peer_snapshot_proto_init() { return nil } } - file_peer_snapshot_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_peer_snapshot_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*QueryPendingSnapshotsResponse); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/snapshot_grpc.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/snapshot_grpc.pb.go index 466f8eed..f991b2f6 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/snapshot_grpc.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/snapshot_grpc.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: -// - protoc-gen-go-grpc v1.3.0 +// - protoc-gen-go-grpc v1.5.1 // - protoc (unknown) // source: peer/snapshot.proto @@ -20,8 +20,8 @@ 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 +// Requires gRPC-Go v1.64.0 or later. +const _ = grpc.SupportPackageIsVersion9 const ( Snapshot_Generate_FullMethodName = "/protos.Snapshot/Generate" @@ -50,8 +50,9 @@ func NewSnapshotClient(cc grpc.ClientConnInterface) SnapshotClient { } func (c *snapshotClient) Generate(ctx context.Context, in *SignedSnapshotRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(emptypb.Empty) - err := c.cc.Invoke(ctx, Snapshot_Generate_FullMethodName, in, out, opts...) + err := c.cc.Invoke(ctx, Snapshot_Generate_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } @@ -59,8 +60,9 @@ func (c *snapshotClient) Generate(ctx context.Context, in *SignedSnapshotRequest } func (c *snapshotClient) Cancel(ctx context.Context, in *SignedSnapshotRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(emptypb.Empty) - err := c.cc.Invoke(ctx, Snapshot_Cancel_FullMethodName, in, out, opts...) + err := c.cc.Invoke(ctx, Snapshot_Cancel_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } @@ -68,8 +70,9 @@ func (c *snapshotClient) Cancel(ctx context.Context, in *SignedSnapshotRequest, } func (c *snapshotClient) QueryPendings(ctx context.Context, in *SignedSnapshotRequest, opts ...grpc.CallOption) (*QueryPendingSnapshotsResponse, error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(QueryPendingSnapshotsResponse) - err := c.cc.Invoke(ctx, Snapshot_QueryPendings_FullMethodName, in, out, opts...) + err := c.cc.Invoke(ctx, Snapshot_QueryPendings_FullMethodName, in, out, cOpts...) if err != nil { return nil, err } @@ -78,7 +81,7 @@ func (c *snapshotClient) QueryPendings(ctx context.Context, in *SignedSnapshotRe // SnapshotServer is the server API for Snapshot service. // All implementations should embed UnimplementedSnapshotServer -// for forward compatibility +// for forward compatibility. type SnapshotServer interface { // Generate a snapshot reqeust. SignedSnapshotRequest contains marshalled bytes for SnaphostRequest Generate(context.Context, *SignedSnapshotRequest) (*emptypb.Empty, error) @@ -88,9 +91,12 @@ type SnapshotServer interface { QueryPendings(context.Context, *SignedSnapshotRequest) (*QueryPendingSnapshotsResponse, error) } -// UnimplementedSnapshotServer should be embedded to have forward compatible implementations. -type UnimplementedSnapshotServer struct { -} +// UnimplementedSnapshotServer should be embedded to have +// forward compatible implementations. +// +// NOTE: this should be embedded by value instead of pointer to avoid a nil +// pointer dereference when methods are called. +type UnimplementedSnapshotServer struct{} func (UnimplementedSnapshotServer) Generate(context.Context, *SignedSnapshotRequest) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method Generate not implemented") @@ -101,6 +107,7 @@ func (UnimplementedSnapshotServer) Cancel(context.Context, *SignedSnapshotReques func (UnimplementedSnapshotServer) QueryPendings(context.Context, *SignedSnapshotRequest) (*QueryPendingSnapshotsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method QueryPendings not implemented") } +func (UnimplementedSnapshotServer) testEmbeddedByValue() {} // UnsafeSnapshotServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to SnapshotServer will @@ -110,6 +117,13 @@ type UnsafeSnapshotServer interface { } func RegisterSnapshotServer(s grpc.ServiceRegistrar, srv SnapshotServer) { + // If the following call pancis, it indicates UnimplementedSnapshotServer was + // embedded by pointer and is nil. This will cause panics if an + // unimplemented method is ever invoked, so we test this at initialization + // time to prevent it from happening at runtime later due to I/O. + if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { + t.testEmbeddedByValue() + } s.RegisterService(&Snapshot_ServiceDesc, srv) } diff --git a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/transaction.pb.go b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/transaction.pb.go index dc094f26..93992aaa 100644 --- a/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/transaction.pb.go +++ b/vendor/github.com/hyperledger/fabric-protos-go-apiv2/peer/transaction.pb.go @@ -4,7 +4,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 +// protoc-gen-go v1.34.2 // protoc (unknown) // source: peer/transaction.proto @@ -628,7 +628,7 @@ func file_peer_transaction_proto_rawDescGZIP() []byte { var file_peer_transaction_proto_enumTypes = make([]protoimpl.EnumInfo, 2) var file_peer_transaction_proto_msgTypes = make([]protoimpl.MessageInfo, 5) -var file_peer_transaction_proto_goTypes = []interface{}{ +var file_peer_transaction_proto_goTypes = []any{ (TxValidationCode)(0), // 0: protos.TxValidationCode (MetaDataKeys)(0), // 1: protos.MetaDataKeys (*ProcessedTransaction)(nil), // 2: protos.ProcessedTransaction @@ -658,7 +658,7 @@ func file_peer_transaction_proto_init() { } file_peer_proposal_response_proto_init() if !protoimpl.UnsafeEnabled { - file_peer_transaction_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_peer_transaction_proto_msgTypes[0].Exporter = func(v any, i int) any { switch v := v.(*ProcessedTransaction); i { case 0: return &v.state @@ -670,7 +670,7 @@ func file_peer_transaction_proto_init() { return nil } } - file_peer_transaction_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_peer_transaction_proto_msgTypes[1].Exporter = func(v any, i int) any { switch v := v.(*Transaction); i { case 0: return &v.state @@ -682,7 +682,7 @@ func file_peer_transaction_proto_init() { return nil } } - file_peer_transaction_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_peer_transaction_proto_msgTypes[2].Exporter = func(v any, i int) any { switch v := v.(*TransactionAction); i { case 0: return &v.state @@ -694,7 +694,7 @@ func file_peer_transaction_proto_init() { return nil } } - file_peer_transaction_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_peer_transaction_proto_msgTypes[3].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeActionPayload); i { case 0: return &v.state @@ -706,7 +706,7 @@ func file_peer_transaction_proto_init() { return nil } } - file_peer_transaction_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_peer_transaction_proto_msgTypes[4].Exporter = func(v any, i int) any { switch v := v.(*ChaincodeEndorsedAction); i { case 0: return &v.state diff --git a/vendor/github.com/hyperledger/fabric/NOTICE b/vendor/github.com/hyperledger/fabric/NOTICE index 2976a598..30688afb 100644 --- a/vendor/github.com/hyperledger/fabric/NOTICE +++ b/vendor/github.com/hyperledger/fabric/NOTICE @@ -1,5 +1,5 @@ Hyperledger Fabric -Copyright [2016-2020] contributors to Hyperledger Fabric +Copyright [2016-2025] contributors to Hyperledger Fabric This product includes software developed at Hyperledger (http://www.hyperledger.org/). diff --git a/vendor/github.com/hyperledger/fabric/common/crypto/sanitize.go b/vendor/github.com/hyperledger/fabric/common/crypto/sanitize.go index c036074e..5d4ce16f 100644 --- a/vendor/github.com/hyperledger/fabric/common/crypto/sanitize.go +++ b/vendor/github.com/hyperledger/fabric/common/crypto/sanitize.go @@ -38,6 +38,7 @@ func SanitizeIdentity(identity []byte) ([]byte, error) { return proto.Marshal(sID) } +// SanitizeX509Cert sanitizes an X.509 certificate to ensure that the ECDSA signature uses a "low-S" value. func SanitizeX509Cert(initialPEM []byte) ([]byte, error) { der, _ := pem.Decode(initialPEM) if der == nil { diff --git a/vendor/github.com/hyperledger/fabric/common/deliver/deliver.go b/vendor/github.com/hyperledger/fabric/common/deliver/deliver.go index d50f0284..3daaacb2 100644 --- a/vendor/github.com/hyperledger/fabric/common/deliver/deliver.go +++ b/vendor/github.com/hyperledger/fabric/common/deliver/deliver.go @@ -197,6 +197,8 @@ func isFiltered(srv *Server) bool { return false } +// deliverBlocks handles delivering blocks to the client from the blockchain channel. +// It processes a signed envelope from a client and responds with the requested blocks. func (h *Handler) deliverBlocks(ctx context.Context, srv *Server, envelope *cb.Envelope) (status cb.Status, err error) { addr := util.ExtractRemoteAddress(ctx) payload, chdr, shdr, err := h.parseEnvelope(ctx, envelope) @@ -411,21 +413,3 @@ func (h *Handler) validateChannelHeader(ctx context.Context, chdr *cb.ChannelHea func noExpiration(_ []byte) time.Time { return time.Time{} } - -func (h *Handler) HandleAttestation(ctx context.Context, srv *Server, env *cb.Envelope) error { - status, err := h.deliverBlocks(ctx, srv, env) - if err != nil { - return err - } - - err = srv.SendStatusResponse(status) - if status != cb.Status_SUCCESS { - return err - } - if err != nil { - addr := util.ExtractRemoteAddress(ctx) - logger.Warningf("Error sending to %s: %s", addr, err) - return err - } - return nil -} diff --git a/vendor/github.com/hyperledger/fabric/common/policies/bft.go b/vendor/github.com/hyperledger/fabric/common/policies/bft.go index 660a9fba..1ba6f11b 100644 --- a/vendor/github.com/hyperledger/fabric/common/policies/bft.go +++ b/vendor/github.com/hyperledger/fabric/common/policies/bft.go @@ -19,6 +19,9 @@ const ( BlockValidationPolicyKey = "BlockValidation" ) +// EncodeBFTBlockVerificationPolicy creates a block verification policy based on Byzantine Fault Tolerance (BFT). +// It takes a list of consenters (orderer nodes), constructs a BFT policy using their identities, and updates +// the orderer's configuration group with this new policy. func EncodeBFTBlockVerificationPolicy(consenterProtos []*cb.Consenter, ordererGroup *cb.ConfigGroup) { n := len(consenterProtos) f := (n - 1) / 3 diff --git a/vendor/github.com/hyperledger/fabric/common/policies/implicitmeta.go b/vendor/github.com/hyperledger/fabric/common/policies/implicitmeta.go index 7787c1c8..20488e9c 100644 --- a/vendor/github.com/hyperledger/fabric/common/policies/implicitmeta.go +++ b/vendor/github.com/hyperledger/fabric/common/policies/implicitmeta.go @@ -83,7 +83,7 @@ func (imp *ImplicitMetaPolicy) EvaluateSignedData(signatureSet []*protoutil.Sign b.WriteString(" ") } b.WriteString("]") - logger.Debugf(b.String()) + logger.Debug(b.String()) } } }() @@ -126,7 +126,7 @@ func (imp *ImplicitMetaPolicy) EvaluateIdentities(identities []msp.Identity) err b.WriteString(" ") } b.WriteString("]") - logger.Debugf(b.String()) + logger.Debug(b.String()) }() for _, policy := range imp.SubPolicies { diff --git a/vendor/github.com/hyperledger/fabric/common/policies/implicitmeta_util.go b/vendor/github.com/hyperledger/fabric/common/policies/implicitmeta_util.go index ed897293..d7b8c67b 100644 --- a/vendor/github.com/hyperledger/fabric/common/policies/implicitmeta_util.go +++ b/vendor/github.com/hyperledger/fabric/common/policies/implicitmeta_util.go @@ -24,7 +24,7 @@ func ImplicitMetaPolicyWithSubPolicy(subPolicyName string, rule cb.ImplicitMetaP } } -// TemplateImplicitMetaPolicy creates a policy at the specified path with the given policyName and subPolicyName +// TemplateImplicitMetaPolicyWithSubPolicy creates a policy at the specified path with the given policyName and subPolicyName func TemplateImplicitMetaPolicyWithSubPolicy(path []string, policyName string, subPolicyName string, rule cb.ImplicitMetaPolicy_Rule) *cb.ConfigGroup { root := protoutil.NewConfigGroup() group := root diff --git a/vendor/github.com/hyperledger/fabric/common/policydsl/policyparser.go b/vendor/github.com/hyperledger/fabric/common/policydsl/policyparser.go index f06e28e8..db18b859 100644 --- a/vendor/github.com/hyperledger/fabric/common/policydsl/policyparser.go +++ b/vendor/github.com/hyperledger/fabric/common/policydsl/policyparser.go @@ -92,6 +92,8 @@ func or(args ...interface{}) (interface{}, error) { return outof(args...) } +// firstPass processes a variadic list of arguments and returns a formatted string. +// The function expects arguments to be of either string, float32, or float64 types. func firstPass(args ...interface{}) (interface{}, error) { toret := "outof(ID" for _, arg := range args { @@ -115,6 +117,9 @@ func firstPass(args ...interface{}) (interface{}, error) { return toret + ")", nil } +// secondPass processes a list of arguments to build a "t-out-of-n" policy. +// It expects the first argument to be a context, the second an integer (threshold t), +// and the rest as either principals (strings) or pre-existing policies. func secondPass(args ...interface{}) (interface{}, error) { /* general sanity check, we expect at least 3 args */ if len(args) < 3 { diff --git a/vendor/github.com/hyperledger/fabric/common/viperutil/config_util.go b/vendor/github.com/hyperledger/fabric/common/viperutil/config_util.go index 192a5060..f9006df8 100644 --- a/vendor/github.com/hyperledger/fabric/common/viperutil/config_util.go +++ b/vendor/github.com/hyperledger/fabric/common/viperutil/config_util.go @@ -7,6 +7,7 @@ SPDX-License-Identifier: Apache-2.0 package viperutil import ( + "bytes" "encoding/pem" "fmt" "io" @@ -18,11 +19,11 @@ import ( "strconv" "strings" + "github.com/go-viper/mapstructure/v2" "github.com/hyperledger/fabric-lib-go/bccsp/factory" "github.com/hyperledger/fabric-lib-go/common/flogging" - "github.com/mitchellh/mapstructure" "github.com/pkg/errors" - "gopkg.in/yaml.v2" + "gopkg.in/yaml.v3" ) var logger = flogging.MustGetLogger("viperutil") @@ -422,6 +423,10 @@ func YamlStringToStructHook(m interface{}) func(rf reflect.Kind, rt reflect.Kind return m, nil } - return m, yaml.UnmarshalStrict([]byte(raw), &m) + dec := yaml.NewDecoder(bytes.NewBuffer([]byte(raw))) + dec.KnownFields(true) + err := dec.Decode(&m) + + return m, err } } diff --git a/vendor/github.com/hyperledger/fabric/msp/configbuilder.go b/vendor/github.com/hyperledger/fabric/msp/configbuilder.go index 1f8d4407..d0cd1976 100644 --- a/vendor/github.com/hyperledger/fabric/msp/configbuilder.go +++ b/vendor/github.com/hyperledger/fabric/msp/configbuilder.go @@ -17,7 +17,7 @@ import ( "github.com/hyperledger/fabric-protos-go-apiv2/msp" "github.com/pkg/errors" "google.golang.org/protobuf/proto" - "gopkg.in/yaml.v2" + "gopkg.in/yaml.v3" ) // OrganizationalUnitIdentifiersConfiguration is used to represent an OU diff --git a/vendor/github.com/hyperledger/fabric/msp/mgmt/mgmt.go b/vendor/github.com/hyperledger/fabric/msp/mgmt/mgmt.go index cec0a366..160cbfc3 100644 --- a/vendor/github.com/hyperledger/fabric/msp/mgmt/mgmt.go +++ b/vendor/github.com/hyperledger/fabric/msp/mgmt/mgmt.go @@ -98,7 +98,7 @@ func loadLocalMSP(bccsp bccsp.BCCSP) msp.MSP { newOpts, found := msp.Options[mspType] if !found { - mspLogger.Panicf("msp type " + mspType + " unknown") + mspLogger.Panicf("msp type %s unknown", mspType) } mspInst, err := msp.New(newOpts, bccsp) diff --git a/vendor/github.com/hyperledger/fabric/msp/msp.go b/vendor/github.com/hyperledger/fabric/msp/msp.go index a2ba5b1e..01258210 100644 --- a/vendor/github.com/hyperledger/fabric/msp/msp.go +++ b/vendor/github.com/hyperledger/fabric/msp/msp.go @@ -99,7 +99,7 @@ type OUIdentifier struct { // CertifiersIdentifier is the hash of certificates chain of trust // related to this organizational unit CertifiersIdentifier []byte - // OrganizationUnitIdentifier defines the organizational unit under the + // OrganizationalUnitIdentifier defines the organizational unit under the // MSP identified with MSPIdentifier OrganizationalUnitIdentifier string } diff --git a/vendor/github.com/hyperledger/fabric/protoutil/blockutils.go b/vendor/github.com/hyperledger/fabric/protoutil/blockutils.go index 18962c4d..761fbfc8 100644 --- a/vendor/github.com/hyperledger/fabric/protoutil/blockutils.go +++ b/vendor/github.com/hyperledger/fabric/protoutil/blockutils.go @@ -309,7 +309,7 @@ func searchConsenterIdentityByID(consenters []*cb.Consenter, identifier uint32) func VerifyTransactionsAreWellFormed(bd *cb.BlockData) error { if bd == nil || bd.Data == nil || len(bd.Data) == 0 { - return fmt.Errorf("empty block") + return errors.New("empty block") } // If we have a single transaction, and the block is a config block, then no need to check diff --git a/vendor/github.com/hyperledger/fabric/protoutil/signeddata.go b/vendor/github.com/hyperledger/fabric/protoutil/signeddata.go index 661e9fb2..03a0a446 100644 --- a/vendor/github.com/hyperledger/fabric/protoutil/signeddata.go +++ b/vendor/github.com/hyperledger/fabric/protoutil/signeddata.go @@ -10,6 +10,7 @@ import ( "bytes" "crypto/x509" "encoding/pem" + "errors" "fmt" "strings" @@ -33,7 +34,7 @@ type SignedData struct { // possible. func ConfigUpdateEnvelopeAsSignedData(ce *common.ConfigUpdateEnvelope) ([]*SignedData, error) { if ce == nil { - return nil, fmt.Errorf("No signatures for nil SignedConfigItem") + return nil, errors.New("No signatures for nil SignedConfigItem") } result := make([]*SignedData, len(ce.Signatures)) @@ -59,7 +60,7 @@ func ConfigUpdateEnvelopeAsSignedData(ce *common.ConfigUpdateEnvelope) ([]*Signe // slice of length 1 or an error indicating why this was not possible. func EnvelopeAsSignedData(env *common.Envelope) ([]*SignedData, error) { if env == nil { - return nil, fmt.Errorf("No signatures for nil Envelope") + return nil, errors.New("No signatures for nil Envelope") } payload := &common.Payload{} @@ -69,7 +70,7 @@ func EnvelopeAsSignedData(env *common.Envelope) ([]*SignedData, error) { } if payload.Header == nil /* || payload.Header.SignatureHeader == nil */ { - return nil, fmt.Errorf("Missing Header") + return nil, errors.New("Missing Header") } shdr := &common.SignatureHeader{} diff --git a/vendor/github.com/stretchr/testify/assert/assertion_compare.go b/vendor/github.com/stretchr/testify/assert/assertion_compare.go index 4d4b4aad..7e19eba0 100644 --- a/vendor/github.com/stretchr/testify/assert/assertion_compare.go +++ b/vendor/github.com/stretchr/testify/assert/assertion_compare.go @@ -7,10 +7,13 @@ import ( "time" ) -type CompareType int +// Deprecated: CompareType has only ever been for internal use and has accidentally been published since v1.6.0. Do not use it. +type CompareType = compareResult + +type compareResult int const ( - compareLess CompareType = iota - 1 + compareLess compareResult = iota - 1 compareEqual compareGreater ) @@ -39,7 +42,7 @@ var ( bytesType = reflect.TypeOf([]byte{}) ) -func compare(obj1, obj2 interface{}, kind reflect.Kind) (CompareType, bool) { +func compare(obj1, obj2 interface{}, kind reflect.Kind) (compareResult, bool) { obj1Value := reflect.ValueOf(obj1) obj2Value := reflect.ValueOf(obj2) @@ -325,7 +328,13 @@ func compare(obj1, obj2 interface{}, kind reflect.Kind) (CompareType, bool) { timeObj2 = obj2Value.Convert(timeType).Interface().(time.Time) } - return compare(timeObj1.UnixNano(), timeObj2.UnixNano(), reflect.Int64) + if timeObj1.Before(timeObj2) { + return compareLess, true + } + if timeObj1.Equal(timeObj2) { + return compareEqual, true + } + return compareGreater, true } case reflect.Slice: { @@ -345,7 +354,7 @@ func compare(obj1, obj2 interface{}, kind reflect.Kind) (CompareType, bool) { bytesObj2 = obj2Value.Convert(bytesType).Interface().([]byte) } - return CompareType(bytes.Compare(bytesObj1, bytesObj2)), true + return compareResult(bytes.Compare(bytesObj1, bytesObj2)), true } case reflect.Uintptr: { @@ -381,7 +390,7 @@ func Greater(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...interface if h, ok := t.(tHelper); ok { h.Helper() } - return compareTwoValues(t, e1, e2, []CompareType{compareGreater}, "\"%v\" is not greater than \"%v\"", msgAndArgs...) + return compareTwoValues(t, e1, e2, []compareResult{compareGreater}, "\"%v\" is not greater than \"%v\"", msgAndArgs...) } // GreaterOrEqual asserts that the first element is greater than or equal to the second @@ -394,7 +403,7 @@ func GreaterOrEqual(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...in if h, ok := t.(tHelper); ok { h.Helper() } - return compareTwoValues(t, e1, e2, []CompareType{compareGreater, compareEqual}, "\"%v\" is not greater than or equal to \"%v\"", msgAndArgs...) + return compareTwoValues(t, e1, e2, []compareResult{compareGreater, compareEqual}, "\"%v\" is not greater than or equal to \"%v\"", msgAndArgs...) } // Less asserts that the first element is less than the second @@ -406,7 +415,7 @@ func Less(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...interface{}) if h, ok := t.(tHelper); ok { h.Helper() } - return compareTwoValues(t, e1, e2, []CompareType{compareLess}, "\"%v\" is not less than \"%v\"", msgAndArgs...) + return compareTwoValues(t, e1, e2, []compareResult{compareLess}, "\"%v\" is not less than \"%v\"", msgAndArgs...) } // LessOrEqual asserts that the first element is less than or equal to the second @@ -419,7 +428,7 @@ func LessOrEqual(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...inter if h, ok := t.(tHelper); ok { h.Helper() } - return compareTwoValues(t, e1, e2, []CompareType{compareLess, compareEqual}, "\"%v\" is not less than or equal to \"%v\"", msgAndArgs...) + return compareTwoValues(t, e1, e2, []compareResult{compareLess, compareEqual}, "\"%v\" is not less than or equal to \"%v\"", msgAndArgs...) } // Positive asserts that the specified element is positive @@ -431,7 +440,7 @@ func Positive(t TestingT, e interface{}, msgAndArgs ...interface{}) bool { h.Helper() } zero := reflect.Zero(reflect.TypeOf(e)) - return compareTwoValues(t, e, zero.Interface(), []CompareType{compareGreater}, "\"%v\" is not positive", msgAndArgs...) + return compareTwoValues(t, e, zero.Interface(), []compareResult{compareGreater}, "\"%v\" is not positive", msgAndArgs...) } // Negative asserts that the specified element is negative @@ -443,10 +452,10 @@ func Negative(t TestingT, e interface{}, msgAndArgs ...interface{}) bool { h.Helper() } zero := reflect.Zero(reflect.TypeOf(e)) - return compareTwoValues(t, e, zero.Interface(), []CompareType{compareLess}, "\"%v\" is not negative", msgAndArgs...) + return compareTwoValues(t, e, zero.Interface(), []compareResult{compareLess}, "\"%v\" is not negative", msgAndArgs...) } -func compareTwoValues(t TestingT, e1 interface{}, e2 interface{}, allowedComparesResults []CompareType, failMessage string, msgAndArgs ...interface{}) bool { +func compareTwoValues(t TestingT, e1 interface{}, e2 interface{}, allowedComparesResults []compareResult, failMessage string, msgAndArgs ...interface{}) bool { if h, ok := t.(tHelper); ok { h.Helper() } @@ -469,7 +478,7 @@ func compareTwoValues(t TestingT, e1 interface{}, e2 interface{}, allowedCompare return true } -func containsValue(values []CompareType, value CompareType) bool { +func containsValue(values []compareResult, value compareResult) bool { for _, v := range values { if v == value { return true diff --git a/vendor/github.com/stretchr/testify/assert/assertion_format.go b/vendor/github.com/stretchr/testify/assert/assertion_format.go index 3ddab109..19063416 100644 --- a/vendor/github.com/stretchr/testify/assert/assertion_format.go +++ b/vendor/github.com/stretchr/testify/assert/assertion_format.go @@ -104,8 +104,8 @@ func EqualExportedValuesf(t TestingT, expected interface{}, actual interface{}, return EqualExportedValues(t, expected, actual, append([]interface{}{msg}, args...)...) } -// EqualValuesf asserts that two objects are equal or convertible to the same types -// and equal. +// EqualValuesf asserts that two objects are equal or convertible to the larger +// type and equal. // // assert.EqualValuesf(t, uint32(123), int32(123), "error message %s", "formatted") func EqualValuesf(t TestingT, expected interface{}, actual interface{}, msg string, args ...interface{}) bool { @@ -186,7 +186,7 @@ func Eventuallyf(t TestingT, condition func() bool, waitFor time.Duration, tick // assert.EventuallyWithTf(t, func(c *assert.CollectT, "error message %s", "formatted") { // // add assertions as needed; any assertion failure will fail the current tick // assert.True(c, externalValue, "expected 'externalValue' to be true") -// }, 1*time.Second, 10*time.Second, "external state has not changed to 'true'; still false") +// }, 10*time.Second, 1*time.Second, "external state has not changed to 'true'; still false") func EventuallyWithTf(t TestingT, condition func(collect *CollectT), waitFor time.Duration, tick time.Duration, msg string, args ...interface{}) bool { if h, ok := t.(tHelper); ok { h.Helper() @@ -568,6 +568,23 @@ func NotContainsf(t TestingT, s interface{}, contains interface{}, msg string, a return NotContains(t, s, contains, append([]interface{}{msg}, args...)...) } +// NotElementsMatchf asserts that the specified listA(array, slice...) is NOT equal to specified +// listB(array, slice...) ignoring the order of the elements. If there are duplicate elements, +// the number of appearances of each of them in both lists should not match. +// This is an inverse of ElementsMatch. +// +// assert.NotElementsMatchf(t, [1, 1, 2, 3], [1, 1, 2, 3], "error message %s", "formatted") -> false +// +// assert.NotElementsMatchf(t, [1, 1, 2, 3], [1, 2, 3], "error message %s", "formatted") -> true +// +// assert.NotElementsMatchf(t, [1, 2, 3], [1, 2, 4], "error message %s", "formatted") -> true +func NotElementsMatchf(t TestingT, listA interface{}, listB interface{}, msg string, args ...interface{}) bool { + if h, ok := t.(tHelper); ok { + h.Helper() + } + return NotElementsMatch(t, listA, listB, append([]interface{}{msg}, args...)...) +} + // NotEmptyf asserts that the specified object is NOT empty. I.e. not nil, "", false, 0 or either // a slice or a channel with len == 0. // @@ -604,7 +621,16 @@ func NotEqualValuesf(t TestingT, expected interface{}, actual interface{}, msg s return NotEqualValues(t, expected, actual, append([]interface{}{msg}, args...)...) } -// NotErrorIsf asserts that at none of the errors in err's chain matches target. +// NotErrorAsf asserts that none of the errors in err's chain matches target, +// but if so, sets target to that error value. +func NotErrorAsf(t TestingT, err error, target interface{}, msg string, args ...interface{}) bool { + if h, ok := t.(tHelper); ok { + h.Helper() + } + return NotErrorAs(t, err, target, append([]interface{}{msg}, args...)...) +} + +// NotErrorIsf asserts that none of the errors in err's chain matches target. // This is a wrapper for errors.Is. func NotErrorIsf(t TestingT, err error, target error, msg string, args ...interface{}) bool { if h, ok := t.(tHelper); ok { diff --git a/vendor/github.com/stretchr/testify/assert/assertion_forward.go b/vendor/github.com/stretchr/testify/assert/assertion_forward.go index a84e09bd..21629087 100644 --- a/vendor/github.com/stretchr/testify/assert/assertion_forward.go +++ b/vendor/github.com/stretchr/testify/assert/assertion_forward.go @@ -186,8 +186,8 @@ func (a *Assertions) EqualExportedValuesf(expected interface{}, actual interface return EqualExportedValuesf(a.t, expected, actual, msg, args...) } -// EqualValues asserts that two objects are equal or convertible to the same types -// and equal. +// EqualValues asserts that two objects are equal or convertible to the larger +// type and equal. // // a.EqualValues(uint32(123), int32(123)) func (a *Assertions) EqualValues(expected interface{}, actual interface{}, msgAndArgs ...interface{}) bool { @@ -197,8 +197,8 @@ func (a *Assertions) EqualValues(expected interface{}, actual interface{}, msgAn return EqualValues(a.t, expected, actual, msgAndArgs...) } -// EqualValuesf asserts that two objects are equal or convertible to the same types -// and equal. +// EqualValuesf asserts that two objects are equal or convertible to the larger +// type and equal. // // a.EqualValuesf(uint32(123), int32(123), "error message %s", "formatted") func (a *Assertions) EqualValuesf(expected interface{}, actual interface{}, msg string, args ...interface{}) bool { @@ -336,7 +336,7 @@ func (a *Assertions) Eventually(condition func() bool, waitFor time.Duration, ti // a.EventuallyWithT(func(c *assert.CollectT) { // // add assertions as needed; any assertion failure will fail the current tick // assert.True(c, externalValue, "expected 'externalValue' to be true") -// }, 1*time.Second, 10*time.Second, "external state has not changed to 'true'; still false") +// }, 10*time.Second, 1*time.Second, "external state has not changed to 'true'; still false") func (a *Assertions) EventuallyWithT(condition func(collect *CollectT), waitFor time.Duration, tick time.Duration, msgAndArgs ...interface{}) bool { if h, ok := a.t.(tHelper); ok { h.Helper() @@ -361,7 +361,7 @@ func (a *Assertions) EventuallyWithT(condition func(collect *CollectT), waitFor // a.EventuallyWithTf(func(c *assert.CollectT, "error message %s", "formatted") { // // add assertions as needed; any assertion failure will fail the current tick // assert.True(c, externalValue, "expected 'externalValue' to be true") -// }, 1*time.Second, 10*time.Second, "external state has not changed to 'true'; still false") +// }, 10*time.Second, 1*time.Second, "external state has not changed to 'true'; still false") func (a *Assertions) EventuallyWithTf(condition func(collect *CollectT), waitFor time.Duration, tick time.Duration, msg string, args ...interface{}) bool { if h, ok := a.t.(tHelper); ok { h.Helper() @@ -1128,6 +1128,40 @@ func (a *Assertions) NotContainsf(s interface{}, contains interface{}, msg strin return NotContainsf(a.t, s, contains, msg, args...) } +// NotElementsMatch asserts that the specified listA(array, slice...) is NOT equal to specified +// listB(array, slice...) ignoring the order of the elements. If there are duplicate elements, +// the number of appearances of each of them in both lists should not match. +// This is an inverse of ElementsMatch. +// +// a.NotElementsMatch([1, 1, 2, 3], [1, 1, 2, 3]) -> false +// +// a.NotElementsMatch([1, 1, 2, 3], [1, 2, 3]) -> true +// +// a.NotElementsMatch([1, 2, 3], [1, 2, 4]) -> true +func (a *Assertions) NotElementsMatch(listA interface{}, listB interface{}, msgAndArgs ...interface{}) bool { + if h, ok := a.t.(tHelper); ok { + h.Helper() + } + return NotElementsMatch(a.t, listA, listB, msgAndArgs...) +} + +// NotElementsMatchf asserts that the specified listA(array, slice...) is NOT equal to specified +// listB(array, slice...) ignoring the order of the elements. If there are duplicate elements, +// the number of appearances of each of them in both lists should not match. +// This is an inverse of ElementsMatch. +// +// a.NotElementsMatchf([1, 1, 2, 3], [1, 1, 2, 3], "error message %s", "formatted") -> false +// +// a.NotElementsMatchf([1, 1, 2, 3], [1, 2, 3], "error message %s", "formatted") -> true +// +// a.NotElementsMatchf([1, 2, 3], [1, 2, 4], "error message %s", "formatted") -> true +func (a *Assertions) NotElementsMatchf(listA interface{}, listB interface{}, msg string, args ...interface{}) bool { + if h, ok := a.t.(tHelper); ok { + h.Helper() + } + return NotElementsMatchf(a.t, listA, listB, msg, args...) +} + // NotEmpty asserts that the specified object is NOT empty. I.e. not nil, "", false, 0 or either // a slice or a channel with len == 0. // @@ -1200,7 +1234,25 @@ func (a *Assertions) NotEqualf(expected interface{}, actual interface{}, msg str return NotEqualf(a.t, expected, actual, msg, args...) } -// NotErrorIs asserts that at none of the errors in err's chain matches target. +// NotErrorAs asserts that none of the errors in err's chain matches target, +// but if so, sets target to that error value. +func (a *Assertions) NotErrorAs(err error, target interface{}, msgAndArgs ...interface{}) bool { + if h, ok := a.t.(tHelper); ok { + h.Helper() + } + return NotErrorAs(a.t, err, target, msgAndArgs...) +} + +// NotErrorAsf asserts that none of the errors in err's chain matches target, +// but if so, sets target to that error value. +func (a *Assertions) NotErrorAsf(err error, target interface{}, msg string, args ...interface{}) bool { + if h, ok := a.t.(tHelper); ok { + h.Helper() + } + return NotErrorAsf(a.t, err, target, msg, args...) +} + +// NotErrorIs asserts that none of the errors in err's chain matches target. // This is a wrapper for errors.Is. func (a *Assertions) NotErrorIs(err error, target error, msgAndArgs ...interface{}) bool { if h, ok := a.t.(tHelper); ok { @@ -1209,7 +1261,7 @@ func (a *Assertions) NotErrorIs(err error, target error, msgAndArgs ...interface return NotErrorIs(a.t, err, target, msgAndArgs...) } -// NotErrorIsf asserts that at none of the errors in err's chain matches target. +// NotErrorIsf asserts that none of the errors in err's chain matches target. // This is a wrapper for errors.Is. func (a *Assertions) NotErrorIsf(err error, target error, msg string, args ...interface{}) bool { if h, ok := a.t.(tHelper); ok { diff --git a/vendor/github.com/stretchr/testify/assert/assertion_order.go b/vendor/github.com/stretchr/testify/assert/assertion_order.go index 00df62a0..1d2f7182 100644 --- a/vendor/github.com/stretchr/testify/assert/assertion_order.go +++ b/vendor/github.com/stretchr/testify/assert/assertion_order.go @@ -6,7 +6,7 @@ import ( ) // isOrdered checks that collection contains orderable elements. -func isOrdered(t TestingT, object interface{}, allowedComparesResults []CompareType, failMessage string, msgAndArgs ...interface{}) bool { +func isOrdered(t TestingT, object interface{}, allowedComparesResults []compareResult, failMessage string, msgAndArgs ...interface{}) bool { objKind := reflect.TypeOf(object).Kind() if objKind != reflect.Slice && objKind != reflect.Array { return false @@ -50,7 +50,7 @@ func isOrdered(t TestingT, object interface{}, allowedComparesResults []CompareT // assert.IsIncreasing(t, []float{1, 2}) // assert.IsIncreasing(t, []string{"a", "b"}) func IsIncreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) bool { - return isOrdered(t, object, []CompareType{compareLess}, "\"%v\" is not less than \"%v\"", msgAndArgs...) + return isOrdered(t, object, []compareResult{compareLess}, "\"%v\" is not less than \"%v\"", msgAndArgs...) } // IsNonIncreasing asserts that the collection is not increasing @@ -59,7 +59,7 @@ func IsIncreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) boo // assert.IsNonIncreasing(t, []float{2, 1}) // assert.IsNonIncreasing(t, []string{"b", "a"}) func IsNonIncreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) bool { - return isOrdered(t, object, []CompareType{compareEqual, compareGreater}, "\"%v\" is not greater than or equal to \"%v\"", msgAndArgs...) + return isOrdered(t, object, []compareResult{compareEqual, compareGreater}, "\"%v\" is not greater than or equal to \"%v\"", msgAndArgs...) } // IsDecreasing asserts that the collection is decreasing @@ -68,7 +68,7 @@ func IsNonIncreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) // assert.IsDecreasing(t, []float{2, 1}) // assert.IsDecreasing(t, []string{"b", "a"}) func IsDecreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) bool { - return isOrdered(t, object, []CompareType{compareGreater}, "\"%v\" is not greater than \"%v\"", msgAndArgs...) + return isOrdered(t, object, []compareResult{compareGreater}, "\"%v\" is not greater than \"%v\"", msgAndArgs...) } // IsNonDecreasing asserts that the collection is not decreasing @@ -77,5 +77,5 @@ func IsDecreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) boo // assert.IsNonDecreasing(t, []float{1, 2}) // assert.IsNonDecreasing(t, []string{"a", "b"}) func IsNonDecreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) bool { - return isOrdered(t, object, []CompareType{compareLess, compareEqual}, "\"%v\" is not less than or equal to \"%v\"", msgAndArgs...) + return isOrdered(t, object, []compareResult{compareLess, compareEqual}, "\"%v\" is not less than or equal to \"%v\"", msgAndArgs...) } diff --git a/vendor/github.com/stretchr/testify/assert/assertions.go b/vendor/github.com/stretchr/testify/assert/assertions.go index 0b7570f2..4e91332b 100644 --- a/vendor/github.com/stretchr/testify/assert/assertions.go +++ b/vendor/github.com/stretchr/testify/assert/assertions.go @@ -19,7 +19,9 @@ import ( "github.com/davecgh/go-spew/spew" "github.com/pmezard/go-difflib/difflib" - "gopkg.in/yaml.v3" + + // Wrapper around gopkg.in/yaml.v3 + "github.com/stretchr/testify/assert/yaml" ) //go:generate sh -c "cd ../_codegen && go build && cd - && ../_codegen/_codegen -output-package=assert -template=assertion_format.go.tmpl" @@ -45,6 +47,10 @@ type BoolAssertionFunc func(TestingT, bool, ...interface{}) bool // for table driven tests. type ErrorAssertionFunc func(TestingT, error, ...interface{}) bool +// PanicAssertionFunc is a common function prototype when validating a panic value. Can be useful +// for table driven tests. +type PanicAssertionFunc = func(t TestingT, f PanicTestFunc, msgAndArgs ...interface{}) bool + // Comparison is a custom function that returns true on success and false on failure type Comparison func() (success bool) @@ -496,7 +502,13 @@ func Same(t TestingT, expected, actual interface{}, msgAndArgs ...interface{}) b h.Helper() } - if !samePointers(expected, actual) { + same, ok := samePointers(expected, actual) + if !ok { + return Fail(t, "Both arguments must be pointers", msgAndArgs...) + } + + if !same { + // both are pointers but not the same type & pointing to the same address return Fail(t, fmt.Sprintf("Not same: \n"+ "expected: %p %#v\n"+ "actual : %p %#v", expected, expected, actual, actual), msgAndArgs...) @@ -516,7 +528,13 @@ func NotSame(t TestingT, expected, actual interface{}, msgAndArgs ...interface{} h.Helper() } - if samePointers(expected, actual) { + same, ok := samePointers(expected, actual) + if !ok { + //fails when the arguments are not pointers + return !(Fail(t, "Both arguments must be pointers", msgAndArgs...)) + } + + if same { return Fail(t, fmt.Sprintf( "Expected and actual point to the same object: %p %#v", expected, expected), msgAndArgs...) @@ -524,21 +542,23 @@ func NotSame(t TestingT, expected, actual interface{}, msgAndArgs ...interface{} return true } -// samePointers compares two generic interface objects and returns whether -// they point to the same object -func samePointers(first, second interface{}) bool { +// samePointers checks if two generic interface objects are pointers of the same +// type pointing to the same object. It returns two values: same indicating if +// they are the same type and point to the same object, and ok indicating that +// both inputs are pointers. +func samePointers(first, second interface{}) (same bool, ok bool) { firstPtr, secondPtr := reflect.ValueOf(first), reflect.ValueOf(second) if firstPtr.Kind() != reflect.Ptr || secondPtr.Kind() != reflect.Ptr { - return false + return false, false //not both are pointers } firstType, secondType := reflect.TypeOf(first), reflect.TypeOf(second) if firstType != secondType { - return false + return false, true // both are pointers, but of different types } // compare pointer addresses - return first == second + return first == second, true } // formatUnequalValues takes two values of arbitrary types and returns string @@ -572,8 +592,8 @@ func truncatingFormat(data interface{}) string { return value } -// EqualValues asserts that two objects are equal or convertible to the same types -// and equal. +// EqualValues asserts that two objects are equal or convertible to the larger +// type and equal. // // assert.EqualValues(t, uint32(123), int32(123)) func EqualValues(t TestingT, expected, actual interface{}, msgAndArgs ...interface{}) bool { @@ -615,21 +635,6 @@ func EqualExportedValues(t TestingT, expected, actual interface{}, msgAndArgs .. return Fail(t, fmt.Sprintf("Types expected to match exactly\n\t%v != %v", aType, bType), msgAndArgs...) } - if aType.Kind() == reflect.Ptr { - aType = aType.Elem() - } - if bType.Kind() == reflect.Ptr { - bType = bType.Elem() - } - - if aType.Kind() != reflect.Struct { - return Fail(t, fmt.Sprintf("Types expected to both be struct or pointer to struct \n\t%v != %v", aType.Kind(), reflect.Struct), msgAndArgs...) - } - - if bType.Kind() != reflect.Struct { - return Fail(t, fmt.Sprintf("Types expected to both be struct or pointer to struct \n\t%v != %v", bType.Kind(), reflect.Struct), msgAndArgs...) - } - expected = copyExportedFields(expected) actual = copyExportedFields(actual) @@ -1170,6 +1175,39 @@ func formatListDiff(listA, listB interface{}, extraA, extraB []interface{}) stri return msg.String() } +// NotElementsMatch asserts that the specified listA(array, slice...) is NOT equal to specified +// listB(array, slice...) ignoring the order of the elements. If there are duplicate elements, +// the number of appearances of each of them in both lists should not match. +// This is an inverse of ElementsMatch. +// +// assert.NotElementsMatch(t, [1, 1, 2, 3], [1, 1, 2, 3]) -> false +// +// assert.NotElementsMatch(t, [1, 1, 2, 3], [1, 2, 3]) -> true +// +// assert.NotElementsMatch(t, [1, 2, 3], [1, 2, 4]) -> true +func NotElementsMatch(t TestingT, listA, listB interface{}, msgAndArgs ...interface{}) (ok bool) { + if h, ok := t.(tHelper); ok { + h.Helper() + } + if isEmpty(listA) && isEmpty(listB) { + return Fail(t, "listA and listB contain the same elements", msgAndArgs) + } + + if !isList(t, listA, msgAndArgs...) { + return Fail(t, "listA is not a list type", msgAndArgs...) + } + if !isList(t, listB, msgAndArgs...) { + return Fail(t, "listB is not a list type", msgAndArgs...) + } + + extraA, extraB := diffLists(listA, listB) + if len(extraA) == 0 && len(extraB) == 0 { + return Fail(t, "listA and listB contain the same elements", msgAndArgs) + } + + return true +} + // Condition uses a Comparison to assert a complex condition. func Condition(t TestingT, comp Comparison, msgAndArgs ...interface{}) bool { if h, ok := t.(tHelper); ok { @@ -1488,6 +1526,9 @@ func InEpsilon(t TestingT, expected, actual interface{}, epsilon float64, msgAnd if err != nil { return Fail(t, err.Error(), msgAndArgs...) } + if math.IsNaN(actualEpsilon) { + return Fail(t, "relative error is NaN", msgAndArgs...) + } if actualEpsilon > epsilon { return Fail(t, fmt.Sprintf("Relative error is too high: %#v (expected)\n"+ " < %#v (actual)", epsilon, actualEpsilon), msgAndArgs...) @@ -1611,7 +1652,6 @@ func ErrorContains(t TestingT, theError error, contains string, msgAndArgs ...in // matchRegexp return true if a specified regexp matches a string. func matchRegexp(rx interface{}, str interface{}) bool { - var r *regexp.Regexp if rr, ok := rx.(*regexp.Regexp); ok { r = rr @@ -1619,7 +1659,14 @@ func matchRegexp(rx interface{}, str interface{}) bool { r = regexp.MustCompile(fmt.Sprint(rx)) } - return (r.FindStringIndex(fmt.Sprint(str)) != nil) + switch v := str.(type) { + case []byte: + return r.Match(v) + case string: + return r.MatchString(v) + default: + return r.MatchString(fmt.Sprint(v)) + } } @@ -1872,7 +1919,7 @@ var spewConfigStringerEnabled = spew.ConfigState{ MaxDepth: 10, } -type tHelper interface { +type tHelper = interface { Helper() } @@ -1911,6 +1958,9 @@ func Eventually(t TestingT, condition func() bool, waitFor time.Duration, tick t // CollectT implements the TestingT interface and collects all errors. type CollectT struct { + // A slice of errors. Non-nil slice denotes a failure. + // If it's non-nil but len(c.errors) == 0, this is also a failure + // obtained by direct c.FailNow() call. errors []error } @@ -1919,9 +1969,10 @@ func (c *CollectT) Errorf(format string, args ...interface{}) { c.errors = append(c.errors, fmt.Errorf(format, args...)) } -// FailNow panics. -func (*CollectT) FailNow() { - panic("Assertion failed") +// FailNow stops execution by calling runtime.Goexit. +func (c *CollectT) FailNow() { + c.fail() + runtime.Goexit() } // Deprecated: That was a method for internal usage that should not have been published. Now just panics. @@ -1934,6 +1985,16 @@ func (*CollectT) Copy(TestingT) { panic("Copy() is deprecated") } +func (c *CollectT) fail() { + if !c.failed() { + c.errors = []error{} // Make it non-nil to mark a failure. + } +} + +func (c *CollectT) failed() bool { + return c.errors != nil +} + // EventuallyWithT asserts that given condition will be met in waitFor time, // periodically checking target function each tick. In contrast to Eventually, // it supplies a CollectT to the condition function, so that the condition @@ -1951,14 +2012,14 @@ func (*CollectT) Copy(TestingT) { // assert.EventuallyWithT(t, func(c *assert.CollectT) { // // add assertions as needed; any assertion failure will fail the current tick // assert.True(c, externalValue, "expected 'externalValue' to be true") -// }, 1*time.Second, 10*time.Second, "external state has not changed to 'true'; still false") +// }, 10*time.Second, 1*time.Second, "external state has not changed to 'true'; still false") func EventuallyWithT(t TestingT, condition func(collect *CollectT), waitFor time.Duration, tick time.Duration, msgAndArgs ...interface{}) bool { if h, ok := t.(tHelper); ok { h.Helper() } var lastFinishedTickErrs []error - ch := make(chan []error, 1) + ch := make(chan *CollectT, 1) timer := time.NewTimer(waitFor) defer timer.Stop() @@ -1978,16 +2039,16 @@ func EventuallyWithT(t TestingT, condition func(collect *CollectT), waitFor time go func() { collect := new(CollectT) defer func() { - ch <- collect.errors + ch <- collect }() condition(collect) }() - case errs := <-ch: - if len(errs) == 0 { + case collect := <-ch: + if !collect.failed() { return true } // Keep the errors from the last ended condition, so that they can be copied to t if timeout is reached. - lastFinishedTickErrs = errs + lastFinishedTickErrs = collect.errors tick = ticker.C } } @@ -2049,7 +2110,7 @@ func ErrorIs(t TestingT, err, target error, msgAndArgs ...interface{}) bool { ), msgAndArgs...) } -// NotErrorIs asserts that at none of the errors in err's chain matches target. +// NotErrorIs asserts that none of the errors in err's chain matches target. // This is a wrapper for errors.Is. func NotErrorIs(t TestingT, err, target error, msgAndArgs ...interface{}) bool { if h, ok := t.(tHelper); ok { @@ -2090,6 +2151,24 @@ func ErrorAs(t TestingT, err error, target interface{}, msgAndArgs ...interface{ ), msgAndArgs...) } +// NotErrorAs asserts that none of the errors in err's chain matches target, +// but if so, sets target to that error value. +func NotErrorAs(t TestingT, err error, target interface{}, msgAndArgs ...interface{}) bool { + if h, ok := t.(tHelper); ok { + h.Helper() + } + if !errors.As(err, target) { + return true + } + + chain := buildErrorChainString(err) + + return Fail(t, fmt.Sprintf("Target error should not be in err chain:\n"+ + "found: %q\n"+ + "in chain: %s", target, chain, + ), msgAndArgs...) +} + func buildErrorChainString(err error) string { if err == nil { return "" diff --git a/vendor/github.com/stretchr/testify/assert/yaml/yaml_custom.go b/vendor/github.com/stretchr/testify/assert/yaml/yaml_custom.go new file mode 100644 index 00000000..baa0cc7d --- /dev/null +++ b/vendor/github.com/stretchr/testify/assert/yaml/yaml_custom.go @@ -0,0 +1,25 @@ +//go:build testify_yaml_custom && !testify_yaml_fail && !testify_yaml_default +// +build testify_yaml_custom,!testify_yaml_fail,!testify_yaml_default + +// Package yaml is an implementation of YAML functions that calls a pluggable implementation. +// +// This implementation is selected with the testify_yaml_custom build tag. +// +// go test -tags testify_yaml_custom +// +// This implementation can be used at build time to replace the default implementation +// to avoid linking with [gopkg.in/yaml.v3]. +// +// In your test package: +// +// import assertYaml "github.com/stretchr/testify/assert/yaml" +// +// func init() { +// assertYaml.Unmarshal = func (in []byte, out interface{}) error { +// // ... +// return nil +// } +// } +package yaml + +var Unmarshal func(in []byte, out interface{}) error diff --git a/vendor/github.com/stretchr/testify/assert/yaml/yaml_default.go b/vendor/github.com/stretchr/testify/assert/yaml/yaml_default.go new file mode 100644 index 00000000..b83c6cf6 --- /dev/null +++ b/vendor/github.com/stretchr/testify/assert/yaml/yaml_default.go @@ -0,0 +1,37 @@ +//go:build !testify_yaml_fail && !testify_yaml_custom +// +build !testify_yaml_fail,!testify_yaml_custom + +// Package yaml is just an indirection to handle YAML deserialization. +// +// This package is just an indirection that allows the builder to override the +// indirection with an alternative implementation of this package that uses +// another implementation of YAML deserialization. This allows to not either not +// use YAML deserialization at all, or to use another implementation than +// [gopkg.in/yaml.v3] (for example for license compatibility reasons, see [PR #1120]). +// +// Alternative implementations are selected using build tags: +// +// - testify_yaml_fail: [Unmarshal] always fails with an error +// - testify_yaml_custom: [Unmarshal] is a variable. Caller must initialize it +// before calling any of [github.com/stretchr/testify/assert.YAMLEq] or +// [github.com/stretchr/testify/assert.YAMLEqf]. +// +// Usage: +// +// go test -tags testify_yaml_fail +// +// You can check with "go list" which implementation is linked: +// +// go list -f '{{.Imports}}' github.com/stretchr/testify/assert/yaml +// go list -tags testify_yaml_fail -f '{{.Imports}}' github.com/stretchr/testify/assert/yaml +// go list -tags testify_yaml_custom -f '{{.Imports}}' github.com/stretchr/testify/assert/yaml +// +// [PR #1120]: https://github.com/stretchr/testify/pull/1120 +package yaml + +import goyaml "gopkg.in/yaml.v3" + +// Unmarshal is just a wrapper of [gopkg.in/yaml.v3.Unmarshal]. +func Unmarshal(in []byte, out interface{}) error { + return goyaml.Unmarshal(in, out) +} diff --git a/vendor/github.com/stretchr/testify/assert/yaml/yaml_fail.go b/vendor/github.com/stretchr/testify/assert/yaml/yaml_fail.go new file mode 100644 index 00000000..e78f7dfe --- /dev/null +++ b/vendor/github.com/stretchr/testify/assert/yaml/yaml_fail.go @@ -0,0 +1,18 @@ +//go:build testify_yaml_fail && !testify_yaml_custom && !testify_yaml_default +// +build testify_yaml_fail,!testify_yaml_custom,!testify_yaml_default + +// Package yaml is an implementation of YAML functions that always fail. +// +// This implementation can be used at build time to replace the default implementation +// to avoid linking with [gopkg.in/yaml.v3]: +// +// go test -tags testify_yaml_fail +package yaml + +import "errors" + +var errNotImplemented = errors.New("YAML functions are not available (see https://pkg.go.dev/github.com/stretchr/testify/assert/yaml)") + +func Unmarshal([]byte, interface{}) error { + return errNotImplemented +} diff --git a/vendor/github.com/stretchr/testify/mock/mock.go b/vendor/github.com/stretchr/testify/mock/mock.go index 213bde2e..eb5682df 100644 --- a/vendor/github.com/stretchr/testify/mock/mock.go +++ b/vendor/github.com/stretchr/testify/mock/mock.go @@ -80,12 +80,12 @@ type Call struct { requires []*Call } -func newCall(parent *Mock, methodName string, callerInfo []string, methodArguments ...interface{}) *Call { +func newCall(parent *Mock, methodName string, callerInfo []string, methodArguments Arguments, returnArguments Arguments) *Call { return &Call{ Parent: parent, Method: methodName, Arguments: methodArguments, - ReturnArguments: make([]interface{}, 0), + ReturnArguments: returnArguments, callerInfo: callerInfo, Repeatability: 0, WaitFor: nil, @@ -256,7 +256,7 @@ func (c *Call) Unset() *Call { // calls have been called as expected. The referenced calls may be from the // same mock instance and/or other mock instances. // -// Mock.On("Do").Return(nil).Notbefore( +// Mock.On("Do").Return(nil).NotBefore( // Mock.On("Init").Return(nil) // ) func (c *Call) NotBefore(calls ...*Call) *Call { @@ -273,6 +273,20 @@ func (c *Call) NotBefore(calls ...*Call) *Call { return c } +// InOrder defines the order in which the calls should be made +// +// For example: +// +// InOrder( +// Mock.On("init").Return(nil), +// Mock.On("Do").Return(nil), +// ) +func InOrder(calls ...*Call) { + for i := 1; i < len(calls); i++ { + calls[i].NotBefore(calls[i-1]) + } +} + // Mock is the workhorse used to track activity on another object. // For an example of its usage, refer to the "Example Usage" section at the top // of this document. @@ -351,7 +365,8 @@ func (m *Mock) On(methodName string, arguments ...interface{}) *Call { m.mutex.Lock() defer m.mutex.Unlock() - c := newCall(m, methodName, assert.CallerInfo(), arguments...) + + c := newCall(m, methodName, assert.CallerInfo(), arguments, make([]interface{}, 0)) m.ExpectedCalls = append(m.ExpectedCalls, c) return c } @@ -491,11 +506,12 @@ func (m *Mock) MethodCalled(methodName string, arguments ...interface{}) Argumen m.mutex.Unlock() if closestCall != nil { - m.fail("\n\nmock: Unexpected Method Call\n-----------------------------\n\n%s\n\nThe closest call I have is: \n\n%s\n\n%s\nDiff: %s", + m.fail("\n\nmock: Unexpected Method Call\n-----------------------------\n\n%s\n\nThe closest call I have is: \n\n%s\n\n%s\nDiff: %s\nat: %s\n", callString(methodName, arguments, true), callString(methodName, closestCall.Arguments, true), diffArguments(closestCall.Arguments, arguments), strings.TrimSpace(mismatch), + assert.CallerInfo(), ) } else { m.fail("\nassert: mock: I don't know what to return because the method call was unexpected.\n\tEither do Mock.On(\"%s\").Return(...) first, or remove the %s() call.\n\tThis method was unexpected:\n\t\t%s\n\tat: %s", methodName, methodName, callString(methodName, arguments, true), assert.CallerInfo()) @@ -529,7 +545,7 @@ func (m *Mock) MethodCalled(methodName string, arguments ...interface{}) Argumen call.totalCalls++ // add the call - m.Calls = append(m.Calls, *newCall(m, methodName, assert.CallerInfo(), arguments...)) + m.Calls = append(m.Calls, *newCall(m, methodName, assert.CallerInfo(), arguments, call.ReturnArguments)) m.mutex.Unlock() // block if specified @@ -764,9 +780,17 @@ const ( ) // AnythingOfTypeArgument contains the type of an argument -// for use when type checking. Used in Diff and Assert. +// for use when type checking. Used in [Arguments.Diff] and [Arguments.Assert]. // -// Deprecated: this is an implementation detail that must not be used. Use [AnythingOfType] instead. +// Deprecated: this is an implementation detail that must not be used. Use the [AnythingOfType] constructor instead, example: +// +// m.On("Do", mock.AnythingOfType("string")) +// +// All explicit type declarations can be replaced with interface{} as is expected by [Mock.On], example: +// +// func anyString interface{} { +// return mock.AnythingOfType("string") +// } type AnythingOfTypeArgument = anythingOfTypeArgument // anythingOfTypeArgument is a string that contains the type of an argument @@ -780,53 +804,54 @@ type anythingOfTypeArgument string // // For example: // -// Assert(t, AnythingOfType("string"), AnythingOfType("int")) +// args.Assert(t, AnythingOfType("string"), AnythingOfType("int")) func AnythingOfType(t string) AnythingOfTypeArgument { return anythingOfTypeArgument(t) } // IsTypeArgument is a struct that contains the type of an argument -// for use when type checking. This is an alternative to AnythingOfType. -// Used in Diff and Assert. +// for use when type checking. This is an alternative to [AnythingOfType]. +// Used in [Arguments.Diff] and [Arguments.Assert]. type IsTypeArgument struct { t reflect.Type } // IsType returns an IsTypeArgument object containing the type to check for. // You can provide a zero-value of the type to check. This is an -// alternative to AnythingOfType. Used in Diff and Assert. +// alternative to [AnythingOfType]. Used in [Arguments.Diff] and [Arguments.Assert]. // // For example: -// Assert(t, IsType(""), IsType(0)) +// +// args.Assert(t, IsType(""), IsType(0)) func IsType(t interface{}) *IsTypeArgument { return &IsTypeArgument{t: reflect.TypeOf(t)} } -// FunctionalOptionsArgument is a struct that contains the type and value of an functional option argument -// for use when type checking. +// FunctionalOptionsArgument contains a list of functional options arguments +// expected for use when matching a list of arguments. type FunctionalOptionsArgument struct { - value interface{} + values []interface{} } // String returns the string representation of FunctionalOptionsArgument func (f *FunctionalOptionsArgument) String() string { var name string - tValue := reflect.ValueOf(f.value) - if tValue.Len() > 0 { - name = "[]" + reflect.TypeOf(tValue.Index(0).Interface()).String() + if len(f.values) > 0 { + name = "[]" + reflect.TypeOf(f.values[0]).String() } - return strings.Replace(fmt.Sprintf("%#v", f.value), "[]interface {}", name, 1) + return strings.Replace(fmt.Sprintf("%#v", f.values), "[]interface {}", name, 1) } -// FunctionalOptions returns an FunctionalOptionsArgument object containing the functional option type -// and the values to check of +// FunctionalOptions returns an [FunctionalOptionsArgument] object containing +// the expected functional-options to check for. // // For example: -// Assert(t, FunctionalOptions("[]foo.FunctionalOption", foo.Opt1(), foo.Opt2())) -func FunctionalOptions(value ...interface{}) *FunctionalOptionsArgument { +// +// args.Assert(t, FunctionalOptions(foo.Opt1("strValue"), foo.Opt2(613))) +func FunctionalOptions(values ...interface{}) *FunctionalOptionsArgument { return &FunctionalOptionsArgument{ - value: value, + values: values, } } @@ -873,10 +898,11 @@ func (f argumentMatcher) String() string { // and false otherwise. // // Example: -// m.On("Do", MatchedBy(func(req *http.Request) bool { return req.Host == "example.com" })) // -// |fn|, must be a function accepting a single argument (of the expected type) -// which returns a bool. If |fn| doesn't match the required signature, +// m.On("Do", MatchedBy(func(req *http.Request) bool { return req.Host == "example.com" })) +// +// fn must be a function accepting a single argument (of the expected type) +// which returns a bool. If fn doesn't match the required signature, // MatchedBy() panics. func MatchedBy(fn interface{}) argumentMatcher { fnType := reflect.TypeOf(fn) @@ -979,20 +1005,17 @@ func (args Arguments) Diff(objects []interface{}) (string, int) { output = fmt.Sprintf("%s\t%d: FAIL: type %s != type %s - %s\n", output, i, expected.t.Name(), actualT.Name(), actualFmt) } case *FunctionalOptionsArgument: - t := expected.value - var name string - tValue := reflect.ValueOf(t) - if tValue.Len() > 0 { - name = "[]" + reflect.TypeOf(tValue.Index(0).Interface()).String() + if len(expected.values) > 0 { + name = "[]" + reflect.TypeOf(expected.values[0]).String() } - tName := reflect.TypeOf(t).Name() - if name != reflect.TypeOf(actual).String() && tValue.Len() != 0 { + const tName = "[]interface{}" + if name != reflect.TypeOf(actual).String() && len(expected.values) != 0 { differences++ output = fmt.Sprintf("%s\t%d: FAIL: type %s != type %s - %s\n", output, i, tName, reflect.TypeOf(actual).Name(), actualFmt) } else { - if ef, af := assertOpts(t, actual); ef == "" && af == "" { + if ef, af := assertOpts(expected.values, actual); ef == "" && af == "" { // match output = fmt.Sprintf("%s\t%d: PASS: %s == %s\n", output, i, tName, tName) } else { @@ -1092,7 +1115,7 @@ func (args Arguments) Error(index int) error { return nil } if s, ok = obj.(error); !ok { - panic(fmt.Sprintf("assert: arguments: Error(%d) failed because object wasn't correct type: %v", index, args.Get(index))) + panic(fmt.Sprintf("assert: arguments: Error(%d) failed because object wasn't correct type: %v", index, obj)) } return s } @@ -1181,32 +1204,38 @@ type tHelper interface { func assertOpts(expected, actual interface{}) (expectedFmt, actualFmt string) { expectedOpts := reflect.ValueOf(expected) actualOpts := reflect.ValueOf(actual) + + var expectedFuncs []*runtime.Func var expectedNames []string for i := 0; i < expectedOpts.Len(); i++ { - expectedNames = append(expectedNames, funcName(expectedOpts.Index(i).Interface())) + f := runtimeFunc(expectedOpts.Index(i).Interface()) + expectedFuncs = append(expectedFuncs, f) + expectedNames = append(expectedNames, funcName(f)) } + var actualFuncs []*runtime.Func var actualNames []string for i := 0; i < actualOpts.Len(); i++ { - actualNames = append(actualNames, funcName(actualOpts.Index(i).Interface())) + f := runtimeFunc(actualOpts.Index(i).Interface()) + actualFuncs = append(actualFuncs, f) + actualNames = append(actualNames, funcName(f)) } - if !assert.ObjectsAreEqual(expectedNames, actualNames) { + + if expectedOpts.Len() != actualOpts.Len() { expectedFmt = fmt.Sprintf("%v", expectedNames) actualFmt = fmt.Sprintf("%v", actualNames) return } for i := 0; i < expectedOpts.Len(); i++ { - expectedOpt := expectedOpts.Index(i).Interface() - actualOpt := actualOpts.Index(i).Interface() - - expectedFunc := expectedNames[i] - actualFunc := actualNames[i] - if expectedFunc != actualFunc { - expectedFmt = expectedFunc - actualFmt = actualFunc + if !isFuncSame(expectedFuncs[i], actualFuncs[i]) { + expectedFmt = expectedNames[i] + actualFmt = actualNames[i] return } + expectedOpt := expectedOpts.Index(i).Interface() + actualOpt := actualOpts.Index(i).Interface() + ot := reflect.TypeOf(expectedOpt) var expectedValues []reflect.Value var actualValues []reflect.Value @@ -1224,9 +1253,9 @@ func assertOpts(expected, actual interface{}) (expectedFmt, actualFmt string) { reflect.ValueOf(actualOpt).Call(actualValues) for i := 0; i < ot.NumIn(); i++ { - if !assert.ObjectsAreEqual(expectedValues[i].Interface(), actualValues[i].Interface()) { - expectedFmt = fmt.Sprintf("%s %+v", expectedNames[i], expectedValues[i].Interface()) - actualFmt = fmt.Sprintf("%s %+v", expectedNames[i], actualValues[i].Interface()) + if expectedArg, actualArg := expectedValues[i].Interface(), actualValues[i].Interface(); !assert.ObjectsAreEqual(expectedArg, actualArg) { + expectedFmt = fmt.Sprintf("%s(%T) -> %#v", expectedNames[i], expectedArg, expectedArg) + actualFmt = fmt.Sprintf("%s(%T) -> %#v", expectedNames[i], actualArg, actualArg) return } } @@ -1235,7 +1264,25 @@ func assertOpts(expected, actual interface{}) (expectedFmt, actualFmt string) { return "", "" } -func funcName(opt interface{}) string { - n := runtime.FuncForPC(reflect.ValueOf(opt).Pointer()).Name() - return strings.TrimSuffix(path.Base(n), path.Ext(n)) +func runtimeFunc(opt interface{}) *runtime.Func { + return runtime.FuncForPC(reflect.ValueOf(opt).Pointer()) +} + +func funcName(f *runtime.Func) string { + name := f.Name() + trimmed := strings.TrimSuffix(path.Base(name), path.Ext(name)) + splitted := strings.Split(trimmed, ".") + + if len(splitted) == 0 { + return trimmed + } + + return splitted[len(splitted)-1] +} + +func isFuncSame(f1, f2 *runtime.Func) bool { + f1File, f1Loc := f1.FileLine(f1.Entry()) + f2File, f2Loc := f2.FileLine(f2.Entry()) + + return f1File == f2File && f1Loc == f2Loc } diff --git a/vendor/github.com/stretchr/testify/require/require.go b/vendor/github.com/stretchr/testify/require/require.go index 506a82f8..d8921950 100644 --- a/vendor/github.com/stretchr/testify/require/require.go +++ b/vendor/github.com/stretchr/testify/require/require.go @@ -34,9 +34,9 @@ func Conditionf(t TestingT, comp assert.Comparison, msg string, args ...interfac // Contains asserts that the specified string, list(array, slice...) or map contains the // specified substring or element. // -// assert.Contains(t, "Hello World", "World") -// assert.Contains(t, ["Hello", "World"], "World") -// assert.Contains(t, {"Hello": "World"}, "Hello") +// require.Contains(t, "Hello World", "World") +// require.Contains(t, ["Hello", "World"], "World") +// require.Contains(t, {"Hello": "World"}, "Hello") func Contains(t TestingT, s interface{}, contains interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -50,9 +50,9 @@ func Contains(t TestingT, s interface{}, contains interface{}, msgAndArgs ...int // Containsf asserts that the specified string, list(array, slice...) or map contains the // specified substring or element. // -// assert.Containsf(t, "Hello World", "World", "error message %s", "formatted") -// assert.Containsf(t, ["Hello", "World"], "World", "error message %s", "formatted") -// assert.Containsf(t, {"Hello": "World"}, "Hello", "error message %s", "formatted") +// require.Containsf(t, "Hello World", "World", "error message %s", "formatted") +// require.Containsf(t, ["Hello", "World"], "World", "error message %s", "formatted") +// require.Containsf(t, {"Hello": "World"}, "Hello", "error message %s", "formatted") func Containsf(t TestingT, s interface{}, contains interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -91,7 +91,7 @@ func DirExistsf(t TestingT, path string, msg string, args ...interface{}) { // listB(array, slice...) ignoring the order of the elements. If there are duplicate elements, // the number of appearances of each of them in both lists should match. // -// assert.ElementsMatch(t, [1, 3, 2, 3], [1, 3, 3, 2]) +// require.ElementsMatch(t, [1, 3, 2, 3], [1, 3, 3, 2]) func ElementsMatch(t TestingT, listA interface{}, listB interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -106,7 +106,7 @@ func ElementsMatch(t TestingT, listA interface{}, listB interface{}, msgAndArgs // listB(array, slice...) ignoring the order of the elements. If there are duplicate elements, // the number of appearances of each of them in both lists should match. // -// assert.ElementsMatchf(t, [1, 3, 2, 3], [1, 3, 3, 2], "error message %s", "formatted") +// require.ElementsMatchf(t, [1, 3, 2, 3], [1, 3, 3, 2], "error message %s", "formatted") func ElementsMatchf(t TestingT, listA interface{}, listB interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -120,7 +120,7 @@ func ElementsMatchf(t TestingT, listA interface{}, listB interface{}, msg string // Empty asserts that the specified object is empty. I.e. nil, "", false, 0 or either // a slice or a channel with len == 0. // -// assert.Empty(t, obj) +// require.Empty(t, obj) func Empty(t TestingT, object interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -134,7 +134,7 @@ func Empty(t TestingT, object interface{}, msgAndArgs ...interface{}) { // Emptyf asserts that the specified object is empty. I.e. nil, "", false, 0 or either // a slice or a channel with len == 0. // -// assert.Emptyf(t, obj, "error message %s", "formatted") +// require.Emptyf(t, obj, "error message %s", "formatted") func Emptyf(t TestingT, object interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -147,7 +147,7 @@ func Emptyf(t TestingT, object interface{}, msg string, args ...interface{}) { // Equal asserts that two objects are equal. // -// assert.Equal(t, 123, 123) +// require.Equal(t, 123, 123) // // Pointer variable equality is determined based on the equality of the // referenced values (as opposed to the memory addresses). Function equality @@ -166,7 +166,7 @@ func Equal(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...i // and that it is equal to the provided error. // // actualObj, err := SomeFunction() -// assert.EqualError(t, err, expectedErrorString) +// require.EqualError(t, err, expectedErrorString) func EqualError(t TestingT, theError error, errString string, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -181,7 +181,7 @@ func EqualError(t TestingT, theError error, errString string, msgAndArgs ...inte // and that it is equal to the provided error. // // actualObj, err := SomeFunction() -// assert.EqualErrorf(t, err, expectedErrorString, "error message %s", "formatted") +// require.EqualErrorf(t, err, expectedErrorString, "error message %s", "formatted") func EqualErrorf(t TestingT, theError error, errString string, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -200,8 +200,8 @@ func EqualErrorf(t TestingT, theError error, errString string, msg string, args // Exported int // notExported int // } -// assert.EqualExportedValues(t, S{1, 2}, S{1, 3}) => true -// assert.EqualExportedValues(t, S{1, 2}, S{2, 3}) => false +// require.EqualExportedValues(t, S{1, 2}, S{1, 3}) => true +// require.EqualExportedValues(t, S{1, 2}, S{2, 3}) => false func EqualExportedValues(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -220,8 +220,8 @@ func EqualExportedValues(t TestingT, expected interface{}, actual interface{}, m // Exported int // notExported int // } -// assert.EqualExportedValuesf(t, S{1, 2}, S{1, 3}, "error message %s", "formatted") => true -// assert.EqualExportedValuesf(t, S{1, 2}, S{2, 3}, "error message %s", "formatted") => false +// require.EqualExportedValuesf(t, S{1, 2}, S{1, 3}, "error message %s", "formatted") => true +// require.EqualExportedValuesf(t, S{1, 2}, S{2, 3}, "error message %s", "formatted") => false func EqualExportedValuesf(t TestingT, expected interface{}, actual interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -232,10 +232,10 @@ func EqualExportedValuesf(t TestingT, expected interface{}, actual interface{}, t.FailNow() } -// EqualValues asserts that two objects are equal or convertible to the same types -// and equal. +// EqualValues asserts that two objects are equal or convertible to the larger +// type and equal. // -// assert.EqualValues(t, uint32(123), int32(123)) +// require.EqualValues(t, uint32(123), int32(123)) func EqualValues(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -246,10 +246,10 @@ func EqualValues(t TestingT, expected interface{}, actual interface{}, msgAndArg t.FailNow() } -// EqualValuesf asserts that two objects are equal or convertible to the same types -// and equal. +// EqualValuesf asserts that two objects are equal or convertible to the larger +// type and equal. // -// assert.EqualValuesf(t, uint32(123), int32(123), "error message %s", "formatted") +// require.EqualValuesf(t, uint32(123), int32(123), "error message %s", "formatted") func EqualValuesf(t TestingT, expected interface{}, actual interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -262,7 +262,7 @@ func EqualValuesf(t TestingT, expected interface{}, actual interface{}, msg stri // Equalf asserts that two objects are equal. // -// assert.Equalf(t, 123, 123, "error message %s", "formatted") +// require.Equalf(t, 123, 123, "error message %s", "formatted") // // Pointer variable equality is determined based on the equality of the // referenced values (as opposed to the memory addresses). Function equality @@ -280,8 +280,8 @@ func Equalf(t TestingT, expected interface{}, actual interface{}, msg string, ar // Error asserts that a function returned an error (i.e. not `nil`). // // actualObj, err := SomeFunction() -// if assert.Error(t, err) { -// assert.Equal(t, expectedError, err) +// if require.Error(t, err) { +// require.Equal(t, expectedError, err) // } func Error(t TestingT, err error, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { @@ -321,7 +321,7 @@ func ErrorAsf(t TestingT, err error, target interface{}, msg string, args ...int // and that the error contains the specified substring. // // actualObj, err := SomeFunction() -// assert.ErrorContains(t, err, expectedErrorSubString) +// require.ErrorContains(t, err, expectedErrorSubString) func ErrorContains(t TestingT, theError error, contains string, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -336,7 +336,7 @@ func ErrorContains(t TestingT, theError error, contains string, msgAndArgs ...in // and that the error contains the specified substring. // // actualObj, err := SomeFunction() -// assert.ErrorContainsf(t, err, expectedErrorSubString, "error message %s", "formatted") +// require.ErrorContainsf(t, err, expectedErrorSubString, "error message %s", "formatted") func ErrorContainsf(t TestingT, theError error, contains string, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -374,8 +374,8 @@ func ErrorIsf(t TestingT, err error, target error, msg string, args ...interface // Errorf asserts that a function returned an error (i.e. not `nil`). // // actualObj, err := SomeFunction() -// if assert.Errorf(t, err, "error message %s", "formatted") { -// assert.Equal(t, expectedErrorf, err) +// if require.Errorf(t, err, "error message %s", "formatted") { +// require.Equal(t, expectedErrorf, err) // } func Errorf(t TestingT, err error, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { @@ -390,7 +390,7 @@ func Errorf(t TestingT, err error, msg string, args ...interface{}) { // Eventually asserts that given condition will be met in waitFor time, // periodically checking target function each tick. // -// assert.Eventually(t, func() bool { return true; }, time.Second, 10*time.Millisecond) +// require.Eventually(t, func() bool { return true; }, time.Second, 10*time.Millisecond) func Eventually(t TestingT, condition func() bool, waitFor time.Duration, tick time.Duration, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -415,10 +415,10 @@ func Eventually(t TestingT, condition func() bool, waitFor time.Duration, tick t // time.Sleep(8*time.Second) // externalValue = true // }() -// assert.EventuallyWithT(t, func(c *assert.CollectT) { +// require.EventuallyWithT(t, func(c *require.CollectT) { // // add assertions as needed; any assertion failure will fail the current tick -// assert.True(c, externalValue, "expected 'externalValue' to be true") -// }, 1*time.Second, 10*time.Second, "external state has not changed to 'true'; still false") +// require.True(c, externalValue, "expected 'externalValue' to be true") +// }, 10*time.Second, 1*time.Second, "external state has not changed to 'true'; still false") func EventuallyWithT(t TestingT, condition func(collect *assert.CollectT), waitFor time.Duration, tick time.Duration, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -443,10 +443,10 @@ func EventuallyWithT(t TestingT, condition func(collect *assert.CollectT), waitF // time.Sleep(8*time.Second) // externalValue = true // }() -// assert.EventuallyWithTf(t, func(c *assert.CollectT, "error message %s", "formatted") { +// require.EventuallyWithTf(t, func(c *require.CollectT, "error message %s", "formatted") { // // add assertions as needed; any assertion failure will fail the current tick -// assert.True(c, externalValue, "expected 'externalValue' to be true") -// }, 1*time.Second, 10*time.Second, "external state has not changed to 'true'; still false") +// require.True(c, externalValue, "expected 'externalValue' to be true") +// }, 10*time.Second, 1*time.Second, "external state has not changed to 'true'; still false") func EventuallyWithTf(t TestingT, condition func(collect *assert.CollectT), waitFor time.Duration, tick time.Duration, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -460,7 +460,7 @@ func EventuallyWithTf(t TestingT, condition func(collect *assert.CollectT), wait // Eventuallyf asserts that given condition will be met in waitFor time, // periodically checking target function each tick. // -// assert.Eventuallyf(t, func() bool { return true; }, time.Second, 10*time.Millisecond, "error message %s", "formatted") +// require.Eventuallyf(t, func() bool { return true; }, time.Second, 10*time.Millisecond, "error message %s", "formatted") func Eventuallyf(t TestingT, condition func() bool, waitFor time.Duration, tick time.Duration, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -473,7 +473,7 @@ func Eventuallyf(t TestingT, condition func() bool, waitFor time.Duration, tick // Exactly asserts that two objects are equal in value and type. // -// assert.Exactly(t, int32(123), int64(123)) +// require.Exactly(t, int32(123), int64(123)) func Exactly(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -486,7 +486,7 @@ func Exactly(t TestingT, expected interface{}, actual interface{}, msgAndArgs .. // Exactlyf asserts that two objects are equal in value and type. // -// assert.Exactlyf(t, int32(123), int64(123), "error message %s", "formatted") +// require.Exactlyf(t, int32(123), int64(123), "error message %s", "formatted") func Exactlyf(t TestingT, expected interface{}, actual interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -543,7 +543,7 @@ func Failf(t TestingT, failureMessage string, msg string, args ...interface{}) { // False asserts that the specified value is false. // -// assert.False(t, myBool) +// require.False(t, myBool) func False(t TestingT, value bool, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -556,7 +556,7 @@ func False(t TestingT, value bool, msgAndArgs ...interface{}) { // Falsef asserts that the specified value is false. // -// assert.Falsef(t, myBool, "error message %s", "formatted") +// require.Falsef(t, myBool, "error message %s", "formatted") func Falsef(t TestingT, value bool, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -593,9 +593,9 @@ func FileExistsf(t TestingT, path string, msg string, args ...interface{}) { // Greater asserts that the first element is greater than the second // -// assert.Greater(t, 2, 1) -// assert.Greater(t, float64(2), float64(1)) -// assert.Greater(t, "b", "a") +// require.Greater(t, 2, 1) +// require.Greater(t, float64(2), float64(1)) +// require.Greater(t, "b", "a") func Greater(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -608,10 +608,10 @@ func Greater(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...interface // GreaterOrEqual asserts that the first element is greater than or equal to the second // -// assert.GreaterOrEqual(t, 2, 1) -// assert.GreaterOrEqual(t, 2, 2) -// assert.GreaterOrEqual(t, "b", "a") -// assert.GreaterOrEqual(t, "b", "b") +// require.GreaterOrEqual(t, 2, 1) +// require.GreaterOrEqual(t, 2, 2) +// require.GreaterOrEqual(t, "b", "a") +// require.GreaterOrEqual(t, "b", "b") func GreaterOrEqual(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -624,10 +624,10 @@ func GreaterOrEqual(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...in // GreaterOrEqualf asserts that the first element is greater than or equal to the second // -// assert.GreaterOrEqualf(t, 2, 1, "error message %s", "formatted") -// assert.GreaterOrEqualf(t, 2, 2, "error message %s", "formatted") -// assert.GreaterOrEqualf(t, "b", "a", "error message %s", "formatted") -// assert.GreaterOrEqualf(t, "b", "b", "error message %s", "formatted") +// require.GreaterOrEqualf(t, 2, 1, "error message %s", "formatted") +// require.GreaterOrEqualf(t, 2, 2, "error message %s", "formatted") +// require.GreaterOrEqualf(t, "b", "a", "error message %s", "formatted") +// require.GreaterOrEqualf(t, "b", "b", "error message %s", "formatted") func GreaterOrEqualf(t TestingT, e1 interface{}, e2 interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -640,9 +640,9 @@ func GreaterOrEqualf(t TestingT, e1 interface{}, e2 interface{}, msg string, arg // Greaterf asserts that the first element is greater than the second // -// assert.Greaterf(t, 2, 1, "error message %s", "formatted") -// assert.Greaterf(t, float64(2), float64(1), "error message %s", "formatted") -// assert.Greaterf(t, "b", "a", "error message %s", "formatted") +// require.Greaterf(t, 2, 1, "error message %s", "formatted") +// require.Greaterf(t, float64(2), float64(1), "error message %s", "formatted") +// require.Greaterf(t, "b", "a", "error message %s", "formatted") func Greaterf(t TestingT, e1 interface{}, e2 interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -656,7 +656,7 @@ func Greaterf(t TestingT, e1 interface{}, e2 interface{}, msg string, args ...in // HTTPBodyContains asserts that a specified handler returns a // body that contains a string. // -// assert.HTTPBodyContains(t, myHandler, "GET", "www.google.com", nil, "I'm Feeling Lucky") +// require.HTTPBodyContains(t, myHandler, "GET", "www.google.com", nil, "I'm Feeling Lucky") // // Returns whether the assertion was successful (true) or not (false). func HTTPBodyContains(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, str interface{}, msgAndArgs ...interface{}) { @@ -672,7 +672,7 @@ func HTTPBodyContains(t TestingT, handler http.HandlerFunc, method string, url s // HTTPBodyContainsf asserts that a specified handler returns a // body that contains a string. // -// assert.HTTPBodyContainsf(t, myHandler, "GET", "www.google.com", nil, "I'm Feeling Lucky", "error message %s", "formatted") +// require.HTTPBodyContainsf(t, myHandler, "GET", "www.google.com", nil, "I'm Feeling Lucky", "error message %s", "formatted") // // Returns whether the assertion was successful (true) or not (false). func HTTPBodyContainsf(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, str interface{}, msg string, args ...interface{}) { @@ -688,7 +688,7 @@ func HTTPBodyContainsf(t TestingT, handler http.HandlerFunc, method string, url // HTTPBodyNotContains asserts that a specified handler returns a // body that does not contain a string. // -// assert.HTTPBodyNotContains(t, myHandler, "GET", "www.google.com", nil, "I'm Feeling Lucky") +// require.HTTPBodyNotContains(t, myHandler, "GET", "www.google.com", nil, "I'm Feeling Lucky") // // Returns whether the assertion was successful (true) or not (false). func HTTPBodyNotContains(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, str interface{}, msgAndArgs ...interface{}) { @@ -704,7 +704,7 @@ func HTTPBodyNotContains(t TestingT, handler http.HandlerFunc, method string, ur // HTTPBodyNotContainsf asserts that a specified handler returns a // body that does not contain a string. // -// assert.HTTPBodyNotContainsf(t, myHandler, "GET", "www.google.com", nil, "I'm Feeling Lucky", "error message %s", "formatted") +// require.HTTPBodyNotContainsf(t, myHandler, "GET", "www.google.com", nil, "I'm Feeling Lucky", "error message %s", "formatted") // // Returns whether the assertion was successful (true) or not (false). func HTTPBodyNotContainsf(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, str interface{}, msg string, args ...interface{}) { @@ -719,7 +719,7 @@ func HTTPBodyNotContainsf(t TestingT, handler http.HandlerFunc, method string, u // HTTPError asserts that a specified handler returns an error status code. // -// assert.HTTPError(t, myHandler, "POST", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// require.HTTPError(t, myHandler, "POST", "/a/b/c", url.Values{"a": []string{"b", "c"}} // // Returns whether the assertion was successful (true) or not (false). func HTTPError(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, msgAndArgs ...interface{}) { @@ -734,7 +734,7 @@ func HTTPError(t TestingT, handler http.HandlerFunc, method string, url string, // HTTPErrorf asserts that a specified handler returns an error status code. // -// assert.HTTPErrorf(t, myHandler, "POST", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// require.HTTPErrorf(t, myHandler, "POST", "/a/b/c", url.Values{"a": []string{"b", "c"}} // // Returns whether the assertion was successful (true) or not (false). func HTTPErrorf(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, msg string, args ...interface{}) { @@ -749,7 +749,7 @@ func HTTPErrorf(t TestingT, handler http.HandlerFunc, method string, url string, // HTTPRedirect asserts that a specified handler returns a redirect status code. // -// assert.HTTPRedirect(t, myHandler, "GET", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// require.HTTPRedirect(t, myHandler, "GET", "/a/b/c", url.Values{"a": []string{"b", "c"}} // // Returns whether the assertion was successful (true) or not (false). func HTTPRedirect(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, msgAndArgs ...interface{}) { @@ -764,7 +764,7 @@ func HTTPRedirect(t TestingT, handler http.HandlerFunc, method string, url strin // HTTPRedirectf asserts that a specified handler returns a redirect status code. // -// assert.HTTPRedirectf(t, myHandler, "GET", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// require.HTTPRedirectf(t, myHandler, "GET", "/a/b/c", url.Values{"a": []string{"b", "c"}} // // Returns whether the assertion was successful (true) or not (false). func HTTPRedirectf(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, msg string, args ...interface{}) { @@ -779,7 +779,7 @@ func HTTPRedirectf(t TestingT, handler http.HandlerFunc, method string, url stri // HTTPStatusCode asserts that a specified handler returns a specified status code. // -// assert.HTTPStatusCode(t, myHandler, "GET", "/notImplemented", nil, 501) +// require.HTTPStatusCode(t, myHandler, "GET", "/notImplemented", nil, 501) // // Returns whether the assertion was successful (true) or not (false). func HTTPStatusCode(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, statuscode int, msgAndArgs ...interface{}) { @@ -794,7 +794,7 @@ func HTTPStatusCode(t TestingT, handler http.HandlerFunc, method string, url str // HTTPStatusCodef asserts that a specified handler returns a specified status code. // -// assert.HTTPStatusCodef(t, myHandler, "GET", "/notImplemented", nil, 501, "error message %s", "formatted") +// require.HTTPStatusCodef(t, myHandler, "GET", "/notImplemented", nil, 501, "error message %s", "formatted") // // Returns whether the assertion was successful (true) or not (false). func HTTPStatusCodef(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, statuscode int, msg string, args ...interface{}) { @@ -809,7 +809,7 @@ func HTTPStatusCodef(t TestingT, handler http.HandlerFunc, method string, url st // HTTPSuccess asserts that a specified handler returns a success status code. // -// assert.HTTPSuccess(t, myHandler, "POST", "http://www.google.com", nil) +// require.HTTPSuccess(t, myHandler, "POST", "http://www.google.com", nil) // // Returns whether the assertion was successful (true) or not (false). func HTTPSuccess(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, msgAndArgs ...interface{}) { @@ -824,7 +824,7 @@ func HTTPSuccess(t TestingT, handler http.HandlerFunc, method string, url string // HTTPSuccessf asserts that a specified handler returns a success status code. // -// assert.HTTPSuccessf(t, myHandler, "POST", "http://www.google.com", nil, "error message %s", "formatted") +// require.HTTPSuccessf(t, myHandler, "POST", "http://www.google.com", nil, "error message %s", "formatted") // // Returns whether the assertion was successful (true) or not (false). func HTTPSuccessf(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, msg string, args ...interface{}) { @@ -839,7 +839,7 @@ func HTTPSuccessf(t TestingT, handler http.HandlerFunc, method string, url strin // Implements asserts that an object is implemented by the specified interface. // -// assert.Implements(t, (*MyInterface)(nil), new(MyObject)) +// require.Implements(t, (*MyInterface)(nil), new(MyObject)) func Implements(t TestingT, interfaceObject interface{}, object interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -852,7 +852,7 @@ func Implements(t TestingT, interfaceObject interface{}, object interface{}, msg // Implementsf asserts that an object is implemented by the specified interface. // -// assert.Implementsf(t, (*MyInterface)(nil), new(MyObject), "error message %s", "formatted") +// require.Implementsf(t, (*MyInterface)(nil), new(MyObject), "error message %s", "formatted") func Implementsf(t TestingT, interfaceObject interface{}, object interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -865,7 +865,7 @@ func Implementsf(t TestingT, interfaceObject interface{}, object interface{}, ms // InDelta asserts that the two numerals are within delta of each other. // -// assert.InDelta(t, math.Pi, 22/7.0, 0.01) +// require.InDelta(t, math.Pi, 22/7.0, 0.01) func InDelta(t TestingT, expected interface{}, actual interface{}, delta float64, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -922,7 +922,7 @@ func InDeltaSlicef(t TestingT, expected interface{}, actual interface{}, delta f // InDeltaf asserts that the two numerals are within delta of each other. // -// assert.InDeltaf(t, math.Pi, 22/7.0, 0.01, "error message %s", "formatted") +// require.InDeltaf(t, math.Pi, 22/7.0, 0.01, "error message %s", "formatted") func InDeltaf(t TestingT, expected interface{}, actual interface{}, delta float64, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -979,9 +979,9 @@ func InEpsilonf(t TestingT, expected interface{}, actual interface{}, epsilon fl // IsDecreasing asserts that the collection is decreasing // -// assert.IsDecreasing(t, []int{2, 1, 0}) -// assert.IsDecreasing(t, []float{2, 1}) -// assert.IsDecreasing(t, []string{"b", "a"}) +// require.IsDecreasing(t, []int{2, 1, 0}) +// require.IsDecreasing(t, []float{2, 1}) +// require.IsDecreasing(t, []string{"b", "a"}) func IsDecreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -994,9 +994,9 @@ func IsDecreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) { // IsDecreasingf asserts that the collection is decreasing // -// assert.IsDecreasingf(t, []int{2, 1, 0}, "error message %s", "formatted") -// assert.IsDecreasingf(t, []float{2, 1}, "error message %s", "formatted") -// assert.IsDecreasingf(t, []string{"b", "a"}, "error message %s", "formatted") +// require.IsDecreasingf(t, []int{2, 1, 0}, "error message %s", "formatted") +// require.IsDecreasingf(t, []float{2, 1}, "error message %s", "formatted") +// require.IsDecreasingf(t, []string{"b", "a"}, "error message %s", "formatted") func IsDecreasingf(t TestingT, object interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1009,9 +1009,9 @@ func IsDecreasingf(t TestingT, object interface{}, msg string, args ...interface // IsIncreasing asserts that the collection is increasing // -// assert.IsIncreasing(t, []int{1, 2, 3}) -// assert.IsIncreasing(t, []float{1, 2}) -// assert.IsIncreasing(t, []string{"a", "b"}) +// require.IsIncreasing(t, []int{1, 2, 3}) +// require.IsIncreasing(t, []float{1, 2}) +// require.IsIncreasing(t, []string{"a", "b"}) func IsIncreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1024,9 +1024,9 @@ func IsIncreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) { // IsIncreasingf asserts that the collection is increasing // -// assert.IsIncreasingf(t, []int{1, 2, 3}, "error message %s", "formatted") -// assert.IsIncreasingf(t, []float{1, 2}, "error message %s", "formatted") -// assert.IsIncreasingf(t, []string{"a", "b"}, "error message %s", "formatted") +// require.IsIncreasingf(t, []int{1, 2, 3}, "error message %s", "formatted") +// require.IsIncreasingf(t, []float{1, 2}, "error message %s", "formatted") +// require.IsIncreasingf(t, []string{"a", "b"}, "error message %s", "formatted") func IsIncreasingf(t TestingT, object interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1039,9 +1039,9 @@ func IsIncreasingf(t TestingT, object interface{}, msg string, args ...interface // IsNonDecreasing asserts that the collection is not decreasing // -// assert.IsNonDecreasing(t, []int{1, 1, 2}) -// assert.IsNonDecreasing(t, []float{1, 2}) -// assert.IsNonDecreasing(t, []string{"a", "b"}) +// require.IsNonDecreasing(t, []int{1, 1, 2}) +// require.IsNonDecreasing(t, []float{1, 2}) +// require.IsNonDecreasing(t, []string{"a", "b"}) func IsNonDecreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1054,9 +1054,9 @@ func IsNonDecreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) // IsNonDecreasingf asserts that the collection is not decreasing // -// assert.IsNonDecreasingf(t, []int{1, 1, 2}, "error message %s", "formatted") -// assert.IsNonDecreasingf(t, []float{1, 2}, "error message %s", "formatted") -// assert.IsNonDecreasingf(t, []string{"a", "b"}, "error message %s", "formatted") +// require.IsNonDecreasingf(t, []int{1, 1, 2}, "error message %s", "formatted") +// require.IsNonDecreasingf(t, []float{1, 2}, "error message %s", "formatted") +// require.IsNonDecreasingf(t, []string{"a", "b"}, "error message %s", "formatted") func IsNonDecreasingf(t TestingT, object interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1069,9 +1069,9 @@ func IsNonDecreasingf(t TestingT, object interface{}, msg string, args ...interf // IsNonIncreasing asserts that the collection is not increasing // -// assert.IsNonIncreasing(t, []int{2, 1, 1}) -// assert.IsNonIncreasing(t, []float{2, 1}) -// assert.IsNonIncreasing(t, []string{"b", "a"}) +// require.IsNonIncreasing(t, []int{2, 1, 1}) +// require.IsNonIncreasing(t, []float{2, 1}) +// require.IsNonIncreasing(t, []string{"b", "a"}) func IsNonIncreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1084,9 +1084,9 @@ func IsNonIncreasing(t TestingT, object interface{}, msgAndArgs ...interface{}) // IsNonIncreasingf asserts that the collection is not increasing // -// assert.IsNonIncreasingf(t, []int{2, 1, 1}, "error message %s", "formatted") -// assert.IsNonIncreasingf(t, []float{2, 1}, "error message %s", "formatted") -// assert.IsNonIncreasingf(t, []string{"b", "a"}, "error message %s", "formatted") +// require.IsNonIncreasingf(t, []int{2, 1, 1}, "error message %s", "formatted") +// require.IsNonIncreasingf(t, []float{2, 1}, "error message %s", "formatted") +// require.IsNonIncreasingf(t, []string{"b", "a"}, "error message %s", "formatted") func IsNonIncreasingf(t TestingT, object interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1121,7 +1121,7 @@ func IsTypef(t TestingT, expectedType interface{}, object interface{}, msg strin // JSONEq asserts that two JSON strings are equivalent. // -// assert.JSONEq(t, `{"hello": "world", "foo": "bar"}`, `{"foo": "bar", "hello": "world"}`) +// require.JSONEq(t, `{"hello": "world", "foo": "bar"}`, `{"foo": "bar", "hello": "world"}`) func JSONEq(t TestingT, expected string, actual string, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1134,7 +1134,7 @@ func JSONEq(t TestingT, expected string, actual string, msgAndArgs ...interface{ // JSONEqf asserts that two JSON strings are equivalent. // -// assert.JSONEqf(t, `{"hello": "world", "foo": "bar"}`, `{"foo": "bar", "hello": "world"}`, "error message %s", "formatted") +// require.JSONEqf(t, `{"hello": "world", "foo": "bar"}`, `{"foo": "bar", "hello": "world"}`, "error message %s", "formatted") func JSONEqf(t TestingT, expected string, actual string, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1148,7 +1148,7 @@ func JSONEqf(t TestingT, expected string, actual string, msg string, args ...int // Len asserts that the specified object has specific length. // Len also fails if the object has a type that len() not accept. // -// assert.Len(t, mySlice, 3) +// require.Len(t, mySlice, 3) func Len(t TestingT, object interface{}, length int, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1162,7 +1162,7 @@ func Len(t TestingT, object interface{}, length int, msgAndArgs ...interface{}) // Lenf asserts that the specified object has specific length. // Lenf also fails if the object has a type that len() not accept. // -// assert.Lenf(t, mySlice, 3, "error message %s", "formatted") +// require.Lenf(t, mySlice, 3, "error message %s", "formatted") func Lenf(t TestingT, object interface{}, length int, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1175,9 +1175,9 @@ func Lenf(t TestingT, object interface{}, length int, msg string, args ...interf // Less asserts that the first element is less than the second // -// assert.Less(t, 1, 2) -// assert.Less(t, float64(1), float64(2)) -// assert.Less(t, "a", "b") +// require.Less(t, 1, 2) +// require.Less(t, float64(1), float64(2)) +// require.Less(t, "a", "b") func Less(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1190,10 +1190,10 @@ func Less(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...interface{}) // LessOrEqual asserts that the first element is less than or equal to the second // -// assert.LessOrEqual(t, 1, 2) -// assert.LessOrEqual(t, 2, 2) -// assert.LessOrEqual(t, "a", "b") -// assert.LessOrEqual(t, "b", "b") +// require.LessOrEqual(t, 1, 2) +// require.LessOrEqual(t, 2, 2) +// require.LessOrEqual(t, "a", "b") +// require.LessOrEqual(t, "b", "b") func LessOrEqual(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1206,10 +1206,10 @@ func LessOrEqual(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...inter // LessOrEqualf asserts that the first element is less than or equal to the second // -// assert.LessOrEqualf(t, 1, 2, "error message %s", "formatted") -// assert.LessOrEqualf(t, 2, 2, "error message %s", "formatted") -// assert.LessOrEqualf(t, "a", "b", "error message %s", "formatted") -// assert.LessOrEqualf(t, "b", "b", "error message %s", "formatted") +// require.LessOrEqualf(t, 1, 2, "error message %s", "formatted") +// require.LessOrEqualf(t, 2, 2, "error message %s", "formatted") +// require.LessOrEqualf(t, "a", "b", "error message %s", "formatted") +// require.LessOrEqualf(t, "b", "b", "error message %s", "formatted") func LessOrEqualf(t TestingT, e1 interface{}, e2 interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1222,9 +1222,9 @@ func LessOrEqualf(t TestingT, e1 interface{}, e2 interface{}, msg string, args . // Lessf asserts that the first element is less than the second // -// assert.Lessf(t, 1, 2, "error message %s", "formatted") -// assert.Lessf(t, float64(1), float64(2), "error message %s", "formatted") -// assert.Lessf(t, "a", "b", "error message %s", "formatted") +// require.Lessf(t, 1, 2, "error message %s", "formatted") +// require.Lessf(t, float64(1), float64(2), "error message %s", "formatted") +// require.Lessf(t, "a", "b", "error message %s", "formatted") func Lessf(t TestingT, e1 interface{}, e2 interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1237,8 +1237,8 @@ func Lessf(t TestingT, e1 interface{}, e2 interface{}, msg string, args ...inter // Negative asserts that the specified element is negative // -// assert.Negative(t, -1) -// assert.Negative(t, -1.23) +// require.Negative(t, -1) +// require.Negative(t, -1.23) func Negative(t TestingT, e interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1251,8 +1251,8 @@ func Negative(t TestingT, e interface{}, msgAndArgs ...interface{}) { // Negativef asserts that the specified element is negative // -// assert.Negativef(t, -1, "error message %s", "formatted") -// assert.Negativef(t, -1.23, "error message %s", "formatted") +// require.Negativef(t, -1, "error message %s", "formatted") +// require.Negativef(t, -1.23, "error message %s", "formatted") func Negativef(t TestingT, e interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1266,7 +1266,7 @@ func Negativef(t TestingT, e interface{}, msg string, args ...interface{}) { // Never asserts that the given condition doesn't satisfy in waitFor time, // periodically checking the target function each tick. // -// assert.Never(t, func() bool { return false; }, time.Second, 10*time.Millisecond) +// require.Never(t, func() bool { return false; }, time.Second, 10*time.Millisecond) func Never(t TestingT, condition func() bool, waitFor time.Duration, tick time.Duration, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1280,7 +1280,7 @@ func Never(t TestingT, condition func() bool, waitFor time.Duration, tick time.D // Neverf asserts that the given condition doesn't satisfy in waitFor time, // periodically checking the target function each tick. // -// assert.Neverf(t, func() bool { return false; }, time.Second, 10*time.Millisecond, "error message %s", "formatted") +// require.Neverf(t, func() bool { return false; }, time.Second, 10*time.Millisecond, "error message %s", "formatted") func Neverf(t TestingT, condition func() bool, waitFor time.Duration, tick time.Duration, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1293,7 +1293,7 @@ func Neverf(t TestingT, condition func() bool, waitFor time.Duration, tick time. // Nil asserts that the specified object is nil. // -// assert.Nil(t, err) +// require.Nil(t, err) func Nil(t TestingT, object interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1306,7 +1306,7 @@ func Nil(t TestingT, object interface{}, msgAndArgs ...interface{}) { // Nilf asserts that the specified object is nil. // -// assert.Nilf(t, err, "error message %s", "formatted") +// require.Nilf(t, err, "error message %s", "formatted") func Nilf(t TestingT, object interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1344,8 +1344,8 @@ func NoDirExistsf(t TestingT, path string, msg string, args ...interface{}) { // NoError asserts that a function returned no error (i.e. `nil`). // // actualObj, err := SomeFunction() -// if assert.NoError(t, err) { -// assert.Equal(t, expectedObj, actualObj) +// if require.NoError(t, err) { +// require.Equal(t, expectedObj, actualObj) // } func NoError(t TestingT, err error, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { @@ -1360,8 +1360,8 @@ func NoError(t TestingT, err error, msgAndArgs ...interface{}) { // NoErrorf asserts that a function returned no error (i.e. `nil`). // // actualObj, err := SomeFunction() -// if assert.NoErrorf(t, err, "error message %s", "formatted") { -// assert.Equal(t, expectedObj, actualObj) +// if require.NoErrorf(t, err, "error message %s", "formatted") { +// require.Equal(t, expectedObj, actualObj) // } func NoErrorf(t TestingT, err error, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { @@ -1400,9 +1400,9 @@ func NoFileExistsf(t TestingT, path string, msg string, args ...interface{}) { // NotContains asserts that the specified string, list(array, slice...) or map does NOT contain the // specified substring or element. // -// assert.NotContains(t, "Hello World", "Earth") -// assert.NotContains(t, ["Hello", "World"], "Earth") -// assert.NotContains(t, {"Hello": "World"}, "Earth") +// require.NotContains(t, "Hello World", "Earth") +// require.NotContains(t, ["Hello", "World"], "Earth") +// require.NotContains(t, {"Hello": "World"}, "Earth") func NotContains(t TestingT, s interface{}, contains interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1416,9 +1416,9 @@ func NotContains(t TestingT, s interface{}, contains interface{}, msgAndArgs ... // NotContainsf asserts that the specified string, list(array, slice...) or map does NOT contain the // specified substring or element. // -// assert.NotContainsf(t, "Hello World", "Earth", "error message %s", "formatted") -// assert.NotContainsf(t, ["Hello", "World"], "Earth", "error message %s", "formatted") -// assert.NotContainsf(t, {"Hello": "World"}, "Earth", "error message %s", "formatted") +// require.NotContainsf(t, "Hello World", "Earth", "error message %s", "formatted") +// require.NotContainsf(t, ["Hello", "World"], "Earth", "error message %s", "formatted") +// require.NotContainsf(t, {"Hello": "World"}, "Earth", "error message %s", "formatted") func NotContainsf(t TestingT, s interface{}, contains interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1429,11 +1429,51 @@ func NotContainsf(t TestingT, s interface{}, contains interface{}, msg string, a t.FailNow() } +// NotElementsMatch asserts that the specified listA(array, slice...) is NOT equal to specified +// listB(array, slice...) ignoring the order of the elements. If there are duplicate elements, +// the number of appearances of each of them in both lists should not match. +// This is an inverse of ElementsMatch. +// +// require.NotElementsMatch(t, [1, 1, 2, 3], [1, 1, 2, 3]) -> false +// +// require.NotElementsMatch(t, [1, 1, 2, 3], [1, 2, 3]) -> true +// +// require.NotElementsMatch(t, [1, 2, 3], [1, 2, 4]) -> true +func NotElementsMatch(t TestingT, listA interface{}, listB interface{}, msgAndArgs ...interface{}) { + if h, ok := t.(tHelper); ok { + h.Helper() + } + if assert.NotElementsMatch(t, listA, listB, msgAndArgs...) { + return + } + t.FailNow() +} + +// NotElementsMatchf asserts that the specified listA(array, slice...) is NOT equal to specified +// listB(array, slice...) ignoring the order of the elements. If there are duplicate elements, +// the number of appearances of each of them in both lists should not match. +// This is an inverse of ElementsMatch. +// +// require.NotElementsMatchf(t, [1, 1, 2, 3], [1, 1, 2, 3], "error message %s", "formatted") -> false +// +// require.NotElementsMatchf(t, [1, 1, 2, 3], [1, 2, 3], "error message %s", "formatted") -> true +// +// require.NotElementsMatchf(t, [1, 2, 3], [1, 2, 4], "error message %s", "formatted") -> true +func NotElementsMatchf(t TestingT, listA interface{}, listB interface{}, msg string, args ...interface{}) { + if h, ok := t.(tHelper); ok { + h.Helper() + } + if assert.NotElementsMatchf(t, listA, listB, msg, args...) { + return + } + t.FailNow() +} + // NotEmpty asserts that the specified object is NOT empty. I.e. not nil, "", false, 0 or either // a slice or a channel with len == 0. // -// if assert.NotEmpty(t, obj) { -// assert.Equal(t, "two", obj[1]) +// if require.NotEmpty(t, obj) { +// require.Equal(t, "two", obj[1]) // } func NotEmpty(t TestingT, object interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { @@ -1448,8 +1488,8 @@ func NotEmpty(t TestingT, object interface{}, msgAndArgs ...interface{}) { // NotEmptyf asserts that the specified object is NOT empty. I.e. not nil, "", false, 0 or either // a slice or a channel with len == 0. // -// if assert.NotEmptyf(t, obj, "error message %s", "formatted") { -// assert.Equal(t, "two", obj[1]) +// if require.NotEmptyf(t, obj, "error message %s", "formatted") { +// require.Equal(t, "two", obj[1]) // } func NotEmptyf(t TestingT, object interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { @@ -1463,7 +1503,7 @@ func NotEmptyf(t TestingT, object interface{}, msg string, args ...interface{}) // NotEqual asserts that the specified values are NOT equal. // -// assert.NotEqual(t, obj1, obj2) +// require.NotEqual(t, obj1, obj2) // // Pointer variable equality is determined based on the equality of the // referenced values (as opposed to the memory addresses). @@ -1479,7 +1519,7 @@ func NotEqual(t TestingT, expected interface{}, actual interface{}, msgAndArgs . // NotEqualValues asserts that two objects are not equal even when converted to the same type // -// assert.NotEqualValues(t, obj1, obj2) +// require.NotEqualValues(t, obj1, obj2) func NotEqualValues(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1492,7 +1532,7 @@ func NotEqualValues(t TestingT, expected interface{}, actual interface{}, msgAnd // NotEqualValuesf asserts that two objects are not equal even when converted to the same type // -// assert.NotEqualValuesf(t, obj1, obj2, "error message %s", "formatted") +// require.NotEqualValuesf(t, obj1, obj2, "error message %s", "formatted") func NotEqualValuesf(t TestingT, expected interface{}, actual interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1505,7 +1545,7 @@ func NotEqualValuesf(t TestingT, expected interface{}, actual interface{}, msg s // NotEqualf asserts that the specified values are NOT equal. // -// assert.NotEqualf(t, obj1, obj2, "error message %s", "formatted") +// require.NotEqualf(t, obj1, obj2, "error message %s", "formatted") // // Pointer variable equality is determined based on the equality of the // referenced values (as opposed to the memory addresses). @@ -1519,7 +1559,31 @@ func NotEqualf(t TestingT, expected interface{}, actual interface{}, msg string, t.FailNow() } -// NotErrorIs asserts that at none of the errors in err's chain matches target. +// NotErrorAs asserts that none of the errors in err's chain matches target, +// but if so, sets target to that error value. +func NotErrorAs(t TestingT, err error, target interface{}, msgAndArgs ...interface{}) { + if h, ok := t.(tHelper); ok { + h.Helper() + } + if assert.NotErrorAs(t, err, target, msgAndArgs...) { + return + } + t.FailNow() +} + +// NotErrorAsf asserts that none of the errors in err's chain matches target, +// but if so, sets target to that error value. +func NotErrorAsf(t TestingT, err error, target interface{}, msg string, args ...interface{}) { + if h, ok := t.(tHelper); ok { + h.Helper() + } + if assert.NotErrorAsf(t, err, target, msg, args...) { + return + } + t.FailNow() +} + +// NotErrorIs asserts that none of the errors in err's chain matches target. // This is a wrapper for errors.Is. func NotErrorIs(t TestingT, err error, target error, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { @@ -1531,7 +1595,7 @@ func NotErrorIs(t TestingT, err error, target error, msgAndArgs ...interface{}) t.FailNow() } -// NotErrorIsf asserts that at none of the errors in err's chain matches target. +// NotErrorIsf asserts that none of the errors in err's chain matches target. // This is a wrapper for errors.Is. func NotErrorIsf(t TestingT, err error, target error, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { @@ -1545,7 +1609,7 @@ func NotErrorIsf(t TestingT, err error, target error, msg string, args ...interf // NotImplements asserts that an object does not implement the specified interface. // -// assert.NotImplements(t, (*MyInterface)(nil), new(MyObject)) +// require.NotImplements(t, (*MyInterface)(nil), new(MyObject)) func NotImplements(t TestingT, interfaceObject interface{}, object interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1558,7 +1622,7 @@ func NotImplements(t TestingT, interfaceObject interface{}, object interface{}, // NotImplementsf asserts that an object does not implement the specified interface. // -// assert.NotImplementsf(t, (*MyInterface)(nil), new(MyObject), "error message %s", "formatted") +// require.NotImplementsf(t, (*MyInterface)(nil), new(MyObject), "error message %s", "formatted") func NotImplementsf(t TestingT, interfaceObject interface{}, object interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1571,7 +1635,7 @@ func NotImplementsf(t TestingT, interfaceObject interface{}, object interface{}, // NotNil asserts that the specified object is not nil. // -// assert.NotNil(t, err) +// require.NotNil(t, err) func NotNil(t TestingT, object interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1584,7 +1648,7 @@ func NotNil(t TestingT, object interface{}, msgAndArgs ...interface{}) { // NotNilf asserts that the specified object is not nil. // -// assert.NotNilf(t, err, "error message %s", "formatted") +// require.NotNilf(t, err, "error message %s", "formatted") func NotNilf(t TestingT, object interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1597,7 +1661,7 @@ func NotNilf(t TestingT, object interface{}, msg string, args ...interface{}) { // NotPanics asserts that the code inside the specified PanicTestFunc does NOT panic. // -// assert.NotPanics(t, func(){ RemainCalm() }) +// require.NotPanics(t, func(){ RemainCalm() }) func NotPanics(t TestingT, f assert.PanicTestFunc, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1610,7 +1674,7 @@ func NotPanics(t TestingT, f assert.PanicTestFunc, msgAndArgs ...interface{}) { // NotPanicsf asserts that the code inside the specified PanicTestFunc does NOT panic. // -// assert.NotPanicsf(t, func(){ RemainCalm() }, "error message %s", "formatted") +// require.NotPanicsf(t, func(){ RemainCalm() }, "error message %s", "formatted") func NotPanicsf(t TestingT, f assert.PanicTestFunc, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1623,8 +1687,8 @@ func NotPanicsf(t TestingT, f assert.PanicTestFunc, msg string, args ...interfac // NotRegexp asserts that a specified regexp does not match a string. // -// assert.NotRegexp(t, regexp.MustCompile("starts"), "it's starting") -// assert.NotRegexp(t, "^start", "it's not starting") +// require.NotRegexp(t, regexp.MustCompile("starts"), "it's starting") +// require.NotRegexp(t, "^start", "it's not starting") func NotRegexp(t TestingT, rx interface{}, str interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1637,8 +1701,8 @@ func NotRegexp(t TestingT, rx interface{}, str interface{}, msgAndArgs ...interf // NotRegexpf asserts that a specified regexp does not match a string. // -// assert.NotRegexpf(t, regexp.MustCompile("starts"), "it's starting", "error message %s", "formatted") -// assert.NotRegexpf(t, "^start", "it's not starting", "error message %s", "formatted") +// require.NotRegexpf(t, regexp.MustCompile("starts"), "it's starting", "error message %s", "formatted") +// require.NotRegexpf(t, "^start", "it's not starting", "error message %s", "formatted") func NotRegexpf(t TestingT, rx interface{}, str interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1651,7 +1715,7 @@ func NotRegexpf(t TestingT, rx interface{}, str interface{}, msg string, args .. // NotSame asserts that two pointers do not reference the same object. // -// assert.NotSame(t, ptr1, ptr2) +// require.NotSame(t, ptr1, ptr2) // // Both arguments must be pointer variables. Pointer variable sameness is // determined based on the equality of both type and value. @@ -1667,7 +1731,7 @@ func NotSame(t TestingT, expected interface{}, actual interface{}, msgAndArgs .. // NotSamef asserts that two pointers do not reference the same object. // -// assert.NotSamef(t, ptr1, ptr2, "error message %s", "formatted") +// require.NotSamef(t, ptr1, ptr2, "error message %s", "formatted") // // Both arguments must be pointer variables. Pointer variable sameness is // determined based on the equality of both type and value. @@ -1685,8 +1749,8 @@ func NotSamef(t TestingT, expected interface{}, actual interface{}, msg string, // contain all elements given in the specified subset list(array, slice...) or // map. // -// assert.NotSubset(t, [1, 3, 4], [1, 2]) -// assert.NotSubset(t, {"x": 1, "y": 2}, {"z": 3}) +// require.NotSubset(t, [1, 3, 4], [1, 2]) +// require.NotSubset(t, {"x": 1, "y": 2}, {"z": 3}) func NotSubset(t TestingT, list interface{}, subset interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1701,8 +1765,8 @@ func NotSubset(t TestingT, list interface{}, subset interface{}, msgAndArgs ...i // contain all elements given in the specified subset list(array, slice...) or // map. // -// assert.NotSubsetf(t, [1, 3, 4], [1, 2], "error message %s", "formatted") -// assert.NotSubsetf(t, {"x": 1, "y": 2}, {"z": 3}, "error message %s", "formatted") +// require.NotSubsetf(t, [1, 3, 4], [1, 2], "error message %s", "formatted") +// require.NotSubsetf(t, {"x": 1, "y": 2}, {"z": 3}, "error message %s", "formatted") func NotSubsetf(t TestingT, list interface{}, subset interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1737,7 +1801,7 @@ func NotZerof(t TestingT, i interface{}, msg string, args ...interface{}) { // Panics asserts that the code inside the specified PanicTestFunc panics. // -// assert.Panics(t, func(){ GoCrazy() }) +// require.Panics(t, func(){ GoCrazy() }) func Panics(t TestingT, f assert.PanicTestFunc, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1752,7 +1816,7 @@ func Panics(t TestingT, f assert.PanicTestFunc, msgAndArgs ...interface{}) { // panics, and that the recovered panic value is an error that satisfies the // EqualError comparison. // -// assert.PanicsWithError(t, "crazy error", func(){ GoCrazy() }) +// require.PanicsWithError(t, "crazy error", func(){ GoCrazy() }) func PanicsWithError(t TestingT, errString string, f assert.PanicTestFunc, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1767,7 +1831,7 @@ func PanicsWithError(t TestingT, errString string, f assert.PanicTestFunc, msgAn // panics, and that the recovered panic value is an error that satisfies the // EqualError comparison. // -// assert.PanicsWithErrorf(t, "crazy error", func(){ GoCrazy() }, "error message %s", "formatted") +// require.PanicsWithErrorf(t, "crazy error", func(){ GoCrazy() }, "error message %s", "formatted") func PanicsWithErrorf(t TestingT, errString string, f assert.PanicTestFunc, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1781,7 +1845,7 @@ func PanicsWithErrorf(t TestingT, errString string, f assert.PanicTestFunc, msg // PanicsWithValue asserts that the code inside the specified PanicTestFunc panics, and that // the recovered panic value equals the expected panic value. // -// assert.PanicsWithValue(t, "crazy error", func(){ GoCrazy() }) +// require.PanicsWithValue(t, "crazy error", func(){ GoCrazy() }) func PanicsWithValue(t TestingT, expected interface{}, f assert.PanicTestFunc, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1795,7 +1859,7 @@ func PanicsWithValue(t TestingT, expected interface{}, f assert.PanicTestFunc, m // PanicsWithValuef asserts that the code inside the specified PanicTestFunc panics, and that // the recovered panic value equals the expected panic value. // -// assert.PanicsWithValuef(t, "crazy error", func(){ GoCrazy() }, "error message %s", "formatted") +// require.PanicsWithValuef(t, "crazy error", func(){ GoCrazy() }, "error message %s", "formatted") func PanicsWithValuef(t TestingT, expected interface{}, f assert.PanicTestFunc, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1808,7 +1872,7 @@ func PanicsWithValuef(t TestingT, expected interface{}, f assert.PanicTestFunc, // Panicsf asserts that the code inside the specified PanicTestFunc panics. // -// assert.Panicsf(t, func(){ GoCrazy() }, "error message %s", "formatted") +// require.Panicsf(t, func(){ GoCrazy() }, "error message %s", "formatted") func Panicsf(t TestingT, f assert.PanicTestFunc, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1821,8 +1885,8 @@ func Panicsf(t TestingT, f assert.PanicTestFunc, msg string, args ...interface{} // Positive asserts that the specified element is positive // -// assert.Positive(t, 1) -// assert.Positive(t, 1.23) +// require.Positive(t, 1) +// require.Positive(t, 1.23) func Positive(t TestingT, e interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1835,8 +1899,8 @@ func Positive(t TestingT, e interface{}, msgAndArgs ...interface{}) { // Positivef asserts that the specified element is positive // -// assert.Positivef(t, 1, "error message %s", "formatted") -// assert.Positivef(t, 1.23, "error message %s", "formatted") +// require.Positivef(t, 1, "error message %s", "formatted") +// require.Positivef(t, 1.23, "error message %s", "formatted") func Positivef(t TestingT, e interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1849,8 +1913,8 @@ func Positivef(t TestingT, e interface{}, msg string, args ...interface{}) { // Regexp asserts that a specified regexp matches a string. // -// assert.Regexp(t, regexp.MustCompile("start"), "it's starting") -// assert.Regexp(t, "start...$", "it's not starting") +// require.Regexp(t, regexp.MustCompile("start"), "it's starting") +// require.Regexp(t, "start...$", "it's not starting") func Regexp(t TestingT, rx interface{}, str interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1863,8 +1927,8 @@ func Regexp(t TestingT, rx interface{}, str interface{}, msgAndArgs ...interface // Regexpf asserts that a specified regexp matches a string. // -// assert.Regexpf(t, regexp.MustCompile("start"), "it's starting", "error message %s", "formatted") -// assert.Regexpf(t, "start...$", "it's not starting", "error message %s", "formatted") +// require.Regexpf(t, regexp.MustCompile("start"), "it's starting", "error message %s", "formatted") +// require.Regexpf(t, "start...$", "it's not starting", "error message %s", "formatted") func Regexpf(t TestingT, rx interface{}, str interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1877,7 +1941,7 @@ func Regexpf(t TestingT, rx interface{}, str interface{}, msg string, args ...in // Same asserts that two pointers reference the same object. // -// assert.Same(t, ptr1, ptr2) +// require.Same(t, ptr1, ptr2) // // Both arguments must be pointer variables. Pointer variable sameness is // determined based on the equality of both type and value. @@ -1893,7 +1957,7 @@ func Same(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...in // Samef asserts that two pointers reference the same object. // -// assert.Samef(t, ptr1, ptr2, "error message %s", "formatted") +// require.Samef(t, ptr1, ptr2, "error message %s", "formatted") // // Both arguments must be pointer variables. Pointer variable sameness is // determined based on the equality of both type and value. @@ -1910,8 +1974,8 @@ func Samef(t TestingT, expected interface{}, actual interface{}, msg string, arg // Subset asserts that the specified list(array, slice...) or map contains all // elements given in the specified subset list(array, slice...) or map. // -// assert.Subset(t, [1, 2, 3], [1, 2]) -// assert.Subset(t, {"x": 1, "y": 2}, {"x": 1}) +// require.Subset(t, [1, 2, 3], [1, 2]) +// require.Subset(t, {"x": 1, "y": 2}, {"x": 1}) func Subset(t TestingT, list interface{}, subset interface{}, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1925,8 +1989,8 @@ func Subset(t TestingT, list interface{}, subset interface{}, msgAndArgs ...inte // Subsetf asserts that the specified list(array, slice...) or map contains all // elements given in the specified subset list(array, slice...) or map. // -// assert.Subsetf(t, [1, 2, 3], [1, 2], "error message %s", "formatted") -// assert.Subsetf(t, {"x": 1, "y": 2}, {"x": 1}, "error message %s", "formatted") +// require.Subsetf(t, [1, 2, 3], [1, 2], "error message %s", "formatted") +// require.Subsetf(t, {"x": 1, "y": 2}, {"x": 1}, "error message %s", "formatted") func Subsetf(t TestingT, list interface{}, subset interface{}, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1939,7 +2003,7 @@ func Subsetf(t TestingT, list interface{}, subset interface{}, msg string, args // True asserts that the specified value is true. // -// assert.True(t, myBool) +// require.True(t, myBool) func True(t TestingT, value bool, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1952,7 +2016,7 @@ func True(t TestingT, value bool, msgAndArgs ...interface{}) { // Truef asserts that the specified value is true. // -// assert.Truef(t, myBool, "error message %s", "formatted") +// require.Truef(t, myBool, "error message %s", "formatted") func Truef(t TestingT, value bool, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1965,7 +2029,7 @@ func Truef(t TestingT, value bool, msg string, args ...interface{}) { // WithinDuration asserts that the two times are within duration delta of each other. // -// assert.WithinDuration(t, time.Now(), time.Now(), 10*time.Second) +// require.WithinDuration(t, time.Now(), time.Now(), 10*time.Second) func WithinDuration(t TestingT, expected time.Time, actual time.Time, delta time.Duration, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1978,7 +2042,7 @@ func WithinDuration(t TestingT, expected time.Time, actual time.Time, delta time // WithinDurationf asserts that the two times are within duration delta of each other. // -// assert.WithinDurationf(t, time.Now(), time.Now(), 10*time.Second, "error message %s", "formatted") +// require.WithinDurationf(t, time.Now(), time.Now(), 10*time.Second, "error message %s", "formatted") func WithinDurationf(t TestingT, expected time.Time, actual time.Time, delta time.Duration, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -1991,7 +2055,7 @@ func WithinDurationf(t TestingT, expected time.Time, actual time.Time, delta tim // WithinRange asserts that a time is within a time range (inclusive). // -// assert.WithinRange(t, time.Now(), time.Now().Add(-time.Second), time.Now().Add(time.Second)) +// require.WithinRange(t, time.Now(), time.Now().Add(-time.Second), time.Now().Add(time.Second)) func WithinRange(t TestingT, actual time.Time, start time.Time, end time.Time, msgAndArgs ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() @@ -2004,7 +2068,7 @@ func WithinRange(t TestingT, actual time.Time, start time.Time, end time.Time, m // WithinRangef asserts that a time is within a time range (inclusive). // -// assert.WithinRangef(t, time.Now(), time.Now().Add(-time.Second), time.Now().Add(time.Second), "error message %s", "formatted") +// require.WithinRangef(t, time.Now(), time.Now().Add(-time.Second), time.Now().Add(time.Second), "error message %s", "formatted") func WithinRangef(t TestingT, actual time.Time, start time.Time, end time.Time, msg string, args ...interface{}) { if h, ok := t.(tHelper); ok { h.Helper() diff --git a/vendor/github.com/stretchr/testify/require/require.go.tmpl b/vendor/github.com/stretchr/testify/require/require.go.tmpl index 55e42dde..8b328368 100644 --- a/vendor/github.com/stretchr/testify/require/require.go.tmpl +++ b/vendor/github.com/stretchr/testify/require/require.go.tmpl @@ -1,4 +1,4 @@ -{{.Comment}} +{{ replace .Comment "assert." "require."}} func {{.DocInfo.Name}}(t TestingT, {{.Params}}) { if h, ok := t.(tHelper); ok { h.Helper() } if assert.{{.DocInfo.Name}}(t, {{.ForwardedParams}}) { return } diff --git a/vendor/github.com/stretchr/testify/require/require_forward.go b/vendor/github.com/stretchr/testify/require/require_forward.go index eee8310a..1bd87304 100644 --- a/vendor/github.com/stretchr/testify/require/require_forward.go +++ b/vendor/github.com/stretchr/testify/require/require_forward.go @@ -187,8 +187,8 @@ func (a *Assertions) EqualExportedValuesf(expected interface{}, actual interface EqualExportedValuesf(a.t, expected, actual, msg, args...) } -// EqualValues asserts that two objects are equal or convertible to the same types -// and equal. +// EqualValues asserts that two objects are equal or convertible to the larger +// type and equal. // // a.EqualValues(uint32(123), int32(123)) func (a *Assertions) EqualValues(expected interface{}, actual interface{}, msgAndArgs ...interface{}) { @@ -198,8 +198,8 @@ func (a *Assertions) EqualValues(expected interface{}, actual interface{}, msgAn EqualValues(a.t, expected, actual, msgAndArgs...) } -// EqualValuesf asserts that two objects are equal or convertible to the same types -// and equal. +// EqualValuesf asserts that two objects are equal or convertible to the larger +// type and equal. // // a.EqualValuesf(uint32(123), int32(123), "error message %s", "formatted") func (a *Assertions) EqualValuesf(expected interface{}, actual interface{}, msg string, args ...interface{}) { @@ -337,7 +337,7 @@ func (a *Assertions) Eventually(condition func() bool, waitFor time.Duration, ti // a.EventuallyWithT(func(c *assert.CollectT) { // // add assertions as needed; any assertion failure will fail the current tick // assert.True(c, externalValue, "expected 'externalValue' to be true") -// }, 1*time.Second, 10*time.Second, "external state has not changed to 'true'; still false") +// }, 10*time.Second, 1*time.Second, "external state has not changed to 'true'; still false") func (a *Assertions) EventuallyWithT(condition func(collect *assert.CollectT), waitFor time.Duration, tick time.Duration, msgAndArgs ...interface{}) { if h, ok := a.t.(tHelper); ok { h.Helper() @@ -362,7 +362,7 @@ func (a *Assertions) EventuallyWithT(condition func(collect *assert.CollectT), w // a.EventuallyWithTf(func(c *assert.CollectT, "error message %s", "formatted") { // // add assertions as needed; any assertion failure will fail the current tick // assert.True(c, externalValue, "expected 'externalValue' to be true") -// }, 1*time.Second, 10*time.Second, "external state has not changed to 'true'; still false") +// }, 10*time.Second, 1*time.Second, "external state has not changed to 'true'; still false") func (a *Assertions) EventuallyWithTf(condition func(collect *assert.CollectT), waitFor time.Duration, tick time.Duration, msg string, args ...interface{}) { if h, ok := a.t.(tHelper); ok { h.Helper() @@ -1129,6 +1129,40 @@ func (a *Assertions) NotContainsf(s interface{}, contains interface{}, msg strin NotContainsf(a.t, s, contains, msg, args...) } +// NotElementsMatch asserts that the specified listA(array, slice...) is NOT equal to specified +// listB(array, slice...) ignoring the order of the elements. If there are duplicate elements, +// the number of appearances of each of them in both lists should not match. +// This is an inverse of ElementsMatch. +// +// a.NotElementsMatch([1, 1, 2, 3], [1, 1, 2, 3]) -> false +// +// a.NotElementsMatch([1, 1, 2, 3], [1, 2, 3]) -> true +// +// a.NotElementsMatch([1, 2, 3], [1, 2, 4]) -> true +func (a *Assertions) NotElementsMatch(listA interface{}, listB interface{}, msgAndArgs ...interface{}) { + if h, ok := a.t.(tHelper); ok { + h.Helper() + } + NotElementsMatch(a.t, listA, listB, msgAndArgs...) +} + +// NotElementsMatchf asserts that the specified listA(array, slice...) is NOT equal to specified +// listB(array, slice...) ignoring the order of the elements. If there are duplicate elements, +// the number of appearances of each of them in both lists should not match. +// This is an inverse of ElementsMatch. +// +// a.NotElementsMatchf([1, 1, 2, 3], [1, 1, 2, 3], "error message %s", "formatted") -> false +// +// a.NotElementsMatchf([1, 1, 2, 3], [1, 2, 3], "error message %s", "formatted") -> true +// +// a.NotElementsMatchf([1, 2, 3], [1, 2, 4], "error message %s", "formatted") -> true +func (a *Assertions) NotElementsMatchf(listA interface{}, listB interface{}, msg string, args ...interface{}) { + if h, ok := a.t.(tHelper); ok { + h.Helper() + } + NotElementsMatchf(a.t, listA, listB, msg, args...) +} + // NotEmpty asserts that the specified object is NOT empty. I.e. not nil, "", false, 0 or either // a slice or a channel with len == 0. // @@ -1201,7 +1235,25 @@ func (a *Assertions) NotEqualf(expected interface{}, actual interface{}, msg str NotEqualf(a.t, expected, actual, msg, args...) } -// NotErrorIs asserts that at none of the errors in err's chain matches target. +// NotErrorAs asserts that none of the errors in err's chain matches target, +// but if so, sets target to that error value. +func (a *Assertions) NotErrorAs(err error, target interface{}, msgAndArgs ...interface{}) { + if h, ok := a.t.(tHelper); ok { + h.Helper() + } + NotErrorAs(a.t, err, target, msgAndArgs...) +} + +// NotErrorAsf asserts that none of the errors in err's chain matches target, +// but if so, sets target to that error value. +func (a *Assertions) NotErrorAsf(err error, target interface{}, msg string, args ...interface{}) { + if h, ok := a.t.(tHelper); ok { + h.Helper() + } + NotErrorAsf(a.t, err, target, msg, args...) +} + +// NotErrorIs asserts that none of the errors in err's chain matches target. // This is a wrapper for errors.Is. func (a *Assertions) NotErrorIs(err error, target error, msgAndArgs ...interface{}) { if h, ok := a.t.(tHelper); ok { @@ -1210,7 +1262,7 @@ func (a *Assertions) NotErrorIs(err error, target error, msgAndArgs ...interface NotErrorIs(a.t, err, target, msgAndArgs...) } -// NotErrorIsf asserts that at none of the errors in err's chain matches target. +// NotErrorIsf asserts that none of the errors in err's chain matches target. // This is a wrapper for errors.Is. func (a *Assertions) NotErrorIsf(err error, target error, msg string, args ...interface{}) { if h, ok := a.t.(tHelper); ok { diff --git a/vendor/github.com/stretchr/testify/require/requirements.go b/vendor/github.com/stretchr/testify/require/requirements.go index 91772dfe..6b7ce929 100644 --- a/vendor/github.com/stretchr/testify/require/requirements.go +++ b/vendor/github.com/stretchr/testify/require/requirements.go @@ -6,7 +6,7 @@ type TestingT interface { FailNow() } -type tHelper interface { +type tHelper = interface { Helper() } diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/batch.go b/vendor/github.com/syndtr/goleveldb/leveldb/batch.go index 823be93f..d5ecf721 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/batch.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/batch.go @@ -32,8 +32,7 @@ func newErrBatchCorrupted(reason string) error { const ( batchHeaderLen = 8 + 4 - batchGrowRec = 3000 - batchBufioSize = 16 + batchGrowLimit = 3000 ) // BatchReplay wraps basic batch operations. @@ -59,10 +58,6 @@ func (index batchIndex) v(data []byte) []byte { return nil } -func (index batchIndex) kv(data []byte) (key, value []byte) { - return index.k(data), index.v(data) -} - // Batch is a write batch. type Batch struct { data []byte @@ -70,14 +65,24 @@ type Batch struct { // internalLen is sums of key/value pair length plus 8-bytes internal key. internalLen int + + // growLimit is the threshold in order to slow down the memory allocation + // for batch when the number of accumulated entries exceeds value. + // + // batchGrowLimit is used as the default threshold if it's not configured. + growLimit int } func (b *Batch) grow(n int) { o := len(b.data) if cap(b.data)-o < n { + limit := batchGrowLimit + if b.growLimit > 0 { + limit = b.growLimit + } div := 1 - if len(b.index) > batchGrowRec { - div = len(b.index) / batchGrowRec + if len(b.index) > limit { + div = len(b.index) / limit } ndata := make([]byte, o, o+n+o/div) copy(ndata, b.data) @@ -223,17 +228,6 @@ func (b *Batch) putMem(seq uint64, mdb *memdb.DB) error { return nil } -func (b *Batch) revertMem(seq uint64, mdb *memdb.DB) error { - var ik []byte - for i, index := range b.index { - ik = makeInternalKey(ik, index.k(b.data), seq+uint64(i), index.keyType) - if err := mdb.Delete(ik); err != nil { - return err - } - } - return nil -} - func newBatch() interface{} { return &Batch{} } @@ -243,6 +237,42 @@ func MakeBatch(n int) *Batch { return &Batch{data: make([]byte, 0, n)} } +// BatchConfig contains the config options for batch. +type BatchConfig struct { + // InitialCapacity is the batch initial capacity to preallocate. + // + // The default value is 0. + InitialCapacity int + + // GrowLimit is the limit (in terms of entry) of how much buffer + // can grow each cycle. + // + // Initially the buffer will grow twice its current size until + // GrowLimit threshold is reached, after that the buffer will grow + // up to GrowLimit each cycle. This buffer grow size in bytes is + // loosely calculated from average entry size multiplied by GrowLimit. + // + // Generally, the memory allocation step is larger if this value + // is configured large, vice versa. + // + // The default value is 3000. + GrowLimit int +} + +// MakeBatchWithConfig initializes a batch object with the given configs. +func MakeBatchWithConfig(config *BatchConfig) *Batch { + var batch = new(Batch) + if config != nil { + if config.InitialCapacity > 0 { + batch.data = make([]byte, 0, config.InitialCapacity) + } + if config.GrowLimit > 0 { + batch.growLimit = config.GrowLimit + } + } + return batch +} + func decodeBatch(data []byte, fn func(i int, index batchIndex) error) error { var index batchIndex for i, o := 0, 0; o < len(data); i++ { diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/cache/cache.go b/vendor/github.com/syndtr/goleveldb/leveldb/cache/cache.go index c36ad323..8e4f397c 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/cache/cache.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/cache/cache.go @@ -8,6 +8,7 @@ package cache import ( + "sort" "sync" "sync/atomic" "unsafe" @@ -32,18 +33,9 @@ type Cacher interface { // Evict evicts the 'cache node'. Evict(n *Node) - - // EvictNS evicts 'cache node' with the given namespace. - EvictNS(ns uint64) - - // EvictAll evicts all 'cache node'. - EvictAll() - - // Close closes the 'cache tree' - Close() error } -// Value is a 'cacheable object'. It may implements util.Releaser, if +// Value is a 'cache-able object'. It may implements util.Releaser, if // so the the Release method will be called once object is released. type Value interface{} @@ -69,32 +61,76 @@ const ( mOverflowGrowThreshold = 1 << 7 ) +const ( + bucketUninitialized = iota + bucketInitialized + bucketFrozen +) + +type mNodes []*Node + +func (x mNodes) Len() int { return len(x) } +func (x mNodes) Less(i, j int) bool { + a, b := x[i].ns, x[j].ns + if a == b { + return x[i].key < x[j].key + } + return a < b +} +func (x mNodes) Swap(i, j int) { x[i], x[j] = x[j], x[i] } + +func (x mNodes) sort() { sort.Sort(x) } + +func (x mNodes) search(ns, key uint64) int { + return sort.Search(len(x), func(i int) bool { + a := x[i].ns + if a == ns { + return x[i].key >= key + } + return a > ns + }) +} + type mBucket struct { - mu sync.Mutex - node []*Node - frozen bool + mu sync.Mutex + nodes mNodes + state int8 } -func (b *mBucket) freeze() []*Node { +func (b *mBucket) freeze() mNodes { b.mu.Lock() defer b.mu.Unlock() - if !b.frozen { - b.frozen = true + if b.state == bucketInitialized { + b.state = bucketFrozen + } else if b.state == bucketUninitialized { + panic("BUG: freeze uninitialized bucket") } - return b.node + return b.nodes } -func (b *mBucket) get(r *Cache, h *mNode, hash uint32, ns, key uint64, noset bool) (done, added bool, n *Node) { +func (b *mBucket) frozen() bool { + if b.state == bucketFrozen { + return true + } + if b.state == bucketUninitialized { + panic("BUG: accessing uninitialized bucket") + } + return false +} + +func (b *mBucket) get(r *Cache, h *mHead, hash uint32, ns, key uint64, getOnly bool) (done, created bool, n *Node) { b.mu.Lock() - if b.frozen { + if b.frozen() { b.mu.Unlock() return } - // Scan the node. - for _, n := range b.node { - if n.hash == hash && n.ns == ns && n.key == key { + // Find the node. + i := b.nodes.search(ns, key) + if i < len(b.nodes) { + n = b.nodes[i] + if n.ns == ns && n.key == key { atomic.AddInt32(&n.ref, 1) b.mu.Unlock() return true, false, n @@ -102,7 +138,7 @@ func (b *mBucket) get(r *Cache, h *mNode, hash uint32, ns, key uint64, noset boo } // Get only. - if noset { + if getOnly { b.mu.Unlock() return true, false, nil } @@ -116,99 +152,106 @@ func (b *mBucket) get(r *Cache, h *mNode, hash uint32, ns, key uint64, noset boo ref: 1, } // Add node to bucket. - b.node = append(b.node, n) - bLen := len(b.node) + if i == len(b.nodes) { + b.nodes = append(b.nodes, n) + } else { + b.nodes = append(b.nodes[:i+1], b.nodes[i:]...) + b.nodes[i] = n + } + bLen := len(b.nodes) b.mu.Unlock() // Update counter. - grow := atomic.AddInt32(&r.nodes, 1) >= h.growThreshold + grow := atomic.AddInt64(&r.statNodes, 1) >= h.growThreshold if bLen > mOverflowThreshold { grow = grow || atomic.AddInt32(&h.overflow, 1) >= mOverflowGrowThreshold } // Grow. - if grow && atomic.CompareAndSwapInt32(&h.resizeInProgess, 0, 1) { + if grow && atomic.CompareAndSwapInt32(&h.resizeInProgress, 0, 1) { nhLen := len(h.buckets) << 1 - nh := &mNode{ - buckets: make([]unsafe.Pointer, nhLen), + nh := &mHead{ + buckets: make([]mBucket, nhLen), mask: uint32(nhLen) - 1, - pred: unsafe.Pointer(h), - growThreshold: int32(nhLen * mOverflowThreshold), - shrinkThreshold: int32(nhLen >> 1), + predecessor: unsafe.Pointer(h), + growThreshold: int64(nhLen * mOverflowThreshold), + shrinkThreshold: int64(nhLen >> 1), } ok := atomic.CompareAndSwapPointer(&r.mHead, unsafe.Pointer(h), unsafe.Pointer(nh)) if !ok { panic("BUG: failed swapping head") } + atomic.AddInt32(&r.statGrow, 1) go nh.initBuckets() } return true, true, n } -func (b *mBucket) delete(r *Cache, h *mNode, hash uint32, ns, key uint64) (done, deleted bool) { +func (b *mBucket) delete(r *Cache, h *mHead, hash uint32, ns, key uint64) (done, deleted bool) { b.mu.Lock() - if b.frozen { + if b.frozen() { b.mu.Unlock() return } - // Scan the node. - var ( - n *Node - bLen int - ) - for i := range b.node { - n = b.node[i] - if n.ns == ns && n.key == key { - if atomic.LoadInt32(&n.ref) == 0 { - deleted = true + // Find the node. + i := b.nodes.search(ns, key) + if i == len(b.nodes) { + b.mu.Unlock() + return true, false + } + n := b.nodes[i] + var bLen int + if n.ns == ns && n.key == key { + if atomic.LoadInt32(&n.ref) == 0 { + deleted = true + // Save and clear value. + if n.value != nil { // Call releaser. - if n.value != nil { - if r, ok := n.value.(util.Releaser); ok { - r.Release() - } - n.value = nil + if r, ok := n.value.(util.Releaser); ok { + r.Release() } - - // Remove node from bucket. - b.node = append(b.node[:i], b.node[i+1:]...) - bLen = len(b.node) + n.value = nil } - break + + // Remove node from bucket. + b.nodes = append(b.nodes[:i], b.nodes[i+1:]...) + bLen = len(b.nodes) } } b.mu.Unlock() if deleted { - // Call OnDel. - for _, f := range n.onDel { + // Call delete funcs. + for _, f := range n.delFuncs { f() } // Update counter. - atomic.AddInt32(&r.size, int32(n.size)*-1) - shrink := atomic.AddInt32(&r.nodes, -1) < h.shrinkThreshold + atomic.AddInt64(&r.statSize, int64(n.size)*-1) + shrink := atomic.AddInt64(&r.statNodes, -1) < h.shrinkThreshold if bLen >= mOverflowThreshold { atomic.AddInt32(&h.overflow, -1) } // Shrink. - if shrink && len(h.buckets) > mInitialSize && atomic.CompareAndSwapInt32(&h.resizeInProgess, 0, 1) { + if shrink && len(h.buckets) > mInitialSize && atomic.CompareAndSwapInt32(&h.resizeInProgress, 0, 1) { nhLen := len(h.buckets) >> 1 - nh := &mNode{ - buckets: make([]unsafe.Pointer, nhLen), + nh := &mHead{ + buckets: make([]mBucket, nhLen), mask: uint32(nhLen) - 1, - pred: unsafe.Pointer(h), - growThreshold: int32(nhLen * mOverflowThreshold), - shrinkThreshold: int32(nhLen >> 1), + predecessor: unsafe.Pointer(h), + growThreshold: int64(nhLen * mOverflowThreshold), + shrinkThreshold: int64(nhLen >> 1), } ok := atomic.CompareAndSwapPointer(&r.mHead, unsafe.Pointer(h), unsafe.Pointer(nh)) if !ok { panic("BUG: failed swapping head") } + atomic.AddInt32(&r.statShrink, 1) go nh.initBuckets() } } @@ -216,95 +259,134 @@ func (b *mBucket) delete(r *Cache, h *mNode, hash uint32, ns, key uint64) (done, return true, deleted } -type mNode struct { - buckets []unsafe.Pointer // []*mBucket - mask uint32 - pred unsafe.Pointer // *mNode - resizeInProgess int32 +type mHead struct { + buckets []mBucket + mask uint32 + predecessor unsafe.Pointer // *mNode + resizeInProgress int32 overflow int32 - growThreshold int32 - shrinkThreshold int32 + growThreshold int64 + shrinkThreshold int64 } -func (n *mNode) initBucket(i uint32) *mBucket { - if b := (*mBucket)(atomic.LoadPointer(&n.buckets[i])); b != nil { +func (h *mHead) initBucket(i uint32) *mBucket { + b := &h.buckets[i] + b.mu.Lock() + if b.state >= bucketInitialized { + b.mu.Unlock() return b } - p := (*mNode)(atomic.LoadPointer(&n.pred)) - if p != nil { - var node []*Node - if n.mask > p.mask { - // Grow. - pb := (*mBucket)(atomic.LoadPointer(&p.buckets[i&p.mask])) - if pb == nil { - pb = p.initBucket(i & p.mask) - } - m := pb.freeze() - // Split nodes. - for _, x := range m { - if x.hash&n.mask == i { - node = append(node, x) - } - } - } else { - // Shrink. - pb0 := (*mBucket)(atomic.LoadPointer(&p.buckets[i])) - if pb0 == nil { - pb0 = p.initBucket(i) - } - pb1 := (*mBucket)(atomic.LoadPointer(&p.buckets[i+uint32(len(n.buckets))])) - if pb1 == nil { - pb1 = p.initBucket(i + uint32(len(n.buckets))) - } - m0 := pb0.freeze() - m1 := pb1.freeze() - // Merge nodes. - node = make([]*Node, 0, len(m0)+len(m1)) - node = append(node, m0...) - node = append(node, m1...) - } - b := &mBucket{node: node} - if atomic.CompareAndSwapPointer(&n.buckets[i], nil, unsafe.Pointer(b)) { - if len(node) > mOverflowThreshold { - atomic.AddInt32(&n.overflow, int32(len(node)-mOverflowThreshold)) + p := (*mHead)(atomic.LoadPointer(&h.predecessor)) + if p == nil { + panic("BUG: uninitialized bucket doesn't have predecessor") + } + + var nodes mNodes + if h.mask > p.mask { + // Grow. + m := p.initBucket(i & p.mask).freeze() + // Split nodes. + for _, x := range m { + if x.hash&h.mask == i { + nodes = append(nodes, x) } - return b } + } else { + // Shrink. + m0 := p.initBucket(i).freeze() + m1 := p.initBucket(i + uint32(len(h.buckets))).freeze() + // Merge nodes. + nodes = make(mNodes, 0, len(m0)+len(m1)) + nodes = append(nodes, m0...) + nodes = append(nodes, m1...) + nodes.sort() + } + b.nodes = nodes + b.state = bucketInitialized + b.mu.Unlock() + return b +} + +func (h *mHead) initBuckets() { + for i := range h.buckets { + h.initBucket(uint32(i)) } + atomic.StorePointer(&h.predecessor, nil) +} - return (*mBucket)(atomic.LoadPointer(&n.buckets[i])) +func (h *mHead) enumerateNodesWithCB(f func([]*Node)) { + var nodes []*Node + for x := range h.buckets { + b := h.initBucket(uint32(x)) + + b.mu.Lock() + nodes = append(nodes, b.nodes...) + b.mu.Unlock() + f(nodes) + } } -func (n *mNode) initBuckets() { - for i := range n.buckets { - n.initBucket(uint32(i)) +func (h *mHead) enumerateNodesByNS(ns uint64) []*Node { + var nodes []*Node + for x := range h.buckets { + b := h.initBucket(uint32(x)) + + b.mu.Lock() + i := b.nodes.search(ns, 0) + for ; i < len(b.nodes); i++ { + n := b.nodes[i] + if n.ns != ns { + break + } + nodes = append(nodes, n) + } + b.mu.Unlock() } - atomic.StorePointer(&n.pred, nil) + return nodes +} + +type Stats struct { + Buckets int + Nodes int64 + Size int64 + GrowCount int32 + ShrinkCount int32 + HitCount int64 + MissCount int64 + SetCount int64 + DelCount int64 } // Cache is a 'cache map'. type Cache struct { mu sync.RWMutex mHead unsafe.Pointer // *mNode - nodes int32 - size int32 cacher Cacher closed bool + + statNodes int64 + statSize int64 + statGrow int32 + statShrink int32 + statHit int64 + statMiss int64 + statSet int64 + statDel int64 } // NewCache creates a new 'cache map'. The cacher is optional and // may be nil. func NewCache(cacher Cacher) *Cache { - h := &mNode{ - buckets: make([]unsafe.Pointer, mInitialSize), + h := &mHead{ + buckets: make([]mBucket, mInitialSize), mask: mInitialSize - 1, - growThreshold: int32(mInitialSize * mOverflowThreshold), + growThreshold: int64(mInitialSize * mOverflowThreshold), shrinkThreshold: 0, } for i := range h.buckets { - h.buckets[i] = unsafe.Pointer(&mBucket{}) + h.buckets[i].state = bucketInitialized } r := &Cache{ mHead: unsafe.Pointer(h), @@ -313,14 +395,20 @@ func NewCache(cacher Cacher) *Cache { return r } -func (r *Cache) getBucket(hash uint32) (*mNode, *mBucket) { - h := (*mNode)(atomic.LoadPointer(&r.mHead)) +func (r *Cache) getBucket(hash uint32) (*mHead, *mBucket) { + h := (*mHead)(atomic.LoadPointer(&r.mHead)) i := hash & h.mask - b := (*mBucket)(atomic.LoadPointer(&h.buckets[i])) - if b == nil { - b = h.initBucket(i) - } - return h, b + return h, h.initBucket(i) +} + +func (r *Cache) enumerateNodesWithCB(f func([]*Node)) { + h := (*mHead)(atomic.LoadPointer(&r.mHead)) + h.enumerateNodesWithCB(f) +} + +func (r *Cache) enumerateNodesByNS(ns uint64) []*Node { + h := (*mHead)(atomic.LoadPointer(&r.mHead)) + return h.enumerateNodesByNS(ns) } func (r *Cache) delete(n *Node) bool { @@ -333,14 +421,29 @@ func (r *Cache) delete(n *Node) bool { } } +// GetStats returns cache statistics. +func (r *Cache) GetStats() Stats { + return Stats{ + Buckets: len((*mHead)(atomic.LoadPointer(&r.mHead)).buckets), + Nodes: atomic.LoadInt64(&r.statNodes), + Size: atomic.LoadInt64(&r.statSize), + GrowCount: atomic.LoadInt32(&r.statGrow), + ShrinkCount: atomic.LoadInt32(&r.statShrink), + HitCount: atomic.LoadInt64(&r.statHit), + MissCount: atomic.LoadInt64(&r.statMiss), + SetCount: atomic.LoadInt64(&r.statSet), + DelCount: atomic.LoadInt64(&r.statDel), + } +} + // Nodes returns number of 'cache node' in the map. func (r *Cache) Nodes() int { - return int(atomic.LoadInt32(&r.nodes)) + return int(atomic.LoadInt64(&r.statNodes)) } // Size returns sums of 'cache node' size in the map. func (r *Cache) Size() int { - return int(atomic.LoadInt32(&r.size)) + return int(atomic.LoadInt64(&r.statSize)) } // Capacity returns cache capacity. @@ -374,14 +477,20 @@ func (r *Cache) Get(ns, key uint64, setFunc func() (size int, value Value)) *Han hash := murmur32(ns, key, 0xf00) for { h, b := r.getBucket(hash) - done, _, n := b.get(r, h, hash, ns, key, setFunc == nil) + done, created, n := b.get(r, h, hash, ns, key, setFunc == nil) if done { + if created || n == nil { + atomic.AddInt64(&r.statMiss, 1) + } else { + atomic.AddInt64(&r.statHit, 1) + } + if n != nil { n.mu.Lock() if n.value == nil { if setFunc == nil { n.mu.Unlock() - n.unref() + n.unRefInternal(false) return nil } @@ -389,10 +498,11 @@ func (r *Cache) Get(ns, key uint64, setFunc func() (size int, value Value)) *Han if n.value == nil { n.size = 0 n.mu.Unlock() - n.unref() + n.unRefInternal(false) return nil } - atomic.AddInt32(&r.size, int32(n.size)) + atomic.AddInt64(&r.statSet, 1) + atomic.AddInt64(&r.statSize, int64(n.size)) } n.mu.Unlock() if r.cacher != nil { @@ -412,11 +522,11 @@ func (r *Cache) Get(ns, key uint64, setFunc func() (size int, value Value)) *Han // only attributed to the particular 'cache node', so when a 'cache node' // is recreated it will not be banned. // -// If onDel is not nil, then it will be executed if such 'cache node' +// If delFunc is not nil, then it will be executed if such 'cache node' // doesn't exist or once the 'cache node' is released. // // Delete return true is such 'cache node' exist. -func (r *Cache) Delete(ns, key uint64, onDel func()) bool { +func (r *Cache) Delete(ns, key uint64, delFunc func()) bool { r.mu.RLock() defer r.mu.RUnlock() if r.closed { @@ -429,15 +539,15 @@ func (r *Cache) Delete(ns, key uint64, onDel func()) bool { done, _, n := b.get(r, h, hash, ns, key, true) if done { if n != nil { - if onDel != nil { + if delFunc != nil { n.mu.Lock() - n.onDel = append(n.onDel, onDel) + n.delFuncs = append(n.delFuncs, delFunc) n.mu.Unlock() } if r.cacher != nil { r.cacher.Ban(n) } - n.unref() + n.unRefInternal(true) return true } @@ -445,8 +555,8 @@ func (r *Cache) Delete(ns, key uint64, onDel func()) bool { } } - if onDel != nil { - onDel() + if delFunc != nil { + delFunc() } return false @@ -472,7 +582,7 @@ func (r *Cache) Evict(ns, key uint64) bool { if r.cacher != nil { r.cacher.Evict(n) } - n.unref() + n.unRefInternal(true) return true } @@ -484,7 +594,7 @@ func (r *Cache) Evict(ns, key uint64) bool { } // EvictNS evicts 'cache node' with the given namespace. This will -// simply call Cacher.EvictNS. +// simply call Cacher.Evict on all nodes with the given namespace. func (r *Cache) EvictNS(ns uint64) { r.mu.RLock() defer r.mu.RUnlock() @@ -493,10 +603,21 @@ func (r *Cache) EvictNS(ns uint64) { } if r.cacher != nil { - r.cacher.EvictNS(ns) + nodes := r.enumerateNodesByNS(ns) + for _, n := range nodes { + r.cacher.Evict(n) + } } } +func (r *Cache) evictAll() { + r.enumerateNodesWithCB(func(nodes []*Node) { + for _, n := range nodes { + r.cacher.Evict(n) + } + }) +} + // EvictAll evicts all 'cache node'. This will simply call Cacher.EvictAll. func (r *Cache) EvictAll() { r.mu.RLock() @@ -506,66 +627,46 @@ func (r *Cache) EvictAll() { } if r.cacher != nil { - r.cacher.EvictAll() + r.evictAll() } } -// Close closes the 'cache map' and forcefully releases all 'cache node'. -func (r *Cache) Close() error { +// Close closes the 'cache map'. +// All 'Cache' method is no-op after 'cache map' is closed. +// All 'cache node' will be evicted from 'cacher'. +// +// If 'force' is true then all 'cache node' will be forcefully released +// even if the 'node ref' is not zero. +func (r *Cache) Close(force bool) { + var head *mHead + // Hold RW-lock to make sure no more in-flight operations. r.mu.Lock() if !r.closed { r.closed = true + head = (*mHead)(atomic.LoadPointer(&r.mHead)) + atomic.StorePointer(&r.mHead, nil) + } + r.mu.Unlock() - h := (*mNode)(r.mHead) - h.initBuckets() + if head != nil { + head.enumerateNodesWithCB(func(nodes []*Node) { + for _, n := range nodes { + // Zeroing ref. Prevent unRefExternal to call finalizer. + if force { + atomic.StoreInt32(&n.ref, 0) + } - for i := range h.buckets { - b := (*mBucket)(h.buckets[i]) - for _, n := range b.node { - // Call releaser. - if n.value != nil { - if r, ok := n.value.(util.Releaser); ok { - r.Release() - } - n.value = nil + // Evict from cacher. + if r.cacher != nil { + r.cacher.Evict(n) } - // Call OnDel. - for _, f := range n.onDel { - f() + if force { + n.callFinalizer() } - n.onDel = nil } - } + }) } - r.mu.Unlock() - - // Avoid deadlock. - if r.cacher != nil { - if err := r.cacher.Close(); err != nil { - return err - } - } - return nil -} - -// CloseWeak closes the 'cache map' and evict all 'cache node' from cacher, but -// unlike Close it doesn't forcefully releases 'cache node'. -func (r *Cache) CloseWeak() error { - r.mu.Lock() - if !r.closed { - r.closed = true - } - r.mu.Unlock() - - // Avoid deadlock. - if r.cacher != nil { - r.cacher.EvictAll() - if err := r.cacher.Close(); err != nil { - return err - } - } - return nil } // Node is a 'cache node'. @@ -579,8 +680,8 @@ type Node struct { size int value Value - ref int32 - onDel []func() + ref int32 + delFuncs []func() CacheData unsafe.Pointer } @@ -618,17 +719,39 @@ func (n *Node) GetHandle() *Handle { return &Handle{unsafe.Pointer(n)} } -func (n *Node) unref() { +func (n *Node) callFinalizer() { + // Call releaser. + if n.value != nil { + if r, ok := n.value.(util.Releaser); ok { + r.Release() + } + n.value = nil + } + + // Call delete funcs. + for _, f := range n.delFuncs { + f() + } + n.delFuncs = nil +} + +func (n *Node) unRefInternal(updateStat bool) { if atomic.AddInt32(&n.ref, -1) == 0 { n.r.delete(n) + if updateStat { + atomic.AddInt64(&n.r.statDel, 1) + } } } -func (n *Node) unrefLocked() { +func (n *Node) unRefExternal() { if atomic.AddInt32(&n.ref, -1) == 0 { n.r.mu.RLock() - if !n.r.closed { + if n.r.closed { + n.callFinalizer() + } else { n.r.delete(n) + atomic.AddInt64(&n.r.statDel, 1) } n.r.mu.RUnlock() } @@ -654,7 +777,7 @@ func (h *Handle) Release() { nPtr := atomic.LoadPointer(&h.n) if nPtr != nil && atomic.CompareAndSwapPointer(&h.n, nPtr, nil) { n := (*Node)(nPtr) - n.unrefLocked() + n.unRefExternal() } } diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/cache/lru.go b/vendor/github.com/syndtr/goleveldb/leveldb/cache/lru.go index d9a84cde..383ad5a5 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/cache/lru.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/cache/lru.go @@ -142,51 +142,14 @@ func (r *lru) Evict(n *Node) { r.mu.Unlock() return } + rn.remove() + r.used -= n.Size() n.CacheData = nil r.mu.Unlock() rn.h.Release() } -func (r *lru) EvictNS(ns uint64) { - var evicted []*lruNode - - r.mu.Lock() - for e := r.recent.prev; e != &r.recent; { - rn := e - e = e.prev - if rn.n.NS() == ns { - rn.remove() - rn.n.CacheData = nil - r.used -= rn.n.Size() - evicted = append(evicted, rn) - } - } - r.mu.Unlock() - - for _, rn := range evicted { - rn.h.Release() - } -} - -func (r *lru) EvictAll() { - r.mu.Lock() - back := r.recent.prev - for rn := back; rn != &r.recent; rn = rn.prev { - rn.n.CacheData = nil - } - r.reset() - r.mu.Unlock() - - for rn := back; rn != &r.recent; rn = rn.prev { - rn.h.Release() - } -} - -func (r *lru) Close() error { - return nil -} - // NewLRU create a new LRU-cache. func NewLRU(capacity int) Cacher { r := &lru{capacity: capacity} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db.go b/vendor/github.com/syndtr/goleveldb/leveldb/db.go index 74e98269..b2724cd9 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/db.go @@ -17,6 +17,7 @@ import ( "sync/atomic" "time" + "github.com/syndtr/goleveldb/leveldb/cache" "github.com/syndtr/goleveldb/leveldb/errors" "github.com/syndtr/goleveldb/leveldb/iterator" "github.com/syndtr/goleveldb/leveldb/journal" @@ -141,7 +142,6 @@ func openDB(s *session) (*DB, error) { } return nil, err } - } // Doesn't need to be included in the wait group. @@ -149,7 +149,9 @@ func openDB(s *session) (*DB, error) { go db.mpoolDrain() if readOnly { - db.SetReadOnly() + if err := db.SetReadOnly(); err != nil { + return nil, err + } } else { db.closeW.Add(2) go db.tCompaction() @@ -311,15 +313,23 @@ func recoverTable(s *session, o *opt.Options) error { return } defer func() { - writer.Close() + if cerr := writer.Close(); cerr != nil { + if err == nil { + err = cerr + } else { + err = fmt.Errorf("error recovering table (%v); error closing (%v)", err, cerr) + } + } if err != nil { - s.stor.Remove(tmpFd) + if rerr := s.stor.Remove(tmpFd); rerr != nil { + err = fmt.Errorf("error recovering table (%v); error removing (%v)", err, rerr) + } tmpFd = storage.FileDesc{} } }() // Copy entries. - tw := table.NewWriter(writer, o) + tw := table.NewWriter(writer, o, nil, 0) for iter.Next() { key := iter.Key() if validInternalKey(key) { @@ -397,7 +407,7 @@ func recoverTable(s *session, o *opt.Options) error { tSeq = seq } if imin == nil { - imin = append([]byte{}, key...) + imin = append([]byte(nil), key...) } imax = append(imax[:0], key...) } @@ -530,7 +540,8 @@ func (db *DB) recoverJournal() error { if jr == nil { jr = journal.NewReader(fr, dropper{db.s, fd}, strict, checksum) } else { - jr.Reset(fr, dropper{db.s, fd}, strict, checksum) + // Ignore the error here + _ = jr.Reset(fr, dropper{db.s, fd}, strict, checksum) } // Flush memdb and remove obsolete journal file. @@ -550,7 +561,10 @@ func (db *DB) recoverJournal() error { } rec.resetAddedTables() - db.s.stor.Remove(ofd) + if err := db.s.stor.Remove(ofd); err != nil { + fr.Close() + return err + } ofd = storage.FileDesc{} } @@ -634,7 +648,9 @@ func (db *DB) recoverJournal() error { // Remove the last obsolete journal file. if !ofd.Zero() { - db.s.stor.Remove(ofd) + if err := db.s.stor.Remove(ofd); err != nil { + return err + } } return nil @@ -688,7 +704,9 @@ func (db *DB) recoverJournalRO() error { if jr == nil { jr = journal.NewReader(fr, dropper{db.s, fd}, strict, checksum) } else { - jr.Reset(fr, dropper{db.s, fd}, strict, checksum) + if err := jr.Reset(fr, dropper{db.s, fd}, strict, checksum); err != nil { + return err + } } // Replay journal to memdb. @@ -765,7 +783,7 @@ func (db *DB) get(auxm *memdb.DB, auxt tFiles, key []byte, seq uint64, ro *opt.R if auxm != nil { if ok, mv, me := memGet(auxm, ikey, db.s.icmp); ok { - return append([]byte{}, mv...), me + return append([]byte(nil), mv...), me } } @@ -777,7 +795,7 @@ func (db *DB) get(auxm *memdb.DB, auxt tFiles, key []byte, seq uint64, ro *opt.R defer m.decref() if ok, mv, me := memGet(m.DB, ikey, db.s.icmp); ok { - return append([]byte{}, mv...), me + return append([]byte(nil), mv...), me } } @@ -1002,15 +1020,15 @@ func (db *DB) GetProperty(name string) (value string, err error) { } } case p == "blockpool": - value = fmt.Sprintf("%v", db.s.tops.bpool) + value = fmt.Sprintf("%v", db.s.tops.blockBuffer) case p == "cachedblock": - if db.s.tops.bcache != nil { - value = fmt.Sprintf("%d", db.s.tops.bcache.Size()) + if db.s.tops.blockCache != nil { + value = fmt.Sprintf("%d", db.s.tops.blockCache.Size()) } else { value = "" } case p == "openedtables": - value = fmt.Sprintf("%d", db.s.tops.cache.Size()) + value = fmt.Sprintf("%d", db.s.tops.fileCache.Size()) case p == "alivesnaps": value = fmt.Sprintf("%d", atomic.LoadInt32(&db.aliveSnaps)) case p == "aliveiters": @@ -1037,6 +1055,9 @@ type DBStats struct { BlockCacheSize int OpenedTablesCount int + FileCache cache.Stats + BlockCache cache.Stats + LevelSizes Sizes LevelTablesCounts []int LevelRead Sizes @@ -1062,13 +1083,20 @@ func (db *DB) Stats(s *DBStats) error { s.WriteDelayDuration = time.Duration(atomic.LoadInt64(&db.cWriteDelay)) s.WritePaused = atomic.LoadInt32(&db.inWritePaused) == 1 - s.OpenedTablesCount = db.s.tops.cache.Size() - if db.s.tops.bcache != nil { - s.BlockCacheSize = db.s.tops.bcache.Size() + s.OpenedTablesCount = db.s.tops.fileCache.Size() + if db.s.tops.blockCache != nil { + s.BlockCacheSize = db.s.tops.blockCache.Size() } else { s.BlockCacheSize = 0 } + s.FileCache = db.s.tops.fileCache.GetStats() + if db.s.tops.blockCache != nil { + s.BlockCache = db.s.tops.blockCache.GetStats() + } else { + s.BlockCache = cache.Stats{} + } + s.AliveIterators = atomic.LoadInt32(&db.aliveIters) s.AliveSnapshots = atomic.LoadInt32(&db.aliveSnaps) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_compaction.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_compaction.go index 6b70eb2c..cc275ace 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_compaction.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/db_compaction.go @@ -7,6 +7,7 @@ package leveldb import ( + "fmt" "sync" "sync/atomic" "time" @@ -272,7 +273,7 @@ func (db *DB) memCompaction() { } defer mdb.decref() - db.logf("memdb@flush N·%d S·%s", mdb.Len(), shortenb(mdb.Size())) + db.logf("memdb@flush N·%d S·%s", mdb.Len(), shortenb(int64(mdb.Size()))) // Don't compact empty memdb. if mdb.Len() == 0 { @@ -350,11 +351,11 @@ func (db *DB) memCompaction() { } type tableCompactionBuilder struct { - db *DB - s *session - c *compaction - rec *sessionRecord - stat0, stat1 *cStatStaging + db *DB + s *session + c *compaction + rec *sessionRecord + stat1 *cStatStaging snapHasLastUkey bool snapLastUkey []byte @@ -389,7 +390,7 @@ func (b *tableCompactionBuilder) appendKV(key, value []byte) error { // Create new table. var err error - b.tw, err = b.s.tops.create() + b.tw, err = b.s.tops.create(b.tableSize) if err != nil { return err } @@ -410,29 +411,40 @@ func (b *tableCompactionBuilder) flush() error { } b.rec.addTableFile(b.c.sourceLevel+1, t) b.stat1.write += t.size - b.s.logf("table@build created L%d@%d N·%d S·%s %q:%q", b.c.sourceLevel+1, t.fd.Num, b.tw.tw.EntriesLen(), shortenb(int(t.size)), t.imin, t.imax) + b.s.logf("table@build created L%d@%d N·%d S·%s %q:%q", b.c.sourceLevel+1, t.fd.Num, b.tw.tw.EntriesLen(), shortenb(t.size), t.imin, t.imax) b.tw = nil return nil } -func (b *tableCompactionBuilder) cleanup() { +func (b *tableCompactionBuilder) cleanup() error { if b.tw != nil { - b.tw.drop() + if err := b.tw.drop(); err != nil { + return err + } b.tw = nil } + return nil } -func (b *tableCompactionBuilder) run(cnt *compactionTransactCounter) error { +func (b *tableCompactionBuilder) run(cnt *compactionTransactCounter) (err error) { snapResumed := b.snapIter > 0 hasLastUkey := b.snapHasLastUkey // The key might has zero length, so this is necessary. - lastUkey := append([]byte{}, b.snapLastUkey...) + lastUkey := append([]byte(nil), b.snapLastUkey...) lastSeq := b.snapLastSeq b.kerrCnt = b.snapKerrCnt b.dropCnt = b.snapDropCnt // Restore compaction state. b.c.restore() - defer b.cleanup() + defer func() { + if cerr := b.cleanup(); cerr != nil { + if err == nil { + err = cerr + } else { + err = fmt.Errorf("tableCompactionBuilder error: %v, cleanup error (%v)", err, cerr) + } + } + }() b.stat1.startTimer() defer b.stat1.stopTimer() @@ -563,7 +575,7 @@ func (db *DB) tableCompaction(c *compaction, noTrivial bool) { rec.delTable(c.sourceLevel+i, t.fd.Num) } } - sourceSize := int(stats[0].read + stats[1].read) + sourceSize := stats[0].read + stats[1].read minSeq := db.minSeq() db.logf("table@compaction L%d·%d -> L%d·%d S·%s Q·%d", c.sourceLevel, len(c.levels[0]), c.sourceLevel+1, len(c.levels[1]), shortenb(sourceSize), minSeq) @@ -584,7 +596,7 @@ func (db *DB) tableCompaction(c *compaction, noTrivial bool) { db.compactionCommit("table", rec) stats[1].stopTimer() - resultSize := int(stats[1].write) + resultSize := stats[1].write db.logf("table@compaction committed F%s S%s Ke·%d D·%d T·%v", sint(len(rec.addedTables)-len(rec.deletedTables)), sshortenb(resultSize-sourceSize), b.kerrCnt, b.dropCnt, stats[1].duration) // Save compaction stats @@ -655,10 +667,7 @@ func (db *DB) tableNeedCompaction() bool { func (db *DB) resumeWrite() bool { v := db.s.version() defer v.release() - if v.tLen(0) < db.s.o.GetWriteL0PauseTrigger() { - return true - } - return false + return v.tLen(0) < db.s.o.GetWriteL0PauseTrigger() } func (db *DB) pauseCompaction(ch chan<- struct{}) { @@ -681,7 +690,7 @@ type cAuto struct { func (r cAuto) ack(err error) { if r.ackC != nil { defer func() { - recover() + _ = recover() }() r.ackC <- err } @@ -696,7 +705,7 @@ type cRange struct { func (r cRange) ack(err error) { if r.ackC != nil { defer func() { - recover() + _ = recover() }() r.ackC <- err } diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_iter.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_iter.go index e6e8ca59..ded13d3e 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_iter.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/db_iter.go @@ -7,7 +7,6 @@ package leveldb import ( - "errors" "math/rand" "runtime" "sync" @@ -18,10 +17,6 @@ import ( "github.com/syndtr/goleveldb/leveldb/util" ) -var ( - errInvalidInternalKey = errors.New("leveldb: Iterator: invalid internal key") -) - type memdbReleaser struct { once sync.Once m *memDB diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_state.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_state.go index 65e1c54b..29430fee 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_state.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/db_state.go @@ -137,8 +137,12 @@ func (db *DB) newMem(n int) (mem *memDB, err error) { if db.journal == nil { db.journal = journal.NewWriter(w) } else { - db.journal.Reset(w) - db.journalWriter.Close() + if err := db.journal.Reset(w); err != nil { + return nil, err + } + if err := db.journalWriter.Close(); err != nil { + return nil, err + } db.frozenJournalFd = db.journalFd } db.journalWriter = w @@ -181,13 +185,6 @@ func (db *DB) getEffectiveMem() *memDB { return db.mem } -// Check whether we has frozen memdb. -func (db *DB) hasFrozenMem() bool { - db.memMu.RLock() - defer db.memMu.RUnlock() - return db.frozenMem != nil -} - // Get frozen memdb. func (db *DB) getFrozenMem() *memDB { db.memMu.RLock() diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_transaction.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_transaction.go index 21d1e512..b7b82fd8 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_transaction.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/db_transaction.go @@ -110,7 +110,7 @@ func (tr *Transaction) flush() error { tr.tables = append(tr.tables, t) tr.rec.addTableFile(0, t) tr.stats.write += t.size - tr.db.logf("transaction@flush created L0@%d N·%d S·%s %q:%q", t.fd.Num, n, shortenb(int(t.size)), t.imin, t.imax) + tr.db.logf("transaction@flush created L0@%d N·%d S·%s %q:%q", t.fd.Num, n, shortenb(t.size), t.imin, t.imax) } return nil } @@ -244,7 +244,7 @@ func (tr *Transaction) Commit() error { // Additionally, wait compaction when certain threshold reached. // Ignore error, returns error only if transaction can't be committed. - tr.db.waitCompaction() + _ = tr.db.waitCompaction() } // Only mark as done if transaction committed successfully. tr.setDone() diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_write.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_write.go index db0c1bec..18eddbe1 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_write.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/db_write.go @@ -246,7 +246,10 @@ func (db *DB) writeLocked(batch, ourBatch *Batch, merge, sync bool) error { // Rotate memdb if it's reach the threshold. if batch.internalLen >= mdbFree { - db.rotateMem(0, false) + if _, err := db.rotateMem(0, false); err != nil { + db.unlockWrite(overflow, merged, err) + return err + } } db.unlockWrite(overflow, merged, nil) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/errors/errors.go b/vendor/github.com/syndtr/goleveldb/leveldb/errors/errors.go index 8d6146b6..0c7f64b2 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/errors/errors.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/errors/errors.go @@ -73,6 +73,7 @@ func SetFd(err error, fd storage.FileDesc) error { case *ErrCorrupted: x.Fd = fd return x + default: + return err } - return err } diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/array_iter.go b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/array_iter.go index a23ab05f..1e4fe4ed 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/array_iter.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/array_iter.go @@ -88,10 +88,7 @@ func (i *basicArrayIterator) Seek(key []byte) bool { return false } i.pos = i.array.Search(key) - if i.pos >= n { - return false - } - return true + return i.pos < n } func (i *basicArrayIterator) Next() bool { diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter.go b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter.go index 939adbb9..fd0b55ad 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter.go @@ -26,10 +26,9 @@ type indexedIterator struct { index IteratorIndexer strict bool - data Iterator - err error - errf func(err error) - closed bool + data Iterator + err error + errf func(err error) } func (i *indexedIterator) setData() { diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter.go b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter.go index 1a7e29df..374e82b6 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter.go @@ -7,6 +7,8 @@ package iterator import ( + "container/heap" + "github.com/syndtr/goleveldb/leveldb/comparer" "github.com/syndtr/goleveldb/leveldb/errors" "github.com/syndtr/goleveldb/leveldb/util" @@ -33,6 +35,9 @@ type mergedIterator struct { err error errf func(err error) releaser util.Releaser + + indexes []int // the heap of iterator indexes + reverse bool //nolint: structcheck // if true, indexes is a max-heap } func assertKey(key []byte) []byte { @@ -67,16 +72,20 @@ func (i *mergedIterator) First() bool { return false } + h := i.indexHeap() + h.Reset(false) for x, iter := range i.iters { switch { case iter.First(): i.keys[x] = assertKey(iter.Key()) + h.Push(x) case i.iterErr(iter): return false default: i.keys[x] = nil } } + heap.Init(h) i.dir = dirSOI return i.next() } @@ -89,16 +98,20 @@ func (i *mergedIterator) Last() bool { return false } + h := i.indexHeap() + h.Reset(true) for x, iter := range i.iters { switch { case iter.Last(): i.keys[x] = assertKey(iter.Key()) + h.Push(x) case i.iterErr(iter): return false default: i.keys[x] = nil } } + heap.Init(h) i.dir = dirEOI return i.prev() } @@ -111,35 +124,31 @@ func (i *mergedIterator) Seek(key []byte) bool { return false } + h := i.indexHeap() + h.Reset(false) for x, iter := range i.iters { switch { case iter.Seek(key): i.keys[x] = assertKey(iter.Key()) + h.Push(x) case i.iterErr(iter): return false default: i.keys[x] = nil } } + heap.Init(h) i.dir = dirSOI return i.next() } func (i *mergedIterator) next() bool { - var key []byte - if i.dir == dirForward { - key = i.keys[i.index] - } - for x, tkey := range i.keys { - if tkey != nil && (key == nil || i.cmp.Compare(tkey, key) < 0) { - key = tkey - i.index = x - } - } - if key == nil { + h := i.indexHeap() + if h.Len() == 0 { i.dir = dirEOI return false } + i.index = heap.Pop(h).(int) i.dir = dirForward return true } @@ -156,7 +165,7 @@ func (i *mergedIterator) Next() bool { case dirSOI: return i.First() case dirBackward: - key := append([]byte{}, i.keys[i.index]...) + key := append([]byte(nil), i.keys[i.index]...) if !i.Seek(key) { return false } @@ -168,6 +177,7 @@ func (i *mergedIterator) Next() bool { switch { case iter.Next(): i.keys[x] = assertKey(iter.Key()) + heap.Push(i.indexHeap(), x) case i.iterErr(iter): return false default: @@ -177,20 +187,12 @@ func (i *mergedIterator) Next() bool { } func (i *mergedIterator) prev() bool { - var key []byte - if i.dir == dirBackward { - key = i.keys[i.index] - } - for x, tkey := range i.keys { - if tkey != nil && (key == nil || i.cmp.Compare(tkey, key) > 0) { - key = tkey - i.index = x - } - } - if key == nil { + h := i.indexHeap() + if h.Len() == 0 { i.dir = dirSOI return false } + i.index = heap.Pop(h).(int) i.dir = dirBackward return true } @@ -207,7 +209,9 @@ func (i *mergedIterator) Prev() bool { case dirEOI: return i.Last() case dirForward: - key := append([]byte{}, i.keys[i.index]...) + key := append([]byte(nil), i.keys[i.index]...) + h := i.indexHeap() + h.Reset(true) for x, iter := range i.iters { if x == i.index { continue @@ -216,12 +220,14 @@ func (i *mergedIterator) Prev() bool { switch { case seek && iter.Prev(), !seek && iter.Last(): i.keys[x] = assertKey(iter.Key()) + h.Push(x) case i.iterErr(iter): return false default: i.keys[x] = nil } } + heap.Init(h) } x := i.index @@ -229,6 +235,7 @@ func (i *mergedIterator) Prev() bool { switch { case iter.Prev(): i.keys[x] = assertKey(iter.Key()) + heap.Push(i.indexHeap(), x) case i.iterErr(iter): return false default: @@ -259,6 +266,7 @@ func (i *mergedIterator) Release() { } i.iters = nil i.keys = nil + i.indexes = nil if i.releaser != nil { i.releaser.Release() i.releaser = nil @@ -284,6 +292,10 @@ func (i *mergedIterator) SetErrorCallback(f func(err error)) { i.errf = f } +func (i *mergedIterator) indexHeap() *indexHeap { + return (*indexHeap)(i) +} + // NewMergedIterator returns an iterator that merges its input. Walking the // resultant iterator will return all key/value pairs of all input iterators // in strictly increasing key order, as defined by cmp. @@ -296,9 +308,43 @@ func (i *mergedIterator) SetErrorCallback(f func(err error)) { // continue to the next 'input iterator'. func NewMergedIterator(iters []Iterator, cmp comparer.Comparer, strict bool) Iterator { return &mergedIterator{ - iters: iters, - cmp: cmp, - strict: strict, - keys: make([][]byte, len(iters)), + iters: iters, + cmp: cmp, + strict: strict, + keys: make([][]byte, len(iters)), + indexes: make([]int, 0, len(iters)), } } + +// indexHeap implements heap.Interface. +type indexHeap mergedIterator + +func (h *indexHeap) Len() int { return len(h.indexes) } +func (h *indexHeap) Less(i, j int) bool { + i, j = h.indexes[i], h.indexes[j] + r := h.cmp.Compare(h.keys[i], h.keys[j]) + if h.reverse { + return r > 0 + } + return r < 0 +} + +func (h *indexHeap) Swap(i, j int) { + h.indexes[i], h.indexes[j] = h.indexes[j], h.indexes[i] +} + +func (h *indexHeap) Push(value interface{}) { + h.indexes = append(h.indexes, value.(int)) +} + +func (h *indexHeap) Pop() interface{} { + e := len(h.indexes) - 1 + popped := h.indexes[e] + h.indexes = h.indexes[:e] + return popped +} + +func (h *indexHeap) Reset(reverse bool) { + h.reverse = reverse + h.indexes = h.indexes[:0] +} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/journal/journal.go b/vendor/github.com/syndtr/goleveldb/leveldb/journal/journal.go index d094c3d0..f7f8b540 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/journal/journal.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/journal/journal.go @@ -354,6 +354,8 @@ type Writer struct { // buf[:written] has already been written to w. // written is zero unless Flush has been called. written int + // blockNumber is the zero based block number currently held in buf. + blockNumber int64 // first is whether the current chunk is the first chunk of the journal. first bool // pending is whether a chunk is buffered but not yet written. @@ -402,6 +404,7 @@ func (w *Writer) writeBlock() { w.i = 0 w.j = headerSize w.written = 0 + w.blockNumber++ } // writePending finishes the current journal and writes the buffer to the @@ -457,6 +460,7 @@ func (w *Writer) Reset(writer io.Writer) (err error) { w.i = 0 w.j = 0 w.written = 0 + w.blockNumber = 0 w.first = false w.pending = false w.err = nil @@ -474,7 +478,7 @@ func (w *Writer) Next() (io.Writer, error) { w.fillHeader(true) } w.i = w.j - w.j = w.j + headerSize + w.j += headerSize // Check if there is room in the block for the header. if w.j > blockSize { // Fill in the rest of the block with zeroes. @@ -491,6 +495,14 @@ func (w *Writer) Next() (io.Writer, error) { return singleWriter{w, w.seq}, nil } +// Size returns the current size of the file. +func (w *Writer) Size() int64 { + if w == nil { + return 0 + } + return w.blockNumber*blockSize + int64(w.j) +} + type singleWriter struct { w *Writer seq int diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/key.go b/vendor/github.com/syndtr/goleveldb/leveldb/key.go index ad8f51ec..dc7be1fa 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/key.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/key.go @@ -25,7 +25,7 @@ func (e *ErrInternalKeyCorrupted) Error() string { } func newErrInternalKeyCorrupted(ikey []byte, reason string) error { - return errors.NewErrCorrupted(storage.FileDesc{}, &ErrInternalKeyCorrupted{append([]byte{}, ikey...), reason}) + return errors.NewErrCorrupted(storage.FileDesc{}, &ErrInternalKeyCorrupted{append([]byte(nil), ikey...), reason}) } type keyType uint @@ -90,7 +90,7 @@ func parseInternalKey(ik []byte) (ukey []byte, seq uint64, kt keyType, err error return nil, 0, 0, newErrInternalKeyCorrupted(ik, "invalid length") } num := binary.LittleEndian.Uint64(ik[len(ik)-8:]) - seq, kt = uint64(num>>8), keyType(num&0xff) + seq, kt = num>>8, keyType(num&0xff) if kt > keyTypeVal { return nil, 0, 0, newErrInternalKeyCorrupted(ik, "invalid type") } @@ -124,7 +124,7 @@ func (ik internalKey) num() uint64 { func (ik internalKey) parseNum() (seq uint64, kt keyType) { num := ik.num() - seq, kt = uint64(num>>8), keyType(num&0xff) + seq, kt = num>>8, keyType(num&0xff) if kt > keyTypeVal { panic(fmt.Sprintf("leveldb: internal key %q, len=%d: invalid type %#x", []byte(ik), len(ik), kt)) } diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/opt/options.go b/vendor/github.com/syndtr/goleveldb/leveldb/opt/options.go index dead5fdf..48fb0416 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/opt/options.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/opt/options.go @@ -41,6 +41,7 @@ var ( DefaultWriteL0PauseTrigger = 12 DefaultWriteL0SlowdownTrigger = 8 DefaultFilterBaseLg = 11 + DefaultMaxManifestFileSize = int64(64 * MiB) ) // Cacher is a caching algorithm. @@ -48,23 +49,60 @@ type Cacher interface { New(capacity int) cache.Cacher } -type CacherFunc struct { +type cacherFunc struct { NewFunc func(capacity int) cache.Cacher } -func (f *CacherFunc) New(capacity int) cache.Cacher { +func (f *cacherFunc) New(capacity int) cache.Cacher { if f != nil && f.NewFunc != nil { return f.NewFunc(capacity) } return nil } +func CacherFunc(f func(capacity int) cache.Cacher) Cacher { + return &cacherFunc{f} +} + +type passthroughCacher struct { + Cacher cache.Cacher +} + +func (p *passthroughCacher) New(capacity int) cache.Cacher { + return p.Cacher +} + +// PassthroughCacher can be used to passthrough pre-initialized +// 'cacher instance'. This is useful for sharing cache over multiple +// DB instances. +// +// Shared cache example: +// +// fileCache := opt.NewLRU(500) +// blockCache := opt.NewLRU(8 * opt.MiB) +// options := &opt.Options{ +// OpenFilesCacher: fileCache, +// BlockCacher: blockCache, +// } +// db1, err1 := leveldb.OpenFile("path/to/db1", options) +// ... +// db2, err2 := leveldb.OpenFile("path/to/db2", options) +// ... +func PassthroughCacher(x cache.Cacher) Cacher { + return &passthroughCacher{x} +} + +// NewLRU creates LRU 'passthrough cacher'. +func NewLRU(capacity int) Cacher { + return PassthroughCacher(cache.NewLRU(capacity)) +} + var ( // LRUCacher is the LRU-cache algorithm. - LRUCacher = &CacherFunc{cache.NewLRU} + LRUCacher = CacherFunc(cache.NewLRU) // NoCacher is the value to disable caching algorithm. - NoCacher = &CacherFunc{} + NoCacher = CacherFunc(nil) ) // Compression is the 'sorted table' block compression algorithm to use. @@ -376,6 +414,13 @@ type Options struct { // // The default value is 11(as well as 2KB) FilterBaseLg int + + // MaxManifestFileSize is the maximum size limit of the MANIFEST-****** file. + // When the MANIFEST-****** file grows beyond this size, LevelDB will create + // a new MANIFEST file. + // + // The default value is 64 MiB. + MaxManifestFileSize int64 } func (o *Options) GetAltFilters() []filter.Filter { @@ -715,7 +760,13 @@ func (wo *WriteOptions) GetSync() bool { func GetStrict(o *Options, ro *ReadOptions, strict Strict) bool { if ro.GetStrict(StrictOverride) { return ro.GetStrict(strict) - } else { - return o.GetStrict(strict) || ro.GetStrict(strict) } + return o.GetStrict(strict) || ro.GetStrict(strict) +} + +func (o *Options) GetMaxManifestFileSize() int64 { + if o == nil || o.MaxManifestFileSize <= 0 { + return DefaultMaxManifestFileSize + } + return o.MaxManifestFileSize } diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/opt/options_darwin.go b/vendor/github.com/syndtr/goleveldb/leveldb/opt/options_darwin.go index 67b82042..e7490816 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/opt/options_darwin.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/opt/options_darwin.go @@ -1,3 +1,4 @@ +//go:build darwin // +build darwin package opt diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/opt/options_default.go b/vendor/github.com/syndtr/goleveldb/leveldb/opt/options_default.go index 97a14a89..4c9f4b05 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/opt/options_default.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/opt/options_default.go @@ -1,3 +1,4 @@ +//go:build !darwin // +build !darwin package opt diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/session.go b/vendor/github.com/syndtr/goleveldb/leveldb/session.go index e1433521..036570e0 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/session.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/session.go @@ -54,7 +54,7 @@ type session struct { stCompPtrs []internalKey // compaction pointers; need external synchronization stVersion *version // current version - ntVersionId int64 // next version id to assign + ntVersionID int64 // next version id to assign refCh chan *vTask relCh chan *vTask deltaCh chan *vDelta @@ -107,7 +107,7 @@ func (s *session) close() { } s.manifest = nil s.manifestWriter = nil - s.setVersion(nil, &version{s: s, closing: true, id: s.ntVersionId}) + s.setVersion(nil, &version{s: s, closing: true, id: s.ntVersionID}) // Close all background goroutines close(s.closeC) @@ -171,7 +171,7 @@ func (s *session) recover() (err error) { if err == nil { // save compact pointers for _, r := range rec.compPtrs { - s.setCompPtr(r.level, internalKey(r.ikey)) + s.setCompPtr(r.level, r.ikey) } // commit record to version staging staging.commit(rec) @@ -226,6 +226,9 @@ func (s *session) commit(r *sessionRecord, trivial bool) (err error) { if s.manifest == nil { // manifest journal writer not yet created, create one err = s.newManifest(r, nv) + } else if s.manifest.Size() >= s.o.GetMaxManifestFileSize() { + // pass nil sessionRecord to avoid over-reference table file + err = s.newManifest(nil, nv) } else { err = s.flushManifest(r) } diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/session_compaction.go b/vendor/github.com/syndtr/goleveldb/leveldb/session_compaction.go index b46a3e45..2fd5f32e 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/session_compaction.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/session_compaction.go @@ -48,7 +48,7 @@ func (s *session) flushMemdb(rec *sessionRecord, mdb *memdb.DB, maxLevel int) (i flushLevel := s.pickMemdbLevel(t.imin.ukey(), t.imax.ukey(), maxLevel) rec.addTableFile(flushLevel, t) - s.logf("memdb@flush created L%d@%d N·%d S·%s %q:%q", flushLevel, t.fd.Num, n, shortenb(int(t.size)), t.imin, t.imax) + s.logf("memdb@flush created L%d@%d N·%d S·%s %q:%q", flushLevel, t.fd.Num, n, shortenb(t.size), t.imin, t.imax) return flushLevel, nil } @@ -226,8 +226,8 @@ func (c *compaction) expand() { exp1 := vt1.getOverlaps(nil, c.s.icmp, xmin.ukey(), xmax.ukey(), false) if len(exp1) == len(t1) { c.s.logf("table@compaction expanding L%d+L%d (F·%d S·%s)+(F·%d S·%s) -> (F·%d S·%s)+(F·%d S·%s)", - c.sourceLevel, c.sourceLevel+1, len(t0), shortenb(int(t0.size())), len(t1), shortenb(int(t1.size())), - len(exp0), shortenb(int(exp0.size())), len(exp1), shortenb(int(exp1.size()))) + c.sourceLevel, c.sourceLevel+1, len(t0), shortenb(t0.size()), len(t1), shortenb(t1.size()), + len(exp0), shortenb(exp0.size()), len(exp1), shortenb(exp1.size())) imin, imax = xmin, xmax t0, t1 = exp0, exp1 amin, amax = append(t0, t1...).getRange(c.s.icmp) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/session_record.go b/vendor/github.com/syndtr/goleveldb/leveldb/session_record.go index 854e1aa6..b1a352f6 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/session_record.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/session_record.go @@ -201,7 +201,7 @@ func (p *sessionRecord) readUvarintMayEOF(field string, r io.ByteReader, mayEOF } x, err := binary.ReadUvarint(r) if err != nil { - if err == io.ErrUnexpectedEOF || (mayEOF == false && err == io.EOF) { + if err == io.ErrUnexpectedEOF || (!mayEOF && err == io.EOF) { p.err = errors.NewErrCorrupted(storage.FileDesc{}, &ErrManifestCorrupted{field, "short read"}) } else if strings.HasPrefix(err.Error(), "binary:") { p.err = errors.NewErrCorrupted(storage.FileDesc{}, &ErrManifestCorrupted{field, err.Error()}) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/session_util.go b/vendor/github.com/syndtr/goleveldb/leveldb/session_util.go index 730bd2cd..f467f2d4 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/session_util.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/session_util.go @@ -24,7 +24,7 @@ type dropper struct { func (d dropper) Drop(err error) { if e, ok := err.(*journal.ErrCorrupted); ok { - d.s.logf("journal@drop %s-%d S·%s %q", d.fd.Type, d.fd.Num, shortenb(e.Size), e.Reason) + d.s.logf("journal@drop %s-%d S·%s %q", d.fd.Type, d.fd.Num, shortenb(int64(e.Size)), e.Reason) } else { d.s.logf("journal@drop %s-%d %q", d.fd.Type, d.fd.Num, err) } @@ -130,7 +130,7 @@ func (s *session) refLoop() { for { // Skip any abandoned version number to prevent blocking processing. if skipAbandoned() { - next += 1 + next++ continue } // Don't bother the version that has been released. @@ -162,13 +162,13 @@ func (s *session) refLoop() { referenced[next] = struct{}{} delete(ref, next) delete(deltas, next) - next += 1 + next++ } // Use delta information to process all released versions. for { if skipAbandoned() { - next += 1 + next++ continue } if d, exist := released[next]; exist { @@ -176,7 +176,7 @@ func (s *session) refLoop() { applyDelta(d) } delete(released, next) - next += 1 + next++ continue } return @@ -396,7 +396,7 @@ func (s *session) recordCommited(rec *sessionRecord) { } for _, r := range rec.compPtrs { - s.setCompPtr(r.level, internalKey(r.ikey)) + s.setCompPtr(r.level, r.ikey) } } @@ -429,14 +429,16 @@ func (s *session) newManifest(rec *sessionRecord, v *version) (err error) { s.manifestWriter.Close() } if !s.manifestFd.Zero() { - s.stor.Remove(s.manifestFd) + err = s.stor.Remove(s.manifestFd) } s.manifestFd = fd s.manifestWriter = writer s.manifest = jw } else { writer.Close() - s.stor.Remove(fd) + if rerr := s.stor.Remove(fd); err != nil { + err = fmt.Errorf("newManifest error: %v, cleanup error (%v)", err, rerr) + } s.reuseFileNum(fd.Num) } }() diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage.go index 9ba71fd6..3c5e70a0 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage.go @@ -111,7 +111,9 @@ func OpenFile(path string, readOnly bool) (Storage, error) { defer func() { if err != nil { - flock.release() + if ferr := flock.release(); ferr != nil { + err = fmt.Errorf("error opening file (%v); error unlocking file (%v)", err, ferr) + } } }() @@ -175,12 +177,13 @@ func itoa(buf []byte, i int, wid int) []byte { return append(buf, b[bp:]...) } -func (fs *fileStorage) printDay(t time.Time) { +func (fs *fileStorage) printDay(t time.Time) error { if fs.day == t.Day() { - return + return nil } fs.day = t.Day() - fs.logw.Write([]byte("=============== " + t.Format("Jan 2, 2006 (MST)") + " ===============\n")) + _, err := fs.logw.Write([]byte("=============== " + t.Format("Jan 2, 2006 (MST)") + " ===============\n")) + return err } func (fs *fileStorage) doLog(t time.Time, str string) { @@ -189,7 +192,9 @@ func (fs *fileStorage) doLog(t time.Time, str string) { fs.logw.Close() fs.logw = nil fs.logSize = 0 - rename(filepath.Join(fs.path, "LOG"), filepath.Join(fs.path, "LOG.old")) + if err := rename(filepath.Join(fs.path, "LOG"), filepath.Join(fs.path, "LOG.old")); err != nil { + return + } } if fs.logw == nil { var err error @@ -200,7 +205,9 @@ func (fs *fileStorage) doLog(t time.Time, str string) { // Force printDay on new log file. fs.day = 0 } - fs.printDay(t) + if err := fs.printDay(t); err != nil { + return + } hour, min, sec := t.Clock() msec := t.Nanosecond() / 1e3 // time @@ -634,8 +641,9 @@ func fsGenOldName(fd FileDesc) string { switch fd.Type { case TypeTable: return fmt.Sprintf("%06d.sst", fd.Num) + default: + return fsGenName(fd) } - return fsGenName(fd) } func fsParseName(name string) (fd FileDesc, ok bool) { diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_nacl.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_nacl.go index 5545aeef..b23d4652 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_nacl.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_nacl.go @@ -4,6 +4,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. +//go:build nacl // +build nacl package storage diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_solaris.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_solaris.go index 79901ee4..cd84ce2e 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_solaris.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_solaris.go @@ -4,6 +4,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. +//go:build solaris // +build solaris package storage diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_unix.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_unix.go index d75f66a9..601ffe39 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_unix.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_unix.go @@ -4,6 +4,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. +//go:build darwin || dragonfly || freebsd || linux || netbsd || openbsd // +build darwin dragonfly freebsd linux netbsd openbsd package storage diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/mem_storage.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/mem_storage.go index 838f1bee..a32972ad 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/mem_storage.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/storage/mem_storage.go @@ -29,7 +29,6 @@ func (lock *memStorageLock) Unlock() { if ms.slock == lock { ms.slock = nil } - return } // memStorage is a memory-backed storage. diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/storage.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/storage.go index 4e4a7242..b385fc6f 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/storage.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/storage/storage.go @@ -59,8 +59,9 @@ func isCorrupted(err error) bool { switch err.(type) { case *ErrCorrupted: return true + default: + return false } - return false } func (e *ErrCorrupted) Error() string { diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/table.go b/vendor/github.com/syndtr/goleveldb/leveldb/table.go index 884be5d3..d0fab40c 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/table.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/table.go @@ -88,18 +88,6 @@ type tFiles []*tFile func (tf tFiles) Len() int { return len(tf) } func (tf tFiles) Swap(i, j int) { tf[i], tf[j] = tf[j], tf[i] } -func (tf tFiles) nums() string { - x := "[ " - for i, f := range tf { - if i != 0 { - x += ", " - } - x += fmt.Sprint(f.fd.Num) - } - x += " ]" - return x -} - // Returns true if i smallest key is less than j. // This used for sort by key in ascending order. func (tf tFiles) lessByKey(icmp *iComparer, i, j int) bool { @@ -360,13 +348,13 @@ type tOps struct { s *session noSync bool evictRemoved bool - cache *cache.Cache - bcache *cache.Cache - bpool *util.BufferPool + fileCache *cache.Cache + blockCache *cache.Cache + blockBuffer *util.BufferPool } // Creates an empty table and returns table writer. -func (t *tOps) create() (*tWriter, error) { +func (t *tOps) create(tSize int) (*tWriter, error) { fd := storage.FileDesc{Type: storage.TypeTable, Num: t.s.allocFileNum()} fw, err := t.s.stor.Create(fd) if err != nil { @@ -376,20 +364,22 @@ func (t *tOps) create() (*tWriter, error) { t: t, fd: fd, w: fw, - tw: table.NewWriter(fw, t.s.o.Options), + tw: table.NewWriter(fw, t.s.o.Options, t.blockBuffer, tSize), }, nil } // Builds table from src iterator. func (t *tOps) createFrom(src iterator.Iterator) (f *tFile, n int, err error) { - w, err := t.create() + w, err := t.create(0) if err != nil { return } defer func() { if err != nil { - w.drop() + if derr := w.drop(); derr != nil { + err = fmt.Errorf("error createFrom (%v); error dropping (%v)", err, derr) + } } }() @@ -412,22 +402,22 @@ func (t *tOps) createFrom(src iterator.Iterator) (f *tFile, n int, err error) { // Opens table. It returns a cache handle, which should // be released after use. func (t *tOps) open(f *tFile) (ch *cache.Handle, err error) { - ch = t.cache.Get(0, uint64(f.fd.Num), func() (size int, value cache.Value) { + ch = t.fileCache.Get(0, uint64(f.fd.Num), func() (size int, value cache.Value) { var r storage.Reader r, err = t.s.stor.Open(f.fd) if err != nil { return 0, nil } - var bcache *cache.NamespaceGetter - if t.bcache != nil { - bcache = &cache.NamespaceGetter{Cache: t.bcache, NS: uint64(f.fd.Num)} + var blockCache *cache.NamespaceGetter + if t.blockCache != nil { + blockCache = &cache.NamespaceGetter{Cache: t.blockCache, NS: uint64(f.fd.Num)} } var tr *table.Reader - tr, err = table.NewReader(r, f.size, f.fd, bcache, t.bpool, t.s.o.Options) + tr, err = table.NewReader(r, f.size, f.fd, blockCache, t.blockBuffer, t.s.o.Options) if err != nil { - r.Close() + _ = r.Close() return 0, nil } return 1, tr @@ -484,14 +474,14 @@ func (t *tOps) newIterator(f *tFile, slice *util.Range, ro *opt.ReadOptions) ite // Removes table from persistent storage. It waits until // no one use the the table. func (t *tOps) remove(fd storage.FileDesc) { - t.cache.Delete(0, uint64(fd.Num), func() { + t.fileCache.Delete(0, uint64(fd.Num), func() { if err := t.s.stor.Remove(fd); err != nil { t.s.logf("table@remove removing @%d %q", fd.Num, err) } else { t.s.logf("table@remove removed @%d", fd.Num) } - if t.evictRemoved && t.bcache != nil { - t.bcache.EvictNS(uint64(fd.Num)) + if t.evictRemoved && t.blockCache != nil { + t.blockCache.EvictNS(uint64(fd.Num)) } // Try to reuse file num, useful for discarded transaction. t.s.reuseFileNum(fd.Num) @@ -501,40 +491,39 @@ func (t *tOps) remove(fd storage.FileDesc) { // Closes the table ops instance. It will close all tables, // regadless still used or not. func (t *tOps) close() { - t.bpool.Close() - t.cache.Close() - if t.bcache != nil { - t.bcache.CloseWeak() + t.fileCache.Close(true) + if t.blockCache != nil { + t.blockCache.Close(false) } } // Creates new initialized table ops instance. func newTableOps(s *session) *tOps { var ( - cacher cache.Cacher - bcache *cache.Cache - bpool *util.BufferPool + fileCacher cache.Cacher + blockCache *cache.Cache + blockBuffer *util.BufferPool ) if s.o.GetOpenFilesCacheCapacity() > 0 { - cacher = s.o.GetOpenFilesCacher().New(s.o.GetOpenFilesCacheCapacity()) + fileCacher = s.o.GetOpenFilesCacher().New(s.o.GetOpenFilesCacheCapacity()) } if !s.o.GetDisableBlockCache() { - var bcacher cache.Cacher + var blockCacher cache.Cacher if s.o.GetBlockCacheCapacity() > 0 { - bcacher = s.o.GetBlockCacher().New(s.o.GetBlockCacheCapacity()) + blockCacher = s.o.GetBlockCacher().New(s.o.GetBlockCacheCapacity()) } - bcache = cache.NewCache(bcacher) + blockCache = cache.NewCache(blockCacher) } if !s.o.GetDisableBufferPool() { - bpool = util.NewBufferPool(s.o.GetBlockSize() + 5) + blockBuffer = util.NewBufferPool(s.o.GetBlockSize() + 5) } return &tOps{ s: s, noSync: s.o.GetNoSync(), evictRemoved: s.o.GetBlockCacheEvictRemoved(), - cache: cache.NewCache(cacher), - bcache: bcache, - bpool: bpool, + fileCache: cache.NewCache(fileCacher), + blockCache: blockCache, + blockBuffer: blockBuffer, } } @@ -553,7 +542,7 @@ type tWriter struct { // Append key/value pair to the table. func (w *tWriter) append(key, value []byte) error { if w.first == nil { - w.first = append([]byte{}, key...) + w.first = append([]byte(nil), key...) } w.last = append(w.last[:0], key...) return w.tw.Append(key, value) @@ -565,16 +554,27 @@ func (w *tWriter) empty() bool { } // Closes the storage.Writer. -func (w *tWriter) close() { +func (w *tWriter) close() error { if w.w != nil { - w.w.Close() + if err := w.w.Close(); err != nil { + return err + } w.w = nil } + return nil } // Finalizes the table and returns table file. func (w *tWriter) finish() (f *tFile, err error) { - defer w.close() + defer func() { + if cerr := w.close(); cerr != nil { + if err == nil { + err = cerr + } else { + err = fmt.Errorf("error opening file (%v); error unlocking file (%v)", err, cerr) + } + } + }() err = w.tw.Close() if err != nil { return @@ -590,11 +590,16 @@ func (w *tWriter) finish() (f *tFile, err error) { } // Drops the table. -func (w *tWriter) drop() { - w.close() - w.t.s.stor.Remove(w.fd) - w.t.s.reuseFileNum(w.fd.Num) +func (w *tWriter) drop() error { + if err := w.close(); err != nil { + return err + } w.tw = nil w.first = nil w.last = nil + if err := w.t.s.stor.Remove(w.fd); err != nil { + return err + } + w.t.s.reuseFileNum(w.fd.Num) + return nil } diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/table/reader.go b/vendor/github.com/syndtr/goleveldb/leveldb/table/reader.go index 496feb6f..8128794c 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/table/reader.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/table/reader.go @@ -901,7 +901,7 @@ func (r *Reader) find(key []byte, filtered bool, ro *opt.ReadOptions, noValue bo } else { // Value does use block buffer, and since the buffer will be // recycled, it need to be copied. - value = append([]byte{}, data.Value()...) + value = append([]byte(nil), data.Value()...) } } data.Release() diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/table/writer.go b/vendor/github.com/syndtr/goleveldb/leveldb/table/writer.go index fda697bd..ea89d600 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/table/writer.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/table/writer.go @@ -40,7 +40,7 @@ type blockWriter struct { scratch []byte } -func (w *blockWriter) append(key, value []byte) { +func (w *blockWriter) append(key, value []byte) (err error) { nShared := 0 if w.nEntries%w.restartInterval == 0 { w.restarts = append(w.restarts, uint32(w.buf.Len())) @@ -50,14 +50,21 @@ func (w *blockWriter) append(key, value []byte) { n := binary.PutUvarint(w.scratch[0:], uint64(nShared)) n += binary.PutUvarint(w.scratch[n:], uint64(len(key)-nShared)) n += binary.PutUvarint(w.scratch[n:], uint64(len(value))) - w.buf.Write(w.scratch[:n]) - w.buf.Write(key[nShared:]) - w.buf.Write(value) + if _, err = w.buf.Write(w.scratch[:n]); err != nil { + return err + } + if _, err = w.buf.Write(key[nShared:]); err != nil { + return err + } + if _, err = w.buf.Write(value); err != nil { + return err + } w.prevKey = append(w.prevKey[:0], key...) w.nEntries++ + return nil } -func (w *blockWriter) finish() { +func (w *blockWriter) finish() error { // Write restarts entry. if w.nEntries == 0 { // Must have at least one restart entry. @@ -68,6 +75,7 @@ func (w *blockWriter) finish() { buf4 := w.buf.Alloc(4) binary.LittleEndian.PutUint32(buf4, x) } + return nil } func (w *blockWriter) reset() { @@ -109,9 +117,9 @@ func (w *filterWriter) flush(offset uint64) { } } -func (w *filterWriter) finish() { +func (w *filterWriter) finish() error { if w.generator == nil { - return + return nil } // Generate last keys. @@ -123,7 +131,7 @@ func (w *filterWriter) finish() { buf4 := w.buf.Alloc(4) binary.LittleEndian.PutUint32(buf4, x) } - w.buf.WriteByte(byte(w.baseLg)) + return w.buf.WriteByte(byte(w.baseLg)) } func (w *filterWriter) generate() { @@ -146,6 +154,7 @@ type Writer struct { compression opt.Compression blockSize int + bpool *util.BufferPool dataBlock blockWriter indexBlock blockWriter filterBlock filterWriter @@ -193,9 +202,9 @@ func (w *Writer) writeBlock(buf *util.Buffer, compression opt.Compression) (bh b return } -func (w *Writer) flushPendingBH(key []byte) { +func (w *Writer) flushPendingBH(key []byte) error { if w.pendingBH.length == 0 { - return + return nil } var separator []byte if len(key) == 0 { @@ -210,15 +219,20 @@ func (w *Writer) flushPendingBH(key []byte) { } n := encodeBlockHandle(w.scratch[:20], w.pendingBH) // Append the block handle to the index block. - w.indexBlock.append(separator, w.scratch[:n]) + if err := w.indexBlock.append(separator, w.scratch[:n]); err != nil { + return err + } // Reset prev key of the data block. w.dataBlock.prevKey = w.dataBlock.prevKey[:0] // Clear pending block handle. w.pendingBH = blockHandle{} + return nil } func (w *Writer) finishBlock() error { - w.dataBlock.finish() + if err := w.dataBlock.finish(); err != nil { + return err + } bh, err := w.writeBlock(&w.dataBlock.buf, w.compression) if err != nil { return err @@ -244,9 +258,13 @@ func (w *Writer) Append(key, value []byte) error { return w.err } - w.flushPendingBH(key) + if err := w.flushPendingBH(key); err != nil { + return err + } // Append key/value pair to the data block. - w.dataBlock.append(key, value) + if err := w.dataBlock.append(key, value); err != nil { + return err + } // Add key to the filter block. w.filterBlock.add(key) @@ -285,6 +303,16 @@ func (w *Writer) BytesLen() int { // after Close, but calling BlocksLen, EntriesLen and BytesLen // is still possible. func (w *Writer) Close() error { + defer func() { + if w.bpool != nil { + // Buffer.Bytes() returns [offset:] of the buffer. + // We need to Reset() so that the offset = 0, resulting + // in buf.Bytes() returning the whole allocated bytes. + w.dataBlock.buf.Reset() + w.bpool.Put(w.dataBlock.buf.Bytes()) + } + }() + if w.err != nil { return w.err } @@ -297,11 +325,15 @@ func (w *Writer) Close() error { return w.err } } - w.flushPendingBH(nil) + if err := w.flushPendingBH(nil); err != nil { + return err + } // Write the filter block. var filterBH blockHandle - w.filterBlock.finish() + if err := w.filterBlock.finish(); err != nil { + return err + } if buf := &w.filterBlock.buf; buf.Len() > 0 { filterBH, w.err = w.writeBlock(buf, opt.NoCompression) if w.err != nil { @@ -313,9 +345,13 @@ func (w *Writer) Close() error { if filterBH.length > 0 { key := []byte("filter." + w.filter.Name()) n := encodeBlockHandle(w.scratch[:20], filterBH) - w.dataBlock.append(key, w.scratch[:n]) + if err := w.dataBlock.append(key, w.scratch[:n]); err != nil { + return err + } + } + if err := w.dataBlock.finish(); err != nil { + return err } - w.dataBlock.finish() metaindexBH, err := w.writeBlock(&w.dataBlock.buf, w.compression) if err != nil { w.err = err @@ -323,7 +359,9 @@ func (w *Writer) Close() error { } // Write the index block. - w.indexBlock.finish() + if err := w.indexBlock.finish(); err != nil { + return err + } indexBH, err := w.writeBlock(&w.indexBlock.buf, w.compression) if err != nil { w.err = err @@ -351,7 +389,15 @@ func (w *Writer) Close() error { // NewWriter creates a new initialized table writer for the file. // // Table writer is not safe for concurrent use. -func NewWriter(f io.Writer, o *opt.Options) *Writer { +func NewWriter(f io.Writer, o *opt.Options, pool *util.BufferPool, size int) *Writer { + var bufBytes []byte + if pool == nil { + bufBytes = make([]byte, size) + } else { + bufBytes = pool.Get(size) + } + bufBytes = bufBytes[:0] + w := &Writer{ writer: f, cmp: o.GetComparer(), @@ -359,6 +405,8 @@ func NewWriter(f io.Writer, o *opt.Options) *Writer { compression: o.GetCompression(), blockSize: o.GetBlockSize(), comparerScratch: make([]byte, 0), + bpool: pool, + dataBlock: blockWriter{buf: *util.NewBuffer(bufBytes)}, } // data block w.dataBlock.restartInterval = o.GetBlockRestartInterval() diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/util.go b/vendor/github.com/syndtr/goleveldb/leveldb/util.go index 0e2b519e..1ef859d4 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/util.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/util.go @@ -22,7 +22,7 @@ func shorten(str string) string { var bunits = [...]string{"", "Ki", "Mi", "Gi", "Ti"} -func shortenb(bytes int) string { +func shortenb(bytes int64) string { i := 0 for ; bytes > 1024 && i < 4; i++ { bytes /= 1024 @@ -30,7 +30,7 @@ func shortenb(bytes int) string { return fmt.Sprintf("%d%sB", bytes, bunits[i]) } -func sshortenb(bytes int) string { +func sshortenb(bytes int64) string { if bytes == 0 { return "~" } @@ -58,13 +58,6 @@ func sint(x int) string { return fmt.Sprintf("%s%d", sign, x) } -func minInt(a, b int) int { - if a < b { - return a - } - return b -} - func maxInt(a, b int) int { if a > b { return a diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer_pool.go b/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer_pool.go index 5ab1f868..4f512f6d 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer_pool.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer_pool.go @@ -10,30 +10,15 @@ import ( "fmt" "sync" "sync/atomic" - "time" ) -type buffer struct { - b []byte - miss int -} - // BufferPool is a 'buffer pool'. type BufferPool struct { - pool [6]chan []byte - size [5]uint32 - sizeMiss [5]uint32 - sizeHalf [5]uint32 - baseline [4]int - baseline0 int - - mu sync.RWMutex - closed bool - closeC chan struct{} + pool [6]sync.Pool + baseline [5]int get uint32 put uint32 - half uint32 less uint32 equal uint32 greater uint32 @@ -41,15 +26,12 @@ type BufferPool struct { } func (p *BufferPool) poolNum(n int) int { - if n <= p.baseline0 && n > p.baseline0/2 { - return 0 - } for i, x := range p.baseline { if n <= x { - return i + 1 + return i } } - return len(p.baseline) + 1 + return len(p.baseline) } // Get returns buffer with length of n. @@ -57,101 +39,47 @@ func (p *BufferPool) Get(n int) []byte { if p == nil { return make([]byte, n) } + atomic.AddUint32(&p.get, 1) - p.mu.RLock() - defer p.mu.RUnlock() + poolNum := p.poolNum(n) - if p.closed { - return make([]byte, n) - } + b := p.pool[poolNum].Get().(*[]byte) - atomic.AddUint32(&p.get, 1) + if cap(*b) == 0 { + // If we grabbed nothing, increment the miss stats. + atomic.AddUint32(&p.miss, 1) - poolNum := p.poolNum(n) - pool := p.pool[poolNum] - if poolNum == 0 { - // Fast path. - select { - case b := <-pool: - switch { - case cap(b) > n: - if cap(b)-n >= n { - atomic.AddUint32(&p.half, 1) - select { - case pool <- b: - default: - } - return make([]byte, n) - } else { - atomic.AddUint32(&p.less, 1) - return b[:n] - } - case cap(b) == n: - atomic.AddUint32(&p.equal, 1) - return b[:n] - default: - atomic.AddUint32(&p.greater, 1) - } - default: - atomic.AddUint32(&p.miss, 1) + if poolNum == len(p.baseline) { + *b = make([]byte, n) + return *b } - return make([]byte, n, p.baseline0) + *b = make([]byte, p.baseline[poolNum]) + *b = (*b)[:n] + return *b } else { - sizePtr := &p.size[poolNum-1] - - select { - case b := <-pool: - switch { - case cap(b) > n: - if cap(b)-n >= n { - atomic.AddUint32(&p.half, 1) - sizeHalfPtr := &p.sizeHalf[poolNum-1] - if atomic.AddUint32(sizeHalfPtr, 1) == 20 { - atomic.StoreUint32(sizePtr, uint32(cap(b)/2)) - atomic.StoreUint32(sizeHalfPtr, 0) - } else { - select { - case pool <- b: - default: - } - } - return make([]byte, n) - } else { - atomic.AddUint32(&p.less, 1) - return b[:n] - } - case cap(b) == n: - atomic.AddUint32(&p.equal, 1) - return b[:n] - default: - atomic.AddUint32(&p.greater, 1) - if uint32(cap(b)) >= atomic.LoadUint32(sizePtr) { - select { - case pool <- b: - default: - } - } - } - default: - atomic.AddUint32(&p.miss, 1) + // If there is enough capacity in the bytes grabbed, resize the length + // to n and return. + if n < cap(*b) { + atomic.AddUint32(&p.less, 1) + *b = (*b)[:n] + return *b + } else if n == cap(*b) { + atomic.AddUint32(&p.equal, 1) + *b = (*b)[:n] + return *b + } else if n > cap(*b) { + atomic.AddUint32(&p.greater, 1) } + } - if size := atomic.LoadUint32(sizePtr); uint32(n) > size { - if size == 0 { - atomic.CompareAndSwapUint32(sizePtr, 0, uint32(n)) - } else { - sizeMissPtr := &p.sizeMiss[poolNum-1] - if atomic.AddUint32(sizeMissPtr, 1) == 20 { - atomic.StoreUint32(sizePtr, uint32(n)) - atomic.StoreUint32(sizeMissPtr, 0) - } - } - return make([]byte, n) - } else { - return make([]byte, n, size) - } + if poolNum == len(p.baseline) { + *b = make([]byte, n) + return *b } + *b = make([]byte, p.baseline[poolNum]) + *b = (*b)[:n] + return *b } // Put adds given buffer to the pool. @@ -160,68 +88,18 @@ func (p *BufferPool) Put(b []byte) { return } - p.mu.RLock() - defer p.mu.RUnlock() - - if p.closed { - return - } + poolNum := p.poolNum(cap(b)) atomic.AddUint32(&p.put, 1) - - pool := p.pool[p.poolNum(cap(b))] - select { - case pool <- b: - default: - } - -} - -func (p *BufferPool) Close() { - if p == nil { - return - } - - p.mu.Lock() - if !p.closed { - p.closed = true - p.closeC <- struct{}{} - } - p.mu.Unlock() + p.pool[poolNum].Put(&b) } func (p *BufferPool) String() string { if p == nil { return "" } - - p.mu.Lock() - defer p.mu.Unlock() - - return fmt.Sprintf("BufferPool{B·%d Z·%v Zm·%v Zh·%v G·%d P·%d H·%d <·%d =·%d >·%d M·%d}", - p.baseline0, p.size, p.sizeMiss, p.sizeHalf, p.get, p.put, p.half, p.less, p.equal, p.greater, p.miss) -} - -func (p *BufferPool) drain() { - ticker := time.NewTicker(2 * time.Second) - defer ticker.Stop() - for { - select { - case <-ticker.C: - for _, ch := range p.pool { - select { - case <-ch: - default: - } - } - case <-p.closeC: - close(p.closeC) - for _, ch := range p.pool { - close(ch) - } - return - } - } + return fmt.Sprintf("BufferPool{B·%d G·%d P·%d <·%d =·%d >·%d M·%d}", + p.baseline, p.get, p.put, p.less, p.equal, p.greater, p.miss) } // NewBufferPool creates a new initialized 'buffer pool'. @@ -229,14 +107,29 @@ func NewBufferPool(baseline int) *BufferPool { if baseline <= 0 { panic("baseline can't be <= 0") } - p := &BufferPool{ - baseline0: baseline, - baseline: [...]int{baseline / 4, baseline / 2, baseline * 2, baseline * 4}, - closeC: make(chan struct{}, 1), + bufPool := &BufferPool{ + baseline: [...]int{baseline / 4, baseline / 2, baseline, baseline * 2, baseline * 4}, + pool: [6]sync.Pool{ + { + New: func() interface{} { return new([]byte) }, + }, + { + New: func() interface{} { return new([]byte) }, + }, + { + New: func() interface{} { return new([]byte) }, + }, + { + New: func() interface{} { return new([]byte) }, + }, + { + New: func() interface{} { return new([]byte) }, + }, + { + New: func() interface{} { return new([]byte) }, + }, + }, } - for i, cap := range []int{2, 2, 4, 4, 2, 1} { - p.pool[i] = make(chan []byte, cap) - } - go p.drain() - return p + + return bufPool } diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/version.go b/vendor/github.com/syndtr/goleveldb/leveldb/version.go index 9535e359..46725091 100644 --- a/vendor/github.com/syndtr/goleveldb/leveldb/version.go +++ b/vendor/github.com/syndtr/goleveldb/leveldb/version.go @@ -43,7 +43,7 @@ type version struct { // newVersion creates a new version with an unique monotonous increasing id. func newVersion(s *session) *version { - id := atomic.AddInt64(&s.ntVersionId, 1) + id := atomic.AddInt64(&s.ntVersionID, 1) nv := &version{s: s, id: id - 1} return nv } @@ -388,7 +388,7 @@ func (v *version) computeCompaction() { } statFiles[level] = len(tables) - statSizes[level] = shortenb(int(size)) + statSizes[level] = shortenb(size) statScore[level] = fmt.Sprintf("%.2f", score) statTotSize += size } @@ -396,7 +396,7 @@ func (v *version) computeCompaction() { v.cLevel = bestLevel v.cScore = bestScore - v.s.logf("version@stat F·%v S·%s%v Sc·%v", statFiles, shortenb(int(statTotSize)), statSizes, statScore) + v.s.logf("version@stat F·%v S·%s%v Sc·%v", statFiles, shortenb(statTotSize), statSizes, statScore) } func (v *version) needCompaction() bool { diff --git a/vendor/golang.org/x/sync/errgroup/errgroup.go b/vendor/golang.org/x/sync/errgroup/errgroup.go index a4ea5d14..f8c3c092 100644 --- a/vendor/golang.org/x/sync/errgroup/errgroup.go +++ b/vendor/golang.org/x/sync/errgroup/errgroup.go @@ -18,7 +18,7 @@ import ( type token struct{} // A Group is a collection of goroutines working on subtasks that are part of -// the same overall task. +// the same overall task. A Group should not be reused for different tasks. // // A zero Group is valid, has no limit on the number of active goroutines, // and does not cancel on error. @@ -61,6 +61,7 @@ func (g *Group) Wait() error { } // Go calls the given function in a new goroutine. +// The first call to Go must happen before a Wait. // It blocks until the new goroutine can be added without the number of // active goroutines in the group exceeding the configured limit. // diff --git a/vendor/golang.org/x/sys/cpu/cpu.go b/vendor/golang.org/x/sys/cpu/cpu.go index 9c105f23..2e73ee19 100644 --- a/vendor/golang.org/x/sys/cpu/cpu.go +++ b/vendor/golang.org/x/sys/cpu/cpu.go @@ -149,6 +149,18 @@ var ARM struct { _ CacheLinePad } +// The booleans in Loong64 contain the correspondingly named cpu feature bit. +// The struct is padded to avoid false sharing. +var Loong64 struct { + _ CacheLinePad + HasLSX bool // support 128-bit vector extension + HasLASX bool // support 256-bit vector extension + HasCRC32 bool // support CRC instruction + HasLAM_BH bool // support AM{SWAP/ADD}[_DB].{B/H} instruction + HasLAMCAS bool // support AMCAS[_DB].{B/H/W/D} instruction + _ CacheLinePad +} + // MIPS64X contains the supported CPU features of the current mips64/mips64le // platforms. If the current platform is not mips64/mips64le or the current // operating system is not Linux then all feature flags are false. diff --git a/vendor/golang.org/x/sys/cpu/cpu_linux_loong64.go b/vendor/golang.org/x/sys/cpu/cpu_linux_loong64.go new file mode 100644 index 00000000..4f341143 --- /dev/null +++ b/vendor/golang.org/x/sys/cpu/cpu_linux_loong64.go @@ -0,0 +1,22 @@ +// Copyright 2025 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package cpu + +// HWCAP bits. These are exposed by the Linux kernel. +const ( + hwcap_LOONGARCH_LSX = 1 << 4 + hwcap_LOONGARCH_LASX = 1 << 5 +) + +func doinit() { + // TODO: Features that require kernel support like LSX and LASX can + // be detected here once needed in std library or by the compiler. + Loong64.HasLSX = hwcIsSet(hwCap, hwcap_LOONGARCH_LSX) + Loong64.HasLASX = hwcIsSet(hwCap, hwcap_LOONGARCH_LASX) +} + +func hwcIsSet(hwc uint, val uint) bool { + return hwc&val != 0 +} diff --git a/vendor/golang.org/x/sys/cpu/cpu_linux_noinit.go b/vendor/golang.org/x/sys/cpu/cpu_linux_noinit.go index 7d902b68..a428dec9 100644 --- a/vendor/golang.org/x/sys/cpu/cpu_linux_noinit.go +++ b/vendor/golang.org/x/sys/cpu/cpu_linux_noinit.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -//go:build linux && !arm && !arm64 && !mips64 && !mips64le && !ppc64 && !ppc64le && !s390x && !riscv64 +//go:build linux && !arm && !arm64 && !loong64 && !mips64 && !mips64le && !ppc64 && !ppc64le && !s390x && !riscv64 package cpu diff --git a/vendor/golang.org/x/sys/cpu/cpu_loong64.go b/vendor/golang.org/x/sys/cpu/cpu_loong64.go index 55863585..45ecb29a 100644 --- a/vendor/golang.org/x/sys/cpu/cpu_loong64.go +++ b/vendor/golang.org/x/sys/cpu/cpu_loong64.go @@ -8,5 +8,43 @@ package cpu const cacheLineSize = 64 +// Bit fields for CPUCFG registers, Related reference documents: +// https://loongson.github.io/LoongArch-Documentation/LoongArch-Vol1-EN.html#_cpucfg +const ( + // CPUCFG1 bits + cpucfg1_CRC32 = 1 << 25 + + // CPUCFG2 bits + cpucfg2_LAM_BH = 1 << 27 + cpucfg2_LAMCAS = 1 << 28 +) + func initOptions() { + options = []option{ + {Name: "lsx", Feature: &Loong64.HasLSX}, + {Name: "lasx", Feature: &Loong64.HasLASX}, + {Name: "crc32", Feature: &Loong64.HasCRC32}, + {Name: "lam_bh", Feature: &Loong64.HasLAM_BH}, + {Name: "lamcas", Feature: &Loong64.HasLAMCAS}, + } + + // The CPUCFG data on Loong64 only reflects the hardware capabilities, + // not the kernel support status, so features such as LSX and LASX that + // require kernel support cannot be obtained from the CPUCFG data. + // + // These features only require hardware capability support and do not + // require kernel specific support, so they can be obtained directly + // through CPUCFG + cfg1 := get_cpucfg(1) + cfg2 := get_cpucfg(2) + + Loong64.HasCRC32 = cfgIsSet(cfg1, cpucfg1_CRC32) + Loong64.HasLAMCAS = cfgIsSet(cfg2, cpucfg2_LAMCAS) + Loong64.HasLAM_BH = cfgIsSet(cfg2, cpucfg2_LAM_BH) +} + +func get_cpucfg(reg uint32) uint32 + +func cfgIsSet(cfg uint32, val uint32) bool { + return cfg&val != 0 } diff --git a/vendor/golang.org/x/sys/cpu/cpu_loong64.s b/vendor/golang.org/x/sys/cpu/cpu_loong64.s new file mode 100644 index 00000000..71cbaf1c --- /dev/null +++ b/vendor/golang.org/x/sys/cpu/cpu_loong64.s @@ -0,0 +1,13 @@ +// Copyright 2025 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +#include "textflag.h" + +// func get_cpucfg(reg uint32) uint32 +TEXT ·get_cpucfg(SB), NOSPLIT|NOFRAME, $0 + MOVW reg+0(FP), R5 + // CPUCFG R5, R4 = 0x00006ca4 + WORD $0x00006ca4 + MOVW R4, ret+8(FP) + RET diff --git a/vendor/golang.org/x/sys/cpu/parse.go b/vendor/golang.org/x/sys/cpu/parse.go index 762b63d6..56a7e1a1 100644 --- a/vendor/golang.org/x/sys/cpu/parse.go +++ b/vendor/golang.org/x/sys/cpu/parse.go @@ -13,7 +13,7 @@ import "strconv" // https://golang.org/cl/209597. func parseRelease(rel string) (major, minor, patch int, ok bool) { // Strip anything after a dash or plus. - for i := 0; i < len(rel); i++ { + for i := range len(rel) { if rel[i] == '-' || rel[i] == '+' { rel = rel[:i] break @@ -21,7 +21,7 @@ func parseRelease(rel string) (major, minor, patch int, ok bool) { } next := func() (int, bool) { - for i := 0; i < len(rel); i++ { + for i := range len(rel) { if rel[i] == '.' { ver, err := strconv.Atoi(rel[:i]) rel = rel[i+1:] diff --git a/vendor/golang.org/x/sys/unix/syscall_darwin.go b/vendor/golang.org/x/sys/unix/syscall_darwin.go index 099867de..798f61ad 100644 --- a/vendor/golang.org/x/sys/unix/syscall_darwin.go +++ b/vendor/golang.org/x/sys/unix/syscall_darwin.go @@ -602,7 +602,150 @@ func Connectx(fd int, srcIf uint32, srcAddr, dstAddr Sockaddr, associd SaeAssocI return } -//sys connectx(fd int, endpoints *SaEndpoints, associd SaeAssocID, flags uint32, iov []Iovec, n *uintptr, connid *SaeConnID) (err error) +// sys connectx(fd int, endpoints *SaEndpoints, associd SaeAssocID, flags uint32, iov []Iovec, n *uintptr, connid *SaeConnID) (err error) +const minIovec = 8 + +func Readv(fd int, iovs [][]byte) (n int, err error) { + if !darwinKernelVersionMin(11, 0, 0) { + return 0, ENOSYS + } + + iovecs := make([]Iovec, 0, minIovec) + iovecs = appendBytes(iovecs, iovs) + n, err = readv(fd, iovecs) + readvRacedetect(iovecs, n, err) + return n, err +} + +func Preadv(fd int, iovs [][]byte, offset int64) (n int, err error) { + if !darwinKernelVersionMin(11, 0, 0) { + return 0, ENOSYS + } + iovecs := make([]Iovec, 0, minIovec) + iovecs = appendBytes(iovecs, iovs) + n, err = preadv(fd, iovecs, offset) + readvRacedetect(iovecs, n, err) + return n, err +} + +func Writev(fd int, iovs [][]byte) (n int, err error) { + if !darwinKernelVersionMin(11, 0, 0) { + return 0, ENOSYS + } + + iovecs := make([]Iovec, 0, minIovec) + iovecs = appendBytes(iovecs, iovs) + if raceenabled { + raceReleaseMerge(unsafe.Pointer(&ioSync)) + } + n, err = writev(fd, iovecs) + writevRacedetect(iovecs, n) + return n, err +} + +func Pwritev(fd int, iovs [][]byte, offset int64) (n int, err error) { + if !darwinKernelVersionMin(11, 0, 0) { + return 0, ENOSYS + } + + iovecs := make([]Iovec, 0, minIovec) + iovecs = appendBytes(iovecs, iovs) + if raceenabled { + raceReleaseMerge(unsafe.Pointer(&ioSync)) + } + n, err = pwritev(fd, iovecs, offset) + writevRacedetect(iovecs, n) + return n, err +} + +func appendBytes(vecs []Iovec, bs [][]byte) []Iovec { + for _, b := range bs { + var v Iovec + v.SetLen(len(b)) + if len(b) > 0 { + v.Base = &b[0] + } else { + v.Base = (*byte)(unsafe.Pointer(&_zero)) + } + vecs = append(vecs, v) + } + return vecs +} + +func writevRacedetect(iovecs []Iovec, n int) { + if !raceenabled { + return + } + for i := 0; n > 0 && i < len(iovecs); i++ { + m := int(iovecs[i].Len) + if m > n { + m = n + } + n -= m + if m > 0 { + raceReadRange(unsafe.Pointer(iovecs[i].Base), m) + } + } +} + +func readvRacedetect(iovecs []Iovec, n int, err error) { + if !raceenabled { + return + } + for i := 0; n > 0 && i < len(iovecs); i++ { + m := int(iovecs[i].Len) + if m > n { + m = n + } + n -= m + if m > 0 { + raceWriteRange(unsafe.Pointer(iovecs[i].Base), m) + } + } + if err == nil { + raceAcquire(unsafe.Pointer(&ioSync)) + } +} + +func darwinMajorMinPatch() (maj, min, patch int, err error) { + var un Utsname + err = Uname(&un) + if err != nil { + return + } + + var mmp [3]int + c := 0 +Loop: + for _, b := range un.Release[:] { + switch { + case b >= '0' && b <= '9': + mmp[c] = 10*mmp[c] + int(b-'0') + case b == '.': + c++ + if c > 2 { + return 0, 0, 0, ENOTSUP + } + case b == 0: + break Loop + default: + return 0, 0, 0, ENOTSUP + } + } + if c != 2 { + return 0, 0, 0, ENOTSUP + } + return mmp[0], mmp[1], mmp[2], nil +} + +func darwinKernelVersionMin(maj, min, patch int) bool { + actualMaj, actualMin, actualPatch, err := darwinMajorMinPatch() + if err != nil { + return false + } + return actualMaj > maj || actualMaj == maj && (actualMin > min || actualMin == min && actualPatch >= patch) +} + //sys sendfile(infd int, outfd int, offset int64, len *int64, hdtr unsafe.Pointer, flags int) (err error) //sys shmat(id int, addr uintptr, flag int) (ret uintptr, err error) @@ -705,3 +848,7 @@ func Connectx(fd int, srcIf uint32, srcAddr, dstAddr Sockaddr, associd SaeAssocI //sys write(fd int, p []byte) (n int, err error) //sys mmap(addr uintptr, length uintptr, prot int, flag int, fd int, pos int64) (ret uintptr, err error) //sys munmap(addr uintptr, length uintptr) (err error) +//sys readv(fd int, iovecs []Iovec) (n int, err error) +//sys preadv(fd int, iovecs []Iovec, offset int64) (n int, err error) +//sys writev(fd int, iovecs []Iovec) (n int, err error) +//sys pwritev(fd int, iovecs []Iovec, offset int64) (n int, err error) diff --git a/vendor/golang.org/x/sys/unix/syscall_linux.go b/vendor/golang.org/x/sys/unix/syscall_linux.go index 230a9454..4958a657 100644 --- a/vendor/golang.org/x/sys/unix/syscall_linux.go +++ b/vendor/golang.org/x/sys/unix/syscall_linux.go @@ -13,6 +13,7 @@ package unix import ( "encoding/binary" + "slices" "strconv" "syscall" "time" @@ -417,7 +418,7 @@ func (sa *SockaddrUnix) sockaddr() (unsafe.Pointer, _Socklen, error) { return nil, 0, EINVAL } sa.raw.Family = AF_UNIX - for i := 0; i < n; i++ { + for i := range n { sa.raw.Path[i] = int8(name[i]) } // length is family (uint16), name, NUL. @@ -507,7 +508,7 @@ func (sa *SockaddrL2) sockaddr() (unsafe.Pointer, _Socklen, error) { psm := (*[2]byte)(unsafe.Pointer(&sa.raw.Psm)) psm[0] = byte(sa.PSM) psm[1] = byte(sa.PSM >> 8) - for i := 0; i < len(sa.Addr); i++ { + for i := range len(sa.Addr) { sa.raw.Bdaddr[i] = sa.Addr[len(sa.Addr)-1-i] } cid := (*[2]byte)(unsafe.Pointer(&sa.raw.Cid)) @@ -589,11 +590,11 @@ func (sa *SockaddrCAN) sockaddr() (unsafe.Pointer, _Socklen, error) { sa.raw.Family = AF_CAN sa.raw.Ifindex = int32(sa.Ifindex) rx := (*[4]byte)(unsafe.Pointer(&sa.RxID)) - for i := 0; i < 4; i++ { + for i := range 4 { sa.raw.Addr[i] = rx[i] } tx := (*[4]byte)(unsafe.Pointer(&sa.TxID)) - for i := 0; i < 4; i++ { + for i := range 4 { sa.raw.Addr[i+4] = tx[i] } return unsafe.Pointer(&sa.raw), SizeofSockaddrCAN, nil @@ -618,11 +619,11 @@ func (sa *SockaddrCANJ1939) sockaddr() (unsafe.Pointer, _Socklen, error) { sa.raw.Family = AF_CAN sa.raw.Ifindex = int32(sa.Ifindex) n := (*[8]byte)(unsafe.Pointer(&sa.Name)) - for i := 0; i < 8; i++ { + for i := range 8 { sa.raw.Addr[i] = n[i] } p := (*[4]byte)(unsafe.Pointer(&sa.PGN)) - for i := 0; i < 4; i++ { + for i := range 4 { sa.raw.Addr[i+8] = p[i] } sa.raw.Addr[12] = sa.Addr @@ -911,7 +912,7 @@ func (sa *SockaddrIUCV) sockaddr() (unsafe.Pointer, _Socklen, error) { // These are EBCDIC encoded by the kernel, but we still need to pad them // with blanks. Initializing with blanks allows the caller to feed in either // a padded or an unpadded string. - for i := 0; i < 8; i++ { + for i := range 8 { sa.raw.Nodeid[i] = ' ' sa.raw.User_id[i] = ' ' sa.raw.Name[i] = ' ' @@ -1148,7 +1149,7 @@ func anyToSockaddr(fd int, rsa *RawSockaddrAny) (Sockaddr, error) { var user [8]byte var name [8]byte - for i := 0; i < 8; i++ { + for i := range 8 { user[i] = byte(pp.User_id[i]) name[i] = byte(pp.Name[i]) } @@ -1173,11 +1174,11 @@ func anyToSockaddr(fd int, rsa *RawSockaddrAny) (Sockaddr, error) { Ifindex: int(pp.Ifindex), } name := (*[8]byte)(unsafe.Pointer(&sa.Name)) - for i := 0; i < 8; i++ { + for i := range 8 { name[i] = pp.Addr[i] } pgn := (*[4]byte)(unsafe.Pointer(&sa.PGN)) - for i := 0; i < 4; i++ { + for i := range 4 { pgn[i] = pp.Addr[i+8] } addr := (*[1]byte)(unsafe.Pointer(&sa.Addr)) @@ -1188,11 +1189,11 @@ func anyToSockaddr(fd int, rsa *RawSockaddrAny) (Sockaddr, error) { Ifindex: int(pp.Ifindex), } rx := (*[4]byte)(unsafe.Pointer(&sa.RxID)) - for i := 0; i < 4; i++ { + for i := range 4 { rx[i] = pp.Addr[i] } tx := (*[4]byte)(unsafe.Pointer(&sa.TxID)) - for i := 0; i < 4; i++ { + for i := range 4 { tx[i] = pp.Addr[i+4] } return sa, nil @@ -2216,10 +2217,7 @@ func readvRacedetect(iovecs []Iovec, n int, err error) { return } for i := 0; n > 0 && i < len(iovecs); i++ { - m := int(iovecs[i].Len) - if m > n { - m = n - } + m := min(int(iovecs[i].Len), n) n -= m if m > 0 { raceWriteRange(unsafe.Pointer(iovecs[i].Base), m) @@ -2270,10 +2268,7 @@ func writevRacedetect(iovecs []Iovec, n int) { return } for i := 0; n > 0 && i < len(iovecs); i++ { - m := int(iovecs[i].Len) - if m > n { - m = n - } + m := min(int(iovecs[i].Len), n) n -= m if m > 0 { raceReadRange(unsafe.Pointer(iovecs[i].Base), m) @@ -2320,12 +2315,7 @@ func isGroupMember(gid int) bool { return false } - for _, g := range groups { - if g == gid { - return true - } - } - return false + return slices.Contains(groups, gid) } func isCapDacOverrideSet() bool { diff --git a/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go b/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go index 24b346e1..813c05b6 100644 --- a/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go +++ b/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go @@ -2512,6 +2512,90 @@ var libc_munmap_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func readv(fd int, iovecs []Iovec) (n int, err error) { + var _p0 unsafe.Pointer + if len(iovecs) > 0 { + _p0 = unsafe.Pointer(&iovecs[0]) + } else { + _p0 = unsafe.Pointer(&_zero) + } + r0, _, e1 := syscall_syscall(libc_readv_trampoline_addr, uintptr(fd), uintptr(_p0), uintptr(len(iovecs))) + n = int(r0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_readv_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_readv readv "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + +func preadv(fd int, iovecs []Iovec, offset int64) (n int, err error) { + var _p0 unsafe.Pointer + if len(iovecs) > 0 { + _p0 = unsafe.Pointer(&iovecs[0]) + } else { + _p0 = unsafe.Pointer(&_zero) + } + r0, _, e1 := syscall_syscall6(libc_preadv_trampoline_addr, uintptr(fd), uintptr(_p0), uintptr(len(iovecs)), uintptr(offset), 0, 0) + n = int(r0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_preadv_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_preadv preadv "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + +func writev(fd int, iovecs []Iovec) (n int, err error) { + var _p0 unsafe.Pointer + if len(iovecs) > 0 { + _p0 = unsafe.Pointer(&iovecs[0]) + } else { + _p0 = unsafe.Pointer(&_zero) + } + r0, _, e1 := syscall_syscall(libc_writev_trampoline_addr, uintptr(fd), uintptr(_p0), uintptr(len(iovecs))) + n = int(r0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_writev_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_writev writev "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + +func pwritev(fd int, iovecs []Iovec, offset int64) (n int, err error) { + var _p0 unsafe.Pointer + if len(iovecs) > 0 { + _p0 = unsafe.Pointer(&iovecs[0]) + } else { + _p0 = unsafe.Pointer(&_zero) + } + r0, _, e1 := syscall_syscall6(libc_pwritev_trampoline_addr, uintptr(fd), uintptr(_p0), uintptr(len(iovecs)), uintptr(offset), 0, 0) + n = int(r0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_pwritev_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_pwritev pwritev "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func Fstat(fd int, stat *Stat_t) (err error) { _, _, e1 := syscall_syscall(libc_fstat64_trampoline_addr, uintptr(fd), uintptr(unsafe.Pointer(stat)), 0) if e1 != 0 { diff --git a/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s b/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s index ebd21310..fda32858 100644 --- a/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s +++ b/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s @@ -738,6 +738,26 @@ TEXT libc_munmap_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_munmap_trampoline_addr(SB), RODATA, $8 DATA ·libc_munmap_trampoline_addr(SB)/8, $libc_munmap_trampoline<>(SB) +TEXT libc_readv_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_readv(SB) +GLOBL ·libc_readv_trampoline_addr(SB), RODATA, $8 +DATA ·libc_readv_trampoline_addr(SB)/8, $libc_readv_trampoline<>(SB) + +TEXT libc_preadv_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_preadv(SB) +GLOBL ·libc_preadv_trampoline_addr(SB), RODATA, $8 +DATA ·libc_preadv_trampoline_addr(SB)/8, $libc_preadv_trampoline<>(SB) + +TEXT libc_writev_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_writev(SB) +GLOBL ·libc_writev_trampoline_addr(SB), RODATA, $8 +DATA ·libc_writev_trampoline_addr(SB)/8, $libc_writev_trampoline<>(SB) + +TEXT libc_pwritev_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_pwritev(SB) +GLOBL ·libc_pwritev_trampoline_addr(SB), RODATA, $8 +DATA ·libc_pwritev_trampoline_addr(SB)/8, $libc_pwritev_trampoline<>(SB) + TEXT libc_fstat64_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_fstat64(SB) GLOBL ·libc_fstat64_trampoline_addr(SB), RODATA, $8 diff --git a/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go b/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go index 824b9c2d..e6f58f3c 100644 --- a/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go +++ b/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go @@ -2512,6 +2512,90 @@ var libc_munmap_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func readv(fd int, iovecs []Iovec) (n int, err error) { + var _p0 unsafe.Pointer + if len(iovecs) > 0 { + _p0 = unsafe.Pointer(&iovecs[0]) + } else { + _p0 = unsafe.Pointer(&_zero) + } + r0, _, e1 := syscall_syscall(libc_readv_trampoline_addr, uintptr(fd), uintptr(_p0), uintptr(len(iovecs))) + n = int(r0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_readv_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_readv readv "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + +func preadv(fd int, iovecs []Iovec, offset int64) (n int, err error) { + var _p0 unsafe.Pointer + if len(iovecs) > 0 { + _p0 = unsafe.Pointer(&iovecs[0]) + } else { + _p0 = unsafe.Pointer(&_zero) + } + r0, _, e1 := syscall_syscall6(libc_preadv_trampoline_addr, uintptr(fd), uintptr(_p0), uintptr(len(iovecs)), uintptr(offset), 0, 0) + n = int(r0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_preadv_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_preadv preadv "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + +func writev(fd int, iovecs []Iovec) (n int, err error) { + var _p0 unsafe.Pointer + if len(iovecs) > 0 { + _p0 = unsafe.Pointer(&iovecs[0]) + } else { + _p0 = unsafe.Pointer(&_zero) + } + r0, _, e1 := syscall_syscall(libc_writev_trampoline_addr, uintptr(fd), uintptr(_p0), uintptr(len(iovecs))) + n = int(r0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_writev_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_writev writev "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + +func pwritev(fd int, iovecs []Iovec, offset int64) (n int, err error) { + var _p0 unsafe.Pointer + if len(iovecs) > 0 { + _p0 = unsafe.Pointer(&iovecs[0]) + } else { + _p0 = unsafe.Pointer(&_zero) + } + r0, _, e1 := syscall_syscall6(libc_pwritev_trampoline_addr, uintptr(fd), uintptr(_p0), uintptr(len(iovecs)), uintptr(offset), 0, 0) + n = int(r0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_pwritev_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_pwritev pwritev "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func Fstat(fd int, stat *Stat_t) (err error) { _, _, e1 := syscall_syscall(libc_fstat_trampoline_addr, uintptr(fd), uintptr(unsafe.Pointer(stat)), 0) if e1 != 0 { diff --git a/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s b/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s index 4f178a22..7f8998b9 100644 --- a/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s +++ b/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s @@ -738,6 +738,26 @@ TEXT libc_munmap_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_munmap_trampoline_addr(SB), RODATA, $8 DATA ·libc_munmap_trampoline_addr(SB)/8, $libc_munmap_trampoline<>(SB) +TEXT libc_readv_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_readv(SB) +GLOBL ·libc_readv_trampoline_addr(SB), RODATA, $8 +DATA ·libc_readv_trampoline_addr(SB)/8, $libc_readv_trampoline<>(SB) + +TEXT libc_preadv_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_preadv(SB) +GLOBL ·libc_preadv_trampoline_addr(SB), RODATA, $8 +DATA ·libc_preadv_trampoline_addr(SB)/8, $libc_preadv_trampoline<>(SB) + +TEXT libc_writev_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_writev(SB) +GLOBL ·libc_writev_trampoline_addr(SB), RODATA, $8 +DATA ·libc_writev_trampoline_addr(SB)/8, $libc_writev_trampoline<>(SB) + +TEXT libc_pwritev_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_pwritev(SB) +GLOBL ·libc_pwritev_trampoline_addr(SB), RODATA, $8 +DATA ·libc_pwritev_trampoline_addr(SB)/8, $libc_pwritev_trampoline<>(SB) + TEXT libc_fstat_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_fstat(SB) GLOBL ·libc_fstat_trampoline_addr(SB), RODATA, $8 diff --git a/vendor/golang.org/x/sys/windows/types_windows.go b/vendor/golang.org/x/sys/windows/types_windows.go index 9d138de5..ad67df2f 100644 --- a/vendor/golang.org/x/sys/windows/types_windows.go +++ b/vendor/golang.org/x/sys/windows/types_windows.go @@ -1074,6 +1074,7 @@ const ( IP_ADD_MEMBERSHIP = 0xc IP_DROP_MEMBERSHIP = 0xd IP_PKTINFO = 0x13 + IP_MTU_DISCOVER = 0x47 IPV6_V6ONLY = 0x1b IPV6_UNICAST_HOPS = 0x4 @@ -1083,6 +1084,7 @@ const ( IPV6_JOIN_GROUP = 0xc IPV6_LEAVE_GROUP = 0xd IPV6_PKTINFO = 0x13 + IPV6_MTU_DISCOVER = 0x47 MSG_OOB = 0x1 MSG_PEEK = 0x2 @@ -1132,6 +1134,15 @@ const ( WSASYS_STATUS_LEN = 128 ) +// enum PMTUD_STATE from ws2ipdef.h +const ( + IP_PMTUDISC_NOT_SET = 0 + IP_PMTUDISC_DO = 1 + IP_PMTUDISC_DONT = 2 + IP_PMTUDISC_PROBE = 3 + IP_PMTUDISC_MAX = 4 +) + type WSABuf struct { Len uint32 Buf *byte @@ -1146,6 +1157,22 @@ type WSAMsg struct { Flags uint32 } +type WSACMSGHDR struct { + Len uintptr + Level int32 + Type int32 +} + +type IN_PKTINFO struct { + Addr [4]byte + Ifindex uint32 +} + +type IN6_PKTINFO struct { + Addr [16]byte + Ifindex uint32 +} + // Flags for WSASocket const ( WSA_FLAG_OVERLAPPED = 0x01 diff --git a/vendor/golang.org/x/tools/go/ast/inspector/inspector.go b/vendor/golang.org/x/tools/go/ast/inspector/inspector.go index 1fc1de0b..0e0ba4c0 100644 --- a/vendor/golang.org/x/tools/go/ast/inspector/inspector.go +++ b/vendor/golang.org/x/tools/go/ast/inspector/inspector.go @@ -73,6 +73,15 @@ func (in *Inspector) Preorder(types []ast.Node, f func(ast.Node)) { // check, Preorder is almost twice as fast as Nodes. The two // features seem to contribute similar slowdowns (~1.4x each). + // This function is equivalent to the PreorderSeq call below, + // but to avoid the additional dynamic call (which adds 13-35% + // to the benchmarks), we expand it out. + // + // in.PreorderSeq(types...)(func(n ast.Node) bool { + // f(n) + // return true + // }) + mask := maskOf(types) for i := 0; i < len(in.events); { ev := in.events[i] diff --git a/vendor/golang.org/x/tools/go/ast/inspector/iter.go b/vendor/golang.org/x/tools/go/ast/inspector/iter.go new file mode 100644 index 00000000..b7e95911 --- /dev/null +++ b/vendor/golang.org/x/tools/go/ast/inspector/iter.go @@ -0,0 +1,85 @@ +// Copyright 2024 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +//go:build go1.23 + +package inspector + +import ( + "go/ast" + "iter" +) + +// PreorderSeq returns an iterator that visits all the +// nodes of the files supplied to New in depth-first order. +// It visits each node n before n's children. +// The complete traversal sequence is determined by ast.Inspect. +// +// The types argument, if non-empty, enables type-based +// filtering of events: only nodes whose type matches an +// element of the types slice are included in the sequence. +func (in *Inspector) PreorderSeq(types ...ast.Node) iter.Seq[ast.Node] { + + // This implementation is identical to Preorder, + // except that it supports breaking out of the loop. + + return func(yield func(ast.Node) bool) { + mask := maskOf(types) + for i := 0; i < len(in.events); { + ev := in.events[i] + if ev.index > i { + // push + if ev.typ&mask != 0 { + if !yield(ev.node) { + break + } + } + pop := ev.index + if in.events[pop].typ&mask == 0 { + // Subtrees do not contain types: skip them and pop. + i = pop + 1 + continue + } + } + i++ + } + } +} + +// All[N] returns an iterator over all the nodes of type N. +// N must be a pointer-to-struct type that implements ast.Node. +// +// Example: +// +// for call := range All[*ast.CallExpr](in) { ... } +func All[N interface { + *S + ast.Node +}, S any](in *Inspector) iter.Seq[N] { + + // To avoid additional dynamic call overheads, + // we duplicate rather than call the logic of PreorderSeq. + + mask := typeOf((N)(nil)) + return func(yield func(N) bool) { + for i := 0; i < len(in.events); { + ev := in.events[i] + if ev.index > i { + // push + if ev.typ&mask != 0 { + if !yield(ev.node.(N)) { + break + } + } + pop := ev.index + if in.events[pop].typ&mask == 0 { + // Subtrees do not contain types: skip them and pop. + i = pop + 1 + continue + } + } + i++ + } + } +} diff --git a/vendor/google.golang.org/protobuf/internal/editiondefaults/editions_defaults.binpb b/vendor/google.golang.org/protobuf/internal/editiondefaults/editions_defaults.binpb index 5a57ef6f..323829da 100644 Binary files a/vendor/google.golang.org/protobuf/internal/editiondefaults/editions_defaults.binpb and b/vendor/google.golang.org/protobuf/internal/editiondefaults/editions_defaults.binpb differ diff --git a/vendor/google.golang.org/protobuf/internal/filedesc/editions.go b/vendor/google.golang.org/protobuf/internal/filedesc/editions.go index 10132c9b..b08b7183 100644 --- a/vendor/google.golang.org/protobuf/internal/filedesc/editions.go +++ b/vendor/google.golang.org/protobuf/internal/filedesc/editions.go @@ -69,6 +69,9 @@ func unmarshalFeatureSet(b []byte, parent EditionFeatures) EditionFeatures { parent.IsDelimitedEncoded = v == genid.FeatureSet_DELIMITED_enum_value case genid.FeatureSet_JsonFormat_field_number: parent.IsJSONCompliant = v == genid.FeatureSet_ALLOW_enum_value + case genid.FeatureSet_EnforceNamingStyle_field_number: + // EnforceNamingStyle is enforced in protoc, languages other than C++ + // are not supposed to do anything with this feature. default: panic(fmt.Sprintf("unkown field number %d while unmarshalling FeatureSet", num)) } diff --git a/vendor/google.golang.org/protobuf/internal/genid/descriptor_gen.go b/vendor/google.golang.org/protobuf/internal/genid/descriptor_gen.go index f30ab6b5..39524782 100644 --- a/vendor/google.golang.org/protobuf/internal/genid/descriptor_gen.go +++ b/vendor/google.golang.org/protobuf/internal/genid/descriptor_gen.go @@ -1014,6 +1014,7 @@ const ( FeatureSet_Utf8Validation_field_name protoreflect.Name = "utf8_validation" FeatureSet_MessageEncoding_field_name protoreflect.Name = "message_encoding" FeatureSet_JsonFormat_field_name protoreflect.Name = "json_format" + FeatureSet_EnforceNamingStyle_field_name protoreflect.Name = "enforce_naming_style" FeatureSet_FieldPresence_field_fullname protoreflect.FullName = "google.protobuf.FeatureSet.field_presence" FeatureSet_EnumType_field_fullname protoreflect.FullName = "google.protobuf.FeatureSet.enum_type" @@ -1021,6 +1022,7 @@ const ( FeatureSet_Utf8Validation_field_fullname protoreflect.FullName = "google.protobuf.FeatureSet.utf8_validation" FeatureSet_MessageEncoding_field_fullname protoreflect.FullName = "google.protobuf.FeatureSet.message_encoding" FeatureSet_JsonFormat_field_fullname protoreflect.FullName = "google.protobuf.FeatureSet.json_format" + FeatureSet_EnforceNamingStyle_field_fullname protoreflect.FullName = "google.protobuf.FeatureSet.enforce_naming_style" ) // Field numbers for google.protobuf.FeatureSet. @@ -1031,6 +1033,7 @@ const ( FeatureSet_Utf8Validation_field_number protoreflect.FieldNumber = 4 FeatureSet_MessageEncoding_field_number protoreflect.FieldNumber = 5 FeatureSet_JsonFormat_field_number protoreflect.FieldNumber = 6 + FeatureSet_EnforceNamingStyle_field_number protoreflect.FieldNumber = 7 ) // Full and short names for google.protobuf.FeatureSet.FieldPresence. @@ -1112,6 +1115,19 @@ const ( FeatureSet_LEGACY_BEST_EFFORT_enum_value = 2 ) +// Full and short names for google.protobuf.FeatureSet.EnforceNamingStyle. +const ( + FeatureSet_EnforceNamingStyle_enum_fullname = "google.protobuf.FeatureSet.EnforceNamingStyle" + FeatureSet_EnforceNamingStyle_enum_name = "EnforceNamingStyle" +) + +// Enum values for google.protobuf.FeatureSet.EnforceNamingStyle. +const ( + FeatureSet_ENFORCE_NAMING_STYLE_UNKNOWN_enum_value = 0 + FeatureSet_STYLE2024_enum_value = 1 + FeatureSet_STYLE_LEGACY_enum_value = 2 +) + // Names for google.protobuf.FeatureSetDefaults. const ( FeatureSetDefaults_message_name protoreflect.Name = "FeatureSetDefaults" diff --git a/vendor/google.golang.org/protobuf/internal/strs/strings_unsafe_go121.go b/vendor/google.golang.org/protobuf/internal/strs/strings_unsafe.go similarity index 99% rename from vendor/google.golang.org/protobuf/internal/strs/strings_unsafe_go121.go rename to vendor/google.golang.org/protobuf/internal/strs/strings_unsafe.go index 1ffddf68..42dd6f70 100644 --- a/vendor/google.golang.org/protobuf/internal/strs/strings_unsafe_go121.go +++ b/vendor/google.golang.org/protobuf/internal/strs/strings_unsafe.go @@ -2,8 +2,6 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -//go:build go1.21 - package strs import ( diff --git a/vendor/google.golang.org/protobuf/internal/strs/strings_unsafe_go120.go b/vendor/google.golang.org/protobuf/internal/strs/strings_unsafe_go120.go deleted file mode 100644 index 832a7988..00000000 --- a/vendor/google.golang.org/protobuf/internal/strs/strings_unsafe_go120.go +++ /dev/null @@ -1,94 +0,0 @@ -// Copyright 2018 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -//go:build !go1.21 - -package strs - -import ( - "unsafe" - - "google.golang.org/protobuf/reflect/protoreflect" -) - -type ( - stringHeader struct { - Data unsafe.Pointer - Len int - } - sliceHeader struct { - Data unsafe.Pointer - Len int - Cap int - } -) - -// UnsafeString returns an unsafe string reference of b. -// The caller must treat the input slice as immutable. -// -// WARNING: Use carefully. The returned result must not leak to the end user -// unless the input slice is provably immutable. -func UnsafeString(b []byte) (s string) { - src := (*sliceHeader)(unsafe.Pointer(&b)) - dst := (*stringHeader)(unsafe.Pointer(&s)) - dst.Data = src.Data - dst.Len = src.Len - return s -} - -// UnsafeBytes returns an unsafe bytes slice reference of s. -// The caller must treat returned slice as immutable. -// -// WARNING: Use carefully. The returned result must not leak to the end user. -func UnsafeBytes(s string) (b []byte) { - src := (*stringHeader)(unsafe.Pointer(&s)) - dst := (*sliceHeader)(unsafe.Pointer(&b)) - dst.Data = src.Data - dst.Len = src.Len - dst.Cap = src.Len - return b -} - -// Builder builds a set of strings with shared lifetime. -// This differs from strings.Builder, which is for building a single string. -type Builder struct { - buf []byte -} - -// AppendFullName is equivalent to protoreflect.FullName.Append, -// but optimized for large batches where each name has a shared lifetime. -func (sb *Builder) AppendFullName(prefix protoreflect.FullName, name protoreflect.Name) protoreflect.FullName { - n := len(prefix) + len(".") + len(name) - if len(prefix) == 0 { - n -= len(".") - } - sb.grow(n) - sb.buf = append(sb.buf, prefix...) - sb.buf = append(sb.buf, '.') - sb.buf = append(sb.buf, name...) - return protoreflect.FullName(sb.last(n)) -} - -// MakeString is equivalent to string(b), but optimized for large batches -// with a shared lifetime. -func (sb *Builder) MakeString(b []byte) string { - sb.grow(len(b)) - sb.buf = append(sb.buf, b...) - return sb.last(len(b)) -} - -func (sb *Builder) grow(n int) { - if cap(sb.buf)-len(sb.buf) >= n { - return - } - - // Unlike strings.Builder, we do not need to copy over the contents - // of the old buffer since our builder provides no API for - // retrieving previously created strings. - sb.buf = make([]byte, 0, 2*(cap(sb.buf)+n)) -} - -func (sb *Builder) last(n int) string { - return UnsafeString(sb.buf[len(sb.buf)-n:]) -} diff --git a/vendor/google.golang.org/protobuf/internal/version/version.go b/vendor/google.golang.org/protobuf/internal/version/version.go index 01efc330..aac1cb18 100644 --- a/vendor/google.golang.org/protobuf/internal/version/version.go +++ b/vendor/google.golang.org/protobuf/internal/version/version.go @@ -52,7 +52,7 @@ import ( const ( Major = 1 Minor = 36 - Patch = 5 + Patch = 6 PreRelease = "" ) diff --git a/vendor/google.golang.org/protobuf/proto/merge.go b/vendor/google.golang.org/protobuf/proto/merge.go index 3c6fe578..ef55b97d 100644 --- a/vendor/google.golang.org/protobuf/proto/merge.go +++ b/vendor/google.golang.org/protobuf/proto/merge.go @@ -59,6 +59,12 @@ func Clone(m Message) Message { return dst.Interface() } +// CloneOf returns a deep copy of m. If the top-level message is invalid, +// it returns an invalid message as well. +func CloneOf[M Message](m M) M { + return Clone(m).(M) +} + // mergeOptions provides a namespace for merge functions, and can be // exported in the future if we add user-visible merge options. type mergeOptions struct{} diff --git a/vendor/google.golang.org/protobuf/reflect/protoreflect/source_gen.go b/vendor/google.golang.org/protobuf/reflect/protoreflect/source_gen.go index ea154eec..a4a0a297 100644 --- a/vendor/google.golang.org/protobuf/reflect/protoreflect/source_gen.go +++ b/vendor/google.golang.org/protobuf/reflect/protoreflect/source_gen.go @@ -398,6 +398,8 @@ func (p *SourcePath) appendFeatureSet(b []byte) []byte { b = p.appendSingularField(b, "message_encoding", nil) case 6: b = p.appendSingularField(b, "json_format", nil) + case 7: + b = p.appendSingularField(b, "enforce_naming_style", nil) } return b } diff --git a/vendor/google.golang.org/protobuf/reflect/protoreflect/value_unsafe_go121.go b/vendor/google.golang.org/protobuf/reflect/protoreflect/value_unsafe.go similarity index 99% rename from vendor/google.golang.org/protobuf/reflect/protoreflect/value_unsafe_go121.go rename to vendor/google.golang.org/protobuf/reflect/protoreflect/value_unsafe.go index 479527b5..fe17f372 100644 --- a/vendor/google.golang.org/protobuf/reflect/protoreflect/value_unsafe_go121.go +++ b/vendor/google.golang.org/protobuf/reflect/protoreflect/value_unsafe.go @@ -2,8 +2,6 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -//go:build go1.21 - package protoreflect import ( diff --git a/vendor/google.golang.org/protobuf/reflect/protoreflect/value_unsafe_go120.go b/vendor/google.golang.org/protobuf/reflect/protoreflect/value_unsafe_go120.go deleted file mode 100644 index 0015fcb3..00000000 --- a/vendor/google.golang.org/protobuf/reflect/protoreflect/value_unsafe_go120.go +++ /dev/null @@ -1,98 +0,0 @@ -// Copyright 2018 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -//go:build !go1.21 - -package protoreflect - -import ( - "unsafe" - - "google.golang.org/protobuf/internal/pragma" -) - -type ( - stringHeader struct { - Data unsafe.Pointer - Len int - } - sliceHeader struct { - Data unsafe.Pointer - Len int - Cap int - } - ifaceHeader struct { - Type unsafe.Pointer - Data unsafe.Pointer - } -) - -var ( - nilType = typeOf(nil) - boolType = typeOf(*new(bool)) - int32Type = typeOf(*new(int32)) - int64Type = typeOf(*new(int64)) - uint32Type = typeOf(*new(uint32)) - uint64Type = typeOf(*new(uint64)) - float32Type = typeOf(*new(float32)) - float64Type = typeOf(*new(float64)) - stringType = typeOf(*new(string)) - bytesType = typeOf(*new([]byte)) - enumType = typeOf(*new(EnumNumber)) -) - -// typeOf returns a pointer to the Go type information. -// The pointer is comparable and equal if and only if the types are identical. -func typeOf(t any) unsafe.Pointer { - return (*ifaceHeader)(unsafe.Pointer(&t)).Type -} - -// value is a union where only one type can be represented at a time. -// The struct is 24B large on 64-bit systems and requires the minimum storage -// necessary to represent each possible type. -// -// The Go GC needs to be able to scan variables containing pointers. -// As such, pointers and non-pointers cannot be intermixed. -type value struct { - pragma.DoNotCompare // 0B - - // typ stores the type of the value as a pointer to the Go type. - typ unsafe.Pointer // 8B - - // ptr stores the data pointer for a String, Bytes, or interface value. - ptr unsafe.Pointer // 8B - - // num stores a Bool, Int32, Int64, Uint32, Uint64, Float32, Float64, or - // Enum value as a raw uint64. - // - // It is also used to store the length of a String or Bytes value; - // the capacity is ignored. - num uint64 // 8B -} - -func valueOfString(v string) Value { - p := (*stringHeader)(unsafe.Pointer(&v)) - return Value{typ: stringType, ptr: p.Data, num: uint64(len(v))} -} -func valueOfBytes(v []byte) Value { - p := (*sliceHeader)(unsafe.Pointer(&v)) - return Value{typ: bytesType, ptr: p.Data, num: uint64(len(v))} -} -func valueOfIface(v any) Value { - p := (*ifaceHeader)(unsafe.Pointer(&v)) - return Value{typ: p.Type, ptr: p.Data} -} - -func (v Value) getString() (x string) { - *(*stringHeader)(unsafe.Pointer(&x)) = stringHeader{Data: v.ptr, Len: int(v.num)} - return x -} -func (v Value) getBytes() (x []byte) { - *(*sliceHeader)(unsafe.Pointer(&x)) = sliceHeader{Data: v.ptr, Len: int(v.num), Cap: int(v.num)} - return x -} -func (v Value) getIface() (x any) { - *(*ifaceHeader)(unsafe.Pointer(&x)) = ifaceHeader{Type: v.typ, Data: v.ptr} - return x -} diff --git a/vendor/google.golang.org/protobuf/types/descriptorpb/descriptor.pb.go b/vendor/google.golang.org/protobuf/types/descriptorpb/descriptor.pb.go index a5163376..7fe280f1 100644 --- a/vendor/google.golang.org/protobuf/types/descriptorpb/descriptor.pb.go +++ b/vendor/google.golang.org/protobuf/types/descriptorpb/descriptor.pb.go @@ -1139,6 +1139,65 @@ func (FeatureSet_JsonFormat) EnumDescriptor() ([]byte, []int) { return file_google_protobuf_descriptor_proto_rawDescGZIP(), []int{19, 5} } +type FeatureSet_EnforceNamingStyle int32 + +const ( + FeatureSet_ENFORCE_NAMING_STYLE_UNKNOWN FeatureSet_EnforceNamingStyle = 0 + FeatureSet_STYLE2024 FeatureSet_EnforceNamingStyle = 1 + FeatureSet_STYLE_LEGACY FeatureSet_EnforceNamingStyle = 2 +) + +// Enum value maps for FeatureSet_EnforceNamingStyle. +var ( + FeatureSet_EnforceNamingStyle_name = map[int32]string{ + 0: "ENFORCE_NAMING_STYLE_UNKNOWN", + 1: "STYLE2024", + 2: "STYLE_LEGACY", + } + FeatureSet_EnforceNamingStyle_value = map[string]int32{ + "ENFORCE_NAMING_STYLE_UNKNOWN": 0, + "STYLE2024": 1, + "STYLE_LEGACY": 2, + } +) + +func (x FeatureSet_EnforceNamingStyle) Enum() *FeatureSet_EnforceNamingStyle { + p := new(FeatureSet_EnforceNamingStyle) + *p = x + return p +} + +func (x FeatureSet_EnforceNamingStyle) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (FeatureSet_EnforceNamingStyle) Descriptor() protoreflect.EnumDescriptor { + return file_google_protobuf_descriptor_proto_enumTypes[16].Descriptor() +} + +func (FeatureSet_EnforceNamingStyle) Type() protoreflect.EnumType { + return &file_google_protobuf_descriptor_proto_enumTypes[16] +} + +func (x FeatureSet_EnforceNamingStyle) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Do not use. +func (x *FeatureSet_EnforceNamingStyle) UnmarshalJSON(b []byte) error { + num, err := protoimpl.X.UnmarshalJSONEnum(x.Descriptor(), b) + if err != nil { + return err + } + *x = FeatureSet_EnforceNamingStyle(num) + return nil +} + +// Deprecated: Use FeatureSet_EnforceNamingStyle.Descriptor instead. +func (FeatureSet_EnforceNamingStyle) EnumDescriptor() ([]byte, []int) { + return file_google_protobuf_descriptor_proto_rawDescGZIP(), []int{19, 6} +} + // Represents the identified object's effect on the element in the original // .proto file. type GeneratedCodeInfo_Annotation_Semantic int32 @@ -1177,11 +1236,11 @@ func (x GeneratedCodeInfo_Annotation_Semantic) String() string { } func (GeneratedCodeInfo_Annotation_Semantic) Descriptor() protoreflect.EnumDescriptor { - return file_google_protobuf_descriptor_proto_enumTypes[16].Descriptor() + return file_google_protobuf_descriptor_proto_enumTypes[17].Descriptor() } func (GeneratedCodeInfo_Annotation_Semantic) Type() protoreflect.EnumType { - return &file_google_protobuf_descriptor_proto_enumTypes[16] + return &file_google_protobuf_descriptor_proto_enumTypes[17] } func (x GeneratedCodeInfo_Annotation_Semantic) Number() protoreflect.EnumNumber { @@ -1277,8 +1336,14 @@ type FileDescriptorProto struct { // The supported values are "proto2", "proto3", and "editions". // // If `edition` is present, this value must be "editions". + // WARNING: This field should only be used by protobuf plugins or special + // cases like the proto compiler. Other uses are discouraged and + // developers should rely on the protoreflect APIs for their client language. Syntax *string `protobuf:"bytes,12,opt,name=syntax" json:"syntax,omitempty"` // The edition of the proto file. + // WARNING: This field should only be used by protobuf plugins or special + // cases like the proto compiler. Other uses are discouraged and + // developers should rely on the protoreflect APIs for their client language. Edition *Edition `protobuf:"varint,14,opt,name=edition,enum=google.protobuf.Edition" json:"edition,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache @@ -2212,6 +2277,9 @@ type FileOptions struct { // determining the ruby package. RubyPackage *string `protobuf:"bytes,45,opt,name=ruby_package,json=rubyPackage" json:"ruby_package,omitempty"` // Any features defined in the specific edition. + // WARNING: This field should only be used by protobuf plugins or special + // cases like the proto compiler. Other uses are discouraged and + // developers should rely on the protoreflect APIs for their client language. Features *FeatureSet `protobuf:"bytes,50,opt,name=features" json:"features,omitempty"` // The parser stores options it doesn't recognize here. // See the documentation for the "Options" section above. @@ -2482,6 +2550,9 @@ type MessageOptions struct { // Deprecated: Marked as deprecated in google/protobuf/descriptor.proto. DeprecatedLegacyJsonFieldConflicts *bool `protobuf:"varint,11,opt,name=deprecated_legacy_json_field_conflicts,json=deprecatedLegacyJsonFieldConflicts" json:"deprecated_legacy_json_field_conflicts,omitempty"` // Any features defined in the specific edition. + // WARNING: This field should only be used by protobuf plugins or special + // cases like the proto compiler. Other uses are discouraged and + // developers should rely on the protoreflect APIs for their client language. Features *FeatureSet `protobuf:"bytes,12,opt,name=features" json:"features,omitempty"` // The parser stores options it doesn't recognize here. See above. UninterpretedOption []*UninterpretedOption `protobuf:"bytes,999,rep,name=uninterpreted_option,json=uninterpretedOption" json:"uninterpreted_option,omitempty"` @@ -2648,6 +2719,9 @@ type FieldOptions struct { Targets []FieldOptions_OptionTargetType `protobuf:"varint,19,rep,name=targets,enum=google.protobuf.FieldOptions_OptionTargetType" json:"targets,omitempty"` EditionDefaults []*FieldOptions_EditionDefault `protobuf:"bytes,20,rep,name=edition_defaults,json=editionDefaults" json:"edition_defaults,omitempty"` // Any features defined in the specific edition. + // WARNING: This field should only be used by protobuf plugins or special + // cases like the proto compiler. Other uses are discouraged and + // developers should rely on the protoreflect APIs for their client language. Features *FeatureSet `protobuf:"bytes,21,opt,name=features" json:"features,omitempty"` FeatureSupport *FieldOptions_FeatureSupport `protobuf:"bytes,22,opt,name=feature_support,json=featureSupport" json:"feature_support,omitempty"` // The parser stores options it doesn't recognize here. See above. @@ -2799,6 +2873,9 @@ func (x *FieldOptions) GetUninterpretedOption() []*UninterpretedOption { type OneofOptions struct { state protoimpl.MessageState `protogen:"open.v1"` // Any features defined in the specific edition. + // WARNING: This field should only be used by protobuf plugins or special + // cases like the proto compiler. Other uses are discouraged and + // developers should rely on the protoreflect APIs for their client language. Features *FeatureSet `protobuf:"bytes,1,opt,name=features" json:"features,omitempty"` // The parser stores options it doesn't recognize here. See above. UninterpretedOption []*UninterpretedOption `protobuf:"bytes,999,rep,name=uninterpreted_option,json=uninterpretedOption" json:"uninterpreted_option,omitempty"` @@ -2871,6 +2948,9 @@ type EnumOptions struct { // Deprecated: Marked as deprecated in google/protobuf/descriptor.proto. DeprecatedLegacyJsonFieldConflicts *bool `protobuf:"varint,6,opt,name=deprecated_legacy_json_field_conflicts,json=deprecatedLegacyJsonFieldConflicts" json:"deprecated_legacy_json_field_conflicts,omitempty"` // Any features defined in the specific edition. + // WARNING: This field should only be used by protobuf plugins or special + // cases like the proto compiler. Other uses are discouraged and + // developers should rely on the protoreflect APIs for their client language. Features *FeatureSet `protobuf:"bytes,7,opt,name=features" json:"features,omitempty"` // The parser stores options it doesn't recognize here. See above. UninterpretedOption []*UninterpretedOption `protobuf:"bytes,999,rep,name=uninterpreted_option,json=uninterpretedOption" json:"uninterpreted_option,omitempty"` @@ -2958,6 +3038,9 @@ type EnumValueOptions struct { // this is a formalization for deprecating enum values. Deprecated *bool `protobuf:"varint,1,opt,name=deprecated,def=0" json:"deprecated,omitempty"` // Any features defined in the specific edition. + // WARNING: This field should only be used by protobuf plugins or special + // cases like the proto compiler. Other uses are discouraged and + // developers should rely on the protoreflect APIs for their client language. Features *FeatureSet `protobuf:"bytes,2,opt,name=features" json:"features,omitempty"` // Indicate that fields annotated with this enum value should not be printed // out when using debug formats, e.g. when the field contains sensitive @@ -3046,6 +3129,9 @@ func (x *EnumValueOptions) GetUninterpretedOption() []*UninterpretedOption { type ServiceOptions struct { state protoimpl.MessageState `protogen:"open.v1"` // Any features defined in the specific edition. + // WARNING: This field should only be used by protobuf plugins or special + // cases like the proto compiler. Other uses are discouraged and + // developers should rely on the protoreflect APIs for their client language. Features *FeatureSet `protobuf:"bytes,34,opt,name=features" json:"features,omitempty"` // Is this service deprecated? // Depending on the target platform, this can emit Deprecated annotations @@ -3124,6 +3210,9 @@ type MethodOptions struct { Deprecated *bool `protobuf:"varint,33,opt,name=deprecated,def=0" json:"deprecated,omitempty"` IdempotencyLevel *MethodOptions_IdempotencyLevel `protobuf:"varint,34,opt,name=idempotency_level,json=idempotencyLevel,enum=google.protobuf.MethodOptions_IdempotencyLevel,def=0" json:"idempotency_level,omitempty"` // Any features defined in the specific edition. + // WARNING: This field should only be used by protobuf plugins or special + // cases like the proto compiler. Other uses are discouraged and + // developers should rely on the protoreflect APIs for their client language. Features *FeatureSet `protobuf:"bytes,35,opt,name=features" json:"features,omitempty"` // The parser stores options it doesn't recognize here. See above. UninterpretedOption []*UninterpretedOption `protobuf:"bytes,999,rep,name=uninterpreted_option,json=uninterpretedOption" json:"uninterpreted_option,omitempty"` @@ -3310,6 +3399,7 @@ type FeatureSet struct { Utf8Validation *FeatureSet_Utf8Validation `protobuf:"varint,4,opt,name=utf8_validation,json=utf8Validation,enum=google.protobuf.FeatureSet_Utf8Validation" json:"utf8_validation,omitempty"` MessageEncoding *FeatureSet_MessageEncoding `protobuf:"varint,5,opt,name=message_encoding,json=messageEncoding,enum=google.protobuf.FeatureSet_MessageEncoding" json:"message_encoding,omitempty"` JsonFormat *FeatureSet_JsonFormat `protobuf:"varint,6,opt,name=json_format,json=jsonFormat,enum=google.protobuf.FeatureSet_JsonFormat" json:"json_format,omitempty"` + EnforceNamingStyle *FeatureSet_EnforceNamingStyle `protobuf:"varint,7,opt,name=enforce_naming_style,json=enforceNamingStyle,enum=google.protobuf.FeatureSet_EnforceNamingStyle" json:"enforce_naming_style,omitempty"` extensionFields protoimpl.ExtensionFields unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache @@ -3387,6 +3477,13 @@ func (x *FeatureSet) GetJsonFormat() FeatureSet_JsonFormat { return FeatureSet_JSON_FORMAT_UNKNOWN } +func (x *FeatureSet) GetEnforceNamingStyle() FeatureSet_EnforceNamingStyle { + if x != nil && x.EnforceNamingStyle != nil { + return *x.EnforceNamingStyle + } + return FeatureSet_ENFORCE_NAMING_STYLE_UNKNOWN +} + // A compiled specification for the defaults of a set of features. These // messages are generated from FeatureSet extensions and can be used to seed // feature resolution. The resolution with this object becomes a simple search @@ -4361,777 +4458,367 @@ func (x *GeneratedCodeInfo_Annotation) GetSemantic() GeneratedCodeInfo_Annotatio var File_google_protobuf_descriptor_proto protoreflect.FileDescriptor -var file_google_protobuf_descriptor_proto_rawDesc = string([]byte{ - 0x0a, 0x20, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2f, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x12, 0x0f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x62, 0x75, 0x66, 0x22, 0x5b, 0x0a, 0x11, 0x46, 0x69, 0x6c, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, - 0x69, 0x70, 0x74, 0x6f, 0x72, 0x53, 0x65, 0x74, 0x12, 0x38, 0x0a, 0x04, 0x66, 0x69, 0x6c, 0x65, - 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x44, 0x65, 0x73, - 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x52, 0x04, 0x66, 0x69, - 0x6c, 0x65, 0x2a, 0x0c, 0x08, 0x80, 0xec, 0xca, 0xff, 0x01, 0x10, 0x81, 0xec, 0xca, 0xff, 0x01, - 0x22, 0x98, 0x05, 0x0a, 0x13, 0x46, 0x69, 0x6c, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, - 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, - 0x70, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x70, - 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x64, 0x65, 0x70, 0x65, 0x6e, 0x64, - 0x65, 0x6e, 0x63, 0x79, 0x18, 0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0a, 0x64, 0x65, 0x70, 0x65, - 0x6e, 0x64, 0x65, 0x6e, 0x63, 0x79, 0x12, 0x2b, 0x0a, 0x11, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, - 0x5f, 0x64, 0x65, 0x70, 0x65, 0x6e, 0x64, 0x65, 0x6e, 0x63, 0x79, 0x18, 0x0a, 0x20, 0x03, 0x28, - 0x05, 0x52, 0x10, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x44, 0x65, 0x70, 0x65, 0x6e, 0x64, 0x65, - 0x6e, 0x63, 0x79, 0x12, 0x27, 0x0a, 0x0f, 0x77, 0x65, 0x61, 0x6b, 0x5f, 0x64, 0x65, 0x70, 0x65, - 0x6e, 0x64, 0x65, 0x6e, 0x63, 0x79, 0x18, 0x0b, 0x20, 0x03, 0x28, 0x05, 0x52, 0x0e, 0x77, 0x65, - 0x61, 0x6b, 0x44, 0x65, 0x70, 0x65, 0x6e, 0x64, 0x65, 0x6e, 0x63, 0x79, 0x12, 0x43, 0x0a, 0x0c, - 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x03, - 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, - 0x72, 0x6f, 0x74, 0x6f, 0x52, 0x0b, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x54, 0x79, 0x70, - 0x65, 0x12, 0x41, 0x0a, 0x09, 0x65, 0x6e, 0x75, 0x6d, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x05, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6e, 0x75, 0x6d, 0x44, 0x65, 0x73, 0x63, 0x72, - 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x52, 0x08, 0x65, 0x6e, 0x75, 0x6d, - 0x54, 0x79, 0x70, 0x65, 0x12, 0x41, 0x0a, 0x07, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x18, - 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x44, - 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x52, 0x07, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x43, 0x0a, 0x09, 0x65, 0x78, 0x74, 0x65, 0x6e, - 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, - 0x6c, 0x64, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, - 0x6f, 0x52, 0x09, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x36, 0x0a, 0x07, - 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c, 0x2e, - 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, - 0x46, 0x69, 0x6c, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x07, 0x6f, 0x70, 0x74, - 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x49, 0x0a, 0x10, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x63, - 0x6f, 0x64, 0x65, 0x5f, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, - 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, - 0x2e, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x43, 0x6f, 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, - 0x0e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x43, 0x6f, 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, - 0x16, 0x0a, 0x06, 0x73, 0x79, 0x6e, 0x74, 0x61, 0x78, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x06, 0x73, 0x79, 0x6e, 0x74, 0x61, 0x78, 0x12, 0x32, 0x0a, 0x07, 0x65, 0x64, 0x69, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, - 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x07, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb9, 0x06, 0x0a, 0x0f, - 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x12, - 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, - 0x61, 0x6d, 0x65, 0x12, 0x3b, 0x0a, 0x05, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x18, 0x02, 0x20, 0x03, - 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, - 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x52, 0x05, 0x66, 0x69, 0x65, 0x6c, 0x64, - 0x12, 0x43, 0x0a, 0x09, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x06, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x44, 0x65, 0x73, 0x63, 0x72, - 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x52, 0x09, 0x65, 0x78, 0x74, 0x65, - 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x41, 0x0a, 0x0b, 0x6e, 0x65, 0x73, 0x74, 0x65, 0x64, 0x5f, - 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x65, 0x73, - 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x52, 0x0a, 0x6e, 0x65, - 0x73, 0x74, 0x65, 0x64, 0x54, 0x79, 0x70, 0x65, 0x12, 0x41, 0x0a, 0x09, 0x65, 0x6e, 0x75, 0x6d, - 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6e, - 0x75, 0x6d, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, - 0x6f, 0x52, 0x08, 0x65, 0x6e, 0x75, 0x6d, 0x54, 0x79, 0x70, 0x65, 0x12, 0x58, 0x0a, 0x0f, 0x65, - 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x05, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2f, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, - 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, - 0x52, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x0e, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, - 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x44, 0x0a, 0x0a, 0x6f, 0x6e, 0x65, 0x6f, 0x66, 0x5f, 0x64, - 0x65, 0x63, 0x6c, 0x18, 0x08, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x67, 0x6f, 0x6f, 0x67, - 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x4f, 0x6e, 0x65, 0x6f, - 0x66, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, - 0x52, 0x09, 0x6f, 0x6e, 0x65, 0x6f, 0x66, 0x44, 0x65, 0x63, 0x6c, 0x12, 0x39, 0x0a, 0x07, 0x6f, - 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x67, - 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x4d, - 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x07, 0x6f, - 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x55, 0x0a, 0x0e, 0x72, 0x65, 0x73, 0x65, 0x72, 0x76, - 0x65, 0x64, 0x5f, 0x72, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x09, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2e, - 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, - 0x2e, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, - 0x2e, 0x52, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x64, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x0d, - 0x72, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x64, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x23, 0x0a, - 0x0d, 0x72, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x64, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x0a, - 0x20, 0x03, 0x28, 0x09, 0x52, 0x0c, 0x72, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x64, 0x4e, 0x61, - 0x6d, 0x65, 0x1a, 0x7a, 0x0a, 0x0e, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x52, - 0x61, 0x6e, 0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x72, 0x74, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x61, 0x72, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x65, 0x6e, - 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x65, 0x6e, 0x64, 0x12, 0x40, 0x0a, 0x07, - 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, - 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, - 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x4f, 0x70, - 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x37, - 0x0a, 0x0d, 0x52, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x64, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, - 0x14, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x72, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, - 0x73, 0x74, 0x61, 0x72, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x65, 0x6e, 0x64, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x03, 0x65, 0x6e, 0x64, 0x22, 0xcc, 0x04, 0x0a, 0x15, 0x45, 0x78, 0x74, 0x65, - 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, - 0x73, 0x12, 0x58, 0x0a, 0x14, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, - 0x65, 0x64, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0xe7, 0x07, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2e, 0x55, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, - 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x13, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, - 0x72, 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x59, 0x0a, 0x0b, 0x64, - 0x65, 0x63, 0x6c, 0x61, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x32, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2e, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x61, 0x6e, 0x67, - 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x6c, 0x61, 0x72, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x03, 0x88, 0x01, 0x02, 0x52, 0x0b, 0x64, 0x65, 0x63, 0x6c, 0x61, - 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x37, 0x0a, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x73, 0x18, 0x32, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, - 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, 0x61, 0x74, 0x75, - 0x72, 0x65, 0x53, 0x65, 0x74, 0x52, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, - 0x6d, 0x0a, 0x0c, 0x76, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x38, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, - 0x6e, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x56, 0x65, - 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x3a, - 0x0a, 0x55, 0x4e, 0x56, 0x45, 0x52, 0x49, 0x46, 0x49, 0x45, 0x44, 0x42, 0x03, 0x88, 0x01, 0x02, - 0x52, 0x0c, 0x76, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x1a, 0x94, - 0x01, 0x0a, 0x0b, 0x44, 0x65, 0x63, 0x6c, 0x61, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x16, - 0x0a, 0x06, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, - 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1b, 0x0a, 0x09, 0x66, 0x75, 0x6c, 0x6c, 0x5f, 0x6e, - 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x75, 0x6c, 0x6c, 0x4e, - 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x65, 0x73, 0x65, 0x72, - 0x76, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x72, 0x65, 0x73, 0x65, 0x72, - 0x76, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x65, 0x70, 0x65, 0x61, 0x74, 0x65, 0x64, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x72, 0x65, 0x70, 0x65, 0x61, 0x74, 0x65, 0x64, 0x4a, - 0x04, 0x08, 0x04, 0x10, 0x05, 0x22, 0x34, 0x0a, 0x11, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x0f, 0x0a, 0x0b, 0x44, 0x45, - 0x43, 0x4c, 0x41, 0x52, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x10, 0x00, 0x12, 0x0e, 0x0a, 0x0a, 0x55, - 0x4e, 0x56, 0x45, 0x52, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x01, 0x2a, 0x09, 0x08, 0xe8, 0x07, - 0x10, 0x80, 0x80, 0x80, 0x80, 0x02, 0x22, 0xc1, 0x06, 0x0a, 0x14, 0x46, 0x69, 0x65, 0x6c, 0x64, - 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x12, - 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, - 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x06, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x41, 0x0a, 0x05, 0x6c, - 0x61, 0x62, 0x65, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2b, 0x2e, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, - 0x6c, 0x64, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, - 0x6f, 0x2e, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x52, 0x05, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x12, 0x3e, - 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2a, 0x2e, 0x67, - 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, - 0x69, 0x65, 0x6c, 0x64, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, - 0x6f, 0x74, 0x6f, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1b, - 0x0a, 0x09, 0x74, 0x79, 0x70, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x74, 0x79, 0x70, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x65, - 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x65, - 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x65, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x66, 0x61, 0x75, - 0x6c, 0x74, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, - 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x1f, 0x0a, 0x0b, - 0x6f, 0x6e, 0x65, 0x6f, 0x66, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x09, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x0a, 0x6f, 0x6e, 0x65, 0x6f, 0x66, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x1b, 0x0a, - 0x09, 0x6a, 0x73, 0x6f, 0x6e, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x6a, 0x73, 0x6f, 0x6e, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x37, 0x0a, 0x07, 0x6f, 0x70, - 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, - 0x65, 0x6c, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x07, 0x6f, 0x70, 0x74, 0x69, - 0x6f, 0x6e, 0x73, 0x12, 0x27, 0x0a, 0x0f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, 0x5f, 0x6f, 0x70, - 0x74, 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x18, 0x11, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x33, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x22, 0xb6, 0x02, 0x0a, - 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0f, 0x0a, 0x0b, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x44, 0x4f, - 0x55, 0x42, 0x4c, 0x45, 0x10, 0x01, 0x12, 0x0e, 0x0a, 0x0a, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x46, - 0x4c, 0x4f, 0x41, 0x54, 0x10, 0x02, 0x12, 0x0e, 0x0a, 0x0a, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x49, - 0x4e, 0x54, 0x36, 0x34, 0x10, 0x03, 0x12, 0x0f, 0x0a, 0x0b, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, - 0x49, 0x4e, 0x54, 0x36, 0x34, 0x10, 0x04, 0x12, 0x0e, 0x0a, 0x0a, 0x54, 0x59, 0x50, 0x45, 0x5f, - 0x49, 0x4e, 0x54, 0x33, 0x32, 0x10, 0x05, 0x12, 0x10, 0x0a, 0x0c, 0x54, 0x59, 0x50, 0x45, 0x5f, - 0x46, 0x49, 0x58, 0x45, 0x44, 0x36, 0x34, 0x10, 0x06, 0x12, 0x10, 0x0a, 0x0c, 0x54, 0x59, 0x50, - 0x45, 0x5f, 0x46, 0x49, 0x58, 0x45, 0x44, 0x33, 0x32, 0x10, 0x07, 0x12, 0x0d, 0x0a, 0x09, 0x54, - 0x59, 0x50, 0x45, 0x5f, 0x42, 0x4f, 0x4f, 0x4c, 0x10, 0x08, 0x12, 0x0f, 0x0a, 0x0b, 0x54, 0x59, - 0x50, 0x45, 0x5f, 0x53, 0x54, 0x52, 0x49, 0x4e, 0x47, 0x10, 0x09, 0x12, 0x0e, 0x0a, 0x0a, 0x54, - 0x59, 0x50, 0x45, 0x5f, 0x47, 0x52, 0x4f, 0x55, 0x50, 0x10, 0x0a, 0x12, 0x10, 0x0a, 0x0c, 0x54, - 0x59, 0x50, 0x45, 0x5f, 0x4d, 0x45, 0x53, 0x53, 0x41, 0x47, 0x45, 0x10, 0x0b, 0x12, 0x0e, 0x0a, - 0x0a, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x42, 0x59, 0x54, 0x45, 0x53, 0x10, 0x0c, 0x12, 0x0f, 0x0a, - 0x0b, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x49, 0x4e, 0x54, 0x33, 0x32, 0x10, 0x0d, 0x12, 0x0d, - 0x0a, 0x09, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x45, 0x4e, 0x55, 0x4d, 0x10, 0x0e, 0x12, 0x11, 0x0a, - 0x0d, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x53, 0x46, 0x49, 0x58, 0x45, 0x44, 0x33, 0x32, 0x10, 0x0f, - 0x12, 0x11, 0x0a, 0x0d, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x53, 0x46, 0x49, 0x58, 0x45, 0x44, 0x36, - 0x34, 0x10, 0x10, 0x12, 0x0f, 0x0a, 0x0b, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x53, 0x49, 0x4e, 0x54, - 0x33, 0x32, 0x10, 0x11, 0x12, 0x0f, 0x0a, 0x0b, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x53, 0x49, 0x4e, - 0x54, 0x36, 0x34, 0x10, 0x12, 0x22, 0x43, 0x0a, 0x05, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x12, 0x12, - 0x0a, 0x0e, 0x4c, 0x41, 0x42, 0x45, 0x4c, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x41, 0x4c, - 0x10, 0x01, 0x12, 0x12, 0x0a, 0x0e, 0x4c, 0x41, 0x42, 0x45, 0x4c, 0x5f, 0x52, 0x45, 0x50, 0x45, - 0x41, 0x54, 0x45, 0x44, 0x10, 0x03, 0x12, 0x12, 0x0a, 0x0e, 0x4c, 0x41, 0x42, 0x45, 0x4c, 0x5f, - 0x52, 0x45, 0x51, 0x55, 0x49, 0x52, 0x45, 0x44, 0x10, 0x02, 0x22, 0x63, 0x0a, 0x14, 0x4f, 0x6e, - 0x65, 0x6f, 0x66, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, - 0x74, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x37, 0x0a, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, - 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x4f, 0x6e, 0x65, 0x6f, 0x66, 0x4f, - 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x22, - 0xe3, 0x02, 0x0a, 0x13, 0x45, 0x6e, 0x75, 0x6d, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, - 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x3f, 0x0a, 0x05, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6e, 0x75, - 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, - 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x36, 0x0a, 0x07, - 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c, 0x2e, - 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, - 0x45, 0x6e, 0x75, 0x6d, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x07, 0x6f, 0x70, 0x74, - 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x5d, 0x0a, 0x0e, 0x72, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x64, - 0x5f, 0x72, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x36, 0x2e, 0x67, - 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, - 0x6e, 0x75, 0x6d, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, - 0x74, 0x6f, 0x2e, 0x45, 0x6e, 0x75, 0x6d, 0x52, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x64, 0x52, - 0x61, 0x6e, 0x67, 0x65, 0x52, 0x0d, 0x72, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x64, 0x52, 0x61, - 0x6e, 0x67, 0x65, 0x12, 0x23, 0x0a, 0x0d, 0x72, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x64, 0x5f, - 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0c, 0x72, 0x65, 0x73, 0x65, - 0x72, 0x76, 0x65, 0x64, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x3b, 0x0a, 0x11, 0x45, 0x6e, 0x75, 0x6d, - 0x52, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x64, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x14, 0x0a, - 0x05, 0x73, 0x74, 0x61, 0x72, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, - 0x61, 0x72, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x65, 0x6e, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, - 0x52, 0x03, 0x65, 0x6e, 0x64, 0x22, 0x83, 0x01, 0x0a, 0x18, 0x45, 0x6e, 0x75, 0x6d, 0x56, 0x61, - 0x6c, 0x75, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, - 0x74, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x3b, - 0x0a, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x21, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2e, 0x45, 0x6e, 0x75, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, - 0x6e, 0x73, 0x52, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x22, 0xa7, 0x01, 0x0a, 0x16, - 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, - 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x3e, 0x0a, 0x06, 0x6d, 0x65, - 0x74, 0x68, 0x6f, 0x64, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x4d, 0x65, 0x74, - 0x68, 0x6f, 0x64, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, - 0x74, 0x6f, 0x52, 0x06, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x12, 0x39, 0x0a, 0x07, 0x6f, 0x70, - 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x07, 0x6f, 0x70, - 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x22, 0x89, 0x02, 0x0a, 0x15, 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, - 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x12, - 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, - 0x61, 0x6d, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x5f, 0x74, 0x79, 0x70, - 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x54, 0x79, - 0x70, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x6f, 0x75, 0x74, 0x70, 0x75, 0x74, 0x5f, 0x74, 0x79, 0x70, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6f, 0x75, 0x74, 0x70, 0x75, 0x74, 0x54, - 0x79, 0x70, 0x65, 0x12, 0x38, 0x0a, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x4f, 0x70, 0x74, - 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x30, 0x0a, - 0x10, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x73, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x69, 0x6e, - 0x67, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x0f, - 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x69, 0x6e, 0x67, 0x12, - 0x30, 0x0a, 0x10, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x5f, 0x73, 0x74, 0x72, 0x65, 0x61, 0x6d, - 0x69, 0x6e, 0x67, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, - 0x52, 0x0f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x69, 0x6e, - 0x67, 0x22, 0xad, 0x09, 0x0a, 0x0b, 0x46, 0x69, 0x6c, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, - 0x73, 0x12, 0x21, 0x0a, 0x0c, 0x6a, 0x61, 0x76, 0x61, 0x5f, 0x70, 0x61, 0x63, 0x6b, 0x61, 0x67, - 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x6a, 0x61, 0x76, 0x61, 0x50, 0x61, 0x63, - 0x6b, 0x61, 0x67, 0x65, 0x12, 0x30, 0x0a, 0x14, 0x6a, 0x61, 0x76, 0x61, 0x5f, 0x6f, 0x75, 0x74, - 0x65, 0x72, 0x5f, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x08, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x12, 0x6a, 0x61, 0x76, 0x61, 0x4f, 0x75, 0x74, 0x65, 0x72, 0x43, 0x6c, 0x61, - 0x73, 0x73, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x35, 0x0a, 0x13, 0x6a, 0x61, 0x76, 0x61, 0x5f, 0x6d, - 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x65, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x11, 0x6a, 0x61, 0x76, 0x61, - 0x4d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x12, 0x44, 0x0a, - 0x1d, 0x6a, 0x61, 0x76, 0x61, 0x5f, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x5f, 0x65, - 0x71, 0x75, 0x61, 0x6c, 0x73, 0x5f, 0x61, 0x6e, 0x64, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x14, - 0x20, 0x01, 0x28, 0x08, 0x42, 0x02, 0x18, 0x01, 0x52, 0x19, 0x6a, 0x61, 0x76, 0x61, 0x47, 0x65, - 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x45, 0x71, 0x75, 0x61, 0x6c, 0x73, 0x41, 0x6e, 0x64, 0x48, - 0x61, 0x73, 0x68, 0x12, 0x3a, 0x0a, 0x16, 0x6a, 0x61, 0x76, 0x61, 0x5f, 0x73, 0x74, 0x72, 0x69, - 0x6e, 0x67, 0x5f, 0x63, 0x68, 0x65, 0x63, 0x6b, 0x5f, 0x75, 0x74, 0x66, 0x38, 0x18, 0x1b, 0x20, - 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x13, 0x6a, 0x61, 0x76, 0x61, - 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x55, 0x74, 0x66, 0x38, 0x12, - 0x53, 0x0a, 0x0c, 0x6f, 0x70, 0x74, 0x69, 0x6d, 0x69, 0x7a, 0x65, 0x5f, 0x66, 0x6f, 0x72, 0x18, - 0x09, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x29, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x4f, 0x70, 0x74, 0x69, - 0x6f, 0x6e, 0x73, 0x2e, 0x4f, 0x70, 0x74, 0x69, 0x6d, 0x69, 0x7a, 0x65, 0x4d, 0x6f, 0x64, 0x65, - 0x3a, 0x05, 0x53, 0x50, 0x45, 0x45, 0x44, 0x52, 0x0b, 0x6f, 0x70, 0x74, 0x69, 0x6d, 0x69, 0x7a, - 0x65, 0x46, 0x6f, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x67, 0x6f, 0x5f, 0x70, 0x61, 0x63, 0x6b, 0x61, - 0x67, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x67, 0x6f, 0x50, 0x61, 0x63, 0x6b, - 0x61, 0x67, 0x65, 0x12, 0x35, 0x0a, 0x13, 0x63, 0x63, 0x5f, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x69, - 0x63, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x18, 0x10, 0x20, 0x01, 0x28, 0x08, - 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x11, 0x63, 0x63, 0x47, 0x65, 0x6e, 0x65, 0x72, - 0x69, 0x63, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x12, 0x39, 0x0a, 0x15, 0x6a, 0x61, - 0x76, 0x61, 0x5f, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x69, 0x63, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x73, 0x18, 0x11, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, - 0x52, 0x13, 0x6a, 0x61, 0x76, 0x61, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x69, 0x63, 0x53, 0x65, 0x72, - 0x76, 0x69, 0x63, 0x65, 0x73, 0x12, 0x35, 0x0a, 0x13, 0x70, 0x79, 0x5f, 0x67, 0x65, 0x6e, 0x65, - 0x72, 0x69, 0x63, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x18, 0x12, 0x20, 0x01, - 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x11, 0x70, 0x79, 0x47, 0x65, 0x6e, - 0x65, 0x72, 0x69, 0x63, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x12, 0x25, 0x0a, 0x0a, - 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x18, 0x17, 0x20, 0x01, 0x28, 0x08, - 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x0a, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, - 0x74, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x10, 0x63, 0x63, 0x5f, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, - 0x5f, 0x61, 0x72, 0x65, 0x6e, 0x61, 0x73, 0x18, 0x1f, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x04, 0x74, - 0x72, 0x75, 0x65, 0x52, 0x0e, 0x63, 0x63, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x41, 0x72, 0x65, - 0x6e, 0x61, 0x73, 0x12, 0x2a, 0x0a, 0x11, 0x6f, 0x62, 0x6a, 0x63, 0x5f, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x5f, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x18, 0x24, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, - 0x6f, 0x62, 0x6a, 0x63, 0x43, 0x6c, 0x61, 0x73, 0x73, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x12, - 0x29, 0x0a, 0x10, 0x63, 0x73, 0x68, 0x61, 0x72, 0x70, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x73, 0x70, - 0x61, 0x63, 0x65, 0x18, 0x25, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x63, 0x73, 0x68, 0x61, 0x72, - 0x70, 0x4e, 0x61, 0x6d, 0x65, 0x73, 0x70, 0x61, 0x63, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x73, 0x77, - 0x69, 0x66, 0x74, 0x5f, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x18, 0x27, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x73, 0x77, 0x69, 0x66, 0x74, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x12, 0x28, 0x0a, - 0x10, 0x70, 0x68, 0x70, 0x5f, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x5f, 0x70, 0x72, 0x65, 0x66, 0x69, - 0x78, 0x18, 0x28, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x70, 0x68, 0x70, 0x43, 0x6c, 0x61, 0x73, - 0x73, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x12, 0x23, 0x0a, 0x0d, 0x70, 0x68, 0x70, 0x5f, 0x6e, - 0x61, 0x6d, 0x65, 0x73, 0x70, 0x61, 0x63, 0x65, 0x18, 0x29, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, - 0x70, 0x68, 0x70, 0x4e, 0x61, 0x6d, 0x65, 0x73, 0x70, 0x61, 0x63, 0x65, 0x12, 0x34, 0x0a, 0x16, - 0x70, 0x68, 0x70, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x6e, 0x61, 0x6d, - 0x65, 0x73, 0x70, 0x61, 0x63, 0x65, 0x18, 0x2c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x70, 0x68, - 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x4e, 0x61, 0x6d, 0x65, 0x73, 0x70, 0x61, - 0x63, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x72, 0x75, 0x62, 0x79, 0x5f, 0x70, 0x61, 0x63, 0x6b, 0x61, - 0x67, 0x65, 0x18, 0x2d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x72, 0x75, 0x62, 0x79, 0x50, 0x61, - 0x63, 0x6b, 0x61, 0x67, 0x65, 0x12, 0x37, 0x0a, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x73, 0x18, 0x32, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x53, 0x65, 0x74, 0x52, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0x58, - 0x0a, 0x14, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x5f, - 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0xe7, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, - 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, - 0x55, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x13, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, - 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x3a, 0x0a, 0x0c, 0x4f, 0x70, 0x74, 0x69, - 0x6d, 0x69, 0x7a, 0x65, 0x4d, 0x6f, 0x64, 0x65, 0x12, 0x09, 0x0a, 0x05, 0x53, 0x50, 0x45, 0x45, - 0x44, 0x10, 0x01, 0x12, 0x0d, 0x0a, 0x09, 0x43, 0x4f, 0x44, 0x45, 0x5f, 0x53, 0x49, 0x5a, 0x45, - 0x10, 0x02, 0x12, 0x10, 0x0a, 0x0c, 0x4c, 0x49, 0x54, 0x45, 0x5f, 0x52, 0x55, 0x4e, 0x54, 0x49, - 0x4d, 0x45, 0x10, 0x03, 0x2a, 0x09, 0x08, 0xe8, 0x07, 0x10, 0x80, 0x80, 0x80, 0x80, 0x02, 0x4a, - 0x04, 0x08, 0x2a, 0x10, 0x2b, 0x4a, 0x04, 0x08, 0x26, 0x10, 0x27, 0x52, 0x14, 0x70, 0x68, 0x70, - 0x5f, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x69, 0x63, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x73, 0x22, 0xf4, 0x03, 0x0a, 0x0e, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x4f, 0x70, 0x74, - 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x3c, 0x0a, 0x17, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, - 0x73, 0x65, 0x74, 0x5f, 0x77, 0x69, 0x72, 0x65, 0x5f, 0x66, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x14, 0x6d, 0x65, - 0x73, 0x73, 0x61, 0x67, 0x65, 0x53, 0x65, 0x74, 0x57, 0x69, 0x72, 0x65, 0x46, 0x6f, 0x72, 0x6d, - 0x61, 0x74, 0x12, 0x4c, 0x0a, 0x1f, 0x6e, 0x6f, 0x5f, 0x73, 0x74, 0x61, 0x6e, 0x64, 0x61, 0x72, - 0x64, 0x5f, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x5f, 0x61, 0x63, 0x63, - 0x65, 0x73, 0x73, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, - 0x73, 0x65, 0x52, 0x1c, 0x6e, 0x6f, 0x53, 0x74, 0x61, 0x6e, 0x64, 0x61, 0x72, 0x64, 0x44, 0x65, - 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x6f, 0x72, - 0x12, 0x25, 0x0a, 0x0a, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x0a, 0x64, 0x65, 0x70, - 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x12, 0x1b, 0x0a, 0x09, 0x6d, 0x61, 0x70, 0x5f, 0x65, - 0x6e, 0x74, 0x72, 0x79, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x6d, 0x61, 0x70, 0x45, - 0x6e, 0x74, 0x72, 0x79, 0x12, 0x56, 0x0a, 0x26, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, - 0x65, 0x64, 0x5f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5f, 0x6a, 0x73, 0x6f, 0x6e, 0x5f, 0x66, - 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x6c, 0x69, 0x63, 0x74, 0x73, 0x18, 0x0b, - 0x20, 0x01, 0x28, 0x08, 0x42, 0x02, 0x18, 0x01, 0x52, 0x22, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, - 0x61, 0x74, 0x65, 0x64, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x4a, 0x73, 0x6f, 0x6e, 0x46, 0x69, - 0x65, 0x6c, 0x64, 0x43, 0x6f, 0x6e, 0x66, 0x6c, 0x69, 0x63, 0x74, 0x73, 0x12, 0x37, 0x0a, 0x08, - 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, - 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, - 0x2e, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x52, 0x08, 0x66, 0x65, 0x61, - 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0x58, 0x0a, 0x14, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, - 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0xe7, 0x07, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x55, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, - 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x13, 0x75, 0x6e, 0x69, 0x6e, - 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x2a, - 0x09, 0x08, 0xe8, 0x07, 0x10, 0x80, 0x80, 0x80, 0x80, 0x02, 0x4a, 0x04, 0x08, 0x04, 0x10, 0x05, - 0x4a, 0x04, 0x08, 0x05, 0x10, 0x06, 0x4a, 0x04, 0x08, 0x06, 0x10, 0x07, 0x4a, 0x04, 0x08, 0x08, - 0x10, 0x09, 0x4a, 0x04, 0x08, 0x09, 0x10, 0x0a, 0x22, 0x9d, 0x0d, 0x0a, 0x0c, 0x46, 0x69, 0x65, - 0x6c, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x41, 0x0a, 0x05, 0x63, 0x74, 0x79, - 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x23, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, - 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, - 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x43, 0x54, 0x79, 0x70, 0x65, 0x3a, 0x06, 0x53, - 0x54, 0x52, 0x49, 0x4e, 0x47, 0x52, 0x05, 0x63, 0x74, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, - 0x70, 0x61, 0x63, 0x6b, 0x65, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x70, 0x61, - 0x63, 0x6b, 0x65, 0x64, 0x12, 0x47, 0x0a, 0x06, 0x6a, 0x73, 0x74, 0x79, 0x70, 0x65, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x0e, 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x4f, 0x70, 0x74, 0x69, - 0x6f, 0x6e, 0x73, 0x2e, 0x4a, 0x53, 0x54, 0x79, 0x70, 0x65, 0x3a, 0x09, 0x4a, 0x53, 0x5f, 0x4e, - 0x4f, 0x52, 0x4d, 0x41, 0x4c, 0x52, 0x06, 0x6a, 0x73, 0x74, 0x79, 0x70, 0x65, 0x12, 0x19, 0x0a, - 0x04, 0x6c, 0x61, 0x7a, 0x79, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, - 0x73, 0x65, 0x52, 0x04, 0x6c, 0x61, 0x7a, 0x79, 0x12, 0x2e, 0x0a, 0x0f, 0x75, 0x6e, 0x76, 0x65, - 0x72, 0x69, 0x66, 0x69, 0x65, 0x64, 0x5f, 0x6c, 0x61, 0x7a, 0x79, 0x18, 0x0f, 0x20, 0x01, 0x28, - 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x0e, 0x75, 0x6e, 0x76, 0x65, 0x72, 0x69, - 0x66, 0x69, 0x65, 0x64, 0x4c, 0x61, 0x7a, 0x79, 0x12, 0x25, 0x0a, 0x0a, 0x64, 0x65, 0x70, 0x72, - 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, - 0x6c, 0x73, 0x65, 0x52, 0x0a, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x12, - 0x19, 0x0a, 0x04, 0x77, 0x65, 0x61, 0x6b, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, - 0x61, 0x6c, 0x73, 0x65, 0x52, 0x04, 0x77, 0x65, 0x61, 0x6b, 0x12, 0x28, 0x0a, 0x0c, 0x64, 0x65, - 0x62, 0x75, 0x67, 0x5f, 0x72, 0x65, 0x64, 0x61, 0x63, 0x74, 0x18, 0x10, 0x20, 0x01, 0x28, 0x08, - 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x0b, 0x64, 0x65, 0x62, 0x75, 0x67, 0x52, 0x65, - 0x64, 0x61, 0x63, 0x74, 0x12, 0x4b, 0x0a, 0x09, 0x72, 0x65, 0x74, 0x65, 0x6e, 0x74, 0x69, 0x6f, - 0x6e, 0x18, 0x11, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x4f, - 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x74, - 0x65, 0x6e, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x09, 0x72, 0x65, 0x74, 0x65, 0x6e, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x48, 0x0a, 0x07, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x73, 0x18, 0x13, 0x20, 0x03, - 0x28, 0x0e, 0x32, 0x2e, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, - 0x73, 0x2e, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x61, 0x72, 0x67, 0x65, 0x74, 0x54, 0x79, - 0x70, 0x65, 0x52, 0x07, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x73, 0x12, 0x57, 0x0a, 0x10, 0x65, - 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x73, 0x18, - 0x14, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2c, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x4f, 0x70, 0x74, - 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x65, 0x66, 0x61, - 0x75, 0x6c, 0x74, 0x52, 0x0f, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x65, 0x66, 0x61, - 0x75, 0x6c, 0x74, 0x73, 0x12, 0x37, 0x0a, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, - 0x18, 0x15, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x53, 0x65, 0x74, 0x52, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0x55, 0x0a, - 0x0f, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, - 0x18, 0x16, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2c, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x4f, 0x70, - 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x75, 0x70, - 0x70, 0x6f, 0x72, 0x74, 0x52, 0x0e, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x75, 0x70, - 0x70, 0x6f, 0x72, 0x74, 0x12, 0x58, 0x0a, 0x14, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, - 0x72, 0x65, 0x74, 0x65, 0x64, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0xe7, 0x07, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x55, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, - 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x13, 0x75, 0x6e, 0x69, 0x6e, 0x74, - 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x1a, 0x5a, - 0x0a, 0x0e, 0x45, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, - 0x12, 0x32, 0x0a, 0x07, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x0e, 0x32, 0x18, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x62, 0x75, 0x66, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x07, 0x65, 0x64, 0x69, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x1a, 0x96, 0x02, 0x0a, 0x0e, 0x46, - 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x47, 0x0a, - 0x12, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x64, 0x75, - 0x63, 0x65, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x67, 0x6f, 0x6f, 0x67, - 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x64, 0x69, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x11, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x74, 0x72, - 0x6f, 0x64, 0x75, 0x63, 0x65, 0x64, 0x12, 0x47, 0x0a, 0x12, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, - 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x11, 0x65, 0x64, - 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x12, - 0x2f, 0x0a, 0x13, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x77, - 0x61, 0x72, 0x6e, 0x69, 0x6e, 0x67, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x12, 0x64, 0x65, - 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x57, 0x61, 0x72, 0x6e, 0x69, 0x6e, 0x67, - 0x12, 0x41, 0x0a, 0x0f, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x65, 0x6d, 0x6f, - 0x76, 0x65, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x67, 0x6f, 0x6f, 0x67, - 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x64, 0x69, 0x74, - 0x69, 0x6f, 0x6e, 0x52, 0x0e, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x6d, 0x6f, - 0x76, 0x65, 0x64, 0x22, 0x2f, 0x0a, 0x05, 0x43, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0a, 0x0a, 0x06, - 0x53, 0x54, 0x52, 0x49, 0x4e, 0x47, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, 0x43, 0x4f, 0x52, 0x44, - 0x10, 0x01, 0x12, 0x10, 0x0a, 0x0c, 0x53, 0x54, 0x52, 0x49, 0x4e, 0x47, 0x5f, 0x50, 0x49, 0x45, - 0x43, 0x45, 0x10, 0x02, 0x22, 0x35, 0x0a, 0x06, 0x4a, 0x53, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0d, - 0x0a, 0x09, 0x4a, 0x53, 0x5f, 0x4e, 0x4f, 0x52, 0x4d, 0x41, 0x4c, 0x10, 0x00, 0x12, 0x0d, 0x0a, - 0x09, 0x4a, 0x53, 0x5f, 0x53, 0x54, 0x52, 0x49, 0x4e, 0x47, 0x10, 0x01, 0x12, 0x0d, 0x0a, 0x09, - 0x4a, 0x53, 0x5f, 0x4e, 0x55, 0x4d, 0x42, 0x45, 0x52, 0x10, 0x02, 0x22, 0x55, 0x0a, 0x0f, 0x4f, - 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x74, 0x65, 0x6e, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x15, - 0x0a, 0x11, 0x52, 0x45, 0x54, 0x45, 0x4e, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x4e, 0x4b, 0x4e, - 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x15, 0x0a, 0x11, 0x52, 0x45, 0x54, 0x45, 0x4e, 0x54, 0x49, - 0x4f, 0x4e, 0x5f, 0x52, 0x55, 0x4e, 0x54, 0x49, 0x4d, 0x45, 0x10, 0x01, 0x12, 0x14, 0x0a, 0x10, - 0x52, 0x45, 0x54, 0x45, 0x4e, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x53, 0x4f, 0x55, 0x52, 0x43, 0x45, - 0x10, 0x02, 0x22, 0x8c, 0x02, 0x0a, 0x10, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x61, 0x72, - 0x67, 0x65, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x17, 0x0a, 0x13, 0x54, 0x41, 0x52, 0x47, 0x45, - 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, - 0x12, 0x14, 0x0a, 0x10, 0x54, 0x41, 0x52, 0x47, 0x45, 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, - 0x46, 0x49, 0x4c, 0x45, 0x10, 0x01, 0x12, 0x1f, 0x0a, 0x1b, 0x54, 0x41, 0x52, 0x47, 0x45, 0x54, - 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x45, 0x58, 0x54, 0x45, 0x4e, 0x53, 0x49, 0x4f, 0x4e, 0x5f, - 0x52, 0x41, 0x4e, 0x47, 0x45, 0x10, 0x02, 0x12, 0x17, 0x0a, 0x13, 0x54, 0x41, 0x52, 0x47, 0x45, - 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x4d, 0x45, 0x53, 0x53, 0x41, 0x47, 0x45, 0x10, 0x03, - 0x12, 0x15, 0x0a, 0x11, 0x54, 0x41, 0x52, 0x47, 0x45, 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, - 0x46, 0x49, 0x45, 0x4c, 0x44, 0x10, 0x04, 0x12, 0x15, 0x0a, 0x11, 0x54, 0x41, 0x52, 0x47, 0x45, - 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x4f, 0x4e, 0x45, 0x4f, 0x46, 0x10, 0x05, 0x12, 0x14, - 0x0a, 0x10, 0x54, 0x41, 0x52, 0x47, 0x45, 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x45, 0x4e, - 0x55, 0x4d, 0x10, 0x06, 0x12, 0x1a, 0x0a, 0x16, 0x54, 0x41, 0x52, 0x47, 0x45, 0x54, 0x5f, 0x54, - 0x59, 0x50, 0x45, 0x5f, 0x45, 0x4e, 0x55, 0x4d, 0x5f, 0x45, 0x4e, 0x54, 0x52, 0x59, 0x10, 0x07, - 0x12, 0x17, 0x0a, 0x13, 0x54, 0x41, 0x52, 0x47, 0x45, 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, - 0x53, 0x45, 0x52, 0x56, 0x49, 0x43, 0x45, 0x10, 0x08, 0x12, 0x16, 0x0a, 0x12, 0x54, 0x41, 0x52, - 0x47, 0x45, 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x4d, 0x45, 0x54, 0x48, 0x4f, 0x44, 0x10, - 0x09, 0x2a, 0x09, 0x08, 0xe8, 0x07, 0x10, 0x80, 0x80, 0x80, 0x80, 0x02, 0x4a, 0x04, 0x08, 0x04, - 0x10, 0x05, 0x4a, 0x04, 0x08, 0x12, 0x10, 0x13, 0x22, 0xac, 0x01, 0x0a, 0x0c, 0x4f, 0x6e, 0x65, - 0x6f, 0x66, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x37, 0x0a, 0x08, 0x66, 0x65, 0x61, - 0x74, 0x75, 0x72, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, - 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x52, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x73, 0x12, 0x58, 0x0a, 0x14, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, - 0x74, 0x65, 0x64, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0xe7, 0x07, 0x20, 0x03, 0x28, - 0x0b, 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x62, 0x75, 0x66, 0x2e, 0x55, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, - 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x13, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, - 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x2a, 0x09, 0x08, 0xe8, - 0x07, 0x10, 0x80, 0x80, 0x80, 0x80, 0x02, 0x22, 0xd1, 0x02, 0x0a, 0x0b, 0x45, 0x6e, 0x75, 0x6d, - 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x6c, 0x6c, 0x6f, 0x77, - 0x5f, 0x61, 0x6c, 0x69, 0x61, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x61, 0x6c, - 0x6c, 0x6f, 0x77, 0x41, 0x6c, 0x69, 0x61, 0x73, 0x12, 0x25, 0x0a, 0x0a, 0x64, 0x65, 0x70, 0x72, - 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, - 0x6c, 0x73, 0x65, 0x52, 0x0a, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x12, - 0x56, 0x0a, 0x26, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x6c, 0x65, - 0x67, 0x61, 0x63, 0x79, 0x5f, 0x6a, 0x73, 0x6f, 0x6e, 0x5f, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, - 0x63, 0x6f, 0x6e, 0x66, 0x6c, 0x69, 0x63, 0x74, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x42, - 0x02, 0x18, 0x01, 0x52, 0x22, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x4c, - 0x65, 0x67, 0x61, 0x63, 0x79, 0x4a, 0x73, 0x6f, 0x6e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x43, 0x6f, - 0x6e, 0x66, 0x6c, 0x69, 0x63, 0x74, 0x73, 0x12, 0x37, 0x0a, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, - 0x72, 0x65, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, 0x6f, 0x6f, 0x67, - 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, 0x61, 0x74, - 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x52, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, - 0x12, 0x58, 0x0a, 0x14, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, - 0x64, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0xe7, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2e, 0x55, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x4f, - 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x13, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, - 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x2a, 0x09, 0x08, 0xe8, 0x07, 0x10, - 0x80, 0x80, 0x80, 0x80, 0x02, 0x4a, 0x04, 0x08, 0x05, 0x10, 0x06, 0x22, 0xd8, 0x02, 0x0a, 0x10, - 0x45, 0x6e, 0x75, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, - 0x12, 0x25, 0x0a, 0x0a, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x0a, 0x64, 0x65, 0x70, - 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x12, 0x37, 0x0a, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, - 0x72, 0x65, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, 0x6f, 0x6f, 0x67, - 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, 0x61, 0x74, - 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x52, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, - 0x12, 0x28, 0x0a, 0x0c, 0x64, 0x65, 0x62, 0x75, 0x67, 0x5f, 0x72, 0x65, 0x64, 0x61, 0x63, 0x74, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x0b, 0x64, - 0x65, 0x62, 0x75, 0x67, 0x52, 0x65, 0x64, 0x61, 0x63, 0x74, 0x12, 0x55, 0x0a, 0x0f, 0x66, 0x65, - 0x61, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x2c, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, - 0x6e, 0x73, 0x2e, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x75, 0x70, 0x70, 0x6f, 0x72, - 0x74, 0x52, 0x0e, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x75, 0x70, 0x70, 0x6f, 0x72, - 0x74, 0x12, 0x58, 0x0a, 0x14, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, - 0x65, 0x64, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0xe7, 0x07, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2e, 0x55, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, - 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x13, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, - 0x72, 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x2a, 0x09, 0x08, 0xe8, 0x07, - 0x10, 0x80, 0x80, 0x80, 0x80, 0x02, 0x22, 0xd5, 0x01, 0x0a, 0x0e, 0x53, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x37, 0x0a, 0x08, 0x66, 0x65, 0x61, - 0x74, 0x75, 0x72, 0x65, 0x73, 0x18, 0x22, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, - 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x52, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x73, 0x12, 0x25, 0x0a, 0x0a, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, - 0x18, 0x21, 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x0a, 0x64, - 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x12, 0x58, 0x0a, 0x14, 0x75, 0x6e, 0x69, - 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6f, - 0x6e, 0x18, 0xe7, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, - 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x55, 0x6e, 0x69, 0x6e, 0x74, - 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x13, - 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, - 0x69, 0x6f, 0x6e, 0x2a, 0x09, 0x08, 0xe8, 0x07, 0x10, 0x80, 0x80, 0x80, 0x80, 0x02, 0x22, 0x99, - 0x03, 0x0a, 0x0d, 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, - 0x12, 0x25, 0x0a, 0x0a, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x18, 0x21, - 0x20, 0x01, 0x28, 0x08, 0x3a, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x0a, 0x64, 0x65, 0x70, - 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x12, 0x71, 0x0a, 0x11, 0x69, 0x64, 0x65, 0x6d, 0x70, - 0x6f, 0x74, 0x65, 0x6e, 0x63, 0x79, 0x5f, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x22, 0x20, 0x01, - 0x28, 0x0e, 0x32, 0x2f, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, - 0x6e, 0x73, 0x2e, 0x49, 0x64, 0x65, 0x6d, 0x70, 0x6f, 0x74, 0x65, 0x6e, 0x63, 0x79, 0x4c, 0x65, - 0x76, 0x65, 0x6c, 0x3a, 0x13, 0x49, 0x44, 0x45, 0x4d, 0x50, 0x4f, 0x54, 0x45, 0x4e, 0x43, 0x59, - 0x5f, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x52, 0x10, 0x69, 0x64, 0x65, 0x6d, 0x70, 0x6f, - 0x74, 0x65, 0x6e, 0x63, 0x79, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x37, 0x0a, 0x08, 0x66, 0x65, - 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x18, 0x23, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, - 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, - 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x52, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, - 0x72, 0x65, 0x73, 0x12, 0x58, 0x0a, 0x14, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, - 0x65, 0x74, 0x65, 0x64, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0xe7, 0x07, 0x20, 0x03, - 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x55, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, - 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x13, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, - 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x50, 0x0a, - 0x10, 0x49, 0x64, 0x65, 0x6d, 0x70, 0x6f, 0x74, 0x65, 0x6e, 0x63, 0x79, 0x4c, 0x65, 0x76, 0x65, - 0x6c, 0x12, 0x17, 0x0a, 0x13, 0x49, 0x44, 0x45, 0x4d, 0x50, 0x4f, 0x54, 0x45, 0x4e, 0x43, 0x59, - 0x5f, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x13, 0x0a, 0x0f, 0x4e, 0x4f, - 0x5f, 0x53, 0x49, 0x44, 0x45, 0x5f, 0x45, 0x46, 0x46, 0x45, 0x43, 0x54, 0x53, 0x10, 0x01, 0x12, - 0x0e, 0x0a, 0x0a, 0x49, 0x44, 0x45, 0x4d, 0x50, 0x4f, 0x54, 0x45, 0x4e, 0x54, 0x10, 0x02, 0x2a, - 0x09, 0x08, 0xe8, 0x07, 0x10, 0x80, 0x80, 0x80, 0x80, 0x02, 0x22, 0x9a, 0x03, 0x0a, 0x13, 0x55, - 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, 0x4f, 0x70, 0x74, 0x69, - 0x6f, 0x6e, 0x12, 0x41, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x2d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2e, 0x55, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x64, - 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4e, 0x61, 0x6d, 0x65, 0x50, 0x61, 0x72, 0x74, 0x52, - 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x29, 0x0a, 0x10, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, - 0x69, 0x65, 0x72, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0f, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, - 0x12, 0x2c, 0x0a, 0x12, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x69, 0x6e, 0x74, - 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x10, 0x70, 0x6f, - 0x73, 0x69, 0x74, 0x69, 0x76, 0x65, 0x49, 0x6e, 0x74, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x2c, - 0x0a, 0x12, 0x6e, 0x65, 0x67, 0x61, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x69, 0x6e, 0x74, 0x5f, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x6e, 0x65, 0x67, 0x61, - 0x74, 0x69, 0x76, 0x65, 0x49, 0x6e, 0x74, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x21, 0x0a, 0x0c, - 0x64, 0x6f, 0x75, 0x62, 0x6c, 0x65, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x01, 0x52, 0x0b, 0x64, 0x6f, 0x75, 0x62, 0x6c, 0x65, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, - 0x21, 0x0a, 0x0c, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, - 0x07, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0b, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x56, 0x61, 0x6c, - 0x75, 0x65, 0x12, 0x27, 0x0a, 0x0f, 0x61, 0x67, 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x65, 0x5f, - 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x61, 0x67, 0x67, - 0x72, 0x65, 0x67, 0x61, 0x74, 0x65, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x1a, 0x4a, 0x0a, 0x08, 0x4e, - 0x61, 0x6d, 0x65, 0x50, 0x61, 0x72, 0x74, 0x12, 0x1b, 0x0a, 0x09, 0x6e, 0x61, 0x6d, 0x65, 0x5f, - 0x70, 0x61, 0x72, 0x74, 0x18, 0x01, 0x20, 0x02, 0x28, 0x09, 0x52, 0x08, 0x6e, 0x61, 0x6d, 0x65, - 0x50, 0x61, 0x72, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x69, 0x73, 0x5f, 0x65, 0x78, 0x74, 0x65, 0x6e, - 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x02, 0x28, 0x08, 0x52, 0x0b, 0x69, 0x73, 0x45, 0x78, - 0x74, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x22, 0xa7, 0x0a, 0x0a, 0x0a, 0x46, 0x65, 0x61, 0x74, - 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x12, 0x91, 0x01, 0x0a, 0x0e, 0x66, 0x69, 0x65, 0x6c, 0x64, - 0x5f, 0x70, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, - 0x29, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2e, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x2e, 0x46, 0x69, 0x65, - 0x6c, 0x64, 0x50, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x63, 0x65, 0x42, 0x3f, 0x88, 0x01, 0x01, 0x98, - 0x01, 0x04, 0x98, 0x01, 0x01, 0xa2, 0x01, 0x0d, 0x12, 0x08, 0x45, 0x58, 0x50, 0x4c, 0x49, 0x43, - 0x49, 0x54, 0x18, 0x84, 0x07, 0xa2, 0x01, 0x0d, 0x12, 0x08, 0x49, 0x4d, 0x50, 0x4c, 0x49, 0x43, - 0x49, 0x54, 0x18, 0xe7, 0x07, 0xa2, 0x01, 0x0d, 0x12, 0x08, 0x45, 0x58, 0x50, 0x4c, 0x49, 0x43, - 0x49, 0x54, 0x18, 0xe8, 0x07, 0xb2, 0x01, 0x03, 0x08, 0xe8, 0x07, 0x52, 0x0d, 0x66, 0x69, 0x65, - 0x6c, 0x64, 0x50, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x63, 0x65, 0x12, 0x6c, 0x0a, 0x09, 0x65, 0x6e, - 0x75, 0x6d, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x24, 0x2e, - 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, - 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x2e, 0x45, 0x6e, 0x75, 0x6d, 0x54, - 0x79, 0x70, 0x65, 0x42, 0x29, 0x88, 0x01, 0x01, 0x98, 0x01, 0x06, 0x98, 0x01, 0x01, 0xa2, 0x01, - 0x0b, 0x12, 0x06, 0x43, 0x4c, 0x4f, 0x53, 0x45, 0x44, 0x18, 0x84, 0x07, 0xa2, 0x01, 0x09, 0x12, - 0x04, 0x4f, 0x50, 0x45, 0x4e, 0x18, 0xe7, 0x07, 0xb2, 0x01, 0x03, 0x08, 0xe8, 0x07, 0x52, 0x08, - 0x65, 0x6e, 0x75, 0x6d, 0x54, 0x79, 0x70, 0x65, 0x12, 0x98, 0x01, 0x0a, 0x17, 0x72, 0x65, 0x70, - 0x65, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x65, 0x6e, 0x63, 0x6f, - 0x64, 0x69, 0x6e, 0x67, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x31, 0x2e, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, 0x61, - 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x2e, 0x52, 0x65, 0x70, 0x65, 0x61, 0x74, 0x65, 0x64, - 0x46, 0x69, 0x65, 0x6c, 0x64, 0x45, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x42, 0x2d, 0x88, - 0x01, 0x01, 0x98, 0x01, 0x04, 0x98, 0x01, 0x01, 0xa2, 0x01, 0x0d, 0x12, 0x08, 0x45, 0x58, 0x50, - 0x41, 0x4e, 0x44, 0x45, 0x44, 0x18, 0x84, 0x07, 0xa2, 0x01, 0x0b, 0x12, 0x06, 0x50, 0x41, 0x43, - 0x4b, 0x45, 0x44, 0x18, 0xe7, 0x07, 0xb2, 0x01, 0x03, 0x08, 0xe8, 0x07, 0x52, 0x15, 0x72, 0x65, - 0x70, 0x65, 0x61, 0x74, 0x65, 0x64, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x45, 0x6e, 0x63, 0x6f, 0x64, - 0x69, 0x6e, 0x67, 0x12, 0x7e, 0x0a, 0x0f, 0x75, 0x74, 0x66, 0x38, 0x5f, 0x76, 0x61, 0x6c, 0x69, - 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2a, 0x2e, 0x67, - 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, - 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x2e, 0x55, 0x74, 0x66, 0x38, 0x56, 0x61, - 0x6c, 0x69, 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x29, 0x88, 0x01, 0x01, 0x98, 0x01, 0x04, - 0x98, 0x01, 0x01, 0xa2, 0x01, 0x09, 0x12, 0x04, 0x4e, 0x4f, 0x4e, 0x45, 0x18, 0x84, 0x07, 0xa2, - 0x01, 0x0b, 0x12, 0x06, 0x56, 0x45, 0x52, 0x49, 0x46, 0x59, 0x18, 0xe7, 0x07, 0xb2, 0x01, 0x03, - 0x08, 0xe8, 0x07, 0x52, 0x0e, 0x75, 0x74, 0x66, 0x38, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x12, 0x7e, 0x0a, 0x10, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x65, - 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2b, 0x2e, - 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, - 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x2e, 0x4d, 0x65, 0x73, 0x73, 0x61, - 0x67, 0x65, 0x45, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x42, 0x26, 0x88, 0x01, 0x01, 0x98, - 0x01, 0x04, 0x98, 0x01, 0x01, 0xa2, 0x01, 0x14, 0x12, 0x0f, 0x4c, 0x45, 0x4e, 0x47, 0x54, 0x48, - 0x5f, 0x50, 0x52, 0x45, 0x46, 0x49, 0x58, 0x45, 0x44, 0x18, 0x84, 0x07, 0xb2, 0x01, 0x03, 0x08, - 0xe8, 0x07, 0x52, 0x0f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x45, 0x6e, 0x63, 0x6f, 0x64, - 0x69, 0x6e, 0x67, 0x12, 0x82, 0x01, 0x0a, 0x0b, 0x6a, 0x73, 0x6f, 0x6e, 0x5f, 0x66, 0x6f, 0x72, - 0x6d, 0x61, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x26, 0x2e, 0x67, 0x6f, 0x6f, 0x67, - 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, 0x61, 0x74, - 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x2e, 0x4a, 0x73, 0x6f, 0x6e, 0x46, 0x6f, 0x72, 0x6d, 0x61, - 0x74, 0x42, 0x39, 0x88, 0x01, 0x01, 0x98, 0x01, 0x03, 0x98, 0x01, 0x06, 0x98, 0x01, 0x01, 0xa2, - 0x01, 0x17, 0x12, 0x12, 0x4c, 0x45, 0x47, 0x41, 0x43, 0x59, 0x5f, 0x42, 0x45, 0x53, 0x54, 0x5f, - 0x45, 0x46, 0x46, 0x4f, 0x52, 0x54, 0x18, 0x84, 0x07, 0xa2, 0x01, 0x0a, 0x12, 0x05, 0x41, 0x4c, - 0x4c, 0x4f, 0x57, 0x18, 0xe7, 0x07, 0xb2, 0x01, 0x03, 0x08, 0xe8, 0x07, 0x52, 0x0a, 0x6a, 0x73, - 0x6f, 0x6e, 0x46, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x22, 0x5c, 0x0a, 0x0d, 0x46, 0x69, 0x65, 0x6c, - 0x64, 0x50, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x63, 0x65, 0x12, 0x1a, 0x0a, 0x16, 0x46, 0x49, 0x45, - 0x4c, 0x44, 0x5f, 0x50, 0x52, 0x45, 0x53, 0x45, 0x4e, 0x43, 0x45, 0x5f, 0x55, 0x4e, 0x4b, 0x4e, - 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x45, 0x58, 0x50, 0x4c, 0x49, 0x43, 0x49, - 0x54, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x49, 0x4d, 0x50, 0x4c, 0x49, 0x43, 0x49, 0x54, 0x10, - 0x02, 0x12, 0x13, 0x0a, 0x0f, 0x4c, 0x45, 0x47, 0x41, 0x43, 0x59, 0x5f, 0x52, 0x45, 0x51, 0x55, - 0x49, 0x52, 0x45, 0x44, 0x10, 0x03, 0x22, 0x37, 0x0a, 0x08, 0x45, 0x6e, 0x75, 0x6d, 0x54, 0x79, - 0x70, 0x65, 0x12, 0x15, 0x0a, 0x11, 0x45, 0x4e, 0x55, 0x4d, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, - 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, 0x4f, 0x50, 0x45, - 0x4e, 0x10, 0x01, 0x12, 0x0a, 0x0a, 0x06, 0x43, 0x4c, 0x4f, 0x53, 0x45, 0x44, 0x10, 0x02, 0x22, - 0x56, 0x0a, 0x15, 0x52, 0x65, 0x70, 0x65, 0x61, 0x74, 0x65, 0x64, 0x46, 0x69, 0x65, 0x6c, 0x64, - 0x45, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x12, 0x23, 0x0a, 0x1f, 0x52, 0x45, 0x50, 0x45, - 0x41, 0x54, 0x45, 0x44, 0x5f, 0x46, 0x49, 0x45, 0x4c, 0x44, 0x5f, 0x45, 0x4e, 0x43, 0x4f, 0x44, - 0x49, 0x4e, 0x47, 0x5f, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x0a, 0x0a, - 0x06, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x44, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x45, 0x58, 0x50, - 0x41, 0x4e, 0x44, 0x45, 0x44, 0x10, 0x02, 0x22, 0x49, 0x0a, 0x0e, 0x55, 0x74, 0x66, 0x38, 0x56, - 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1b, 0x0a, 0x17, 0x55, 0x54, 0x46, - 0x38, 0x5f, 0x56, 0x41, 0x4c, 0x49, 0x44, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x4e, 0x4b, - 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x0a, 0x0a, 0x06, 0x56, 0x45, 0x52, 0x49, 0x46, 0x59, - 0x10, 0x02, 0x12, 0x08, 0x0a, 0x04, 0x4e, 0x4f, 0x4e, 0x45, 0x10, 0x03, 0x22, 0x04, 0x08, 0x01, - 0x10, 0x01, 0x22, 0x53, 0x0a, 0x0f, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x45, 0x6e, 0x63, - 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x12, 0x1c, 0x0a, 0x18, 0x4d, 0x45, 0x53, 0x53, 0x41, 0x47, 0x45, - 0x5f, 0x45, 0x4e, 0x43, 0x4f, 0x44, 0x49, 0x4e, 0x47, 0x5f, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, - 0x4e, 0x10, 0x00, 0x12, 0x13, 0x0a, 0x0f, 0x4c, 0x45, 0x4e, 0x47, 0x54, 0x48, 0x5f, 0x50, 0x52, - 0x45, 0x46, 0x49, 0x58, 0x45, 0x44, 0x10, 0x01, 0x12, 0x0d, 0x0a, 0x09, 0x44, 0x45, 0x4c, 0x49, - 0x4d, 0x49, 0x54, 0x45, 0x44, 0x10, 0x02, 0x22, 0x48, 0x0a, 0x0a, 0x4a, 0x73, 0x6f, 0x6e, 0x46, - 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x12, 0x17, 0x0a, 0x13, 0x4a, 0x53, 0x4f, 0x4e, 0x5f, 0x46, 0x4f, - 0x52, 0x4d, 0x41, 0x54, 0x5f, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x09, - 0x0a, 0x05, 0x41, 0x4c, 0x4c, 0x4f, 0x57, 0x10, 0x01, 0x12, 0x16, 0x0a, 0x12, 0x4c, 0x45, 0x47, - 0x41, 0x43, 0x59, 0x5f, 0x42, 0x45, 0x53, 0x54, 0x5f, 0x45, 0x46, 0x46, 0x4f, 0x52, 0x54, 0x10, - 0x02, 0x2a, 0x06, 0x08, 0xe8, 0x07, 0x10, 0x8b, 0x4e, 0x2a, 0x06, 0x08, 0x8b, 0x4e, 0x10, 0x90, - 0x4e, 0x2a, 0x06, 0x08, 0x90, 0x4e, 0x10, 0x91, 0x4e, 0x4a, 0x06, 0x08, 0xe7, 0x07, 0x10, 0xe8, - 0x07, 0x22, 0xef, 0x03, 0x0a, 0x12, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, - 0x44, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x73, 0x12, 0x58, 0x0a, 0x08, 0x64, 0x65, 0x66, 0x61, - 0x75, 0x6c, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x3c, 0x2e, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, 0x61, - 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x44, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x73, 0x2e, - 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x45, 0x64, 0x69, 0x74, 0x69, 0x6f, - 0x6e, 0x44, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x52, 0x08, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, - 0x74, 0x73, 0x12, 0x41, 0x0a, 0x0f, 0x6d, 0x69, 0x6e, 0x69, 0x6d, 0x75, 0x6d, 0x5f, 0x65, 0x64, - 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x64, - 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0e, 0x6d, 0x69, 0x6e, 0x69, 0x6d, 0x75, 0x6d, 0x45, 0x64, - 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x41, 0x0a, 0x0f, 0x6d, 0x61, 0x78, 0x69, 0x6d, 0x75, 0x6d, - 0x5f, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, - 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, - 0x2e, 0x45, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0e, 0x6d, 0x61, 0x78, 0x69, 0x6d, 0x75, - 0x6d, 0x45, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x1a, 0xf8, 0x01, 0x0a, 0x18, 0x46, 0x65, 0x61, - 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x45, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x65, - 0x66, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x32, 0x0a, 0x07, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, - 0x52, 0x07, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x4e, 0x0a, 0x14, 0x6f, 0x76, 0x65, - 0x72, 0x72, 0x69, 0x64, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x53, 0x65, 0x74, 0x52, 0x13, 0x6f, 0x76, 0x65, 0x72, 0x72, 0x69, 0x64, 0x61, 0x62, 0x6c, - 0x65, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0x42, 0x0a, 0x0e, 0x66, 0x69, 0x78, - 0x65, 0x64, 0x5f, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1b, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x62, 0x75, 0x66, 0x2e, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x52, 0x0d, - 0x66, 0x69, 0x78, 0x65, 0x64, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x4a, 0x04, 0x08, - 0x01, 0x10, 0x02, 0x4a, 0x04, 0x08, 0x02, 0x10, 0x03, 0x52, 0x08, 0x66, 0x65, 0x61, 0x74, 0x75, - 0x72, 0x65, 0x73, 0x22, 0xb5, 0x02, 0x0a, 0x0e, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x43, 0x6f, - 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x44, 0x0a, 0x08, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x28, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, - 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x6f, 0x75, 0x72, 0x63, - 0x65, 0x43, 0x6f, 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x4c, 0x6f, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x52, 0x08, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x1a, 0xce, 0x01, 0x0a, - 0x08, 0x4c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x16, 0x0a, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x01, 0x20, 0x03, 0x28, 0x05, 0x42, 0x02, 0x10, 0x01, 0x52, 0x04, 0x70, 0x61, 0x74, - 0x68, 0x12, 0x16, 0x0a, 0x04, 0x73, 0x70, 0x61, 0x6e, 0x18, 0x02, 0x20, 0x03, 0x28, 0x05, 0x42, - 0x02, 0x10, 0x01, 0x52, 0x04, 0x73, 0x70, 0x61, 0x6e, 0x12, 0x29, 0x0a, 0x10, 0x6c, 0x65, 0x61, - 0x64, 0x69, 0x6e, 0x67, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0f, 0x6c, 0x65, 0x61, 0x64, 0x69, 0x6e, 0x67, 0x43, 0x6f, 0x6d, 0x6d, - 0x65, 0x6e, 0x74, 0x73, 0x12, 0x2b, 0x0a, 0x11, 0x74, 0x72, 0x61, 0x69, 0x6c, 0x69, 0x6e, 0x67, - 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x10, 0x74, 0x72, 0x61, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x43, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, - 0x73, 0x12, 0x3a, 0x0a, 0x19, 0x6c, 0x65, 0x61, 0x64, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, - 0x61, 0x63, 0x68, 0x65, 0x64, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x06, - 0x20, 0x03, 0x28, 0x09, 0x52, 0x17, 0x6c, 0x65, 0x61, 0x64, 0x69, 0x6e, 0x67, 0x44, 0x65, 0x74, - 0x61, 0x63, 0x68, 0x65, 0x64, 0x43, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2a, 0x0c, 0x08, - 0x80, 0xec, 0xca, 0xff, 0x01, 0x10, 0x81, 0xec, 0xca, 0xff, 0x01, 0x22, 0xd0, 0x02, 0x0a, 0x11, - 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x64, 0x43, 0x6f, 0x64, 0x65, 0x49, 0x6e, 0x66, - 0x6f, 0x12, 0x4d, 0x0a, 0x0a, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, - 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, - 0x64, 0x43, 0x6f, 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x41, 0x6e, 0x6e, 0x6f, 0x74, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x1a, 0xeb, 0x01, 0x0a, 0x0a, 0x41, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, - 0x16, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x03, 0x28, 0x05, 0x42, 0x02, 0x10, - 0x01, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1f, 0x0a, 0x0b, 0x73, 0x6f, 0x75, 0x72, 0x63, - 0x65, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, 0x6f, - 0x75, 0x72, 0x63, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x62, 0x65, 0x67, 0x69, - 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x62, 0x65, 0x67, 0x69, 0x6e, 0x12, 0x10, - 0x0a, 0x03, 0x65, 0x6e, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x65, 0x6e, 0x64, - 0x12, 0x52, 0x0a, 0x08, 0x73, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x18, 0x05, 0x20, 0x01, - 0x28, 0x0e, 0x32, 0x36, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x64, 0x43, 0x6f, - 0x64, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x41, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x2e, 0x53, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x52, 0x08, 0x73, 0x65, 0x6d, 0x61, - 0x6e, 0x74, 0x69, 0x63, 0x22, 0x28, 0x0a, 0x08, 0x53, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, - 0x12, 0x08, 0x0a, 0x04, 0x4e, 0x4f, 0x4e, 0x45, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x53, 0x45, - 0x54, 0x10, 0x01, 0x12, 0x09, 0x0a, 0x05, 0x41, 0x4c, 0x49, 0x41, 0x53, 0x10, 0x02, 0x2a, 0xa7, - 0x02, 0x0a, 0x07, 0x45, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x13, 0x0a, 0x0f, 0x45, 0x44, - 0x49, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, - 0x13, 0x0a, 0x0e, 0x45, 0x44, 0x49, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x4c, 0x45, 0x47, 0x41, 0x43, - 0x59, 0x10, 0x84, 0x07, 0x12, 0x13, 0x0a, 0x0e, 0x45, 0x44, 0x49, 0x54, 0x49, 0x4f, 0x4e, 0x5f, - 0x50, 0x52, 0x4f, 0x54, 0x4f, 0x32, 0x10, 0xe6, 0x07, 0x12, 0x13, 0x0a, 0x0e, 0x45, 0x44, 0x49, - 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x50, 0x52, 0x4f, 0x54, 0x4f, 0x33, 0x10, 0xe7, 0x07, 0x12, 0x11, - 0x0a, 0x0c, 0x45, 0x44, 0x49, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x32, 0x30, 0x32, 0x33, 0x10, 0xe8, - 0x07, 0x12, 0x11, 0x0a, 0x0c, 0x45, 0x44, 0x49, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x32, 0x30, 0x32, - 0x34, 0x10, 0xe9, 0x07, 0x12, 0x17, 0x0a, 0x13, 0x45, 0x44, 0x49, 0x54, 0x49, 0x4f, 0x4e, 0x5f, - 0x31, 0x5f, 0x54, 0x45, 0x53, 0x54, 0x5f, 0x4f, 0x4e, 0x4c, 0x59, 0x10, 0x01, 0x12, 0x17, 0x0a, - 0x13, 0x45, 0x44, 0x49, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x32, 0x5f, 0x54, 0x45, 0x53, 0x54, 0x5f, - 0x4f, 0x4e, 0x4c, 0x59, 0x10, 0x02, 0x12, 0x1d, 0x0a, 0x17, 0x45, 0x44, 0x49, 0x54, 0x49, 0x4f, - 0x4e, 0x5f, 0x39, 0x39, 0x39, 0x39, 0x37, 0x5f, 0x54, 0x45, 0x53, 0x54, 0x5f, 0x4f, 0x4e, 0x4c, - 0x59, 0x10, 0x9d, 0x8d, 0x06, 0x12, 0x1d, 0x0a, 0x17, 0x45, 0x44, 0x49, 0x54, 0x49, 0x4f, 0x4e, - 0x5f, 0x39, 0x39, 0x39, 0x39, 0x38, 0x5f, 0x54, 0x45, 0x53, 0x54, 0x5f, 0x4f, 0x4e, 0x4c, 0x59, - 0x10, 0x9e, 0x8d, 0x06, 0x12, 0x1d, 0x0a, 0x17, 0x45, 0x44, 0x49, 0x54, 0x49, 0x4f, 0x4e, 0x5f, - 0x39, 0x39, 0x39, 0x39, 0x39, 0x5f, 0x54, 0x45, 0x53, 0x54, 0x5f, 0x4f, 0x4e, 0x4c, 0x59, 0x10, - 0x9f, 0x8d, 0x06, 0x12, 0x13, 0x0a, 0x0b, 0x45, 0x44, 0x49, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x4d, - 0x41, 0x58, 0x10, 0xff, 0xff, 0xff, 0xff, 0x07, 0x42, 0x7e, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, - 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x42, - 0x10, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, - 0x73, 0x48, 0x01, 0x5a, 0x2d, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, - 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, - 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, - 0x70, 0x62, 0xf8, 0x01, 0x01, 0xa2, 0x02, 0x03, 0x47, 0x50, 0x42, 0xaa, 0x02, 0x1a, 0x47, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x52, 0x65, - 0x66, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, -}) +const file_google_protobuf_descriptor_proto_rawDesc = "" + + "\n" + + " google/protobuf/descriptor.proto\x12\x0fgoogle.protobuf\"[\n" + + "\x11FileDescriptorSet\x128\n" + + "\x04file\x18\x01 \x03(\v2$.google.protobuf.FileDescriptorProtoR\x04file*\f\b\x80\xec\xca\xff\x01\x10\x81\xec\xca\xff\x01\"\x98\x05\n" + + "\x13FileDescriptorProto\x12\x12\n" + + "\x04name\x18\x01 \x01(\tR\x04name\x12\x18\n" + + "\apackage\x18\x02 \x01(\tR\apackage\x12\x1e\n" + + "\n" + + "dependency\x18\x03 \x03(\tR\n" + + "dependency\x12+\n" + + "\x11public_dependency\x18\n" + + " \x03(\x05R\x10publicDependency\x12'\n" + + "\x0fweak_dependency\x18\v \x03(\x05R\x0eweakDependency\x12C\n" + + "\fmessage_type\x18\x04 \x03(\v2 .google.protobuf.DescriptorProtoR\vmessageType\x12A\n" + + "\tenum_type\x18\x05 \x03(\v2$.google.protobuf.EnumDescriptorProtoR\benumType\x12A\n" + + "\aservice\x18\x06 \x03(\v2'.google.protobuf.ServiceDescriptorProtoR\aservice\x12C\n" + + "\textension\x18\a \x03(\v2%.google.protobuf.FieldDescriptorProtoR\textension\x126\n" + + "\aoptions\x18\b \x01(\v2\x1c.google.protobuf.FileOptionsR\aoptions\x12I\n" + + "\x10source_code_info\x18\t \x01(\v2\x1f.google.protobuf.SourceCodeInfoR\x0esourceCodeInfo\x12\x16\n" + + "\x06syntax\x18\f \x01(\tR\x06syntax\x122\n" + + "\aedition\x18\x0e \x01(\x0e2\x18.google.protobuf.EditionR\aedition\"\xb9\x06\n" + + "\x0fDescriptorProto\x12\x12\n" + + "\x04name\x18\x01 \x01(\tR\x04name\x12;\n" + + "\x05field\x18\x02 \x03(\v2%.google.protobuf.FieldDescriptorProtoR\x05field\x12C\n" + + "\textension\x18\x06 \x03(\v2%.google.protobuf.FieldDescriptorProtoR\textension\x12A\n" + + "\vnested_type\x18\x03 \x03(\v2 .google.protobuf.DescriptorProtoR\n" + + "nestedType\x12A\n" + + "\tenum_type\x18\x04 \x03(\v2$.google.protobuf.EnumDescriptorProtoR\benumType\x12X\n" + + "\x0fextension_range\x18\x05 \x03(\v2/.google.protobuf.DescriptorProto.ExtensionRangeR\x0eextensionRange\x12D\n" + + "\n" + + "oneof_decl\x18\b \x03(\v2%.google.protobuf.OneofDescriptorProtoR\toneofDecl\x129\n" + + "\aoptions\x18\a \x01(\v2\x1f.google.protobuf.MessageOptionsR\aoptions\x12U\n" + + "\x0ereserved_range\x18\t \x03(\v2..google.protobuf.DescriptorProto.ReservedRangeR\rreservedRange\x12#\n" + + "\rreserved_name\x18\n" + + " \x03(\tR\freservedName\x1az\n" + + "\x0eExtensionRange\x12\x14\n" + + "\x05start\x18\x01 \x01(\x05R\x05start\x12\x10\n" + + "\x03end\x18\x02 \x01(\x05R\x03end\x12@\n" + + "\aoptions\x18\x03 \x01(\v2&.google.protobuf.ExtensionRangeOptionsR\aoptions\x1a7\n" + + "\rReservedRange\x12\x14\n" + + "\x05start\x18\x01 \x01(\x05R\x05start\x12\x10\n" + + "\x03end\x18\x02 \x01(\x05R\x03end\"\xcc\x04\n" + + "\x15ExtensionRangeOptions\x12X\n" + + "\x14uninterpreted_option\x18\xe7\a \x03(\v2$.google.protobuf.UninterpretedOptionR\x13uninterpretedOption\x12Y\n" + + "\vdeclaration\x18\x02 \x03(\v22.google.protobuf.ExtensionRangeOptions.DeclarationB\x03\x88\x01\x02R\vdeclaration\x127\n" + + "\bfeatures\x182 \x01(\v2\x1b.google.protobuf.FeatureSetR\bfeatures\x12m\n" + + "\fverification\x18\x03 \x01(\x0e28.google.protobuf.ExtensionRangeOptions.VerificationState:\n" + + "UNVERIFIEDB\x03\x88\x01\x02R\fverification\x1a\x94\x01\n" + + "\vDeclaration\x12\x16\n" + + "\x06number\x18\x01 \x01(\x05R\x06number\x12\x1b\n" + + "\tfull_name\x18\x02 \x01(\tR\bfullName\x12\x12\n" + + "\x04type\x18\x03 \x01(\tR\x04type\x12\x1a\n" + + "\breserved\x18\x05 \x01(\bR\breserved\x12\x1a\n" + + "\brepeated\x18\x06 \x01(\bR\brepeatedJ\x04\b\x04\x10\x05\"4\n" + + "\x11VerificationState\x12\x0f\n" + + "\vDECLARATION\x10\x00\x12\x0e\n" + + "\n" + + "UNVERIFIED\x10\x01*\t\b\xe8\a\x10\x80\x80\x80\x80\x02\"\xc1\x06\n" + + "\x14FieldDescriptorProto\x12\x12\n" + + "\x04name\x18\x01 \x01(\tR\x04name\x12\x16\n" + + "\x06number\x18\x03 \x01(\x05R\x06number\x12A\n" + + "\x05label\x18\x04 \x01(\x0e2+.google.protobuf.FieldDescriptorProto.LabelR\x05label\x12>\n" + + "\x04type\x18\x05 \x01(\x0e2*.google.protobuf.FieldDescriptorProto.TypeR\x04type\x12\x1b\n" + + "\ttype_name\x18\x06 \x01(\tR\btypeName\x12\x1a\n" + + "\bextendee\x18\x02 \x01(\tR\bextendee\x12#\n" + + "\rdefault_value\x18\a \x01(\tR\fdefaultValue\x12\x1f\n" + + "\voneof_index\x18\t \x01(\x05R\n" + + "oneofIndex\x12\x1b\n" + + "\tjson_name\x18\n" + + " \x01(\tR\bjsonName\x127\n" + + "\aoptions\x18\b \x01(\v2\x1d.google.protobuf.FieldOptionsR\aoptions\x12'\n" + + "\x0fproto3_optional\x18\x11 \x01(\bR\x0eproto3Optional\"\xb6\x02\n" + + "\x04Type\x12\x0f\n" + + "\vTYPE_DOUBLE\x10\x01\x12\x0e\n" + + "\n" + + "TYPE_FLOAT\x10\x02\x12\x0e\n" + + "\n" + + "TYPE_INT64\x10\x03\x12\x0f\n" + + "\vTYPE_UINT64\x10\x04\x12\x0e\n" + + "\n" + + "TYPE_INT32\x10\x05\x12\x10\n" + + "\fTYPE_FIXED64\x10\x06\x12\x10\n" + + "\fTYPE_FIXED32\x10\a\x12\r\n" + + "\tTYPE_BOOL\x10\b\x12\x0f\n" + + "\vTYPE_STRING\x10\t\x12\x0e\n" + + "\n" + + "TYPE_GROUP\x10\n" + + "\x12\x10\n" + + "\fTYPE_MESSAGE\x10\v\x12\x0e\n" + + "\n" + + "TYPE_BYTES\x10\f\x12\x0f\n" + + "\vTYPE_UINT32\x10\r\x12\r\n" + + "\tTYPE_ENUM\x10\x0e\x12\x11\n" + + "\rTYPE_SFIXED32\x10\x0f\x12\x11\n" + + "\rTYPE_SFIXED64\x10\x10\x12\x0f\n" + + "\vTYPE_SINT32\x10\x11\x12\x0f\n" + + "\vTYPE_SINT64\x10\x12\"C\n" + + "\x05Label\x12\x12\n" + + "\x0eLABEL_OPTIONAL\x10\x01\x12\x12\n" + + "\x0eLABEL_REPEATED\x10\x03\x12\x12\n" + + "\x0eLABEL_REQUIRED\x10\x02\"c\n" + + "\x14OneofDescriptorProto\x12\x12\n" + + "\x04name\x18\x01 \x01(\tR\x04name\x127\n" + + "\aoptions\x18\x02 \x01(\v2\x1d.google.protobuf.OneofOptionsR\aoptions\"\xe3\x02\n" + + "\x13EnumDescriptorProto\x12\x12\n" + + "\x04name\x18\x01 \x01(\tR\x04name\x12?\n" + + "\x05value\x18\x02 \x03(\v2).google.protobuf.EnumValueDescriptorProtoR\x05value\x126\n" + + "\aoptions\x18\x03 \x01(\v2\x1c.google.protobuf.EnumOptionsR\aoptions\x12]\n" + + "\x0ereserved_range\x18\x04 \x03(\v26.google.protobuf.EnumDescriptorProto.EnumReservedRangeR\rreservedRange\x12#\n" + + "\rreserved_name\x18\x05 \x03(\tR\freservedName\x1a;\n" + + "\x11EnumReservedRange\x12\x14\n" + + "\x05start\x18\x01 \x01(\x05R\x05start\x12\x10\n" + + "\x03end\x18\x02 \x01(\x05R\x03end\"\x83\x01\n" + + "\x18EnumValueDescriptorProto\x12\x12\n" + + "\x04name\x18\x01 \x01(\tR\x04name\x12\x16\n" + + "\x06number\x18\x02 \x01(\x05R\x06number\x12;\n" + + "\aoptions\x18\x03 \x01(\v2!.google.protobuf.EnumValueOptionsR\aoptions\"\xa7\x01\n" + + "\x16ServiceDescriptorProto\x12\x12\n" + + "\x04name\x18\x01 \x01(\tR\x04name\x12>\n" + + "\x06method\x18\x02 \x03(\v2&.google.protobuf.MethodDescriptorProtoR\x06method\x129\n" + + "\aoptions\x18\x03 \x01(\v2\x1f.google.protobuf.ServiceOptionsR\aoptions\"\x89\x02\n" + + "\x15MethodDescriptorProto\x12\x12\n" + + "\x04name\x18\x01 \x01(\tR\x04name\x12\x1d\n" + + "\n" + + "input_type\x18\x02 \x01(\tR\tinputType\x12\x1f\n" + + "\voutput_type\x18\x03 \x01(\tR\n" + + "outputType\x128\n" + + "\aoptions\x18\x04 \x01(\v2\x1e.google.protobuf.MethodOptionsR\aoptions\x120\n" + + "\x10client_streaming\x18\x05 \x01(\b:\x05falseR\x0fclientStreaming\x120\n" + + "\x10server_streaming\x18\x06 \x01(\b:\x05falseR\x0fserverStreaming\"\xad\t\n" + + "\vFileOptions\x12!\n" + + "\fjava_package\x18\x01 \x01(\tR\vjavaPackage\x120\n" + + "\x14java_outer_classname\x18\b \x01(\tR\x12javaOuterClassname\x125\n" + + "\x13java_multiple_files\x18\n" + + " \x01(\b:\x05falseR\x11javaMultipleFiles\x12D\n" + + "\x1djava_generate_equals_and_hash\x18\x14 \x01(\bB\x02\x18\x01R\x19javaGenerateEqualsAndHash\x12:\n" + + "\x16java_string_check_utf8\x18\x1b \x01(\b:\x05falseR\x13javaStringCheckUtf8\x12S\n" + + "\foptimize_for\x18\t \x01(\x0e2).google.protobuf.FileOptions.OptimizeMode:\x05SPEEDR\voptimizeFor\x12\x1d\n" + + "\n" + + "go_package\x18\v \x01(\tR\tgoPackage\x125\n" + + "\x13cc_generic_services\x18\x10 \x01(\b:\x05falseR\x11ccGenericServices\x129\n" + + "\x15java_generic_services\x18\x11 \x01(\b:\x05falseR\x13javaGenericServices\x125\n" + + "\x13py_generic_services\x18\x12 \x01(\b:\x05falseR\x11pyGenericServices\x12%\n" + + "\n" + + "deprecated\x18\x17 \x01(\b:\x05falseR\n" + + "deprecated\x12.\n" + + "\x10cc_enable_arenas\x18\x1f \x01(\b:\x04trueR\x0eccEnableArenas\x12*\n" + + "\x11objc_class_prefix\x18$ \x01(\tR\x0fobjcClassPrefix\x12)\n" + + "\x10csharp_namespace\x18% \x01(\tR\x0fcsharpNamespace\x12!\n" + + "\fswift_prefix\x18' \x01(\tR\vswiftPrefix\x12(\n" + + "\x10php_class_prefix\x18( \x01(\tR\x0ephpClassPrefix\x12#\n" + + "\rphp_namespace\x18) \x01(\tR\fphpNamespace\x124\n" + + "\x16php_metadata_namespace\x18, \x01(\tR\x14phpMetadataNamespace\x12!\n" + + "\fruby_package\x18- \x01(\tR\vrubyPackage\x127\n" + + "\bfeatures\x182 \x01(\v2\x1b.google.protobuf.FeatureSetR\bfeatures\x12X\n" + + "\x14uninterpreted_option\x18\xe7\a \x03(\v2$.google.protobuf.UninterpretedOptionR\x13uninterpretedOption\":\n" + + "\fOptimizeMode\x12\t\n" + + "\x05SPEED\x10\x01\x12\r\n" + + "\tCODE_SIZE\x10\x02\x12\x10\n" + + "\fLITE_RUNTIME\x10\x03*\t\b\xe8\a\x10\x80\x80\x80\x80\x02J\x04\b*\x10+J\x04\b&\x10'R\x14php_generic_services\"\xf4\x03\n" + + "\x0eMessageOptions\x12<\n" + + "\x17message_set_wire_format\x18\x01 \x01(\b:\x05falseR\x14messageSetWireFormat\x12L\n" + + "\x1fno_standard_descriptor_accessor\x18\x02 \x01(\b:\x05falseR\x1cnoStandardDescriptorAccessor\x12%\n" + + "\n" + + "deprecated\x18\x03 \x01(\b:\x05falseR\n" + + "deprecated\x12\x1b\n" + + "\tmap_entry\x18\a \x01(\bR\bmapEntry\x12V\n" + + "&deprecated_legacy_json_field_conflicts\x18\v \x01(\bB\x02\x18\x01R\"deprecatedLegacyJsonFieldConflicts\x127\n" + + "\bfeatures\x18\f \x01(\v2\x1b.google.protobuf.FeatureSetR\bfeatures\x12X\n" + + "\x14uninterpreted_option\x18\xe7\a \x03(\v2$.google.protobuf.UninterpretedOptionR\x13uninterpretedOption*\t\b\xe8\a\x10\x80\x80\x80\x80\x02J\x04\b\x04\x10\x05J\x04\b\x05\x10\x06J\x04\b\x06\x10\aJ\x04\b\b\x10\tJ\x04\b\t\x10\n" + + "\"\x9d\r\n" + + "\fFieldOptions\x12A\n" + + "\x05ctype\x18\x01 \x01(\x0e2#.google.protobuf.FieldOptions.CType:\x06STRINGR\x05ctype\x12\x16\n" + + "\x06packed\x18\x02 \x01(\bR\x06packed\x12G\n" + + "\x06jstype\x18\x06 \x01(\x0e2$.google.protobuf.FieldOptions.JSType:\tJS_NORMALR\x06jstype\x12\x19\n" + + "\x04lazy\x18\x05 \x01(\b:\x05falseR\x04lazy\x12.\n" + + "\x0funverified_lazy\x18\x0f \x01(\b:\x05falseR\x0eunverifiedLazy\x12%\n" + + "\n" + + "deprecated\x18\x03 \x01(\b:\x05falseR\n" + + "deprecated\x12\x19\n" + + "\x04weak\x18\n" + + " \x01(\b:\x05falseR\x04weak\x12(\n" + + "\fdebug_redact\x18\x10 \x01(\b:\x05falseR\vdebugRedact\x12K\n" + + "\tretention\x18\x11 \x01(\x0e2-.google.protobuf.FieldOptions.OptionRetentionR\tretention\x12H\n" + + "\atargets\x18\x13 \x03(\x0e2..google.protobuf.FieldOptions.OptionTargetTypeR\atargets\x12W\n" + + "\x10edition_defaults\x18\x14 \x03(\v2,.google.protobuf.FieldOptions.EditionDefaultR\x0feditionDefaults\x127\n" + + "\bfeatures\x18\x15 \x01(\v2\x1b.google.protobuf.FeatureSetR\bfeatures\x12U\n" + + "\x0ffeature_support\x18\x16 \x01(\v2,.google.protobuf.FieldOptions.FeatureSupportR\x0efeatureSupport\x12X\n" + + "\x14uninterpreted_option\x18\xe7\a \x03(\v2$.google.protobuf.UninterpretedOptionR\x13uninterpretedOption\x1aZ\n" + + "\x0eEditionDefault\x122\n" + + "\aedition\x18\x03 \x01(\x0e2\x18.google.protobuf.EditionR\aedition\x12\x14\n" + + "\x05value\x18\x02 \x01(\tR\x05value\x1a\x96\x02\n" + + "\x0eFeatureSupport\x12G\n" + + "\x12edition_introduced\x18\x01 \x01(\x0e2\x18.google.protobuf.EditionR\x11editionIntroduced\x12G\n" + + "\x12edition_deprecated\x18\x02 \x01(\x0e2\x18.google.protobuf.EditionR\x11editionDeprecated\x12/\n" + + "\x13deprecation_warning\x18\x03 \x01(\tR\x12deprecationWarning\x12A\n" + + "\x0fedition_removed\x18\x04 \x01(\x0e2\x18.google.protobuf.EditionR\x0eeditionRemoved\"/\n" + + "\x05CType\x12\n" + + "\n" + + "\x06STRING\x10\x00\x12\b\n" + + "\x04CORD\x10\x01\x12\x10\n" + + "\fSTRING_PIECE\x10\x02\"5\n" + + "\x06JSType\x12\r\n" + + "\tJS_NORMAL\x10\x00\x12\r\n" + + "\tJS_STRING\x10\x01\x12\r\n" + + "\tJS_NUMBER\x10\x02\"U\n" + + "\x0fOptionRetention\x12\x15\n" + + "\x11RETENTION_UNKNOWN\x10\x00\x12\x15\n" + + "\x11RETENTION_RUNTIME\x10\x01\x12\x14\n" + + "\x10RETENTION_SOURCE\x10\x02\"\x8c\x02\n" + + "\x10OptionTargetType\x12\x17\n" + + "\x13TARGET_TYPE_UNKNOWN\x10\x00\x12\x14\n" + + "\x10TARGET_TYPE_FILE\x10\x01\x12\x1f\n" + + "\x1bTARGET_TYPE_EXTENSION_RANGE\x10\x02\x12\x17\n" + + "\x13TARGET_TYPE_MESSAGE\x10\x03\x12\x15\n" + + "\x11TARGET_TYPE_FIELD\x10\x04\x12\x15\n" + + "\x11TARGET_TYPE_ONEOF\x10\x05\x12\x14\n" + + "\x10TARGET_TYPE_ENUM\x10\x06\x12\x1a\n" + + "\x16TARGET_TYPE_ENUM_ENTRY\x10\a\x12\x17\n" + + "\x13TARGET_TYPE_SERVICE\x10\b\x12\x16\n" + + "\x12TARGET_TYPE_METHOD\x10\t*\t\b\xe8\a\x10\x80\x80\x80\x80\x02J\x04\b\x04\x10\x05J\x04\b\x12\x10\x13\"\xac\x01\n" + + "\fOneofOptions\x127\n" + + "\bfeatures\x18\x01 \x01(\v2\x1b.google.protobuf.FeatureSetR\bfeatures\x12X\n" + + "\x14uninterpreted_option\x18\xe7\a \x03(\v2$.google.protobuf.UninterpretedOptionR\x13uninterpretedOption*\t\b\xe8\a\x10\x80\x80\x80\x80\x02\"\xd1\x02\n" + + "\vEnumOptions\x12\x1f\n" + + "\vallow_alias\x18\x02 \x01(\bR\n" + + "allowAlias\x12%\n" + + "\n" + + "deprecated\x18\x03 \x01(\b:\x05falseR\n" + + "deprecated\x12V\n" + + "&deprecated_legacy_json_field_conflicts\x18\x06 \x01(\bB\x02\x18\x01R\"deprecatedLegacyJsonFieldConflicts\x127\n" + + "\bfeatures\x18\a \x01(\v2\x1b.google.protobuf.FeatureSetR\bfeatures\x12X\n" + + "\x14uninterpreted_option\x18\xe7\a \x03(\v2$.google.protobuf.UninterpretedOptionR\x13uninterpretedOption*\t\b\xe8\a\x10\x80\x80\x80\x80\x02J\x04\b\x05\x10\x06\"\xd8\x02\n" + + "\x10EnumValueOptions\x12%\n" + + "\n" + + "deprecated\x18\x01 \x01(\b:\x05falseR\n" + + "deprecated\x127\n" + + "\bfeatures\x18\x02 \x01(\v2\x1b.google.protobuf.FeatureSetR\bfeatures\x12(\n" + + "\fdebug_redact\x18\x03 \x01(\b:\x05falseR\vdebugRedact\x12U\n" + + "\x0ffeature_support\x18\x04 \x01(\v2,.google.protobuf.FieldOptions.FeatureSupportR\x0efeatureSupport\x12X\n" + + "\x14uninterpreted_option\x18\xe7\a \x03(\v2$.google.protobuf.UninterpretedOptionR\x13uninterpretedOption*\t\b\xe8\a\x10\x80\x80\x80\x80\x02\"\xd5\x01\n" + + "\x0eServiceOptions\x127\n" + + "\bfeatures\x18\" \x01(\v2\x1b.google.protobuf.FeatureSetR\bfeatures\x12%\n" + + "\n" + + "deprecated\x18! \x01(\b:\x05falseR\n" + + "deprecated\x12X\n" + + "\x14uninterpreted_option\x18\xe7\a \x03(\v2$.google.protobuf.UninterpretedOptionR\x13uninterpretedOption*\t\b\xe8\a\x10\x80\x80\x80\x80\x02\"\x99\x03\n" + + "\rMethodOptions\x12%\n" + + "\n" + + "deprecated\x18! \x01(\b:\x05falseR\n" + + "deprecated\x12q\n" + + "\x11idempotency_level\x18\" \x01(\x0e2/.google.protobuf.MethodOptions.IdempotencyLevel:\x13IDEMPOTENCY_UNKNOWNR\x10idempotencyLevel\x127\n" + + "\bfeatures\x18# \x01(\v2\x1b.google.protobuf.FeatureSetR\bfeatures\x12X\n" + + "\x14uninterpreted_option\x18\xe7\a \x03(\v2$.google.protobuf.UninterpretedOptionR\x13uninterpretedOption\"P\n" + + "\x10IdempotencyLevel\x12\x17\n" + + "\x13IDEMPOTENCY_UNKNOWN\x10\x00\x12\x13\n" + + "\x0fNO_SIDE_EFFECTS\x10\x01\x12\x0e\n" + + "\n" + + "IDEMPOTENT\x10\x02*\t\b\xe8\a\x10\x80\x80\x80\x80\x02\"\x9a\x03\n" + + "\x13UninterpretedOption\x12A\n" + + "\x04name\x18\x02 \x03(\v2-.google.protobuf.UninterpretedOption.NamePartR\x04name\x12)\n" + + "\x10identifier_value\x18\x03 \x01(\tR\x0fidentifierValue\x12,\n" + + "\x12positive_int_value\x18\x04 \x01(\x04R\x10positiveIntValue\x12,\n" + + "\x12negative_int_value\x18\x05 \x01(\x03R\x10negativeIntValue\x12!\n" + + "\fdouble_value\x18\x06 \x01(\x01R\vdoubleValue\x12!\n" + + "\fstring_value\x18\a \x01(\fR\vstringValue\x12'\n" + + "\x0faggregate_value\x18\b \x01(\tR\x0eaggregateValue\x1aJ\n" + + "\bNamePart\x12\x1b\n" + + "\tname_part\x18\x01 \x02(\tR\bnamePart\x12!\n" + + "\fis_extension\x18\x02 \x02(\bR\visExtension\"\xae\f\n" + + "\n" + + "FeatureSet\x12\x91\x01\n" + + "\x0efield_presence\x18\x01 \x01(\x0e2).google.protobuf.FeatureSet.FieldPresenceB?\x88\x01\x01\x98\x01\x04\x98\x01\x01\xa2\x01\r\x12\bEXPLICIT\x18\x84\a\xa2\x01\r\x12\bIMPLICIT\x18\xe7\a\xa2\x01\r\x12\bEXPLICIT\x18\xe8\a\xb2\x01\x03\b\xe8\aR\rfieldPresence\x12l\n" + + "\tenum_type\x18\x02 \x01(\x0e2$.google.protobuf.FeatureSet.EnumTypeB)\x88\x01\x01\x98\x01\x06\x98\x01\x01\xa2\x01\v\x12\x06CLOSED\x18\x84\a\xa2\x01\t\x12\x04OPEN\x18\xe7\a\xb2\x01\x03\b\xe8\aR\benumType\x12\x98\x01\n" + + "\x17repeated_field_encoding\x18\x03 \x01(\x0e21.google.protobuf.FeatureSet.RepeatedFieldEncodingB-\x88\x01\x01\x98\x01\x04\x98\x01\x01\xa2\x01\r\x12\bEXPANDED\x18\x84\a\xa2\x01\v\x12\x06PACKED\x18\xe7\a\xb2\x01\x03\b\xe8\aR\x15repeatedFieldEncoding\x12~\n" + + "\x0futf8_validation\x18\x04 \x01(\x0e2*.google.protobuf.FeatureSet.Utf8ValidationB)\x88\x01\x01\x98\x01\x04\x98\x01\x01\xa2\x01\t\x12\x04NONE\x18\x84\a\xa2\x01\v\x12\x06VERIFY\x18\xe7\a\xb2\x01\x03\b\xe8\aR\x0eutf8Validation\x12~\n" + + "\x10message_encoding\x18\x05 \x01(\x0e2+.google.protobuf.FeatureSet.MessageEncodingB&\x88\x01\x01\x98\x01\x04\x98\x01\x01\xa2\x01\x14\x12\x0fLENGTH_PREFIXED\x18\x84\a\xb2\x01\x03\b\xe8\aR\x0fmessageEncoding\x12\x82\x01\n" + + "\vjson_format\x18\x06 \x01(\x0e2&.google.protobuf.FeatureSet.JsonFormatB9\x88\x01\x01\x98\x01\x03\x98\x01\x06\x98\x01\x01\xa2\x01\x17\x12\x12LEGACY_BEST_EFFORT\x18\x84\a\xa2\x01\n" + + "\x12\x05ALLOW\x18\xe7\a\xb2\x01\x03\b\xe8\aR\n" + + "jsonFormat\x12\xab\x01\n" + + "\x14enforce_naming_style\x18\a \x01(\x0e2..google.protobuf.FeatureSet.EnforceNamingStyleBI\x88\x01\x02\x98\x01\x01\x98\x01\x02\x98\x01\x03\x98\x01\x04\x98\x01\x05\x98\x01\x06\x98\x01\a\x98\x01\b\x98\x01\t\xa2\x01\x11\x12\fSTYLE_LEGACY\x18\x84\a\xa2\x01\x0e\x12\tSTYLE2024\x18\xe9\a\xb2\x01\x03\b\xe9\aR\x12enforceNamingStyle\"\\\n" + + "\rFieldPresence\x12\x1a\n" + + "\x16FIELD_PRESENCE_UNKNOWN\x10\x00\x12\f\n" + + "\bEXPLICIT\x10\x01\x12\f\n" + + "\bIMPLICIT\x10\x02\x12\x13\n" + + "\x0fLEGACY_REQUIRED\x10\x03\"7\n" + + "\bEnumType\x12\x15\n" + + "\x11ENUM_TYPE_UNKNOWN\x10\x00\x12\b\n" + + "\x04OPEN\x10\x01\x12\n" + + "\n" + + "\x06CLOSED\x10\x02\"V\n" + + "\x15RepeatedFieldEncoding\x12#\n" + + "\x1fREPEATED_FIELD_ENCODING_UNKNOWN\x10\x00\x12\n" + + "\n" + + "\x06PACKED\x10\x01\x12\f\n" + + "\bEXPANDED\x10\x02\"I\n" + + "\x0eUtf8Validation\x12\x1b\n" + + "\x17UTF8_VALIDATION_UNKNOWN\x10\x00\x12\n" + + "\n" + + "\x06VERIFY\x10\x02\x12\b\n" + + "\x04NONE\x10\x03\"\x04\b\x01\x10\x01\"S\n" + + "\x0fMessageEncoding\x12\x1c\n" + + "\x18MESSAGE_ENCODING_UNKNOWN\x10\x00\x12\x13\n" + + "\x0fLENGTH_PREFIXED\x10\x01\x12\r\n" + + "\tDELIMITED\x10\x02\"H\n" + + "\n" + + "JsonFormat\x12\x17\n" + + "\x13JSON_FORMAT_UNKNOWN\x10\x00\x12\t\n" + + "\x05ALLOW\x10\x01\x12\x16\n" + + "\x12LEGACY_BEST_EFFORT\x10\x02\"W\n" + + "\x12EnforceNamingStyle\x12 \n" + + "\x1cENFORCE_NAMING_STYLE_UNKNOWN\x10\x00\x12\r\n" + + "\tSTYLE2024\x10\x01\x12\x10\n" + + "\fSTYLE_LEGACY\x10\x02*\x06\b\xe8\a\x10\x8bN*\x06\b\x8bN\x10\x90N*\x06\b\x90N\x10\x91NJ\x06\b\xe7\a\x10\xe8\a\"\xef\x03\n" + + "\x12FeatureSetDefaults\x12X\n" + + "\bdefaults\x18\x01 \x03(\v2<.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefaultR\bdefaults\x12A\n" + + "\x0fminimum_edition\x18\x04 \x01(\x0e2\x18.google.protobuf.EditionR\x0eminimumEdition\x12A\n" + + "\x0fmaximum_edition\x18\x05 \x01(\x0e2\x18.google.protobuf.EditionR\x0emaximumEdition\x1a\xf8\x01\n" + + "\x18FeatureSetEditionDefault\x122\n" + + "\aedition\x18\x03 \x01(\x0e2\x18.google.protobuf.EditionR\aedition\x12N\n" + + "\x14overridable_features\x18\x04 \x01(\v2\x1b.google.protobuf.FeatureSetR\x13overridableFeatures\x12B\n" + + "\x0efixed_features\x18\x05 \x01(\v2\x1b.google.protobuf.FeatureSetR\rfixedFeaturesJ\x04\b\x01\x10\x02J\x04\b\x02\x10\x03R\bfeatures\"\xb5\x02\n" + + "\x0eSourceCodeInfo\x12D\n" + + "\blocation\x18\x01 \x03(\v2(.google.protobuf.SourceCodeInfo.LocationR\blocation\x1a\xce\x01\n" + + "\bLocation\x12\x16\n" + + "\x04path\x18\x01 \x03(\x05B\x02\x10\x01R\x04path\x12\x16\n" + + "\x04span\x18\x02 \x03(\x05B\x02\x10\x01R\x04span\x12)\n" + + "\x10leading_comments\x18\x03 \x01(\tR\x0fleadingComments\x12+\n" + + "\x11trailing_comments\x18\x04 \x01(\tR\x10trailingComments\x12:\n" + + "\x19leading_detached_comments\x18\x06 \x03(\tR\x17leadingDetachedComments*\f\b\x80\xec\xca\xff\x01\x10\x81\xec\xca\xff\x01\"\xd0\x02\n" + + "\x11GeneratedCodeInfo\x12M\n" + + "\n" + + "annotation\x18\x01 \x03(\v2-.google.protobuf.GeneratedCodeInfo.AnnotationR\n" + + "annotation\x1a\xeb\x01\n" + + "\n" + + "Annotation\x12\x16\n" + + "\x04path\x18\x01 \x03(\x05B\x02\x10\x01R\x04path\x12\x1f\n" + + "\vsource_file\x18\x02 \x01(\tR\n" + + "sourceFile\x12\x14\n" + + "\x05begin\x18\x03 \x01(\x05R\x05begin\x12\x10\n" + + "\x03end\x18\x04 \x01(\x05R\x03end\x12R\n" + + "\bsemantic\x18\x05 \x01(\x0e26.google.protobuf.GeneratedCodeInfo.Annotation.SemanticR\bsemantic\"(\n" + + "\bSemantic\x12\b\n" + + "\x04NONE\x10\x00\x12\a\n" + + "\x03SET\x10\x01\x12\t\n" + + "\x05ALIAS\x10\x02*\xa7\x02\n" + + "\aEdition\x12\x13\n" + + "\x0fEDITION_UNKNOWN\x10\x00\x12\x13\n" + + "\x0eEDITION_LEGACY\x10\x84\a\x12\x13\n" + + "\x0eEDITION_PROTO2\x10\xe6\a\x12\x13\n" + + "\x0eEDITION_PROTO3\x10\xe7\a\x12\x11\n" + + "\fEDITION_2023\x10\xe8\a\x12\x11\n" + + "\fEDITION_2024\x10\xe9\a\x12\x17\n" + + "\x13EDITION_1_TEST_ONLY\x10\x01\x12\x17\n" + + "\x13EDITION_2_TEST_ONLY\x10\x02\x12\x1d\n" + + "\x17EDITION_99997_TEST_ONLY\x10\x9d\x8d\x06\x12\x1d\n" + + "\x17EDITION_99998_TEST_ONLY\x10\x9e\x8d\x06\x12\x1d\n" + + "\x17EDITION_99999_TEST_ONLY\x10\x9f\x8d\x06\x12\x13\n" + + "\vEDITION_MAX\x10\xff\xff\xff\xff\aB~\n" + + "\x13com.google.protobufB\x10DescriptorProtosH\x01Z-google.golang.org/protobuf/types/descriptorpb\xf8\x01\x01\xa2\x02\x03GPB\xaa\x02\x1aGoogle.Protobuf.Reflection" var ( file_google_protobuf_descriptor_proto_rawDescOnce sync.Once @@ -5145,7 +4832,7 @@ func file_google_protobuf_descriptor_proto_rawDescGZIP() []byte { return file_google_protobuf_descriptor_proto_rawDescData } -var file_google_protobuf_descriptor_proto_enumTypes = make([]protoimpl.EnumInfo, 17) +var file_google_protobuf_descriptor_proto_enumTypes = make([]protoimpl.EnumInfo, 18) var file_google_protobuf_descriptor_proto_msgTypes = make([]protoimpl.MessageInfo, 33) var file_google_protobuf_descriptor_proto_goTypes = []any{ (Edition)(0), // 0: google.protobuf.Edition @@ -5164,124 +4851,126 @@ var file_google_protobuf_descriptor_proto_goTypes = []any{ (FeatureSet_Utf8Validation)(0), // 13: google.protobuf.FeatureSet.Utf8Validation (FeatureSet_MessageEncoding)(0), // 14: google.protobuf.FeatureSet.MessageEncoding (FeatureSet_JsonFormat)(0), // 15: google.protobuf.FeatureSet.JsonFormat - (GeneratedCodeInfo_Annotation_Semantic)(0), // 16: google.protobuf.GeneratedCodeInfo.Annotation.Semantic - (*FileDescriptorSet)(nil), // 17: google.protobuf.FileDescriptorSet - (*FileDescriptorProto)(nil), // 18: google.protobuf.FileDescriptorProto - (*DescriptorProto)(nil), // 19: google.protobuf.DescriptorProto - (*ExtensionRangeOptions)(nil), // 20: google.protobuf.ExtensionRangeOptions - (*FieldDescriptorProto)(nil), // 21: google.protobuf.FieldDescriptorProto - (*OneofDescriptorProto)(nil), // 22: google.protobuf.OneofDescriptorProto - (*EnumDescriptorProto)(nil), // 23: google.protobuf.EnumDescriptorProto - (*EnumValueDescriptorProto)(nil), // 24: google.protobuf.EnumValueDescriptorProto - (*ServiceDescriptorProto)(nil), // 25: google.protobuf.ServiceDescriptorProto - (*MethodDescriptorProto)(nil), // 26: google.protobuf.MethodDescriptorProto - (*FileOptions)(nil), // 27: google.protobuf.FileOptions - (*MessageOptions)(nil), // 28: google.protobuf.MessageOptions - (*FieldOptions)(nil), // 29: google.protobuf.FieldOptions - (*OneofOptions)(nil), // 30: google.protobuf.OneofOptions - (*EnumOptions)(nil), // 31: google.protobuf.EnumOptions - (*EnumValueOptions)(nil), // 32: google.protobuf.EnumValueOptions - (*ServiceOptions)(nil), // 33: google.protobuf.ServiceOptions - (*MethodOptions)(nil), // 34: google.protobuf.MethodOptions - (*UninterpretedOption)(nil), // 35: google.protobuf.UninterpretedOption - (*FeatureSet)(nil), // 36: google.protobuf.FeatureSet - (*FeatureSetDefaults)(nil), // 37: google.protobuf.FeatureSetDefaults - (*SourceCodeInfo)(nil), // 38: google.protobuf.SourceCodeInfo - (*GeneratedCodeInfo)(nil), // 39: google.protobuf.GeneratedCodeInfo - (*DescriptorProto_ExtensionRange)(nil), // 40: google.protobuf.DescriptorProto.ExtensionRange - (*DescriptorProto_ReservedRange)(nil), // 41: google.protobuf.DescriptorProto.ReservedRange - (*ExtensionRangeOptions_Declaration)(nil), // 42: google.protobuf.ExtensionRangeOptions.Declaration - (*EnumDescriptorProto_EnumReservedRange)(nil), // 43: google.protobuf.EnumDescriptorProto.EnumReservedRange - (*FieldOptions_EditionDefault)(nil), // 44: google.protobuf.FieldOptions.EditionDefault - (*FieldOptions_FeatureSupport)(nil), // 45: google.protobuf.FieldOptions.FeatureSupport - (*UninterpretedOption_NamePart)(nil), // 46: google.protobuf.UninterpretedOption.NamePart - (*FeatureSetDefaults_FeatureSetEditionDefault)(nil), // 47: google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault - (*SourceCodeInfo_Location)(nil), // 48: google.protobuf.SourceCodeInfo.Location - (*GeneratedCodeInfo_Annotation)(nil), // 49: google.protobuf.GeneratedCodeInfo.Annotation + (FeatureSet_EnforceNamingStyle)(0), // 16: google.protobuf.FeatureSet.EnforceNamingStyle + (GeneratedCodeInfo_Annotation_Semantic)(0), // 17: google.protobuf.GeneratedCodeInfo.Annotation.Semantic + (*FileDescriptorSet)(nil), // 18: google.protobuf.FileDescriptorSet + (*FileDescriptorProto)(nil), // 19: google.protobuf.FileDescriptorProto + (*DescriptorProto)(nil), // 20: google.protobuf.DescriptorProto + (*ExtensionRangeOptions)(nil), // 21: google.protobuf.ExtensionRangeOptions + (*FieldDescriptorProto)(nil), // 22: google.protobuf.FieldDescriptorProto + (*OneofDescriptorProto)(nil), // 23: google.protobuf.OneofDescriptorProto + (*EnumDescriptorProto)(nil), // 24: google.protobuf.EnumDescriptorProto + (*EnumValueDescriptorProto)(nil), // 25: google.protobuf.EnumValueDescriptorProto + (*ServiceDescriptorProto)(nil), // 26: google.protobuf.ServiceDescriptorProto + (*MethodDescriptorProto)(nil), // 27: google.protobuf.MethodDescriptorProto + (*FileOptions)(nil), // 28: google.protobuf.FileOptions + (*MessageOptions)(nil), // 29: google.protobuf.MessageOptions + (*FieldOptions)(nil), // 30: google.protobuf.FieldOptions + (*OneofOptions)(nil), // 31: google.protobuf.OneofOptions + (*EnumOptions)(nil), // 32: google.protobuf.EnumOptions + (*EnumValueOptions)(nil), // 33: google.protobuf.EnumValueOptions + (*ServiceOptions)(nil), // 34: google.protobuf.ServiceOptions + (*MethodOptions)(nil), // 35: google.protobuf.MethodOptions + (*UninterpretedOption)(nil), // 36: google.protobuf.UninterpretedOption + (*FeatureSet)(nil), // 37: google.protobuf.FeatureSet + (*FeatureSetDefaults)(nil), // 38: google.protobuf.FeatureSetDefaults + (*SourceCodeInfo)(nil), // 39: google.protobuf.SourceCodeInfo + (*GeneratedCodeInfo)(nil), // 40: google.protobuf.GeneratedCodeInfo + (*DescriptorProto_ExtensionRange)(nil), // 41: google.protobuf.DescriptorProto.ExtensionRange + (*DescriptorProto_ReservedRange)(nil), // 42: google.protobuf.DescriptorProto.ReservedRange + (*ExtensionRangeOptions_Declaration)(nil), // 43: google.protobuf.ExtensionRangeOptions.Declaration + (*EnumDescriptorProto_EnumReservedRange)(nil), // 44: google.protobuf.EnumDescriptorProto.EnumReservedRange + (*FieldOptions_EditionDefault)(nil), // 45: google.protobuf.FieldOptions.EditionDefault + (*FieldOptions_FeatureSupport)(nil), // 46: google.protobuf.FieldOptions.FeatureSupport + (*UninterpretedOption_NamePart)(nil), // 47: google.protobuf.UninterpretedOption.NamePart + (*FeatureSetDefaults_FeatureSetEditionDefault)(nil), // 48: google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + (*SourceCodeInfo_Location)(nil), // 49: google.protobuf.SourceCodeInfo.Location + (*GeneratedCodeInfo_Annotation)(nil), // 50: google.protobuf.GeneratedCodeInfo.Annotation } var file_google_protobuf_descriptor_proto_depIdxs = []int32{ - 18, // 0: google.protobuf.FileDescriptorSet.file:type_name -> google.protobuf.FileDescriptorProto - 19, // 1: google.protobuf.FileDescriptorProto.message_type:type_name -> google.protobuf.DescriptorProto - 23, // 2: google.protobuf.FileDescriptorProto.enum_type:type_name -> google.protobuf.EnumDescriptorProto - 25, // 3: google.protobuf.FileDescriptorProto.service:type_name -> google.protobuf.ServiceDescriptorProto - 21, // 4: google.protobuf.FileDescriptorProto.extension:type_name -> google.protobuf.FieldDescriptorProto - 27, // 5: google.protobuf.FileDescriptorProto.options:type_name -> google.protobuf.FileOptions - 38, // 6: google.protobuf.FileDescriptorProto.source_code_info:type_name -> google.protobuf.SourceCodeInfo + 19, // 0: google.protobuf.FileDescriptorSet.file:type_name -> google.protobuf.FileDescriptorProto + 20, // 1: google.protobuf.FileDescriptorProto.message_type:type_name -> google.protobuf.DescriptorProto + 24, // 2: google.protobuf.FileDescriptorProto.enum_type:type_name -> google.protobuf.EnumDescriptorProto + 26, // 3: google.protobuf.FileDescriptorProto.service:type_name -> google.protobuf.ServiceDescriptorProto + 22, // 4: google.protobuf.FileDescriptorProto.extension:type_name -> google.protobuf.FieldDescriptorProto + 28, // 5: google.protobuf.FileDescriptorProto.options:type_name -> google.protobuf.FileOptions + 39, // 6: google.protobuf.FileDescriptorProto.source_code_info:type_name -> google.protobuf.SourceCodeInfo 0, // 7: google.protobuf.FileDescriptorProto.edition:type_name -> google.protobuf.Edition - 21, // 8: google.protobuf.DescriptorProto.field:type_name -> google.protobuf.FieldDescriptorProto - 21, // 9: google.protobuf.DescriptorProto.extension:type_name -> google.protobuf.FieldDescriptorProto - 19, // 10: google.protobuf.DescriptorProto.nested_type:type_name -> google.protobuf.DescriptorProto - 23, // 11: google.protobuf.DescriptorProto.enum_type:type_name -> google.protobuf.EnumDescriptorProto - 40, // 12: google.protobuf.DescriptorProto.extension_range:type_name -> google.protobuf.DescriptorProto.ExtensionRange - 22, // 13: google.protobuf.DescriptorProto.oneof_decl:type_name -> google.protobuf.OneofDescriptorProto - 28, // 14: google.protobuf.DescriptorProto.options:type_name -> google.protobuf.MessageOptions - 41, // 15: google.protobuf.DescriptorProto.reserved_range:type_name -> google.protobuf.DescriptorProto.ReservedRange - 35, // 16: google.protobuf.ExtensionRangeOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption - 42, // 17: google.protobuf.ExtensionRangeOptions.declaration:type_name -> google.protobuf.ExtensionRangeOptions.Declaration - 36, // 18: google.protobuf.ExtensionRangeOptions.features:type_name -> google.protobuf.FeatureSet + 22, // 8: google.protobuf.DescriptorProto.field:type_name -> google.protobuf.FieldDescriptorProto + 22, // 9: google.protobuf.DescriptorProto.extension:type_name -> google.protobuf.FieldDescriptorProto + 20, // 10: google.protobuf.DescriptorProto.nested_type:type_name -> google.protobuf.DescriptorProto + 24, // 11: google.protobuf.DescriptorProto.enum_type:type_name -> google.protobuf.EnumDescriptorProto + 41, // 12: google.protobuf.DescriptorProto.extension_range:type_name -> google.protobuf.DescriptorProto.ExtensionRange + 23, // 13: google.protobuf.DescriptorProto.oneof_decl:type_name -> google.protobuf.OneofDescriptorProto + 29, // 14: google.protobuf.DescriptorProto.options:type_name -> google.protobuf.MessageOptions + 42, // 15: google.protobuf.DescriptorProto.reserved_range:type_name -> google.protobuf.DescriptorProto.ReservedRange + 36, // 16: google.protobuf.ExtensionRangeOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption + 43, // 17: google.protobuf.ExtensionRangeOptions.declaration:type_name -> google.protobuf.ExtensionRangeOptions.Declaration + 37, // 18: google.protobuf.ExtensionRangeOptions.features:type_name -> google.protobuf.FeatureSet 1, // 19: google.protobuf.ExtensionRangeOptions.verification:type_name -> google.protobuf.ExtensionRangeOptions.VerificationState 3, // 20: google.protobuf.FieldDescriptorProto.label:type_name -> google.protobuf.FieldDescriptorProto.Label 2, // 21: google.protobuf.FieldDescriptorProto.type:type_name -> google.protobuf.FieldDescriptorProto.Type - 29, // 22: google.protobuf.FieldDescriptorProto.options:type_name -> google.protobuf.FieldOptions - 30, // 23: google.protobuf.OneofDescriptorProto.options:type_name -> google.protobuf.OneofOptions - 24, // 24: google.protobuf.EnumDescriptorProto.value:type_name -> google.protobuf.EnumValueDescriptorProto - 31, // 25: google.protobuf.EnumDescriptorProto.options:type_name -> google.protobuf.EnumOptions - 43, // 26: google.protobuf.EnumDescriptorProto.reserved_range:type_name -> google.protobuf.EnumDescriptorProto.EnumReservedRange - 32, // 27: google.protobuf.EnumValueDescriptorProto.options:type_name -> google.protobuf.EnumValueOptions - 26, // 28: google.protobuf.ServiceDescriptorProto.method:type_name -> google.protobuf.MethodDescriptorProto - 33, // 29: google.protobuf.ServiceDescriptorProto.options:type_name -> google.protobuf.ServiceOptions - 34, // 30: google.protobuf.MethodDescriptorProto.options:type_name -> google.protobuf.MethodOptions + 30, // 22: google.protobuf.FieldDescriptorProto.options:type_name -> google.protobuf.FieldOptions + 31, // 23: google.protobuf.OneofDescriptorProto.options:type_name -> google.protobuf.OneofOptions + 25, // 24: google.protobuf.EnumDescriptorProto.value:type_name -> google.protobuf.EnumValueDescriptorProto + 32, // 25: google.protobuf.EnumDescriptorProto.options:type_name -> google.protobuf.EnumOptions + 44, // 26: google.protobuf.EnumDescriptorProto.reserved_range:type_name -> google.protobuf.EnumDescriptorProto.EnumReservedRange + 33, // 27: google.protobuf.EnumValueDescriptorProto.options:type_name -> google.protobuf.EnumValueOptions + 27, // 28: google.protobuf.ServiceDescriptorProto.method:type_name -> google.protobuf.MethodDescriptorProto + 34, // 29: google.protobuf.ServiceDescriptorProto.options:type_name -> google.protobuf.ServiceOptions + 35, // 30: google.protobuf.MethodDescriptorProto.options:type_name -> google.protobuf.MethodOptions 4, // 31: google.protobuf.FileOptions.optimize_for:type_name -> google.protobuf.FileOptions.OptimizeMode - 36, // 32: google.protobuf.FileOptions.features:type_name -> google.protobuf.FeatureSet - 35, // 33: google.protobuf.FileOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption - 36, // 34: google.protobuf.MessageOptions.features:type_name -> google.protobuf.FeatureSet - 35, // 35: google.protobuf.MessageOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption + 37, // 32: google.protobuf.FileOptions.features:type_name -> google.protobuf.FeatureSet + 36, // 33: google.protobuf.FileOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption + 37, // 34: google.protobuf.MessageOptions.features:type_name -> google.protobuf.FeatureSet + 36, // 35: google.protobuf.MessageOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption 5, // 36: google.protobuf.FieldOptions.ctype:type_name -> google.protobuf.FieldOptions.CType 6, // 37: google.protobuf.FieldOptions.jstype:type_name -> google.protobuf.FieldOptions.JSType 7, // 38: google.protobuf.FieldOptions.retention:type_name -> google.protobuf.FieldOptions.OptionRetention 8, // 39: google.protobuf.FieldOptions.targets:type_name -> google.protobuf.FieldOptions.OptionTargetType - 44, // 40: google.protobuf.FieldOptions.edition_defaults:type_name -> google.protobuf.FieldOptions.EditionDefault - 36, // 41: google.protobuf.FieldOptions.features:type_name -> google.protobuf.FeatureSet - 45, // 42: google.protobuf.FieldOptions.feature_support:type_name -> google.protobuf.FieldOptions.FeatureSupport - 35, // 43: google.protobuf.FieldOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption - 36, // 44: google.protobuf.OneofOptions.features:type_name -> google.protobuf.FeatureSet - 35, // 45: google.protobuf.OneofOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption - 36, // 46: google.protobuf.EnumOptions.features:type_name -> google.protobuf.FeatureSet - 35, // 47: google.protobuf.EnumOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption - 36, // 48: google.protobuf.EnumValueOptions.features:type_name -> google.protobuf.FeatureSet - 45, // 49: google.protobuf.EnumValueOptions.feature_support:type_name -> google.protobuf.FieldOptions.FeatureSupport - 35, // 50: google.protobuf.EnumValueOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption - 36, // 51: google.protobuf.ServiceOptions.features:type_name -> google.protobuf.FeatureSet - 35, // 52: google.protobuf.ServiceOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption + 45, // 40: google.protobuf.FieldOptions.edition_defaults:type_name -> google.protobuf.FieldOptions.EditionDefault + 37, // 41: google.protobuf.FieldOptions.features:type_name -> google.protobuf.FeatureSet + 46, // 42: google.protobuf.FieldOptions.feature_support:type_name -> google.protobuf.FieldOptions.FeatureSupport + 36, // 43: google.protobuf.FieldOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption + 37, // 44: google.protobuf.OneofOptions.features:type_name -> google.protobuf.FeatureSet + 36, // 45: google.protobuf.OneofOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption + 37, // 46: google.protobuf.EnumOptions.features:type_name -> google.protobuf.FeatureSet + 36, // 47: google.protobuf.EnumOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption + 37, // 48: google.protobuf.EnumValueOptions.features:type_name -> google.protobuf.FeatureSet + 46, // 49: google.protobuf.EnumValueOptions.feature_support:type_name -> google.protobuf.FieldOptions.FeatureSupport + 36, // 50: google.protobuf.EnumValueOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption + 37, // 51: google.protobuf.ServiceOptions.features:type_name -> google.protobuf.FeatureSet + 36, // 52: google.protobuf.ServiceOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption 9, // 53: google.protobuf.MethodOptions.idempotency_level:type_name -> google.protobuf.MethodOptions.IdempotencyLevel - 36, // 54: google.protobuf.MethodOptions.features:type_name -> google.protobuf.FeatureSet - 35, // 55: google.protobuf.MethodOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption - 46, // 56: google.protobuf.UninterpretedOption.name:type_name -> google.protobuf.UninterpretedOption.NamePart + 37, // 54: google.protobuf.MethodOptions.features:type_name -> google.protobuf.FeatureSet + 36, // 55: google.protobuf.MethodOptions.uninterpreted_option:type_name -> google.protobuf.UninterpretedOption + 47, // 56: google.protobuf.UninterpretedOption.name:type_name -> google.protobuf.UninterpretedOption.NamePart 10, // 57: google.protobuf.FeatureSet.field_presence:type_name -> google.protobuf.FeatureSet.FieldPresence 11, // 58: google.protobuf.FeatureSet.enum_type:type_name -> google.protobuf.FeatureSet.EnumType 12, // 59: google.protobuf.FeatureSet.repeated_field_encoding:type_name -> google.protobuf.FeatureSet.RepeatedFieldEncoding 13, // 60: google.protobuf.FeatureSet.utf8_validation:type_name -> google.protobuf.FeatureSet.Utf8Validation 14, // 61: google.protobuf.FeatureSet.message_encoding:type_name -> google.protobuf.FeatureSet.MessageEncoding 15, // 62: google.protobuf.FeatureSet.json_format:type_name -> google.protobuf.FeatureSet.JsonFormat - 47, // 63: google.protobuf.FeatureSetDefaults.defaults:type_name -> google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault - 0, // 64: google.protobuf.FeatureSetDefaults.minimum_edition:type_name -> google.protobuf.Edition - 0, // 65: google.protobuf.FeatureSetDefaults.maximum_edition:type_name -> google.protobuf.Edition - 48, // 66: google.protobuf.SourceCodeInfo.location:type_name -> google.protobuf.SourceCodeInfo.Location - 49, // 67: google.protobuf.GeneratedCodeInfo.annotation:type_name -> google.protobuf.GeneratedCodeInfo.Annotation - 20, // 68: google.protobuf.DescriptorProto.ExtensionRange.options:type_name -> google.protobuf.ExtensionRangeOptions - 0, // 69: google.protobuf.FieldOptions.EditionDefault.edition:type_name -> google.protobuf.Edition - 0, // 70: google.protobuf.FieldOptions.FeatureSupport.edition_introduced:type_name -> google.protobuf.Edition - 0, // 71: google.protobuf.FieldOptions.FeatureSupport.edition_deprecated:type_name -> google.protobuf.Edition - 0, // 72: google.protobuf.FieldOptions.FeatureSupport.edition_removed:type_name -> google.protobuf.Edition - 0, // 73: google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.edition:type_name -> google.protobuf.Edition - 36, // 74: google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.overridable_features:type_name -> google.protobuf.FeatureSet - 36, // 75: google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.fixed_features:type_name -> google.protobuf.FeatureSet - 16, // 76: google.protobuf.GeneratedCodeInfo.Annotation.semantic:type_name -> google.protobuf.GeneratedCodeInfo.Annotation.Semantic - 77, // [77:77] is the sub-list for method output_type - 77, // [77:77] is the sub-list for method input_type - 77, // [77:77] is the sub-list for extension type_name - 77, // [77:77] is the sub-list for extension extendee - 0, // [0:77] is the sub-list for field type_name + 16, // 63: google.protobuf.FeatureSet.enforce_naming_style:type_name -> google.protobuf.FeatureSet.EnforceNamingStyle + 48, // 64: google.protobuf.FeatureSetDefaults.defaults:type_name -> google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + 0, // 65: google.protobuf.FeatureSetDefaults.minimum_edition:type_name -> google.protobuf.Edition + 0, // 66: google.protobuf.FeatureSetDefaults.maximum_edition:type_name -> google.protobuf.Edition + 49, // 67: google.protobuf.SourceCodeInfo.location:type_name -> google.protobuf.SourceCodeInfo.Location + 50, // 68: google.protobuf.GeneratedCodeInfo.annotation:type_name -> google.protobuf.GeneratedCodeInfo.Annotation + 21, // 69: google.protobuf.DescriptorProto.ExtensionRange.options:type_name -> google.protobuf.ExtensionRangeOptions + 0, // 70: google.protobuf.FieldOptions.EditionDefault.edition:type_name -> google.protobuf.Edition + 0, // 71: google.protobuf.FieldOptions.FeatureSupport.edition_introduced:type_name -> google.protobuf.Edition + 0, // 72: google.protobuf.FieldOptions.FeatureSupport.edition_deprecated:type_name -> google.protobuf.Edition + 0, // 73: google.protobuf.FieldOptions.FeatureSupport.edition_removed:type_name -> google.protobuf.Edition + 0, // 74: google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.edition:type_name -> google.protobuf.Edition + 37, // 75: google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.overridable_features:type_name -> google.protobuf.FeatureSet + 37, // 76: google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.fixed_features:type_name -> google.protobuf.FeatureSet + 17, // 77: google.protobuf.GeneratedCodeInfo.Annotation.semantic:type_name -> google.protobuf.GeneratedCodeInfo.Annotation.Semantic + 78, // [78:78] is the sub-list for method output_type + 78, // [78:78] is the sub-list for method input_type + 78, // [78:78] is the sub-list for extension type_name + 78, // [78:78] is the sub-list for extension extendee + 0, // [0:78] is the sub-list for field type_name } func init() { file_google_protobuf_descriptor_proto_init() } @@ -5294,7 +4983,7 @@ func file_google_protobuf_descriptor_proto_init() { File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_google_protobuf_descriptor_proto_rawDesc), len(file_google_protobuf_descriptor_proto_rawDesc)), - NumEnums: 17, + NumEnums: 18, NumMessages: 33, NumExtensions: 0, NumServices: 0, diff --git a/vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.pb.go b/vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.pb.go index 28d24bad..37e712b6 100644 --- a/vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.pb.go +++ b/vendor/google.golang.org/protobuf/types/gofeaturespb/go_features.pb.go @@ -228,63 +228,29 @@ var ( var File_google_protobuf_go_features_proto protoreflect.FileDescriptor -var file_google_protobuf_go_features_proto_rawDesc = string([]byte{ - 0x0a, 0x21, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2f, 0x67, 0x6f, 0x5f, 0x66, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x12, 0x02, 0x70, 0x62, 0x1a, 0x20, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, - 0x74, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xab, 0x05, 0x0a, 0x0a, 0x47, 0x6f, - 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x12, 0xbe, 0x01, 0x0a, 0x1a, 0x6c, 0x65, 0x67, - 0x61, 0x63, 0x79, 0x5f, 0x75, 0x6e, 0x6d, 0x61, 0x72, 0x73, 0x68, 0x61, 0x6c, 0x5f, 0x6a, 0x73, - 0x6f, 0x6e, 0x5f, 0x65, 0x6e, 0x75, 0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x42, 0x80, 0x01, - 0x88, 0x01, 0x01, 0x98, 0x01, 0x06, 0x98, 0x01, 0x01, 0xa2, 0x01, 0x09, 0x12, 0x04, 0x74, 0x72, - 0x75, 0x65, 0x18, 0x84, 0x07, 0xa2, 0x01, 0x0a, 0x12, 0x05, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x18, - 0xe7, 0x07, 0xb2, 0x01, 0x5b, 0x08, 0xe8, 0x07, 0x10, 0xe8, 0x07, 0x1a, 0x53, 0x54, 0x68, 0x65, - 0x20, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x20, 0x55, 0x6e, 0x6d, 0x61, 0x72, 0x73, 0x68, 0x61, - 0x6c, 0x4a, 0x53, 0x4f, 0x4e, 0x20, 0x41, 0x50, 0x49, 0x20, 0x69, 0x73, 0x20, 0x64, 0x65, 0x70, - 0x72, 0x65, 0x63, 0x61, 0x74, 0x65, 0x64, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x77, 0x69, 0x6c, 0x6c, - 0x20, 0x62, 0x65, 0x20, 0x72, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x64, 0x20, 0x69, 0x6e, 0x20, 0x61, - 0x20, 0x66, 0x75, 0x74, 0x75, 0x72, 0x65, 0x20, 0x65, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x2e, - 0x52, 0x17, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x55, 0x6e, 0x6d, 0x61, 0x72, 0x73, 0x68, 0x61, - 0x6c, 0x4a, 0x73, 0x6f, 0x6e, 0x45, 0x6e, 0x75, 0x6d, 0x12, 0x74, 0x0a, 0x09, 0x61, 0x70, 0x69, - 0x5f, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x17, 0x2e, 0x70, - 0x62, 0x2e, 0x47, 0x6f, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x2e, 0x41, 0x50, 0x49, - 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x42, 0x3e, 0x88, 0x01, 0x01, 0x98, 0x01, 0x03, 0x98, 0x01, 0x01, - 0xa2, 0x01, 0x1a, 0x12, 0x15, 0x41, 0x50, 0x49, 0x5f, 0x4c, 0x45, 0x56, 0x45, 0x4c, 0x5f, 0x55, - 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x18, 0x84, 0x07, 0xa2, 0x01, 0x0f, - 0x12, 0x0a, 0x41, 0x50, 0x49, 0x5f, 0x4f, 0x50, 0x41, 0x51, 0x55, 0x45, 0x18, 0xe9, 0x07, 0xb2, - 0x01, 0x03, 0x08, 0xe8, 0x07, 0x52, 0x08, 0x61, 0x70, 0x69, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x12, - 0x7c, 0x0a, 0x11, 0x73, 0x74, 0x72, 0x69, 0x70, 0x5f, 0x65, 0x6e, 0x75, 0x6d, 0x5f, 0x70, 0x72, - 0x65, 0x66, 0x69, 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1e, 0x2e, 0x70, 0x62, 0x2e, - 0x47, 0x6f, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x73, 0x2e, 0x53, 0x74, 0x72, 0x69, 0x70, - 0x45, 0x6e, 0x75, 0x6d, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x42, 0x30, 0x88, 0x01, 0x01, 0x98, - 0x01, 0x06, 0x98, 0x01, 0x07, 0x98, 0x01, 0x01, 0xa2, 0x01, 0x1b, 0x12, 0x16, 0x53, 0x54, 0x52, - 0x49, 0x50, 0x5f, 0x45, 0x4e, 0x55, 0x4d, 0x5f, 0x50, 0x52, 0x45, 0x46, 0x49, 0x58, 0x5f, 0x4b, - 0x45, 0x45, 0x50, 0x18, 0x84, 0x07, 0xb2, 0x01, 0x03, 0x08, 0xe9, 0x07, 0x52, 0x0f, 0x73, 0x74, - 0x72, 0x69, 0x70, 0x45, 0x6e, 0x75, 0x6d, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x22, 0x53, 0x0a, - 0x08, 0x41, 0x50, 0x49, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x19, 0x0a, 0x15, 0x41, 0x50, 0x49, - 0x5f, 0x4c, 0x45, 0x56, 0x45, 0x4c, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, - 0x45, 0x44, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x41, 0x50, 0x49, 0x5f, 0x4f, 0x50, 0x45, 0x4e, - 0x10, 0x01, 0x12, 0x0e, 0x0a, 0x0a, 0x41, 0x50, 0x49, 0x5f, 0x48, 0x59, 0x42, 0x52, 0x49, 0x44, - 0x10, 0x02, 0x12, 0x0e, 0x0a, 0x0a, 0x41, 0x50, 0x49, 0x5f, 0x4f, 0x50, 0x41, 0x51, 0x55, 0x45, - 0x10, 0x03, 0x22, 0x92, 0x01, 0x0a, 0x0f, 0x53, 0x74, 0x72, 0x69, 0x70, 0x45, 0x6e, 0x75, 0x6d, - 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x12, 0x21, 0x0a, 0x1d, 0x53, 0x54, 0x52, 0x49, 0x50, 0x5f, - 0x45, 0x4e, 0x55, 0x4d, 0x5f, 0x50, 0x52, 0x45, 0x46, 0x49, 0x58, 0x5f, 0x55, 0x4e, 0x53, 0x50, - 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x1a, 0x0a, 0x16, 0x53, 0x54, 0x52, - 0x49, 0x50, 0x5f, 0x45, 0x4e, 0x55, 0x4d, 0x5f, 0x50, 0x52, 0x45, 0x46, 0x49, 0x58, 0x5f, 0x4b, - 0x45, 0x45, 0x50, 0x10, 0x01, 0x12, 0x23, 0x0a, 0x1f, 0x53, 0x54, 0x52, 0x49, 0x50, 0x5f, 0x45, - 0x4e, 0x55, 0x4d, 0x5f, 0x50, 0x52, 0x45, 0x46, 0x49, 0x58, 0x5f, 0x47, 0x45, 0x4e, 0x45, 0x52, - 0x41, 0x54, 0x45, 0x5f, 0x42, 0x4f, 0x54, 0x48, 0x10, 0x02, 0x12, 0x1b, 0x0a, 0x17, 0x53, 0x54, - 0x52, 0x49, 0x50, 0x5f, 0x45, 0x4e, 0x55, 0x4d, 0x5f, 0x50, 0x52, 0x45, 0x46, 0x49, 0x58, 0x5f, - 0x53, 0x54, 0x52, 0x49, 0x50, 0x10, 0x03, 0x3a, 0x3c, 0x0a, 0x02, 0x67, 0x6f, 0x12, 0x1b, 0x2e, - 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, - 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x53, 0x65, 0x74, 0x18, 0xea, 0x07, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x0e, 0x2e, 0x70, 0x62, 0x2e, 0x47, 0x6f, 0x46, 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x73, 0x52, 0x02, 0x67, 0x6f, 0x42, 0x2f, 0x5a, 0x2d, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, - 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x62, 0x75, 0x66, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x67, 0x6f, 0x66, 0x65, 0x61, 0x74, - 0x75, 0x72, 0x65, 0x73, 0x70, 0x62, -}) +const file_google_protobuf_go_features_proto_rawDesc = "" + + "\n" + + "!google/protobuf/go_features.proto\x12\x02pb\x1a google/protobuf/descriptor.proto\"\xab\x05\n" + + "\n" + + "GoFeatures\x12\xbe\x01\n" + + "\x1alegacy_unmarshal_json_enum\x18\x01 \x01(\bB\x80\x01\x88\x01\x01\x98\x01\x06\x98\x01\x01\xa2\x01\t\x12\x04true\x18\x84\a\xa2\x01\n" + + "\x12\x05false\x18\xe7\a\xb2\x01[\b\xe8\a\x10\xe8\a\x1aSThe legacy UnmarshalJSON API is deprecated and will be removed in a future edition.R\x17legacyUnmarshalJsonEnum\x12t\n" + + "\tapi_level\x18\x02 \x01(\x0e2\x17.pb.GoFeatures.APILevelB>\x88\x01\x01\x98\x01\x03\x98\x01\x01\xa2\x01\x1a\x12\x15API_LEVEL_UNSPECIFIED\x18\x84\a\xa2\x01\x0f\x12\n" + + "API_OPAQUE\x18\xe9\a\xb2\x01\x03\b\xe8\aR\bapiLevel\x12|\n" + + "\x11strip_enum_prefix\x18\x03 \x01(\x0e2\x1e.pb.GoFeatures.StripEnumPrefixB0\x88\x01\x01\x98\x01\x06\x98\x01\a\x98\x01\x01\xa2\x01\x1b\x12\x16STRIP_ENUM_PREFIX_KEEP\x18\x84\a\xb2\x01\x03\b\xe9\aR\x0fstripEnumPrefix\"S\n" + + "\bAPILevel\x12\x19\n" + + "\x15API_LEVEL_UNSPECIFIED\x10\x00\x12\f\n" + + "\bAPI_OPEN\x10\x01\x12\x0e\n" + + "\n" + + "API_HYBRID\x10\x02\x12\x0e\n" + + "\n" + + "API_OPAQUE\x10\x03\"\x92\x01\n" + + "\x0fStripEnumPrefix\x12!\n" + + "\x1dSTRIP_ENUM_PREFIX_UNSPECIFIED\x10\x00\x12\x1a\n" + + "\x16STRIP_ENUM_PREFIX_KEEP\x10\x01\x12#\n" + + "\x1fSTRIP_ENUM_PREFIX_GENERATE_BOTH\x10\x02\x12\x1b\n" + + "\x17STRIP_ENUM_PREFIX_STRIP\x10\x03:<\n" + + "\x02go\x12\x1b.google.protobuf.FeatureSet\x18\xea\a \x01(\v2\x0e.pb.GoFeaturesR\x02goB/Z-google.golang.org/protobuf/types/gofeaturespb" var ( file_google_protobuf_go_features_proto_rawDescOnce sync.Once diff --git a/vendor/google.golang.org/protobuf/types/known/anypb/any.pb.go b/vendor/google.golang.org/protobuf/types/known/anypb/any.pb.go index 497da66e..1ff0d149 100644 --- a/vendor/google.golang.org/protobuf/types/known/anypb/any.pb.go +++ b/vendor/google.golang.org/protobuf/types/known/anypb/any.pb.go @@ -412,23 +412,13 @@ func (x *Any) GetValue() []byte { var File_google_protobuf_any_proto protoreflect.FileDescriptor -var file_google_protobuf_any_proto_rawDesc = string([]byte{ - 0x0a, 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, 0x12, 0x0f, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x22, 0x36, 0x0a, 0x03, - 0x41, 0x6e, 0x79, 0x12, 0x19, 0x0a, 0x08, 0x74, 0x79, 0x70, 0x65, 0x5f, 0x75, 0x72, 0x6c, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x74, 0x79, 0x70, 0x65, 0x55, 0x72, 0x6c, 0x12, 0x14, - 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x42, 0x76, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, - 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x42, 0x08, 0x41, 0x6e, 0x79, - 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, - 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x62, 0x75, 0x66, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x2f, - 0x61, 0x6e, 0x79, 0x70, 0x62, 0xa2, 0x02, 0x03, 0x47, 0x50, 0x42, 0xaa, 0x02, 0x1e, 0x47, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x57, 0x65, - 0x6c, 0x6c, 0x4b, 0x6e, 0x6f, 0x77, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x73, 0x62, 0x06, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x33, -}) +const file_google_protobuf_any_proto_rawDesc = "" + + "\n" + + "\x19google/protobuf/any.proto\x12\x0fgoogle.protobuf\"6\n" + + "\x03Any\x12\x19\n" + + "\btype_url\x18\x01 \x01(\tR\atypeUrl\x12\x14\n" + + "\x05value\x18\x02 \x01(\fR\x05valueBv\n" + + "\x13com.google.protobufB\bAnyProtoP\x01Z,google.golang.org/protobuf/types/known/anypb\xa2\x02\x03GPB\xaa\x02\x1eGoogle.Protobuf.WellKnownTypesb\x06proto3" var ( file_google_protobuf_any_proto_rawDescOnce sync.Once diff --git a/vendor/google.golang.org/protobuf/types/known/durationpb/duration.pb.go b/vendor/google.golang.org/protobuf/types/known/durationpb/duration.pb.go index 193880d1..ca2e7b38 100644 --- a/vendor/google.golang.org/protobuf/types/known/durationpb/duration.pb.go +++ b/vendor/google.golang.org/protobuf/types/known/durationpb/duration.pb.go @@ -289,24 +289,13 @@ func (x *Duration) GetNanos() int32 { var File_google_protobuf_duration_proto protoreflect.FileDescriptor -var file_google_protobuf_duration_proto_rawDesc = string([]byte{ - 0x0a, 0x1e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2f, 0x64, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x12, 0x0f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x22, 0x3a, 0x0a, 0x08, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x18, 0x0a, - 0x07, 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, - 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x6e, 0x61, 0x6e, 0x6f, 0x73, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6e, 0x61, 0x6e, 0x6f, 0x73, 0x42, 0x83, 0x01, - 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x62, 0x75, 0x66, 0x42, 0x0d, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x50, - 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x31, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x67, - 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x2f, 0x64, - 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x70, 0x62, 0xf8, 0x01, 0x01, 0xa2, 0x02, 0x03, 0x47, - 0x50, 0x42, 0xaa, 0x02, 0x1e, 0x47, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x50, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x57, 0x65, 0x6c, 0x6c, 0x4b, 0x6e, 0x6f, 0x77, 0x6e, 0x54, 0x79, - 0x70, 0x65, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, -}) +const file_google_protobuf_duration_proto_rawDesc = "" + + "\n" + + "\x1egoogle/protobuf/duration.proto\x12\x0fgoogle.protobuf\":\n" + + "\bDuration\x12\x18\n" + + "\aseconds\x18\x01 \x01(\x03R\aseconds\x12\x14\n" + + "\x05nanos\x18\x02 \x01(\x05R\x05nanosB\x83\x01\n" + + "\x13com.google.protobufB\rDurationProtoP\x01Z1google.golang.org/protobuf/types/known/durationpb\xf8\x01\x01\xa2\x02\x03GPB\xaa\x02\x1eGoogle.Protobuf.WellKnownTypesb\x06proto3" var ( file_google_protobuf_duration_proto_rawDescOnce sync.Once diff --git a/vendor/google.golang.org/protobuf/types/known/emptypb/empty.pb.go b/vendor/google.golang.org/protobuf/types/known/emptypb/empty.pb.go index a5b8657c..1d7ee3b4 100644 --- a/vendor/google.golang.org/protobuf/types/known/emptypb/empty.pb.go +++ b/vendor/google.golang.org/protobuf/types/known/emptypb/empty.pb.go @@ -86,20 +86,12 @@ func (*Empty) Descriptor() ([]byte, []int) { var File_google_protobuf_empty_proto protoreflect.FileDescriptor -var file_google_protobuf_empty_proto_rawDesc = string([]byte{ - 0x0a, 0x1b, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2f, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0f, 0x67, - 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x22, 0x07, - 0x0a, 0x05, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x42, 0x7d, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x67, - 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x42, 0x0a, - 0x45, 0x6d, 0x70, 0x74, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x6b, - 0x6e, 0x6f, 0x77, 0x6e, 0x2f, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x70, 0x62, 0xf8, 0x01, 0x01, 0xa2, - 0x02, 0x03, 0x47, 0x50, 0x42, 0xaa, 0x02, 0x1e, 0x47, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x50, - 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x57, 0x65, 0x6c, 0x6c, 0x4b, 0x6e, 0x6f, 0x77, - 0x6e, 0x54, 0x79, 0x70, 0x65, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, -}) +const file_google_protobuf_empty_proto_rawDesc = "" + + "\n" + + "\x1bgoogle/protobuf/empty.proto\x12\x0fgoogle.protobuf\"\a\n" + + "\x05EmptyB}\n" + + "\x13com.google.protobufB\n" + + "EmptyProtoP\x01Z.google.golang.org/protobuf/types/known/emptypb\xf8\x01\x01\xa2\x02\x03GPB\xaa\x02\x1eGoogle.Protobuf.WellKnownTypesb\x06proto3" var ( file_google_protobuf_empty_proto_rawDescOnce sync.Once diff --git a/vendor/google.golang.org/protobuf/types/known/timestamppb/timestamp.pb.go b/vendor/google.golang.org/protobuf/types/known/timestamppb/timestamp.pb.go index 00ac835c..06d584c1 100644 --- a/vendor/google.golang.org/protobuf/types/known/timestamppb/timestamp.pb.go +++ b/vendor/google.golang.org/protobuf/types/known/timestamppb/timestamp.pb.go @@ -298,24 +298,13 @@ func (x *Timestamp) GetNanos() int32 { var File_google_protobuf_timestamp_proto protoreflect.FileDescriptor -var file_google_protobuf_timestamp_proto_rawDesc = string([]byte{ - 0x0a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x12, 0x0f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x22, 0x3b, 0x0a, 0x09, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, - 0x18, 0x0a, 0x07, 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x07, 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x6e, 0x61, 0x6e, - 0x6f, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6e, 0x61, 0x6e, 0x6f, 0x73, 0x42, - 0x85, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x42, 0x0e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x32, 0x67, 0x6f, 0x6f, 0x67, 0x6c, - 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x6b, 0x6e, 0x6f, 0x77, - 0x6e, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x70, 0x62, 0xf8, 0x01, 0x01, - 0xa2, 0x02, 0x03, 0x47, 0x50, 0x42, 0xaa, 0x02, 0x1e, 0x47, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, - 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x57, 0x65, 0x6c, 0x6c, 0x4b, 0x6e, 0x6f, - 0x77, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, -}) +const file_google_protobuf_timestamp_proto_rawDesc = "" + + "\n" + + "\x1fgoogle/protobuf/timestamp.proto\x12\x0fgoogle.protobuf\";\n" + + "\tTimestamp\x12\x18\n" + + "\aseconds\x18\x01 \x01(\x03R\aseconds\x12\x14\n" + + "\x05nanos\x18\x02 \x01(\x05R\x05nanosB\x85\x01\n" + + "\x13com.google.protobufB\x0eTimestampProtoP\x01Z2google.golang.org/protobuf/types/known/timestamppb\xf8\x01\x01\xa2\x02\x03GPB\xaa\x02\x1eGoogle.Protobuf.WellKnownTypesb\x06proto3" var ( file_google_protobuf_timestamp_proto_rawDescOnce sync.Once diff --git a/vendor/modules.txt b/vendor/modules.txt index c6415366..01b66fcf 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -40,7 +40,7 @@ github.com/alecthomas/template/parse # github.com/alecthomas/units v0.0.0-20240626203959-61d1e3462e30 ## explicit; go 1.15 github.com/alecthomas/units -# github.com/bits-and-blooms/bitset v1.13.0 +# github.com/bits-and-blooms/bitset v1.14.3 ## explicit; go 1.16 github.com/bits-and-blooms/bitset # github.com/consensys/bavard v0.1.13 @@ -97,14 +97,14 @@ github.com/google/go-cmp/cmp/internal/diff github.com/google/go-cmp/cmp/internal/flags github.com/google/go-cmp/cmp/internal/function github.com/google/go-cmp/cmp/internal/value -# github.com/google/pprof v0.0.0-20240827171923-fa2c70bbbfe5 +# github.com/google/pprof v0.0.0-20241001023024-f4c0cfd0cf1d ## explicit; go 1.22 github.com/google/pprof/profile # github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 ## explicit; go 1.14 github.com/grpc-ecosystem/go-grpc-middleware -# github.com/hyperledger-labs/SmartBFT v0.0.0-20240916013553-852e5be5889b -## explicit; go 1.22 +# github.com/hyperledger-labs/SmartBFT v0.0.0-20250503203013-eb005eef8866 +## explicit; go 1.24.2 github.com/hyperledger-labs/SmartBFT/internal/bft github.com/hyperledger-labs/SmartBFT/pkg/api github.com/hyperledger-labs/SmartBFT/pkg/consensus @@ -116,8 +116,8 @@ github.com/hyperledger-labs/SmartBFT/smartbftprotos # github.com/hyperledger/aries-bbs-go v0.0.0-20240528084656-761671ea73bc ## explicit; go 1.20 github.com/hyperledger/aries-bbs-go/bbs -# github.com/hyperledger/fabric v1.4.0-rc1.0.20240918034325-94590aa4332b -## explicit; go 1.23.1 +# github.com/hyperledger/fabric v1.4.0-rc1.0.20250510200036-435a7f1a780a +## explicit; go 1.24.2 github.com/hyperledger/fabric/common/capabilities github.com/hyperledger/fabric/common/cauthdsl github.com/hyperledger/fabric/common/channelconfig @@ -168,8 +168,8 @@ github.com/hyperledger/fabric-lib-go/common/flogging/fabenc github.com/hyperledger/fabric-lib-go/common/metrics github.com/hyperledger/fabric-lib-go/common/metrics/disabled github.com/hyperledger/fabric-lib-go/common/metrics/metricsfakes -# github.com/hyperledger/fabric-protos-go-apiv2 v0.3.3 -## explicit; go 1.17 +# github.com/hyperledger/fabric-protos-go-apiv2 v0.3.7 +## explicit; go 1.22.0 github.com/hyperledger/fabric-protos-go-apiv2/common github.com/hyperledger/fabric-protos-go-apiv2/ledger/rwset github.com/hyperledger/fabric-protos-go-apiv2/ledger/rwset/kvrwset @@ -311,9 +311,10 @@ github.com/spf13/viper/internal/features # github.com/stretchr/objx v0.5.2 ## explicit; go 1.20 github.com/stretchr/objx -# github.com/stretchr/testify v1.9.0 +# github.com/stretchr/testify v1.10.0 ## explicit; go 1.17 github.com/stretchr/testify/assert +github.com/stretchr/testify/assert/yaml github.com/stretchr/testify/mock github.com/stretchr/testify/require # github.com/subosito/gotenv v1.6.0 @@ -322,7 +323,7 @@ github.com/subosito/gotenv # github.com/sykesm/zap-logfmt v0.0.4 ## explicit; go 1.13 github.com/sykesm/zap-logfmt -# github.com/syndtr/goleveldb v1.0.1-0.20210305035536-64b5b1c73954 +# github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d ## explicit; go 1.14 github.com/syndtr/goleveldb/leveldb github.com/syndtr/goleveldb/leveldb/cache @@ -351,12 +352,12 @@ go.uber.org/zap/internal/pool go.uber.org/zap/internal/stacktrace go.uber.org/zap/zapcore go.uber.org/zap/zapgrpc -# golang.org/x/crypto v0.36.0 +# golang.org/x/crypto v0.37.0 ## explicit; go 1.23.0 golang.org/x/crypto/blake2b golang.org/x/crypto/hkdf golang.org/x/crypto/sha3 -# golang.org/x/net v0.38.0 +# golang.org/x/net v0.39.0 ## explicit; go 1.23.0 golang.org/x/net/context golang.org/x/net/html @@ -369,16 +370,16 @@ golang.org/x/net/idna golang.org/x/net/internal/httpcommon golang.org/x/net/internal/timeseries golang.org/x/net/trace -# golang.org/x/sync v0.12.0 +# golang.org/x/sync v0.13.0 ## explicit; go 1.23.0 golang.org/x/sync/errgroup golang.org/x/sync/semaphore -# golang.org/x/sys v0.31.0 +# golang.org/x/sys v0.32.0 ## explicit; go 1.23.0 golang.org/x/sys/cpu golang.org/x/sys/unix golang.org/x/sys/windows -# golang.org/x/text v0.23.0 +# golang.org/x/text v0.24.0 ## explicit; go 1.23.0 golang.org/x/text/encoding golang.org/x/text/encoding/charmap @@ -400,8 +401,8 @@ golang.org/x/text/secure/bidirule golang.org/x/text/transform golang.org/x/text/unicode/bidi golang.org/x/text/unicode/norm -# golang.org/x/tools v0.24.0 -## explicit; go 1.19 +# golang.org/x/tools v0.26.0 +## explicit; go 1.22.0 golang.org/x/tools/cover golang.org/x/tools/go/ast/inspector # google.golang.org/genproto/googleapis/rpc v0.0.0-20250218202821-56aae31c358a @@ -471,8 +472,8 @@ google.golang.org/grpc/serviceconfig google.golang.org/grpc/stats google.golang.org/grpc/status google.golang.org/grpc/tap -# google.golang.org/protobuf v1.36.5 -## explicit; go 1.21 +# google.golang.org/protobuf v1.36.6 +## explicit; go 1.22 google.golang.org/protobuf/encoding/protojson google.golang.org/protobuf/encoding/prototext google.golang.org/protobuf/encoding/protowire