VOL-1460 Updated core to use voltha-protos instead of local protos
Moved protos to python directory in order to maintain functionaly of containers built there.
Added capability to do local builds of protos
Added instructions on running dep ensure for getting protos.
Updated github.com/golang/protobuf version to v1.3.1
Change-Id: Ia6ef55f07f0d5dcb5b750d7c37b21b71db85bfc4
diff --git a/.gitignore b/.gitignore
index 2843ab3..ac6a1af 100644
--- a/.gitignore
+++ b/.gitignore
@@ -54,11 +54,10 @@
**/*.pdf
# Vagrant logfile
-*.log
-
-# Files copied over during make
-python/protos/*.proto
+*.logo
# voltha cli history
python/cli/.voltha_cli_history
+#voltha-protos dependency
+vendor/github.com/opencord/voltha-protos
diff --git a/BUILD.md b/BUILD.md
index 2607e4f..26ae9b0 100644
--- a/BUILD.md
+++ b/BUILD.md
@@ -33,10 +33,21 @@
### Installing Voltha dependencies
+Install dep for fetching go protos
+
```
+mkdir -p $GOPATH/bin
+curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
+```
+
+Pull dependencies for the project
+
+```
+cd $GOPATH/src/github.com/opencord/voltha-go/
+dep ensure
+
go get -u google.golang.org/grpc # gRPC
go get -u github.com/golang-collections/go-datastructures/queue
-go get -u github.com/golang/protobuf/protoc-gen-go # protoc plugin for Go
go get -u github.com/grpc-ecosystem/grpc-gateway/protoc-gen-grpc-gateway
go get -u github.com/gogo/protobuf/proto # Clone function
go get -u go.uber.org/zap # logger
@@ -45,8 +56,7 @@
go get -u github.com/google/uuid
go get -u github.com/cevaris/ordered_map
go get -u github.com/gyuho/goraph
-go get -u go.etcd.io/etcd # etcd client
-go install ./vendor/github.com/golang/protobuf/protoc-gen-go
+go get -u go.etcd.io/etcd # etcd client
git clone https://github.com/googleapis/googleapis.git /usr/local/include/googleapis
```
diff --git a/Gopkg.lock b/Gopkg.lock
index ae91607..a961e9a 100644
--- a/Gopkg.lock
+++ b/Gopkg.lock
@@ -1,18 +1,3 @@
-#
-# Copyright 2019-present Open Networking Foundation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
# This file is autogenerated, do not edit; changes may be undone by the next 'dep ensure'.
@@ -25,12 +10,12 @@
version = "v1.3.5"
[[projects]]
- digest = "1:28917d5a3f5e53a4c8a4035195c022649c66a4d71d6357a2276cd347945bd527"
+ digest = "1:82a18170c9c41e36939cb5d26da1546b2cfa786aa030a978d3bf183519849230"
name = "github.com/Shopify/sarama"
packages = ["."]
pruneopts = "UT"
- revision = "03a43f93cd29dc549e6d9b11892795c206f9c38c"
- version = "v1.20.1"
+ revision = "4602b5a8c6e826f9e0737865818dd43b2339a092"
+ version = "v1.21.0"
[[projects]]
branch = "master"
@@ -50,19 +35,19 @@
[[projects]]
branch = "master"
- digest = "1:78097abc20f73ec968b3f67bf74deda55009caa4b801d0d04f36145c869ab3c3"
+ digest = "1:9d61b5ca59d3db0b1f1c1e9f5930b4f7c7fd954f54b70c1d83802b8805db918f"
name = "github.com/cevaris/ordered_map"
packages = ["."]
pruneopts = "UT"
- revision = "0efaee1733e3399a3cb88fc7d2ce340bf2e863d7"
+ revision = "3adeae072e730f1919a936e13b4923706d3f60fe"
[[projects]]
- digest = "1:5c1e58f68ac83cf9c05c6c6748cd91b830dd94be9d2e6480add3c6524bb86b68"
+ digest = "1:bcf36df8d43860bfde913d008301aef27c6e9a303582118a837c4a34c0d18167"
name = "github.com/coreos/go-systemd"
packages = ["journal"]
pruneopts = "UT"
- revision = "9002847aa1425fb6ac49077c0a630b3b67e0fbfd"
- version = "v18"
+ revision = "95778dfbb74eb7e4dbaf43bf7d71809650ef8076"
+ version = "v19"
[[projects]]
digest = "1:39ff4d4d6baca1ac63c6a03404b761d664be14a71bb5a4aca8fef643d0f66fef"
@@ -126,7 +111,7 @@
revision = "59788d5eb2591d3497ffb8fafed2f16fe00e7775"
[[projects]]
- digest = "1:d0f384a62cb855617be65bf8fbad8b9133965955537b950b03e67993ee5fcae3"
+ digest = "1:c33a34578570e05f7aab50030acfbeee2d95ee7690bfb803a08bbd9a7b820e4e"
name = "github.com/golang/protobuf"
packages = [
"descriptor",
@@ -144,8 +129,8 @@
"ptypes/timestamp",
]
pruneopts = "UT"
- revision = "aa810b61a9c79d51363740d207bb46cf8e620ed5"
- version = "v1.2.0"
+ revision = "b5d812f8a3706043e23a9cd5babf2e5423744d30"
+ version = "v1.3.1"
[[projects]]
digest = "1:e4f5819333ac698d294fe04dbf640f84719658d5c7ce195b10060cc37292ce79"
@@ -156,12 +141,12 @@
version = "v0.0.1"
[[projects]]
- branch = "master"
digest = "1:0bfbe13936953a98ae3cfe8ed6670d396ad81edf069a806d2f6515d7bb6950df"
name = "github.com/google/btree"
packages = ["."]
pruneopts = "UT"
revision = "4030bb1f1f0c35b30ca7009e9ebd06849dd45306"
+ version = "v1.0.0"
[[projects]]
branch = "master"
@@ -172,12 +157,12 @@
revision = "24818f796faf91cd76ec7bddd72458fbced7a6c1"
[[projects]]
- digest = "1:236d7e1bdb50d8f68559af37dbcf9d142d56b431c9b2176d41e2a009b664cda8"
+ digest = "1:582b704bebaa06b48c29b0cec224a6058a09c86883aaddabde889cd1a5f73e1b"
name = "github.com/google/uuid"
packages = ["."]
pruneopts = "UT"
- revision = "9b3b1e0f5f99ae461456d768e7d301a7acdaa2d8"
- version = "v1.1.0"
+ revision = "0cd6bf5da1e1c83f8b45653022c74f71af0538a4"
+ version = "v1.1.1"
[[projects]]
digest = "1:65c4414eeb350c47b8de71110150d0ea8a281835b1f386eacaa3ad7325929c21"
@@ -211,20 +196,20 @@
version = "v2.0"
[[projects]]
- digest = "1:1b9c99915ccf7df1e6085259ebf137a7b11fab87f47c382b3ec7a7ab51fbe2d8"
+ digest = "1:9537873f2fc92467f451178506405fae087efc624d8d92644042209a03a2bfa0"
name = "github.com/hashicorp/consul"
packages = ["api"]
pruneopts = "UT"
- revision = "c97c712e96e0e53308054d5e1180289fe02dce38"
- version = "v1.4.2"
+ revision = "ea5210a30e154f4da9a4c8e729b45b8ce7b9b92c"
+ version = "v1.4.4"
[[projects]]
- digest = "1:f47d6109c2034cb16bd62b220e18afd5aa9d5a1630fe5d937ad96a4fb7cbb277"
+ digest = "1:af105c7c5dc0b4ae41991f122cae860b9600f7d226072c2a83127048c991660c"
name = "github.com/hashicorp/go-cleanhttp"
packages = ["."]
pruneopts = "UT"
- revision = "e8ab9daed8d1ddd2d3c4efba338fe2eeae2e4f18"
- version = "v0.5.0"
+ revision = "eda1e5db218aad1db63ca4642c8906b26bcf2744"
+ version = "v0.5.1"
[[projects]]
digest = "1:2be5a35f0c5b35162c41bb24971e5dcf6ce825403296ee435429cdcc4e1e847e"
@@ -247,8 +232,8 @@
name = "github.com/hashicorp/golang-lru"
packages = ["simplelru"]
pruneopts = "UT"
- revision = "20f1fb78b0740ba8c3cb143a61e86ba5c8669768"
- version = "v0.5.0"
+ revision = "7087cb70de9f7a8bc0a10c375cb0d2280a8edf9c"
+ version = "v0.5.1"
[[projects]]
digest = "1:acc81e4e4289587b257ccdfccbc6eaf16d4c2fb57dda73c6bb349bf50f02501f"
@@ -259,12 +244,12 @@
version = "v0.8.2"
[[projects]]
- digest = "1:3e551bbb3a7c0ab2a2bf4660e7fcad16db089fdcfbb44b0199e62838038623ea"
+ digest = "1:f5a2051c55d05548d2d4fd23d244027b59fbd943217df8aa3b5e170ac2fd6e1b"
name = "github.com/json-iterator/go"
packages = ["."]
pruneopts = "UT"
- revision = "1624edc4454b8682399def8740d46db5e4362ba4"
- version = "v1.1.5"
+ revision = "0ff49de124c6f76f8494e194af75bde0f1a49a29"
+ version = "v1.1.6"
[[projects]]
digest = "1:5d231480e1c64a726869bc4142d270184c419749d34f167646baa21008eb0a79"
@@ -300,6 +285,21 @@
[[projects]]
branch = "master"
+ digest = "1:006dac2df928fdba2ef90eef18eaa0077c26d2a0657e5581ea4c5d19083d78ea"
+ name = "github.com/opencord/voltha-protos"
+ packages = [
+ "go/afrouter",
+ "go/common",
+ "go/inter_container",
+ "go/omci",
+ "go/openflow_13",
+ "go/voltha",
+ ]
+ pruneopts = "T"
+ revision = "ad7456523decde24e81d283286ad97ed2f1d94d0"
+
+[[projects]]
+ branch = "master"
digest = "1:3bf17a6e6eaa6ad24152148a631d18662f7212e21637c2699bff3369b7f00fa2"
name = "github.com/petar/GoLLRB"
packages = ["llrb"]
@@ -315,15 +315,15 @@
version = "v2.0.1"
[[projects]]
- digest = "1:c7a5e79396b6eb570159df7a1d487ce5775bf43b7907976fbef6de544ea160ad"
+ digest = "1:d4c88b5ad20151a96c1e5a55547a944b6af623aa315f69ee0d172b00f95d27fb"
name = "github.com/pierrec/lz4"
packages = [
".",
"internal/xxh32",
]
pruneopts = "UT"
- revision = "473cd7ce01a1113208073166464b98819526150e"
- version = "v2.0.8"
+ revision = "062282ea0dcff40c9fb8525789eef9644b1fbd6e"
+ version = "v2.1.0"
[[projects]]
digest = "1:0028cb19b2e4c3112225cd871870f2d9cf49b9b4276531f03438a88e94be86fe"
@@ -351,7 +351,7 @@
[[projects]]
branch = "master"
- digest = "1:abdce0add127cb0ec1110f0620f4ae965d48b0f77b34d29a2a3e02c42571c435"
+ digest = "1:54b6573c932c76eb84e3e2e2bd5c57e2ae43e3bc728a95c7fdabbb512c09b273"
name = "go.etcd.io/etcd"
packages = [
"auth/authpb",
@@ -370,7 +370,7 @@
"raft/raftpb",
]
pruneopts = "UT"
- revision = "a7e3bd06b2ef0286e1571836997287a81146c25a"
+ revision = "7a5acb4a43aa06bd9e32ab59a46271ab88d497e4"
[[projects]]
digest = "1:3c1a69cdae3501bf75e76d0d86dc6f2b0a7421bc205c0cb7b96b19eed464a34d"
@@ -405,15 +405,15 @@
[[projects]]
branch = "master"
- digest = "1:fde12c4da6237363bf36b81b59aa36a43d28061167ec4acb0d41fc49464e28b9"
+ digest = "1:058e9504b9a79bfe86092974d05bb3298d2aa0c312d266d43148de289a5065d9"
name = "golang.org/x/crypto"
packages = ["ssh/terminal"]
pruneopts = "UT"
- revision = "a4c6cb3142f211c99e4bf4cd769535b29a9b616f"
+ revision = "b7391e95e576cacdcdd422573063bc057239113d"
[[projects]]
branch = "master"
- digest = "1:9d2f08c64693fbe7177b5980f80c35672c80f12be79bb3bc86948b934d70e4ee"
+ digest = "1:5b51b81e299d0dfd03f567fd8d8a2d7ee954b3b72c69292f07c49aae785b6dd9"
name = "golang.org/x/net"
packages = [
"context",
@@ -426,29 +426,29 @@
"trace",
]
pruneopts = "UT"
- revision = "3a22650c66bd7f4fb6d1e8072ffd7b75c8a27898"
+ revision = "addf6b3196f61cd44ce5a76657913698c73479d0"
[[projects]]
branch = "master"
- digest = "1:53bc3c7758c9e20dd5b53c4db7d982fec731443319d98c804794675272950c79"
+ digest = "1:9927d6aceb89d188e21485f42a7a254e67e6fdcf4260aba375fe18e3c300dfb4"
name = "golang.org/x/oauth2"
packages = [
".",
"internal",
]
pruneopts = "UT"
- revision = "9b3c75971fc92dd27c6436a37c05c831498658f1"
+ revision = "c85d3e98c914e3a33234ad863dcbff5dbc425bb8"
[[projects]]
branch = "master"
- digest = "1:560aa660b6f65b334a3c13534ec067e3a4f8aad617d2c1fbb53f1494a90feaf8"
+ digest = "1:6b3e6ddcebac95be1d690dbd53b5aa2e520715becb7e521bb526ccf3b4c53c15"
name = "golang.org/x/sys"
packages = [
"unix",
"windows",
]
pruneopts = "UT"
- revision = "a9d3bda3a223baa6bba6ef412cb273f0fd163c05"
+ revision = "f49334f85ddcf0f08d7fb6dd7363e9e6d6b777eb"
[[projects]]
digest = "1:a2ab62866c75542dd18d2b069fec854577a20211d7c0ea6ae746072a1dccdd18"
@@ -479,10 +479,10 @@
name = "golang.org/x/time"
packages = ["rate"]
pruneopts = "UT"
- revision = "85acf8d2951cb2a3bde7632f9ff273ef0379bcbd"
+ revision = "9d24e82272b4f38b78bc8cff74fa936d31ccd8ef"
[[projects]]
- digest = "1:6f3bd49ddf2e104e52062774d797714371fac1b8bddfd8e124ce78e6b2264a10"
+ digest = "1:6eb6e3b6d9fffb62958cf7f7d88dbbe1dd6839436b0802e194c590667a40412a"
name = "google.golang.org/appengine"
packages = [
"internal",
@@ -494,19 +494,22 @@
"urlfetch",
]
pruneopts = "UT"
- revision = "e9657d882bb81064595ca3b56cbe2546bbabf7b1"
- version = "v1.4.0"
+ revision = "54a98f90d1c46b7731eb8fb305d2a321c30ef610"
+ version = "v1.5.0"
[[projects]]
branch = "master"
- digest = "1:077c1c599507b3b3e9156d17d36e1e61928ee9b53a5b420f10f28ebd4a0b275c"
+ digest = "1:08aea4eff69cb424f2ce0d69f88c2f0d351fc44e82cab057ddf3946f41f02108"
name = "google.golang.org/genproto"
- packages = ["googleapis/rpc/status"]
+ packages = [
+ "googleapis/api/annotations",
+ "googleapis/rpc/status",
+ ]
pruneopts = "UT"
- revision = "082222b4a5c572e33e82ee9162d1352c7cf38682"
+ revision = "e79c0c59cdb5e117ef82a6f885294df3d74065d5"
[[projects]]
- digest = "1:6dfe7f3314a390dc9e21368dd41236169bf40ae69674f42b7bd45db537751a94"
+ digest = "1:a0bdff6a1dd68e7fa6edbffe3bef8e061db79543975d1c53afcae3a8d8a6c445"
name = "google.golang.org/grpc"
packages = [
".",
@@ -543,16 +546,16 @@
"tap",
]
pruneopts = "UT"
- revision = "a02b0774206b209466313a0b525d2c738fe407eb"
- version = "v1.18.0"
+ revision = "3507fb8e1a5ad030303c106fef3a47c9fdad16ad"
+ version = "v1.19.1"
[[projects]]
- digest = "1:28917d5a3f5e53a4c8a4035195c022649c66a4d71d6357a2276cd347945bd527"
+ digest = "1:82a18170c9c41e36939cb5d26da1546b2cfa786aa030a978d3bf183519849230"
name = "gopkg.in/Shopify/sarama.v1"
packages = ["."]
pruneopts = "UT"
- revision = "03a43f93cd29dc549e6d9b11892795c206f9c38c"
- version = "v1.20.1"
+ revision = "4602b5a8c6e826f9e0737865818dd43b2339a092"
+ version = "v1.21.0"
[[projects]]
digest = "1:2d1fbdc6777e5408cabeb02bf336305e724b925ff4546ded0fa8715a7267922a"
@@ -572,7 +575,7 @@
[[projects]]
branch = "release-1.13"
- digest = "1:0d299a04c6472e4458461d7034c76d014cc6f632a3262cbf21d123b19ce13e65"
+ digest = "1:6cec2c64c7569cd43b9fa5f8973f3a82919ebed36296d19312de057e59651b05"
name = "k8s.io/api"
packages = [
"admissionregistration/v1alpha1",
@@ -609,11 +612,11 @@
"storage/v1beta1",
]
pruneopts = "UT"
- revision = "a61488babbd64b32da2ed985e2e70fe7b4ffc05a"
+ revision = "5cb15d34447165a97c76ed5a60e4e99c8a01ecfe"
[[projects]]
branch = "master"
- digest = "1:97f690e88b67728656d37740d16daeaf0e22c0ecd8b0c7793747c3f156c40858"
+ digest = "1:8b968e0eeea43c17729fc2edc31acf4577d05efdfb51476ed3be3f810aae615d"
name = "k8s.io/apimachinery"
packages = [
"pkg/api/errors",
@@ -653,7 +656,7 @@
"third_party/forked/golang/reflect",
]
pruneopts = "UT"
- revision = "450d01ad5771972f60ff23d8f7c6df3211cffbcf"
+ revision = "6d73c65dcf6cffc0f66c0f037f6df2a99d20c542"
[[projects]]
digest = "1:67a85fd36cd1803b7421e6179e55e0b6668417ab338e20451cec0988f0762c63"
@@ -748,6 +751,12 @@
"github.com/google/uuid",
"github.com/gyuho/goraph",
"github.com/hashicorp/consul/api",
+ "github.com/opencord/voltha-protos/go/afrouter",
+ "github.com/opencord/voltha-protos/go/common",
+ "github.com/opencord/voltha-protos/go/inter_container",
+ "github.com/opencord/voltha-protos/go/omci",
+ "github.com/opencord/voltha-protos/go/openflow_13",
+ "github.com/opencord/voltha-protos/go/voltha",
"github.com/stretchr/testify/assert",
"go.etcd.io/etcd/clientv3",
"go.etcd.io/etcd/clientv3/concurrency",
@@ -755,6 +764,7 @@
"go.uber.org/zap",
"go.uber.org/zap/zapcore",
"golang.org/x/net/context",
+ "google.golang.org/genproto/googleapis/api/annotations",
"google.golang.org/grpc",
"google.golang.org/grpc/codes",
"google.golang.org/grpc/connectivity",
diff --git a/Gopkg.toml b/Gopkg.toml
index 65255b0..796ff2a 100644
--- a/Gopkg.toml
+++ b/Gopkg.toml
@@ -61,7 +61,7 @@
[[constraint]]
name = "github.com/golang/protobuf"
- version = "1.2.0"
+ version = "=1.3.1"
[[constraint]]
name = "github.com/google/uuid"
@@ -102,3 +102,7 @@
[prune]
go-tests = true
unused-packages = true
+
+ [[prune.project]]
+ name = "github.com/opencord/voltha-protos"
+ unused-packages = false
diff --git a/Makefile b/Makefile
index 97624e0..b0bf2be 100644
--- a/Makefile
+++ b/Makefile
@@ -84,6 +84,10 @@
containers: base rw_core ro_core simulated_olt simulated_onu afrouter arouterd
base:
+ifdef LOCAL_PROTOS
+ mkdir -p vendor/github.com/opencord/voltha-protos/go
+ cp -r ${GOPATH}/src/github.com/opencord/voltha-protos/go/ vendor/github.com/opencord/voltha-protos
+endif
docker build $(DOCKER_BUILD_ARGS) -t base:latest -f docker/Dockerfile.base .
afrouter:
diff --git a/adapters/common/adapter_proxy.go b/adapters/common/adapter_proxy.go
index 5e04484..13b98b0 100644
--- a/adapters/common/adapter_proxy.go
+++ b/adapters/common/adapter_proxy.go
@@ -23,7 +23,7 @@
"github.com/google/uuid"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
"time"
)
diff --git a/adapters/common/core_proxy.go b/adapters/common/core_proxy.go
index 3198111..137877f 100644
--- a/adapters/common/core_proxy.go
+++ b/adapters/common/core_proxy.go
@@ -21,8 +21,8 @@
a "github.com/golang/protobuf/ptypes/any"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
"sync"
diff --git a/adapters/common/request_handler.go b/adapters/common/request_handler.go
index 4d65d89..5b839c6 100644
--- a/adapters/common/request_handler.go
+++ b/adapters/common/request_handler.go
@@ -22,8 +22,8 @@
"github.com/opencord/voltha-go/adapters"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
)
diff --git a/adapters/iAdapter.go b/adapters/iAdapter.go
index d0463f1..a1dfa16 100644
--- a/adapters/iAdapter.go
+++ b/adapters/iAdapter.go
@@ -16,9 +16,9 @@
package adapters
import (
- ic "github.com/opencord/voltha-go/protos/inter_container"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
)
//IAdapter represents the set of APIs a voltha adapter has to support.
diff --git a/adapters/simulated_olt/adaptercore/device_handler.go b/adapters/simulated_olt/adaptercore/device_handler.go
index e7a86ac..9aaeea4 100644
--- a/adapters/simulated_olt/adaptercore/device_handler.go
+++ b/adapters/simulated_olt/adaptercore/device_handler.go
@@ -21,9 +21,9 @@
"github.com/gogo/protobuf/proto"
com "github.com/opencord/voltha-go/adapters/common"
"github.com/opencord/voltha-go/common/log"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- of "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ of "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"strconv"
"strings"
"sync"
diff --git a/adapters/simulated_olt/adaptercore/simulated_olt.go b/adapters/simulated_olt/adaptercore/simulated_olt.go
index 529b89d..bc70a82 100644
--- a/adapters/simulated_olt/adaptercore/simulated_olt.go
+++ b/adapters/simulated_olt/adaptercore/simulated_olt.go
@@ -22,9 +22,9 @@
com "github.com/opencord/voltha-go/adapters/common"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"sync"
)
diff --git a/adapters/simulated_olt/main.go b/adapters/simulated_olt/main.go
index ea6fb6c..4a18d10 100644
--- a/adapters/simulated_olt/main.go
+++ b/adapters/simulated_olt/main.go
@@ -26,8 +26,8 @@
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/kvstore"
"github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ "github.com/opencord/voltha-protos/go/voltha"
"os"
"os/signal"
"strconv"
diff --git a/adapters/simulated_onu/adaptercore/device_handler.go b/adapters/simulated_onu/adaptercore/device_handler.go
index aad0c86..2e3271c 100644
--- a/adapters/simulated_onu/adaptercore/device_handler.go
+++ b/adapters/simulated_onu/adaptercore/device_handler.go
@@ -21,9 +21,9 @@
"github.com/gogo/protobuf/proto"
com "github.com/opencord/voltha-go/adapters/common"
"github.com/opencord/voltha-go/common/log"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- of "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ of "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"strconv"
"strings"
"sync"
diff --git a/adapters/simulated_onu/adaptercore/simulated_onu.go b/adapters/simulated_onu/adaptercore/simulated_onu.go
index c10b844..f0b92d8 100644
--- a/adapters/simulated_onu/adaptercore/simulated_onu.go
+++ b/adapters/simulated_onu/adaptercore/simulated_onu.go
@@ -22,9 +22,9 @@
com "github.com/opencord/voltha-go/adapters/common"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"sync"
)
diff --git a/adapters/simulated_onu/main.go b/adapters/simulated_onu/main.go
index a5c18aa..7ea1430 100644
--- a/adapters/simulated_onu/main.go
+++ b/adapters/simulated_onu/main.go
@@ -26,8 +26,8 @@
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/kvstore"
"github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ "github.com/opencord/voltha-protos/go/voltha"
"os"
"os/signal"
"strconv"
diff --git a/afrouter/afrouter/api.go b/afrouter/afrouter/api.go
index 5766e8d..aec1221 100644
--- a/afrouter/afrouter/api.go
+++ b/afrouter/afrouter/api.go
@@ -26,7 +26,7 @@
"google.golang.org/grpc"
"golang.org/x/net/context"
"github.com/opencord/voltha-go/common/log"
- pb "github.com/opencord/voltha-go/protos/afrouter"
+ pb "github.com/opencord/voltha-protos/go/afrouter"
)
diff --git a/arouterd/arouterd.go b/arouterd/arouterd.go
index 68a7861..d8d7cff 100644
--- a/arouterd/arouterd.go
+++ b/arouterd/arouterd.go
@@ -31,10 +31,10 @@
kafka "github.com/opencord/voltha-go/kafka"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
empty "github.com/golang/protobuf/ptypes/empty"
- vpb "github.com/opencord/voltha-go/protos/voltha"
- cmn "github.com/opencord/voltha-go/protos/common"
- pb "github.com/opencord/voltha-go/protos/afrouter"
- ic "github.com/opencord/voltha-go/protos/inter_container"
+ vpb "github.com/opencord/voltha-protos/go/voltha"
+ cmn "github.com/opencord/voltha-protos/go/common"
+ pb "github.com/opencord/voltha-protos/go/afrouter"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
)
type configConn struct {
diff --git a/common/core/northbound/grpc/default_api_handler.go b/common/core/northbound/grpc/default_api_handler.go
index b6cd185..5f8148d 100644
--- a/common/core/northbound/grpc/default_api_handler.go
+++ b/common/core/northbound/grpc/default_api_handler.go
@@ -20,9 +20,9 @@
"errors"
"github.com/golang/protobuf/ptypes/empty"
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/common"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/common"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
)
type DefaultAPIHandler struct {
diff --git a/compose/openolt.yml b/compose/openolt.yml
index 6d74b70..915dbca 100644
--- a/compose/openolt.yml
+++ b/compose/openolt.yml
@@ -16,7 +16,7 @@
version: '2'
services:
openolt:
- image: "${REGISTRY}${REPOSITORY}voltha-openolt${TAG}"
+ image: "${REGISTRY}${REPOSITORY}voltha-adapter-openolt${TAG}"
logging:
driver: "json-file"
options:
diff --git a/db/model/base_test.go b/db/model/base_test.go
index 38f4567..9d8a1a9 100644
--- a/db/model/base_test.go
+++ b/db/model/base_test.go
@@ -17,7 +17,7 @@
import (
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"runtime/debug"
"sync"
)
diff --git a/db/model/child_type.go b/db/model/child_type.go
index 224da9f..da6f688 100644
--- a/db/model/child_type.go
+++ b/db/model/child_type.go
@@ -21,7 +21,7 @@
"github.com/golang/protobuf/proto"
"github.com/golang/protobuf/protoc-gen-go/descriptor"
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/common"
+ "github.com/opencord/voltha-protos/go/common"
"reflect"
"strconv"
"sync"
diff --git a/db/model/child_type_test.go b/db/model/child_type_test.go
index d604b76..349baa6 100644
--- a/db/model/child_type_test.go
+++ b/db/model/child_type_test.go
@@ -16,7 +16,7 @@
package model
import (
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"reflect"
"testing"
)
diff --git a/db/model/event_bus.go b/db/model/event_bus.go
index 71e0922..335d43f 100644
--- a/db/model/event_bus.go
+++ b/db/model/event_bus.go
@@ -20,7 +20,7 @@
"encoding/json"
"github.com/golang/protobuf/proto"
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
)
// EventBus contains the details required to communicate with the event bus mechanism
diff --git a/db/model/event_bus_client.go b/db/model/event_bus_client.go
index f038cad..c9c1314 100644
--- a/db/model/event_bus_client.go
+++ b/db/model/event_bus_client.go
@@ -18,7 +18,7 @@
import (
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
)
// EventBusClient is an abstraction layer structure to communicate with an event bus mechanism
diff --git a/db/model/node_test.go b/db/model/node_test.go
index d60cc44..240e918 100644
--- a/db/model/node_test.go
+++ b/db/model/node_test.go
@@ -19,9 +19,9 @@
"crypto/md5"
"fmt"
"github.com/golang/protobuf/ptypes/any"
- "github.com/opencord/voltha-go/protos/common"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/common"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"reflect"
"testing"
)
diff --git a/db/model/proxy_load_test.go b/db/model/proxy_load_test.go
index 23c95e2..47df98c 100644
--- a/db/model/proxy_load_test.go
+++ b/db/model/proxy_load_test.go
@@ -19,9 +19,9 @@
"encoding/hex"
"github.com/google/uuid"
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/common"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/common"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"math/rand"
"reflect"
"strconv"
diff --git a/db/model/proxy_test.go b/db/model/proxy_test.go
index 0180ce1..1e93243 100644
--- a/db/model/proxy_test.go
+++ b/db/model/proxy_test.go
@@ -20,9 +20,9 @@
"encoding/json"
"github.com/golang/protobuf/proto"
"github.com/google/uuid"
- "github.com/opencord/voltha-go/protos/common"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/common"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"math/rand"
"reflect"
"strconv"
diff --git a/db/model/transaction_test.go b/db/model/transaction_test.go
index 10ca520..b6e324e 100644
--- a/db/model/transaction_test.go
+++ b/db/model/transaction_test.go
@@ -19,8 +19,8 @@
import (
"encoding/hex"
"github.com/google/uuid"
- "github.com/opencord/voltha-go/protos/common"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/common"
+ "github.com/opencord/voltha-protos/go/voltha"
"strconv"
"testing"
)
diff --git a/docker/Dockerfile.arouter b/docker/Dockerfile.arouter
index b1769a1..329fc68 100644
--- a/docker/Dockerfile.arouter
+++ b/docker/Dockerfile.arouter
@@ -9,22 +9,18 @@
ADD db $GOPATH/src/github.com/opencord/voltha-go/db
ADD kafka $GOPATH/src/github.com/opencord/voltha-go/kafka
ADD afrouter $GOPATH/src/github.com/opencord/voltha-go/afrouter
+ADD vendor $GOPATH/src/github.com/opencord/voltha-go/vendor
# Copy required proto files
# ... VOLTHA proos
# Repeat here even if it's done in the base
-ADD protos/*.proto /src/protos/
-ADD protos/scripts/* /src/protos/
ADD afrouter/arouter.json /src
+COPY vendor/github.com/opencord/voltha-protos/go/voltha.pb /src
#
# Copy generated executables here
WORKDIR $GOPATH/src/github.com/opencord/voltha-go
-# Compile protobuf files
-# Repeat here even if it's done in the base
-RUN sh /src/protos/build_protos.sh /src/protos
-
# Build rw_core
RUN cd afrouter && go build -o /src/afrouter
@@ -39,7 +35,7 @@
# Copy required files
COPY --from=build-env /src/afrouter /app/
COPY --from=build-env /src/arouter.json /app/
-COPY --from=build-env /src/protos/voltha.pb /app/
+COPY --from=build-env /src/voltha.pb /app/
WORKDIR config
WORKDIR /app
diff --git a/docker/Dockerfile.arouterd b/docker/Dockerfile.arouterd
index 1755af1..f3c1dd3 100644
--- a/docker/Dockerfile.arouterd
+++ b/docker/Dockerfile.arouterd
@@ -13,11 +13,7 @@
ADD arouterd $GOPATH/src/github.com/opencord/voltha-go/arouterd
-# Copy required proto files
-# ... VOLTHA proos
# Repeate here even if done in base file
-ADD protos/*.proto /src/protos/
-ADD protos/scripts/* /src/protos/
ADD afrouter/arouter.json /src
#
@@ -27,7 +23,6 @@
# Compile protobuf files
# Repeate here even if done in base file
RUN go get google.golang.org/genproto/googleapis/api/annotations
-RUN sh /src/protos/build_protos.sh /src/protos
# Build rw_core
RUN cd arouterd && go build -o /src/arouterd
diff --git a/docker/Dockerfile.base b/docker/Dockerfile.base
index 3e6098c..1a22cd9 100644
--- a/docker/Dockerfile.base
+++ b/docker/Dockerfile.base
@@ -10,16 +10,11 @@
RUN git clone https://github.com/googleapis/googleapis.git /usr/local/include/googleapis
# Prepare directory structure
-RUN ["mkdir", "-p", "/src", "src/protos"]
+RUN ["mkdir", "-p", "/src"]
RUN ["mkdir", "-p", "$GOPATH/src", "$GOPATH/pkg", "$GOPATH/bin"]
-RUN ["mkdir", "-p", "$GOPATH/src/github.com/opencord/voltha/protos/go"]
+RUN ["mkdir", "-p", "$GOPATH/src/github.com/opencord/voltha-go"]
RUN ["mkdir", "-p", "/share"]
-# Install golang protobuf
-#RUN go get github.com/golang/protobuf/protoc-gen-go
-#RUN go get google.golang.org/genproto/googleapis/rpc/status
-#RUN go get google.golang.org/grpc/binarylog/grpc_binarylog_v1
-
# Copy files
#ADD rw_core $GOPATH/src/github.com/opencord/voltha-go/rw_core
#ADD common $GOPATH/src/github.com/opencord/voltha-go/common
@@ -28,11 +23,6 @@
ADD vendor $GOPATH/src/github.com/opencord/voltha-go/vendor
#ADD afrouter $GOPATH/src/github.com/opencord/voltha-go/afrouter
-
-# Copy required proto files
-# ... VOLTHA proos
-ADD protos/*.proto /src/protos/
-ADD protos/scripts/* /src/protos/
ADD afrouter/arouter.json /src
#
@@ -41,13 +31,4 @@
#RUN ls -ltrR /go/src/github.com/opencord/voltha-go
-# Install golang protobuf
-#RUN go get github.com/golang/protobuf/protoc-gen-go
-#RUN go get google.golang.org/genproto/googleapis/rpc/status
-#RUN go get google.golang.org/grpc/binarylog/grpc_binarylog_v1
-RUN go install ./vendor/github.com/golang/protobuf/protoc-gen-go
-
-# Compile protobuf files
-RUN sh /src/protos/build_protos.sh /src/protos
-
VOLUME /share
diff --git a/docker/Dockerfile.ro_core b/docker/Dockerfile.ro_core
index c7c6a70..0784f9a 100644
--- a/docker/Dockerfile.ro_core
+++ b/docker/Dockerfile.ro_core
@@ -11,9 +11,9 @@
RUN go get google.golang.org/genproto/googleapis/api/annotations
# Prepare directory structure
-RUN ["mkdir", "-p", "/src", "src/protos"]
+RUN ["mkdir", "-p", "/src"]
RUN ["mkdir", "-p", "$GOPATH/src", "$GOPATH/pkg", "$GOPATH/bin"]
-RUN ["mkdir", "-p", "$GOPATH/src/github.com/opencord/voltha/protos/go"]
+RUN ["mkdir", "-p", "$GOPATH/src/github.com/opencord/voltha-go"]
WORKDIR $GOPATH/src/github.com/opencord/voltha-go
@@ -24,17 +24,6 @@
ADD kafka ./kafka
ADD vendor ./vendor
-# Install the protoc-gen-go
-RUN go install ./vendor/github.com/golang/protobuf/protoc-gen-go
-
-# Copy required proto files
-# ... VOLTHA proos
-ADD protos/*.proto /src/protos/
-ADD protos/scripts/* /src/protos/
-
-# Compile protobuf files
-RUN sh /src/protos/build_protos.sh /src/protos
-
# Build ro_core
RUN cd ro_core && go build -o /src/ro_core
diff --git a/docker/Dockerfile.rw_core b/docker/Dockerfile.rw_core
index 714ead7..8081beb 100644
--- a/docker/Dockerfile.rw_core
+++ b/docker/Dockerfile.rw_core
@@ -11,9 +11,9 @@
RUN go get google.golang.org/genproto/googleapis/api/annotations
# Prepare directory structure
-RUN ["mkdir", "-p", "/src", "src/protos"]
+RUN ["mkdir", "-p", "/src"]
RUN ["mkdir", "-p", "$GOPATH/src", "$GOPATH/pkg", "$GOPATH/bin"]
-RUN ["mkdir", "-p", "$GOPATH/src/github.com/opencord/voltha/protos/go"]
+RUN ["mkdir", "-p", "$GOPATH/src/github.com/opencord/voltha-go"]
WORKDIR $GOPATH/src/github.com/opencord/voltha-go
@@ -24,17 +24,6 @@
ADD kafka ./kafka
ADD vendor ./vendor
-# Install the protoc-gen-go
-RUN go install ./vendor/github.com/golang/protobuf/protoc-gen-go
-
-# Copy required proto files
-# ... VOLTHA proos
-ADD protos/*.proto /src/protos/
-ADD protos/scripts/* /src/protos/
-
-# Compile protobuf files
-RUN sh /src/protos/build_protos.sh /src/protos
-
# Build rw_core
RUN cd rw_core && go build -o /src/rw_core
diff --git a/docker/Dockerfile.simulated_olt b/docker/Dockerfile.simulated_olt
index 6513c0e..d9251b0 100644
--- a/docker/Dockerfile.simulated_olt
+++ b/docker/Dockerfile.simulated_olt
@@ -11,9 +11,9 @@
RUN go get google.golang.org/genproto/googleapis/api/annotations
# Prepare directory structure
-RUN ["mkdir", "-p", "/src", "src/protos"]
+RUN ["mkdir", "-p", "/src"]
RUN ["mkdir", "-p", "$GOPATH/src", "$GOPATH/pkg", "$GOPATH/bin"]
-RUN ["mkdir", "-p", "$GOPATH/src/github.com/opencord/voltha/protos/go"]
+RUN ["mkdir", "-p", "$GOPATH/src/github.com/opencord/voltha-go"]
WORKDIR $GOPATH/src/github.com/opencord/voltha-go
@@ -26,17 +26,6 @@
ADD kafka ./kafka
ADD vendor ./vendor
-# Install the protoc-gen-go
-RUN go install ./vendor/github.com/golang/protobuf/protoc-gen-go
-
-# Copy required proto files
-# ... VOLTHA proos
-ADD protos/*.proto /src/protos/
-ADD protos/scripts/* /src/protos/
-
-# Compile protobuf files
-RUN sh /src/protos/build_protos.sh /src/protos
-
# Build simulated_olt
RUN cd adapters/simulated_olt && go build -o /src/simulated_olt
diff --git a/docker/Dockerfile.simulated_onu b/docker/Dockerfile.simulated_onu
index 607ac6a..ae1588f 100644
--- a/docker/Dockerfile.simulated_onu
+++ b/docker/Dockerfile.simulated_onu
@@ -11,9 +11,9 @@
RUN go get google.golang.org/genproto/googleapis/api/annotations
# Prepare directory structure
-RUN ["mkdir", "-p", "/src", "src/protos"]
+RUN ["mkdir", "-p", "/src"]
RUN ["mkdir", "-p", "$GOPATH/src", "$GOPATH/pkg", "$GOPATH/bin"]
-RUN ["mkdir", "-p", "$GOPATH/src/github.com/opencord/voltha/protos/go"]
+RUN ["mkdir", "-p", "$GOPATH/src/github.com/opencord/voltha-go"]
WORKDIR $GOPATH/src/github.com/opencord/voltha-go
@@ -26,17 +26,6 @@
ADD kafka ./kafka
ADD vendor ./vendor
-# Install the protoc-gen-go
-RUN go install ./vendor/github.com/golang/protobuf/protoc-gen-go
-
-# Copy required proto files
-# ... VOLTHA proos
-ADD protos/*.proto /src/protos/
-ADD protos/scripts/* /src/protos/
-
-# Compile protobuf files
-RUN sh /src/protos/build_protos.sh /src/protos
-
# Build simulated_onu
RUN cd adapters/simulated_onu && go build -o /src/simulated_onu
diff --git a/kafka/client.go b/kafka/client.go
index 9588274..4eb3e5a 100644
--- a/kafka/client.go
+++ b/kafka/client.go
@@ -16,7 +16,7 @@
package kafka
import (
- ca "github.com/opencord/voltha-go/protos/inter_container"
+ ca "github.com/opencord/voltha-protos/go/inter_container"
"time"
)
diff --git a/kafka/kafka_inter_container_library.go b/kafka/kafka_inter_container_library.go
index e5e9606..42e5a02 100644
--- a/kafka/kafka_inter_container_library.go
+++ b/kafka/kafka_inter_container_library.go
@@ -24,7 +24,7 @@
"github.com/golang/protobuf/ptypes/any"
"github.com/google/uuid"
"github.com/opencord/voltha-go/common/log"
- ic "github.com/opencord/voltha-go/protos/inter_container"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
"reflect"
"strings"
"sync"
diff --git a/kafka/sarama_client.go b/kafka/sarama_client.go
index b0ce502..add1900 100644
--- a/kafka/sarama_client.go
+++ b/kafka/sarama_client.go
@@ -22,7 +22,7 @@
"github.com/golang/protobuf/proto"
"github.com/google/uuid"
"github.com/opencord/voltha-go/common/log"
- ic "github.com/opencord/voltha-go/protos/inter_container"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
"gopkg.in/Shopify/sarama.v1"
"strings"
"sync"
diff --git a/protos/scripts/build_protos.sh b/protos/scripts/build_protos.sh
deleted file mode 100755
index 7a9dd76..0000000
--- a/protos/scripts/build_protos.sh
+++ /dev/null
@@ -1,69 +0,0 @@
-#!/bin/sh
-
-# Copyright 2018 the original author or authors.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-export SRC_DIR="$1"
-
-echo $SRC_DIR
-
-export MAPS=Mgoogle/protobuf/descriptor.proto=github.com/golang/protobuf/protoc-gen-go/descriptor
-export INCS="\
- -I $SRC_DIR \
- -I /usr/local/include/googleapis"
-
-export VOLTHA_PB="\
- $SRC_DIR/adapter.proto \
- $SRC_DIR/device.proto \
- $SRC_DIR/events.proto \
- $SRC_DIR/health.proto \
- $SRC_DIR/logical_device.proto \
- $SRC_DIR/ponsim.proto \
- $SRC_DIR/voltha.proto"
-
-export COMMON_PB="\
- $SRC_DIR/common.proto \
- $SRC_DIR/meta.proto \
- $SRC_DIR/yang_options.proto"
-
-export INTER_CONTAINER_PB="$SRC_DIR/inter_container.proto"
-export SCHEMA_PB="$SRC_DIR/schema.proto"
-export IETF_PB="$SRC_DIR/ietf_interfaces.proto"
-export OF_PB="$SRC_DIR/openflow_13.proto"
-export OMCI_PB="$SRC_DIR/omci*.proto"
-export AFROUTER_PB="$SRC_DIR/afrouter.proto"
-export OMCI_PB="$SRC_DIR/omci_mib_db.proto"
-
-export PB_VARS="\
- VOLTHA_PB \
- COMMON_PB \
- INTER_CONTAINER_PB \
- SCHEMA_PB \
- IETF_PB \
- OF_PB \
- OMCI_PB \
- AFROUTER_PB \
- OMCI_PB"
-
-export OTHER_INCLUDES="/usr/local/include/googleapis"
-export PROTO_DESC_FILE="${SRC_DIR}/voltha.pb"
-
-for pb_var in $PB_VARS
-do
- pbs="$(eval echo \$$pb_var)"
- echo "Compiling $pbs"
- protoc --go_out=$MAPS,plugins=grpc:$GOPATH/src $INCS $pbs
-done
-
-protoc -I ${SRC_DIR} -I ${OTHER_INCLUDES} --include_imports --include_source_info --descriptor_set_out=${PROTO_DESC_FILE} ${SRC_DIR}/*.proto
diff --git a/python/Makefile b/python/Makefile
index c9bdcda..7a548e0 100644
--- a/python/Makefile
+++ b/python/Makefile
@@ -185,7 +185,7 @@
ifneq ($(VOLTHA_BUILD),docker)
make -C protos
else
- cp ../protos/*.proto ./protos
+ #cp ../protos/*.proto ./protos
docker build $(DOCKER_BUILD_ARGS) -t ${REGISTRY}${REPOSITORY}voltha-protos:${TAG} -f docker/Dockerfile.protos .
endif
diff --git a/python/adapters/openolt/main.py b/python/adapters/openolt/main.py
index b591ea6..273ff13 100755
--- a/python/adapters/openolt/main.py
+++ b/python/adapters/openolt/main.py
@@ -381,8 +381,10 @@
# TODO: Add KV Store object reference
kv_store=self.args.backend,
default_topic=self.args.name,
+ group_id_prefix=self.args.instance_id,
# Needs to assign a real class
target_cls=openolt_request_handler
+
)
).start()
diff --git a/python/adapters/openolt/openolt.py b/python/adapters/openolt/openolt.py
index 7756791..7af023e 100644
--- a/python/adapters/openolt/openolt.py
+++ b/python/adapters/openolt/openolt.py
@@ -33,9 +33,9 @@
from twisted.internet.task import LoopingCall
from python.adapters.common.frameio.frameio import BpfProgramFilter, hexify
+from python.adapters.iadapter import OltAdapter
from python.common.utils.asleep import asleep
from python.common.utils.registry import registry
-from python.adapters.iadapter import OltAdapter
from python.adapters.kafka.kafka_proxy import get_kafka_proxy
from python.protos import openolt_pb2
from python.protos import third_party
@@ -57,7 +57,7 @@
OFPC_GROUP_STATS, OFPC_PORT_STATS, OFPC_TABLE_STATS, OFPC_FLOW_STATS, \
ofp_switch_features, ofp_desc
from python.protos.openflow_13_pb2 import ofp_port
-from python.protos.ponsim_pb2 import FlowTable, PonSimFrame, PonSimMetricsRequest
+from python.protos.ponsim_pb2 import FlowTable, PonSimFrame, PonSimMetricsRequest, PonSimStub
_ = third_party
log = structlog.get_logger()
@@ -72,8 +72,109 @@
# }
#}
+class AdapterPmMetrics:
+ def __init__(self, device):
+ self.pm_names = {'tx_64_pkts', 'tx_65_127_pkts', 'tx_128_255_pkts',
+ 'tx_256_511_pkts', 'tx_512_1023_pkts',
+ 'tx_1024_1518_pkts', 'tx_1519_9k_pkts',
+ 'rx_64_pkts', 'rx_65_127_pkts',
+ 'rx_128_255_pkts', 'rx_256_511_pkts',
+ 'rx_512_1023_pkts', 'rx_1024_1518_pkts',
+ 'rx_1519_9k_pkts'}
+ self.device = device
+ self.id = device.id
+ self.name = 'ponsim_olt'
+ self.default_freq = 150
+ self.grouped = False
+ self.freq_override = False
+ self.pon_metrics_config = dict()
+ self.nni_metrics_config = dict()
+ self.lc = None
+ for m in self.pm_names:
+ self.pon_metrics_config[m] = PmConfig(name=m,
+ type=PmConfig.COUNTER,
+ enabled=True)
+ self.nni_metrics_config[m] = PmConfig(name=m,
+ type=PmConfig.COUNTER,
+ enabled=True)
-class OpenoltAdapter(object):
+ def update(self, pm_config):
+ if self.default_freq != pm_config.default_freq:
+ # Update the callback to the new frequency.
+ self.default_freq = pm_config.default_freq
+ self.lc.stop()
+ self.lc.start(interval=self.default_freq / 10)
+ for m in pm_config.metrics:
+ self.pon_metrics_config[m.name].enabled = m.enabled
+ self.nni_metrics_config[m.name].enabled = m.enabled
+
+ def make_proto(self):
+ pm_config = PmConfigs(
+ id=self.id,
+ default_freq=self.default_freq,
+ grouped=False,
+ freq_override=False)
+ for m in sorted(self.pon_metrics_config):
+ pm = self.pon_metrics_config[m] # Either will do they're the same
+ pm_config.metrics.extend([PmConfig(name=pm.name,
+ type=pm.type,
+ enabled=pm.enabled)])
+ return pm_config
+
+ def collect_port_metrics(self, channel):
+ rtrn_port_metrics = dict()
+ stub = ponsim_pb2.PonSimStub(channel)
+ stats = stub.GetStats(Empty())
+ rtrn_port_metrics['pon'] = self.extract_pon_metrics(stats)
+ rtrn_port_metrics['nni'] = self.extract_nni_metrics(stats)
+ return rtrn_port_metrics
+
+ def extract_pon_metrics(self, stats):
+ rtrn_pon_metrics = dict()
+ for m in stats.metrics:
+ if m.port_name == "pon":
+ for p in m.packets:
+ if self.pon_metrics_config[p.name].enabled:
+ rtrn_pon_metrics[p.name] = p.value
+ return rtrn_pon_metrics
+
+ def extract_nni_metrics(self, stats):
+ rtrn_pon_metrics = dict()
+ for m in stats.metrics:
+ if m.port_name == "nni":
+ for p in m.packets:
+ if self.pon_metrics_config[p.name].enabled:
+ rtrn_pon_metrics[p.name] = p.value
+ return rtrn_pon_metrics
+
+ def start_collector(self, callback):
+ log.info("starting-pm-collection", device_name=self.name,
+ device_id=self.device.id)
+ prefix = 'voltha.{}.{}'.format(self.name, self.device.id)
+ self.lc = LoopingCall(callback, self.device.id, prefix)
+ self.lc.start(interval=self.default_freq / 10)
+
+ def stop_collector(self):
+ log.info("stopping-pm-collection", device_name=self.name,
+ device_id=self.device.id)
+ self.lc.stop()
+
+
+class AdapterAlarms:
+ def __init__(self, adapter, device):
+ self.adapter = adapter
+ self.device = device
+ self.lc = None
+
+ # TODO: Implement code to send to kafka cluster directly instead of
+ # going through the voltha core.
+ def send_alarm(self, context_data, alarm_data):
+ log.debug("send-alarm-not-implemented")
+ return
+
+
+
+class OpenoltAdapter(OltAdapter):
name = 'openolt'
supported_device_types = [
@@ -81,12 +182,22 @@
id=name,
adapter=name,
accepts_bulk_flow_update=True,
- accepts_direct_logical_flows_update=True
+ accepts_add_remove_flow_updates=True
)
]
# System Init Methods #
def __init__(self, core_proxy, adapter_proxy, config):
+ super(OpenoltAdapter, self).__init__(core_proxy=core_proxy,
+ adapter_proxy=adapter_proxy,
+ config=config,
+ device_handler_class=OpenoltHandler,
+ name='openolt',
+ vendor='Voltha project',
+ version='0.4',
+ device_type='openolt',
+ accepts_bulk_flow_update=True,
+ accepts_add_remove_flow_updates=False)
self.adapter_proxy = adapter_proxy
self.core_proxy = core_proxy
self.config = config
@@ -288,3 +399,481 @@
def unsuppress_alarm(self, filter):
log.info('unsuppress_alarm - Not implemented yet', filter=filter)
raise NotImplementedError()
+
+class OpenoltHandler(object):
+ def __init__(self, adapter, device_id):
+ self.adapter = adapter
+ self.core_proxy = adapter.core_proxy
+ self.adapter_proxy = adapter.adapter_proxy
+ self.device_id = device_id
+ self.log = structlog.get_logger(device_id=device_id)
+ self.channel = None
+ self.io_port = None
+ self.logical_device_id = None
+ self.nni_port = None
+ self.ofp_port_no = None
+ self.interface = registry('main').get_args().interface
+ self.pm_metrics = None
+ self.alarms = None
+ self.frames = None
+
+ @inlineCallbacks
+ def get_channel(self):
+ if self.channel is None:
+ try:
+ device = yield self.core_proxy.get_device(self.device_id)
+ self.log.info('device-info', device=device,
+ host_port=device.host_and_port)
+ self.channel = grpc.insecure_channel(device.host_and_port)
+ except Exception as e:
+ log.exception("ponsim-connection-failure", e=e)
+
+ # returnValue(self.channel)
+
+ def close_channel(self):
+ if self.channel is None:
+ self.log.info('grpc-channel-already-closed')
+ return
+ else:
+ if self.frames is not None:
+ self.frames.cancel()
+ self.frames = None
+ self.log.info('cancelled-grpc-frame-stream')
+
+ self.channel.unsubscribe(lambda *args: None)
+ self.channel = None
+
+ self.log.info('grpc-channel-closed')
+
+ @inlineCallbacks
+ def _get_nni_port(self):
+ ports = yield self.core_proxy.get_ports(self.device_id,
+ Port.ETHERNET_NNI)
+ returnValue(ports)
+
+ @inlineCallbacks
+ def activate(self, device):
+ try:
+ self.log.info('activating')
+ print (dir(device))
+ if not device.host_and_port:
+ device.oper_status = OperStatus.FAILED
+ device.reason = 'No host_and_port field provided'
+ self.core_proxy.device_update(device)
+ return
+ yield self.get_channel()
+ stub = PonSimStub(self.channel)
+ info = stub.GetDeviceInfo(Empty())
+ log.info('got-info', info=info, device_id=device.id)
+ self.ofp_port_no = info.nni_port
+
+ device.root = True
+ device.vendor = 'ponsim'
+ device.model = 'n/a'
+ device.serial_number = device.host_and_port
+ device.mac_address = "AA:BB:CC:DD:EE:FF"
+ yield self.core_proxy.device_update(device)
+
+ # Now set the initial PM configuration for this device
+ self.pm_metrics = AdapterPmMetrics(device)
+ pm_config = self.pm_metrics.make_proto()
+ log.info("initial-pm-config", pm_config=pm_config)
+ self.core_proxy.device_pm_config_update(pm_config, init=True)
+
+ # Setup alarm handler
+ self.alarms = AdapterAlarms(self.adapter, device)
+
+ nni_port = Port(
+ port_no=info.nni_port,
+ label='NNI facing Ethernet port',
+ type=Port.ETHERNET_NNI,
+ oper_status=OperStatus.ACTIVE
+ )
+ self.nni_port = nni_port
+ yield self.core_proxy.port_created(device.id, nni_port)
+ yield self.core_proxy.port_created(device.id, Port(
+ port_no=1,
+ label='PON port',
+ type=Port.PON_OLT,
+ oper_status=OperStatus.ACTIVE
+ ))
+
+ yield self.core_proxy.device_state_update(device.id,
+ connect_status=ConnectStatus.REACHABLE,
+ oper_status=OperStatus.ACTIVE)
+
+ # register ONUS
+ self.log.info('onu-found', onus=info.onus, len=len(info.onus))
+ for onu in info.onus:
+ vlan_id = onu.uni_port
+ yield self.core_proxy.child_device_detected(
+ parent_device_id=device.id,
+ parent_port_no=1,
+ child_device_type='ponsim_onu',
+ channel_id=vlan_id,
+ )
+
+ self.log.info('starting-frame-grpc-stream')
+ reactor.callInThread(self.rcv_grpc)
+ self.log.info('started-frame-grpc-stream')
+
+ # Start collecting stats from the device after a brief pause
+ self.start_kpi_collection(device.id)
+ except Exception as e:
+ log.exception("Exception-activating", e=e)
+
+ def get_ofp_device_info(self, device):
+ return SwitchCapability(
+ desc=ofp_desc(
+ hw_desc='ponsim pon',
+ sw_desc='ponsim pon',
+ serial_num=device.serial_number,
+ dp_desc='n/a'
+ ),
+ switch_features=ofp_switch_features(
+ n_buffers=256, # TODO fake for now
+ n_tables=2, # TODO ditto
+ capabilities=( # TODO and ditto
+ OFPC_FLOW_STATS
+ | OFPC_TABLE_STATS
+ | OFPC_PORT_STATS
+ | OFPC_GROUP_STATS
+ )
+ )
+ )
+
+ def get_ofp_port_info(self, device, port_no):
+ # Since the adapter created the device port then it has the reference of the port to
+ # return the capability. TODO: Do a lookup on the NNI port number and return the
+ # appropriate attributes
+ self.log.info('get_ofp_port_info', port_no=port_no,
+ info=self.ofp_port_no, device_id=device.id)
+ cap = OFPPF_1GB_FD | OFPPF_FIBER
+ return PortCapability(
+ port=LogicalPort(
+ ofp_port=ofp_port(
+ hw_addr=mac_str_to_tuple(
+ 'AA:BB:CC:DD:EE:%02x' % port_no),
+ config=0,
+ state=OFPPS_LIVE,
+ curr=cap,
+ advertised=cap,
+ peer=cap,
+ curr_speed=OFPPF_1GB_FD,
+ max_speed=OFPPF_1GB_FD
+ ),
+ device_id=device.id,
+ device_port_no=port_no
+ )
+ )
+
+ # TODO - change for core 2.0
+ def reconcile(self, device):
+ self.log.info('reconciling-OLT-device')
+
+ @inlineCallbacks
+ def _rcv_frame(self, frame):
+ pkt = Ether(frame)
+
+ if pkt.haslayer(Dot1Q):
+ outer_shim = pkt.getlayer(Dot1Q)
+
+ if isinstance(outer_shim.payload, Dot1Q):
+ inner_shim = outer_shim.payload
+ cvid = inner_shim.vlan
+ popped_frame = (
+ Ether(src=pkt.src, dst=pkt.dst, type=inner_shim.type) /
+ inner_shim.payload
+ )
+ self.log.info('sending-packet-in',device_id=self.device_id, port=cvid)
+ yield self.core_proxy.send_packet_in(device_id=self.device_id,
+ port=cvid,
+ packet=str(popped_frame))
+ elif pkt.haslayer(Raw):
+ raw_data = json.loads(pkt.getlayer(Raw).load)
+ self.alarms.send_alarm(self, raw_data)
+
+ @inlineCallbacks
+ def rcv_grpc(self):
+ """
+ This call establishes a GRPC stream to receive frames.
+ """
+ yield self.get_channel()
+ stub = PonSimStub(self.channel)
+ # stub = PonSimStub(self.get_channel())
+
+ # Attempt to establish a grpc stream with the remote ponsim service
+ self.frames = stub.ReceiveFrames(Empty())
+
+ self.log.info('start-receiving-grpc-frames')
+
+ try:
+ for frame in self.frames:
+ self.log.info('received-grpc-frame',
+ frame_len=len(frame.payload))
+ yield self._rcv_frame(frame.payload)
+
+ except _Rendezvous, e:
+ log.warn('grpc-connection-lost', message=e.message)
+
+ self.log.info('stopped-receiving-grpc-frames')
+
+ @inlineCallbacks
+ def update_flow_table(self, flows):
+ yield self.get_channel()
+ stub = PonSimStub(self.channel)
+
+ self.log.info('pushing-olt-flow-table')
+ stub.UpdateFlowTable(FlowTable(
+ port=0,
+ flows=flows
+ ))
+ self.log.info('success')
+
+ def remove_from_flow_table(self, flows):
+ self.log.debug('remove-from-flow-table', flows=flows)
+ # TODO: Update PONSIM code to accept incremental flow changes
+ # Once completed, the accepts_add_remove_flow_updates for this
+ # device type can be set to True
+
+ def add_to_flow_table(self, flows):
+ self.log.debug('add-to-flow-table', flows=flows)
+ # TODO: Update PONSIM code to accept incremental flow changes
+ # Once completed, the accepts_add_remove_flow_updates for this
+ # device type can be set to True
+
+ def update_pm_config(self, device, pm_config):
+ log.info("handler-update-pm-config", device=device,
+ pm_config=pm_config)
+ self.pm_metrics.update(pm_config)
+
+ def send_proxied_message(self, proxy_address, msg):
+ self.log.info('sending-proxied-message')
+ if isinstance(msg, FlowTable):
+ stub = PonSimStub(self.get_channel())
+ self.log.info('pushing-onu-flow-table', port=msg.port)
+ res = stub.UpdateFlowTable(msg)
+ self.core_proxy.receive_proxied_message(proxy_address, res)
+
+ @inlineCallbacks
+ def process_inter_adapter_message(self, request):
+ self.log.info('process-inter-adapter-message', msg=request)
+ try:
+ if request.header.type == InterAdapterMessageType.FLOW_REQUEST:
+ f = FlowTable()
+ if request.body:
+ request.body.Unpack(f)
+ stub = PonSimStub(self.channel)
+ self.log.info('pushing-onu-flow-table')
+ res = stub.UpdateFlowTable(f)
+ # Send response back
+ reply = InterAdapterResponseBody()
+ reply.status = True
+ self.log.info('sending-response-back', reply=reply)
+ yield self.adapter_proxy.send_inter_adapter_message(
+ msg=reply,
+ type=InterAdapterMessageType.FLOW_RESPONSE,
+ from_adapter=self.adapter.name,
+ to_adapter=request.header.from_topic,
+ to_device_id=request.header.to_device_id,
+ message_id=request.header.id
+ )
+ elif request.header.type == InterAdapterMessageType.METRICS_REQUEST:
+ m = PonSimMetricsRequest()
+ if request.body:
+ request.body.Unpack(m)
+ stub = PonSimStub(self.channel)
+ self.log.info('proxying onu stats request', port=m.port)
+ res = stub.GetStats(m)
+ # Send response back
+ reply = InterAdapterResponseBody()
+ reply.status = True
+ reply.body.Pack(res)
+ self.log.info('sending-response-back', reply=reply)
+ yield self.adapter_proxy.send_inter_adapter_message(
+ msg=reply,
+ type=InterAdapterMessageType.METRICS_RESPONSE,
+ from_adapter=self.adapter.name,
+ to_adapter=request.header.from_topic,
+ to_device_id=request.header.to_device_id,
+ message_id=request.header.id
+ )
+ except Exception as e:
+ self.log.exception("error-processing-inter-adapter-message", e=e)
+
+ def packet_out(self, egress_port, msg):
+ self.log.info('sending-packet-out', egress_port=egress_port,
+ msg=hexify(msg))
+ try:
+ pkt = Ether(msg)
+ out_pkt = pkt
+ if egress_port != self.nni_port.port_no:
+ # don't do the vlan manipulation for the NNI port, vlans are already correct
+ out_pkt = (
+ Ether(src=pkt.src, dst=pkt.dst) /
+ Dot1Q(vlan=egress_port, type=pkt.type) /
+ pkt.payload
+ )
+
+ # TODO need better way of mapping logical ports to PON ports
+ out_port = self.nni_port.port_no if egress_port == self.nni_port.port_no else 1
+
+ # send over grpc stream
+ stub = PonSimStub(self.channel)
+ frame = PonSimFrame(id=self.device_id, payload=str(out_pkt),
+ out_port=out_port)
+ stub.SendFrame(frame)
+ except Exception as e:
+ self.log.exception("error-processing-packet-out", e=e)
+
+
+ @inlineCallbacks
+ def reboot(self):
+ self.log.info('rebooting', device_id=self.device_id)
+
+ yield self.core_proxy.device_state_update(self.device_id,
+ connect_status=ConnectStatus.UNREACHABLE)
+
+ # Update the child devices connect state to UNREACHABLE
+ yield self.core_proxy.children_state_update(self.device_id,
+ connect_status=ConnectStatus.UNREACHABLE)
+
+ # Sleep 10 secs, simulating a reboot
+ # TODO: send alert and clear alert after the reboot
+ yield asleep(10)
+
+ # Change the connection status back to REACHABLE. With a
+ # real OLT the connection state must be the actual state
+ yield self.core_proxy.device_state_update(self.device_id,
+ connect_status=ConnectStatus.REACHABLE)
+
+ # Update the child devices connect state to REACHABLE
+ yield self.core_proxy.children_state_update(self.device_id,
+ connect_status=ConnectStatus.REACHABLE)
+
+ self.log.info('rebooted', device_id=self.device_id)
+
+ def self_test_device(self, device):
+ """
+ This is called to Self a device based on a NBI call.
+ :param device: A Voltha.Device object.
+ :return: Will return result of self test
+ """
+ log.info('self-test-device', device=device.id)
+ raise NotImplementedError()
+
+ @inlineCallbacks
+ def disable(self):
+ self.log.info('disabling', device_id=self.device_id)
+
+ self.stop_kpi_collection()
+
+ # Update the operational status to UNKNOWN and connection status to UNREACHABLE
+ yield self.core_proxy.device_state_update(self.device_id,
+ oper_status=OperStatus.UNKNOWN,
+ connect_status=ConnectStatus.UNREACHABLE)
+
+ self.close_channel()
+ self.log.info('disabled-grpc-channel')
+
+ self.stop_kpi_collection()
+
+ # TODO:
+ # 1) Remove all flows from the device
+ # 2) Remove the device from ponsim
+
+ self.log.info('disabled', device_id=self.device_id)
+
+ @inlineCallbacks
+ def reenable(self):
+ self.log.info('re-enabling', device_id=self.device_id)
+
+ # Set the ofp_port_no and nni_port in case we bypassed the reconcile
+ # process if the device was in DISABLED state on voltha restart
+ if not self.ofp_port_no and not self.nni_port:
+ yield self.get_channel()
+ stub = PonSimStub(self.channel)
+ info = stub.GetDeviceInfo(Empty())
+ log.info('got-info', info=info)
+ self.ofp_port_no = info.nni_port
+ ports = yield self._get_nni_port()
+ # For ponsim, we are using only 1 NNI port
+ if ports.items:
+ self.nni_port = ports.items[0]
+
+ # Update the state of the NNI port
+ yield self.core_proxy.port_state_update(self.device_id,
+ port_type=Port.ETHERNET_NNI,
+ port_no=self.ofp_port_no,
+ oper_status=OperStatus.ACTIVE)
+
+ # Update the state of the PON port
+ yield self.core_proxy.port_state_update(self.device_id,
+ port_type=Port.PON_OLT,
+ port_no=1,
+ oper_status=OperStatus.ACTIVE)
+
+ # Set the operational state of the device to ACTIVE and connect status to REACHABLE
+ yield self.core_proxy.device_state_update(self.device_id,
+ connect_status=ConnectStatus.REACHABLE,
+ oper_status=OperStatus.ACTIVE)
+
+ # TODO: establish frame grpc-stream
+ # yield reactor.callInThread(self.rcv_grpc)
+
+ self.start_kpi_collection(self.device_id)
+
+ self.log.info('re-enabled', device_id=self.device_id)
+
+ def delete(self):
+ self.log.info('deleting', device_id=self.device_id)
+
+ self.close_channel()
+ self.log.info('disabled-grpc-channel')
+
+ # TODO:
+ # 1) Remove all flows from the device
+ # 2) Remove the device from ponsim
+
+ self.log.info('deleted', device_id=self.device_id)
+
+ def start_kpi_collection(self, device_id):
+
+ kafka_cluster_proxy = get_kafka_proxy()
+
+ def _collect(device_id, prefix):
+
+ try:
+ # Step 1: gather metrics from device
+ port_metrics = \
+ self.pm_metrics.collect_port_metrics(self.channel)
+
+ # Step 2: prepare the KpiEvent for submission
+ # we can time-stamp them here (or could use time derived from OLT
+ ts = arrow.utcnow().timestamp
+ kpi_event = KpiEvent(
+ type=KpiEventType.slice,
+ ts=ts,
+ prefixes={
+ # OLT NNI port
+ prefix + '.nni': MetricValuePairs(
+ metrics=port_metrics['nni']),
+ # OLT PON port
+ prefix + '.pon': MetricValuePairs(
+ metrics=port_metrics['pon'])
+ }
+ )
+
+ # Step 3: submit directly to the kafka bus
+ if kafka_cluster_proxy:
+ if isinstance(kpi_event, Message):
+ kpi_event = dumps(MessageToDict(kpi_event, True, True))
+ kafka_cluster_proxy.send_message("voltha.kpis", kpi_event)
+
+ except Exception as e:
+ log.exception('failed-to-submit-kpis', e=e)
+
+ self.pm_metrics.start_collector(_collect)
+
+ def stop_kpi_collection(self):
+ self.pm_metrics.stop_collector()
diff --git a/python/common/utils/nethelpers.py b/python/common/utils/nethelpers.py
index b17aced..7df7f9f 100644
--- a/python/common/utils/nethelpers.py
+++ b/python/common/utils/nethelpers.py
@@ -72,6 +72,8 @@
return iface
return None
+def mac_str_to_tuple(mac):
+ return tuple(int(d, 16) for d in mac.split(':'))
def _get_my_primary_local_ipv4(ifname=None):
try:
diff --git a/protos/adapter.proto b/python/protos/adapter.proto
similarity index 92%
rename from protos/adapter.proto
rename to python/protos/adapter.proto
index c70e0a6..6aec120 100644
--- a/protos/adapter.proto
+++ b/python/protos/adapter.proto
@@ -1,6 +1,6 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/voltha";
+option go_package = "github.com/opencord/voltha-protos/go/voltha";
package voltha;
diff --git a/protos/afrouter.proto b/python/protos/afrouter.proto
similarity index 91%
rename from protos/afrouter.proto
rename to python/protos/afrouter.proto
index 7702841..ee968ad 100644
--- a/protos/afrouter.proto
+++ b/python/protos/afrouter.proto
@@ -2,7 +2,7 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/afrouter";
+option go_package = "github.com/opencord/voltha-protos/go/afrouter";
package afrouter;
diff --git a/protos/common.proto b/python/protos/common.proto
similarity index 97%
rename from protos/common.proto
rename to python/protos/common.proto
index b1c13ae..076477f 100644
--- a/protos/common.proto
+++ b/python/protos/common.proto
@@ -1,6 +1,6 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/common";
+option go_package = "github.com/opencord/voltha-protos/go/common";
package voltha;
diff --git a/protos/device.proto b/python/protos/device.proto
similarity index 88%
rename from protos/device.proto
rename to python/protos/device.proto
index 229981e..cf53269 100644
--- a/protos/device.proto
+++ b/python/protos/device.proto
@@ -1,6 +1,6 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/voltha";
+option go_package = "github.com/opencord/voltha-protos/go/voltha";
package voltha;
@@ -17,7 +17,7 @@
// Unique name for the device type
string id = 1;
- // Unique vendor id for the device type applicable to ONU
+ // Unique venor id for the device type applicable to ONU
// 4 bytes of vendor id from ONU serial number
string vendor_id = 5;
@@ -26,9 +26,12 @@
// Name of the adapter that handles device type
string adapter = 2;
- // Capabilities
+ // Capabilitities
+
bool accepts_bulk_flow_update = 3;
bool accepts_add_remove_flow_updates = 4;
+ bool accepts_direct_logical_flows_update = 7;
+
}
// A plurality of device types
@@ -38,9 +41,10 @@
message PmConfig {
enum PmType {
- COUNTER = 0;
- GUAGE = 1;
- STATE = 2;
+ COUNTER = 0;
+ GAUGE = 1;
+ STATE = 2;
+ CONTEXT = 3;
}
string name = 1;
PmType type = 2;
@@ -116,15 +120,15 @@
DEVICE_BUSY = 2;
INSUFFICIENT_SPACE = 3;
UNKNOWN_ERROR = 4;
+ CANCELLED = 5;
}
enum ImageActivateState {
IMAGE_UNKNOWN = 0;
IMAGE_INACTIVE = 1;
- IMAGE_ACTIVATING = 2;
+ IMAGE_ACTIVATE = 2;
IMAGE_ACTIVE = 3;
- IMAGE_REVERTING = 4;
- IMAGE_REVERTED = 5;
+ IMAGE_REVERT = 4;
}
// Device Identifier
@@ -163,6 +167,9 @@
// Image activation state
ImageActivateState image_state = 12;
+
+ // Image file size
+ uint32 file_size = 13;
}
message ImageDownloads {
@@ -200,6 +207,13 @@
}
repeated PeerPort peers = 8;
+ fixed64 rx_packets = 9;
+ fixed64 rx_bytes = 10;
+ fixed64 rx_errors = 11;
+ fixed64 tx_packets = 12;
+ fixed64 tx_bytes = 13;
+ fixed64 tx_errors = 14;
+
}
message Ports {
@@ -251,10 +265,10 @@
uint32 onu_session_id = 7; // session identifier for the ONU; optional
};
- // Device contact MAC address (format: "xx:xx:xx:xx:xx:xx")
- string mac_address = 13;
-
oneof address {
+ // Device contact MAC address (format: "xx:xx:xx:xx:xx:xx")
+ string mac_address = 13;
+
// Device contact IPv4 address (format: "a.b.c.d" or can use hostname too)
string ipv4_address = 14;
@@ -295,3 +309,21 @@
message Devices {
repeated Device items = 1;
}
+
+message SimulateAlarmRequest {
+ enum OperationType {
+ RAISE = 0;
+ CLEAR = 1;
+ }
+ // Device Identifier
+ string id = 1;
+ string indicator = 2;
+ string intf_id = 3;
+ string port_type_name = 4;
+ string onu_device_id = 5;
+ int32 inverse_bit_error_rate = 6;
+ int32 drift = 7;
+ int32 new_eqd = 8;
+ string onu_serial_number = 9;
+ OperationType operation = 10;
+}
diff --git a/protos/events.proto b/python/protos/events.proto
similarity index 97%
rename from protos/events.proto
rename to python/protos/events.proto
index 27fd5cd..1a1534d 100644
--- a/protos/events.proto
+++ b/python/protos/events.proto
@@ -1,6 +1,6 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/voltha";
+option go_package = "github.com/opencord/voltha-protos/go/voltha";
package voltha;
diff --git a/protos/health.proto b/python/protos/health.proto
similarity index 92%
rename from protos/health.proto
rename to python/protos/health.proto
index 0730eac..907b683 100644
--- a/protos/health.proto
+++ b/python/protos/health.proto
@@ -1,6 +1,6 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/voltha";
+option go_package = "github.com/opencord/voltha-protos/go/voltha";
package voltha;
diff --git a/protos/ietf_interfaces.proto b/python/protos/ietf_interfaces.proto
similarity index 94%
rename from protos/ietf_interfaces.proto
rename to python/protos/ietf_interfaces.proto
index d43c02d..90e489b 100644
--- a/protos/ietf_interfaces.proto
+++ b/python/protos/ietf_interfaces.proto
@@ -1,6 +1,6 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/ietf";
+option go_package = "github.com/opencord/voltha-protos/go/ietf";
package ietf_interfaces;
diff --git a/protos/inter_container.proto b/python/protos/inter_container.proto
similarity index 94%
rename from protos/inter_container.proto
rename to python/protos/inter_container.proto
index 4d4ffe8..5896f13 100644
--- a/protos/inter_container.proto
+++ b/python/protos/inter_container.proto
@@ -5,7 +5,7 @@
import public "logical_device.proto";
-option go_package = "github.com/opencord/voltha-go/protos/inter_container";
+option go_package = "github.com/opencord/voltha-protos/go/inter_container";
package voltha;
@@ -48,8 +48,7 @@
MessageType type = 2;
string from_topic = 3;
string to_topic = 4;
- string key_topic = 5;
- int64 timestamp = 6;
+ int64 timestamp = 5;
}
message Argument {
diff --git a/protos/logical_device.proto b/python/protos/logical_device.proto
similarity index 95%
rename from protos/logical_device.proto
rename to python/protos/logical_device.proto
index 54b9e02..521768c 100644
--- a/protos/logical_device.proto
+++ b/python/protos/logical_device.proto
@@ -1,6 +1,6 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/voltha";
+option go_package = "github.com/opencord/voltha-protos/go/voltha";
package voltha;
diff --git a/protos/meta.proto b/python/protos/meta.proto
similarity index 96%
rename from protos/meta.proto
rename to python/protos/meta.proto
index fc02e46..a308ffa 100644
--- a/protos/meta.proto
+++ b/python/protos/meta.proto
@@ -17,7 +17,7 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/common";
+option go_package = "github.com/opencord/voltha-protos/go/common";
package voltha;
diff --git a/protos/omci_mib_db.proto b/python/protos/omci_mib_db.proto
similarity index 95%
rename from protos/omci_mib_db.proto
rename to python/protos/omci_mib_db.proto
index f8fe157..aa773dc 100644
--- a/protos/omci_mib_db.proto
+++ b/python/protos/omci_mib_db.proto
@@ -15,7 +15,7 @@
//
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/omci";
+option go_package = "github.com/opencord/voltha-protos/go/omci";
package omci;
diff --git a/protos/openflow_13.proto b/python/protos/openflow_13.proto
similarity index 99%
rename from protos/openflow_13.proto
rename to python/protos/openflow_13.proto
index e242e76..ee08eb6 100644
--- a/protos/openflow_13.proto
+++ b/python/protos/openflow_13.proto
@@ -57,7 +57,7 @@
*/
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/openflow_13";
+option go_package = "github.com/opencord/voltha-protos/go/openflow_13";
package openflow_13;
diff --git a/python/protos/openolt.proto b/python/protos/openolt.proto
index f6c1da1..ba1c4a9 100644
--- a/python/protos/openolt.proto
+++ b/python/protos/openolt.proto
@@ -13,7 +13,7 @@
// limitations under the License.
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/voltha";
+option go_package = "github.com/opencord/voltha-protos/go/voltha";
package voltha;
diff --git a/protos/ponsim.proto b/python/protos/ponsim.proto
similarity index 94%
rename from protos/ponsim.proto
rename to python/protos/ponsim.proto
index 1cd9e4e..74eb97e 100644
--- a/protos/ponsim.proto
+++ b/python/protos/ponsim.proto
@@ -1,6 +1,6 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/voltha";
+option go_package = "github.com/opencord/voltha-protos/go/voltha";
package voltha;
diff --git a/protos/schema.proto b/python/protos/schema.proto
similarity index 93%
rename from protos/schema.proto
rename to python/protos/schema.proto
index bb1f895..2edd85a 100644
--- a/protos/schema.proto
+++ b/python/protos/schema.proto
@@ -1,6 +1,6 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/schema";
+option go_package = "github.com/opencord/voltha-protos/go/schema";
package schema;
diff --git a/protos/voltha.proto b/python/protos/voltha.proto
similarity index 98%
rename from protos/voltha.proto
rename to python/protos/voltha.proto
index 7048e62..2563bb0 100644
--- a/protos/voltha.proto
+++ b/python/protos/voltha.proto
@@ -6,7 +6,7 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/voltha";
+option go_package = "github.com/opencord/voltha-protos/go/voltha";
package voltha;
@@ -159,13 +159,6 @@
};
}
- // Get the membership group of a Voltha Core
- rpc GetMembership(google.protobuf.Empty) returns(Membership) {
- option (google.api.http) = {
- get: "/api/v1/membership"
- };
- }
-
// Set the membership group of a Voltha Core
rpc UpdateMembership(Membership) returns(google.protobuf.Empty) {
option (google.api.http) = {
diff --git a/protos/yang_options.proto b/python/protos/yang_options.proto
similarity index 97%
rename from protos/yang_options.proto
rename to python/protos/yang_options.proto
index 25f70a8..25e6fa7 100644
--- a/protos/yang_options.proto
+++ b/python/protos/yang_options.proto
@@ -17,7 +17,7 @@
syntax = "proto3";
-option go_package = "github.com/opencord/voltha-go/protos/common";
+option go_package = "github.com/opencord/voltha-protos/go/common";
package voltha;
diff --git a/quickstart.md b/quickstart.md
index 633097f..5320569 100644
--- a/quickstart.md
+++ b/quickstart.md
@@ -38,7 +38,7 @@
### VOLTHA Protos
-Library containing all VOLTHA gRPC Protobuf definitions and the build system to produce needed stubs in Python and Golang. Currently only Python stubs are produced and used by openolt and openonu adapters below. Soon all VOLTHA 2.x core and components will use the protobufs built from this repo. Once this stabilizes you will no longer need a local build. The python vesion of the stubs will be available in pip. Currently the plan is to push the voltha-protos pip library once a sprint into PyPi. The Golang vesion of the stubs will be available via go get *TODO*
+Library containing all VOLTHA gRPC Protobuf definitions and the build system to produce needed stubs in Python and Golang.
```sh
mkdir ~/source
@@ -46,6 +46,12 @@
git clone https://gerrit.opencord.org/voltha-protos.git
```
+Setup local voltha-protos for go if editing protos is needed
+Follow voltha-protos README for setup, then:
+```
+export LOCAL_PROTOS=true
+```
+
Generate the local tar.gz that is the dev version of voltha-protos:
```sh
cd ~/source/voltha-protos/
diff --git a/ro_core/core/core.go b/ro_core/core/core.go
index 0ba9b1b..5825574 100644
--- a/ro_core/core/core.go
+++ b/ro_core/core/core.go
@@ -21,7 +21,7 @@
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/kvstore"
"github.com/opencord/voltha-go/db/model"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"github.com/opencord/voltha-go/ro_core/config"
"google.golang.org/grpc"
)
diff --git a/ro_core/core/device_agent.go b/ro_core/core/device_agent.go
index ce4125e..ca70d48 100644
--- a/ro_core/core/device_agent.go
+++ b/ro_core/core/device_agent.go
@@ -20,7 +20,7 @@
"github.com/gogo/protobuf/proto"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/model"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
"sync"
diff --git a/ro_core/core/device_manager.go b/ro_core/core/device_manager.go
index 92c6516..9e67b72 100644
--- a/ro_core/core/device_manager.go
+++ b/ro_core/core/device_manager.go
@@ -19,7 +19,7 @@
"context"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/model"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
"sync"
diff --git a/ro_core/core/grpc_nbi_api_handler.go b/ro_core/core/grpc_nbi_api_handler.go
index 5727983..8338507 100644
--- a/ro_core/core/grpc_nbi_api_handler.go
+++ b/ro_core/core/grpc_nbi_api_handler.go
@@ -21,8 +21,10 @@
"github.com/golang/protobuf/ptypes/empty"
da "github.com/opencord/voltha-go/common/core/northbound/grpc"
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/common"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/common"
+ "github.com/opencord/voltha-protos/go/omci"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/metadata"
"google.golang.org/grpc/status"
@@ -252,3 +254,49 @@
}
return nil, errors.New("UnImplemented")
}
+
+//@TODO useless stub, what should this actually do?
+func (handler *APIHandler) GetAlarmDeviceData(
+ ctx context.Context,
+ in *common.ID,
+) (*omci.AlarmDeviceData, error) {
+ log.Debug("GetAlarmDeviceData-stub")
+ return nil, nil
+}
+
+//@TODO useless stub, what should this actually do?
+func (handler *APIHandler) GetMeterStatsOfLogicalDevice(
+ ctx context.Context,
+ in *common.ID,
+) (*openflow_13.MeterStatsReply, error) {
+ log.Debug("GetMeterStatsOfLogicalDevice-stub")
+ return nil, nil
+}
+
+//@TODO useless stub, what should this actually do?
+func (handler *APIHandler) GetMibDeviceData(
+ ctx context.Context,
+ in *common.ID,
+) (*omci.MibDeviceData, error) {
+ log.Debug("GetMibDeviceData-stub")
+ return nil, nil
+}
+
+//@TODO useless stub, what should this actually do?
+func (handler *APIHandler) SimulateAlarm(
+ ctx context.Context,
+ in *voltha.SimulateAlarmRequest,
+) (*common.OperationResp, error) {
+ log.Debug("SimulateAlarm-stub")
+ return nil, nil
+}
+
+//@TODO useless stub, what should this actually do?
+func (handler *APIHandler) UpdateLogicalDeviceMeterTable(
+ ctx context.Context,
+ in *openflow_13.MeterModUpdate,
+) (*empty.Empty, error) {
+ log.Debug("UpdateLogicalDeviceMeterTable-stub")
+ return nil, nil
+}
+
diff --git a/ro_core/core/logical_device_agent.go b/ro_core/core/logical_device_agent.go
index f3153ca..1357bd4 100644
--- a/ro_core/core/logical_device_agent.go
+++ b/ro_core/core/logical_device_agent.go
@@ -20,7 +20,7 @@
"github.com/gogo/protobuf/proto"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/model"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
"sync"
diff --git a/ro_core/core/logical_device_manager.go b/ro_core/core/logical_device_manager.go
index 9ee3456..846df63 100644
--- a/ro_core/core/logical_device_manager.go
+++ b/ro_core/core/logical_device_manager.go
@@ -19,7 +19,7 @@
"context"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/model"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
"sync"
diff --git a/ro_core/core/model_proxy_manager.go b/ro_core/core/model_proxy_manager.go
index d5f7ace..6db4bef 100644
--- a/ro_core/core/model_proxy_manager.go
+++ b/ro_core/core/model_proxy_manager.go
@@ -19,7 +19,7 @@
"context"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/model"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
)
diff --git a/ro_core/main.go b/ro_core/main.go
index 599fe9f..f80c77e 100644
--- a/ro_core/main.go
+++ b/ro_core/main.go
@@ -22,7 +22,7 @@
grpcserver "github.com/opencord/voltha-go/common/grpc"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/kvstore"
- ic "github.com/opencord/voltha-go/protos/inter_container"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
"github.com/opencord/voltha-go/ro_core/config"
c "github.com/opencord/voltha-go/ro_core/core"
"os"
diff --git a/rw_core/core/adapter_manager.go b/rw_core/core/adapter_manager.go
index ec3f0db..be5b589 100644
--- a/rw_core/core/adapter_manager.go
+++ b/rw_core/core/adapter_manager.go
@@ -22,7 +22,7 @@
"github.com/gogo/protobuf/proto"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/model"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"reflect"
"sync"
)
diff --git a/rw_core/core/adapter_proxy.go b/rw_core/core/adapter_proxy.go
index ebc79ba..49f56e5 100644
--- a/rw_core/core/adapter_proxy.go
+++ b/rw_core/core/adapter_proxy.go
@@ -21,9 +21,9 @@
a "github.com/golang/protobuf/ptypes/any"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
)
diff --git a/rw_core/core/adapter_request_handler.go b/rw_core/core/adapter_request_handler.go
index f450ca2..d933466 100644
--- a/rw_core/core/adapter_request_handler.go
+++ b/rw_core/core/adapter_request_handler.go
@@ -23,9 +23,9 @@
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/model"
"github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- "github.com/opencord/voltha-go/protos/voltha"
"github.com/opencord/voltha-go/rw_core/utils"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
)
diff --git a/rw_core/core/core.go b/rw_core/core/core.go
index 9f6adcd..a504f34 100644
--- a/rw_core/core/core.go
+++ b/rw_core/core/core.go
@@ -24,7 +24,7 @@
"github.com/opencord/voltha-go/db/kvstore"
"github.com/opencord/voltha-go/db/model"
"github.com/opencord/voltha-go/kafka"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"github.com/opencord/voltha-go/rw_core/config"
"google.golang.org/grpc"
"google.golang.org/grpc/codes"
@@ -262,4 +262,4 @@
log.Info("Adapter-Manager-Starting...")
core.adapterMgr.start(ctx)
log.Info("Adapter-Manager-Started")
-}
\ No newline at end of file
+}
diff --git a/rw_core/core/device_agent.go b/rw_core/core/device_agent.go
index 1d9480d..af4cb7b 100644
--- a/rw_core/core/device_agent.go
+++ b/rw_core/core/device_agent.go
@@ -21,9 +21,9 @@
"github.com/gogo/protobuf/proto"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/model"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- ofp "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ ofp "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
fu "github.com/opencord/voltha-go/rw_core/utils"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
diff --git a/rw_core/core/device_manager.go b/rw_core/core/device_manager.go
index b27f01a..287adaf 100644
--- a/rw_core/core/device_manager.go
+++ b/rw_core/core/device_manager.go
@@ -21,9 +21,9 @@
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/model"
"github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- ofp "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ ofp "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
"reflect"
diff --git a/rw_core/core/device_ownership.go b/rw_core/core/device_ownership.go
index 92262ab..4a692d3 100644
--- a/rw_core/core/device_ownership.go
+++ b/rw_core/core/device_ownership.go
@@ -20,7 +20,7 @@
"fmt"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/kvstore"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"github.com/opencord/voltha-go/rw_core/utils"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
diff --git a/rw_core/core/device_state_transitions.go b/rw_core/core/device_state_transitions.go
index bee8246..21f7531 100644
--- a/rw_core/core/device_state_transitions.go
+++ b/rw_core/core/device_state_transitions.go
@@ -17,7 +17,7 @@
import (
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
)
type DeviceType int32
diff --git a/rw_core/core/grpc_nbi_api_handler.go b/rw_core/core/grpc_nbi_api_handler.go
index 1e5cc5b..7ed756c 100644
--- a/rw_core/core/grpc_nbi_api_handler.go
+++ b/rw_core/core/grpc_nbi_api_handler.go
@@ -22,10 +22,11 @@
"github.com/golang/protobuf/ptypes/empty"
da "github.com/opencord/voltha-go/common/core/northbound/grpc"
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/common"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
"github.com/opencord/voltha-go/rw_core/utils"
+ "github.com/opencord/voltha-protos/go/common"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/omci"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/metadata"
"google.golang.org/grpc/status"
@@ -806,3 +807,48 @@
log.Debugw("Subscribe-request", log.Fields{"ofAgent": ofAgent})
return &voltha.OfAgentSubscriber{OfagentId: ofAgent.OfagentId, VolthaId: ofAgent.VolthaId}, nil
}
+
+//@TODO useless stub, what should this actually do?
+func (handler *APIHandler) GetAlarmDeviceData(
+ ctx context.Context,
+ in *common.ID,
+) (*omci.AlarmDeviceData, error) {
+ log.Debug("GetAlarmDeviceData-stub")
+ return nil, nil
+}
+
+//@TODO useless stub, what should this actually do?
+func (handler *APIHandler) GetMeterStatsOfLogicalDevice(
+ ctx context.Context,
+ in *common.ID,
+) (*openflow_13.MeterStatsReply, error) {
+ log.Debug("GetMeterStatsOfLogicalDevice-stub")
+ return nil, nil
+}
+
+//@TODO useless stub, what should this actually do?
+func (handler *APIHandler) GetMibDeviceData(
+ ctx context.Context,
+ in *common.ID,
+) (*omci.MibDeviceData, error) {
+ log.Debug("GetMibDeviceData-stub")
+ return nil, nil
+}
+
+//@TODO useless stub, what should this actually do?
+func (handler *APIHandler) SimulateAlarm(
+ ctx context.Context,
+ in *voltha.SimulateAlarmRequest,
+) (*common.OperationResp, error) {
+ log.Debug("SimulateAlarm-stub")
+ return nil, nil
+}
+
+//@TODO useless stub, what should this actually do?
+func (handler *APIHandler) UpdateLogicalDeviceMeterTable(
+ ctx context.Context,
+ in *openflow_13.MeterModUpdate,
+) (*empty.Empty, error) {
+ log.Debug("UpdateLogicalDeviceMeterTable-stub")
+ return nil, nil
+}
diff --git a/rw_core/core/logical_device_agent.go b/rw_core/core/logical_device_agent.go
index a8e6a70..b1a68cc 100644
--- a/rw_core/core/logical_device_agent.go
+++ b/rw_core/core/logical_device_agent.go
@@ -22,9 +22,9 @@
"github.com/gogo/protobuf/proto"
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/model"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- ofp "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ ofp "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
fd "github.com/opencord/voltha-go/rw_core/flow_decomposition"
"github.com/opencord/voltha-go/rw_core/graph"
fu "github.com/opencord/voltha-go/rw_core/utils"
diff --git a/rw_core/core/logical_device_manager.go b/rw_core/core/logical_device_manager.go
index 5f572b1..2fc0f1e 100644
--- a/rw_core/core/logical_device_manager.go
+++ b/rw_core/core/logical_device_manager.go
@@ -21,8 +21,8 @@
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/model"
"github.com/opencord/voltha-go/kafka"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
"strings"
diff --git a/rw_core/coreIf/device_manager_if.go b/rw_core/coreIf/device_manager_if.go
index dbe5598..ec191dc 100644
--- a/rw_core/coreIf/device_manager_if.go
+++ b/rw_core/coreIf/device_manager_if.go
@@ -19,7 +19,7 @@
*/
package coreIf
-import "github.com/opencord/voltha-go/protos/voltha"
+import "github.com/opencord/voltha-protos/go/voltha"
// DeviceManager represents a generic device manager
type DeviceManager interface {
diff --git a/rw_core/coreIf/logical_device_agent_if.go b/rw_core/coreIf/logical_device_agent_if.go
index 43bbf18..8394fac 100644
--- a/rw_core/coreIf/logical_device_agent_if.go
+++ b/rw_core/coreIf/logical_device_agent_if.go
@@ -20,7 +20,7 @@
package coreIf
import (
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"github.com/opencord/voltha-go/rw_core/graph"
"github.com/opencord/voltha-go/rw_core/utils"
)
diff --git a/rw_core/flow_decomposition/flow_decomposer.go b/rw_core/flow_decomposition/flow_decomposer.go
index f702633..6c67ace 100644
--- a/rw_core/flow_decomposition/flow_decomposer.go
+++ b/rw_core/flow_decomposition/flow_decomposer.go
@@ -22,8 +22,8 @@
"fmt"
"github.com/gogo/protobuf/proto"
"github.com/opencord/voltha-go/common/log"
- ofp "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ ofp "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"github.com/opencord/voltha-go/rw_core/coreIf"
"github.com/opencord/voltha-go/rw_core/graph"
fu "github.com/opencord/voltha-go/rw_core/utils"
diff --git a/rw_core/flow_decomposition/flow_decomposer_test.go b/rw_core/flow_decomposition/flow_decomposer_test.go
index f00a1e7..a0a2e3b 100644
--- a/rw_core/flow_decomposition/flow_decomposer_test.go
+++ b/rw_core/flow_decomposition/flow_decomposer_test.go
@@ -18,8 +18,8 @@
import (
"errors"
"github.com/opencord/voltha-go/common/log"
- ofp "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ ofp "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"github.com/opencord/voltha-go/rw_core/graph"
fu "github.com/opencord/voltha-go/rw_core/utils"
"github.com/stretchr/testify/assert"
diff --git a/rw_core/graph/device_graph.go b/rw_core/graph/device_graph.go
index 58198de..0ed2748 100644
--- a/rw_core/graph/device_graph.go
+++ b/rw_core/graph/device_graph.go
@@ -21,7 +21,7 @@
"fmt"
"github.com/gyuho/goraph"
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/voltha"
"strconv"
"strings"
"sync"
diff --git a/rw_core/graph/device_graph_test.go b/rw_core/graph/device_graph_test.go
index 533d03d..09b39e0 100644
--- a/rw_core/graph/device_graph_test.go
+++ b/rw_core/graph/device_graph_test.go
@@ -18,8 +18,8 @@
import (
"errors"
"fmt"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"github.com/stretchr/testify/assert"
"testing"
"time"
diff --git a/rw_core/main.go b/rw_core/main.go
index 2dadeb2..5db4078 100644
--- a/rw_core/main.go
+++ b/rw_core/main.go
@@ -23,7 +23,7 @@
"github.com/opencord/voltha-go/common/log"
"github.com/opencord/voltha-go/db/kvstore"
"github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
"github.com/opencord/voltha-go/rw_core/config"
c "github.com/opencord/voltha-go/rw_core/core"
"os"
diff --git a/rw_core/utils/flow_utils.go b/rw_core/utils/flow_utils.go
index 6fa6a02..10be81a 100644
--- a/rw_core/utils/flow_utils.go
+++ b/rw_core/utils/flow_utils.go
@@ -19,7 +19,7 @@
"bytes"
"github.com/cevaris/ordered_map"
"github.com/gogo/protobuf/proto"
- ofp "github.com/opencord/voltha-go/protos/openflow_13"
+ ofp "github.com/opencord/voltha-protos/go/openflow_13"
"strings"
)
diff --git a/tests/afrouter/suites/test1.json b/tests/afrouter/suites/test1.json
index 77cc0ec..3634f99 100644
--- a/tests/afrouter/suites/test1.json
+++ b/tests/afrouter/suites/test1.json
@@ -3,7 +3,7 @@
"cmdLine":"afrouter -logLevel 1 -config arouter_test.json",
"protoFiles": [
{
- "importPath":"github.com/opencord/voltha-go/protos/",
+ "importPath":"github.com/opencord/voltha-protos/go/",
"service":"VolthaService",
"package":"voltha"
},
diff --git a/tests/afrouter/suites/test2.tmpl.json b/tests/afrouter/suites/test2.tmpl.json
index c8d040e..1355068 100644
--- a/tests/afrouter/suites/test2.tmpl.json
+++ b/tests/afrouter/suites/test2.tmpl.json
@@ -3,7 +3,7 @@
"cmdLine":"afrouter -config arouter_test.json -logLevel 1",
"protoFiles": [
{
- "importPath":"github.com/opencord/voltha-go/protos/",
+ "importPath":"github.com/opencord/voltha-protos/go/",
"service":"VolthaService",
"package":"voltha"
},
diff --git a/tests/core/api/grpc_nbi_api_handler_client_test.go b/tests/core/api/grpc_nbi_api_handler_client_test.go
index ef0defa..47e4472 100644
--- a/tests/core/api/grpc_nbi_api_handler_client_test.go
+++ b/tests/core/api/grpc_nbi_api_handler_client_test.go
@@ -21,9 +21,9 @@
com "github.com/opencord/voltha-go/adapters/common"
"github.com/golang/protobuf/ptypes/empty"
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/common"
- "github.com/opencord/voltha-go/protos/openflow_13"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/common"
+ "github.com/opencord/voltha-protos/go/openflow_13"
+ "github.com/opencord/voltha-protos/go/voltha"
"github.com/stretchr/testify/assert"
"google.golang.org/grpc"
"google.golang.org/grpc/codes"
diff --git a/tests/core/concurrency/core_concurrency_test.go b/tests/core/concurrency/core_concurrency_test.go
index d781ffc..42f5de0 100644
--- a/tests/core/concurrency/core_concurrency_test.go
+++ b/tests/core/concurrency/core_concurrency_test.go
@@ -23,8 +23,8 @@
"github.com/google/uuid"
com "github.com/opencord/voltha-go/adapters/common"
"github.com/opencord/voltha-go/common/log"
- "github.com/opencord/voltha-go/protos/common"
- "github.com/opencord/voltha-go/protos/voltha"
+ "github.com/opencord/voltha-protos/go/common"
+ "github.com/opencord/voltha-protos/go/voltha"
"github.com/stretchr/testify/assert"
"google.golang.org/grpc"
"google.golang.org/grpc/metadata"
diff --git a/tests/kafka/kafka_client_test.go b/tests/kafka/kafka_client_test.go
index 12f0ae4..b4fc0cf 100644
--- a/tests/kafka/kafka_client_test.go
+++ b/tests/kafka/kafka_client_test.go
@@ -22,7 +22,7 @@
"github.com/google/uuid"
"github.com/opencord/voltha-go/common/log"
kk "github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
"github.com/stretchr/testify/assert"
"os"
"testing"
diff --git a/tests/kafka/kafka_inter_container_messaging_test.go b/tests/kafka/kafka_inter_container_messaging_test.go
index de97558..d6a8e8b 100644
--- a/tests/kafka/kafka_inter_container_messaging_test.go
+++ b/tests/kafka/kafka_inter_container_messaging_test.go
@@ -21,8 +21,8 @@
"github.com/google/uuid"
"github.com/opencord/voltha-go/common/log"
kk "github.com/opencord/voltha-go/kafka"
- ic "github.com/opencord/voltha-go/protos/inter_container"
- "github.com/opencord/voltha-go/protos/voltha"
+ ic "github.com/opencord/voltha-protos/go/inter_container"
+ "github.com/opencord/voltha-protos/go/voltha"
rhp "github.com/opencord/voltha-go/rw_core/core"
"github.com/stretchr/testify/assert"
"os"
diff --git a/vendor/github.com/Shopify/sarama/.travis.yml b/vendor/github.com/Shopify/sarama/.travis.yml
index eb54a0d..b7f7874 100644
--- a/vendor/github.com/Shopify/sarama/.travis.yml
+++ b/vendor/github.com/Shopify/sarama/.travis.yml
@@ -11,9 +11,9 @@
- KAFKA_HOSTNAME=localhost
- DEBUG=true
matrix:
- - KAFKA_VERSION=1.1.1
- - KAFKA_VERSION=2.0.1
- - KAFKA_VERSION=2.1.0
+ - KAFKA_VERSION=1.1.1 KAFKA_SCALA_VERSION=2.11
+ - KAFKA_VERSION=2.0.1 KAFKA_SCALA_VERSION=2.12
+ - KAFKA_VERSION=2.1.0 KAFKA_SCALA_VERSION=2.12
before_install:
- export REPOSITORY_ROOT=${TRAVIS_BUILD_DIR}
diff --git a/vendor/github.com/Shopify/sarama/CHANGELOG.md b/vendor/github.com/Shopify/sarama/CHANGELOG.md
index afc8511..0e69c2d 100644
--- a/vendor/github.com/Shopify/sarama/CHANGELOG.md
+++ b/vendor/github.com/Shopify/sarama/CHANGELOG.md
@@ -1,5 +1,41 @@
# Changelog
+#### Version 1.21.0 (2019-02-24)
+
+New Features:
+- Add CreateAclRequest, DescribeAclRequest, DeleteAclRequest
+ ([1236](https://github.com/Shopify/sarama/pull/1236)).
+- Add DescribeTopic, DescribeConsumerGroup, ListConsumerGroups, ListConsumerGroupOffsets admin requests
+ ([1178](https://github.com/Shopify/sarama/pull/1178)).
+- Implement SASL/OAUTHBEARER
+ ([1240](https://github.com/Shopify/sarama/pull/1240)).
+
+Improvements:
+- Add Go mod support
+ ([1282](https://github.com/Shopify/sarama/pull/1282)).
+- Add error codes 73—76
+ ([1239](https://github.com/Shopify/sarama/pull/1239)).
+- Add retry backoff function
+ ([1160](https://github.com/Shopify/sarama/pull/1160)).
+- Maintain metadata in the producer even when retries are disabled
+ ([1189](https://github.com/Shopify/sarama/pull/1189)).
+- Include ReplicaAssignment in ListTopics
+ ([1274](https://github.com/Shopify/sarama/pull/1274)).
+- Add producer performance tool
+ ([1222](https://github.com/Shopify/sarama/pull/1222)).
+- Add support LogAppend timestamps
+ ([1258](https://github.com/Shopify/sarama/pull/1258)).
+
+Bug Fixes:
+- Fix potential deadlock when a heartbeat request fails
+ ([1286](https://github.com/Shopify/sarama/pull/1286)).
+- Fix consuming compacted topic
+ ([1227](https://github.com/Shopify/sarama/pull/1227)).
+- Set correct Kafka version for DescribeConfigsRequest v1
+ ([1277](https://github.com/Shopify/sarama/pull/1277)).
+- Update kafka test version
+ ([1273](https://github.com/Shopify/sarama/pull/1273)).
+
#### Version 1.20.1 (2019-01-10)
New Features:
diff --git a/vendor/github.com/Shopify/sarama/Makefile b/vendor/github.com/Shopify/sarama/Makefile
index 8fcf219..09f743c 100644
--- a/vendor/github.com/Shopify/sarama/Makefile
+++ b/vendor/github.com/Shopify/sarama/Makefile
@@ -1,3 +1,5 @@
+export GO111MODULE=on
+
default: fmt vet errcheck test
# Taken from https://github.com/codecov/example-go#caveat-multiple-files
diff --git a/vendor/github.com/Shopify/sarama/acl_bindings.go b/vendor/github.com/Shopify/sarama/acl_bindings.go
index 5151735..b91c282 100644
--- a/vendor/github.com/Shopify/sarama/acl_bindings.go
+++ b/vendor/github.com/Shopify/sarama/acl_bindings.go
@@ -1,17 +1,26 @@
package sarama
type Resource struct {
- ResourceType AclResourceType
- ResourceName string
+ ResourceType AclResourceType
+ ResourceName string
+ ResoucePatternType AclResourcePatternType
}
-func (r *Resource) encode(pe packetEncoder) error {
+func (r *Resource) encode(pe packetEncoder, version int16) error {
pe.putInt8(int8(r.ResourceType))
if err := pe.putString(r.ResourceName); err != nil {
return err
}
+ if version == 1 {
+ if r.ResoucePatternType == AclPatternUnknown {
+ Logger.Print("Cannot encode an unknown resource pattern type, using Literal instead")
+ r.ResoucePatternType = AclPatternLiteral
+ }
+ pe.putInt8(int8(r.ResoucePatternType))
+ }
+
return nil
}
@@ -25,6 +34,13 @@
if r.ResourceName, err = pd.getString(); err != nil {
return err
}
+ if version == 1 {
+ pattern, err := pd.getInt8()
+ if err != nil {
+ return err
+ }
+ r.ResoucePatternType = AclResourcePatternType(pattern)
+ }
return nil
}
@@ -80,8 +96,8 @@
Acls []*Acl
}
-func (r *ResourceAcls) encode(pe packetEncoder) error {
- if err := r.Resource.encode(pe); err != nil {
+func (r *ResourceAcls) encode(pe packetEncoder, version int16) error {
+ if err := r.Resource.encode(pe, version); err != nil {
return err
}
diff --git a/vendor/github.com/Shopify/sarama/acl_create_request.go b/vendor/github.com/Shopify/sarama/acl_create_request.go
index 0b6ecbe..d3d5ad8 100644
--- a/vendor/github.com/Shopify/sarama/acl_create_request.go
+++ b/vendor/github.com/Shopify/sarama/acl_create_request.go
@@ -1,6 +1,7 @@
package sarama
type CreateAclsRequest struct {
+ Version int16
AclCreations []*AclCreation
}
@@ -10,7 +11,7 @@
}
for _, aclCreation := range c.AclCreations {
- if err := aclCreation.encode(pe); err != nil {
+ if err := aclCreation.encode(pe, c.Version); err != nil {
return err
}
}
@@ -19,6 +20,7 @@
}
func (c *CreateAclsRequest) decode(pd packetDecoder, version int16) (err error) {
+ c.Version = version
n, err := pd.getArrayLength()
if err != nil {
return err
@@ -41,11 +43,16 @@
}
func (d *CreateAclsRequest) version() int16 {
- return 0
+ return d.Version
}
func (d *CreateAclsRequest) requiredVersion() KafkaVersion {
- return V0_11_0_0
+ switch d.Version {
+ case 1:
+ return V2_0_0_0
+ default:
+ return V0_11_0_0
+ }
}
type AclCreation struct {
@@ -53,8 +60,8 @@
Acl
}
-func (a *AclCreation) encode(pe packetEncoder) error {
- if err := a.Resource.encode(pe); err != nil {
+func (a *AclCreation) encode(pe packetEncoder, version int16) error {
+ if err := a.Resource.encode(pe, version); err != nil {
return err
}
if err := a.Acl.encode(pe); err != nil {
diff --git a/vendor/github.com/Shopify/sarama/acl_delete_request.go b/vendor/github.com/Shopify/sarama/acl_delete_request.go
index 4133dce..5e94ad7 100644
--- a/vendor/github.com/Shopify/sarama/acl_delete_request.go
+++ b/vendor/github.com/Shopify/sarama/acl_delete_request.go
@@ -1,6 +1,7 @@
package sarama
type DeleteAclsRequest struct {
+ Version int
Filters []*AclFilter
}
@@ -10,6 +11,7 @@
}
for _, filter := range d.Filters {
+ filter.Version = d.Version
if err := filter.encode(pe); err != nil {
return err
}
@@ -19,6 +21,7 @@
}
func (d *DeleteAclsRequest) decode(pd packetDecoder, version int16) (err error) {
+ d.Version = int(version)
n, err := pd.getArrayLength()
if err != nil {
return err
@@ -27,6 +30,7 @@
d.Filters = make([]*AclFilter, n)
for i := 0; i < n; i++ {
d.Filters[i] = new(AclFilter)
+ d.Filters[i].Version = int(version)
if err := d.Filters[i].decode(pd, version); err != nil {
return err
}
@@ -40,9 +44,14 @@
}
func (d *DeleteAclsRequest) version() int16 {
- return 0
+ return int16(d.Version)
}
func (d *DeleteAclsRequest) requiredVersion() KafkaVersion {
- return V0_11_0_0
+ switch d.Version {
+ case 1:
+ return V2_0_0_0
+ default:
+ return V0_11_0_0
+ }
}
diff --git a/vendor/github.com/Shopify/sarama/acl_delete_response.go b/vendor/github.com/Shopify/sarama/acl_delete_response.go
index b5e1c45..a885fe5 100644
--- a/vendor/github.com/Shopify/sarama/acl_delete_response.go
+++ b/vendor/github.com/Shopify/sarama/acl_delete_response.go
@@ -3,6 +3,7 @@
import "time"
type DeleteAclsResponse struct {
+ Version int16
ThrottleTime time.Duration
FilterResponses []*FilterResponse
}
@@ -15,7 +16,7 @@
}
for _, filterResponse := range a.FilterResponses {
- if err := filterResponse.encode(pe); err != nil {
+ if err := filterResponse.encode(pe, a.Version); err != nil {
return err
}
}
@@ -51,7 +52,7 @@
}
func (d *DeleteAclsResponse) version() int16 {
- return 0
+ return int16(d.Version)
}
func (d *DeleteAclsResponse) requiredVersion() KafkaVersion {
@@ -64,7 +65,7 @@
MatchingAcls []*MatchingAcl
}
-func (f *FilterResponse) encode(pe packetEncoder) error {
+func (f *FilterResponse) encode(pe packetEncoder, version int16) error {
pe.putInt16(int16(f.Err))
if err := pe.putNullableString(f.ErrMsg); err != nil {
return err
@@ -74,7 +75,7 @@
return err
}
for _, matchingAcl := range f.MatchingAcls {
- if err := matchingAcl.encode(pe); err != nil {
+ if err := matchingAcl.encode(pe, version); err != nil {
return err
}
}
@@ -115,13 +116,13 @@
Acl
}
-func (m *MatchingAcl) encode(pe packetEncoder) error {
+func (m *MatchingAcl) encode(pe packetEncoder, version int16) error {
pe.putInt16(int16(m.Err))
if err := pe.putNullableString(m.ErrMsg); err != nil {
return err
}
- if err := m.Resource.encode(pe); err != nil {
+ if err := m.Resource.encode(pe, version); err != nil {
return err
}
diff --git a/vendor/github.com/Shopify/sarama/acl_describe_request.go b/vendor/github.com/Shopify/sarama/acl_describe_request.go
index 02a5a1f..3c95320 100644
--- a/vendor/github.com/Shopify/sarama/acl_describe_request.go
+++ b/vendor/github.com/Shopify/sarama/acl_describe_request.go
@@ -1,14 +1,18 @@
package sarama
type DescribeAclsRequest struct {
+ Version int
AclFilter
}
func (d *DescribeAclsRequest) encode(pe packetEncoder) error {
+ d.AclFilter.Version = d.Version
return d.AclFilter.encode(pe)
}
func (d *DescribeAclsRequest) decode(pd packetDecoder, version int16) (err error) {
+ d.Version = int(version)
+ d.AclFilter.Version = int(version)
return d.AclFilter.decode(pd, version)
}
@@ -17,9 +21,14 @@
}
func (d *DescribeAclsRequest) version() int16 {
- return 0
+ return int16(d.Version)
}
func (d *DescribeAclsRequest) requiredVersion() KafkaVersion {
- return V0_11_0_0
+ switch d.Version {
+ case 1:
+ return V2_0_0_0
+ default:
+ return V0_11_0_0
+ }
}
diff --git a/vendor/github.com/Shopify/sarama/acl_describe_response.go b/vendor/github.com/Shopify/sarama/acl_describe_response.go
index 5bc9497..db3a88c 100644
--- a/vendor/github.com/Shopify/sarama/acl_describe_response.go
+++ b/vendor/github.com/Shopify/sarama/acl_describe_response.go
@@ -3,6 +3,7 @@
import "time"
type DescribeAclsResponse struct {
+ Version int16
ThrottleTime time.Duration
Err KError
ErrMsg *string
@@ -22,7 +23,7 @@
}
for _, resourceAcl := range d.ResourceAcls {
- if err := resourceAcl.encode(pe); err != nil {
+ if err := resourceAcl.encode(pe, d.Version); err != nil {
return err
}
}
@@ -72,9 +73,14 @@
}
func (d *DescribeAclsResponse) version() int16 {
- return 0
+ return int16(d.Version)
}
func (d *DescribeAclsResponse) requiredVersion() KafkaVersion {
- return V0_11_0_0
+ switch d.Version {
+ case 1:
+ return V2_0_0_0
+ default:
+ return V0_11_0_0
+ }
}
diff --git a/vendor/github.com/Shopify/sarama/acl_filter.go b/vendor/github.com/Shopify/sarama/acl_filter.go
index 9706354..fad5558 100644
--- a/vendor/github.com/Shopify/sarama/acl_filter.go
+++ b/vendor/github.com/Shopify/sarama/acl_filter.go
@@ -1,12 +1,14 @@
package sarama
type AclFilter struct {
- ResourceType AclResourceType
- ResourceName *string
- Principal *string
- Host *string
- Operation AclOperation
- PermissionType AclPermissionType
+ Version int
+ ResourceType AclResourceType
+ ResourceName *string
+ ResourcePatternTypeFilter AclResourcePatternType
+ Principal *string
+ Host *string
+ Operation AclOperation
+ PermissionType AclPermissionType
}
func (a *AclFilter) encode(pe packetEncoder) error {
@@ -14,6 +16,11 @@
if err := pe.putNullableString(a.ResourceName); err != nil {
return err
}
+
+ if a.Version == 1 {
+ pe.putInt8(int8(a.ResourcePatternTypeFilter))
+ }
+
if err := pe.putNullableString(a.Principal); err != nil {
return err
}
@@ -37,6 +44,16 @@
return err
}
+ if a.Version == 1 {
+ pattern, err := pd.getInt8()
+
+ if err != nil {
+ return err
+ }
+
+ a.ResourcePatternTypeFilter = AclResourcePatternType(pattern)
+ }
+
if a.Principal, err = pd.getNullableString(); err != nil {
return err
}
diff --git a/vendor/github.com/Shopify/sarama/acl_types.go b/vendor/github.com/Shopify/sarama/acl_types.go
index 19da6f2..72b7985 100644
--- a/vendor/github.com/Shopify/sarama/acl_types.go
+++ b/vendor/github.com/Shopify/sarama/acl_types.go
@@ -40,3 +40,15 @@
AclResourceCluster AclResourceType = 4
AclResourceTransactionalID AclResourceType = 5
)
+
+type AclResourcePatternType int
+
+// ref: https://github.com/apache/kafka/blob/trunk/clients/src/main/java/org/apache/kafka/common/resource/PatternType.java
+
+const (
+ AclPatternUnknown AclResourcePatternType = iota
+ AclPatternAny
+ AclPatternMatch
+ AclPatternLiteral
+ AclPatternPrefixed
+)
diff --git a/vendor/github.com/Shopify/sarama/admin.go b/vendor/github.com/Shopify/sarama/admin.go
index 5272575..18b055a 100644
--- a/vendor/github.com/Shopify/sarama/admin.go
+++ b/vendor/github.com/Shopify/sarama/admin.go
@@ -1,6 +1,10 @@
package sarama
-import "errors"
+import (
+ "errors"
+ "math/rand"
+ "sync"
+)
// ClusterAdmin is the administrative client for Kafka, which supports managing and inspecting topics,
// brokers, configurations and ACLs. The minimum broker version required is 0.10.0.0.
@@ -13,6 +17,12 @@
// may not return information about the new topic.The validateOnly option is supported from version 0.10.2.0.
CreateTopic(topic string, detail *TopicDetail, validateOnly bool) error
+ // List the topics available in the cluster with the default options.
+ ListTopics() (map[string]TopicDetail, error)
+
+ // Describe some topics in the cluster
+ DescribeTopics(topics []string) (metadata []*TopicMetadata, err error)
+
// Delete a topic. It may take several seconds after the DeleteTopic to returns success
// and for all the brokers to become aware that the topics are gone.
// During this time, listTopics may continue to return information about the deleted topic.
@@ -65,6 +75,18 @@
// This operation is supported by brokers with version 0.11.0.0 or higher.
DeleteACL(filter AclFilter, validateOnly bool) ([]MatchingAcl, error)
+ // List the consumer groups available in the cluster.
+ ListConsumerGroups() (map[string]string, error)
+
+ // Describe the given consumer group
+ DescribeConsumerGroups(groups []string) ([]*GroupDescription, error)
+
+ // List the consumer group offsets available in the cluster.
+ ListConsumerGroupOffsets(group string, topicPartitions map[string][]int32) (*OffsetFetchResponse, error)
+
+ // Get information about the nodes in the cluster
+ DescribeCluster() (brokers []*Broker, controllerID int32, err error)
+
// Close shuts down the admin and closes underlying client.
Close() error
}
@@ -150,6 +172,127 @@
return nil
}
+func (ca *clusterAdmin) DescribeTopics(topics []string) (metadata []*TopicMetadata, err error) {
+ controller, err := ca.Controller()
+ if err != nil {
+ return nil, err
+ }
+
+ request := &MetadataRequest{
+ Topics: topics,
+ AllowAutoTopicCreation: false,
+ }
+
+ if ca.conf.Version.IsAtLeast(V0_11_0_0) {
+ request.Version = 4
+ }
+
+ response, err := controller.GetMetadata(request)
+ if err != nil {
+ return nil, err
+ }
+ return response.Topics, nil
+}
+
+func (ca *clusterAdmin) DescribeCluster() (brokers []*Broker, controllerID int32, err error) {
+ controller, err := ca.Controller()
+ if err != nil {
+ return nil, int32(0), err
+ }
+
+ request := &MetadataRequest{
+ Topics: []string{},
+ }
+
+ response, err := controller.GetMetadata(request)
+ if err != nil {
+ return nil, int32(0), err
+ }
+
+ return response.Brokers, response.ControllerID, nil
+}
+
+func (ca *clusterAdmin) findAnyBroker() (*Broker, error) {
+ brokers := ca.client.Brokers()
+ if len(brokers) > 0 {
+ index := rand.Intn(len(brokers))
+ return brokers[index], nil
+ }
+ return nil, errors.New("no available broker")
+}
+
+func (ca *clusterAdmin) ListTopics() (map[string]TopicDetail, error) {
+ // In order to build TopicDetails we need to first get the list of all
+ // topics using a MetadataRequest and then get their configs using a
+ // DescribeConfigsRequest request. To avoid sending many requests to the
+ // broker, we use a single DescribeConfigsRequest.
+
+ // Send the all-topic MetadataRequest
+ b, err := ca.findAnyBroker()
+ if err != nil {
+ return nil, err
+ }
+ _ = b.Open(ca.client.Config())
+
+ metadataReq := &MetadataRequest{}
+ metadataResp, err := b.GetMetadata(metadataReq)
+ if err != nil {
+ return nil, err
+ }
+
+ topicsDetailsMap := make(map[string]TopicDetail)
+
+ var describeConfigsResources []*ConfigResource
+
+ for _, topic := range metadataResp.Topics {
+ topicDetails := TopicDetail{
+ NumPartitions: int32(len(topic.Partitions)),
+ }
+ if len(topic.Partitions) > 0 {
+ topicDetails.ReplicaAssignment = map[int32][]int32{}
+ for _, partition := range topic.Partitions {
+ topicDetails.ReplicaAssignment[partition.ID] = partition.Replicas
+ }
+ topicDetails.ReplicationFactor = int16(len(topic.Partitions[0].Replicas))
+ }
+ topicsDetailsMap[topic.Name] = topicDetails
+
+ // we populate the resources we want to describe from the MetadataResponse
+ topicResource := ConfigResource{
+ Type: TopicResource,
+ Name: topic.Name,
+ }
+ describeConfigsResources = append(describeConfigsResources, &topicResource)
+ }
+
+ // Send the DescribeConfigsRequest
+ describeConfigsReq := &DescribeConfigsRequest{
+ Resources: describeConfigsResources,
+ }
+ describeConfigsResp, err := b.DescribeConfigs(describeConfigsReq)
+ if err != nil {
+ return nil, err
+ }
+
+ for _, resource := range describeConfigsResp.Resources {
+ topicDetails := topicsDetailsMap[resource.Name]
+ topicDetails.ConfigEntries = make(map[string]*string)
+
+ for _, entry := range resource.Configs {
+ // only include non-default non-sensitive config
+ // (don't actually think topic config will ever be sensitive)
+ if entry.Default || entry.Sensitive {
+ continue
+ }
+ topicDetails.ConfigEntries[entry.Name] = &entry.Value
+ }
+
+ topicsDetailsMap[resource.Name] = topicDetails
+ }
+
+ return topicsDetailsMap, nil
+}
+
func (ca *clusterAdmin) DeleteTopic(topic string) error {
if topic == "" {
@@ -380,3 +523,92 @@
}
return mAcls, nil
}
+
+func (ca *clusterAdmin) DescribeConsumerGroups(groups []string) (result []*GroupDescription, err error) {
+ groupsPerBroker := make(map[*Broker][]string)
+
+ for _, group := range groups {
+ controller, err := ca.client.Coordinator(group)
+ if err != nil {
+ return nil, err
+ }
+ groupsPerBroker[controller] = append(groupsPerBroker[controller], group)
+
+ }
+
+ for broker, brokerGroups := range groupsPerBroker {
+ response, err := broker.DescribeGroups(&DescribeGroupsRequest{
+ Groups: brokerGroups,
+ })
+ if err != nil {
+ return nil, err
+ }
+
+ result = append(result, response.Groups...)
+ }
+ return result, nil
+}
+
+func (ca *clusterAdmin) ListConsumerGroups() (allGroups map[string]string, err error) {
+ allGroups = make(map[string]string)
+
+ // Query brokers in parallel, since we have to query *all* brokers
+ brokers := ca.client.Brokers()
+ groupMaps := make(chan map[string]string, len(brokers))
+ errors := make(chan error, len(brokers))
+ wg := sync.WaitGroup{}
+
+ for _, b := range brokers {
+ wg.Add(1)
+ go func(b *Broker, conf *Config) {
+ defer wg.Done()
+ _ = b.Open(conf) // Ensure that broker is opened
+
+ response, err := b.ListGroups(&ListGroupsRequest{})
+ if err != nil {
+ errors <- err
+ return
+ }
+
+ groups := make(map[string]string)
+ for group, typ := range response.Groups {
+ groups[group] = typ
+ }
+
+ groupMaps <- groups
+
+ }(b, ca.conf)
+ }
+
+ wg.Wait()
+ close(groupMaps)
+ close(errors)
+
+ for groupMap := range groupMaps {
+ for group, protocolType := range groupMap {
+ allGroups[group] = protocolType
+ }
+ }
+
+ // Intentionally return only the first error for simplicity
+ err = <-errors
+ return
+}
+
+func (ca *clusterAdmin) ListConsumerGroupOffsets(group string, topicPartitions map[string][]int32) (*OffsetFetchResponse, error) {
+ coordinator, err := ca.client.Coordinator(group)
+ if err != nil {
+ return nil, err
+ }
+
+ request := &OffsetFetchRequest{
+ ConsumerGroup: group,
+ partitions: topicPartitions,
+ }
+
+ if ca.conf.Version.IsAtLeast(V0_8_2_2) {
+ request.Version = 1
+ }
+
+ return coordinator.FetchOffset(request)
+}
diff --git a/vendor/github.com/Shopify/sarama/async_producer.go b/vendor/github.com/Shopify/sarama/async_producer.go
index 89a0c70..5174a35 100644
--- a/vendor/github.com/Shopify/sarama/async_producer.go
+++ b/vendor/github.com/Shopify/sarama/async_producer.go
@@ -483,6 +483,19 @@
return input
}
+func (pp *partitionProducer) backoff(retries int) {
+ var backoff time.Duration
+ if pp.parent.conf.Producer.Retry.BackoffFunc != nil {
+ maxRetries := pp.parent.conf.Producer.Retry.Max
+ backoff = pp.parent.conf.Producer.Retry.BackoffFunc(retries, maxRetries)
+ } else {
+ backoff = pp.parent.conf.Producer.Retry.Backoff
+ }
+ if backoff > 0 {
+ time.Sleep(backoff)
+ }
+}
+
func (pp *partitionProducer) dispatch() {
// try to prefetch the leader; if this doesn't work, we'll do a proper call to `updateLeader`
// on the first message
@@ -493,11 +506,31 @@
pp.brokerProducer.input <- &ProducerMessage{Topic: pp.topic, Partition: pp.partition, flags: syn}
}
+ defer func() {
+ if pp.brokerProducer != nil {
+ pp.parent.unrefBrokerProducer(pp.leader, pp.brokerProducer)
+ }
+ }()
+
for msg := range pp.input {
+
+ if pp.brokerProducer != nil && pp.brokerProducer.abandoned != nil {
+ select {
+ case <-pp.brokerProducer.abandoned:
+ // a message on the abandoned channel means that our current broker selection is out of date
+ Logger.Printf("producer/leader/%s/%d abandoning broker %d\n", pp.topic, pp.partition, pp.leader.ID())
+ pp.parent.unrefBrokerProducer(pp.leader, pp.brokerProducer)
+ pp.brokerProducer = nil
+ time.Sleep(pp.parent.conf.Producer.Retry.Backoff)
+ default:
+ // producer connection is still open.
+ }
+ }
+
if msg.retries > pp.highWatermark {
// a new, higher, retry level; handle it and then back off
pp.newHighWatermark(msg.retries)
- time.Sleep(pp.parent.conf.Producer.Retry.Backoff)
+ pp.backoff(msg.retries)
} else if pp.highWatermark > 0 {
// we are retrying something (else highWatermark would be 0) but this message is not a *new* retry level
if msg.retries < pp.highWatermark {
@@ -525,7 +558,7 @@
if pp.brokerProducer == nil {
if err := pp.updateLeader(); err != nil {
pp.parent.returnError(msg, err)
- time.Sleep(pp.parent.conf.Producer.Retry.Backoff)
+ pp.backoff(msg.retries)
continue
}
Logger.Printf("producer/leader/%s/%d selected broker %d\n", pp.topic, pp.partition, pp.leader.ID())
@@ -533,10 +566,6 @@
pp.brokerProducer.input <- msg
}
-
- if pp.brokerProducer != nil {
- pp.parent.unrefBrokerProducer(pp.leader, pp.brokerProducer)
- }
}
func (pp *partitionProducer) newHighWatermark(hwm int) {
@@ -637,6 +666,10 @@
close(responses)
})
+ if p.conf.Producer.Retry.Max <= 0 {
+ bp.abandoned = make(chan struct{})
+ }
+
return bp
}
@@ -655,6 +688,7 @@
input chan *ProducerMessage
output chan<- *produceSet
responses <-chan *brokerProducerResponse
+ abandoned chan struct{}
buffer *produceSet
timer <-chan time.Time
@@ -829,9 +863,17 @@
// Retriable errors
case ErrInvalidMessage, ErrUnknownTopicOrPartition, ErrLeaderNotAvailable, ErrNotLeaderForPartition,
ErrRequestTimedOut, ErrNotEnoughReplicas, ErrNotEnoughReplicasAfterAppend:
- retryTopics = append(retryTopics, topic)
+ if bp.parent.conf.Producer.Retry.Max <= 0 {
+ bp.parent.abandonBrokerConnection(bp.broker)
+ bp.parent.returnErrors(pSet.msgs, block.Err)
+ } else {
+ retryTopics = append(retryTopics, topic)
+ }
// Other non-retriable errors
default:
+ if bp.parent.conf.Producer.Retry.Max <= 0 {
+ bp.parent.abandonBrokerConnection(bp.broker)
+ }
bp.parent.returnErrors(pSet.msgs, block.Err)
}
})
@@ -1048,5 +1090,10 @@
p.brokerLock.Lock()
defer p.brokerLock.Unlock()
+ bc, ok := p.brokers[broker]
+ if ok && bc.abandoned != nil {
+ close(bc.abandoned)
+ }
+
delete(p.brokers, broker)
}
diff --git a/vendor/github.com/Shopify/sarama/broker.go b/vendor/github.com/Shopify/sarama/broker.go
index 6a33b80..9129089 100644
--- a/vendor/github.com/Shopify/sarama/broker.go
+++ b/vendor/github.com/Shopify/sarama/broker.go
@@ -6,7 +6,9 @@
"fmt"
"io"
"net"
+ "sort"
"strconv"
+ "strings"
"sync"
"sync/atomic"
"time"
@@ -46,6 +48,50 @@
brokerResponseSize metrics.Histogram
}
+// SASLMechanism specifies the SASL mechanism the client uses to authenticate with the broker
+type SASLMechanism string
+
+const (
+ // SASLTypeOAuth represents the SASL/OAUTHBEARER mechanism (Kafka 2.0.0+)
+ SASLTypeOAuth = "OAUTHBEARER"
+ // SASLTypePlaintext represents the SASL/PLAIN mechanism
+ SASLTypePlaintext = "PLAIN"
+ // SASLHandshakeV0 is v0 of the Kafka SASL handshake protocol. Client and
+ // server negotiate SASL auth using opaque packets.
+ SASLHandshakeV0 = int16(0)
+ // SASLHandshakeV1 is v1 of the Kafka SASL handshake protocol. Client and
+ // server negotiate SASL by wrapping tokens with Kafka protocol headers.
+ SASLHandshakeV1 = int16(1)
+ // SASLExtKeyAuth is the reserved extension key name sent as part of the
+ // SASL/OAUTHBEARER intial client response
+ SASLExtKeyAuth = "auth"
+)
+
+// AccessToken contains an access token used to authenticate a
+// SASL/OAUTHBEARER client along with associated metadata.
+type AccessToken struct {
+ // Token is the access token payload.
+ Token string
+ // Extensions is a optional map of arbitrary key-value pairs that can be
+ // sent with the SASL/OAUTHBEARER initial client response. These values are
+ // ignored by the SASL server if they are unexpected. This feature is only
+ // supported by Kafka >= 2.1.0.
+ Extensions map[string]string
+}
+
+// AccessTokenProvider is the interface that encapsulates how implementors
+// can generate access tokens for Kafka broker authentication.
+type AccessTokenProvider interface {
+ // Token returns an access token. The implementation should ensure token
+ // reuse so that multiple calls at connect time do not create multiple
+ // tokens. The implementation should also periodically refresh the token in
+ // order to guarantee that each call returns an unexpired token. This
+ // method should not block indefinitely--a timeout error should be returned
+ // after a short period of inactivity so that the broker connection logic
+ // can log debugging information and retry.
+ Token() (*AccessToken, error)
+}
+
type responsePromise struct {
requestTime time.Time
correlationID int32
@@ -125,7 +171,9 @@
}
if conf.Net.SASL.Enable {
- b.connErr = b.sendAndReceiveSASLPlainAuth()
+
+ b.connErr = b.authenticateViaSASL()
+
if b.connErr != nil {
err = b.conn.Close()
if err == nil {
@@ -744,8 +792,16 @@
close(b.done)
}
-func (b *Broker) sendAndReceiveSASLPlainHandshake() error {
- rb := &SaslHandshakeRequest{"PLAIN"}
+func (b *Broker) authenticateViaSASL() error {
+ if b.conf.Net.SASL.Mechanism == SASLTypeOAuth {
+ return b.sendAndReceiveSASLOAuth(b.conf.Net.SASL.TokenProvider)
+ }
+ return b.sendAndReceiveSASLPlainAuth()
+}
+
+func (b *Broker) sendAndReceiveSASLHandshake(saslType string, version int16) error {
+ rb := &SaslHandshakeRequest{Mechanism: saslType, Version: version}
+
req := &request{correlationID: b.correlationID, clientID: b.conf.ClientID, body: rb}
buf, err := encode(req, b.conf.MetricRegistry)
if err != nil {
@@ -814,7 +870,7 @@
// of responding to bad credentials but thats how its being done today.
func (b *Broker) sendAndReceiveSASLPlainAuth() error {
if b.conf.Net.SASL.Handshake {
- handshakeErr := b.sendAndReceiveSASLPlainHandshake()
+ handshakeErr := b.sendAndReceiveSASLHandshake(SASLTypePlaintext, SASLHandshakeV0)
if handshakeErr != nil {
Logger.Printf("Error while performing SASL handshake %s\n", b.addr)
return handshakeErr
@@ -853,6 +909,157 @@
return nil
}
+// sendAndReceiveSASLOAuth performs the authentication flow as described by KIP-255
+// https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=75968876
+func (b *Broker) sendAndReceiveSASLOAuth(provider AccessTokenProvider) error {
+
+ if err := b.sendAndReceiveSASLHandshake(SASLTypeOAuth, SASLHandshakeV1); err != nil {
+ return err
+ }
+
+ token, err := provider.Token()
+
+ if err != nil {
+ return err
+ }
+
+ requestTime := time.Now()
+
+ correlationID := b.correlationID
+
+ bytesWritten, err := b.sendSASLOAuthBearerClientResponse(token, correlationID)
+
+ if err != nil {
+ return err
+ }
+
+ b.updateOutgoingCommunicationMetrics(bytesWritten)
+
+ b.correlationID++
+
+ bytesRead, err := b.receiveSASLOAuthBearerServerResponse(correlationID)
+
+ if err != nil {
+ return err
+ }
+
+ requestLatency := time.Since(requestTime)
+ b.updateIncomingCommunicationMetrics(bytesRead, requestLatency)
+
+ return nil
+}
+
+// Build SASL/OAUTHBEARER initial client response as described by RFC-7628
+// https://tools.ietf.org/html/rfc7628
+func buildClientInitialResponse(token *AccessToken) ([]byte, error) {
+
+ var ext string
+
+ if token.Extensions != nil && len(token.Extensions) > 0 {
+ if _, ok := token.Extensions[SASLExtKeyAuth]; ok {
+ return []byte{}, fmt.Errorf("The extension `%s` is invalid", SASLExtKeyAuth)
+ }
+ ext = "\x01" + mapToString(token.Extensions, "=", "\x01")
+ }
+
+ resp := []byte(fmt.Sprintf("n,,\x01auth=Bearer %s%s\x01\x01", token.Token, ext))
+
+ return resp, nil
+}
+
+// mapToString returns a list of key-value pairs ordered by key.
+// keyValSep separates the key from the value. elemSep separates each pair.
+func mapToString(extensions map[string]string, keyValSep string, elemSep string) string {
+
+ buf := make([]string, 0, len(extensions))
+
+ for k, v := range extensions {
+ buf = append(buf, k+keyValSep+v)
+ }
+
+ sort.Strings(buf)
+
+ return strings.Join(buf, elemSep)
+}
+
+func (b *Broker) sendSASLOAuthBearerClientResponse(token *AccessToken, correlationID int32) (int, error) {
+
+ initialResp, err := buildClientInitialResponse(token)
+
+ if err != nil {
+ return 0, err
+ }
+
+ rb := &SaslAuthenticateRequest{initialResp}
+
+ req := &request{correlationID: correlationID, clientID: b.conf.ClientID, body: rb}
+
+ buf, err := encode(req, b.conf.MetricRegistry)
+
+ if err != nil {
+ return 0, err
+ }
+
+ if err := b.conn.SetWriteDeadline(time.Now().Add(b.conf.Net.WriteTimeout)); err != nil {
+ return 0, err
+ }
+
+ return b.conn.Write(buf)
+}
+
+func (b *Broker) receiveSASLOAuthBearerServerResponse(correlationID int32) (int, error) {
+
+ buf := make([]byte, 8)
+
+ bytesRead, err := io.ReadFull(b.conn, buf)
+
+ if err != nil {
+ return bytesRead, err
+ }
+
+ header := responseHeader{}
+
+ err = decode(buf, &header)
+
+ if err != nil {
+ return bytesRead, err
+ }
+
+ if header.correlationID != correlationID {
+ return bytesRead, fmt.Errorf("correlation ID didn't match, wanted %d, got %d", b.correlationID, header.correlationID)
+ }
+
+ buf = make([]byte, header.length-4)
+
+ c, err := io.ReadFull(b.conn, buf)
+
+ bytesRead += c
+
+ if err != nil {
+ return bytesRead, err
+ }
+
+ res := &SaslAuthenticateResponse{}
+
+ if err := versionedDecode(buf, res, 0); err != nil {
+ return bytesRead, err
+ }
+
+ if err != nil {
+ return bytesRead, err
+ }
+
+ if res.Err != ErrNoError {
+ return bytesRead, res.Err
+ }
+
+ if len(res.SaslAuthBytes) > 0 {
+ Logger.Printf("Received SASL auth response: %s", res.SaslAuthBytes)
+ }
+
+ return bytesRead, nil
+}
+
func (b *Broker) updateIncomingCommunicationMetrics(bytes int, requestLatency time.Duration) {
b.updateRequestLatencyMetrics(requestLatency)
b.responseRate.Mark(1)
diff --git a/vendor/github.com/Shopify/sarama/client.go b/vendor/github.com/Shopify/sarama/client.go
index 79be5ce..0016f8f 100644
--- a/vendor/github.com/Shopify/sarama/client.go
+++ b/vendor/github.com/Shopify/sarama/client.go
@@ -710,8 +710,11 @@
func (client *client) tryRefreshMetadata(topics []string, attemptsRemaining int) error {
retry := func(err error) error {
if attemptsRemaining > 0 {
+ backoff := client.computeBackoff(attemptsRemaining)
Logger.Printf("client/metadata retrying after %dms... (%d attempts remaining)\n", client.conf.Metadata.Retry.Backoff/time.Millisecond, attemptsRemaining)
- time.Sleep(client.conf.Metadata.Retry.Backoff)
+ if backoff > 0 {
+ time.Sleep(backoff)
+ }
return client.tryRefreshMetadata(topics, attemptsRemaining-1)
}
return err
@@ -839,11 +842,22 @@
return client.brokers[client.controllerID]
}
+func (client *client) computeBackoff(attemptsRemaining int) time.Duration {
+ if client.conf.Metadata.Retry.BackoffFunc != nil {
+ maxRetries := client.conf.Metadata.Retry.Max
+ retries := maxRetries - attemptsRemaining
+ return client.conf.Metadata.Retry.BackoffFunc(retries, maxRetries)
+ } else {
+ return client.conf.Metadata.Retry.Backoff
+ }
+}
+
func (client *client) getConsumerMetadata(consumerGroup string, attemptsRemaining int) (*FindCoordinatorResponse, error) {
retry := func(err error) (*FindCoordinatorResponse, error) {
if attemptsRemaining > 0 {
- Logger.Printf("client/coordinator retrying after %dms... (%d attempts remaining)\n", client.conf.Metadata.Retry.Backoff/time.Millisecond, attemptsRemaining)
- time.Sleep(client.conf.Metadata.Retry.Backoff)
+ backoff := client.computeBackoff(attemptsRemaining)
+ Logger.Printf("client/coordinator retrying after %dms... (%d attempts remaining)\n", backoff/time.Millisecond, attemptsRemaining)
+ time.Sleep(backoff)
return client.getConsumerMetadata(consumerGroup, attemptsRemaining-1)
}
return nil, err
diff --git a/vendor/github.com/Shopify/sarama/config.go b/vendor/github.com/Shopify/sarama/config.go
index ed20522..9495b7f 100644
--- a/vendor/github.com/Shopify/sarama/config.go
+++ b/vendor/github.com/Shopify/sarama/config.go
@@ -54,6 +54,9 @@
// Whether or not to use SASL authentication when connecting to the broker
// (defaults to false).
Enable bool
+ // SASLMechanism is the name of the enabled SASL mechanism.
+ // Possible values: OAUTHBEARER, PLAIN (defaults to PLAIN).
+ Mechanism SASLMechanism
// Whether or not to send the Kafka SASL handshake first if enabled
// (defaults to true). You should only set this to false if you're using
// a non-Kafka SASL proxy.
@@ -61,6 +64,11 @@
//username and password for SASL/PLAIN authentication
User string
Password string
+ // TokenProvider is a user-defined callback for generating
+ // access tokens for SASL/OAUTHBEARER auth. See the
+ // AccessTokenProvider interface docs for proper implementation
+ // guidelines.
+ TokenProvider AccessTokenProvider
}
// KeepAlive specifies the keep-alive period for an active network connection.
@@ -84,6 +92,10 @@
// How long to wait for leader election to occur before retrying
// (default 250ms). Similar to the JVM's `retry.backoff.ms`.
Backoff time.Duration
+ // Called to compute backoff time dynamically. Useful for implementing
+ // more sophisticated backoff strategies. This takes precedence over
+ // `Backoff` if set.
+ BackoffFunc func(retries, maxRetries int) time.Duration
}
// How frequently to refresh the cluster metadata in the background.
// Defaults to 10 minutes. Set to 0 to disable. Similar to
@@ -171,6 +183,10 @@
// (default 100ms). Similar to the `retry.backoff.ms` setting of the
// JVM producer.
Backoff time.Duration
+ // Called to compute backoff time dynamically. Useful for implementing
+ // more sophisticated backoff strategies. This takes precedence over
+ // `Backoff` if set.
+ BackoffFunc func(retries, maxRetries int) time.Duration
}
}
@@ -229,6 +245,10 @@
// How long to wait after a failing to read from a partition before
// trying again (default 2s).
Backoff time.Duration
+ // Called to compute backoff time dynamically. Useful for implementing
+ // more sophisticated backoff strategies. This takes precedence over
+ // `Backoff` if set.
+ BackoffFunc func(retries int) time.Duration
}
// Fetch is the namespace for controlling how many bytes are retrieved by any
@@ -454,10 +474,25 @@
return ConfigurationError("Net.WriteTimeout must be > 0")
case c.Net.KeepAlive < 0:
return ConfigurationError("Net.KeepAlive must be >= 0")
- case c.Net.SASL.Enable == true && c.Net.SASL.User == "":
- return ConfigurationError("Net.SASL.User must not be empty when SASL is enabled")
- case c.Net.SASL.Enable == true && c.Net.SASL.Password == "":
- return ConfigurationError("Net.SASL.Password must not be empty when SASL is enabled")
+ case c.Net.SASL.Enable:
+ // For backwards compatibility, empty mechanism value defaults to PLAIN
+ isSASLPlain := len(c.Net.SASL.Mechanism) == 0 || c.Net.SASL.Mechanism == SASLTypePlaintext
+ if isSASLPlain {
+ if c.Net.SASL.User == "" {
+ return ConfigurationError("Net.SASL.User must not be empty when SASL is enabled")
+ }
+ if c.Net.SASL.Password == "" {
+ return ConfigurationError("Net.SASL.Password must not be empty when SASL is enabled")
+ }
+ } else if c.Net.SASL.Mechanism == SASLTypeOAuth {
+ if c.Net.SASL.TokenProvider == nil {
+ return ConfigurationError("An AccessTokenProvider instance must be provided to Net.SASL.User.TokenProvider")
+ }
+ } else {
+ msg := fmt.Sprintf("The SASL mechanism configuration is invalid. Possible values are `%s` and `%s`",
+ SASLTypeOAuth, SASLTypePlaintext)
+ return ConfigurationError(msg)
+ }
}
// validate the Admin values
diff --git a/vendor/github.com/Shopify/sarama/consumer.go b/vendor/github.com/Shopify/sarama/consumer.go
index 33d9d14..ce72ff1 100644
--- a/vendor/github.com/Shopify/sarama/consumer.go
+++ b/vendor/github.com/Shopify/sarama/consumer.go
@@ -314,6 +314,8 @@
fetchSize int32
offset int64
+
+ retries int32
}
var errTimedOut = errors.New("timed out feeding messages to the user") // not user-facing
@@ -332,12 +334,21 @@
}
}
+func (child *partitionConsumer) computeBackoff() time.Duration {
+ if child.conf.Consumer.Retry.BackoffFunc != nil {
+ retries := atomic.AddInt32(&child.retries, 1)
+ return child.conf.Consumer.Retry.BackoffFunc(int(retries))
+ } else {
+ return child.conf.Consumer.Retry.Backoff
+ }
+}
+
func (child *partitionConsumer) dispatcher() {
for range child.trigger {
select {
case <-child.dying:
close(child.trigger)
- case <-time.After(child.conf.Consumer.Retry.Backoff):
+ case <-time.After(child.computeBackoff()):
if child.broker != nil {
child.consumer.unrefBrokerConsumer(child.broker)
child.broker = nil
@@ -451,6 +462,10 @@
for response := range child.feeder {
msgs, child.responseResult = child.parseResponse(response)
+ if child.responseResult == nil {
+ atomic.StoreInt32(&child.retries, 0)
+ }
+
for i, msg := range msgs {
messageSelect:
select {
@@ -487,9 +502,13 @@
for _, msgBlock := range msgSet.Messages {
for _, msg := range msgBlock.Messages() {
offset := msg.Offset
+ timestamp := msg.Msg.Timestamp
if msg.Msg.Version >= 1 {
baseOffset := msgBlock.Offset - msgBlock.Messages()[len(msgBlock.Messages())-1].Offset
offset += baseOffset
+ if msg.Msg.LogAppendTime {
+ timestamp = msgBlock.Msg.Timestamp
+ }
}
if offset < child.offset {
continue
@@ -500,14 +519,14 @@
Key: msg.Msg.Key,
Value: msg.Msg.Value,
Offset: offset,
- Timestamp: msg.Msg.Timestamp,
+ Timestamp: timestamp,
BlockTimestamp: msgBlock.Msg.Timestamp,
})
child.offset = offset + 1
}
}
if len(messages) == 0 {
- return nil, ErrIncompleteResponse
+ child.offset++
}
return messages, nil
}
@@ -519,19 +538,23 @@
if offset < child.offset {
continue
}
+ timestamp := batch.FirstTimestamp.Add(rec.TimestampDelta)
+ if batch.LogAppendTime {
+ timestamp = batch.MaxTimestamp
+ }
messages = append(messages, &ConsumerMessage{
Topic: child.topic,
Partition: child.partition,
Key: rec.Key,
Value: rec.Value,
Offset: offset,
- Timestamp: batch.FirstTimestamp.Add(rec.TimestampDelta),
+ Timestamp: timestamp,
Headers: rec.Headers,
})
child.offset = offset + 1
}
if len(messages) == 0 {
- child.offset += 1
+ child.offset++
}
return messages, nil
}
@@ -787,6 +810,9 @@
MinBytes: bc.consumer.conf.Consumer.Fetch.Min,
MaxWaitTime: int32(bc.consumer.conf.Consumer.MaxWaitTime / time.Millisecond),
}
+ if bc.consumer.conf.Version.IsAtLeast(V0_9_0_0) {
+ request.Version = 1
+ }
if bc.consumer.conf.Version.IsAtLeast(V0_10_0_0) {
request.Version = 2
}
diff --git a/vendor/github.com/Shopify/sarama/consumer_group.go b/vendor/github.com/Shopify/sarama/consumer_group.go
index bb6a2c2..8c8babc 100644
--- a/vendor/github.com/Shopify/sarama/consumer_group.go
+++ b/vendor/github.com/Shopify/sarama/consumer_group.go
@@ -657,6 +657,12 @@
resp, err := s.parent.heartbeatRequest(coordinator, s.memberID, s.generationID)
if err != nil {
_ = coordinator.Close()
+
+ if retries <= 0 {
+ s.parent.handleError(err, "", -1)
+ return
+ }
+
retries--
continue
}
diff --git a/vendor/github.com/Shopify/sarama/describe_configs_request.go b/vendor/github.com/Shopify/sarama/describe_configs_request.go
index 416a4fe..ccb587b 100644
--- a/vendor/github.com/Shopify/sarama/describe_configs_request.go
+++ b/vendor/github.com/Shopify/sarama/describe_configs_request.go
@@ -103,7 +103,7 @@
func (r *DescribeConfigsRequest) requiredVersion() KafkaVersion {
switch r.Version {
case 1:
- return V1_0_0_0
+ return V1_1_0_0
case 2:
return V2_0_0_0
default:
diff --git a/vendor/github.com/Shopify/sarama/errors.go b/vendor/github.com/Shopify/sarama/errors.go
index c11421d..87a4c61 100644
--- a/vendor/github.com/Shopify/sarama/errors.go
+++ b/vendor/github.com/Shopify/sarama/errors.go
@@ -157,6 +157,10 @@
ErrFetchSessionIDNotFound KError = 70
ErrInvalidFetchSessionEpoch KError = 71
ErrListenerNotFound KError = 72
+ ErrTopicDeletionDisabled KError = 73
+ ErrFencedLeaderEpoch KError = 74
+ ErrUnknownLeaderEpoch KError = 75
+ ErrUnsupportedCompressionType KError = 76
)
func (err KError) Error() string {
@@ -311,6 +315,14 @@
return "kafka server: The fetch session epoch is invalid."
case ErrListenerNotFound:
return "kafka server: There is no listener on the leader broker that matches the listener on which metadata request was processed."
+ case ErrTopicDeletionDisabled:
+ return "kafka server: Topic deletion is disabled."
+ case ErrFencedLeaderEpoch:
+ return "kafka server: The leader epoch in the request is older than the epoch on the broker."
+ case ErrUnknownLeaderEpoch:
+ return "kafka server: The leader epoch in the request is newer than the epoch on the broker."
+ case ErrUnsupportedCompressionType:
+ return "kafka server: The requesting client does not support the compression type of given partition."
}
return fmt.Sprintf("Unknown error, how did this happen? Error code = %d", err)
diff --git a/vendor/github.com/Shopify/sarama/fetch_response.go b/vendor/github.com/Shopify/sarama/fetch_response.go
index 90acfc2..9df99c1 100644
--- a/vendor/github.com/Shopify/sarama/fetch_response.go
+++ b/vendor/github.com/Shopify/sarama/fetch_response.go
@@ -186,9 +186,11 @@
}
type FetchResponse struct {
- Blocks map[string]map[int32]*FetchResponseBlock
- ThrottleTime time.Duration
- Version int16 // v1 requires 0.9+, v2 requires 0.10+
+ Blocks map[string]map[int32]*FetchResponseBlock
+ ThrottleTime time.Duration
+ Version int16 // v1 requires 0.9+, v2 requires 0.10+
+ LogAppendTime bool
+ Timestamp time.Time
}
func (r *FetchResponse) decode(pd packetDecoder, version int16) (err error) {
@@ -355,10 +357,13 @@
return kb, vb
}
-func (r *FetchResponse) AddMessage(topic string, partition int32, key, value Encoder, offset int64) {
+func (r *FetchResponse) AddMessageWithTimestamp(topic string, partition int32, key, value Encoder, offset int64, timestamp time.Time, version int8) {
frb := r.getOrCreateBlock(topic, partition)
kb, vb := encodeKV(key, value)
- msg := &Message{Key: kb, Value: vb}
+ if r.LogAppendTime {
+ timestamp = r.Timestamp
+ }
+ msg := &Message{Key: kb, Value: vb, LogAppendTime: r.LogAppendTime, Timestamp: timestamp, Version: version}
msgBlock := &MessageBlock{Msg: msg, Offset: offset}
if len(frb.RecordsSet) == 0 {
records := newLegacyRecords(&MessageSet{})
@@ -368,18 +373,26 @@
set.Messages = append(set.Messages, msgBlock)
}
-func (r *FetchResponse) AddRecord(topic string, partition int32, key, value Encoder, offset int64) {
+func (r *FetchResponse) AddRecordWithTimestamp(topic string, partition int32, key, value Encoder, offset int64, timestamp time.Time) {
frb := r.getOrCreateBlock(topic, partition)
kb, vb := encodeKV(key, value)
- rec := &Record{Key: kb, Value: vb, OffsetDelta: offset}
if len(frb.RecordsSet) == 0 {
- records := newDefaultRecords(&RecordBatch{Version: 2})
+ records := newDefaultRecords(&RecordBatch{Version: 2, LogAppendTime: r.LogAppendTime, FirstTimestamp: timestamp, MaxTimestamp: r.Timestamp})
frb.RecordsSet = []*Records{&records}
}
batch := frb.RecordsSet[0].RecordBatch
+ rec := &Record{Key: kb, Value: vb, OffsetDelta: offset, TimestampDelta: timestamp.Sub(batch.FirstTimestamp)}
batch.addRecord(rec)
}
+func (r *FetchResponse) AddMessage(topic string, partition int32, key, value Encoder, offset int64) {
+ r.AddMessageWithTimestamp(topic, partition, key, value, offset, time.Time{}, 0)
+}
+
+func (r *FetchResponse) AddRecord(topic string, partition int32, key, value Encoder, offset int64) {
+ r.AddRecordWithTimestamp(topic, partition, key, value, offset, time.Time{})
+}
+
func (r *FetchResponse) SetLastOffsetDelta(topic string, partition int32, offset int32) {
frb := r.getOrCreateBlock(topic, partition)
if len(frb.RecordsSet) == 0 {
diff --git a/vendor/github.com/Shopify/sarama/message.go b/vendor/github.com/Shopify/sarama/message.go
index 51d3309..f64c79b 100644
--- a/vendor/github.com/Shopify/sarama/message.go
+++ b/vendor/github.com/Shopify/sarama/message.go
@@ -5,12 +5,15 @@
"time"
)
-// CompressionCodec represents the various compression codecs recognized by Kafka in messages.
-type CompressionCodec int8
-
// The lowest 3 bits contain the compression codec used for the message
const compressionCodecMask int8 = 0x07
+// Bit 3 set for "LogAppend" timestamps
+const timestampTypeMask = 0x08
+
+// CompressionCodec represents the various compression codecs recognized by Kafka in messages.
+type CompressionCodec int8
+
const (
CompressionNone CompressionCodec = 0
CompressionGZIP CompressionCodec = 1
@@ -36,6 +39,7 @@
type Message struct {
Codec CompressionCodec // codec used to compress the message contents
CompressionLevel int // compression level
+ LogAppendTime bool // the used timestamp is LogAppendTime
Key []byte // the message key, may be nil
Value []byte // the message contents
Set *MessageSet // the message set a message might wrap
@@ -52,6 +56,9 @@
pe.putInt8(m.Version)
attributes := int8(m.Codec) & compressionCodecMask
+ if m.LogAppendTime {
+ attributes |= timestampTypeMask
+ }
pe.putInt8(attributes)
if m.Version >= 1 {
@@ -108,6 +115,7 @@
return err
}
m.Codec = CompressionCodec(attribute & compressionCodecMask)
+ m.LogAppendTime = attribute×tampTypeMask == timestampTypeMask
if m.Version == 1 {
if err := (Timestamp{&m.Timestamp}).decode(pd); err != nil {
@@ -149,7 +157,7 @@
return pd.pop()
}
-// decodes a message set from a previousy encoded bulk-message
+// decodes a message set from a previously encoded bulk-message
func (m *Message) decodeSet() (err error) {
pd := realDecoder{raw: m.Value}
m.Set = &MessageSet{}
diff --git a/vendor/github.com/Shopify/sarama/mockresponses.go b/vendor/github.com/Shopify/sarama/mockresponses.go
index fe55200..348c223 100644
--- a/vendor/github.com/Shopify/sarama/mockresponses.go
+++ b/vendor/github.com/Shopify/sarama/mockresponses.go
@@ -66,6 +66,69 @@
return res
}
+type MockListGroupsResponse struct {
+ groups map[string]string
+ t TestReporter
+}
+
+func NewMockListGroupsResponse(t TestReporter) *MockListGroupsResponse {
+ return &MockListGroupsResponse{
+ groups: make(map[string]string),
+ t: t,
+ }
+}
+
+func (m *MockListGroupsResponse) For(reqBody versionedDecoder) encoder {
+ request := reqBody.(*ListGroupsRequest)
+ _ = request
+ response := &ListGroupsResponse{
+ Groups: m.groups,
+ }
+ return response
+}
+
+func (m *MockListGroupsResponse) AddGroup(groupID, protocolType string) *MockListGroupsResponse {
+ m.groups[groupID] = protocolType
+ return m
+}
+
+type MockDescribeGroupsResponse struct {
+ groups map[string]*GroupDescription
+ t TestReporter
+}
+
+func NewMockDescribeGroupsResponse(t TestReporter) *MockDescribeGroupsResponse {
+ return &MockDescribeGroupsResponse{
+ t: t,
+ groups: make(map[string]*GroupDescription),
+ }
+}
+
+func (m *MockDescribeGroupsResponse) AddGroupDescription(groupID string, description *GroupDescription) *MockDescribeGroupsResponse {
+ m.groups[groupID] = description
+ return m
+}
+
+func (m *MockDescribeGroupsResponse) For(reqBody versionedDecoder) encoder {
+ request := reqBody.(*DescribeGroupsRequest)
+
+ response := &DescribeGroupsResponse{}
+ for _, requestedGroup := range request.Groups {
+ if group, ok := m.groups[requestedGroup]; ok {
+ response.Groups = append(response.Groups, group)
+ } else {
+ // Mimic real kafka - if a group doesn't exist, return
+ // an entry with state "Dead"
+ response.Groups = append(response.Groups, &GroupDescription{
+ GroupId: requestedGroup,
+ State: "Dead",
+ })
+ }
+ }
+
+ return response
+}
+
// MockMetadataResponse is a `MetadataResponse` builder.
type MockMetadataResponse struct {
controllerID int32
@@ -111,17 +174,25 @@
for addr, brokerID := range mmr.brokers {
metadataResponse.AddBroker(addr, brokerID)
}
+
+ // Generate set of replicas
+ replicas := []int32{}
+
+ for _, brokerID := range mmr.brokers {
+ replicas = append(replicas, brokerID)
+ }
+
if len(metadataRequest.Topics) == 0 {
for topic, partitions := range mmr.leaders {
for partition, brokerID := range partitions {
- metadataResponse.AddTopicPartition(topic, partition, brokerID, nil, nil, ErrNoError)
+ metadataResponse.AddTopicPartition(topic, partition, brokerID, replicas, replicas, ErrNoError)
}
}
return metadataResponse
}
for _, topic := range metadataRequest.Topics {
for partition, brokerID := range mmr.leaders[topic] {
- metadataResponse.AddTopicPartition(topic, partition, brokerID, nil, nil, ErrNoError)
+ metadataResponse.AddTopicPartition(topic, partition, brokerID, replicas, replicas, ErrNoError)
}
}
return metadataResponse
@@ -631,16 +702,32 @@
req := reqBody.(*DescribeConfigsRequest)
res := &DescribeConfigsResponse{}
- var configEntries []*ConfigEntry
- configEntries = append(configEntries, &ConfigEntry{Name: "my_topic",
- Value: "my_topic",
- ReadOnly: true,
- Default: true,
- Sensitive: false,
- })
-
for _, r := range req.Resources {
- res.Resources = append(res.Resources, &ResourceResponse{Name: r.Name, Configs: configEntries})
+ var configEntries []*ConfigEntry
+ switch r.Type {
+ case TopicResource:
+ configEntries = append(configEntries,
+ &ConfigEntry{Name: "max.message.bytes",
+ Value: "1000000",
+ ReadOnly: false,
+ Default: true,
+ Sensitive: false,
+ }, &ConfigEntry{Name: "retention.ms",
+ Value: "5000",
+ ReadOnly: false,
+ Default: false,
+ Sensitive: false,
+ }, &ConfigEntry{Name: "password",
+ Value: "12345",
+ ReadOnly: false,
+ Default: false,
+ Sensitive: true,
+ })
+ res.Resources = append(res.Resources, &ResourceResponse{
+ Name: r.Name,
+ Configs: configEntries,
+ })
+ }
}
return res
}
@@ -706,10 +793,64 @@
return res
}
+type MockSaslAuthenticateResponse struct {
+ t TestReporter
+ kerror KError
+ saslAuthBytes []byte
+}
+
+func NewMockSaslAuthenticateResponse(t TestReporter) *MockSaslAuthenticateResponse {
+ return &MockSaslAuthenticateResponse{t: t}
+}
+
+func (msar *MockSaslAuthenticateResponse) For(reqBody versionedDecoder) encoder {
+ res := &SaslAuthenticateResponse{}
+ res.Err = msar.kerror
+ res.SaslAuthBytes = msar.saslAuthBytes
+ return res
+}
+
+func (msar *MockSaslAuthenticateResponse) SetError(kerror KError) *MockSaslAuthenticateResponse {
+ msar.kerror = kerror
+ return msar
+}
+
+func (msar *MockSaslAuthenticateResponse) SetAuthBytes(saslAuthBytes []byte) *MockSaslAuthenticateResponse {
+ msar.saslAuthBytes = saslAuthBytes
+ return msar
+}
+
type MockDeleteAclsResponse struct {
t TestReporter
}
+type MockSaslHandshakeResponse struct {
+ enabledMechanisms []string
+ kerror KError
+ t TestReporter
+}
+
+func NewMockSaslHandshakeResponse(t TestReporter) *MockSaslHandshakeResponse {
+ return &MockSaslHandshakeResponse{t: t}
+}
+
+func (mshr *MockSaslHandshakeResponse) For(reqBody versionedDecoder) encoder {
+ res := &SaslHandshakeResponse{}
+ res.Err = mshr.kerror
+ res.EnabledMechanisms = mshr.enabledMechanisms
+ return res
+}
+
+func (mshr *MockSaslHandshakeResponse) SetError(kerror KError) *MockSaslHandshakeResponse {
+ mshr.kerror = kerror
+ return mshr
+}
+
+func (mshr *MockSaslHandshakeResponse) SetEnabledMechanisms(enabledMechanisms []string) *MockSaslHandshakeResponse {
+ mshr.enabledMechanisms = enabledMechanisms
+ return mshr
+}
+
func NewMockDeleteAclsResponse(t TestReporter) *MockDeleteAclsResponse {
return &MockDeleteAclsResponse{t: t}
}
diff --git a/vendor/github.com/Shopify/sarama/offset_manager.go b/vendor/github.com/Shopify/sarama/offset_manager.go
index 8ea857f..2432f7b 100644
--- a/vendor/github.com/Shopify/sarama/offset_manager.go
+++ b/vendor/github.com/Shopify/sarama/offset_manager.go
@@ -120,6 +120,14 @@
return nil
}
+func (om *offsetManager) computeBackoff(retries int) time.Duration {
+ if om.conf.Metadata.Retry.BackoffFunc != nil {
+ return om.conf.Metadata.Retry.BackoffFunc(retries, om.conf.Metadata.Retry.Max)
+ } else {
+ return om.conf.Metadata.Retry.Backoff
+ }
+}
+
func (om *offsetManager) fetchInitialOffset(topic string, partition int32, retries int) (int64, string, error) {
broker, err := om.coordinator()
if err != nil {
@@ -161,10 +169,11 @@
if retries <= 0 {
return 0, "", block.Err
}
+ backoff := om.computeBackoff(retries)
select {
case <-om.closing:
return 0, "", block.Err
- case <-time.After(om.conf.Metadata.Retry.Backoff):
+ case <-time.After(backoff):
}
return om.fetchInitialOffset(topic, partition, retries-1)
default:
diff --git a/vendor/github.com/Shopify/sarama/record_batch.go b/vendor/github.com/Shopify/sarama/record_batch.go
index e0f183f..a36f7e6 100644
--- a/vendor/github.com/Shopify/sarama/record_batch.go
+++ b/vendor/github.com/Shopify/sarama/record_batch.go
@@ -36,6 +36,7 @@
Codec CompressionCodec
CompressionLevel int
Control bool
+ LogAppendTime bool
LastOffsetDelta int32
FirstTimestamp time.Time
MaxTimestamp time.Time
@@ -120,6 +121,7 @@
}
b.Codec = CompressionCodec(int8(attributes) & compressionCodecMask)
b.Control = attributes&controlMask == controlMask
+ b.LogAppendTime = attributes×tampTypeMask == timestampTypeMask
if b.LastOffsetDelta, err = pd.getInt32(); err != nil {
return err
@@ -200,6 +202,9 @@
if b.Control {
attr |= controlMask
}
+ if b.LogAppendTime {
+ attr |= timestampTypeMask
+ }
return attr
}
diff --git a/vendor/github.com/Shopify/sarama/request.go b/vendor/github.com/Shopify/sarama/request.go
index 4d211a1..f7eea59 100644
--- a/vendor/github.com/Shopify/sarama/request.go
+++ b/vendor/github.com/Shopify/sarama/request.go
@@ -140,6 +140,8 @@
return &DescribeConfigsRequest{}
case 33:
return &AlterConfigsRequest{}
+ case 36:
+ return &SaslAuthenticateRequest{}
case 37:
return &CreatePartitionsRequest{}
case 42:
diff --git a/vendor/github.com/Shopify/sarama/sasl_handshake_request.go b/vendor/github.com/Shopify/sarama/sasl_handshake_request.go
index fbbc894..fe5ba05 100644
--- a/vendor/github.com/Shopify/sarama/sasl_handshake_request.go
+++ b/vendor/github.com/Shopify/sarama/sasl_handshake_request.go
@@ -2,6 +2,7 @@
type SaslHandshakeRequest struct {
Mechanism string
+ Version int16
}
func (r *SaslHandshakeRequest) encode(pe packetEncoder) error {
@@ -25,7 +26,7 @@
}
func (r *SaslHandshakeRequest) version() int16 {
- return 0
+ return r.Version
}
func (r *SaslHandshakeRequest) requiredVersion() KafkaVersion {
diff --git a/vendor/github.com/cevaris/ordered_map/.travis.yml b/vendor/github.com/cevaris/ordered_map/.travis.yml
index 6d74ee9..193242f 100644
--- a/vendor/github.com/cevaris/ordered_map/.travis.yml
+++ b/vendor/github.com/cevaris/ordered_map/.travis.yml
@@ -3,6 +3,9 @@
go:
- tip
+ - 1.12
+ - 1.11
+ - 1.10
- 1.9
- 1.8
- 1.7
diff --git a/vendor/github.com/cevaris/ordered_map/README.md b/vendor/github.com/cevaris/ordered_map/README.md
index 37b4503..bc3e366 100644
--- a/vendor/github.com/cevaris/ordered_map/README.md
+++ b/vendor/github.com/cevaris/ordered_map/README.md
@@ -9,7 +9,7 @@
- Full support Key/Value for all data types
- Exposes an Iterator that iterates in order of insertion
- Full Get/Set/Delete map interface
-- Supports Golang v1.3 through v1.9
+- Supports Golang v1.3 through v1.12
## Download and Install
diff --git a/vendor/github.com/coreos/go-systemd/journal/journal.go b/vendor/github.com/coreos/go-systemd/journal/journal.go
index 603ad4c..a0f4837 100644
--- a/vendor/github.com/coreos/go-systemd/journal/journal.go
+++ b/vendor/github.com/coreos/go-systemd/journal/journal.go
@@ -33,7 +33,10 @@
"os"
"strconv"
"strings"
+ "sync"
+ "sync/atomic"
"syscall"
+ "unsafe"
)
// Priority of a journal message
@@ -50,19 +53,35 @@
PriDebug
)
-var conn net.Conn
+var (
+ // This can be overridden at build-time:
+ // https://github.com/golang/go/wiki/GcToolchainTricks#including-build-information-in-the-executable
+ journalSocket = "/run/systemd/journal/socket"
+
+ // unixConnPtr atomically holds the local unconnected Unix-domain socket.
+ // Concrete safe pointer type: *net.UnixConn
+ unixConnPtr unsafe.Pointer
+ // onceConn ensures that unixConnPtr is initialized exactly once.
+ onceConn sync.Once
+)
func init() {
- var err error
- conn, err = net.Dial("unixgram", "/run/systemd/journal/socket")
- if err != nil {
- conn = nil
- }
+ onceConn.Do(initConn)
}
-// Enabled returns true if the local systemd journal is available for logging
+// Enabled checks whether the local systemd journal is available for logging.
func Enabled() bool {
- return conn != nil
+ onceConn.Do(initConn)
+
+ if (*net.UnixConn)(atomic.LoadPointer(&unixConnPtr)) == nil {
+ return false
+ }
+
+ if _, err := net.Dial("unixgram", journalSocket); err != nil {
+ return false
+ }
+
+ return true
}
// Send a message to the local systemd journal. vars is a map of journald
@@ -73,8 +92,14 @@
// (http://www.freedesktop.org/software/systemd/man/systemd.journal-fields.html)
// for more details. vars may be nil.
func Send(message string, priority Priority, vars map[string]string) error {
+ conn := (*net.UnixConn)(atomic.LoadPointer(&unixConnPtr))
if conn == nil {
- return journalError("could not connect to journald socket")
+ return errors.New("could not initialize socket to journald")
+ }
+
+ socketAddr := &net.UnixAddr{
+ Name: journalSocket,
+ Net: "unixgram",
}
data := new(bytes.Buffer)
@@ -84,32 +109,30 @@
appendVariable(data, k, v)
}
- _, err := io.Copy(conn, data)
- if err != nil && isSocketSpaceError(err) {
- file, err := tempFd()
- if err != nil {
- return journalError(err.Error())
- }
- defer file.Close()
- _, err = io.Copy(file, data)
- if err != nil {
- return journalError(err.Error())
- }
-
- rights := syscall.UnixRights(int(file.Fd()))
-
- /* this connection should always be a UnixConn, but better safe than sorry */
- unixConn, ok := conn.(*net.UnixConn)
- if !ok {
- return journalError("can't send file through non-Unix connection")
- }
- _, _, err = unixConn.WriteMsgUnix([]byte{}, rights, nil)
- if err != nil {
- return journalError(err.Error())
- }
- } else if err != nil {
- return journalError(err.Error())
+ _, _, err := conn.WriteMsgUnix(data.Bytes(), nil, socketAddr)
+ if err == nil {
+ return nil
}
+ if !isSocketSpaceError(err) {
+ return err
+ }
+
+ // Large log entry, send it via tempfile and ancillary-fd.
+ file, err := tempFd()
+ if err != nil {
+ return err
+ }
+ defer file.Close()
+ _, err = io.Copy(file, data)
+ if err != nil {
+ return err
+ }
+ rights := syscall.UnixRights(int(file.Fd()))
+ _, _, err = conn.WriteMsgUnix([]byte{}, rights, socketAddr)
+ if err != nil {
+ return err
+ }
+
return nil
}
@@ -120,7 +143,7 @@
func appendVariable(w io.Writer, name, value string) {
if err := validVarName(name); err != nil {
- journalError(err.Error())
+ fmt.Fprintf(os.Stderr, "variable name %s contains invalid character, ignoring\n", name)
}
if strings.ContainsRune(value, '\n') {
/* When the value contains a newline, we write:
@@ -137,9 +160,9 @@
}
}
-// validVarName validates a variable name to make sure it journald will accept it.
+// validVarName validates a variable name to make sure journald will accept it.
// The variable name must be in uppercase and consist only of characters,
-// numbers and underscores, and may not begin with an underscore. (from the docs)
+// numbers and underscores, and may not begin with an underscore:
// https://www.freedesktop.org/software/systemd/man/sd_journal_print.html
func validVarName(name string) error {
if name == "" {
@@ -156,20 +179,23 @@
return nil
}
+// isSocketSpaceError checks whether the error is signaling
+// an "overlarge message" condition.
func isSocketSpaceError(err error) bool {
opErr, ok := err.(*net.OpError)
- if !ok {
+ if !ok || opErr == nil {
return false
}
- sysErr, ok := opErr.Err.(syscall.Errno)
- if !ok {
+ sysErr, ok := opErr.Err.(*os.SyscallError)
+ if !ok || sysErr == nil {
return false
}
- return sysErr == syscall.EMSGSIZE || sysErr == syscall.ENOBUFS
+ return sysErr.Err == syscall.EMSGSIZE || sysErr.Err == syscall.ENOBUFS
}
+// tempFd creates a temporary, unlinked file under `/dev/shm`.
func tempFd() (*os.File, error) {
file, err := ioutil.TempFile("/dev/shm/", "journal.XXXXX")
if err != nil {
@@ -182,8 +208,18 @@
return file, nil
}
-func journalError(s string) error {
- s = "journal error: " + s
- fmt.Fprintln(os.Stderr, s)
- return errors.New(s)
+// initConn initializes the global `unixConnPtr` socket.
+// It is meant to be called exactly once, at program startup.
+func initConn() {
+ autobind, err := net.ResolveUnixAddr("unixgram", "")
+ if err != nil {
+ return
+ }
+
+ sock, err := net.ListenUnixgram("unixgram", autobind)
+ if err != nil {
+ return
+ }
+
+ atomic.StorePointer(&unixConnPtr, unsafe.Pointer(sock))
}
diff --git a/vendor/github.com/golang/protobuf/proto/decode.go b/vendor/github.com/golang/protobuf/proto/decode.go
index d9aa3c4..63b0f08 100644
--- a/vendor/github.com/golang/protobuf/proto/decode.go
+++ b/vendor/github.com/golang/protobuf/proto/decode.go
@@ -186,7 +186,6 @@
if b&0x80 == 0 {
goto done
}
- // x -= 0x80 << 63 // Always zero.
return 0, errOverflow
diff --git a/vendor/github.com/golang/protobuf/proto/deprecated.go b/vendor/github.com/golang/protobuf/proto/deprecated.go
new file mode 100644
index 0000000..35b882c
--- /dev/null
+++ b/vendor/github.com/golang/protobuf/proto/deprecated.go
@@ -0,0 +1,63 @@
+// Go support for Protocol Buffers - Google's data interchange format
+//
+// Copyright 2018 The Go Authors. All rights reserved.
+// https://github.com/golang/protobuf
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are
+// met:
+//
+// * Redistributions of source code must retain the above copyright
+// notice, this list of conditions and the following disclaimer.
+// * Redistributions in binary form must reproduce the above
+// copyright notice, this list of conditions and the following disclaimer
+// in the documentation and/or other materials provided with the
+// distribution.
+// * Neither the name of Google Inc. nor the names of its
+// contributors may be used to endorse or promote products derived from
+// this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+package proto
+
+import "errors"
+
+// Deprecated: do not use.
+type Stats struct{ Emalloc, Dmalloc, Encode, Decode, Chit, Cmiss, Size uint64 }
+
+// Deprecated: do not use.
+func GetStats() Stats { return Stats{} }
+
+// Deprecated: do not use.
+func MarshalMessageSet(interface{}) ([]byte, error) {
+ return nil, errors.New("proto: not implemented")
+}
+
+// Deprecated: do not use.
+func UnmarshalMessageSet([]byte, interface{}) error {
+ return errors.New("proto: not implemented")
+}
+
+// Deprecated: do not use.
+func MarshalMessageSetJSON(interface{}) ([]byte, error) {
+ return nil, errors.New("proto: not implemented")
+}
+
+// Deprecated: do not use.
+func UnmarshalMessageSetJSON([]byte, interface{}) error {
+ return errors.New("proto: not implemented")
+}
+
+// Deprecated: do not use.
+func RegisterMessageSetType(Message, int32, string) {}
diff --git a/vendor/github.com/golang/protobuf/proto/equal.go b/vendor/github.com/golang/protobuf/proto/equal.go
index d4db5a1..f9b6e41 100644
--- a/vendor/github.com/golang/protobuf/proto/equal.go
+++ b/vendor/github.com/golang/protobuf/proto/equal.go
@@ -246,7 +246,8 @@
return false
}
- m1, m2 := e1.value, e2.value
+ m1 := extensionAsLegacyType(e1.value)
+ m2 := extensionAsLegacyType(e2.value)
if m1 == nil && m2 == nil {
// Both have only encoded form.
diff --git a/vendor/github.com/golang/protobuf/proto/extensions.go b/vendor/github.com/golang/protobuf/proto/extensions.go
index 816a3b9..fa88add 100644
--- a/vendor/github.com/golang/protobuf/proto/extensions.go
+++ b/vendor/github.com/golang/protobuf/proto/extensions.go
@@ -185,9 +185,25 @@
// extension will have only enc set. When such an extension is
// accessed using GetExtension (or GetExtensions) desc and value
// will be set.
- desc *ExtensionDesc
+ desc *ExtensionDesc
+
+ // value is a concrete value for the extension field. Let the type of
+ // desc.ExtensionType be the "API type" and the type of Extension.value
+ // be the "storage type". The API type and storage type are the same except:
+ // * For scalars (except []byte), the API type uses *T,
+ // while the storage type uses T.
+ // * For repeated fields, the API type uses []T, while the storage type
+ // uses *[]T.
+ //
+ // The reason for the divergence is so that the storage type more naturally
+ // matches what is expected of when retrieving the values through the
+ // protobuf reflection APIs.
+ //
+ // The value may only be populated if desc is also populated.
value interface{}
- enc []byte
+
+ // enc is the raw bytes for the extension field.
+ enc []byte
}
// SetRawExtension is for testing only.
@@ -334,7 +350,7 @@
// descriptors with the same field number.
return nil, errors.New("proto: descriptor conflict")
}
- return e.value, nil
+ return extensionAsLegacyType(e.value), nil
}
if extension.ExtensionType == nil {
@@ -349,11 +365,11 @@
// Remember the decoded version and drop the encoded version.
// That way it is safe to mutate what we return.
- e.value = v
+ e.value = extensionAsStorageType(v)
e.desc = extension
e.enc = nil
emap[extension.Field] = e
- return e.value, nil
+ return extensionAsLegacyType(e.value), nil
}
// defaultExtensionValue returns the default value for extension.
@@ -488,7 +504,7 @@
}
typ := reflect.TypeOf(extension.ExtensionType)
if typ != reflect.TypeOf(value) {
- return errors.New("proto: bad extension value type")
+ return fmt.Errorf("proto: bad extension value type. got: %T, want: %T", value, extension.ExtensionType)
}
// nil extension values need to be caught early, because the
// encoder can't distinguish an ErrNil due to a nil extension
@@ -500,7 +516,7 @@
}
extmap := epb.extensionsWrite()
- extmap[extension.Field] = Extension{desc: extension, value: value}
+ extmap[extension.Field] = Extension{desc: extension, value: extensionAsStorageType(value)}
return nil
}
@@ -541,3 +557,51 @@
func RegisteredExtensions(pb Message) map[int32]*ExtensionDesc {
return extensionMaps[reflect.TypeOf(pb).Elem()]
}
+
+// extensionAsLegacyType converts an value in the storage type as the API type.
+// See Extension.value.
+func extensionAsLegacyType(v interface{}) interface{} {
+ switch rv := reflect.ValueOf(v); rv.Kind() {
+ case reflect.Bool, reflect.Int32, reflect.Int64, reflect.Uint32, reflect.Uint64, reflect.Float32, reflect.Float64, reflect.String:
+ // Represent primitive types as a pointer to the value.
+ rv2 := reflect.New(rv.Type())
+ rv2.Elem().Set(rv)
+ v = rv2.Interface()
+ case reflect.Ptr:
+ // Represent slice types as the value itself.
+ switch rv.Type().Elem().Kind() {
+ case reflect.Slice:
+ if rv.IsNil() {
+ v = reflect.Zero(rv.Type().Elem()).Interface()
+ } else {
+ v = rv.Elem().Interface()
+ }
+ }
+ }
+ return v
+}
+
+// extensionAsStorageType converts an value in the API type as the storage type.
+// See Extension.value.
+func extensionAsStorageType(v interface{}) interface{} {
+ switch rv := reflect.ValueOf(v); rv.Kind() {
+ case reflect.Ptr:
+ // Represent slice types as the value itself.
+ switch rv.Type().Elem().Kind() {
+ case reflect.Bool, reflect.Int32, reflect.Int64, reflect.Uint32, reflect.Uint64, reflect.Float32, reflect.Float64, reflect.String:
+ if rv.IsNil() {
+ v = reflect.Zero(rv.Type().Elem()).Interface()
+ } else {
+ v = rv.Elem().Interface()
+ }
+ }
+ case reflect.Slice:
+ // Represent slice types as a pointer to the value.
+ if rv.Type().Elem().Kind() != reflect.Uint8 {
+ rv2 := reflect.New(rv.Type())
+ rv2.Elem().Set(rv)
+ v = rv2.Interface()
+ }
+ }
+ return v
+}
diff --git a/vendor/github.com/golang/protobuf/proto/lib.go b/vendor/github.com/golang/protobuf/proto/lib.go
index 75565cc..fdd328b 100644
--- a/vendor/github.com/golang/protobuf/proto/lib.go
+++ b/vendor/github.com/golang/protobuf/proto/lib.go
@@ -341,26 +341,6 @@
ProtoMessage()
}
-// Stats records allocation details about the protocol buffer encoders
-// and decoders. Useful for tuning the library itself.
-type Stats struct {
- Emalloc uint64 // mallocs in encode
- Dmalloc uint64 // mallocs in decode
- Encode uint64 // number of encodes
- Decode uint64 // number of decodes
- Chit uint64 // number of cache hits
- Cmiss uint64 // number of cache misses
- Size uint64 // number of sizes
-}
-
-// Set to true to enable stats collection.
-const collectStats = false
-
-var stats Stats
-
-// GetStats returns a copy of the global Stats structure.
-func GetStats() Stats { return stats }
-
// A Buffer is a buffer manager for marshaling and unmarshaling
// protocol buffers. It may be reused between invocations to
// reduce memory usage. It is not necessary to use a Buffer;
@@ -960,13 +940,19 @@
return false
}
-// ProtoPackageIsVersion2 is referenced from generated protocol buffer files
-// to assert that that code is compatible with this version of the proto package.
-const ProtoPackageIsVersion2 = true
+const (
+ // ProtoPackageIsVersion3 is referenced from generated protocol buffer files
+ // to assert that that code is compatible with this version of the proto package.
+ ProtoPackageIsVersion3 = true
-// ProtoPackageIsVersion1 is referenced from generated protocol buffer files
-// to assert that that code is compatible with this version of the proto package.
-const ProtoPackageIsVersion1 = true
+ // ProtoPackageIsVersion2 is referenced from generated protocol buffer files
+ // to assert that that code is compatible with this version of the proto package.
+ ProtoPackageIsVersion2 = true
+
+ // ProtoPackageIsVersion1 is referenced from generated protocol buffer files
+ // to assert that that code is compatible with this version of the proto package.
+ ProtoPackageIsVersion1 = true
+)
// InternalMessageInfo is a type used internally by generated .pb.go files.
// This type is not intended to be used by non-generated code.
diff --git a/vendor/github.com/golang/protobuf/proto/message_set.go b/vendor/github.com/golang/protobuf/proto/message_set.go
index 3b6ca41..f48a756 100644
--- a/vendor/github.com/golang/protobuf/proto/message_set.go
+++ b/vendor/github.com/golang/protobuf/proto/message_set.go
@@ -36,13 +36,7 @@
*/
import (
- "bytes"
- "encoding/json"
"errors"
- "fmt"
- "reflect"
- "sort"
- "sync"
)
// errNoMessageTypeID occurs when a protocol buffer does not have a message type ID.
@@ -145,46 +139,9 @@
return buf[i+1:]
}
-// MarshalMessageSet encodes the extension map represented by m in the message set wire format.
-// It is called by generated Marshal methods on protocol buffer messages with the message_set_wire_format option.
-func MarshalMessageSet(exts interface{}) ([]byte, error) {
- return marshalMessageSet(exts, false)
-}
-
-// marshaMessageSet implements above function, with the opt to turn on / off deterministic during Marshal.
-func marshalMessageSet(exts interface{}, deterministic bool) ([]byte, error) {
- switch exts := exts.(type) {
- case *XXX_InternalExtensions:
- var u marshalInfo
- siz := u.sizeMessageSet(exts)
- b := make([]byte, 0, siz)
- return u.appendMessageSet(b, exts, deterministic)
-
- case map[int32]Extension:
- // This is an old-style extension map.
- // Wrap it in a new-style XXX_InternalExtensions.
- ie := XXX_InternalExtensions{
- p: &struct {
- mu sync.Mutex
- extensionMap map[int32]Extension
- }{
- extensionMap: exts,
- },
- }
-
- var u marshalInfo
- siz := u.sizeMessageSet(&ie)
- b := make([]byte, 0, siz)
- return u.appendMessageSet(b, &ie, deterministic)
-
- default:
- return nil, errors.New("proto: not an extension map")
- }
-}
-
-// UnmarshalMessageSet decodes the extension map encoded in buf in the message set wire format.
+// unmarshalMessageSet decodes the extension map encoded in buf in the message set wire format.
// It is called by Unmarshal methods on protocol buffer messages with the message_set_wire_format option.
-func UnmarshalMessageSet(buf []byte, exts interface{}) error {
+func unmarshalMessageSet(buf []byte, exts interface{}) error {
var m map[int32]Extension
switch exts := exts.(type) {
case *XXX_InternalExtensions:
@@ -222,93 +179,3 @@
}
return nil
}
-
-// MarshalMessageSetJSON encodes the extension map represented by m in JSON format.
-// It is called by generated MarshalJSON methods on protocol buffer messages with the message_set_wire_format option.
-func MarshalMessageSetJSON(exts interface{}) ([]byte, error) {
- var m map[int32]Extension
- switch exts := exts.(type) {
- case *XXX_InternalExtensions:
- var mu sync.Locker
- m, mu = exts.extensionsRead()
- if m != nil {
- // Keep the extensions map locked until we're done marshaling to prevent
- // races between marshaling and unmarshaling the lazily-{en,de}coded
- // values.
- mu.Lock()
- defer mu.Unlock()
- }
- case map[int32]Extension:
- m = exts
- default:
- return nil, errors.New("proto: not an extension map")
- }
- var b bytes.Buffer
- b.WriteByte('{')
-
- // Process the map in key order for deterministic output.
- ids := make([]int32, 0, len(m))
- for id := range m {
- ids = append(ids, id)
- }
- sort.Sort(int32Slice(ids)) // int32Slice defined in text.go
-
- for i, id := range ids {
- ext := m[id]
- msd, ok := messageSetMap[id]
- if !ok {
- // Unknown type; we can't render it, so skip it.
- continue
- }
-
- if i > 0 && b.Len() > 1 {
- b.WriteByte(',')
- }
-
- fmt.Fprintf(&b, `"[%s]":`, msd.name)
-
- x := ext.value
- if x == nil {
- x = reflect.New(msd.t.Elem()).Interface()
- if err := Unmarshal(ext.enc, x.(Message)); err != nil {
- return nil, err
- }
- }
- d, err := json.Marshal(x)
- if err != nil {
- return nil, err
- }
- b.Write(d)
- }
- b.WriteByte('}')
- return b.Bytes(), nil
-}
-
-// UnmarshalMessageSetJSON decodes the extension map encoded in buf in JSON format.
-// It is called by generated UnmarshalJSON methods on protocol buffer messages with the message_set_wire_format option.
-func UnmarshalMessageSetJSON(buf []byte, exts interface{}) error {
- // Common-case fast path.
- if len(buf) == 0 || bytes.Equal(buf, []byte("{}")) {
- return nil
- }
-
- // This is fairly tricky, and it's not clear that it is needed.
- return errors.New("TODO: UnmarshalMessageSetJSON not yet implemented")
-}
-
-// A global registry of types that can be used in a MessageSet.
-
-var messageSetMap = make(map[int32]messageSetDesc)
-
-type messageSetDesc struct {
- t reflect.Type // pointer to struct
- name string
-}
-
-// RegisterMessageSetType is called from the generated code.
-func RegisterMessageSetType(m Message, fieldNum int32, name string) {
- messageSetMap[fieldNum] = messageSetDesc{
- t: reflect.TypeOf(m),
- name: name,
- }
-}
diff --git a/vendor/github.com/golang/protobuf/proto/pointer_reflect.go b/vendor/github.com/golang/protobuf/proto/pointer_reflect.go
index b6cad90..94fa919 100644
--- a/vendor/github.com/golang/protobuf/proto/pointer_reflect.go
+++ b/vendor/github.com/golang/protobuf/proto/pointer_reflect.go
@@ -79,10 +79,13 @@
// toAddrPointer converts an interface to a pointer that points to
// the interface data.
-func toAddrPointer(i *interface{}, isptr bool) pointer {
+func toAddrPointer(i *interface{}, isptr, deref bool) pointer {
v := reflect.ValueOf(*i)
u := reflect.New(v.Type())
u.Elem().Set(v)
+ if deref {
+ u = u.Elem()
+ }
return pointer{v: u}
}
diff --git a/vendor/github.com/golang/protobuf/proto/pointer_unsafe.go b/vendor/github.com/golang/protobuf/proto/pointer_unsafe.go
index d55a335..dbfffe0 100644
--- a/vendor/github.com/golang/protobuf/proto/pointer_unsafe.go
+++ b/vendor/github.com/golang/protobuf/proto/pointer_unsafe.go
@@ -85,16 +85,21 @@
// toAddrPointer converts an interface to a pointer that points to
// the interface data.
-func toAddrPointer(i *interface{}, isptr bool) pointer {
+func toAddrPointer(i *interface{}, isptr, deref bool) (p pointer) {
// Super-tricky - read or get the address of data word of interface value.
if isptr {
// The interface is of pointer type, thus it is a direct interface.
// The data word is the pointer data itself. We take its address.
- return pointer{p: unsafe.Pointer(uintptr(unsafe.Pointer(i)) + ptrSize)}
+ p = pointer{p: unsafe.Pointer(uintptr(unsafe.Pointer(i)) + ptrSize)}
+ } else {
+ // The interface is not of pointer type. The data word is the pointer
+ // to the data.
+ p = pointer{p: (*[2]unsafe.Pointer)(unsafe.Pointer(i))[1]}
}
- // The interface is not of pointer type. The data word is the pointer
- // to the data.
- return pointer{p: (*[2]unsafe.Pointer)(unsafe.Pointer(i))[1]}
+ if deref {
+ p.p = *(*unsafe.Pointer)(p.p)
+ }
+ return p
}
// valToPointer converts v to a pointer. v must be of pointer type.
diff --git a/vendor/github.com/golang/protobuf/proto/properties.go b/vendor/github.com/golang/protobuf/proto/properties.go
index 50b99b8..79668ff 100644
--- a/vendor/github.com/golang/protobuf/proto/properties.go
+++ b/vendor/github.com/golang/protobuf/proto/properties.go
@@ -334,9 +334,6 @@
sprop, ok := propertiesMap[t]
propertiesMu.RUnlock()
if ok {
- if collectStats {
- stats.Chit++
- }
return sprop
}
@@ -346,17 +343,20 @@
return sprop
}
+type (
+ oneofFuncsIface interface {
+ XXX_OneofFuncs() (func(Message, *Buffer) error, func(Message, int, int, *Buffer) (bool, error), func(Message) int, []interface{})
+ }
+ oneofWrappersIface interface {
+ XXX_OneofWrappers() []interface{}
+ }
+)
+
// getPropertiesLocked requires that propertiesMu is held.
func getPropertiesLocked(t reflect.Type) *StructProperties {
if prop, ok := propertiesMap[t]; ok {
- if collectStats {
- stats.Chit++
- }
return prop
}
- if collectStats {
- stats.Cmiss++
- }
prop := new(StructProperties)
// in case of recursive protos, fill this in now.
@@ -391,13 +391,14 @@
// Re-order prop.order.
sort.Sort(prop)
- type oneofMessage interface {
- XXX_OneofFuncs() (func(Message, *Buffer) error, func(Message, int, int, *Buffer) (bool, error), func(Message) int, []interface{})
+ var oots []interface{}
+ switch m := reflect.Zero(reflect.PtrTo(t)).Interface().(type) {
+ case oneofFuncsIface:
+ _, _, _, oots = m.XXX_OneofFuncs()
+ case oneofWrappersIface:
+ oots = m.XXX_OneofWrappers()
}
- if om, ok := reflect.Zero(reflect.PtrTo(t)).Interface().(oneofMessage); ok {
- var oots []interface{}
- _, _, _, oots = om.XXX_OneofFuncs()
-
+ if len(oots) > 0 {
// Interpret oneof metadata.
prop.OneofTypes = make(map[string]*OneofProperties)
for _, oot := range oots {
diff --git a/vendor/github.com/golang/protobuf/proto/table_marshal.go b/vendor/github.com/golang/protobuf/proto/table_marshal.go
index b167944..5cb11fa 100644
--- a/vendor/github.com/golang/protobuf/proto/table_marshal.go
+++ b/vendor/github.com/golang/protobuf/proto/table_marshal.go
@@ -87,6 +87,7 @@
sizer sizer
marshaler marshaler
isptr bool // elem is pointer typed, thus interface of this type is a direct interface (extension only)
+ deref bool // dereference the pointer before operating on it; implies isptr
}
var (
@@ -320,8 +321,11 @@
// get oneof implementers
var oneofImplementers []interface{}
- if m, ok := reflect.Zero(reflect.PtrTo(t)).Interface().(oneofMessage); ok {
+ switch m := reflect.Zero(reflect.PtrTo(t)).Interface().(type) {
+ case oneofFuncsIface:
_, _, _, oneofImplementers = m.XXX_OneofFuncs()
+ case oneofWrappersIface:
+ oneofImplementers = m.XXX_OneofWrappers()
}
n := t.NumField()
@@ -407,13 +411,22 @@
panic("tag is not an integer")
}
wt := wiretype(tags[0])
+ if t.Kind() == reflect.Ptr && t.Elem().Kind() != reflect.Struct {
+ t = t.Elem()
+ }
sizer, marshaler := typeMarshaler(t, tags, false, false)
+ var deref bool
+ if t.Kind() == reflect.Slice && t.Elem().Kind() != reflect.Uint8 {
+ t = reflect.PtrTo(t)
+ deref = true
+ }
e = &marshalElemInfo{
wiretag: uint64(tag)<<3 | wt,
tagsize: SizeVarint(uint64(tag) << 3),
sizer: sizer,
marshaler: marshaler,
isptr: t.Kind() == reflect.Ptr,
+ deref: deref,
}
// update cache
@@ -448,7 +461,7 @@
func (fi *marshalFieldInfo) computeOneofFieldInfo(f *reflect.StructField, oneofImplementers []interface{}) {
fi.field = toField(f)
- fi.wiretag = 1<<31 - 1 // Use a large tag number, make oneofs sorted at the end. This tag will not appear on the wire.
+ fi.wiretag = math.MaxInt32 // Use a large tag number, make oneofs sorted at the end. This tag will not appear on the wire.
fi.isPointer = true
fi.sizer, fi.marshaler = makeOneOfMarshaler(fi, f)
fi.oneofElems = make(map[reflect.Type]*marshalElemInfo)
@@ -476,10 +489,6 @@
}
}
-type oneofMessage interface {
- XXX_OneofFuncs() (func(Message, *Buffer) error, func(Message, int, int, *Buffer) (bool, error), func(Message) int, []interface{})
-}
-
// wiretype returns the wire encoding of the type.
func wiretype(encoding string) uint64 {
switch encoding {
@@ -2310,8 +2319,8 @@
for _, k := range m.MapKeys() {
ki := k.Interface()
vi := m.MapIndex(k).Interface()
- kaddr := toAddrPointer(&ki, false) // pointer to key
- vaddr := toAddrPointer(&vi, valIsPtr) // pointer to value
+ kaddr := toAddrPointer(&ki, false, false) // pointer to key
+ vaddr := toAddrPointer(&vi, valIsPtr, false) // pointer to value
siz := keySizer(kaddr, 1) + valSizer(vaddr, 1) // tag of key = 1 (size=1), tag of val = 2 (size=1)
n += siz + SizeVarint(uint64(siz)) + tagsize
}
@@ -2329,8 +2338,8 @@
for _, k := range keys {
ki := k.Interface()
vi := m.MapIndex(k).Interface()
- kaddr := toAddrPointer(&ki, false) // pointer to key
- vaddr := toAddrPointer(&vi, valIsPtr) // pointer to value
+ kaddr := toAddrPointer(&ki, false, false) // pointer to key
+ vaddr := toAddrPointer(&vi, valIsPtr, false) // pointer to value
b = appendVarint(b, tag)
siz := keySizer(kaddr, 1) + valCachedSizer(vaddr, 1) // tag of key = 1 (size=1), tag of val = 2 (size=1)
b = appendVarint(b, uint64(siz))
@@ -2399,7 +2408,7 @@
// the last time this function was called.
ei := u.getExtElemInfo(e.desc)
v := e.value
- p := toAddrPointer(&v, ei.isptr)
+ p := toAddrPointer(&v, ei.isptr, ei.deref)
n += ei.sizer(p, ei.tagsize)
}
mu.Unlock()
@@ -2434,7 +2443,7 @@
ei := u.getExtElemInfo(e.desc)
v := e.value
- p := toAddrPointer(&v, ei.isptr)
+ p := toAddrPointer(&v, ei.isptr, ei.deref)
b, err = ei.marshaler(b, p, ei.wiretag, deterministic)
if !nerr.Merge(err) {
return b, err
@@ -2465,7 +2474,7 @@
ei := u.getExtElemInfo(e.desc)
v := e.value
- p := toAddrPointer(&v, ei.isptr)
+ p := toAddrPointer(&v, ei.isptr, ei.deref)
b, err = ei.marshaler(b, p, ei.wiretag, deterministic)
if !nerr.Merge(err) {
return b, err
@@ -2510,7 +2519,7 @@
ei := u.getExtElemInfo(e.desc)
v := e.value
- p := toAddrPointer(&v, ei.isptr)
+ p := toAddrPointer(&v, ei.isptr, ei.deref)
n += ei.sizer(p, 1) // message, tag = 3 (size=1)
}
mu.Unlock()
@@ -2553,7 +2562,7 @@
ei := u.getExtElemInfo(e.desc)
v := e.value
- p := toAddrPointer(&v, ei.isptr)
+ p := toAddrPointer(&v, ei.isptr, ei.deref)
b, err = ei.marshaler(b, p, 3<<3|WireBytes, deterministic)
if !nerr.Merge(err) {
return b, err
@@ -2591,7 +2600,7 @@
ei := u.getExtElemInfo(e.desc)
v := e.value
- p := toAddrPointer(&v, ei.isptr)
+ p := toAddrPointer(&v, ei.isptr, ei.deref)
b, err = ei.marshaler(b, p, 3<<3|WireBytes, deterministic)
b = append(b, 1<<3|WireEndGroup)
if !nerr.Merge(err) {
@@ -2621,7 +2630,7 @@
ei := u.getExtElemInfo(e.desc)
v := e.value
- p := toAddrPointer(&v, ei.isptr)
+ p := toAddrPointer(&v, ei.isptr, ei.deref)
n += ei.sizer(p, ei.tagsize)
}
return n
@@ -2656,7 +2665,7 @@
ei := u.getExtElemInfo(e.desc)
v := e.value
- p := toAddrPointer(&v, ei.isptr)
+ p := toAddrPointer(&v, ei.isptr, ei.deref)
b, err = ei.marshaler(b, p, ei.wiretag, deterministic)
if !nerr.Merge(err) {
return b, err
diff --git a/vendor/github.com/golang/protobuf/proto/table_unmarshal.go b/vendor/github.com/golang/protobuf/proto/table_unmarshal.go
index ebf1caa..acee2fc 100644
--- a/vendor/github.com/golang/protobuf/proto/table_unmarshal.go
+++ b/vendor/github.com/golang/protobuf/proto/table_unmarshal.go
@@ -136,7 +136,7 @@
u.computeUnmarshalInfo()
}
if u.isMessageSet {
- return UnmarshalMessageSet(b, m.offset(u.extensions).toExtensions())
+ return unmarshalMessageSet(b, m.offset(u.extensions).toExtensions())
}
var reqMask uint64 // bitmask of required fields we've seen.
var errLater error
@@ -362,46 +362,48 @@
}
// Find any types associated with oneof fields.
- // TODO: XXX_OneofFuncs returns more info than we need. Get rid of some of it?
- fn := reflect.Zero(reflect.PtrTo(t)).MethodByName("XXX_OneofFuncs")
- if fn.IsValid() {
- res := fn.Call(nil)[3] // last return value from XXX_OneofFuncs: []interface{}
- for i := res.Len() - 1; i >= 0; i-- {
- v := res.Index(i) // interface{}
- tptr := reflect.ValueOf(v.Interface()).Type() // *Msg_X
- typ := tptr.Elem() // Msg_X
+ var oneofImplementers []interface{}
+ switch m := reflect.Zero(reflect.PtrTo(t)).Interface().(type) {
+ case oneofFuncsIface:
+ _, _, _, oneofImplementers = m.XXX_OneofFuncs()
+ case oneofWrappersIface:
+ oneofImplementers = m.XXX_OneofWrappers()
+ }
+ for _, v := range oneofImplementers {
+ tptr := reflect.TypeOf(v) // *Msg_X
+ typ := tptr.Elem() // Msg_X
- f := typ.Field(0) // oneof implementers have one field
- baseUnmarshal := fieldUnmarshaler(&f)
- tags := strings.Split(f.Tag.Get("protobuf"), ",")
- fieldNum, err := strconv.Atoi(tags[1])
- if err != nil {
- panic("protobuf tag field not an integer: " + tags[1])
- }
- var name string
- for _, tag := range tags {
- if strings.HasPrefix(tag, "name=") {
- name = strings.TrimPrefix(tag, "name=")
- break
- }
- }
-
- // Find the oneof field that this struct implements.
- // Might take O(n^2) to process all of the oneofs, but who cares.
- for _, of := range oneofFields {
- if tptr.Implements(of.ityp) {
- // We have found the corresponding interface for this struct.
- // That lets us know where this struct should be stored
- // when we encounter it during unmarshaling.
- unmarshal := makeUnmarshalOneof(typ, of.ityp, baseUnmarshal)
- u.setTag(fieldNum, of.field, unmarshal, 0, name)
- }
+ f := typ.Field(0) // oneof implementers have one field
+ baseUnmarshal := fieldUnmarshaler(&f)
+ tags := strings.Split(f.Tag.Get("protobuf"), ",")
+ fieldNum, err := strconv.Atoi(tags[1])
+ if err != nil {
+ panic("protobuf tag field not an integer: " + tags[1])
+ }
+ var name string
+ for _, tag := range tags {
+ if strings.HasPrefix(tag, "name=") {
+ name = strings.TrimPrefix(tag, "name=")
+ break
}
}
+
+ // Find the oneof field that this struct implements.
+ // Might take O(n^2) to process all of the oneofs, but who cares.
+ for _, of := range oneofFields {
+ if tptr.Implements(of.ityp) {
+ // We have found the corresponding interface for this struct.
+ // That lets us know where this struct should be stored
+ // when we encounter it during unmarshaling.
+ unmarshal := makeUnmarshalOneof(typ, of.ityp, baseUnmarshal)
+ u.setTag(fieldNum, of.field, unmarshal, 0, name)
+ }
+ }
+
}
// Get extension ranges, if any.
- fn = reflect.Zero(reflect.PtrTo(t)).MethodByName("ExtensionRangeArray")
+ fn := reflect.Zero(reflect.PtrTo(t)).MethodByName("ExtensionRangeArray")
if fn.IsValid() {
if !u.extensions.IsValid() && !u.oldExtensions.IsValid() {
panic("a message with extensions, but no extensions field in " + t.Name())
@@ -1948,7 +1950,7 @@
// If there is an error, it returns 0,0.
func decodeVarint(b []byte) (uint64, int) {
var x, y uint64
- if len(b) <= 0 {
+ if len(b) == 0 {
goto bad
}
x = uint64(b[0])
diff --git a/vendor/github.com/golang/protobuf/protoc-gen-go/descriptor/descriptor.pb.go b/vendor/github.com/golang/protobuf/protoc-gen-go/descriptor/descriptor.pb.go
index e855b1f..1ded05b 100644
--- a/vendor/github.com/golang/protobuf/protoc-gen-go/descriptor/descriptor.pb.go
+++ b/vendor/github.com/golang/protobuf/protoc-gen-go/descriptor/descriptor.pb.go
@@ -1,11 +1,13 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/protobuf/descriptor.proto
-package descriptor // import "github.com/golang/protobuf/protoc-gen-go/descriptor"
+package descriptor
-import proto "github.com/golang/protobuf/proto"
-import fmt "fmt"
-import math "math"
+import (
+ fmt "fmt"
+ proto "github.com/golang/protobuf/proto"
+ math "math"
+)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@@ -16,7 +18,7 @@
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
-const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
+const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
type FieldDescriptorProto_Type int32
@@ -72,6 +74,7 @@
17: "TYPE_SINT32",
18: "TYPE_SINT64",
}
+
var FieldDescriptorProto_Type_value = map[string]int32{
"TYPE_DOUBLE": 1,
"TYPE_FLOAT": 2,
@@ -98,9 +101,11 @@
*p = x
return p
}
+
func (x FieldDescriptorProto_Type) String() string {
return proto.EnumName(FieldDescriptorProto_Type_name, int32(x))
}
+
func (x *FieldDescriptorProto_Type) UnmarshalJSON(data []byte) error {
value, err := proto.UnmarshalJSONEnum(FieldDescriptorProto_Type_value, data, "FieldDescriptorProto_Type")
if err != nil {
@@ -109,8 +114,9 @@
*x = FieldDescriptorProto_Type(value)
return nil
}
+
func (FieldDescriptorProto_Type) EnumDescriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{4, 0}
+ return fileDescriptor_e5baabe45344a177, []int{4, 0}
}
type FieldDescriptorProto_Label int32
@@ -127,6 +133,7 @@
2: "LABEL_REQUIRED",
3: "LABEL_REPEATED",
}
+
var FieldDescriptorProto_Label_value = map[string]int32{
"LABEL_OPTIONAL": 1,
"LABEL_REQUIRED": 2,
@@ -138,9 +145,11 @@
*p = x
return p
}
+
func (x FieldDescriptorProto_Label) String() string {
return proto.EnumName(FieldDescriptorProto_Label_name, int32(x))
}
+
func (x *FieldDescriptorProto_Label) UnmarshalJSON(data []byte) error {
value, err := proto.UnmarshalJSONEnum(FieldDescriptorProto_Label_value, data, "FieldDescriptorProto_Label")
if err != nil {
@@ -149,8 +158,9 @@
*x = FieldDescriptorProto_Label(value)
return nil
}
+
func (FieldDescriptorProto_Label) EnumDescriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{4, 1}
+ return fileDescriptor_e5baabe45344a177, []int{4, 1}
}
// Generated classes can be optimized for speed or code size.
@@ -168,6 +178,7 @@
2: "CODE_SIZE",
3: "LITE_RUNTIME",
}
+
var FileOptions_OptimizeMode_value = map[string]int32{
"SPEED": 1,
"CODE_SIZE": 2,
@@ -179,9 +190,11 @@
*p = x
return p
}
+
func (x FileOptions_OptimizeMode) String() string {
return proto.EnumName(FileOptions_OptimizeMode_name, int32(x))
}
+
func (x *FileOptions_OptimizeMode) UnmarshalJSON(data []byte) error {
value, err := proto.UnmarshalJSONEnum(FileOptions_OptimizeMode_value, data, "FileOptions_OptimizeMode")
if err != nil {
@@ -190,8 +203,9 @@
*x = FileOptions_OptimizeMode(value)
return nil
}
+
func (FileOptions_OptimizeMode) EnumDescriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{10, 0}
+ return fileDescriptor_e5baabe45344a177, []int{10, 0}
}
type FieldOptions_CType int32
@@ -208,6 +222,7 @@
1: "CORD",
2: "STRING_PIECE",
}
+
var FieldOptions_CType_value = map[string]int32{
"STRING": 0,
"CORD": 1,
@@ -219,9 +234,11 @@
*p = x
return p
}
+
func (x FieldOptions_CType) String() string {
return proto.EnumName(FieldOptions_CType_name, int32(x))
}
+
func (x *FieldOptions_CType) UnmarshalJSON(data []byte) error {
value, err := proto.UnmarshalJSONEnum(FieldOptions_CType_value, data, "FieldOptions_CType")
if err != nil {
@@ -230,8 +247,9 @@
*x = FieldOptions_CType(value)
return nil
}
+
func (FieldOptions_CType) EnumDescriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{12, 0}
+ return fileDescriptor_e5baabe45344a177, []int{12, 0}
}
type FieldOptions_JSType int32
@@ -250,6 +268,7 @@
1: "JS_STRING",
2: "JS_NUMBER",
}
+
var FieldOptions_JSType_value = map[string]int32{
"JS_NORMAL": 0,
"JS_STRING": 1,
@@ -261,9 +280,11 @@
*p = x
return p
}
+
func (x FieldOptions_JSType) String() string {
return proto.EnumName(FieldOptions_JSType_name, int32(x))
}
+
func (x *FieldOptions_JSType) UnmarshalJSON(data []byte) error {
value, err := proto.UnmarshalJSONEnum(FieldOptions_JSType_value, data, "FieldOptions_JSType")
if err != nil {
@@ -272,8 +293,9 @@
*x = FieldOptions_JSType(value)
return nil
}
+
func (FieldOptions_JSType) EnumDescriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{12, 1}
+ return fileDescriptor_e5baabe45344a177, []int{12, 1}
}
// Is this method side-effect-free (or safe in HTTP parlance), or idempotent,
@@ -292,6 +314,7 @@
1: "NO_SIDE_EFFECTS",
2: "IDEMPOTENT",
}
+
var MethodOptions_IdempotencyLevel_value = map[string]int32{
"IDEMPOTENCY_UNKNOWN": 0,
"NO_SIDE_EFFECTS": 1,
@@ -303,9 +326,11 @@
*p = x
return p
}
+
func (x MethodOptions_IdempotencyLevel) String() string {
return proto.EnumName(MethodOptions_IdempotencyLevel_name, int32(x))
}
+
func (x *MethodOptions_IdempotencyLevel) UnmarshalJSON(data []byte) error {
value, err := proto.UnmarshalJSONEnum(MethodOptions_IdempotencyLevel_value, data, "MethodOptions_IdempotencyLevel")
if err != nil {
@@ -314,8 +339,9 @@
*x = MethodOptions_IdempotencyLevel(value)
return nil
}
+
func (MethodOptions_IdempotencyLevel) EnumDescriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{17, 0}
+ return fileDescriptor_e5baabe45344a177, []int{17, 0}
}
// The protocol compiler can output a FileDescriptorSet containing the .proto
@@ -331,16 +357,17 @@
func (m *FileDescriptorSet) String() string { return proto.CompactTextString(m) }
func (*FileDescriptorSet) ProtoMessage() {}
func (*FileDescriptorSet) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{0}
+ return fileDescriptor_e5baabe45344a177, []int{0}
}
+
func (m *FileDescriptorSet) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_FileDescriptorSet.Unmarshal(m, b)
}
func (m *FileDescriptorSet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_FileDescriptorSet.Marshal(b, m, deterministic)
}
-func (dst *FileDescriptorSet) XXX_Merge(src proto.Message) {
- xxx_messageInfo_FileDescriptorSet.Merge(dst, src)
+func (m *FileDescriptorSet) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_FileDescriptorSet.Merge(m, src)
}
func (m *FileDescriptorSet) XXX_Size() int {
return xxx_messageInfo_FileDescriptorSet.Size(m)
@@ -392,16 +419,17 @@
func (m *FileDescriptorProto) String() string { return proto.CompactTextString(m) }
func (*FileDescriptorProto) ProtoMessage() {}
func (*FileDescriptorProto) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{1}
+ return fileDescriptor_e5baabe45344a177, []int{1}
}
+
func (m *FileDescriptorProto) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_FileDescriptorProto.Unmarshal(m, b)
}
func (m *FileDescriptorProto) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_FileDescriptorProto.Marshal(b, m, deterministic)
}
-func (dst *FileDescriptorProto) XXX_Merge(src proto.Message) {
- xxx_messageInfo_FileDescriptorProto.Merge(dst, src)
+func (m *FileDescriptorProto) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_FileDescriptorProto.Merge(m, src)
}
func (m *FileDescriptorProto) XXX_Size() int {
return xxx_messageInfo_FileDescriptorProto.Size(m)
@@ -519,16 +547,17 @@
func (m *DescriptorProto) String() string { return proto.CompactTextString(m) }
func (*DescriptorProto) ProtoMessage() {}
func (*DescriptorProto) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{2}
+ return fileDescriptor_e5baabe45344a177, []int{2}
}
+
func (m *DescriptorProto) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_DescriptorProto.Unmarshal(m, b)
}
func (m *DescriptorProto) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_DescriptorProto.Marshal(b, m, deterministic)
}
-func (dst *DescriptorProto) XXX_Merge(src proto.Message) {
- xxx_messageInfo_DescriptorProto.Merge(dst, src)
+func (m *DescriptorProto) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_DescriptorProto.Merge(m, src)
}
func (m *DescriptorProto) XXX_Size() int {
return xxx_messageInfo_DescriptorProto.Size(m)
@@ -622,16 +651,17 @@
func (m *DescriptorProto_ExtensionRange) String() string { return proto.CompactTextString(m) }
func (*DescriptorProto_ExtensionRange) ProtoMessage() {}
func (*DescriptorProto_ExtensionRange) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{2, 0}
+ return fileDescriptor_e5baabe45344a177, []int{2, 0}
}
+
func (m *DescriptorProto_ExtensionRange) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_DescriptorProto_ExtensionRange.Unmarshal(m, b)
}
func (m *DescriptorProto_ExtensionRange) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_DescriptorProto_ExtensionRange.Marshal(b, m, deterministic)
}
-func (dst *DescriptorProto_ExtensionRange) XXX_Merge(src proto.Message) {
- xxx_messageInfo_DescriptorProto_ExtensionRange.Merge(dst, src)
+func (m *DescriptorProto_ExtensionRange) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_DescriptorProto_ExtensionRange.Merge(m, src)
}
func (m *DescriptorProto_ExtensionRange) XXX_Size() int {
return xxx_messageInfo_DescriptorProto_ExtensionRange.Size(m)
@@ -678,16 +708,17 @@
func (m *DescriptorProto_ReservedRange) String() string { return proto.CompactTextString(m) }
func (*DescriptorProto_ReservedRange) ProtoMessage() {}
func (*DescriptorProto_ReservedRange) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{2, 1}
+ return fileDescriptor_e5baabe45344a177, []int{2, 1}
}
+
func (m *DescriptorProto_ReservedRange) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_DescriptorProto_ReservedRange.Unmarshal(m, b)
}
func (m *DescriptorProto_ReservedRange) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_DescriptorProto_ReservedRange.Marshal(b, m, deterministic)
}
-func (dst *DescriptorProto_ReservedRange) XXX_Merge(src proto.Message) {
- xxx_messageInfo_DescriptorProto_ReservedRange.Merge(dst, src)
+func (m *DescriptorProto_ReservedRange) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_DescriptorProto_ReservedRange.Merge(m, src)
}
func (m *DescriptorProto_ReservedRange) XXX_Size() int {
return xxx_messageInfo_DescriptorProto_ReservedRange.Size(m)
@@ -725,7 +756,7 @@
func (m *ExtensionRangeOptions) String() string { return proto.CompactTextString(m) }
func (*ExtensionRangeOptions) ProtoMessage() {}
func (*ExtensionRangeOptions) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{3}
+ return fileDescriptor_e5baabe45344a177, []int{3}
}
var extRange_ExtensionRangeOptions = []proto.ExtensionRange{
@@ -735,14 +766,15 @@
func (*ExtensionRangeOptions) ExtensionRangeArray() []proto.ExtensionRange {
return extRange_ExtensionRangeOptions
}
+
func (m *ExtensionRangeOptions) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ExtensionRangeOptions.Unmarshal(m, b)
}
func (m *ExtensionRangeOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ExtensionRangeOptions.Marshal(b, m, deterministic)
}
-func (dst *ExtensionRangeOptions) XXX_Merge(src proto.Message) {
- xxx_messageInfo_ExtensionRangeOptions.Merge(dst, src)
+func (m *ExtensionRangeOptions) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_ExtensionRangeOptions.Merge(m, src)
}
func (m *ExtensionRangeOptions) XXX_Size() int {
return xxx_messageInfo_ExtensionRangeOptions.Size(m)
@@ -801,16 +833,17 @@
func (m *FieldDescriptorProto) String() string { return proto.CompactTextString(m) }
func (*FieldDescriptorProto) ProtoMessage() {}
func (*FieldDescriptorProto) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{4}
+ return fileDescriptor_e5baabe45344a177, []int{4}
}
+
func (m *FieldDescriptorProto) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_FieldDescriptorProto.Unmarshal(m, b)
}
func (m *FieldDescriptorProto) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_FieldDescriptorProto.Marshal(b, m, deterministic)
}
-func (dst *FieldDescriptorProto) XXX_Merge(src proto.Message) {
- xxx_messageInfo_FieldDescriptorProto.Merge(dst, src)
+func (m *FieldDescriptorProto) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_FieldDescriptorProto.Merge(m, src)
}
func (m *FieldDescriptorProto) XXX_Size() int {
return xxx_messageInfo_FieldDescriptorProto.Size(m)
@@ -904,16 +937,17 @@
func (m *OneofDescriptorProto) String() string { return proto.CompactTextString(m) }
func (*OneofDescriptorProto) ProtoMessage() {}
func (*OneofDescriptorProto) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{5}
+ return fileDescriptor_e5baabe45344a177, []int{5}
}
+
func (m *OneofDescriptorProto) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_OneofDescriptorProto.Unmarshal(m, b)
}
func (m *OneofDescriptorProto) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_OneofDescriptorProto.Marshal(b, m, deterministic)
}
-func (dst *OneofDescriptorProto) XXX_Merge(src proto.Message) {
- xxx_messageInfo_OneofDescriptorProto.Merge(dst, src)
+func (m *OneofDescriptorProto) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_OneofDescriptorProto.Merge(m, src)
}
func (m *OneofDescriptorProto) XXX_Size() int {
return xxx_messageInfo_OneofDescriptorProto.Size(m)
@@ -959,16 +993,17 @@
func (m *EnumDescriptorProto) String() string { return proto.CompactTextString(m) }
func (*EnumDescriptorProto) ProtoMessage() {}
func (*EnumDescriptorProto) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{6}
+ return fileDescriptor_e5baabe45344a177, []int{6}
}
+
func (m *EnumDescriptorProto) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_EnumDescriptorProto.Unmarshal(m, b)
}
func (m *EnumDescriptorProto) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_EnumDescriptorProto.Marshal(b, m, deterministic)
}
-func (dst *EnumDescriptorProto) XXX_Merge(src proto.Message) {
- xxx_messageInfo_EnumDescriptorProto.Merge(dst, src)
+func (m *EnumDescriptorProto) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_EnumDescriptorProto.Merge(m, src)
}
func (m *EnumDescriptorProto) XXX_Size() int {
return xxx_messageInfo_EnumDescriptorProto.Size(m)
@@ -1032,16 +1067,17 @@
func (m *EnumDescriptorProto_EnumReservedRange) String() string { return proto.CompactTextString(m) }
func (*EnumDescriptorProto_EnumReservedRange) ProtoMessage() {}
func (*EnumDescriptorProto_EnumReservedRange) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{6, 0}
+ return fileDescriptor_e5baabe45344a177, []int{6, 0}
}
+
func (m *EnumDescriptorProto_EnumReservedRange) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_EnumDescriptorProto_EnumReservedRange.Unmarshal(m, b)
}
func (m *EnumDescriptorProto_EnumReservedRange) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_EnumDescriptorProto_EnumReservedRange.Marshal(b, m, deterministic)
}
-func (dst *EnumDescriptorProto_EnumReservedRange) XXX_Merge(src proto.Message) {
- xxx_messageInfo_EnumDescriptorProto_EnumReservedRange.Merge(dst, src)
+func (m *EnumDescriptorProto_EnumReservedRange) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_EnumDescriptorProto_EnumReservedRange.Merge(m, src)
}
func (m *EnumDescriptorProto_EnumReservedRange) XXX_Size() int {
return xxx_messageInfo_EnumDescriptorProto_EnumReservedRange.Size(m)
@@ -1080,16 +1116,17 @@
func (m *EnumValueDescriptorProto) String() string { return proto.CompactTextString(m) }
func (*EnumValueDescriptorProto) ProtoMessage() {}
func (*EnumValueDescriptorProto) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{7}
+ return fileDescriptor_e5baabe45344a177, []int{7}
}
+
func (m *EnumValueDescriptorProto) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_EnumValueDescriptorProto.Unmarshal(m, b)
}
func (m *EnumValueDescriptorProto) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_EnumValueDescriptorProto.Marshal(b, m, deterministic)
}
-func (dst *EnumValueDescriptorProto) XXX_Merge(src proto.Message) {
- xxx_messageInfo_EnumValueDescriptorProto.Merge(dst, src)
+func (m *EnumValueDescriptorProto) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_EnumValueDescriptorProto.Merge(m, src)
}
func (m *EnumValueDescriptorProto) XXX_Size() int {
return xxx_messageInfo_EnumValueDescriptorProto.Size(m)
@@ -1135,16 +1172,17 @@
func (m *ServiceDescriptorProto) String() string { return proto.CompactTextString(m) }
func (*ServiceDescriptorProto) ProtoMessage() {}
func (*ServiceDescriptorProto) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{8}
+ return fileDescriptor_e5baabe45344a177, []int{8}
}
+
func (m *ServiceDescriptorProto) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ServiceDescriptorProto.Unmarshal(m, b)
}
func (m *ServiceDescriptorProto) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ServiceDescriptorProto.Marshal(b, m, deterministic)
}
-func (dst *ServiceDescriptorProto) XXX_Merge(src proto.Message) {
- xxx_messageInfo_ServiceDescriptorProto.Merge(dst, src)
+func (m *ServiceDescriptorProto) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_ServiceDescriptorProto.Merge(m, src)
}
func (m *ServiceDescriptorProto) XXX_Size() int {
return xxx_messageInfo_ServiceDescriptorProto.Size(m)
@@ -1197,16 +1235,17 @@
func (m *MethodDescriptorProto) String() string { return proto.CompactTextString(m) }
func (*MethodDescriptorProto) ProtoMessage() {}
func (*MethodDescriptorProto) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{9}
+ return fileDescriptor_e5baabe45344a177, []int{9}
}
+
func (m *MethodDescriptorProto) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_MethodDescriptorProto.Unmarshal(m, b)
}
func (m *MethodDescriptorProto) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_MethodDescriptorProto.Marshal(b, m, deterministic)
}
-func (dst *MethodDescriptorProto) XXX_Merge(src proto.Message) {
- xxx_messageInfo_MethodDescriptorProto.Merge(dst, src)
+func (m *MethodDescriptorProto) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MethodDescriptorProto.Merge(m, src)
}
func (m *MethodDescriptorProto) XXX_Size() int {
return xxx_messageInfo_MethodDescriptorProto.Size(m)
@@ -1336,6 +1375,14 @@
// is empty. When this option is empty, the package name will be used for
// determining the namespace.
PhpNamespace *string `protobuf:"bytes,41,opt,name=php_namespace,json=phpNamespace" json:"php_namespace,omitempty"`
+ // Use this option to change the namespace of php generated metadata classes.
+ // Default is empty. When this option is empty, the proto file name will be used
+ // for determining the namespace.
+ PhpMetadataNamespace *string `protobuf:"bytes,44,opt,name=php_metadata_namespace,json=phpMetadataNamespace" json:"php_metadata_namespace,omitempty"`
+ // Use this option to change the package of ruby generated classes. Default
+ // is empty. When this option is not set, the package name will be used for
+ // determining the ruby package.
+ RubyPackage *string `protobuf:"bytes,45,opt,name=ruby_package,json=rubyPackage" json:"ruby_package,omitempty"`
// The parser stores options it doesn't recognize here.
// See the documentation for the "Options" section above.
UninterpretedOption []*UninterpretedOption `protobuf:"bytes,999,rep,name=uninterpreted_option,json=uninterpretedOption" json:"uninterpreted_option,omitempty"`
@@ -1349,7 +1396,7 @@
func (m *FileOptions) String() string { return proto.CompactTextString(m) }
func (*FileOptions) ProtoMessage() {}
func (*FileOptions) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{10}
+ return fileDescriptor_e5baabe45344a177, []int{10}
}
var extRange_FileOptions = []proto.ExtensionRange{
@@ -1359,14 +1406,15 @@
func (*FileOptions) ExtensionRangeArray() []proto.ExtensionRange {
return extRange_FileOptions
}
+
func (m *FileOptions) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_FileOptions.Unmarshal(m, b)
}
func (m *FileOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_FileOptions.Marshal(b, m, deterministic)
}
-func (dst *FileOptions) XXX_Merge(src proto.Message) {
- xxx_messageInfo_FileOptions.Merge(dst, src)
+func (m *FileOptions) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_FileOptions.Merge(m, src)
}
func (m *FileOptions) XXX_Size() int {
return xxx_messageInfo_FileOptions.Size(m)
@@ -1514,6 +1562,20 @@
return ""
}
+func (m *FileOptions) GetPhpMetadataNamespace() string {
+ if m != nil && m.PhpMetadataNamespace != nil {
+ return *m.PhpMetadataNamespace
+ }
+ return ""
+}
+
+func (m *FileOptions) GetRubyPackage() string {
+ if m != nil && m.RubyPackage != nil {
+ return *m.RubyPackage
+ }
+ return ""
+}
+
func (m *FileOptions) GetUninterpretedOption() []*UninterpretedOption {
if m != nil {
return m.UninterpretedOption
@@ -1584,7 +1646,7 @@
func (m *MessageOptions) String() string { return proto.CompactTextString(m) }
func (*MessageOptions) ProtoMessage() {}
func (*MessageOptions) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{11}
+ return fileDescriptor_e5baabe45344a177, []int{11}
}
var extRange_MessageOptions = []proto.ExtensionRange{
@@ -1594,14 +1656,15 @@
func (*MessageOptions) ExtensionRangeArray() []proto.ExtensionRange {
return extRange_MessageOptions
}
+
func (m *MessageOptions) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_MessageOptions.Unmarshal(m, b)
}
func (m *MessageOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_MessageOptions.Marshal(b, m, deterministic)
}
-func (dst *MessageOptions) XXX_Merge(src proto.Message) {
- xxx_messageInfo_MessageOptions.Merge(dst, src)
+func (m *MessageOptions) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MessageOptions.Merge(m, src)
}
func (m *MessageOptions) XXX_Size() int {
return xxx_messageInfo_MessageOptions.Size(m)
@@ -1723,7 +1786,7 @@
func (m *FieldOptions) String() string { return proto.CompactTextString(m) }
func (*FieldOptions) ProtoMessage() {}
func (*FieldOptions) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{12}
+ return fileDescriptor_e5baabe45344a177, []int{12}
}
var extRange_FieldOptions = []proto.ExtensionRange{
@@ -1733,14 +1796,15 @@
func (*FieldOptions) ExtensionRangeArray() []proto.ExtensionRange {
return extRange_FieldOptions
}
+
func (m *FieldOptions) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_FieldOptions.Unmarshal(m, b)
}
func (m *FieldOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_FieldOptions.Marshal(b, m, deterministic)
}
-func (dst *FieldOptions) XXX_Merge(src proto.Message) {
- xxx_messageInfo_FieldOptions.Merge(dst, src)
+func (m *FieldOptions) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_FieldOptions.Merge(m, src)
}
func (m *FieldOptions) XXX_Size() int {
return xxx_messageInfo_FieldOptions.Size(m)
@@ -1819,7 +1883,7 @@
func (m *OneofOptions) String() string { return proto.CompactTextString(m) }
func (*OneofOptions) ProtoMessage() {}
func (*OneofOptions) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{13}
+ return fileDescriptor_e5baabe45344a177, []int{13}
}
var extRange_OneofOptions = []proto.ExtensionRange{
@@ -1829,14 +1893,15 @@
func (*OneofOptions) ExtensionRangeArray() []proto.ExtensionRange {
return extRange_OneofOptions
}
+
func (m *OneofOptions) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_OneofOptions.Unmarshal(m, b)
}
func (m *OneofOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_OneofOptions.Marshal(b, m, deterministic)
}
-func (dst *OneofOptions) XXX_Merge(src proto.Message) {
- xxx_messageInfo_OneofOptions.Merge(dst, src)
+func (m *OneofOptions) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_OneofOptions.Merge(m, src)
}
func (m *OneofOptions) XXX_Size() int {
return xxx_messageInfo_OneofOptions.Size(m)
@@ -1875,7 +1940,7 @@
func (m *EnumOptions) String() string { return proto.CompactTextString(m) }
func (*EnumOptions) ProtoMessage() {}
func (*EnumOptions) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{14}
+ return fileDescriptor_e5baabe45344a177, []int{14}
}
var extRange_EnumOptions = []proto.ExtensionRange{
@@ -1885,14 +1950,15 @@
func (*EnumOptions) ExtensionRangeArray() []proto.ExtensionRange {
return extRange_EnumOptions
}
+
func (m *EnumOptions) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_EnumOptions.Unmarshal(m, b)
}
func (m *EnumOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_EnumOptions.Marshal(b, m, deterministic)
}
-func (dst *EnumOptions) XXX_Merge(src proto.Message) {
- xxx_messageInfo_EnumOptions.Merge(dst, src)
+func (m *EnumOptions) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_EnumOptions.Merge(m, src)
}
func (m *EnumOptions) XXX_Size() int {
return xxx_messageInfo_EnumOptions.Size(m)
@@ -1944,7 +2010,7 @@
func (m *EnumValueOptions) String() string { return proto.CompactTextString(m) }
func (*EnumValueOptions) ProtoMessage() {}
func (*EnumValueOptions) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{15}
+ return fileDescriptor_e5baabe45344a177, []int{15}
}
var extRange_EnumValueOptions = []proto.ExtensionRange{
@@ -1954,14 +2020,15 @@
func (*EnumValueOptions) ExtensionRangeArray() []proto.ExtensionRange {
return extRange_EnumValueOptions
}
+
func (m *EnumValueOptions) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_EnumValueOptions.Unmarshal(m, b)
}
func (m *EnumValueOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_EnumValueOptions.Marshal(b, m, deterministic)
}
-func (dst *EnumValueOptions) XXX_Merge(src proto.Message) {
- xxx_messageInfo_EnumValueOptions.Merge(dst, src)
+func (m *EnumValueOptions) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_EnumValueOptions.Merge(m, src)
}
func (m *EnumValueOptions) XXX_Size() int {
return xxx_messageInfo_EnumValueOptions.Size(m)
@@ -2006,7 +2073,7 @@
func (m *ServiceOptions) String() string { return proto.CompactTextString(m) }
func (*ServiceOptions) ProtoMessage() {}
func (*ServiceOptions) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{16}
+ return fileDescriptor_e5baabe45344a177, []int{16}
}
var extRange_ServiceOptions = []proto.ExtensionRange{
@@ -2016,14 +2083,15 @@
func (*ServiceOptions) ExtensionRangeArray() []proto.ExtensionRange {
return extRange_ServiceOptions
}
+
func (m *ServiceOptions) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ServiceOptions.Unmarshal(m, b)
}
func (m *ServiceOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ServiceOptions.Marshal(b, m, deterministic)
}
-func (dst *ServiceOptions) XXX_Merge(src proto.Message) {
- xxx_messageInfo_ServiceOptions.Merge(dst, src)
+func (m *ServiceOptions) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_ServiceOptions.Merge(m, src)
}
func (m *ServiceOptions) XXX_Size() int {
return xxx_messageInfo_ServiceOptions.Size(m)
@@ -2069,7 +2137,7 @@
func (m *MethodOptions) String() string { return proto.CompactTextString(m) }
func (*MethodOptions) ProtoMessage() {}
func (*MethodOptions) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{17}
+ return fileDescriptor_e5baabe45344a177, []int{17}
}
var extRange_MethodOptions = []proto.ExtensionRange{
@@ -2079,14 +2147,15 @@
func (*MethodOptions) ExtensionRangeArray() []proto.ExtensionRange {
return extRange_MethodOptions
}
+
func (m *MethodOptions) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_MethodOptions.Unmarshal(m, b)
}
func (m *MethodOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_MethodOptions.Marshal(b, m, deterministic)
}
-func (dst *MethodOptions) XXX_Merge(src proto.Message) {
- xxx_messageInfo_MethodOptions.Merge(dst, src)
+func (m *MethodOptions) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MethodOptions.Merge(m, src)
}
func (m *MethodOptions) XXX_Size() int {
return xxx_messageInfo_MethodOptions.Size(m)
@@ -2146,16 +2215,17 @@
func (m *UninterpretedOption) String() string { return proto.CompactTextString(m) }
func (*UninterpretedOption) ProtoMessage() {}
func (*UninterpretedOption) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{18}
+ return fileDescriptor_e5baabe45344a177, []int{18}
}
+
func (m *UninterpretedOption) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_UninterpretedOption.Unmarshal(m, b)
}
func (m *UninterpretedOption) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_UninterpretedOption.Marshal(b, m, deterministic)
}
-func (dst *UninterpretedOption) XXX_Merge(src proto.Message) {
- xxx_messageInfo_UninterpretedOption.Merge(dst, src)
+func (m *UninterpretedOption) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_UninterpretedOption.Merge(m, src)
}
func (m *UninterpretedOption) XXX_Size() int {
return xxx_messageInfo_UninterpretedOption.Size(m)
@@ -2232,16 +2302,17 @@
func (m *UninterpretedOption_NamePart) String() string { return proto.CompactTextString(m) }
func (*UninterpretedOption_NamePart) ProtoMessage() {}
func (*UninterpretedOption_NamePart) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{18, 0}
+ return fileDescriptor_e5baabe45344a177, []int{18, 0}
}
+
func (m *UninterpretedOption_NamePart) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_UninterpretedOption_NamePart.Unmarshal(m, b)
}
func (m *UninterpretedOption_NamePart) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_UninterpretedOption_NamePart.Marshal(b, m, deterministic)
}
-func (dst *UninterpretedOption_NamePart) XXX_Merge(src proto.Message) {
- xxx_messageInfo_UninterpretedOption_NamePart.Merge(dst, src)
+func (m *UninterpretedOption_NamePart) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_UninterpretedOption_NamePart.Merge(m, src)
}
func (m *UninterpretedOption_NamePart) XXX_Size() int {
return xxx_messageInfo_UninterpretedOption_NamePart.Size(m)
@@ -2322,16 +2393,17 @@
func (m *SourceCodeInfo) String() string { return proto.CompactTextString(m) }
func (*SourceCodeInfo) ProtoMessage() {}
func (*SourceCodeInfo) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{19}
+ return fileDescriptor_e5baabe45344a177, []int{19}
}
+
func (m *SourceCodeInfo) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_SourceCodeInfo.Unmarshal(m, b)
}
func (m *SourceCodeInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_SourceCodeInfo.Marshal(b, m, deterministic)
}
-func (dst *SourceCodeInfo) XXX_Merge(src proto.Message) {
- xxx_messageInfo_SourceCodeInfo.Merge(dst, src)
+func (m *SourceCodeInfo) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_SourceCodeInfo.Merge(m, src)
}
func (m *SourceCodeInfo) XXX_Size() int {
return xxx_messageInfo_SourceCodeInfo.Size(m)
@@ -2439,16 +2511,17 @@
func (m *SourceCodeInfo_Location) String() string { return proto.CompactTextString(m) }
func (*SourceCodeInfo_Location) ProtoMessage() {}
func (*SourceCodeInfo_Location) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{19, 0}
+ return fileDescriptor_e5baabe45344a177, []int{19, 0}
}
+
func (m *SourceCodeInfo_Location) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_SourceCodeInfo_Location.Unmarshal(m, b)
}
func (m *SourceCodeInfo_Location) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_SourceCodeInfo_Location.Marshal(b, m, deterministic)
}
-func (dst *SourceCodeInfo_Location) XXX_Merge(src proto.Message) {
- xxx_messageInfo_SourceCodeInfo_Location.Merge(dst, src)
+func (m *SourceCodeInfo_Location) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_SourceCodeInfo_Location.Merge(m, src)
}
func (m *SourceCodeInfo_Location) XXX_Size() int {
return xxx_messageInfo_SourceCodeInfo_Location.Size(m)
@@ -2510,16 +2583,17 @@
func (m *GeneratedCodeInfo) String() string { return proto.CompactTextString(m) }
func (*GeneratedCodeInfo) ProtoMessage() {}
func (*GeneratedCodeInfo) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{20}
+ return fileDescriptor_e5baabe45344a177, []int{20}
}
+
func (m *GeneratedCodeInfo) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GeneratedCodeInfo.Unmarshal(m, b)
}
func (m *GeneratedCodeInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_GeneratedCodeInfo.Marshal(b, m, deterministic)
}
-func (dst *GeneratedCodeInfo) XXX_Merge(src proto.Message) {
- xxx_messageInfo_GeneratedCodeInfo.Merge(dst, src)
+func (m *GeneratedCodeInfo) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_GeneratedCodeInfo.Merge(m, src)
}
func (m *GeneratedCodeInfo) XXX_Size() int {
return xxx_messageInfo_GeneratedCodeInfo.Size(m)
@@ -2559,16 +2633,17 @@
func (m *GeneratedCodeInfo_Annotation) String() string { return proto.CompactTextString(m) }
func (*GeneratedCodeInfo_Annotation) ProtoMessage() {}
func (*GeneratedCodeInfo_Annotation) Descriptor() ([]byte, []int) {
- return fileDescriptor_descriptor_4df4cb5f42392df6, []int{20, 0}
+ return fileDescriptor_e5baabe45344a177, []int{20, 0}
}
+
func (m *GeneratedCodeInfo_Annotation) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GeneratedCodeInfo_Annotation.Unmarshal(m, b)
}
func (m *GeneratedCodeInfo_Annotation) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_GeneratedCodeInfo_Annotation.Marshal(b, m, deterministic)
}
-func (dst *GeneratedCodeInfo_Annotation) XXX_Merge(src proto.Message) {
- xxx_messageInfo_GeneratedCodeInfo_Annotation.Merge(dst, src)
+func (m *GeneratedCodeInfo_Annotation) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_GeneratedCodeInfo_Annotation.Merge(m, src)
}
func (m *GeneratedCodeInfo_Annotation) XXX_Size() int {
return xxx_messageInfo_GeneratedCodeInfo_Annotation.Size(m)
@@ -2608,6 +2683,12 @@
}
func init() {
+ proto.RegisterEnum("google.protobuf.FieldDescriptorProto_Type", FieldDescriptorProto_Type_name, FieldDescriptorProto_Type_value)
+ proto.RegisterEnum("google.protobuf.FieldDescriptorProto_Label", FieldDescriptorProto_Label_name, FieldDescriptorProto_Label_value)
+ proto.RegisterEnum("google.protobuf.FileOptions_OptimizeMode", FileOptions_OptimizeMode_name, FileOptions_OptimizeMode_value)
+ proto.RegisterEnum("google.protobuf.FieldOptions_CType", FieldOptions_CType_name, FieldOptions_CType_value)
+ proto.RegisterEnum("google.protobuf.FieldOptions_JSType", FieldOptions_JSType_name, FieldOptions_JSType_value)
+ proto.RegisterEnum("google.protobuf.MethodOptions_IdempotencyLevel", MethodOptions_IdempotencyLevel_name, MethodOptions_IdempotencyLevel_value)
proto.RegisterType((*FileDescriptorSet)(nil), "google.protobuf.FileDescriptorSet")
proto.RegisterType((*FileDescriptorProto)(nil), "google.protobuf.FileDescriptorProto")
proto.RegisterType((*DescriptorProto)(nil), "google.protobuf.DescriptorProto")
@@ -2635,178 +2716,172 @@
proto.RegisterType((*SourceCodeInfo_Location)(nil), "google.protobuf.SourceCodeInfo.Location")
proto.RegisterType((*GeneratedCodeInfo)(nil), "google.protobuf.GeneratedCodeInfo")
proto.RegisterType((*GeneratedCodeInfo_Annotation)(nil), "google.protobuf.GeneratedCodeInfo.Annotation")
- proto.RegisterEnum("google.protobuf.FieldDescriptorProto_Type", FieldDescriptorProto_Type_name, FieldDescriptorProto_Type_value)
- proto.RegisterEnum("google.protobuf.FieldDescriptorProto_Label", FieldDescriptorProto_Label_name, FieldDescriptorProto_Label_value)
- proto.RegisterEnum("google.protobuf.FileOptions_OptimizeMode", FileOptions_OptimizeMode_name, FileOptions_OptimizeMode_value)
- proto.RegisterEnum("google.protobuf.FieldOptions_CType", FieldOptions_CType_name, FieldOptions_CType_value)
- proto.RegisterEnum("google.protobuf.FieldOptions_JSType", FieldOptions_JSType_name, FieldOptions_JSType_value)
- proto.RegisterEnum("google.protobuf.MethodOptions_IdempotencyLevel", MethodOptions_IdempotencyLevel_name, MethodOptions_IdempotencyLevel_value)
}
-func init() {
- proto.RegisterFile("google/protobuf/descriptor.proto", fileDescriptor_descriptor_4df4cb5f42392df6)
-}
+func init() { proto.RegisterFile("google/protobuf/descriptor.proto", fileDescriptor_e5baabe45344a177) }
-var fileDescriptor_descriptor_4df4cb5f42392df6 = []byte{
- // 2555 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x59, 0xdd, 0x6e, 0x1b, 0xc7,
- 0xf5, 0xcf, 0xf2, 0x4b, 0xe4, 0x21, 0x45, 0x8d, 0x46, 0x8a, 0xbd, 0x56, 0x3e, 0x2c, 0x33, 0x1f,
- 0x96, 0x9d, 0x7f, 0xa8, 0xc0, 0xb1, 0x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xc1, 0x95, 0x48, 0xaf, 0x41, 0x03, 0xa2, 0x8f, 0xa9,
- 0x31, 0x13, 0x2a, 0xf0, 0x47, 0x88, 0xcb, 0x21, 0xa1, 0x15, 0xf6, 0x47, 0xb2, 0xb5, 0x6f, 0x24,
- 0x58, 0x8f, 0xae, 0x53, 0x46, 0xec, 0xac, 0x63, 0x00, 0x62, 0xdb, 0x4e, 0x90, 0x74, 0xd7, 0x62,
- 0x28, 0x2f, 0xc8, 0xd5, 0x1b, 0xb1, 0x90, 0x9a, 0x50, 0xb0, 0x35, 0x01, 0x98, 0xf5, 0x9c, 0xeb,
- 0xb6, 0xab, 0x50, 0x0e, 0x3f, 0xf0, 0xf0, 0xaf, 0x84, 0xe2, 0x02, 0x0e, 0x02, 0x62, 0xf7, 0x2e,
- 0xbc, 0x09, 0xf9, 0x53, 0x3a, 0x32, 0xed, 0xf0, 0xd9, 0x56, 0x34, 0xa2, 0x67, 0x92, 0x5c, 0xfc,
- 0x4c, 0xb2, 0xff, 0x5b, 0x09, 0x36, 0x74, 0x67, 0x32, 0x6f, 0xef, 0x3e, 0x9a, 0x7b, 0x05, 0xf0,
- 0x3f, 0x96, 0x3e, 0xff, 0x68, 0x64, 0x06, 0xe3, 0xe9, 0x69, 0x5d, 0x77, 0x26, 0xbb, 0x23, 0xc7,
- 0x22, 0xf6, 0x68, 0xf6, 0x99, 0x93, 0xff, 0xd1, 0xdf, 0x1d, 0x51, 0xfb, 0xdd, 0x91, 0x93, 0xf8,
- 0xe8, 0x79, 0x7f, 0xf6, 0xf7, 0xbf, 0x92, 0xf4, 0xa7, 0x4c, 0xf6, 0xa0, 0xb7, 0xff, 0xe7, 0xcc,
- 0xd6, 0x81, 0x18, 0xae, 0x17, 0xb9, 0x47, 0xa5, 0x43, 0x8b, 0xea, 0x6c, 0xca, 0xff, 0x0b, 0x00,
- 0x00, 0xff, 0xff, 0x1a, 0x28, 0x25, 0x79, 0x42, 0x1d, 0x00, 0x00,
+var fileDescriptor_e5baab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x6f, 0x42, 0xfe, 0x84, 0x8e, 0x4c, 0x3b, 0x7c, 0x0f, 0x16, 0x8d, 0xe8, 0xfd, 0x25,
+ 0x17, 0xbf, 0xbf, 0xec, 0xff, 0x46, 0x82, 0x0d, 0xdd, 0x99, 0xcc, 0xfb, 0xbb, 0x8f, 0xe6, 0x9e,
+ 0x17, 0xfc, 0x8f, 0xa5, 0xcf, 0x3f, 0x1a, 0x99, 0xc1, 0x78, 0x7a, 0x52, 0xd7, 0x9d, 0xc9, 0xee,
+ 0xc8, 0xb1, 0x88, 0x3d, 0x9a, 0x7d, 0x3f, 0xe5, 0x7f, 0xf4, 0x1b, 0x23, 0x6a, 0xdf, 0x18, 0x39,
+ 0x89, 0xaf, 0xa9, 0xf7, 0x66, 0x7f, 0xff, 0x27, 0x49, 0x7f, 0xca, 0x64, 0x0f, 0x7a, 0xfb, 0x7f,
+ 0xce, 0x6c, 0x1d, 0x88, 0xee, 0x7a, 0x51, 0x78, 0x54, 0x3a, 0xb4, 0xa8, 0xce, 0x86, 0xfc, 0xff,
+ 0x00, 0x00, 0x00, 0xff, 0xff, 0x3e, 0xe8, 0xef, 0xc4, 0x9b, 0x1d, 0x00, 0x00,
}
diff --git a/vendor/github.com/golang/protobuf/protoc-gen-go/descriptor/descriptor.proto b/vendor/github.com/golang/protobuf/protoc-gen-go/descriptor/descriptor.proto
index 8697a50..ed08fcb 100644
--- a/vendor/github.com/golang/protobuf/protoc-gen-go/descriptor/descriptor.proto
+++ b/vendor/github.com/golang/protobuf/protoc-gen-go/descriptor/descriptor.proto
@@ -417,6 +417,17 @@
// determining the namespace.
optional string php_namespace = 41;
+
+ // Use this option to change the namespace of php generated metadata classes.
+ // Default is empty. When this option is empty, the proto file name will be used
+ // for determining the namespace.
+ optional string php_metadata_namespace = 44;
+
+ // Use this option to change the package of ruby generated classes. Default
+ // is empty. When this option is not set, the package name will be used for
+ // determining the ruby package.
+ optional string ruby_package = 45;
+
// The parser stores options it doesn't recognize here.
// See the documentation for the "Options" section above.
repeated UninterpretedOption uninterpreted_option = 999;
diff --git a/vendor/github.com/golang/protobuf/protoc-gen-go/generator/generator.go b/vendor/github.com/golang/protobuf/protoc-gen-go/generator/generator.go
index c13a9f1..6f4a902 100644
--- a/vendor/github.com/golang/protobuf/protoc-gen-go/generator/generator.go
+++ b/vendor/github.com/golang/protobuf/protoc-gen-go/generator/generator.go
@@ -43,6 +43,7 @@
"crypto/sha256"
"encoding/hex"
"fmt"
+ "go/ast"
"go/build"
"go/parser"
"go/printer"
@@ -67,7 +68,7 @@
// It is incremented whenever an incompatibility between the generated code and
// proto package is introduced; the generated code references
// a constant, proto.ProtoPackageIsVersionN (where N is generatedCodeVersion).
-const generatedCodeVersion = 2
+const generatedCodeVersion = 3
// A Plugin provides functionality to add to the output during Go code generation,
// such as to produce RPC stubs.
@@ -271,7 +272,6 @@
// This is used for supporting public imports.
exported map[Object][]symbol
- fingerprint string // Fingerprint of this file's contents.
importPath GoImportPath // Import path of this file's package.
packageName GoPackageName // Name of this file's Go package.
@@ -282,8 +282,8 @@
// to the compressed bytes of this descriptor. It is not exported, so
// it is only valid inside the generated package.
func (d *FileDescriptor) VarName() string {
- name := strings.Map(badToUnderscore, baseName(d.GetName()))
- return fmt.Sprintf("fileDescriptor_%s_%s", name, d.fingerprint)
+ h := sha256.Sum256([]byte(d.GetName()))
+ return fmt.Sprintf("fileDescriptor_%s", hex.EncodeToString(h[:8]))
}
// goPackageOption interprets the file's go_package option.
@@ -340,7 +340,7 @@
type symbol interface {
// GenerateAlias should generate an appropriate alias
// for the symbol from the named package.
- GenerateAlias(g *Generator, pkg GoPackageName)
+ GenerateAlias(g *Generator, filename string, pkg GoPackageName)
}
type messageSymbol struct {
@@ -356,7 +356,8 @@
genType bool // whether typ contains a generated type (message/group/enum)
}
-func (ms *messageSymbol) GenerateAlias(g *Generator, pkg GoPackageName) {
+func (ms *messageSymbol) GenerateAlias(g *Generator, filename string, pkg GoPackageName) {
+ g.P("// ", ms.sym, " from public import ", filename)
g.P("type ", ms.sym, " = ", pkg, ".", ms.sym)
for _, name := range ms.oneofTypes {
g.P("type ", name, " = ", pkg, ".", name)
@@ -368,8 +369,9 @@
proto3 bool // Whether this came from a proto3 file.
}
-func (es enumSymbol) GenerateAlias(g *Generator, pkg GoPackageName) {
+func (es enumSymbol) GenerateAlias(g *Generator, filename string, pkg GoPackageName) {
s := es.name
+ g.P("// ", s, " from public import ", filename)
g.P("type ", s, " = ", pkg, ".", s)
g.P("var ", s, "_name = ", pkg, ".", s, "_name")
g.P("var ", s, "_value = ", pkg, ".", s, "_value")
@@ -381,7 +383,7 @@
cast string // if non-empty, a type cast is required (used for enums)
}
-func (cs constOrVarSymbol) GenerateAlias(g *Generator, pkg GoPackageName) {
+func (cs constOrVarSymbol) GenerateAlias(g *Generator, filename string, pkg GoPackageName) {
v := string(pkg) + "." + cs.sym
if cs.cast != "" {
v = cs.cast + "(" + v + ")"
@@ -418,6 +420,7 @@
packageNames map[GoImportPath]GoPackageName // Imported package names in the current file.
usedPackages map[GoImportPath]bool // Packages used in current file.
usedPackageNames map[GoPackageName]bool // Package names used in the current file.
+ addedImports map[GoImportPath]bool // Additional imports to emit.
typeNameToObject map[string]Object // Key is a fully-qualified name in input syntax.
init []string // Lines to emit in the init function.
indent string
@@ -532,7 +535,7 @@
return name
}
name := cleanPackageName(baseName(string(importPath)))
- for i, orig := 1, name; g.usedPackageNames[name]; i++ {
+ for i, orig := 1, name; g.usedPackageNames[name] || isGoPredeclaredIdentifier[string(name)]; i++ {
name = orig + GoPackageName(strconv.Itoa(i))
}
g.packageNames[importPath] = name
@@ -540,6 +543,13 @@
return name
}
+// AddImport adds a package to the generated file's import section.
+// It returns the name used for the package.
+func (g *Generator) AddImport(importPath GoImportPath) GoPackageName {
+ g.addedImports[importPath] = true
+ return g.GoPackageName(importPath)
+}
+
var globalPackageNames = map[GoPackageName]bool{
"fmt": true,
"math": true,
@@ -585,9 +595,51 @@
"var": true,
}
+var isGoPredeclaredIdentifier = map[string]bool{
+ "append": true,
+ "bool": true,
+ "byte": true,
+ "cap": true,
+ "close": true,
+ "complex": true,
+ "complex128": true,
+ "complex64": true,
+ "copy": true,
+ "delete": true,
+ "error": true,
+ "false": true,
+ "float32": true,
+ "float64": true,
+ "imag": true,
+ "int": true,
+ "int16": true,
+ "int32": true,
+ "int64": true,
+ "int8": true,
+ "iota": true,
+ "len": true,
+ "make": true,
+ "new": true,
+ "nil": true,
+ "panic": true,
+ "print": true,
+ "println": true,
+ "real": true,
+ "recover": true,
+ "rune": true,
+ "string": true,
+ "true": true,
+ "uint": true,
+ "uint16": true,
+ "uint32": true,
+ "uint64": true,
+ "uint8": true,
+ "uintptr": true,
+}
+
func cleanPackageName(name string) GoPackageName {
name = strings.Map(badToUnderscore, name)
- // Identifier must not be keyword: insert _.
+ // Identifier must not be keyword or predeclared identifier: insert _.
if isGoKeyword[name] {
name = "_" + name
}
@@ -724,27 +776,10 @@
if fd == nil {
g.Fail("could not find file named", fileName)
}
- fingerprint, err := fingerprintProto(fd.FileDescriptorProto)
- if err != nil {
- g.Error(err)
- }
- fd.fingerprint = fingerprint
g.genFiles = append(g.genFiles, fd)
}
}
-// fingerprintProto returns a fingerprint for a message.
-// The fingerprint is intended to prevent conflicts between generated fileds,
-// not to provide cryptographic security.
-func fingerprintProto(m proto.Message) (string, error) {
- b, err := proto.Marshal(m)
- if err != nil {
- return "", err
- }
- h := sha256.Sum256(b)
- return hex.EncodeToString(h[:8]), nil
-}
-
// Scan the descriptors in this file. For each one, build the slice of nested descriptors
func (g *Generator) buildNestedDescriptors(descs []*Descriptor) {
for _, desc := range descs {
@@ -938,39 +973,6 @@
if !ok {
g.Fail("can't find object with type", typeName)
}
-
- // If the file of this object isn't a direct dependency of the current file,
- // or in the current file, then this object has been publicly imported into
- // a dependency of the current file.
- // We should return the ImportedDescriptor object for it instead.
- direct := *o.File().Name == *g.file.Name
- if !direct {
- for _, dep := range g.file.Dependency {
- if *g.fileByName(dep).Name == *o.File().Name {
- direct = true
- break
- }
- }
- }
- if !direct {
- found := false
- Loop:
- for _, dep := range g.file.Dependency {
- df := g.fileByName(*g.fileByName(dep).Name)
- for _, td := range df.imp {
- if td.o == o {
- // Found it!
- o = td
- found = true
- break Loop
- }
- }
- }
- if !found {
- log.Printf("protoc-gen-go: WARNING: failed finding publicly imported dependency for %v, used in %v", typeName, *g.file.Name)
- }
- }
-
return o
}
@@ -1124,6 +1126,7 @@
g.usedPackages = make(map[GoImportPath]bool)
g.packageNames = make(map[GoImportPath]GoPackageName)
g.usedPackageNames = make(map[GoPackageName]bool)
+ g.addedImports = make(map[GoImportPath]bool)
for name := range globalPackageNames {
g.usedPackageNames[name] = true
}
@@ -1152,12 +1155,11 @@
g.generateExtension(ext)
}
g.generateInitFunction()
+ g.generateFileDescriptor(file)
// Run the plugins before the imports so we know which imports are necessary.
g.runPlugins(file)
- g.generateFileDescriptor(file)
-
// Generate header and imports last, though they appear first in the output.
rem := g.Buffer
remAnno := g.annotations
@@ -1183,7 +1185,7 @@
// make a copy independent of g; we'll need it after Reset.
original = append([]byte(nil), original...)
}
- ast, err := parser.ParseFile(fset, "", original, parser.ParseComments)
+ fileAST, err := parser.ParseFile(fset, "", original, parser.ParseComments)
if err != nil {
// Print out the bad code with line numbers.
// This should never happen in practice, but it can while changing generated code,
@@ -1195,8 +1197,9 @@
}
g.Fail("bad Go source code was generated:", err.Error(), "\n"+src.String())
}
+ ast.SortImports(fset, fileAST)
g.Reset()
- err = (&printer.Config{Mode: printer.TabIndent | printer.UseSpaces, Tabwidth: 8}).Fprint(g, fset, ast)
+ err = (&printer.Config{Mode: printer.TabIndent | printer.UseSpaces, Tabwidth: 8}).Fprint(g, fset, fileAST)
if err != nil {
g.Fail("generated Go source code could not be reformatted:", err.Error())
}
@@ -1225,28 +1228,10 @@
g.P("// source: ", g.file.Name)
}
g.P()
-
- importPath, _, _ := g.file.goPackageOption()
- if importPath == "" {
- g.P("package ", g.file.packageName)
- } else {
- g.P("package ", g.file.packageName, " // import ", GoImportPath(g.ImportPrefix)+importPath)
- }
+ g.PrintComments(strconv.Itoa(packagePath))
g.P()
-
- if loc, ok := g.file.comments[strconv.Itoa(packagePath)]; ok {
- g.P("/*")
- // not using g.PrintComments because this is a /* */ comment block.
- text := strings.TrimSuffix(loc.GetLeadingComments(), "\n")
- for _, line := range strings.Split(text, "\n") {
- line = strings.TrimPrefix(line, " ")
- // ensure we don't escape from the block comment
- line = strings.Replace(line, "*/", "* /", -1)
- g.P(line)
- }
- g.P("*/")
- g.P()
- }
+ g.P("package ", g.file.packageName)
+ g.P()
}
// deprecationComment is the standard comment added to deprecated
@@ -1277,7 +1262,7 @@
w := new(bytes.Buffer)
nl := ""
for _, line := range strings.Split(strings.TrimSuffix(loc.GetLeadingComments(), "\n"), "\n") {
- fmt.Fprintf(w, "%s// %s", nl, strings.TrimPrefix(line, " "))
+ fmt.Fprintf(w, "%s//%s", nl, line)
nl = "\n"
}
return w.String(), true
@@ -1299,17 +1284,7 @@
// Generate the imports
func (g *Generator) generateImports() {
- // We almost always need a proto import. Rather than computing when we
- // do, which is tricky when there's a plugin, just import it and
- // reference it later. The same argument applies to the fmt and math packages.
- g.P("import "+g.Pkg["proto"]+" ", GoImportPath(g.ImportPrefix)+"github.com/golang/protobuf/proto")
- g.P("import " + g.Pkg["fmt"] + ` "fmt"`)
- g.P("import " + g.Pkg["math"] + ` "math"`)
- var (
- imports = make(map[GoImportPath]bool)
- strongImports = make(map[GoImportPath]bool)
- importPaths []string
- )
+ imports := make(map[GoImportPath]GoPackageName)
for i, s := range g.file.Dependency {
fd := g.fileByName(s)
importPath := fd.importPath
@@ -1317,32 +1292,37 @@
if importPath == g.file.importPath {
continue
}
- if !imports[importPath] {
- importPaths = append(importPaths, string(importPath))
+ // Do not import weak imports.
+ if g.weak(int32(i)) {
+ continue
}
- imports[importPath] = true
- if !g.weak(int32(i)) {
- strongImports[importPath] = true
- }
- }
- sort.Strings(importPaths)
- for i := range importPaths {
- importPath := GoImportPath(importPaths[i])
- packageName := g.GoPackageName(importPath)
- fullPath := GoImportPath(g.ImportPrefix) + importPath
- // Skip weak imports.
- if !strongImports[importPath] {
- g.P("// skipping weak import ", packageName, " ", fullPath)
+ // Do not import a package twice.
+ if _, ok := imports[importPath]; ok {
continue
}
// We need to import all the dependencies, even if we don't reference them,
// because other code and tools depend on having the full transitive closure
// of protocol buffer types in the binary.
+ packageName := g.GoPackageName(importPath)
if _, ok := g.usedPackages[importPath]; !ok {
packageName = "_"
}
- g.P("import ", packageName, " ", fullPath)
+ imports[importPath] = packageName
}
+ for importPath := range g.addedImports {
+ imports[importPath] = g.GoPackageName(importPath)
+ }
+ // We almost always need a proto import. Rather than computing when we
+ // do, which is tricky when there's a plugin, just import it and
+ // reference it later. The same argument applies to the fmt and math packages.
+ g.P("import (")
+ g.P(g.Pkg["fmt"] + ` "fmt"`)
+ g.P(g.Pkg["math"] + ` "math"`)
+ g.P(g.Pkg["proto"]+" ", GoImportPath(g.ImportPrefix)+"github.com/golang/protobuf/proto")
+ for importPath, packageName := range imports {
+ g.P(packageName, " ", GoImportPath(g.ImportPrefix)+importPath)
+ }
+ g.P(")")
g.P()
// TODO: may need to worry about uniqueness across plugins
for _, p := range plugins {
@@ -1357,24 +1337,19 @@
}
func (g *Generator) generateImported(id *ImportedDescriptor) {
- tn := id.TypeName()
- sn := tn[len(tn)-1]
df := id.o.File()
filename := *df.Name
if df.importPath == g.file.importPath {
// Don't generate type aliases for files in the same Go package as this one.
- g.P("// Ignoring public import of ", sn, " from ", filename)
- g.P()
return
}
if !supportTypeAliases {
g.Fail(fmt.Sprintf("%s: public imports require at least go1.9", filename))
}
- g.P("// ", sn, " from public import ", filename)
g.usedPackages[df.importPath] = true
for _, sym := range df.exported[id.o] {
- sym.GenerateAlias(g, g.GoPackageName(df.importPath))
+ sym.GenerateAlias(g, filename, g.GoPackageName(df.importPath))
}
g.P()
@@ -1410,6 +1385,7 @@
g.file.addExport(enum, constOrVarSymbol{name, "const", ccTypeName})
}
g.P(")")
+ g.P()
g.P("var ", ccTypeName, "_name = map[int32]string{")
generated := make(map[int32]bool) // avoid duplicate values
for _, e := range enum.Value {
@@ -1421,11 +1397,13 @@
generated[*e.Number] = true
}
g.P("}")
+ g.P()
g.P("var ", ccTypeName, "_value = map[string]int32{")
for _, e := range enum.Value {
g.P(strconv.Quote(*e.Name), ": ", e.Number, ",")
}
g.P("}")
+ g.P()
if !enum.proto3() {
g.P("func (x ", ccTypeName, ") Enum() *", ccTypeName, " {")
@@ -1433,11 +1411,13 @@
g.P("*p = x")
g.P("return p")
g.P("}")
+ g.P()
}
g.P("func (x ", ccTypeName, ") String() string {")
g.P("return ", g.Pkg["proto"], ".EnumName(", ccTypeName, "_name, int32(x))")
g.P("}")
+ g.P()
if !enum.proto3() {
g.P("func (x *", ccTypeName, ") UnmarshalJSON(data []byte) error {")
@@ -1448,6 +1428,7 @@
g.P("*x = ", ccTypeName, "(value)")
g.P("return nil")
g.P("}")
+ g.P()
}
var indexes []string
@@ -1459,11 +1440,13 @@
g.P("func (", ccTypeName, ") EnumDescriptor() ([]byte, []int) {")
g.P("return ", g.file.VarName(), ", []int{", strings.Join(indexes, ", "), "}")
g.P("}")
+ g.P()
if enum.file.GetPackage() == "google.protobuf" && enum.GetName() == "NullValue" {
g.P("func (", ccTypeName, `) XXX_WellKnownType() string { return "`, enum.GetName(), `" }`)
+ g.P()
}
- g.P()
+ g.generateEnumRegistration(enum)
}
// The tag is a string like "varint,2,opt,name=fieldname,def=7" that
@@ -1520,6 +1503,18 @@
g.Fail("unknown enum type", CamelCaseSlice(obj.TypeName()))
}
defaultValue = enum.integerValueAsString(defaultValue)
+ case descriptor.FieldDescriptorProto_TYPE_FLOAT:
+ if def := defaultValue; def != "inf" && def != "-inf" && def != "nan" {
+ if f, err := strconv.ParseFloat(defaultValue, 32); err == nil {
+ defaultValue = fmt.Sprint(float32(f))
+ }
+ }
+ case descriptor.FieldDescriptorProto_TYPE_DOUBLE:
+ if def := defaultValue; def != "inf" && def != "-inf" && def != "nan" {
+ if f, err := strconv.ParseFloat(defaultValue, 64); err == nil {
+ defaultValue = fmt.Sprint(f)
+ }
+ }
}
defaultValue = ",def=" + defaultValue
}
@@ -1557,7 +1552,7 @@
name = name[i+1:]
}
}
- if json := field.GetJsonName(); json != "" && json != name {
+ if json := field.GetJsonName(); field.Extendee == nil && json != "" && json != name {
// TODO: escaping might be needed, in which case
// perhaps this should be in its own "json" tag.
name += ",json=" + json
@@ -1661,11 +1656,16 @@
}
func (g *Generator) RecordTypeUse(t string) {
- if _, ok := g.typeNameToObject[t]; ok {
- // Call ObjectNamed to get the true object to record the use.
- obj := g.ObjectNamed(t)
- g.usedPackages[obj.GoImportPath()] = true
+ if _, ok := g.typeNameToObject[t]; !ok {
+ return
}
+ importPath := g.ObjectNamed(t).GoImportPath()
+ if importPath == g.outputImportPath {
+ // Don't record use of objects in our package.
+ return
+ }
+ g.AddImport(importPath)
+ g.usedPackages[importPath] = true
}
// Method names that may be generated. Fields with these names get an
@@ -1765,7 +1765,7 @@
// oneofField - field containing list of subfields:
// - oneofSubField - a field within the oneof
-// msgCtx contais the context for the generator functions.
+// msgCtx contains the context for the generator functions.
type msgCtx struct {
goName string // Go struct name of the message, e.g. MessageName
message *Descriptor // The descriptor for the message
@@ -1869,216 +1869,15 @@
fieldNumber int // Actual field number, as defined in proto, e.g. 12
getterDef string // Default for getters, e.g. "nil", `""` or "Default_MessageType_FieldName"
protoDef string // Default value as defined in the proto file, e.g "yoshi" or "5"
-}
-
-// wireTypeName returns a textual wire type, needed for oneof sub fields in generated code.
-func (f *oneofSubField) wireTypeName() string {
- switch f.protoType {
- case descriptor.FieldDescriptorProto_TYPE_FIXED64,
- descriptor.FieldDescriptorProto_TYPE_SFIXED64,
- descriptor.FieldDescriptorProto_TYPE_DOUBLE:
- return "WireFixed64"
- case descriptor.FieldDescriptorProto_TYPE_FIXED32,
- descriptor.FieldDescriptorProto_TYPE_SFIXED32,
- descriptor.FieldDescriptorProto_TYPE_FLOAT:
- return "WireFixed32"
- case descriptor.FieldDescriptorProto_TYPE_GROUP:
- return "WireStartGroup"
- case descriptor.FieldDescriptorProto_TYPE_MESSAGE,
- descriptor.FieldDescriptorProto_TYPE_STRING,
- descriptor.FieldDescriptorProto_TYPE_BYTES:
- return "WireBytes"
- default: // All others are Varints
- return "WireVarint"
- }
+ deprecated string // Deprecation comment, if any.
}
// typedNil prints a nil casted to the pointer to this field.
-// - for XXX_OneofFuncs
+// - for XXX_OneofWrappers
func (f *oneofSubField) typedNil(g *Generator) {
g.P("(*", f.oneofTypeName, ")(nil),")
}
-// marshalCase prints the case matching this oneof subfield in the marshalling code.
-func (f *oneofSubField) marshalCase(g *Generator) {
- g.P("case *", f.oneofTypeName, ":")
- wire := f.wireTypeName()
- var pre, post string
- val := "x." + f.goName // overridden for TYPE_BOOL
- switch f.protoType {
- case descriptor.FieldDescriptorProto_TYPE_DOUBLE:
- pre = "b.EncodeFixed64(" + g.Pkg["math"] + ".Float64bits("
- post = "))"
- case descriptor.FieldDescriptorProto_TYPE_FLOAT:
- pre = "b.EncodeFixed32(uint64(" + g.Pkg["math"] + ".Float32bits("
- post = ")))"
- case descriptor.FieldDescriptorProto_TYPE_INT64, descriptor.FieldDescriptorProto_TYPE_UINT64:
- pre, post = "b.EncodeVarint(uint64(", "))"
- case descriptor.FieldDescriptorProto_TYPE_INT32, descriptor.FieldDescriptorProto_TYPE_UINT32, descriptor.FieldDescriptorProto_TYPE_ENUM:
- pre, post = "b.EncodeVarint(uint64(", "))"
- case descriptor.FieldDescriptorProto_TYPE_FIXED64, descriptor.FieldDescriptorProto_TYPE_SFIXED64:
- pre, post = "b.EncodeFixed64(uint64(", "))"
- case descriptor.FieldDescriptorProto_TYPE_FIXED32, descriptor.FieldDescriptorProto_TYPE_SFIXED32:
- pre, post = "b.EncodeFixed32(uint64(", "))"
- case descriptor.FieldDescriptorProto_TYPE_BOOL:
- g.P("t := uint64(0)")
- g.P("if ", val, " { t = 1 }")
- val = "t"
- pre, post = "b.EncodeVarint(", ")"
- case descriptor.FieldDescriptorProto_TYPE_STRING:
- pre, post = "b.EncodeStringBytes(", ")"
- case descriptor.FieldDescriptorProto_TYPE_GROUP:
- pre, post = "b.Marshal(", ")"
- case descriptor.FieldDescriptorProto_TYPE_MESSAGE:
- pre, post = "b.EncodeMessage(", ")"
- case descriptor.FieldDescriptorProto_TYPE_BYTES:
- pre, post = "b.EncodeRawBytes(", ")"
- case descriptor.FieldDescriptorProto_TYPE_SINT32:
- pre, post = "b.EncodeZigzag32(uint64(", "))"
- case descriptor.FieldDescriptorProto_TYPE_SINT64:
- pre, post = "b.EncodeZigzag64(uint64(", "))"
- default:
- g.Fail("unhandled oneof field type ", f.protoType.String())
- }
- g.P("b.EncodeVarint(", f.fieldNumber, "<<3|", g.Pkg["proto"], ".", wire, ")")
- if t := f.protoType; t != descriptor.FieldDescriptorProto_TYPE_GROUP && t != descriptor.FieldDescriptorProto_TYPE_MESSAGE {
- g.P(pre, val, post)
- } else {
- g.P("if err := ", pre, val, post, "; err != nil {")
- g.P("return err")
- g.P("}")
- }
- if f.protoType == descriptor.FieldDescriptorProto_TYPE_GROUP {
- g.P("b.EncodeVarint(", f.fieldNumber, "<<3|", g.Pkg["proto"], ".WireEndGroup)")
- }
-}
-
-// unmarshalCase prints the case matching this oneof subfield in the unmarshalling code.
-func (f *oneofSubField) unmarshalCase(g *Generator, origOneofName string, oneofName string) {
- g.P("case ", f.fieldNumber, ": // ", origOneofName, ".", f.getProtoName())
- g.P("if wire != ", g.Pkg["proto"], ".", f.wireTypeName(), " {")
- g.P("return true, ", g.Pkg["proto"], ".ErrInternalBadWireType")
- g.P("}")
- lhs := "x, err" // overridden for TYPE_MESSAGE and TYPE_GROUP
- var dec, cast, cast2 string
- switch f.protoType {
- case descriptor.FieldDescriptorProto_TYPE_DOUBLE:
- dec, cast = "b.DecodeFixed64()", g.Pkg["math"]+".Float64frombits"
- case descriptor.FieldDescriptorProto_TYPE_FLOAT:
- dec, cast, cast2 = "b.DecodeFixed32()", "uint32", g.Pkg["math"]+".Float32frombits"
- case descriptor.FieldDescriptorProto_TYPE_INT64:
- dec, cast = "b.DecodeVarint()", "int64"
- case descriptor.FieldDescriptorProto_TYPE_UINT64:
- dec = "b.DecodeVarint()"
- case descriptor.FieldDescriptorProto_TYPE_INT32:
- dec, cast = "b.DecodeVarint()", "int32"
- case descriptor.FieldDescriptorProto_TYPE_FIXED64:
- dec = "b.DecodeFixed64()"
- case descriptor.FieldDescriptorProto_TYPE_FIXED32:
- dec, cast = "b.DecodeFixed32()", "uint32"
- case descriptor.FieldDescriptorProto_TYPE_BOOL:
- dec = "b.DecodeVarint()"
- // handled specially below
- case descriptor.FieldDescriptorProto_TYPE_STRING:
- dec = "b.DecodeStringBytes()"
- case descriptor.FieldDescriptorProto_TYPE_GROUP:
- g.P("msg := new(", f.goType[1:], ")") // drop star
- lhs = "err"
- dec = "b.DecodeGroup(msg)"
- // handled specially below
- case descriptor.FieldDescriptorProto_TYPE_MESSAGE:
- g.P("msg := new(", f.goType[1:], ")") // drop star
- lhs = "err"
- dec = "b.DecodeMessage(msg)"
- // handled specially below
- case descriptor.FieldDescriptorProto_TYPE_BYTES:
- dec = "b.DecodeRawBytes(true)"
- case descriptor.FieldDescriptorProto_TYPE_UINT32:
- dec, cast = "b.DecodeVarint()", "uint32"
- case descriptor.FieldDescriptorProto_TYPE_ENUM:
- dec, cast = "b.DecodeVarint()", f.goType
- case descriptor.FieldDescriptorProto_TYPE_SFIXED32:
- dec, cast = "b.DecodeFixed32()", "int32"
- case descriptor.FieldDescriptorProto_TYPE_SFIXED64:
- dec, cast = "b.DecodeFixed64()", "int64"
- case descriptor.FieldDescriptorProto_TYPE_SINT32:
- dec, cast = "b.DecodeZigzag32()", "int32"
- case descriptor.FieldDescriptorProto_TYPE_SINT64:
- dec, cast = "b.DecodeZigzag64()", "int64"
- default:
- g.Fail("unhandled oneof field type ", f.protoType.String())
- }
- g.P(lhs, " := ", dec)
- val := "x"
- if cast != "" {
- val = cast + "(" + val + ")"
- }
- if cast2 != "" {
- val = cast2 + "(" + val + ")"
- }
- switch f.protoType {
- case descriptor.FieldDescriptorProto_TYPE_BOOL:
- val += " != 0"
- case descriptor.FieldDescriptorProto_TYPE_GROUP,
- descriptor.FieldDescriptorProto_TYPE_MESSAGE:
- val = "msg"
- }
- g.P("m.", oneofName, " = &", f.oneofTypeName, "{", val, "}")
- g.P("return true, err")
-}
-
-// sizerCase prints the case matching this oneof subfield in the sizer code.
-func (f *oneofSubField) sizerCase(g *Generator) {
- g.P("case *", f.oneofTypeName, ":")
- val := "x." + f.goName
- var varint, fixed string
- switch f.protoType {
- case descriptor.FieldDescriptorProto_TYPE_DOUBLE:
- fixed = "8"
- case descriptor.FieldDescriptorProto_TYPE_FLOAT:
- fixed = "4"
- case descriptor.FieldDescriptorProto_TYPE_INT64, descriptor.FieldDescriptorProto_TYPE_UINT64, descriptor.FieldDescriptorProto_TYPE_INT32, descriptor.FieldDescriptorProto_TYPE_UINT32, descriptor.FieldDescriptorProto_TYPE_ENUM:
- varint = val
- case descriptor.FieldDescriptorProto_TYPE_FIXED64, descriptor.FieldDescriptorProto_TYPE_SFIXED64:
- fixed = "8"
- case descriptor.FieldDescriptorProto_TYPE_FIXED32, descriptor.FieldDescriptorProto_TYPE_SFIXED32:
- fixed = "4"
- case descriptor.FieldDescriptorProto_TYPE_BOOL:
- fixed = "1"
- case descriptor.FieldDescriptorProto_TYPE_STRING:
- fixed = "len(" + val + ")"
- varint = fixed
- case descriptor.FieldDescriptorProto_TYPE_GROUP:
- fixed = g.Pkg["proto"] + ".Size(" + val + ")"
- case descriptor.FieldDescriptorProto_TYPE_MESSAGE:
- g.P("s := ", g.Pkg["proto"], ".Size(", val, ")")
- fixed = "s"
- varint = fixed
- case descriptor.FieldDescriptorProto_TYPE_BYTES:
- fixed = "len(" + val + ")"
- varint = fixed
- case descriptor.FieldDescriptorProto_TYPE_SINT32:
- varint = "(uint32(" + val + ") << 1) ^ uint32((int32(" + val + ") >> 31))"
- case descriptor.FieldDescriptorProto_TYPE_SINT64:
- varint = "uint64(" + val + " << 1) ^ uint64((int64(" + val + ") >> 63))"
- default:
- g.Fail("unhandled oneof field type ", f.protoType.String())
- }
- // Tag and wire varint is known statically,
- // so don't generate code for that part of the size computation.
- tagAndWireSize := proto.SizeVarint(uint64(f.fieldNumber << 3)) // wire doesn't affect varint size
- g.P("n += ", tagAndWireSize, " // tag and wire")
- if varint != "" {
- g.P("n += ", g.Pkg["proto"], ".SizeVarint(uint64(", varint, "))")
- }
- if fixed != "" {
- g.P("n += ", fixed)
- }
- if f.protoType == descriptor.FieldDescriptorProto_TYPE_GROUP {
- g.P("n += ", tagAndWireSize, " // tag and wire")
- }
-}
-
// getProtoDef returns the default value explicitly stated in the proto file, e.g "yoshi" or "5".
func (f *oneofSubField) getProtoDef() string {
return f.protoDef
@@ -2138,6 +1937,9 @@
g.P()
// Getters for each oneof
for _, sf := range f.subFields {
+ if sf.deprecated != "" {
+ g.P(sf.deprecated)
+ }
g.P("func (m *", mc.goName, ") ", Annotate(mc.message.file, sf.fullPath, sf.getterName), "() "+sf.goType+" {")
g.P("if x, ok := m.", f.getterName, "().(*", sf.oneofTypeName, "); ok {")
g.P("return x.", sf.goName)
@@ -2215,6 +2017,14 @@
def = "float32(" + def + ")"
}
kind = "var "
+ case df.getProtoType() == descriptor.FieldDescriptorProto_TYPE_FLOAT:
+ if f, err := strconv.ParseFloat(def, 32); err == nil {
+ def = fmt.Sprint(float32(f))
+ }
+ case df.getProtoType() == descriptor.FieldDescriptorProto_TYPE_DOUBLE:
+ if f, err := strconv.ParseFloat(def, 64); err == nil {
+ def = fmt.Sprint(f)
+ }
case df.getProtoType() == descriptor.FieldDescriptorProto_TYPE_ENUM:
// Must be an enum. Need to construct the prefixed name.
obj := g.ObjectNamed(df.getProtoTypeName())
@@ -2263,17 +2073,11 @@
if len(ofields) == 0 {
return
}
- enc := "_" + mc.goName + "_OneofMarshaler"
- dec := "_" + mc.goName + "_OneofUnmarshaler"
- size := "_" + mc.goName + "_OneofSizer"
- encSig := "(msg " + g.Pkg["proto"] + ".Message, b *" + g.Pkg["proto"] + ".Buffer) error"
- decSig := "(msg " + g.Pkg["proto"] + ".Message, tag, wire int, b *" + g.Pkg["proto"] + ".Buffer) (bool, error)"
- sizeSig := "(msg " + g.Pkg["proto"] + ".Message) (n int)"
// OneofFuncs
- g.P("// XXX_OneofFuncs is for the internal use of the proto package.")
- g.P("func (*", mc.goName, ") XXX_OneofFuncs() (func", encSig, ", func", decSig, ", func", sizeSig, ", []interface{}) {")
- g.P("return ", enc, ", ", dec, ", ", size, ", []interface{}{")
+ g.P("// XXX_OneofWrappers is for the internal use of the proto package.")
+ g.P("func (*", mc.goName, ") XXX_OneofWrappers() []interface{} {")
+ g.P("return []interface{}{")
for _, of := range ofields {
for _, sf := range of.subFields {
sf.typedNil(g)
@@ -2282,59 +2086,6 @@
g.P("}")
g.P("}")
g.P()
-
- // marshaler
- g.P("func ", enc, encSig, " {")
- g.P("m := msg.(*", mc.goName, ")")
- for _, of := range ofields {
- g.P("// ", of.getProtoName())
- g.P("switch x := m.", of.goName, ".(type) {")
- for _, sf := range of.subFields {
- // also fills in field.wire
- sf.marshalCase(g)
- }
- g.P("case nil:")
- g.P("default:")
- g.P(" return ", g.Pkg["fmt"], `.Errorf("`, mc.goName, ".", of.goName, ` has unexpected type %T", x)`)
- g.P("}")
- }
- g.P("return nil")
- g.P("}")
- g.P()
-
- // unmarshaler
- g.P("func ", dec, decSig, " {")
- g.P("m := msg.(*", mc.goName, ")")
- g.P("switch tag {")
- for _, of := range ofields {
- for _, sf := range of.subFields {
- sf.unmarshalCase(g, of.getProtoName(), of.goName)
- }
- }
- g.P("default:")
- g.P("return false, nil")
- g.P("}")
- g.P("}")
- g.P()
-
- // sizer
- g.P("func ", size, sizeSig, " {")
- g.P("m := msg.(*", mc.goName, ")")
- for _, of := range ofields {
- g.P("// ", of.getProtoName())
- g.P("switch x := m.", of.goName, ".(type) {")
- for _, sf := range of.subFields {
- // also fills in field.wire
- sf.sizerCase(g)
- }
- g.P("case nil:")
- g.P("default:")
- g.P("panic(", g.Pkg["fmt"], ".Sprintf(\"proto: unexpected type %T in oneof\", x))")
- g.P("}")
- }
- g.P("return n")
- g.P("}")
- g.P()
}
// generateMessageStruct adds the actual struct with it's members (but not methods) to the output.
@@ -2386,25 +2137,16 @@
g.P("func (*", mc.goName, ") Descriptor() ([]byte, []int) {")
g.P("return ", g.file.VarName(), ", []int{", strings.Join(indexes, ", "), "}")
g.P("}")
+ g.P()
// TODO: Revisit the decision to use a XXX_WellKnownType method
// if we change proto.MessageName to work with multiple equivalents.
if mc.message.file.GetPackage() == "google.protobuf" && wellKnownTypes[mc.message.GetName()] {
g.P("func (*", mc.goName, `) XXX_WellKnownType() string { return "`, mc.message.GetName(), `" }`)
+ g.P()
}
// Extension support methods
if len(mc.message.ExtensionRange) > 0 {
- // message_set_wire_format only makes sense when extensions are defined.
- if opts := mc.message.Options; opts != nil && opts.GetMessageSetWireFormat() {
- g.P()
- g.P("func (m *", mc.goName, ") MarshalJSON() ([]byte, error) {")
- g.P("return ", g.Pkg["proto"], ".MarshalMessageSetJSON(&m.XXX_InternalExtensions)")
- g.P("}")
- g.P("func (m *", mc.goName, ") UnmarshalJSON(buf []byte) error {")
- g.P("return ", g.Pkg["proto"], ".UnmarshalMessageSetJSON(buf, &m.XXX_InternalExtensions)")
- g.P("}")
- }
-
g.P()
g.P("var extRange_", mc.goName, " = []", g.Pkg["proto"], ".ExtensionRange{")
for _, r := range mc.message.ExtensionRange {
@@ -2415,6 +2157,7 @@
g.P("func (*", mc.goName, ") ExtensionRangeArray() []", g.Pkg["proto"], ".ExtensionRange {")
g.P("return extRange_", mc.goName)
g.P("}")
+ g.P()
}
// TODO: It does not scale to keep adding another method for every
@@ -2432,8 +2175,8 @@
g.P("return xxx_messageInfo_", mc.goName, ".Marshal(b, m, deterministic)")
g.P("}")
- g.P("func (dst *", mc.goName, ") XXX_Merge(src ", g.Pkg["proto"], ".Message) {")
- g.P("xxx_messageInfo_", mc.goName, ".Merge(dst, src)")
+ g.P("func (m *", mc.goName, ") XXX_Merge(src ", g.Pkg["proto"], ".Message) {")
+ g.P("xxx_messageInfo_", mc.goName, ".Merge(m, src)")
g.P("}")
g.P("func (m *", mc.goName, ") XXX_Size() int {") // avoid name clash with "Size" field in some message
@@ -2503,8 +2246,7 @@
if oneof && oFields[*field.OneofIndex] == nil {
odp := message.OneofDecl[int(*field.OneofIndex)]
base := CamelCase(odp.GetName())
- names := allocNames(base, "Get"+base)
- fname, gname := names[0], names[1]
+ fname := allocNames(base)[0]
// This is the first field of a oneof we haven't seen before.
// Generate the union field.
@@ -2522,7 +2264,7 @@
of := oneofField{
fieldCommon: fieldCommon{
goName: fname,
- getterName: gname,
+ getterName: "Get"+fname,
goType: dname,
tags: tag,
protoName: odp.GetName(),
@@ -2564,6 +2306,11 @@
}
}
+ fieldDeprecated := ""
+ if field.GetOptions().GetDeprecated() {
+ fieldDeprecated = deprecationComment
+ }
+
dvalue := g.getterDefault(field, goTypeName)
if oneof {
tname := goTypeName + "_" + fieldName
@@ -2607,17 +2354,13 @@
getterDef: dvalue,
protoDef: field.GetDefaultValue(),
oneofTypeName: tname,
+ deprecated: fieldDeprecated,
}
oneofField.subFields = append(oneofField.subFields, &sf)
g.RecordTypeUse(field.GetTypeName())
continue
}
- fieldDeprecated := ""
- if field.GetOptions().GetDeprecated() {
- fieldDeprecated = deprecationComment
- }
-
fieldFullPath := fmt.Sprintf("%s,%d,%d", message.path, messageFieldPath, i)
c, ok := g.makeComments(fieldFullPath)
if ok {
@@ -2663,27 +2406,24 @@
g.generateOneofFuncs(mc, topLevelFields)
g.P()
- if !message.group {
-
- var oneofTypes []string
- for _, f := range topLevelFields {
- if of, ok := f.(*oneofField); ok {
- for _, osf := range of.subFields {
- oneofTypes = append(oneofTypes, osf.oneofTypeName)
- }
+ var oneofTypes []string
+ for _, f := range topLevelFields {
+ if of, ok := f.(*oneofField); ok {
+ for _, osf := range of.subFields {
+ oneofTypes = append(oneofTypes, osf.oneofTypeName)
}
}
-
- opts := message.Options
- ms := &messageSymbol{
- sym: goTypeName,
- hasExtensions: len(message.ExtensionRange) > 0,
- isMessageSet: opts != nil && opts.GetMessageSetWireFormat(),
- oneofTypes: oneofTypes,
- }
- g.file.addExport(message, ms)
}
+ opts := message.Options
+ ms := &messageSymbol{
+ sym: goTypeName,
+ hasExtensions: len(message.ExtensionRange) > 0,
+ isMessageSet: opts != nil && opts.GetMessageSetWireFormat(),
+ oneofTypes: oneofTypes,
+ }
+ g.file.addExport(message, ms)
+
for _, ext := range message.ext {
g.generateExtension(ext)
}
@@ -2811,10 +2551,8 @@
// In addition, the situation for when to apply this special case is implemented
// differently in other languages:
// https://github.com/google/protobuf/blob/aff10976/src/google/protobuf/text_format.cc#L1560
- mset := false
if extDesc.GetOptions().GetMessageSetWireFormat() && typeName[len(typeName)-1] == "message_set_extension" {
typeName = typeName[:len(typeName)-1]
- mset = true
}
// For text formatting, the package must be exactly what the .proto file declares,
@@ -2835,26 +2573,12 @@
g.P("}")
g.P()
- if mset {
- // Generate a bit more code to register with message_set.go.
- g.addInitf("%s.RegisterMessageSetType((%s)(nil), %d, %q)", g.Pkg["proto"], fieldType, *field.Number, extName)
- }
+ g.addInitf("%s.RegisterExtension(%s)", g.Pkg["proto"], ext.DescName())
g.file.addExport(ext, constOrVarSymbol{ccTypeName, "var", ""})
}
func (g *Generator) generateInitFunction() {
- for _, enum := range g.file.enum {
- g.generateEnumRegistration(enum)
- }
- for _, d := range g.file.desc {
- for _, ext := range d.ext {
- g.generateExtensionRegistration(ext)
- }
- }
- for _, ext := range g.file.ext {
- g.generateExtensionRegistration(ext)
- }
if len(g.init) == 0 {
return
}
@@ -2918,10 +2642,6 @@
g.addInitf("%s.RegisterEnum(%q, %[3]s_name, %[3]s_value)", g.Pkg["proto"], pkg+ccTypeName, ccTypeName)
}
-func (g *Generator) generateExtensionRegistration(ext *ExtensionDescriptor) {
- g.addInitf("%s.RegisterExtension(%s)", g.Pkg["proto"], ext.DescName())
-}
-
// And now lots of helper functions.
// Is c an ASCII lower-case letter?
diff --git a/vendor/github.com/golang/protobuf/protoc-gen-go/grpc/grpc.go b/vendor/github.com/golang/protobuf/protoc-gen-go/grpc/grpc.go
index faef1ab..1ddfe83 100644
--- a/vendor/github.com/golang/protobuf/protoc-gen-go/grpc/grpc.go
+++ b/vendor/github.com/golang/protobuf/protoc-gen-go/grpc/grpc.go
@@ -36,7 +36,6 @@
import (
"fmt"
- "path"
"strconv"
"strings"
@@ -53,7 +52,7 @@
// Paths for packages used by code generated in this file,
// relative to the import_prefix of the generator.Generator.
const (
- contextPkgPath = "golang.org/x/net/context"
+ contextPkgPath = "context"
grpcPkgPath = "google.golang.org/grpc"
)
@@ -83,8 +82,6 @@
// Init initializes the plugin.
func (g *grpc) Init(gen *generator.Generator) {
g.gen = gen
- contextPkg = generator.RegisterUniquePackageName("context", nil)
- grpcPkg = generator.RegisterUniquePackageName("grpc", nil)
}
// Given a type name defined in a .proto, return its object.
@@ -108,6 +105,9 @@
return
}
+ contextPkg = string(g.gen.AddImport(contextPkgPath))
+ grpcPkg = string(g.gen.AddImport(grpcPkgPath))
+
g.P("// Reference imports to suppress errors if they are not otherwise used.")
g.P("var _ ", contextPkg, ".Context")
g.P("var _ ", grpcPkg, ".ClientConn")
@@ -126,14 +126,6 @@
// GenerateImports generates the import declaration for this file.
func (g *grpc) GenerateImports(file *generator.FileDescriptor) {
- if len(file.FileDescriptorProto.Service) == 0 {
- return
- }
- g.P("import (")
- g.P(contextPkg, " ", generator.GoImportPath(path.Join(string(g.gen.ImportPrefix), contextPkgPath)))
- g.P(grpcPkg, " ", generator.GoImportPath(path.Join(string(g.gen.ImportPrefix), grpcPkgPath)))
- g.P(")")
- g.P()
}
// reservedClientName records whether a client name is reserved on the client side.
diff --git a/vendor/github.com/golang/protobuf/ptypes/any/any.pb.go b/vendor/github.com/golang/protobuf/ptypes/any/any.pb.go
index e3c56d3..78ee523 100644
--- a/vendor/github.com/golang/protobuf/ptypes/any/any.pb.go
+++ b/vendor/github.com/golang/protobuf/ptypes/any/any.pb.go
@@ -1,11 +1,13 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/protobuf/any.proto
-package any // import "github.com/golang/protobuf/ptypes/any"
+package any
-import proto "github.com/golang/protobuf/proto"
-import fmt "fmt"
-import math "math"
+import (
+ fmt "fmt"
+ proto "github.com/golang/protobuf/proto"
+ math "math"
+)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@@ -16,7 +18,7 @@
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
-const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
+const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
// `Any` contains an arbitrary serialized protocol buffer message along with a
// URL that describes the type of the serialized message.
@@ -99,17 +101,18 @@
// }
//
type Any struct {
- // A URL/resource name whose content describes the type of the
- // serialized protocol buffer message.
+ // A URL/resource name that uniquely identifies the type of the serialized
+ // protocol buffer message. The last segment of the URL's path must represent
+ // the fully qualified name of the type (as in
+ // `path/google.protobuf.Duration`). The name should be in a canonical form
+ // (e.g., leading "." is not accepted).
//
- // For URLs which use the scheme `http`, `https`, or no scheme, the
- // following restrictions and interpretations apply:
+ // In practice, teams usually precompile into the binary all types that they
+ // expect it to use in the context of Any. However, for URLs which use the
+ // scheme `http`, `https`, or no scheme, one can optionally set up a type
+ // server that maps type URLs to message definitions as follows:
//
// * If no scheme is provided, `https` is assumed.
- // * The last segment of the URL's path must represent the fully
- // qualified name of the type (as in `path/google.protobuf.Duration`).
- // The name should be in a canonical form (e.g., leading "." is
- // not accepted).
// * An HTTP GET on the URL must yield a [google.protobuf.Type][]
// value in binary format, or produce an error.
// * Applications are allowed to cache lookup results based on the
@@ -118,6 +121,10 @@
// on changes to types. (Use versioned type names to manage
// breaking changes.)
//
+ // Note: this functionality is not currently available in the official
+ // protobuf release, and it is not used for type URLs beginning with
+ // type.googleapis.com.
+ //
// Schemes other than `http`, `https` (or the empty scheme) might be
// used with implementation specific semantics.
//
@@ -133,17 +140,19 @@
func (m *Any) String() string { return proto.CompactTextString(m) }
func (*Any) ProtoMessage() {}
func (*Any) Descriptor() ([]byte, []int) {
- return fileDescriptor_any_744b9ca530f228db, []int{0}
+ return fileDescriptor_b53526c13ae22eb4, []int{0}
}
+
func (*Any) XXX_WellKnownType() string { return "Any" }
+
func (m *Any) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Any.Unmarshal(m, b)
}
func (m *Any) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Any.Marshal(b, m, deterministic)
}
-func (dst *Any) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Any.Merge(dst, src)
+func (m *Any) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_Any.Merge(m, src)
}
func (m *Any) XXX_Size() int {
return xxx_messageInfo_Any.Size(m)
@@ -172,9 +181,9 @@
proto.RegisterType((*Any)(nil), "google.protobuf.Any")
}
-func init() { proto.RegisterFile("google/protobuf/any.proto", fileDescriptor_any_744b9ca530f228db) }
+func init() { proto.RegisterFile("google/protobuf/any.proto", fileDescriptor_b53526c13ae22eb4) }
-var fileDescriptor_any_744b9ca530f228db = []byte{
+var fileDescriptor_b53526c13ae22eb4 = []byte{
// 185 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x4c, 0xcf, 0xcf, 0x4f,
0xcf, 0x49, 0xd5, 0x2f, 0x28, 0xca, 0x2f, 0xc9, 0x4f, 0x2a, 0x4d, 0xd3, 0x4f, 0xcc, 0xab, 0xd4,
diff --git a/vendor/github.com/golang/protobuf/ptypes/any/any.proto b/vendor/github.com/golang/protobuf/ptypes/any/any.proto
index c748667..4932942 100644
--- a/vendor/github.com/golang/protobuf/ptypes/any/any.proto
+++ b/vendor/github.com/golang/protobuf/ptypes/any/any.proto
@@ -120,17 +120,18 @@
// }
//
message Any {
- // A URL/resource name whose content describes the type of the
- // serialized protocol buffer message.
+ // A URL/resource name that uniquely identifies the type of the serialized
+ // protocol buffer message. The last segment of the URL's path must represent
+ // the fully qualified name of the type (as in
+ // `path/google.protobuf.Duration`). The name should be in a canonical form
+ // (e.g., leading "." is not accepted).
//
- // For URLs which use the scheme `http`, `https`, or no scheme, the
- // following restrictions and interpretations apply:
+ // In practice, teams usually precompile into the binary all types that they
+ // expect it to use in the context of Any. However, for URLs which use the
+ // scheme `http`, `https`, or no scheme, one can optionally set up a type
+ // server that maps type URLs to message definitions as follows:
//
// * If no scheme is provided, `https` is assumed.
- // * The last segment of the URL's path must represent the fully
- // qualified name of the type (as in `path/google.protobuf.Duration`).
- // The name should be in a canonical form (e.g., leading "." is
- // not accepted).
// * An HTTP GET on the URL must yield a [google.protobuf.Type][]
// value in binary format, or produce an error.
// * Applications are allowed to cache lookup results based on the
@@ -139,6 +140,10 @@
// on changes to types. (Use versioned type names to manage
// breaking changes.)
//
+ // Note: this functionality is not currently available in the official
+ // protobuf release, and it is not used for type URLs beginning with
+ // type.googleapis.com.
+ //
// Schemes other than `http`, `https` (or the empty scheme) might be
// used with implementation specific semantics.
//
diff --git a/vendor/github.com/golang/protobuf/ptypes/duration.go b/vendor/github.com/golang/protobuf/ptypes/duration.go
index 65cb0f8..26d1ca2 100644
--- a/vendor/github.com/golang/protobuf/ptypes/duration.go
+++ b/vendor/github.com/golang/protobuf/ptypes/duration.go
@@ -82,7 +82,7 @@
return 0, fmt.Errorf("duration: %v is out of range for time.Duration", p)
}
if p.Nanos != 0 {
- d += time.Duration(p.Nanos)
+ d += time.Duration(p.Nanos) * time.Nanosecond
if (d < 0) != (p.Nanos < 0) {
return 0, fmt.Errorf("duration: %v is out of range for time.Duration", p)
}
diff --git a/vendor/github.com/golang/protobuf/ptypes/duration/duration.pb.go b/vendor/github.com/golang/protobuf/ptypes/duration/duration.pb.go
index a7beb2c..0d681ee 100644
--- a/vendor/github.com/golang/protobuf/ptypes/duration/duration.pb.go
+++ b/vendor/github.com/golang/protobuf/ptypes/duration/duration.pb.go
@@ -1,11 +1,13 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/protobuf/duration.proto
-package duration // import "github.com/golang/protobuf/ptypes/duration"
+package duration
-import proto "github.com/golang/protobuf/proto"
-import fmt "fmt"
-import math "math"
+import (
+ fmt "fmt"
+ proto "github.com/golang/protobuf/proto"
+ math "math"
+)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@@ -16,7 +18,7 @@
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
-const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
+const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
// A Duration represents a signed, fixed-length span of time represented
// as a count of seconds and fractions of seconds at nanosecond
@@ -99,17 +101,19 @@
func (m *Duration) String() string { return proto.CompactTextString(m) }
func (*Duration) ProtoMessage() {}
func (*Duration) Descriptor() ([]byte, []int) {
- return fileDescriptor_duration_e7d612259e3f0613, []int{0}
+ return fileDescriptor_23597b2ebd7ac6c5, []int{0}
}
+
func (*Duration) XXX_WellKnownType() string { return "Duration" }
+
func (m *Duration) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Duration.Unmarshal(m, b)
}
func (m *Duration) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Duration.Marshal(b, m, deterministic)
}
-func (dst *Duration) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Duration.Merge(dst, src)
+func (m *Duration) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_Duration.Merge(m, src)
}
func (m *Duration) XXX_Size() int {
return xxx_messageInfo_Duration.Size(m)
@@ -138,11 +142,9 @@
proto.RegisterType((*Duration)(nil), "google.protobuf.Duration")
}
-func init() {
- proto.RegisterFile("google/protobuf/duration.proto", fileDescriptor_duration_e7d612259e3f0613)
-}
+func init() { proto.RegisterFile("google/protobuf/duration.proto", fileDescriptor_23597b2ebd7ac6c5) }
-var fileDescriptor_duration_e7d612259e3f0613 = []byte{
+var fileDescriptor_23597b2ebd7ac6c5 = []byte{
// 190 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x4b, 0xcf, 0xcf, 0x4f,
0xcf, 0x49, 0xd5, 0x2f, 0x28, 0xca, 0x2f, 0xc9, 0x4f, 0x2a, 0x4d, 0xd3, 0x4f, 0x29, 0x2d, 0x4a,
diff --git a/vendor/github.com/golang/protobuf/ptypes/empty/empty.pb.go b/vendor/github.com/golang/protobuf/ptypes/empty/empty.pb.go
index a69b403..b4eb03e 100644
--- a/vendor/github.com/golang/protobuf/ptypes/empty/empty.pb.go
+++ b/vendor/github.com/golang/protobuf/ptypes/empty/empty.pb.go
@@ -1,11 +1,13 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/protobuf/empty.proto
-package empty // import "github.com/golang/protobuf/ptypes/empty"
+package empty
-import proto "github.com/golang/protobuf/proto"
-import fmt "fmt"
-import math "math"
+import (
+ fmt "fmt"
+ proto "github.com/golang/protobuf/proto"
+ math "math"
+)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@@ -16,7 +18,7 @@
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
-const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
+const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
// A generic empty message that you can re-use to avoid defining duplicated
// empty messages in your APIs. A typical example is to use it as the request
@@ -37,17 +39,19 @@
func (m *Empty) String() string { return proto.CompactTextString(m) }
func (*Empty) ProtoMessage() {}
func (*Empty) Descriptor() ([]byte, []int) {
- return fileDescriptor_empty_39e6d6db0632e5b2, []int{0}
+ return fileDescriptor_900544acb223d5b8, []int{0}
}
+
func (*Empty) XXX_WellKnownType() string { return "Empty" }
+
func (m *Empty) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Empty.Unmarshal(m, b)
}
func (m *Empty) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Empty.Marshal(b, m, deterministic)
}
-func (dst *Empty) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Empty.Merge(dst, src)
+func (m *Empty) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_Empty.Merge(m, src)
}
func (m *Empty) XXX_Size() int {
return xxx_messageInfo_Empty.Size(m)
@@ -62,9 +66,9 @@
proto.RegisterType((*Empty)(nil), "google.protobuf.Empty")
}
-func init() { proto.RegisterFile("google/protobuf/empty.proto", fileDescriptor_empty_39e6d6db0632e5b2) }
+func init() { proto.RegisterFile("google/protobuf/empty.proto", fileDescriptor_900544acb223d5b8) }
-var fileDescriptor_empty_39e6d6db0632e5b2 = []byte{
+var fileDescriptor_900544acb223d5b8 = []byte{
// 148 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x4e, 0xcf, 0xcf, 0x4f,
0xcf, 0x49, 0xd5, 0x2f, 0x28, 0xca, 0x2f, 0xc9, 0x4f, 0x2a, 0x4d, 0xd3, 0x4f, 0xcd, 0x2d, 0x28,
diff --git a/vendor/github.com/golang/protobuf/ptypes/timestamp.go b/vendor/github.com/golang/protobuf/ptypes/timestamp.go
index 47f10db..8da0df0 100644
--- a/vendor/github.com/golang/protobuf/ptypes/timestamp.go
+++ b/vendor/github.com/golang/protobuf/ptypes/timestamp.go
@@ -111,11 +111,9 @@
// TimestampProto converts the time.Time to a google.protobuf.Timestamp proto.
// It returns an error if the resulting Timestamp is invalid.
func TimestampProto(t time.Time) (*tspb.Timestamp, error) {
- seconds := t.Unix()
- nanos := int32(t.Sub(time.Unix(seconds, 0)))
ts := &tspb.Timestamp{
- Seconds: seconds,
- Nanos: nanos,
+ Seconds: t.Unix(),
+ Nanos: int32(t.Nanosecond()),
}
if err := validateTimestamp(ts); err != nil {
return nil, err
diff --git a/vendor/github.com/golang/protobuf/ptypes/timestamp/timestamp.pb.go b/vendor/github.com/golang/protobuf/ptypes/timestamp/timestamp.pb.go
index 8e76ae9..31cd846 100644
--- a/vendor/github.com/golang/protobuf/ptypes/timestamp/timestamp.pb.go
+++ b/vendor/github.com/golang/protobuf/ptypes/timestamp/timestamp.pb.go
@@ -1,11 +1,13 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/protobuf/timestamp.proto
-package timestamp // import "github.com/golang/protobuf/ptypes/timestamp"
+package timestamp
-import proto "github.com/golang/protobuf/proto"
-import fmt "fmt"
-import math "math"
+import (
+ fmt "fmt"
+ proto "github.com/golang/protobuf/proto"
+ math "math"
+)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
@@ -16,7 +18,7 @@
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
-const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
+const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
// A Timestamp represents a point in time independent of any time zone
// or calendar, represented as seconds and fractions of seconds at
@@ -81,7 +83,9 @@
// {hour}, {min}, and {sec} are zero-padded to two digits each. The fractional
// seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution),
// are optional. The "Z" suffix indicates the timezone ("UTC"); the timezone
-// is required, though only UTC (as indicated by "Z") is presently supported.
+// is required. A proto3 JSON serializer should always use UTC (as indicated by
+// "Z") when printing the Timestamp type and a proto3 JSON parser should be
+// able to accept both UTC and other timezones (as indicated by an offset).
//
// For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past
// 01:30 UTC on January 15, 2017.
@@ -92,8 +96,8 @@
// to this format using [`strftime`](https://docs.python.org/2/library/time.html#time.strftime)
// with the time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one
// can use the Joda Time's [`ISODateTimeFormat.dateTime()`](
-// http://www.joda.org/joda-time/apidocs/org/joda/time/format/ISODateTimeFormat.html#dateTime--)
-// to obtain a formatter capable of generating timestamps in this format.
+// http://www.joda.org/joda-time/apidocs/org/joda/time/format/ISODateTimeFormat.html#dateTime--
+// ) to obtain a formatter capable of generating timestamps in this format.
//
//
type Timestamp struct {
@@ -115,17 +119,19 @@
func (m *Timestamp) String() string { return proto.CompactTextString(m) }
func (*Timestamp) ProtoMessage() {}
func (*Timestamp) Descriptor() ([]byte, []int) {
- return fileDescriptor_timestamp_b826e8e5fba671a8, []int{0}
+ return fileDescriptor_292007bbfe81227e, []int{0}
}
+
func (*Timestamp) XXX_WellKnownType() string { return "Timestamp" }
+
func (m *Timestamp) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Timestamp.Unmarshal(m, b)
}
func (m *Timestamp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Timestamp.Marshal(b, m, deterministic)
}
-func (dst *Timestamp) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Timestamp.Merge(dst, src)
+func (m *Timestamp) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_Timestamp.Merge(m, src)
}
func (m *Timestamp) XXX_Size() int {
return xxx_messageInfo_Timestamp.Size(m)
@@ -154,11 +160,9 @@
proto.RegisterType((*Timestamp)(nil), "google.protobuf.Timestamp")
}
-func init() {
- proto.RegisterFile("google/protobuf/timestamp.proto", fileDescriptor_timestamp_b826e8e5fba671a8)
-}
+func init() { proto.RegisterFile("google/protobuf/timestamp.proto", fileDescriptor_292007bbfe81227e) }
-var fileDescriptor_timestamp_b826e8e5fba671a8 = []byte{
+var fileDescriptor_292007bbfe81227e = []byte{
// 191 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x4f, 0xcf, 0xcf, 0x4f,
0xcf, 0x49, 0xd5, 0x2f, 0x28, 0xca, 0x2f, 0xc9, 0x4f, 0x2a, 0x4d, 0xd3, 0x2f, 0xc9, 0xcc, 0x4d,
diff --git a/vendor/github.com/golang/protobuf/ptypes/timestamp/timestamp.proto b/vendor/github.com/golang/protobuf/ptypes/timestamp/timestamp.proto
index 06750ab..eafb3fa 100644
--- a/vendor/github.com/golang/protobuf/ptypes/timestamp/timestamp.proto
+++ b/vendor/github.com/golang/protobuf/ptypes/timestamp/timestamp.proto
@@ -103,7 +103,9 @@
// {hour}, {min}, and {sec} are zero-padded to two digits each. The fractional
// seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution),
// are optional. The "Z" suffix indicates the timezone ("UTC"); the timezone
-// is required, though only UTC (as indicated by "Z") is presently supported.
+// is required. A proto3 JSON serializer should always use UTC (as indicated by
+// "Z") when printing the Timestamp type and a proto3 JSON parser should be
+// able to accept both UTC and other timezones (as indicated by an offset).
//
// For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past
// 01:30 UTC on January 15, 2017.
@@ -114,8 +116,8 @@
// to this format using [`strftime`](https://docs.python.org/2/library/time.html#time.strftime)
// with the time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one
// can use the Joda Time's [`ISODateTimeFormat.dateTime()`](
-// http://www.joda.org/joda-time/apidocs/org/joda/time/format/ISODateTimeFormat.html#dateTime--)
-// to obtain a formatter capable of generating timestamps in this format.
+// http://www.joda.org/joda-time/apidocs/org/joda/time/format/ISODateTimeFormat.html#dateTime--
+// ) to obtain a formatter capable of generating timestamps in this format.
//
//
message Timestamp {
diff --git a/vendor/github.com/google/uuid/node.go b/vendor/github.com/google/uuid/node.go
index 3e4e90d..d651a2b 100644
--- a/vendor/github.com/google/uuid/node.go
+++ b/vendor/github.com/google/uuid/node.go
@@ -48,6 +48,7 @@
// does not specify a specific interface generate a random Node ID
// (section 4.1.6)
if name == "" {
+ ifname = "random"
randomBits(nodeID[:])
return true
}
diff --git a/vendor/github.com/hashicorp/consul/api/agent.go b/vendor/github.com/hashicorp/consul/api/agent.go
index 6a3fb27..6acf8ad 100644
--- a/vendor/github.com/hashicorp/consul/api/agent.go
+++ b/vendor/github.com/hashicorp/consul/api/agent.go
@@ -926,41 +926,86 @@
// UpdateACLToken updates the agent's "acl_token". See updateToken for more
// details.
+//
+// DEPRECATED (ACL-Legacy-Compat) - Prefer UpdateDefaultACLToken for v1.4.3 and above
func (a *Agent) UpdateACLToken(token string, q *WriteOptions) (*WriteMeta, error) {
return a.updateToken("acl_token", token, q)
}
// UpdateACLAgentToken updates the agent's "acl_agent_token". See updateToken
// for more details.
+//
+// DEPRECATED (ACL-Legacy-Compat) - Prefer UpdateAgentACLToken for v1.4.3 and above
func (a *Agent) UpdateACLAgentToken(token string, q *WriteOptions) (*WriteMeta, error) {
return a.updateToken("acl_agent_token", token, q)
}
// UpdateACLAgentMasterToken updates the agent's "acl_agent_master_token". See
// updateToken for more details.
+//
+// DEPRECATED (ACL-Legacy-Compat) - Prefer UpdateAgentMasterACLToken for v1.4.3 and above
func (a *Agent) UpdateACLAgentMasterToken(token string, q *WriteOptions) (*WriteMeta, error) {
return a.updateToken("acl_agent_master_token", token, q)
}
// UpdateACLReplicationToken updates the agent's "acl_replication_token". See
// updateToken for more details.
+//
+// DEPRECATED (ACL-Legacy-Compat) - Prefer UpdateReplicationACLToken for v1.4.3 and above
func (a *Agent) UpdateACLReplicationToken(token string, q *WriteOptions) (*WriteMeta, error) {
return a.updateToken("acl_replication_token", token, q)
}
-// updateToken can be used to update an agent's ACL token after the agent has
-// started. The tokens are not persisted, so will need to be updated again if
-// the agent is restarted.
+// UpdateDefaultACLToken updates the agent's "default" token. See updateToken
+// for more details
+func (a *Agent) UpdateDefaultACLToken(token string, q *WriteOptions) (*WriteMeta, error) {
+ return a.updateTokenFallback("default", "acl_token", token, q)
+}
+
+// UpdateAgentACLToken updates the agent's "agent" token. See updateToken
+// for more details
+func (a *Agent) UpdateAgentACLToken(token string, q *WriteOptions) (*WriteMeta, error) {
+ return a.updateTokenFallback("agent", "acl_agent_token", token, q)
+}
+
+// UpdateAgentMasterACLToken updates the agent's "agent_master" token. See updateToken
+// for more details
+func (a *Agent) UpdateAgentMasterACLToken(token string, q *WriteOptions) (*WriteMeta, error) {
+ return a.updateTokenFallback("agent_master", "acl_agent_master_token", token, q)
+}
+
+// UpdateReplicationACLToken updates the agent's "replication" token. See updateToken
+// for more details
+func (a *Agent) UpdateReplicationACLToken(token string, q *WriteOptions) (*WriteMeta, error) {
+ return a.updateTokenFallback("replication", "acl_replication_token", token, q)
+}
+
+// updateToken can be used to update one of an agent's ACL tokens after the agent has
+// started. The tokens are may not be persisted, so will need to be updated again if
+// the agent is restarted unless the agent is configured to persist them.
func (a *Agent) updateToken(target, token string, q *WriteOptions) (*WriteMeta, error) {
+ meta, _, err := a.updateTokenOnce(target, token, q)
+ return meta, err
+}
+
+func (a *Agent) updateTokenFallback(target, fallback, token string, q *WriteOptions) (*WriteMeta, error) {
+ meta, status, err := a.updateTokenOnce(target, token, q)
+ if err != nil && status == 404 {
+ meta, _, err = a.updateTokenOnce(fallback, token, q)
+ }
+ return meta, err
+}
+
+func (a *Agent) updateTokenOnce(target, token string, q *WriteOptions) (*WriteMeta, int, error) {
r := a.c.newRequest("PUT", fmt.Sprintf("/v1/agent/token/%s", target))
r.setWriteOptions(q)
r.obj = &AgentToken{Token: token}
rtt, resp, err := requireOK(a.c.doRequest(r))
if err != nil {
- return nil, err
+ return nil, resp.StatusCode, err
}
resp.Body.Close()
wm := &WriteMeta{RequestTime: rtt}
- return wm, nil
+ return wm, resp.StatusCode, nil
}
diff --git a/vendor/github.com/hashicorp/consul/api/api.go b/vendor/github.com/hashicorp/consul/api/api.go
index b913fa3..39a0ad3 100644
--- a/vendor/github.com/hashicorp/consul/api/api.go
+++ b/vendor/github.com/hashicorp/consul/api/api.go
@@ -93,7 +93,7 @@
// If there is a cached response that is older than the MaxAge, it is treated
// as a cache miss and a new fetch invoked. If the fetch fails, the error is
// returned. Clients that wish to allow for stale results on error can set
- // StaleIfError to a longer duration to change this behaviour. It is ignored
+ // StaleIfError to a longer duration to change this behavior. It is ignored
// if the endpoint supports background refresh caching. See
// https://www.consul.io/api/index.html#agent-caching for more details.
MaxAge time.Duration
diff --git a/vendor/github.com/hashicorp/consul/api/prepared_query.go b/vendor/github.com/hashicorp/consul/api/prepared_query.go
index 8bb1004..0204581 100644
--- a/vendor/github.com/hashicorp/consul/api/prepared_query.go
+++ b/vendor/github.com/hashicorp/consul/api/prepared_query.go
@@ -55,6 +55,11 @@
// service entry to be returned.
NodeMeta map[string]string
+ // ServiceMeta is a map of required service metadata fields. If a key/value
+ // pair is in this map it must be present on the node in order for the
+ // service entry to be returned.
+ ServiceMeta map[string]string
+
// Connect if true will filter the prepared query results to only
// include Connect-capable services. These include both native services
// and proxies for matching services. Note that if a proxy matches,
diff --git a/vendor/github.com/hashicorp/go-cleanhttp/handlers.go b/vendor/github.com/hashicorp/go-cleanhttp/handlers.go
index 7eda377..3c845dc 100644
--- a/vendor/github.com/hashicorp/go-cleanhttp/handlers.go
+++ b/vendor/github.com/hashicorp/go-cleanhttp/handlers.go
@@ -27,17 +27,22 @@
}
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
- // Check URL path for non-printable characters
- idx := strings.IndexFunc(r.URL.Path, func(c rune) bool {
- return !unicode.IsPrint(c)
- })
+ if r != nil {
+ // Check URL path for non-printable characters
+ idx := strings.IndexFunc(r.URL.Path, func(c rune) bool {
+ return !unicode.IsPrint(c)
+ })
- if idx != -1 {
- w.WriteHeader(input.ErrStatus)
- return
+ if idx != -1 {
+ w.WriteHeader(input.ErrStatus)
+ return
+ }
+
+ if next != nil {
+ next.ServeHTTP(w, r)
+ }
}
- next.ServeHTTP(w, r)
return
})
}
diff --git a/vendor/github.com/json-iterator/go/README.md b/vendor/github.com/json-iterator/go/README.md
index 54d5afe..50d56ff 100644
--- a/vendor/github.com/json-iterator/go/README.md
+++ b/vendor/github.com/json-iterator/go/README.md
@@ -10,10 +10,6 @@
You can also use thrift like JSON using [thrift-iterator](https://github.com/thrift-iterator/go)
-```
-Go开发者们请加入我们,滴滴出行平台技术部 taowen@didichuxing.com
-```
-
# Benchmark
![benchmark](http://jsoniter.com/benchmarks/go-benchmark.png)
diff --git a/vendor/github.com/json-iterator/go/any.go b/vendor/github.com/json-iterator/go/any.go
index daecfed..f6b8aea 100644
--- a/vendor/github.com/json-iterator/go/any.go
+++ b/vendor/github.com/json-iterator/go/any.go
@@ -312,6 +312,10 @@
func (codec *directAnyCodec) Encode(ptr unsafe.Pointer, stream *Stream) {
any := *(*Any)(ptr)
+ if any == nil {
+ stream.WriteNil()
+ return
+ }
any.WriteTo(stream)
}
diff --git a/vendor/github.com/json-iterator/go/iter_float.go b/vendor/github.com/json-iterator/go/iter_float.go
index 4f883c0..b975463 100644
--- a/vendor/github.com/json-iterator/go/iter_float.go
+++ b/vendor/github.com/json-iterator/go/iter_float.go
@@ -77,14 +77,12 @@
}
func (iter *Iterator) readPositiveFloat32() (ret float32) {
- value := uint64(0)
- c := byte(' ')
i := iter.head
// first char
if i == iter.tail {
return iter.readFloat32SlowPath()
}
- c = iter.buf[i]
+ c := iter.buf[i]
i++
ind := floatDigits[c]
switch ind {
@@ -107,7 +105,7 @@
return
}
}
- value = uint64(ind)
+ value := uint64(ind)
// chars before dot
non_decimal_loop:
for ; i < iter.tail; i++ {
@@ -145,9 +143,7 @@
}
// too many decimal places
return iter.readFloat32SlowPath()
- case invalidCharForNumber:
- fallthrough
- case dotInNumber:
+ case invalidCharForNumber, dotInNumber:
return iter.readFloat32SlowPath()
}
decimalPlaces++
@@ -218,14 +214,12 @@
}
func (iter *Iterator) readPositiveFloat64() (ret float64) {
- value := uint64(0)
- c := byte(' ')
i := iter.head
// first char
if i == iter.tail {
return iter.readFloat64SlowPath()
}
- c = iter.buf[i]
+ c := iter.buf[i]
i++
ind := floatDigits[c]
switch ind {
@@ -248,7 +242,7 @@
return
}
}
- value = uint64(ind)
+ value := uint64(ind)
// chars before dot
non_decimal_loop:
for ; i < iter.tail; i++ {
@@ -286,9 +280,7 @@
}
// too many decimal places
return iter.readFloat64SlowPath()
- case invalidCharForNumber:
- fallthrough
- case dotInNumber:
+ case invalidCharForNumber, dotInNumber:
return iter.readFloat64SlowPath()
}
decimalPlaces++
diff --git a/vendor/github.com/json-iterator/go/iter_skip_strict.go b/vendor/github.com/json-iterator/go/iter_skip_strict.go
index f67bc2e..6cf66d0 100644
--- a/vendor/github.com/json-iterator/go/iter_skip_strict.go
+++ b/vendor/github.com/json-iterator/go/iter_skip_strict.go
@@ -2,12 +2,22 @@
package jsoniter
-import "fmt"
+import (
+ "fmt"
+ "io"
+)
func (iter *Iterator) skipNumber() {
if !iter.trySkipNumber() {
iter.unreadByte()
- iter.ReadFloat32()
+ if iter.Error != nil && iter.Error != io.EOF {
+ return
+ }
+ iter.ReadFloat64()
+ if iter.Error != nil && iter.Error != io.EOF {
+ iter.Error = nil
+ iter.ReadBigFloat()
+ }
}
}
diff --git a/vendor/github.com/json-iterator/go/reflect_extension.go b/vendor/github.com/json-iterator/go/reflect_extension.go
index 04f6875..05e8fbf 100644
--- a/vendor/github.com/json-iterator/go/reflect_extension.go
+++ b/vendor/github.com/json-iterator/go/reflect_extension.go
@@ -338,7 +338,7 @@
for i := 0; i < structType.NumField(); i++ {
field := structType.Field(i)
tag, hastag := field.Tag().Lookup(ctx.getTagKey())
- if ctx.onlyTaggedField && !hastag {
+ if ctx.onlyTaggedField && !hastag && !field.Anonymous() {
continue
}
tagParts := strings.Split(tag, ",")
diff --git a/vendor/github.com/json-iterator/go/reflect_map.go b/vendor/github.com/json-iterator/go/reflect_map.go
index 7f66a88..547b442 100644
--- a/vendor/github.com/json-iterator/go/reflect_map.go
+++ b/vendor/github.com/json-iterator/go/reflect_map.go
@@ -64,14 +64,26 @@
return &numericMapKeyDecoder{decoderOfType(ctx, typ)}
default:
ptrType := reflect2.PtrTo(typ)
- if ptrType.Implements(textMarshalerType) {
+ if ptrType.Implements(unmarshalerType) {
+ return &referenceDecoder{
+ &unmarshalerDecoder{
+ valType: ptrType,
+ },
+ }
+ }
+ if typ.Implements(unmarshalerType) {
+ return &unmarshalerDecoder{
+ valType: typ,
+ }
+ }
+ if ptrType.Implements(textUnmarshalerType) {
return &referenceDecoder{
&textUnmarshalerDecoder{
valType: ptrType,
},
}
}
- if typ.Implements(textMarshalerType) {
+ if typ.Implements(textUnmarshalerType) {
return &textUnmarshalerDecoder{
valType: typ,
}
diff --git a/vendor/github.com/json-iterator/go/reflect_marshaler.go b/vendor/github.com/json-iterator/go/reflect_marshaler.go
index 58ac959..fea5071 100644
--- a/vendor/github.com/json-iterator/go/reflect_marshaler.go
+++ b/vendor/github.com/json-iterator/go/reflect_marshaler.go
@@ -93,8 +93,7 @@
stream.WriteNil()
return
}
- marshaler := obj.(json.Marshaler)
- bytes, err := marshaler.MarshalJSON()
+ bytes, err := json.Marshal(obj)
if err != nil {
stream.Error = err
} else {
diff --git a/vendor/github.com/pierrec/lz4/.travis.yml b/vendor/github.com/pierrec/lz4/.travis.yml
index 204afe1..658910d 100644
--- a/vendor/github.com/pierrec/lz4/.travis.yml
+++ b/vendor/github.com/pierrec/lz4/.travis.yml
@@ -20,3 +20,5 @@
script:
- go test -v -cpu=2
- go test -v -cpu=2 -race
+ - go test -v -cpu=2 -tags noasm
+ - go test -v -cpu=2 -race -tags noasm
diff --git a/vendor/github.com/pierrec/lz4/block.go b/vendor/github.com/pierrec/lz4/block.go
index 07863ce..d96e0e7 100644
--- a/vendor/github.com/pierrec/lz4/block.go
+++ b/vendor/github.com/pierrec/lz4/block.go
@@ -30,75 +30,17 @@
// The destination buffer must be sized appropriately.
//
// An error is returned if the source data is invalid or the destination buffer is too small.
-func UncompressBlock(src, dst []byte) (si int, err error) {
- defer func() {
- // It is now faster to let the runtime panic and recover on out of bound slice access
- // than checking indices as we go along.
- if recover() != nil {
- err = ErrInvalidSourceShortBuffer
- }
- }()
+func UncompressBlock(src, dst []byte) (di int, err error) {
sn := len(src)
if sn == 0 {
return 0, nil
}
- var di int
- for {
- // Literals and match lengths (token).
- b := int(src[si])
- si++
-
- // Literals.
- if lLen := b >> 4; lLen > 0 {
- if lLen == 0xF {
- for src[si] == 0xFF {
- lLen += 0xFF
- si++
- }
- lLen += int(src[si])
- si++
- }
- i := si
- si += lLen
- di += copy(dst[di:di+si-i], src[i:si])
-
- if si >= sn {
- return di, nil
- }
- }
-
- si++
- _ = src[si] // Bound check elimination.
- offset := int(src[si-1]) | int(src[si])<<8
- si++
-
- // Match.
- mLen := b & 0xF
- if mLen == 0xF {
- for src[si] == 0xFF {
- mLen += 0xFF
- si++
- }
- mLen += int(src[si])
- si++
- }
- mLen += minMatch
-
- // Copy the match.
- i := di - offset
- if offset > 0 && mLen >= offset {
- // Efficiently copy the match dst[di-offset:di] into the dst slice.
- bytesToCopy := offset * (mLen / offset)
- expanded := dst[i:]
- for n := offset; n <= bytesToCopy+offset; n *= 2 {
- copy(expanded[n:], expanded[:n])
- }
- di += bytesToCopy
- mLen -= bytesToCopy
- }
- di += copy(dst[di:di+mLen], dst[i:i+mLen])
+ di = decodeBlock(dst, src)
+ if di < 0 {
+ return 0, ErrInvalidSourceShortBuffer
}
+ return di, nil
}
// CompressBlock compresses the source buffer into the destination one.
diff --git a/vendor/go.etcd.io/etcd/clientv3/README.md b/vendor/go.etcd.io/etcd/clientv3/README.md
index a249b73..0b2dc9a 100644
--- a/vendor/go.etcd.io/etcd/clientv3/README.md
+++ b/vendor/go.etcd.io/etcd/clientv3/README.md
@@ -28,7 +28,7 @@
defer cli.Close()
```
-etcd v3 uses [`gRPC`](http://www.grpc.io) for remote procedure calls. And `clientv3` uses
+etcd v3 uses [`gRPC`](https://www.grpc.io) for remote procedure calls. And `clientv3` uses
[`grpc-go`](https://github.com/grpc/grpc-go) to connect to etcd. Make sure to close the client after using it.
If the client is not closed, the connection will have leaky goroutines. To specify client request timeout,
pass `context.WithTimeout` to APIs:
diff --git a/vendor/go.etcd.io/etcd/clientv3/balancer/balancer.go b/vendor/go.etcd.io/etcd/clientv3/balancer/balancer.go
index 25dc2b7..3c44e70 100644
--- a/vendor/go.etcd.io/etcd/clientv3/balancer/balancer.go
+++ b/vendor/go.etcd.io/etcd/clientv3/balancer/balancer.go
@@ -36,7 +36,7 @@
bb := &builder{cfg}
balancer.Register(bb)
- bb.cfg.Logger.Info(
+ bb.cfg.Logger.Debug(
"registered balancer",
zap.String("policy", bb.cfg.Policy.String()),
zap.String("name", bb.cfg.Name),
diff --git a/vendor/go.etcd.io/etcd/clientv3/balancer/grpc1.7-health.go b/vendor/go.etcd.io/etcd/clientv3/balancer/grpc1.7-health.go
index 7d24b93..2153767 100644
--- a/vendor/go.etcd.io/etcd/clientv3/balancer/grpc1.7-health.go
+++ b/vendor/go.etcd.io/etcd/clientv3/balancer/grpc1.7-health.go
@@ -38,10 +38,10 @@
unknownService = "unknown service grpc.health.v1.Health"
)
-// ErrNoAddrAvilable is returned by Get() when the balancer does not have
+// ErrNoAddrAvailable is returned by Get() when the balancer does not have
// any active connection to endpoints at the time.
// This error is returned only when opts.BlockingWait is true.
-var ErrNoAddrAvilable = status.Error(codes.Unavailable, "there is no address available")
+var ErrNoAddrAvailable = status.Error(codes.Unavailable, "there is no address available")
type NotifyMsg int
@@ -510,7 +510,7 @@
return grpc.Address{Addr: ""}, nil, grpc.ErrClientConnClosing
}
if addr == "" {
- return grpc.Address{Addr: ""}, nil, ErrNoAddrAvilable
+ return grpc.Address{Addr: ""}, nil, ErrNoAddrAvailable
}
return grpc.Address{Addr: addr}, func() {}, nil
}
diff --git a/vendor/go.etcd.io/etcd/clientv3/client.go b/vendor/go.etcd.io/etcd/clientv3/client.go
index 276b0f0..445ecfe 100644
--- a/vendor/go.etcd.io/etcd/clientv3/client.go
+++ b/vendor/go.etcd.io/etcd/clientv3/client.go
@@ -20,7 +20,6 @@
"errors"
"fmt"
"net"
- "net/url"
"os"
"strconv"
"strings"
@@ -32,6 +31,7 @@
"go.etcd.io/etcd/clientv3/balancer/picker"
"go.etcd.io/etcd/clientv3/balancer/resolver/endpoint"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
+ "go.etcd.io/etcd/pkg/logutil"
"go.uber.org/zap"
"google.golang.org/grpc"
"google.golang.org/grpc/codes"
@@ -446,7 +446,7 @@
callOpts: defaultCallOpts,
}
- lcfg := DefaultLogConfig
+ lcfg := logutil.DefaultZapLoggerConfig
if cfg.LogConfig != nil {
lcfg = *cfg.LogConfig
}
@@ -530,10 +530,10 @@
n := uint(len(c.Endpoints()))
quorum := (n/2 + 1)
if attempt%quorum == 0 {
- c.lg.Info("backoff", zap.Uint("attempt", attempt), zap.Uint("quorum", quorum), zap.Duration("waitBetween", waitBetween), zap.Float64("jitterFraction", jitterFraction))
+ c.lg.Debug("backoff", zap.Uint("attempt", attempt), zap.Uint("quorum", quorum), zap.Duration("waitBetween", waitBetween), zap.Float64("jitterFraction", jitterFraction))
return jitterUp(waitBetween, jitterFraction)
}
- c.lg.Info("backoff skipped", zap.Uint("attempt", attempt), zap.Uint("quorum", quorum))
+ c.lg.Debug("backoff skipped", zap.Uint("attempt", attempt), zap.Uint("quorum", quorum))
return 0
}
}
@@ -666,11 +666,3 @@
// <= gRPC v1.7.x returns 'errors.New("grpc: the client connection is closing")'
return strings.Contains(err.Error(), "grpc: the client connection is closing")
}
-
-func getHost(ep string) string {
- url, uerr := url.Parse(ep)
- if uerr != nil || !strings.Contains(ep, "://") {
- return ep
- }
- return url.Host
-}
diff --git a/vendor/go.etcd.io/etcd/clientv3/config.go b/vendor/go.etcd.io/etcd/clientv3/config.go
index 96e94e1..bd03768 100644
--- a/vendor/go.etcd.io/etcd/clientv3/config.go
+++ b/vendor/go.etcd.io/etcd/clientv3/config.go
@@ -82,21 +82,3 @@
// PermitWithoutStream when set will allow client to send keepalive pings to server without any active streams(RPCs).
PermitWithoutStream bool `json:"permit-without-stream"`
}
-
-// DefaultLogConfig is the default client logging configuration.
-// Default log level is "Warn". Use "zap.InfoLevel" for debugging.
-// Use "/dev/null" for output paths, to discard all logs.
-var DefaultLogConfig = zap.Config{
- Level: zap.NewAtomicLevelAt(zap.WarnLevel),
- Development: false,
- Sampling: &zap.SamplingConfig{
- Initial: 100,
- Thereafter: 100,
- },
- Encoding: "json",
- EncoderConfig: zap.NewProductionEncoderConfig(),
-
- // Use "/dev/null" to discard all
- OutputPaths: []string{"stderr"},
- ErrorOutputPaths: []string{"stderr"},
-}
diff --git a/vendor/go.etcd.io/etcd/clientv3/op.go b/vendor/go.etcd.io/etcd/clientv3/op.go
index 13507c9..085dd28 100644
--- a/vendor/go.etcd.io/etcd/clientv3/op.go
+++ b/vendor/go.etcd.io/etcd/clientv3/op.go
@@ -218,6 +218,10 @@
// OpGet returns "get" operation based on given key and operation options.
func OpGet(key string, opts ...OpOption) Op {
+ // WithPrefix and WithFromKey are not supported together
+ if isWithPrefix(opts) && isWithFromKey(opts) {
+ panic("`WithPrefix` and `WithFromKey` cannot be set at the same time, choose one")
+ }
ret := Op{t: tRange, key: []byte(key)}
ret.applyOpts(opts)
return ret
@@ -225,6 +229,10 @@
// OpDelete returns "delete" operation based on given key and operation options.
func OpDelete(key string, opts ...OpOption) Op {
+ // WithPrefix and WithFromKey are not supported together
+ if isWithPrefix(opts) && isWithFromKey(opts) {
+ panic("`WithPrefix` and `WithFromKey` cannot be set at the same time, choose one")
+ }
ret := Op{t: tDeleteRange, key: []byte(key)}
ret.applyOpts(opts)
switch {
@@ -544,3 +552,9 @@
ret.applyOpts(opts)
return &pb.LeaseTimeToLiveRequest{ID: int64(id), Keys: ret.attachedKeys}
}
+
+// isWithPrefix returns true if WithPrefix is being called in the op
+func isWithPrefix(opts []OpOption) bool { return isOpFuncCalled("WithPrefix", opts) }
+
+// isWithFromKey returns true if WithFromKey is being called in the op
+func isWithFromKey(opts []OpOption) bool { return isOpFuncCalled("WithFromKey", opts) }
diff --git a/vendor/go.etcd.io/etcd/clientv3/retry_interceptor.go b/vendor/go.etcd.io/etcd/clientv3/retry_interceptor.go
index 6b1054e..e48a003 100644
--- a/vendor/go.etcd.io/etcd/clientv3/retry_interceptor.go
+++ b/vendor/go.etcd.io/etcd/clientv3/retry_interceptor.go
@@ -48,7 +48,7 @@
if err := waitRetryBackoff(ctx, attempt, callOpts); err != nil {
return err
}
- logger.Info(
+ logger.Debug(
"retrying of unary invoker",
zap.String("target", cc.Target()),
zap.Uint("attempt", attempt),
@@ -112,7 +112,7 @@
return nil, grpc.Errorf(codes.Unimplemented, "clientv3/retry_interceptor: cannot retry on ClientStreams, set Disable()")
}
newStreamer, err := streamer(ctx, desc, cc, method, grpcOpts...)
- logger.Info("retry stream intercept", zap.Error(err))
+ logger.Warn("retry stream intercept", zap.Error(err))
if err != nil {
// TODO(mwitkow): Maybe dial and transport errors should be retriable?
return nil, err
@@ -228,7 +228,7 @@
if s.callOpts.retryAuth && rpctypes.Error(err) == rpctypes.ErrInvalidAuthToken {
gterr := s.client.getToken(s.ctx)
if gterr != nil {
- s.client.lg.Info("retry failed to fetch new auth token", zap.Error(gterr))
+ s.client.lg.Warn("retry failed to fetch new auth token", zap.Error(gterr))
return false, err // return the original error for simplicity
}
return true, err
diff --git a/vendor/go.etcd.io/etcd/clientv3/utils.go b/vendor/go.etcd.io/etcd/clientv3/utils.go
index 8502758..b998c41 100644
--- a/vendor/go.etcd.io/etcd/clientv3/utils.go
+++ b/vendor/go.etcd.io/etcd/clientv3/utils.go
@@ -16,6 +16,9 @@
import (
"math/rand"
+ "reflect"
+ "runtime"
+ "strings"
"time"
)
@@ -29,3 +32,18 @@
multiplier := jitter * (rand.Float64()*2 - 1)
return time.Duration(float64(duration) * (1 + multiplier))
}
+
+// Check if the provided function is being called in the op options.
+func isOpFuncCalled(op string, opts []OpOption) bool {
+ for _, opt := range opts {
+ v := reflect.ValueOf(opt)
+ if v.Kind() == reflect.Func {
+ if opFunc := runtime.FuncForPC(v.Pointer()); opFunc != nil {
+ if strings.Contains(opFunc.Name(), op) {
+ return true
+ }
+ }
+ }
+ }
+ return false
+}
diff --git a/vendor/go.etcd.io/etcd/clientv3/watch.go b/vendor/go.etcd.io/etcd/clientv3/watch.go
index 8ec58bb..d50acbc 100644
--- a/vendor/go.etcd.io/etcd/clientv3/watch.go
+++ b/vendor/go.etcd.io/etcd/clientv3/watch.go
@@ -371,6 +371,10 @@
err = werr
}
}
+ // Consider context.Canceled as a successful close
+ if err == context.Canceled {
+ err = nil
+ }
return err
}
diff --git a/vendor/go.etcd.io/etcd/raft/node.go b/vendor/go.etcd.io/etcd/raft/node.go
index 749db98..2ec2c3a 100644
--- a/vendor/go.etcd.io/etcd/raft/node.go
+++ b/vendor/go.etcd.io/etcd/raft/node.go
@@ -504,9 +504,9 @@
return ErrStopped
}
select {
- case rsp := <-pm.result:
- if rsp != nil {
- return rsp
+ case err := <-pm.result:
+ if err != nil {
+ return err
}
case <-ctx.Done():
return ctx.Err()
diff --git a/vendor/golang.org/x/crypto/ssh/terminal/util_windows.go b/vendor/golang.org/x/crypto/ssh/terminal/util_windows.go
index 6cb8a95..5cfdf8f 100644
--- a/vendor/golang.org/x/crypto/ssh/terminal/util_windows.go
+++ b/vendor/golang.org/x/crypto/ssh/terminal/util_windows.go
@@ -64,13 +64,15 @@
return windows.SetConsoleMode(windows.Handle(fd), state.mode)
}
-// GetSize returns the dimensions of the given terminal.
+// GetSize returns the visible dimensions of the given terminal.
+//
+// These dimensions don't include any scrollback buffer height.
func GetSize(fd int) (width, height int, err error) {
var info windows.ConsoleScreenBufferInfo
if err := windows.GetConsoleScreenBufferInfo(windows.Handle(fd), &info); err != nil {
return 0, 0, err
}
- return int(info.Size.X), int(info.Size.Y), nil
+ return int(info.Window.Right - info.Window.Left + 1), int(info.Window.Bottom - info.Window.Top + 1), nil
}
// ReadPassword reads a line of input from a terminal without local echo. This
diff --git a/vendor/golang.org/x/net/http2/frame.go b/vendor/golang.org/x/net/http2/frame.go
index b46791d..514c126 100644
--- a/vendor/golang.org/x/net/http2/frame.go
+++ b/vendor/golang.org/x/net/http2/frame.go
@@ -643,7 +643,7 @@
return f.WriteDataPadded(streamID, endStream, data, nil)
}
-// WriteData writes a DATA frame with optional padding.
+// WriteDataPadded writes a DATA frame with optional padding.
//
// If pad is nil, the padding bit is not sent.
// The length of pad must not exceed 255 bytes.
diff --git a/vendor/golang.org/x/oauth2/internal/token.go b/vendor/golang.org/x/oauth2/internal/token.go
index 955d5a0..355c386 100644
--- a/vendor/golang.org/x/oauth2/internal/token.go
+++ b/vendor/golang.org/x/oauth2/internal/token.go
@@ -11,6 +11,7 @@
"fmt"
"io"
"io/ioutil"
+ "math"
"mime"
"net/http"
"net/url"
@@ -62,16 +63,12 @@
TokenType string `json:"token_type"`
RefreshToken string `json:"refresh_token"`
ExpiresIn expirationTime `json:"expires_in"` // at least PayPal returns string, while most return number
- Expires expirationTime `json:"expires"` // broken Facebook spelling of expires_in
}
func (e *tokenJSON) expiry() (t time.Time) {
if v := e.ExpiresIn; v != 0 {
return time.Now().Add(time.Duration(v) * time.Second)
}
- if v := e.Expires; v != 0 {
- return time.Now().Add(time.Duration(v) * time.Second)
- }
return
}
@@ -90,6 +87,9 @@
if err != nil {
return err
}
+ if i > math.MaxInt32 {
+ i = math.MaxInt32
+ }
*e = expirationTime(i)
return nil
}
@@ -260,12 +260,6 @@
Raw: vals,
}
e := vals.Get("expires_in")
- if e == "" || e == "null" {
- // TODO(jbd): Facebook's OAuth2 implementation is broken and
- // returns expires_in field in expires. Remove the fallback to expires,
- // when Facebook fixes their implementation.
- e = vals.Get("expires")
- }
expires, _ := strconv.Atoi(e)
if expires != 0 {
token.Expiry = time.Now().Add(time.Duration(expires) * time.Second)
diff --git a/vendor/golang.org/x/sys/unix/mkall.sh b/vendor/golang.org/x/sys/unix/mkall.sh
index 75152f9..1e5c59d 100755
--- a/vendor/golang.org/x/sys/unix/mkall.sh
+++ b/vendor/golang.org/x/sys/unix/mkall.sh
@@ -207,8 +207,6 @@
esac
if [ -n "$mksysctl" ]; then echo "$mksysctl |gofmt >$zsysctl"; fi
if [ -n "$mksysnum" ]; then echo "$mksysnum |gofmt >zsysnum_$GOOSARCH.go"; fi
- if [ -n "$mktypes" ]; then
- echo "$mktypes types_$GOOS.go | go run mkpost.go > ztypes_$GOOSARCH.go";
+ if [ -n "$mktypes" ]; then echo "$mktypes types_$GOOS.go | go run mkpost.go > ztypes_$GOOSARCH.go"; fi
if [ -n "$mkasm" ]; then echo "$mkasm $GOARCH"; fi
- fi
) | $run
diff --git a/vendor/golang.org/x/sys/unix/mkerrors.sh b/vendor/golang.org/x/sys/unix/mkerrors.sh
index 6a23484..cfb61ba 100755
--- a/vendor/golang.org/x/sys/unix/mkerrors.sh
+++ b/vendor/golang.org/x/sys/unix/mkerrors.sh
@@ -192,6 +192,7 @@
#include <linux/if_packet.h>
#include <linux/if_addr.h>
#include <linux/falloc.h>
+#include <linux/fanotify.h>
#include <linux/filter.h>
#include <linux/fs.h>
#include <linux/kexec.h>
@@ -501,6 +502,7 @@
$2 !~ "WMESGLEN" &&
$2 ~ /^W[A-Z0-9]+$/ ||
$2 ~/^PPPIOC/ ||
+ $2 ~ /^FAN_|FANOTIFY_/ ||
$2 ~ /^BLK[A-Z]*(GET$|SET$|BUF$|PART$|SIZE)/ {printf("\t%s = C.%s\n", $2, $2)}
$2 ~ /^__WCOREFLAG$/ {next}
$2 ~ /^__W[A-Z0-9]+$/ {printf("\t%s = C.%s\n", substr($2,3), $2)}
diff --git a/vendor/golang.org/x/sys/unix/mksyscall.go b/vendor/golang.org/x/sys/unix/mksyscall.go
index e06e425..bed93d4 100644
--- a/vendor/golang.org/x/sys/unix/mksyscall.go
+++ b/vendor/golang.org/x/sys/unix/mksyscall.go
@@ -228,7 +228,7 @@
} else {
args = append(args, fmt.Sprintf("uintptr(%s)", p.Name))
}
- } else if p.Type == "int64" && endianness != "" {
+ } else if (p.Type == "int64" || p.Type == "uint64") && endianness != "" {
if len(args)%2 == 1 && *arm {
// arm abi specifies 64-bit argument uses
// (even, odd) pair
diff --git a/vendor/golang.org/x/sys/unix/sockcmsg_unix.go b/vendor/golang.org/x/sys/unix/sockcmsg_unix.go
index 5f9ae23..26e8b36 100644
--- a/vendor/golang.org/x/sys/unix/sockcmsg_unix.go
+++ b/vendor/golang.org/x/sys/unix/sockcmsg_unix.go
@@ -25,8 +25,8 @@
if SizeofPtr == 8 {
salign = 4
}
- case "openbsd":
- // OpenBSD armv7 requires 64-bit alignment.
+ case "netbsd", "openbsd":
+ // NetBSD and OpenBSD armv7 require 64-bit alignment.
if runtime.GOARCH == "arm" {
salign = 8
}
diff --git a/vendor/golang.org/x/sys/unix/syscall_aix.go b/vendor/golang.org/x/sys/unix/syscall_aix.go
index a76826f..fd83d87 100644
--- a/vendor/golang.org/x/sys/unix/syscall_aix.go
+++ b/vendor/golang.org/x/sys/unix/syscall_aix.go
@@ -545,3 +545,5 @@
//sys gettimeofday(tv *Timeval, tzp *Timezone) (err error)
//sysnb Time(t *Time_t) (tt Time_t, err error)
//sys Utime(path string, buf *Utimbuf) (err error)
+
+//sys Getsystemcfg(label int) (n uint64)
diff --git a/vendor/golang.org/x/sys/unix/syscall_linux.go b/vendor/golang.org/x/sys/unix/syscall_linux.go
index 4bb86aa..7e429ab 100644
--- a/vendor/golang.org/x/sys/unix/syscall_linux.go
+++ b/vendor/golang.org/x/sys/unix/syscall_linux.go
@@ -39,6 +39,20 @@
return Open(path, O_CREAT|O_WRONLY|O_TRUNC, mode)
}
+//sys FanotifyInit(flags uint, event_f_flags uint) (fd int, err error)
+//sys fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error)
+
+func FanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname string) (err error) {
+ if pathname == "" {
+ return fanotifyMark(fd, flags, mask, dirFd, nil)
+ }
+ p, err := BytePtrFromString(pathname)
+ if err != nil {
+ return err
+ }
+ return fanotifyMark(fd, flags, mask, dirFd, p)
+}
+
//sys fchmodat(dirfd int, path string, mode uint32) (err error)
func Fchmodat(dirfd int, path string, mode uint32, flags int) (err error) {
@@ -990,10 +1004,28 @@
return string(buf[:vallen-1]), nil
}
+func GetsockoptTpacketStats(fd, level, opt int) (*TpacketStats, error) {
+ var value TpacketStats
+ vallen := _Socklen(SizeofTpacketStats)
+ err := getsockopt(fd, level, opt, unsafe.Pointer(&value), &vallen)
+ return &value, err
+}
+
+func GetsockoptTpacketStatsV3(fd, level, opt int) (*TpacketStatsV3, error) {
+ var value TpacketStatsV3
+ vallen := _Socklen(SizeofTpacketStatsV3)
+ err := getsockopt(fd, level, opt, unsafe.Pointer(&value), &vallen)
+ return &value, err
+}
+
func SetsockoptIPMreqn(fd, level, opt int, mreq *IPMreqn) (err error) {
return setsockopt(fd, level, opt, unsafe.Pointer(mreq), unsafe.Sizeof(*mreq))
}
+func SetsockoptPacketMreq(fd, level, opt int, mreq *PacketMreq) error {
+ return setsockopt(fd, level, opt, unsafe.Pointer(mreq), unsafe.Sizeof(*mreq))
+}
+
// SetsockoptSockFprog attaches a classic BPF or an extended BPF program to a
// socket to filter incoming packets. See 'man 7 socket' for usage information.
func SetsockoptSockFprog(fd, level, opt int, fprog *SockFprog) error {
@@ -1008,6 +1040,14 @@
return setsockopt(fd, level, opt, p, uintptr(len(filter)*SizeofCanFilter))
}
+func SetsockoptTpacketReq(fd, level, opt int, tp *TpacketReq) error {
+ return setsockopt(fd, level, opt, unsafe.Pointer(tp), unsafe.Sizeof(*tp))
+}
+
+func SetsockoptTpacketReq3(fd, level, opt int, tp *TpacketReq3) error {
+ return setsockopt(fd, level, opt, unsafe.Pointer(tp), unsafe.Sizeof(*tp))
+}
+
// Keyctl Commands (http://man7.org/linux/man-pages/man2/keyctl.2.html)
// KeyctlInt calls keyctl commands in which each argument is an int.
diff --git a/vendor/golang.org/x/sys/unix/syscall_linux_arm.go b/vendor/golang.org/x/sys/unix/syscall_linux_arm.go
index cda3559..3a3c37b 100644
--- a/vendor/golang.org/x/sys/unix/syscall_linux_arm.go
+++ b/vendor/golang.org/x/sys/unix/syscall_linux_arm.go
@@ -19,12 +19,18 @@
return Timeval{Sec: int32(sec), Usec: int32(usec)}
}
+//sysnb pipe(p *[2]_C_int) (err error)
+
func Pipe(p []int) (err error) {
if len(p) != 2 {
return EINVAL
}
var pp [2]_C_int
+ // Try pipe2 first for Android O, then try pipe for kernel 2.6.23.
err = pipe2(&pp, 0)
+ if err == ENOSYS {
+ err = pipe(&pp)
+ }
p[0] = int(pp[0])
p[1] = int(pp[1])
return
diff --git a/vendor/golang.org/x/sys/unix/syscall_linux_arm64.go b/vendor/golang.org/x/sys/unix/syscall_linux_arm64.go
index 6d56722..cb20b15 100644
--- a/vendor/golang.org/x/sys/unix/syscall_linux_arm64.go
+++ b/vendor/golang.org/x/sys/unix/syscall_linux_arm64.go
@@ -208,3 +208,16 @@
}
return ppoll(&fds[0], len(fds), ts, nil)
}
+
+//sys kexecFileLoad(kernelFd int, initrdFd int, cmdlineLen int, cmdline string, flags int) (err error)
+
+func KexecFileLoad(kernelFd int, initrdFd int, cmdline string, flags int) error {
+ cmdlineLen := len(cmdline)
+ if cmdlineLen > 0 {
+ // Account for the additional NULL byte added by
+ // BytePtrFromString in kexecFileLoad. The kexec_file_load
+ // syscall expects a NULL-terminated string.
+ cmdlineLen++
+ }
+ return kexecFileLoad(kernelFd, initrdFd, cmdlineLen, cmdline, flags)
+}
diff --git a/vendor/golang.org/x/sys/unix/syscall_linux_riscv64.go b/vendor/golang.org/x/sys/unix/syscall_linux_riscv64.go
index f23ca45..6230f64 100644
--- a/vendor/golang.org/x/sys/unix/syscall_linux_riscv64.go
+++ b/vendor/golang.org/x/sys/unix/syscall_linux_riscv64.go
@@ -211,3 +211,16 @@
func Renameat(olddirfd int, oldpath string, newdirfd int, newpath string) (err error) {
return Renameat2(olddirfd, oldpath, newdirfd, newpath, 0)
}
+
+//sys kexecFileLoad(kernelFd int, initrdFd int, cmdlineLen int, cmdline string, flags int) (err error)
+
+func KexecFileLoad(kernelFd int, initrdFd int, cmdline string, flags int) error {
+ cmdlineLen := len(cmdline)
+ if cmdlineLen > 0 {
+ // Account for the additional NULL byte added by
+ // BytePtrFromString in kexecFileLoad. The kexec_file_load
+ // syscall expects a NULL-terminated string.
+ cmdlineLen++
+ }
+ return kexecFileLoad(kernelFd, initrdFd, cmdlineLen, cmdline, flags)
+}
diff --git a/vendor/golang.org/x/sys/unix/syscall_openbsd.go b/vendor/golang.org/x/sys/unix/syscall_openbsd.go
index 6879995..c8648ec 100644
--- a/vendor/golang.org/x/sys/unix/syscall_openbsd.go
+++ b/vendor/golang.org/x/sys/unix/syscall_openbsd.go
@@ -43,6 +43,23 @@
return nil, EINVAL
}
+func SysctlClockinfo(name string) (*Clockinfo, error) {
+ mib, err := sysctlmib(name)
+ if err != nil {
+ return nil, err
+ }
+
+ n := uintptr(SizeofClockinfo)
+ var ci Clockinfo
+ if err := sysctl(mib, (*byte)(unsafe.Pointer(&ci)), &n, nil, 0); err != nil {
+ return nil, err
+ }
+ if n != SizeofClockinfo {
+ return nil, EIO
+ }
+ return &ci, nil
+}
+
func SysctlUvmexp(name string) (*Uvmexp, error) {
mib, err := sysctlmib(name)
if err != nil {
diff --git a/vendor/golang.org/x/sys/unix/syscall_unix.go b/vendor/golang.org/x/sys/unix/syscall_unix.go
index 33583a2..ae59fba 100644
--- a/vendor/golang.org/x/sys/unix/syscall_unix.go
+++ b/vendor/golang.org/x/sys/unix/syscall_unix.go
@@ -28,6 +28,11 @@
errENOENT error = syscall.ENOENT
)
+var (
+ signalNameMapOnce sync.Once
+ signalNameMap map[string]syscall.Signal
+)
+
// errnoErr returns common boxed Errno values, to prevent
// allocations at runtime.
func errnoErr(e syscall.Errno) error {
@@ -66,6 +71,19 @@
return ""
}
+// SignalNum returns the syscall.Signal for signal named s,
+// or 0 if a signal with such name is not found.
+// The signal name should start with "SIG".
+func SignalNum(s string) syscall.Signal {
+ signalNameMapOnce.Do(func() {
+ signalNameMap = make(map[string]syscall.Signal)
+ for _, signal := range signalList {
+ signalNameMap[signal.name] = signal.num
+ }
+ })
+ return signalNameMap[s]
+}
+
// clen returns the index of the first NULL byte in n or len(n) if n contains no NULL byte.
func clen(n []byte) int {
i := bytes.IndexByte(n, 0)
@@ -377,3 +395,22 @@
func Exec(argv0 string, argv []string, envv []string) error {
return syscall.Exec(argv0, argv, envv)
}
+
+// Lutimes sets the access and modification times tv on path. If path refers to
+// a symlink, it is not dereferenced and the timestamps are set on the symlink.
+// If tv is nil, the access and modification times are set to the current time.
+// Otherwise tv must contain exactly 2 elements, with access time as the first
+// element and modification time as the second element.
+func Lutimes(path string, tv []Timeval) error {
+ if tv == nil {
+ return UtimesNanoAt(AT_FDCWD, path, nil, AT_SYMLINK_NOFOLLOW)
+ }
+ if len(tv) != 2 {
+ return EINVAL
+ }
+ ts := []Timespec{
+ NsecToTimespec(TimevalToNsec(tv[0])),
+ NsecToTimespec(TimevalToNsec(tv[1])),
+ }
+ return UtimesNanoAt(AT_FDCWD, path, ts, AT_SYMLINK_NOFOLLOW)
+}
diff --git a/vendor/golang.org/x/sys/unix/types_openbsd.go b/vendor/golang.org/x/sys/unix/types_openbsd.go
index 4e5e57f..8aafbe4 100644
--- a/vendor/golang.org/x/sys/unix/types_openbsd.go
+++ b/vendor/golang.org/x/sys/unix/types_openbsd.go
@@ -274,3 +274,9 @@
const SizeofUvmexp = C.sizeof_struct_uvmexp
type Uvmexp C.struct_uvmexp
+
+// Clockinfo
+
+const SizeofClockinfo = C.sizeof_struct_clockinfo
+
+type Clockinfo C.struct_clockinfo
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_386.go b/vendor/golang.org/x/sys/unix/zerrors_linux_386.go
index cb89df8..9e99d67 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_386.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_386.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x80041270
BLKBSZSET = 0x40041271
@@ -486,6 +487,50 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
@@ -493,6 +538,7 @@
FFDLY = 0x8000
FLUSHO = 0x1000
FP_XSTATE_MAGIC2 = 0x46505845
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -514,7 +560,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1134,7 +1180,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1398,6 +1444,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2232,6 +2284,7 @@
TUNGETVNETBE = 0x800454df
TUNGETVNETHDRSZ = 0x800454d7
TUNGETVNETLE = 0x800454dd
+ TUNSETCARRIER = 0x400454e2
TUNSETDEBUG = 0x400454c9
TUNSETFILTEREBPF = 0x800454e1
TUNSETGROUP = 0x400454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go
index 73c9b88..e3091f1 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x80081270
BLKBSZSET = 0x40081271
@@ -486,6 +487,50 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
@@ -493,6 +538,7 @@
FFDLY = 0x8000
FLUSHO = 0x1000
FP_XSTATE_MAGIC2 = 0x46505845
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -514,7 +560,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1134,7 +1180,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1398,6 +1444,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2233,6 +2285,7 @@
TUNGETVNETBE = 0x800454df
TUNGETVNETHDRSZ = 0x800454d7
TUNGETVNETLE = 0x800454dd
+ TUNSETCARRIER = 0x400454e2
TUNSETDEBUG = 0x400454c9
TUNSETFILTEREBPF = 0x800454e1
TUNSETGROUP = 0x400454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go b/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go
index f1ef82f..a75dfeb 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x80041270
BLKBSZSET = 0x40041271
@@ -486,12 +487,57 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
FF1 = 0x8000
FFDLY = 0x8000
FLUSHO = 0x1000
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -513,7 +559,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1132,7 +1178,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1396,6 +1442,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2239,6 +2291,7 @@
TUNGETVNETBE = 0x800454df
TUNGETVNETHDRSZ = 0x800454d7
TUNGETVNETLE = 0x800454dd
+ TUNSETCARRIER = 0x400454e2
TUNSETDEBUG = 0x400454c9
TUNSETFILTEREBPF = 0x800454e1
TUNSETGROUP = 0x400454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go
index cf17c99..393ad7c 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x80081270
BLKBSZSET = 0x40081271
@@ -488,6 +489,50 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
@@ -495,6 +540,7 @@
FFDLY = 0x8000
FLUSHO = 0x1000
FPSIMD_MAGIC = 0x46508001
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -516,7 +562,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1135,7 +1181,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1399,6 +1445,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2224,6 +2276,7 @@
TUNGETVNETBE = 0x800454df
TUNGETVNETHDRSZ = 0x800454d7
TUNGETVNETLE = 0x800454dd
+ TUNSETCARRIER = 0x400454e2
TUNSETDEBUG = 0x400454c9
TUNSETFILTEREBPF = 0x800454e1
TUNSETGROUP = 0x400454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go
index 380913c..ba1beb9 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x40041270
BLKBSZSET = 0x80041271
@@ -486,12 +487,57 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
FF1 = 0x8000
FFDLY = 0x8000
FLUSHO = 0x2000
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -513,7 +559,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1132,7 +1178,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1396,6 +1442,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2234,6 +2286,7 @@
TUNGETVNETBE = 0x400454df
TUNGETVNETHDRSZ = 0x400454d7
TUNGETVNETLE = 0x400454dd
+ TUNSETCARRIER = 0x800454e2
TUNSETDEBUG = 0x800454c9
TUNSETFILTEREBPF = 0x400454e1
TUNSETGROUP = 0x800454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go
index fb82529..efba3e5 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x40081270
BLKBSZSET = 0x80081271
@@ -486,12 +487,57 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
FF1 = 0x8000
FFDLY = 0x8000
FLUSHO = 0x2000
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -513,7 +559,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1132,7 +1178,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1396,6 +1442,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2234,6 +2286,7 @@
TUNGETVNETBE = 0x400454df
TUNGETVNETHDRSZ = 0x400454d7
TUNGETVNETLE = 0x400454dd
+ TUNSETCARRIER = 0x800454e2
TUNSETDEBUG = 0x800454c9
TUNSETFILTEREBPF = 0x400454e1
TUNSETGROUP = 0x800454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go
index 677d904..d3f6e90 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x40081270
BLKBSZSET = 0x80081271
@@ -486,12 +487,57 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
FF1 = 0x8000
FFDLY = 0x8000
FLUSHO = 0x2000
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -513,7 +559,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1132,7 +1178,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1396,6 +1442,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2234,6 +2286,7 @@
TUNGETVNETBE = 0x400454df
TUNGETVNETHDRSZ = 0x400454d7
TUNGETVNETLE = 0x400454dd
+ TUNSETCARRIER = 0x800454e2
TUNSETDEBUG = 0x800454c9
TUNSETFILTEREBPF = 0x400454e1
TUNSETGROUP = 0x800454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go b/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go
index 7ddd09d..7275cd8 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x40041270
BLKBSZSET = 0x80041271
@@ -486,12 +487,57 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
FF1 = 0x8000
FFDLY = 0x8000
FLUSHO = 0x2000
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -513,7 +559,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1132,7 +1178,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1396,6 +1442,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2234,6 +2286,7 @@
TUNGETVNETBE = 0x400454df
TUNGETVNETHDRSZ = 0x400454d7
TUNGETVNETLE = 0x400454dd
+ TUNSETCARRIER = 0x800454e2
TUNSETDEBUG = 0x800454c9
TUNSETFILTEREBPF = 0x400454e1
TUNSETGROUP = 0x800454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go
index ebaca41..7586a13 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x40081270
BLKBSZSET = 0x80081271
@@ -486,12 +487,57 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
FF1 = 0x4000
FFDLY = 0x4000
FLUSHO = 0x800000
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -513,7 +559,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1131,7 +1177,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1398,6 +1444,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2294,6 +2346,7 @@
TUNGETVNETBE = 0x400454df
TUNGETVNETHDRSZ = 0x400454d7
TUNGETVNETLE = 0x400454dd
+ TUNSETCARRIER = 0x800454e2
TUNSETDEBUG = 0x800454c9
TUNSETFILTEREBPF = 0x400454e1
TUNSETGROUP = 0x800454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go
index 02938cb..b861ec7 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x40081270
BLKBSZSET = 0x80081271
@@ -486,12 +487,57 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
FF1 = 0x4000
FFDLY = 0x4000
FLUSHO = 0x800000
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -513,7 +559,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1131,7 +1177,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1398,6 +1444,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2294,6 +2346,7 @@
TUNGETVNETBE = 0x400454df
TUNGETVNETHDRSZ = 0x400454d7
TUNGETVNETLE = 0x400454dd
+ TUNSETCARRIER = 0x800454e2
TUNSETDEBUG = 0x800454c9
TUNSETFILTEREBPF = 0x400454e1
TUNSETGROUP = 0x800454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go
index 5aea4b9..a321ec2 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x80081270
BLKBSZSET = 0x40081271
@@ -486,12 +487,57 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
FF1 = 0x8000
FFDLY = 0x8000
FLUSHO = 0x1000
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -513,7 +559,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1132,7 +1178,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1396,6 +1442,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2220,6 +2272,7 @@
TUNGETVNETBE = 0x800454df
TUNGETVNETHDRSZ = 0x800454d7
TUNGETVNETLE = 0x800454dd
+ TUNSETCARRIER = 0x400454e2
TUNSETDEBUG = 0x400454c9
TUNSETFILTEREBPF = 0x800454e1
TUNSETGROUP = 0x400454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go b/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go
index 7f7c2e3..f6c9916 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go
@@ -174,6 +174,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x80081270
BLKBSZSET = 0x40081271
@@ -486,12 +487,57 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
FF1 = 0x8000
FFDLY = 0x8000
FLUSHO = 0x1000
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -513,7 +559,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1132,7 +1178,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1396,6 +1442,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2293,6 +2345,7 @@
TUNGETVNETBE = 0x800454df
TUNGETVNETHDRSZ = 0x800454d7
TUNGETVNETLE = 0x800454dd
+ TUNSETCARRIER = 0x400454e2
TUNSETDEBUG = 0x400454c9
TUNSETFILTEREBPF = 0x800454e1
TUNSETGROUP = 0x400454ce
diff --git a/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go b/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go
index 968e21f..c1e95e2 100644
--- a/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go
+++ b/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go
@@ -177,6 +177,7 @@
B9600 = 0xd
BALLOON_KVM_MAGIC = 0x13661366
BDEVFS_MAGIC = 0x62646576
+ BINDERFS_SUPER_MAGIC = 0x6c6f6f70
BINFMTFS_MAGIC = 0x42494e4d
BLKBSZGET = 0x40081270
BLKBSZSET = 0x80081271
@@ -490,12 +491,57 @@
FALLOC_FL_PUNCH_HOLE = 0x2
FALLOC_FL_UNSHARE_RANGE = 0x40
FALLOC_FL_ZERO_RANGE = 0x10
+ FANOTIFY_METADATA_VERSION = 0x3
+ FAN_ACCESS = 0x1
+ FAN_ACCESS_PERM = 0x20000
+ FAN_ALLOW = 0x1
+ FAN_ALL_CLASS_BITS = 0xc
+ FAN_ALL_EVENTS = 0x3b
+ FAN_ALL_INIT_FLAGS = 0x3f
+ FAN_ALL_MARK_FLAGS = 0xff
+ FAN_ALL_OUTGOING_EVENTS = 0x3403b
+ FAN_ALL_PERM_EVENTS = 0x30000
+ FAN_AUDIT = 0x10
+ FAN_CLASS_CONTENT = 0x4
+ FAN_CLASS_NOTIF = 0x0
+ FAN_CLASS_PRE_CONTENT = 0x8
+ FAN_CLOEXEC = 0x1
+ FAN_CLOSE = 0x18
+ FAN_CLOSE_NOWRITE = 0x10
+ FAN_CLOSE_WRITE = 0x8
+ FAN_DENY = 0x2
+ FAN_ENABLE_AUDIT = 0x40
+ FAN_EVENT_METADATA_LEN = 0x18
+ FAN_EVENT_ON_CHILD = 0x8000000
+ FAN_MARK_ADD = 0x1
+ FAN_MARK_DONT_FOLLOW = 0x4
+ FAN_MARK_FILESYSTEM = 0x100
+ FAN_MARK_FLUSH = 0x80
+ FAN_MARK_IGNORED_MASK = 0x20
+ FAN_MARK_IGNORED_SURV_MODIFY = 0x40
+ FAN_MARK_INODE = 0x0
+ FAN_MARK_MOUNT = 0x10
+ FAN_MARK_ONLYDIR = 0x8
+ FAN_MARK_REMOVE = 0x2
+ FAN_MODIFY = 0x2
+ FAN_NOFD = -0x1
+ FAN_NONBLOCK = 0x2
+ FAN_ONDIR = 0x40000000
+ FAN_OPEN = 0x20
+ FAN_OPEN_EXEC = 0x1000
+ FAN_OPEN_EXEC_PERM = 0x40000
+ FAN_OPEN_PERM = 0x10000
+ FAN_Q_OVERFLOW = 0x4000
+ FAN_REPORT_TID = 0x100
+ FAN_UNLIMITED_MARKS = 0x20
+ FAN_UNLIMITED_QUEUE = 0x10
FD_CLOEXEC = 0x1
FD_SETSIZE = 0x400
FF0 = 0x0
FF1 = 0x8000
FFDLY = 0x8000
FLUSHO = 0x1000
+ FS_ENCRYPTION_MODE_ADIANTUM = 0x9
FS_ENCRYPTION_MODE_AES_128_CBC = 0x5
FS_ENCRYPTION_MODE_AES_128_CTS = 0x6
FS_ENCRYPTION_MODE_AES_256_CBC = 0x3
@@ -517,7 +563,7 @@
FS_POLICY_FLAGS_PAD_4 = 0x0
FS_POLICY_FLAGS_PAD_8 = 0x1
FS_POLICY_FLAGS_PAD_MASK = 0x3
- FS_POLICY_FLAGS_VALID = 0x3
+ FS_POLICY_FLAGS_VALID = 0x7
FUTEXFS_SUPER_MAGIC = 0xbad1dea
F_ADD_SEALS = 0x409
F_DUPFD = 0x0
@@ -1136,7 +1182,7 @@
NETLINK_UNUSED = 0x1
NETLINK_USERSOCK = 0x2
NETLINK_XFRM = 0x6
- NETNSA_MAX = 0x3
+ NETNSA_MAX = 0x5
NETNSA_NSID_NOT_ASSIGNED = -0x1
NFNETLINK_V0 = 0x0
NFNLGRP_ACCT_QUOTA = 0x8
@@ -1400,6 +1446,12 @@
PR_MCE_KILL_SET = 0x1
PR_MPX_DISABLE_MANAGEMENT = 0x2c
PR_MPX_ENABLE_MANAGEMENT = 0x2b
+ PR_PAC_APDAKEY = 0x4
+ PR_PAC_APDBKEY = 0x8
+ PR_PAC_APGAKEY = 0x10
+ PR_PAC_APIAKEY = 0x1
+ PR_PAC_APIBKEY = 0x2
+ PR_PAC_RESET_KEYS = 0x36
PR_SET_CHILD_SUBREAPER = 0x24
PR_SET_DUMPABLE = 0x4
PR_SET_ENDIAN = 0x14
@@ -2282,6 +2334,7 @@
TUNGETVNETBE = 0x400454df
TUNGETVNETHDRSZ = 0x400454d7
TUNGETVNETLE = 0x400454dd
+ TUNSETCARRIER = 0x800454e2
TUNSETDEBUG = 0x800454c9
TUNSETFILTEREBPF = 0x400454e1
TUNSETGROUP = 0x800454ce
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64.go b/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64.go
index e645a05..52802bf 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64.go
@@ -1367,6 +1367,14 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func Getsystemcfg(label int) (n uint64) {
+ r0, _ := callgetsystemcfg(label)
+ n = uint64(r0)
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func Getrlimit(resource int, rlim *Rlimit) (err error) {
_, e1 := callgetrlimit(resource, uintptr(unsafe.Pointer(rlim)))
if e1 != 0 {
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gc.go b/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gc.go
index 0b8eb72..a2b24e4 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gc.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gc.go
@@ -120,6 +120,7 @@
//go:cgo_import_dynamic libc_gettimeofday gettimeofday "libc.a/shr_64.o"
//go:cgo_import_dynamic libc_time time "libc.a/shr_64.o"
//go:cgo_import_dynamic libc_utime utime "libc.a/shr_64.o"
+//go:cgo_import_dynamic libc_getsystemcfg getsystemcfg "libc.a/shr_64.o"
//go:cgo_import_dynamic libc_getrlimit getrlimit "libc.a/shr_64.o"
//go:cgo_import_dynamic libc_setrlimit setrlimit "libc.a/shr_64.o"
//go:cgo_import_dynamic libc_lseek lseek "libc.a/shr_64.o"
@@ -235,6 +236,7 @@
//go:linkname libc_gettimeofday libc_gettimeofday
//go:linkname libc_time libc_time
//go:linkname libc_utime libc_utime
+//go:linkname libc_getsystemcfg libc_getsystemcfg
//go:linkname libc_getrlimit libc_getrlimit
//go:linkname libc_setrlimit libc_setrlimit
//go:linkname libc_lseek libc_lseek
@@ -353,6 +355,7 @@
libc_gettimeofday,
libc_time,
libc_utime,
+ libc_getsystemcfg,
libc_getrlimit,
libc_setrlimit,
libc_lseek,
@@ -1135,6 +1138,13 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func callgetsystemcfg(label int) (r1 uintptr, e1 Errno) {
+ r1, _, e1 = syscall6(uintptr(unsafe.Pointer(&libc_getsystemcfg)), 1, uintptr(label), 0, 0, 0, 0, 0)
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func callgetrlimit(resource int, rlim uintptr) (r1 uintptr, e1 Errno) {
r1, _, e1 = rawSyscall6(uintptr(unsafe.Pointer(&libc_getrlimit)), 2, uintptr(resource), rlim, 0, 0, 0, 0)
return
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gccgo.go b/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gccgo.go
index e88a442..5491c89 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gccgo.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gccgo.go
@@ -118,6 +118,7 @@
int gettimeofday(uintptr_t, uintptr_t);
int time(uintptr_t);
int utime(uintptr_t, uintptr_t);
+unsigned long long getsystemcfg(int);
int getrlimit(int, uintptr_t);
int setrlimit(int, uintptr_t);
long long lseek(int, long long, int);
@@ -1011,6 +1012,14 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func callgetsystemcfg(label int) (r1 uintptr, e1 Errno) {
+ r1 = uintptr(C.getsystemcfg(C.int(label)))
+ e1 = syscall.GetErrno()
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func callgetrlimit(resource int, rlim uintptr) (r1 uintptr, e1 Errno) {
r1 = uintptr(C.getrlimit(C.int(resource), C.uintptr_t(rlim)))
e1 = syscall.GetErrno()
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_386.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_386.go
index c8b4510..9855afa 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_386.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_386.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(mask>>32), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)))
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_amd64.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_amd64.go
index 2aac318..773e251 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_amd64.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_amd64.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)), 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_arm.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_arm.go
index 13c06c2..ccea621 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_arm.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_arm.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(mask>>32), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)))
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
@@ -1658,6 +1679,16 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func pipe(p *[2]_C_int) (err error) {
+ _, _, e1 := RawSyscall(SYS_PIPE, uintptr(unsafe.Pointer(p)), 0, 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func pipe2(p *[2]_C_int, flags int) (err error) {
_, _, e1 := RawSyscall(SYS_PIPE2, uintptr(unsafe.Pointer(p)), uintptr(flags), 0)
if e1 != 0 {
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_arm64.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_arm64.go
index 737fa8d..712c7a3 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_arm64.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_arm64.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)), 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
@@ -2206,3 +2227,18 @@
}
return
}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func kexecFileLoad(kernelFd int, initrdFd int, cmdlineLen int, cmdline string, flags int) (err error) {
+ var _p0 *byte
+ _p0, err = BytePtrFromString(cmdline)
+ if err != nil {
+ return
+ }
+ _, _, e1 := Syscall6(SYS_KEXEC_FILE_LOAD, uintptr(kernelFd), uintptr(initrdFd), uintptr(cmdlineLen), uintptr(unsafe.Pointer(_p0)), uintptr(flags), 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_mips.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_mips.go
index 0a85f3f..68b3251 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_mips.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_mips.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask>>32), uintptr(mask), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)))
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_mips64.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_mips64.go
index ec7007e..a8be407 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_mips64.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_mips64.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)), 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_mips64le.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_mips64le.go
index c5bb25d..1351028 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_mips64le.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_mips64le.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)), 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_mipsle.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_mipsle.go
index 26ada04..327b4f9 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_mipsle.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_mipsle.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(mask>>32), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)))
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64.go
index 2da9cb7..c145bd3 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)), 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64le.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64le.go
index 772733d..cd8179c 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64le.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64le.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)), 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_riscv64.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_riscv64.go
index 996eba5..2e90cf0 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_riscv64.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_riscv64.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)), 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
@@ -2186,3 +2207,18 @@
}
return
}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func kexecFileLoad(kernelFd int, initrdFd int, cmdlineLen int, cmdline string, flags int) (err error) {
+ var _p0 *byte
+ _p0, err = BytePtrFromString(cmdline)
+ if err != nil {
+ return
+ }
+ _, _, e1 := Syscall6(SYS_KEXEC_FILE_LOAD, uintptr(kernelFd), uintptr(initrdFd), uintptr(cmdlineLen), uintptr(unsafe.Pointer(_p0)), uintptr(flags), 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_s390x.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_s390x.go
index cb9072a..fe9c7e1 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_s390x.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_s390x.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)), 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
diff --git a/vendor/golang.org/x/sys/unix/zsyscall_linux_sparc64.go b/vendor/golang.org/x/sys/unix/zsyscall_linux_sparc64.go
index 5e48a10..d4a2100 100644
--- a/vendor/golang.org/x/sys/unix/zsyscall_linux_sparc64.go
+++ b/vendor/golang.org/x/sys/unix/zsyscall_linux_sparc64.go
@@ -14,6 +14,27 @@
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+func FanotifyInit(flags uint, event_f_flags uint) (fd int, err error) {
+ r0, _, e1 := Syscall(SYS_FANOTIFY_INIT, uintptr(flags), uintptr(event_f_flags), 0)
+ fd = int(r0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
+func fanotifyMark(fd int, flags uint, mask uint64, dirFd int, pathname *byte) (err error) {
+ _, _, e1 := Syscall6(SYS_FANOTIFY_MARK, uintptr(fd), uintptr(flags), uintptr(mask), uintptr(dirFd), uintptr(unsafe.Pointer(pathname)), 0)
+ if e1 != 0 {
+ err = errnoErr(e1)
+ }
+ return
+}
+
+// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
+
func fchmodat(dirfd int, path string, mode uint32) (err error) {
var _p0 *byte
_p0, err = BytePtrFromString(path)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go
index 3206967..b81d508 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go
@@ -285,4 +285,5 @@
SYS_STATX = 291
SYS_IO_PGETEVENTS = 292
SYS_RSEQ = 293
+ SYS_KEXEC_FILE_LOAD = 294
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go
index 473c746..2c8c46a 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go
@@ -284,4 +284,5 @@
SYS_STATX = 291
SYS_IO_PGETEVENTS = 292
SYS_RSEQ = 293
+ SYS_KEXEC_FILE_LOAD = 294
)
diff --git a/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go b/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go
index 93480fc..6ed3063 100644
--- a/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go
+++ b/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go
@@ -253,6 +253,7 @@
SYS_TIMER_GETOVERRUN = 264
SYS_TIMER_DELETE = 265
SYS_TIMER_CREATE = 266
+ SYS_VSERVER = 267
SYS_IO_SETUP = 268
SYS_IO_DESTROY = 269
SYS_IO_SUBMIT = 270
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_386.go b/vendor/golang.org/x/sys/unix/ztypes_linux_386.go
index 3e9c18e..6dfe56b 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_386.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_386.go
@@ -575,6 +575,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -640,6 +641,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x8
@@ -961,7 +973,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1064,6 +1077,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1085,21 +1099,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1112,6 +1143,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1416,6 +1448,9 @@
SizeofTpacketHdr = 0x18
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2031,3 +2066,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_amd64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_amd64.go
index 14365ff..9f8cbf4 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_amd64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_amd64.go
@@ -576,6 +576,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -641,6 +642,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x10
@@ -972,7 +984,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1075,6 +1088,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1096,21 +1110,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1123,6 +1154,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1428,6 +1460,9 @@
SizeofTpacketHdr = 0x20
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2044,3 +2079,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_arm.go b/vendor/golang.org/x/sys/unix/ztypes_linux_arm.go
index 80ad473..cbbf19a 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_arm.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_arm.go
@@ -579,6 +579,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -644,6 +645,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x8
@@ -950,7 +962,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1053,6 +1066,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1074,21 +1088,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1101,6 +1132,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1406,6 +1438,9 @@
SizeofTpacketHdr = 0x18
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2022,3 +2057,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_arm64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_arm64.go
index 20e78cc..be21189 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_arm64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_arm64.go
@@ -577,6 +577,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -642,6 +643,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x10
@@ -951,7 +963,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1054,6 +1067,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1075,21 +1089,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1102,6 +1133,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1407,6 +1439,9 @@
SizeofTpacketHdr = 0x20
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2023,3 +2058,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_mips.go b/vendor/golang.org/x/sys/unix/ztypes_linux_mips.go
index bdeb0cb..d599ca2 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_mips.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_mips.go
@@ -578,6 +578,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -643,6 +644,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x8
@@ -955,7 +967,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1058,6 +1071,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1079,21 +1093,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1106,6 +1137,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1412,6 +1444,9 @@
SizeofTpacketHdr = 0x18
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2028,3 +2063,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go
index 2d3f591..011be86 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go
@@ -577,6 +577,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -642,6 +643,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x10
@@ -953,7 +965,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1056,6 +1069,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1077,21 +1091,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1104,6 +1135,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1409,6 +1441,9 @@
SizeofTpacketHdr = 0x20
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2025,3 +2060,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go b/vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go
index 5fb57ff..8163445 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go
@@ -577,6 +577,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -642,6 +643,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x10
@@ -953,7 +965,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1056,6 +1069,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1077,21 +1091,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1104,6 +1135,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1409,6 +1441,9 @@
SizeofTpacketHdr = 0x20
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2025,3 +2060,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go b/vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go
index b46b26f..4ecf7a8 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go
@@ -578,6 +578,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -643,6 +644,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x8
@@ -955,7 +967,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1058,6 +1071,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1079,21 +1093,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1106,6 +1137,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1412,6 +1444,9 @@
SizeofTpacketHdr = 0x18
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2028,3 +2063,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64.go
index e14e3c9..ea817ba 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64.go
@@ -578,6 +578,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -643,6 +644,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x10
@@ -961,7 +973,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1064,6 +1077,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1085,21 +1099,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1112,6 +1143,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1417,6 +1449,9 @@
SizeofTpacketHdr = 0x20
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2033,3 +2068,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64le.go b/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64le.go
index 2332e8f..192ea3b 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64le.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_ppc64le.go
@@ -578,6 +578,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -643,6 +644,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x10
@@ -961,7 +973,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1064,6 +1077,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1085,21 +1099,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1112,6 +1143,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1417,6 +1449,9 @@
SizeofTpacketHdr = 0x20
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2033,3 +2068,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go
index efec4f8..673e5e7 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go
@@ -577,6 +577,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -642,6 +643,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x10
@@ -978,7 +990,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1081,6 +1094,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1102,21 +1116,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1129,6 +1160,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1434,6 +1466,9 @@
SizeofTpacketHdr = 0x20
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2050,3 +2085,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_s390x.go b/vendor/golang.org/x/sys/unix/ztypes_linux_s390x.go
index 71cc23f..faafcdd 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_s390x.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_s390x.go
@@ -576,6 +576,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -641,6 +642,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x10
@@ -974,7 +986,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1077,6 +1090,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1098,21 +1112,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1125,6 +1156,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1431,6 +1463,9 @@
SizeofTpacketHdr = 0x20
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2047,3 +2082,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_linux_sparc64.go b/vendor/golang.org/x/sys/unix/ztypes_linux_sparc64.go
index 48805ba..392dd73 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_linux_sparc64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_linux_sparc64.go
@@ -580,6 +580,7 @@
SizeofIfAddrmsg = 0x8
SizeofRtMsg = 0xc
SizeofRtNexthop = 0x8
+ SizeofNdUseroptmsg = 0x10
)
type NlMsghdr struct {
@@ -645,6 +646,17 @@
Ifindex int32
}
+type NdUseroptmsg struct {
+ Family uint8
+ Pad1 uint8
+ Opts_len uint16
+ Ifindex int32
+ Icmp_type uint8
+ Icmp_code uint8
+ Pad2 uint16
+ Pad3 uint32
+}
+
const (
SizeofSockFilter = 0x8
SizeofSockFprog = 0x10
@@ -956,7 +968,8 @@
Clockid int32
Sample_regs_intr uint64
Aux_watermark uint32
- _ uint32
+ Sample_max_stack uint16
+ _ uint16
}
type PerfEventMmapPage struct {
@@ -1059,6 +1072,7 @@
PERF_COUNT_SW_ALIGNMENT_FAULTS = 0x7
PERF_COUNT_SW_EMULATION_FAULTS = 0x8
PERF_COUNT_SW_DUMMY = 0x9
+ PERF_COUNT_SW_BPF_OUTPUT = 0xa
PERF_SAMPLE_IP = 0x1
PERF_SAMPLE_TID = 0x2
@@ -1080,21 +1094,38 @@
PERF_SAMPLE_BRANCH_ANY_CALL = 0x10
PERF_SAMPLE_BRANCH_ANY_RETURN = 0x20
PERF_SAMPLE_BRANCH_IND_CALL = 0x40
+ PERF_SAMPLE_BRANCH_ABORT_TX = 0x80
+ PERF_SAMPLE_BRANCH_IN_TX = 0x100
+ PERF_SAMPLE_BRANCH_NO_TX = 0x200
+ PERF_SAMPLE_BRANCH_COND = 0x400
+ PERF_SAMPLE_BRANCH_CALL_STACK = 0x800
+ PERF_SAMPLE_BRANCH_IND_JUMP = 0x1000
+ PERF_SAMPLE_BRANCH_CALL = 0x2000
+ PERF_SAMPLE_BRANCH_NO_FLAGS = 0x4000
+ PERF_SAMPLE_BRANCH_NO_CYCLES = 0x8000
+ PERF_SAMPLE_BRANCH_TYPE_SAVE = 0x10000
PERF_FORMAT_TOTAL_TIME_ENABLED = 0x1
PERF_FORMAT_TOTAL_TIME_RUNNING = 0x2
PERF_FORMAT_ID = 0x4
PERF_FORMAT_GROUP = 0x8
- PERF_RECORD_MMAP = 0x1
- PERF_RECORD_LOST = 0x2
- PERF_RECORD_COMM = 0x3
- PERF_RECORD_EXIT = 0x4
- PERF_RECORD_THROTTLE = 0x5
- PERF_RECORD_UNTHROTTLE = 0x6
- PERF_RECORD_FORK = 0x7
- PERF_RECORD_READ = 0x8
- PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP = 0x1
+ PERF_RECORD_LOST = 0x2
+ PERF_RECORD_COMM = 0x3
+ PERF_RECORD_EXIT = 0x4
+ PERF_RECORD_THROTTLE = 0x5
+ PERF_RECORD_UNTHROTTLE = 0x6
+ PERF_RECORD_FORK = 0x7
+ PERF_RECORD_READ = 0x8
+ PERF_RECORD_SAMPLE = 0x9
+ PERF_RECORD_MMAP2 = 0xa
+ PERF_RECORD_AUX = 0xb
+ PERF_RECORD_ITRACE_START = 0xc
+ PERF_RECORD_LOST_SAMPLES = 0xd
+ PERF_RECORD_SWITCH = 0xe
+ PERF_RECORD_SWITCH_CPU_WIDE = 0xf
+ PERF_RECORD_NAMESPACES = 0x10
PERF_CONTEXT_HV = -0x20
PERF_CONTEXT_KERNEL = -0x80
@@ -1107,6 +1138,7 @@
PERF_FLAG_FD_NO_GROUP = 0x1
PERF_FLAG_FD_OUTPUT = 0x2
PERF_FLAG_PID_CGROUP = 0x4
+ PERF_FLAG_FD_CLOEXEC = 0x8
)
const (
@@ -1412,6 +1444,9 @@
SizeofTpacketHdr = 0x20
SizeofTpacket2Hdr = 0x20
SizeofTpacket3Hdr = 0x30
+
+ SizeofTpacketStats = 0x8
+ SizeofTpacketStatsV3 = 0xc
)
const (
@@ -2028,3 +2063,18 @@
Info uint32
Data uint32
}
+
+type FanotifyEventMetadata struct {
+ Event_len uint32
+ Vers uint8
+ Reserved uint8
+ Metadata_len uint16
+ Mask uint64
+ Fd int32
+ Pid int32
+}
+
+type FanotifyResponse struct {
+ Fd int32
+ Response uint32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_openbsd_386.go b/vendor/golang.org/x/sys/unix/ztypes_openbsd_386.go
index 8b37d83..900fb44 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_openbsd_386.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_openbsd_386.go
@@ -558,3 +558,13 @@
Fpswtch int32
Kmapent int32
}
+
+const SizeofClockinfo = 0x14
+
+type Clockinfo struct {
+ Hz int32
+ Tick int32
+ Tickadj int32
+ Stathz int32
+ Profhz int32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_openbsd_amd64.go b/vendor/golang.org/x/sys/unix/ztypes_openbsd_amd64.go
index 6efea46..028fa78 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_openbsd_amd64.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_openbsd_amd64.go
@@ -558,3 +558,13 @@
Fpswtch int32
Kmapent int32
}
+
+const SizeofClockinfo = 0x14
+
+type Clockinfo struct {
+ Hz int32
+ Tick int32
+ Tickadj int32
+ Stathz int32
+ Profhz int32
+}
diff --git a/vendor/golang.org/x/sys/unix/ztypes_openbsd_arm.go b/vendor/golang.org/x/sys/unix/ztypes_openbsd_arm.go
index 510efc3..b45d5ee 100644
--- a/vendor/golang.org/x/sys/unix/ztypes_openbsd_arm.go
+++ b/vendor/golang.org/x/sys/unix/ztypes_openbsd_arm.go
@@ -559,3 +559,13 @@
Fpswtch int32
Kmapent int32
}
+
+const SizeofClockinfo = 0x14
+
+type Clockinfo struct {
+ Hz int32
+ Tick int32
+ Tickadj int32
+ Stathz int32
+ Profhz int32
+}
diff --git a/vendor/golang.org/x/sys/windows/dll_windows.go b/vendor/golang.org/x/sys/windows/dll_windows.go
index e92c05b..ba67658 100644
--- a/vendor/golang.org/x/sys/windows/dll_windows.go
+++ b/vendor/golang.org/x/sys/windows/dll_windows.go
@@ -359,11 +359,11 @@
// trying to load "foo.dll" out of the system
// folder, but LoadLibraryEx doesn't support
// that yet on their system, so emulate it.
- windir, _ := Getenv("WINDIR") // old var; apparently works on XP
- if windir == "" {
- return nil, errString("%WINDIR% not defined")
+ systemdir, err := GetSystemDirectory()
+ if err != nil {
+ return nil, err
}
- loadDLL = windir + "\\System32\\" + name
+ loadDLL = systemdir + "\\" + name
}
}
h, err := LoadLibraryEx(loadDLL, 0, flags)
diff --git a/vendor/golang.org/x/sys/windows/security_windows.go b/vendor/golang.org/x/sys/windows/security_windows.go
index 9f946da..da06406 100644
--- a/vendor/golang.org/x/sys/windows/security_windows.go
+++ b/vendor/golang.org/x/sys/windows/security_windows.go
@@ -169,6 +169,7 @@
//sys GetLengthSid(sid *SID) (len uint32) = advapi32.GetLengthSid
//sys CopySid(destSidLen uint32, destSid *SID, srcSid *SID) (err error) = advapi32.CopySid
//sys AllocateAndInitializeSid(identAuth *SidIdentifierAuthority, subAuth byte, subAuth0 uint32, subAuth1 uint32, subAuth2 uint32, subAuth3 uint32, subAuth4 uint32, subAuth5 uint32, subAuth6 uint32, subAuth7 uint32, sid **SID) (err error) = advapi32.AllocateAndInitializeSid
+//sys createWellKnownSid(sidType WELL_KNOWN_SID_TYPE, domainSid *SID, sid *SID, sizeSid *uint32) (err error) = advapi32.CreateWellKnownSid
//sys FreeSid(sid *SID) (err error) [failretval!=0] = advapi32.FreeSid
//sys EqualSid(sid1 *SID, sid2 *SID) (isEqual bool) = advapi32.EqualSid
@@ -286,6 +287,158 @@
}
}
+// Various types of pre-specified sids that can be synthesized at runtime.
+type WELL_KNOWN_SID_TYPE uint32
+
+const (
+ WinNullSid = 0
+ WinWorldSid = 1
+ WinLocalSid = 2
+ WinCreatorOwnerSid = 3
+ WinCreatorGroupSid = 4
+ WinCreatorOwnerServerSid = 5
+ WinCreatorGroupServerSid = 6
+ WinNtAuthoritySid = 7
+ WinDialupSid = 8
+ WinNetworkSid = 9
+ WinBatchSid = 10
+ WinInteractiveSid = 11
+ WinServiceSid = 12
+ WinAnonymousSid = 13
+ WinProxySid = 14
+ WinEnterpriseControllersSid = 15
+ WinSelfSid = 16
+ WinAuthenticatedUserSid = 17
+ WinRestrictedCodeSid = 18
+ WinTerminalServerSid = 19
+ WinRemoteLogonIdSid = 20
+ WinLogonIdsSid = 21
+ WinLocalSystemSid = 22
+ WinLocalServiceSid = 23
+ WinNetworkServiceSid = 24
+ WinBuiltinDomainSid = 25
+ WinBuiltinAdministratorsSid = 26
+ WinBuiltinUsersSid = 27
+ WinBuiltinGuestsSid = 28
+ WinBuiltinPowerUsersSid = 29
+ WinBuiltinAccountOperatorsSid = 30
+ WinBuiltinSystemOperatorsSid = 31
+ WinBuiltinPrintOperatorsSid = 32
+ WinBuiltinBackupOperatorsSid = 33
+ WinBuiltinReplicatorSid = 34
+ WinBuiltinPreWindows2000CompatibleAccessSid = 35
+ WinBuiltinRemoteDesktopUsersSid = 36
+ WinBuiltinNetworkConfigurationOperatorsSid = 37
+ WinAccountAdministratorSid = 38
+ WinAccountGuestSid = 39
+ WinAccountKrbtgtSid = 40
+ WinAccountDomainAdminsSid = 41
+ WinAccountDomainUsersSid = 42
+ WinAccountDomainGuestsSid = 43
+ WinAccountComputersSid = 44
+ WinAccountControllersSid = 45
+ WinAccountCertAdminsSid = 46
+ WinAccountSchemaAdminsSid = 47
+ WinAccountEnterpriseAdminsSid = 48
+ WinAccountPolicyAdminsSid = 49
+ WinAccountRasAndIasServersSid = 50
+ WinNTLMAuthenticationSid = 51
+ WinDigestAuthenticationSid = 52
+ WinSChannelAuthenticationSid = 53
+ WinThisOrganizationSid = 54
+ WinOtherOrganizationSid = 55
+ WinBuiltinIncomingForestTrustBuildersSid = 56
+ WinBuiltinPerfMonitoringUsersSid = 57
+ WinBuiltinPerfLoggingUsersSid = 58
+ WinBuiltinAuthorizationAccessSid = 59
+ WinBuiltinTerminalServerLicenseServersSid = 60
+ WinBuiltinDCOMUsersSid = 61
+ WinBuiltinIUsersSid = 62
+ WinIUserSid = 63
+ WinBuiltinCryptoOperatorsSid = 64
+ WinUntrustedLabelSid = 65
+ WinLowLabelSid = 66
+ WinMediumLabelSid = 67
+ WinHighLabelSid = 68
+ WinSystemLabelSid = 69
+ WinWriteRestrictedCodeSid = 70
+ WinCreatorOwnerRightsSid = 71
+ WinCacheablePrincipalsGroupSid = 72
+ WinNonCacheablePrincipalsGroupSid = 73
+ WinEnterpriseReadonlyControllersSid = 74
+ WinAccountReadonlyControllersSid = 75
+ WinBuiltinEventLogReadersGroup = 76
+ WinNewEnterpriseReadonlyControllersSid = 77
+ WinBuiltinCertSvcDComAccessGroup = 78
+ WinMediumPlusLabelSid = 79
+ WinLocalLogonSid = 80
+ WinConsoleLogonSid = 81
+ WinThisOrganizationCertificateSid = 82
+ WinApplicationPackageAuthoritySid = 83
+ WinBuiltinAnyPackageSid = 84
+ WinCapabilityInternetClientSid = 85
+ WinCapabilityInternetClientServerSid = 86
+ WinCapabilityPrivateNetworkClientServerSid = 87
+ WinCapabilityPicturesLibrarySid = 88
+ WinCapabilityVideosLibrarySid = 89
+ WinCapabilityMusicLibrarySid = 90
+ WinCapabilityDocumentsLibrarySid = 91
+ WinCapabilitySharedUserCertificatesSid = 92
+ WinCapabilityEnterpriseAuthenticationSid = 93
+ WinCapabilityRemovableStorageSid = 94
+ WinBuiltinRDSRemoteAccessServersSid = 95
+ WinBuiltinRDSEndpointServersSid = 96
+ WinBuiltinRDSManagementServersSid = 97
+ WinUserModeDriversSid = 98
+ WinBuiltinHyperVAdminsSid = 99
+ WinAccountCloneableControllersSid = 100
+ WinBuiltinAccessControlAssistanceOperatorsSid = 101
+ WinBuiltinRemoteManagementUsersSid = 102
+ WinAuthenticationAuthorityAssertedSid = 103
+ WinAuthenticationServiceAssertedSid = 104
+ WinLocalAccountSid = 105
+ WinLocalAccountAndAdministratorSid = 106
+ WinAccountProtectedUsersSid = 107
+ WinCapabilityAppointmentsSid = 108
+ WinCapabilityContactsSid = 109
+ WinAccountDefaultSystemManagedSid = 110
+ WinBuiltinDefaultSystemManagedGroupSid = 111
+ WinBuiltinStorageReplicaAdminsSid = 112
+ WinAccountKeyAdminsSid = 113
+ WinAccountEnterpriseKeyAdminsSid = 114
+ WinAuthenticationKeyTrustSid = 115
+ WinAuthenticationKeyPropertyMFASid = 116
+ WinAuthenticationKeyPropertyAttestationSid = 117
+ WinAuthenticationFreshKeyAuthSid = 118
+ WinBuiltinDeviceOwnersSid = 119
+)
+
+// Creates a sid for a well-known predefined alias, generally using the constants of the form
+// Win*Sid, for the local machine.
+func CreateWellKnownSid(sidType WELL_KNOWN_SID_TYPE) (*SID, error) {
+ return CreateWellKnownDomainSid(sidType, nil)
+}
+
+// Creates a sid for a well-known predefined alias, generally using the constants of the form
+// Win*Sid, for the domain specified by the domainSid parameter.
+func CreateWellKnownDomainSid(sidType WELL_KNOWN_SID_TYPE, domainSid *SID) (*SID, error) {
+ n := uint32(50)
+ for {
+ b := make([]byte, n)
+ sid := (*SID)(unsafe.Pointer(&b[0]))
+ err := createWellKnownSid(sidType, domainSid, sid, &n)
+ if err == nil {
+ return sid, nil
+ }
+ if err != ERROR_INSUFFICIENT_BUFFER {
+ return nil, err
+ }
+ if n <= uint32(len(b)) {
+ return nil, err
+ }
+ }
+}
+
const (
// do not reorder
TOKEN_ASSIGN_PRIMARY = 1 << iota
@@ -372,6 +525,7 @@
//sys OpenProcessToken(h Handle, access uint32, token *Token) (err error) = advapi32.OpenProcessToken
//sys GetTokenInformation(t Token, infoClass uint32, info *byte, infoLen uint32, returnedLen *uint32) (err error) = advapi32.GetTokenInformation
//sys GetUserProfileDirectory(t Token, dir *uint16, dirLen *uint32) (err error) = userenv.GetUserProfileDirectoryW
+//sys getSystemDirectory(dir *uint16, dirLen uint32) (len uint32, err error) = kernel32.GetSystemDirectoryW
// An access token contains the security information for a logon session.
// The system creates an access token when a user logs on, and every
@@ -468,6 +622,23 @@
}
}
+// GetSystemDirectory retrieves path to current location of the system
+// directory, which is typically, though not always, C:\Windows\System32.
+func GetSystemDirectory() (string, error) {
+ n := uint32(MAX_PATH)
+ for {
+ b := make([]uint16, n)
+ l, e := getSystemDirectory(&b[0], n)
+ if e != nil {
+ return "", e
+ }
+ if l <= n {
+ return UTF16ToString(b[:l]), nil
+ }
+ n = l
+ }
+}
+
// IsMember reports whether the access token t is a member of the provided SID.
func (t Token) IsMember(sid *SID) (bool, error) {
var b int32
diff --git a/vendor/golang.org/x/sys/windows/syscall_windows.go b/vendor/golang.org/x/sys/windows/syscall_windows.go
index f72fa55..7aff0d0 100644
--- a/vendor/golang.org/x/sys/windows/syscall_windows.go
+++ b/vendor/golang.org/x/sys/windows/syscall_windows.go
@@ -137,6 +137,7 @@
//sys CreateFile(name *uint16, access uint32, mode uint32, sa *SecurityAttributes, createmode uint32, attrs uint32, templatefile int32) (handle Handle, err error) [failretval==InvalidHandle] = CreateFileW
//sys ReadFile(handle Handle, buf []byte, done *uint32, overlapped *Overlapped) (err error)
//sys WriteFile(handle Handle, buf []byte, done *uint32, overlapped *Overlapped) (err error)
+//sys GetOverlappedResult(handle Handle, overlapped *Overlapped, done *uint32, wait bool) (err error)
//sys SetFilePointer(handle Handle, lowoffset int32, highoffsetptr *int32, whence uint32) (newlowoffset uint32, err error) [failretval==0xffffffff]
//sys CloseHandle(handle Handle) (err error)
//sys GetStdHandle(stdhandle uint32) (handle Handle, err error) [failretval==InvalidHandle]
diff --git a/vendor/golang.org/x/sys/windows/types_windows.go b/vendor/golang.org/x/sys/windows/types_windows.go
index 141ca81..bbf19f0 100644
--- a/vendor/golang.org/x/sys/windows/types_windows.go
+++ b/vendor/golang.org/x/sys/windows/types_windows.go
@@ -126,9 +126,19 @@
OPEN_ALWAYS = 4
TRUNCATE_EXISTING = 5
- FILE_FLAG_OPEN_REPARSE_POINT = 0x00200000
- FILE_FLAG_BACKUP_SEMANTICS = 0x02000000
- FILE_FLAG_OVERLAPPED = 0x40000000
+ FILE_FLAG_OPEN_REQUIRING_OPLOCK = 0x00040000
+ FILE_FLAG_FIRST_PIPE_INSTANCE = 0x00080000
+ FILE_FLAG_OPEN_NO_RECALL = 0x00100000
+ FILE_FLAG_OPEN_REPARSE_POINT = 0x00200000
+ FILE_FLAG_SESSION_AWARE = 0x00800000
+ FILE_FLAG_POSIX_SEMANTICS = 0x01000000
+ FILE_FLAG_BACKUP_SEMANTICS = 0x02000000
+ FILE_FLAG_DELETE_ON_CLOSE = 0x04000000
+ FILE_FLAG_SEQUENTIAL_SCAN = 0x08000000
+ FILE_FLAG_RANDOM_ACCESS = 0x10000000
+ FILE_FLAG_NO_BUFFERING = 0x20000000
+ FILE_FLAG_OVERLAPPED = 0x40000000
+ FILE_FLAG_WRITE_THROUGH = 0x80000000
HANDLE_FLAG_INHERIT = 0x00000001
STARTF_USESTDHANDLES = 0x00000100
diff --git a/vendor/golang.org/x/sys/windows/zsyscall_windows.go b/vendor/golang.org/x/sys/windows/zsyscall_windows.go
index e4b54e2..eb9f062 100644
--- a/vendor/golang.org/x/sys/windows/zsyscall_windows.go
+++ b/vendor/golang.org/x/sys/windows/zsyscall_windows.go
@@ -77,6 +77,7 @@
procCreateFileW = modkernel32.NewProc("CreateFileW")
procReadFile = modkernel32.NewProc("ReadFile")
procWriteFile = modkernel32.NewProc("WriteFile")
+ procGetOverlappedResult = modkernel32.NewProc("GetOverlappedResult")
procSetFilePointer = modkernel32.NewProc("SetFilePointer")
procCloseHandle = modkernel32.NewProc("CloseHandle")
procGetStdHandle = modkernel32.NewProc("GetStdHandle")
@@ -246,12 +247,14 @@
procGetLengthSid = modadvapi32.NewProc("GetLengthSid")
procCopySid = modadvapi32.NewProc("CopySid")
procAllocateAndInitializeSid = modadvapi32.NewProc("AllocateAndInitializeSid")
+ procCreateWellKnownSid = modadvapi32.NewProc("CreateWellKnownSid")
procFreeSid = modadvapi32.NewProc("FreeSid")
procEqualSid = modadvapi32.NewProc("EqualSid")
procCheckTokenMembership = modadvapi32.NewProc("CheckTokenMembership")
procOpenProcessToken = modadvapi32.NewProc("OpenProcessToken")
procGetTokenInformation = modadvapi32.NewProc("GetTokenInformation")
procGetUserProfileDirectoryW = moduserenv.NewProc("GetUserProfileDirectoryW")
+ procGetSystemDirectoryW = modkernel32.NewProc("GetSystemDirectoryW")
)
func RegisterEventSource(uncServerName *uint16, sourceName *uint16) (handle Handle, err error) {
@@ -652,6 +655,24 @@
return
}
+func GetOverlappedResult(handle Handle, overlapped *Overlapped, done *uint32, wait bool) (err error) {
+ var _p0 uint32
+ if wait {
+ _p0 = 1
+ } else {
+ _p0 = 0
+ }
+ r1, _, e1 := syscall.Syscall6(procGetOverlappedResult.Addr(), 4, uintptr(handle), uintptr(unsafe.Pointer(overlapped)), uintptr(unsafe.Pointer(done)), uintptr(_p0), 0, 0)
+ if r1 == 0 {
+ if e1 != 0 {
+ err = errnoErr(e1)
+ } else {
+ err = syscall.EINVAL
+ }
+ }
+ return
+}
+
func SetFilePointer(handle Handle, lowoffset int32, highoffsetptr *int32, whence uint32) (newlowoffset uint32, err error) {
r0, _, e1 := syscall.Syscall6(procSetFilePointer.Addr(), 4, uintptr(handle), uintptr(lowoffset), uintptr(unsafe.Pointer(highoffsetptr)), uintptr(whence), 0, 0)
newlowoffset = uint32(r0)
@@ -2653,6 +2674,18 @@
return
}
+func createWellKnownSid(sidType WELL_KNOWN_SID_TYPE, domainSid *SID, sid *SID, sizeSid *uint32) (err error) {
+ r1, _, e1 := syscall.Syscall6(procCreateWellKnownSid.Addr(), 4, uintptr(sidType), uintptr(unsafe.Pointer(domainSid)), uintptr(unsafe.Pointer(sid)), uintptr(unsafe.Pointer(sizeSid)), 0, 0)
+ if r1 == 0 {
+ if e1 != 0 {
+ err = errnoErr(e1)
+ } else {
+ err = syscall.EINVAL
+ }
+ }
+ return
+}
+
func FreeSid(sid *SID) (err error) {
r1, _, e1 := syscall.Syscall(procFreeSid.Addr(), 1, uintptr(unsafe.Pointer(sid)), 0, 0)
if r1 != 0 {
@@ -2718,3 +2751,16 @@
}
return
}
+
+func getSystemDirectory(dir *uint16, dirLen uint32) (len uint32, err error) {
+ r0, _, e1 := syscall.Syscall(procGetSystemDirectoryW.Addr(), 2, uintptr(unsafe.Pointer(dir)), uintptr(dirLen), 0)
+ len = uint32(r0)
+ if len == 0 {
+ if e1 != 0 {
+ err = errnoErr(e1)
+ } else {
+ err = syscall.EINVAL
+ }
+ }
+ return
+}
diff --git a/vendor/google.golang.org/appengine/internal/api.go b/vendor/google.golang.org/appengine/internal/api.go
index bbc1cb9..a6ec19e 100644
--- a/vendor/google.golang.org/appengine/internal/api.go
+++ b/vendor/google.golang.org/appengine/internal/api.go
@@ -44,6 +44,7 @@
curNamespaceHeader = http.CanonicalHeaderKey("X-AppEngine-Current-Namespace")
userIPHeader = http.CanonicalHeaderKey("X-AppEngine-User-IP")
remoteAddrHeader = http.CanonicalHeaderKey("X-AppEngine-Remote-Addr")
+ devRequestIdHeader = http.CanonicalHeaderKey("X-Appengine-Dev-Request-Id")
// Outgoing headers.
apiEndpointHeader = http.CanonicalHeaderKey("X-Google-RPC-Service-Endpoint")
@@ -494,6 +495,9 @@
if ticket == "" {
ticket = DefaultTicket()
}
+ if dri := c.req.Header.Get(devRequestIdHeader); IsDevAppServer() && dri != "" {
+ ticket = dri
+ }
req := &remotepb.Request{
ServiceName: &service,
Method: &method,
diff --git a/vendor/google.golang.org/genproto/googleapis/rpc/status/status.pb.go b/vendor/google.golang.org/genproto/googleapis/rpc/status/status.pb.go
index 7bfe37a..57ae35f 100644
--- a/vendor/google.golang.org/genproto/googleapis/rpc/status/status.pb.go
+++ b/vendor/google.golang.org/genproto/googleapis/rpc/status/status.pb.go
@@ -19,24 +19,25 @@
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
-// The `Status` type defines a logical error model that is suitable for different
-// programming environments, including REST APIs and RPC APIs. It is used by
-// [gRPC](https://github.com/grpc). The error model is designed to be:
+// The `Status` type defines a logical error model that is suitable for
+// different programming environments, including REST APIs and RPC APIs. It is
+// used by [gRPC](https://github.com/grpc). The error model is designed to be:
//
// - Simple to use and understand for most users
// - Flexible enough to meet unexpected needs
//
// # Overview
//
-// The `Status` message contains three pieces of data: error code, error message,
-// and error details. The error code should be an enum value of
-// [google.rpc.Code][google.rpc.Code], but it may accept additional error codes if needed. The
-// error message should be a developer-facing English message that helps
-// developers *understand* and *resolve* the error. If a localized user-facing
-// error message is needed, put the localized message in the error details or
-// localize it in the client. The optional error details may contain arbitrary
-// information about the error. There is a predefined set of error detail types
-// in the package `google.rpc` that can be used for common error conditions.
+// The `Status` message contains three pieces of data: error code, error
+// message, and error details. The error code should be an enum value of
+// [google.rpc.Code][google.rpc.Code], but it may accept additional error codes
+// if needed. The error message should be a developer-facing English message
+// that helps developers *understand* and *resolve* the error. If a localized
+// user-facing error message is needed, put the localized message in the error
+// details or localize it in the client. The optional error details may contain
+// arbitrary information about the error. There is a predefined set of error
+// detail types in the package `google.rpc` that can be used for common error
+// conditions.
//
// # Language mapping
//
@@ -72,11 +73,13 @@
// - Logging. If some API errors are stored in logs, the message `Status` could
// be used directly after any stripping needed for security/privacy reasons.
type Status struct {
- // The status code, which should be an enum value of [google.rpc.Code][google.rpc.Code].
+ // The status code, which should be an enum value of
+ // [google.rpc.Code][google.rpc.Code].
Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
// A developer-facing error message, which should be in English. Any
// user-facing error message should be localized and sent in the
- // [google.rpc.Status.details][google.rpc.Status.details] field, or localized by the client.
+ // [google.rpc.Status.details][google.rpc.Status.details] field, or localized
+ // by the client.
Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
// A list of messages that carry the error details. There is a common set of
// message types for APIs to use.
@@ -90,7 +93,7 @@
func (m *Status) String() string { return proto.CompactTextString(m) }
func (*Status) ProtoMessage() {}
func (*Status) Descriptor() ([]byte, []int) {
- return fileDescriptor_status_c6e4de62dcdf2edf, []int{0}
+ return fileDescriptor_status_ced6ddf76350620b, []int{0}
}
func (m *Status) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Status.Unmarshal(m, b)
@@ -135,9 +138,9 @@
proto.RegisterType((*Status)(nil), "google.rpc.Status")
}
-func init() { proto.RegisterFile("google/rpc/status.proto", fileDescriptor_status_c6e4de62dcdf2edf) }
+func init() { proto.RegisterFile("google/rpc/status.proto", fileDescriptor_status_ced6ddf76350620b) }
-var fileDescriptor_status_c6e4de62dcdf2edf = []byte{
+var fileDescriptor_status_ced6ddf76350620b = []byte{
// 209 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x12, 0x4f, 0xcf, 0xcf, 0x4f,
0xcf, 0x49, 0xd5, 0x2f, 0x2a, 0x48, 0xd6, 0x2f, 0x2e, 0x49, 0x2c, 0x29, 0x2d, 0xd6, 0x2b, 0x28,
diff --git a/vendor/google.golang.org/grpc/.travis.yml b/vendor/google.golang.org/grpc/.travis.yml
index f443eec..8f36b81 100644
--- a/vendor/google.golang.org/grpc/.travis.yml
+++ b/vendor/google.golang.org/grpc/.travis.yml
@@ -2,6 +2,8 @@
matrix:
include:
+ - go: 1.12beta2
+ env: GO111MODULE=on
- go: 1.11.x
env: VET=1 GO111MODULE=on
- go: 1.11.x
diff --git a/vendor/google.golang.org/grpc/CONTRIBUTING.md b/vendor/google.golang.org/grpc/CONTRIBUTING.md
index 0863eb2..ca34e8a 100644
--- a/vendor/google.golang.org/grpc/CONTRIBUTING.md
+++ b/vendor/google.golang.org/grpc/CONTRIBUTING.md
@@ -31,6 +31,7 @@
- `make vet` to catch vet errors
- `make test` to run the tests
- `make testrace` to run tests in race mode
+ - optional `make testappengine` to run tests with appengine
- Exceptions to the rules can be made if there's a compelling reason for doing so.
diff --git a/vendor/google.golang.org/grpc/Makefile b/vendor/google.golang.org/grpc/Makefile
index 41a754f..db982aa 100644
--- a/vendor/google.golang.org/grpc/Makefile
+++ b/vendor/google.golang.org/grpc/Makefile
@@ -1,4 +1,4 @@
-all: vet test testrace testappengine
+all: vet test testrace
build: deps
go build google.golang.org/grpc/...
diff --git a/vendor/google.golang.org/grpc/README.md b/vendor/google.golang.org/grpc/README.md
index e3fb3c7..f5eec67 100644
--- a/vendor/google.golang.org/grpc/README.md
+++ b/vendor/google.golang.org/grpc/README.md
@@ -20,7 +20,7 @@
Constraints
-----------
-The grpc package should only depend on standard Go packages and a small number of exceptions. If your contribution introduces new dependencies which are NOT in the [list](http://godoc.org/google.golang.org/grpc?imports), you need a discussion with gRPC-Go authors and consultants.
+The grpc package should only depend on standard Go packages and a small number of exceptions. If your contribution introduces new dependencies which are NOT in the [list](https://godoc.org/google.golang.org/grpc?imports), you need a discussion with gRPC-Go authors and consultants.
Documentation
-------------
diff --git a/vendor/google.golang.org/grpc/backoff.go b/vendor/google.golang.org/grpc/backoff.go
index fa31565..97c6e25 100644
--- a/vendor/google.golang.org/grpc/backoff.go
+++ b/vendor/google.golang.org/grpc/backoff.go
@@ -17,7 +17,7 @@
*/
// See internal/backoff package for the backoff implementation. This file is
-// kept for the exported types and API backward compatility.
+// kept for the exported types and API backward compatibility.
package grpc
diff --git a/vendor/google.golang.org/grpc/balancer/balancer.go b/vendor/google.golang.org/grpc/balancer/balancer.go
index 317c2e7..67518de 100644
--- a/vendor/google.golang.org/grpc/balancer/balancer.go
+++ b/vendor/google.golang.org/grpc/balancer/balancer.go
@@ -61,7 +61,7 @@
}
// Get returns the resolver builder registered with the given name.
-// Note that the compare is done in a case-insenstive fashion.
+// Note that the compare is done in a case-insensitive fashion.
// If no builder is register with the name, nil will be returned.
func Get(name string) Builder {
if b, ok := m[strings.ToLower(name)]; ok {
@@ -127,7 +127,7 @@
// The SubConn will be shutdown.
RemoveSubConn(SubConn)
- // UpdateBalancerState is called by balancer to nofity gRPC that some internal
+ // UpdateBalancerState is called by balancer to notify gRPC that some internal
// state in balancer has changed.
//
// gRPC will update the connectivity state of the ClientConn, and will call pick
@@ -227,9 +227,10 @@
// - Else (error is other non-nil error):
// - The RPC will fail with unavailable error.
//
- // The returned done() function will be called once the rpc has finished, with the
- // final status of that RPC.
- // done may be nil if balancer doesn't care about the RPC status.
+ // The returned done() function will be called once the rpc has finished,
+ // with the final status of that RPC. If the SubConn returned is not a
+ // valid SubConn type, done may not be called. done may be nil if balancer
+ // doesn't care about the RPC status.
Pick(ctx context.Context, opts PickOptions) (conn SubConn, done func(DoneInfo), err error)
}
diff --git a/vendor/google.golang.org/grpc/balancer/roundrobin/roundrobin.go b/vendor/google.golang.org/grpc/balancer/roundrobin/roundrobin.go
index 57aea9f..29f7a4d 100644
--- a/vendor/google.golang.org/grpc/balancer/roundrobin/roundrobin.go
+++ b/vendor/google.golang.org/grpc/balancer/roundrobin/roundrobin.go
@@ -28,6 +28,7 @@
"google.golang.org/grpc/balancer"
"google.golang.org/grpc/balancer/base"
"google.golang.org/grpc/grpclog"
+ "google.golang.org/grpc/internal/grpcrand"
"google.golang.org/grpc/resolver"
)
@@ -47,12 +48,19 @@
func (*rrPickerBuilder) Build(readySCs map[resolver.Address]balancer.SubConn) balancer.Picker {
grpclog.Infof("roundrobinPicker: newPicker called with readySCs: %v", readySCs)
+ if len(readySCs) == 0 {
+ return base.NewErrPicker(balancer.ErrNoSubConnAvailable)
+ }
var scs []balancer.SubConn
for _, sc := range readySCs {
scs = append(scs, sc)
}
return &rrPicker{
subConns: scs,
+ // Start at a random index, as the same RR balancer rebuilds a new
+ // picker when SubConn states change, and we don't want to apply excess
+ // load to the first server in the list.
+ next: grpcrand.Intn(len(scs)),
}
}
@@ -67,10 +75,6 @@
}
func (p *rrPicker) Pick(ctx context.Context, opts balancer.PickOptions) (balancer.SubConn, func(balancer.DoneInfo), error) {
- if len(p.subConns) <= 0 {
- return nil, nil, balancer.ErrNoSubConnAvailable
- }
-
p.mu.Lock()
sc := p.subConns[p.next]
p.next = (p.next + 1) % len(p.subConns)
diff --git a/vendor/google.golang.org/grpc/balancer_v1_wrapper.go b/vendor/google.golang.org/grpc/balancer_v1_wrapper.go
index 42b60fe..29bda63 100644
--- a/vendor/google.golang.org/grpc/balancer_v1_wrapper.go
+++ b/vendor/google.golang.org/grpc/balancer_v1_wrapper.go
@@ -281,9 +281,8 @@
}
// The picker is the balancerWrapper itself.
-// Pick should never return ErrNoSubConnAvailable.
// It either blocks or returns error, consistent with v1 balancer Get().
-func (bw *balancerWrapper) Pick(ctx context.Context, opts balancer.PickOptions) (balancer.SubConn, func(balancer.DoneInfo), error) {
+func (bw *balancerWrapper) Pick(ctx context.Context, opts balancer.PickOptions) (sc balancer.SubConn, done func(balancer.DoneInfo), err error) {
failfast := true // Default failfast is true.
if ss, ok := rpcInfoFromContext(ctx); ok {
failfast = ss.failfast
@@ -292,35 +291,51 @@
if err != nil {
return nil, nil, err
}
- var done func(balancer.DoneInfo)
if p != nil {
- done = func(i balancer.DoneInfo) { p() }
+ done = func(balancer.DoneInfo) { p() }
+ defer func() {
+ if err != nil {
+ p()
+ }
+ }()
}
- var sc balancer.SubConn
+
bw.mu.Lock()
defer bw.mu.Unlock()
if bw.pickfirst {
// Get the first sc in conns.
- for _, sc = range bw.conns {
- break
+ for _, sc := range bw.conns {
+ return sc, done, nil
}
- } else {
- var ok bool
- sc, ok = bw.conns[resolver.Address{
- Addr: a.Addr,
- Type: resolver.Backend,
- ServerName: "",
- Metadata: a.Metadata,
- }]
- if !ok && failfast {
- return nil, nil, balancer.ErrTransientFailure
- }
- if s, ok := bw.connSt[sc]; failfast && (!ok || s.s != connectivity.Ready) {
- // If the returned sc is not ready and RPC is failfast,
- // return error, and this RPC will fail.
- return nil, nil, balancer.ErrTransientFailure
- }
+ return nil, nil, balancer.ErrNoSubConnAvailable
}
-
- return sc, done, nil
+ sc, ok1 := bw.conns[resolver.Address{
+ Addr: a.Addr,
+ Type: resolver.Backend,
+ ServerName: "",
+ Metadata: a.Metadata,
+ }]
+ s, ok2 := bw.connSt[sc]
+ if !ok1 || !ok2 {
+ // This can only happen due to a race where Get() returned an address
+ // that was subsequently removed by Notify. In this case we should
+ // retry always.
+ return nil, nil, balancer.ErrNoSubConnAvailable
+ }
+ switch s.s {
+ case connectivity.Ready, connectivity.Idle:
+ return sc, done, nil
+ case connectivity.Shutdown, connectivity.TransientFailure:
+ // If the returned sc has been shut down or is in transient failure,
+ // return error, and this RPC will fail or wait for another picker (if
+ // non-failfast).
+ return nil, nil, balancer.ErrTransientFailure
+ default:
+ // For other states (connecting or unknown), the v1 balancer would
+ // traditionally wait until ready and then issue the RPC. Returning
+ // ErrNoSubConnAvailable will be a slight improvement in that it will
+ // allow the balancer to choose another address in case others are
+ // connected.
+ return nil, nil, balancer.ErrNoSubConnAvailable
+ }
}
diff --git a/vendor/google.golang.org/grpc/call.go b/vendor/google.golang.org/grpc/call.go
index 100f05d..9e20e4d 100644
--- a/vendor/google.golang.org/grpc/call.go
+++ b/vendor/google.golang.org/grpc/call.go
@@ -40,7 +40,7 @@
func combine(o1 []CallOption, o2 []CallOption) []CallOption {
// we don't use append because o1 could have extra capacity whose
// elements would be overwritten, which could cause inadvertent
- // sharing (and race connditions) between concurrent calls
+ // sharing (and race conditions) between concurrent calls
if len(o1) == 0 {
return o2
} else if len(o2) == 0 {
diff --git a/vendor/google.golang.org/grpc/clientconn.go b/vendor/google.golang.org/grpc/clientconn.go
index 56d0bf7..df1bb94 100644
--- a/vendor/google.golang.org/grpc/clientconn.go
+++ b/vendor/google.golang.org/grpc/clientconn.go
@@ -86,7 +86,7 @@
// with other individual Transport Credentials.
errTransportCredsAndBundle = errors.New("grpc: credentials.Bundle may not be used with individual TransportCredentials")
// errTransportCredentialsMissing indicates that users want to transmit security
- // information (e.g., oauth2 token) which requires secure connection on an insecure
+ // information (e.g., OAuth2 token) which requires secure connection on an insecure
// connection.
errTransportCredentialsMissing = errors.New("grpc: the credentials require transport level security (use grpc.WithTransportCredentials() to set)")
// errCredentialsConflict indicates that grpc.WithTransportCredentials()
@@ -237,9 +237,9 @@
grpclog.Infof("parsed scheme: %q", cc.parsedTarget.Scheme)
cc.dopts.resolverBuilder = resolver.Get(cc.parsedTarget.Scheme)
if cc.dopts.resolverBuilder == nil {
- // If resolver builder is still nil, the parse target's scheme is
+ // If resolver builder is still nil, the parsed target's scheme is
// not registered. Fallback to default resolver and set Endpoint to
- // the original unparsed target.
+ // the original target.
grpclog.Infof("scheme %q not registered, fallback to default scheme", cc.parsedTarget.Scheme)
cc.parsedTarget = resolver.Target{
Scheme: resolver.GetDefaultScheme(),
@@ -436,7 +436,7 @@
}
cc.mu.Lock()
// TODO: load balance policy runtime change is ignored.
- // We may revist this decision in the future.
+ // We may revisit this decision in the future.
cc.sc = sc
cc.scRaw = ""
cc.mu.Unlock()
@@ -926,9 +926,8 @@
backoffIdx int // Needs to be stateful for resetConnectBackoff.
resetBackoff chan struct{}
- channelzID int64 // channelz unique identification number.
- czData *channelzData
- healthCheckEnabled bool
+ channelzID int64 // channelz unique identification number.
+ czData *channelzData
}
// Note: this requires a lock on ac.mu.
@@ -938,7 +937,6 @@
}
updateMsg := fmt.Sprintf("Subchannel Connectivity change to %v", s)
- grpclog.Infof(updateMsg)
ac.state = s
if channelz.IsOn() {
channelz.AddTraceEvent(ac.channelzID, &channelz.TraceEventDesc{
@@ -973,6 +971,14 @@
}
addrs := ac.addrs
backoffFor := ac.dopts.bs.Backoff(ac.backoffIdx)
+
+ // This will be the duration that dial gets to finish.
+ dialDuration := getMinConnectTimeout()
+ if dialDuration < backoffFor {
+ // Give dial more time as we keep failing to connect.
+ dialDuration = backoffFor
+ }
+ connectDeadline := time.Now().Add(dialDuration)
ac.mu.Unlock()
addrLoop:
@@ -985,17 +991,7 @@
}
ac.updateConnectivityState(connectivity.Connecting)
ac.transport = nil
- ac.mu.Unlock()
- // This will be the duration that dial gets to finish.
- dialDuration := getMinConnectTimeout()
- if dialDuration < backoffFor {
- // Give dial more time as we keep failing to connect.
- dialDuration = backoffFor
- }
- connectDeadline := time.Now().Add(dialDuration)
-
- ac.mu.Lock()
ac.cc.mu.RLock()
ac.dopts.copts.KeepaliveParams = ac.cc.mkp
ac.cc.mu.RUnlock()
@@ -1063,6 +1059,7 @@
continue
}
+ backoffFor = 0
ac.mu.Lock()
reqHandshake := ac.dopts.reqHandshake
ac.mu.Unlock()
@@ -1158,7 +1155,7 @@
Authority: ac.cc.authority,
}
- prefaceTimer := time.NewTimer(connectDeadline.Sub(time.Now()))
+ prefaceTimer := time.NewTimer(time.Until(connectDeadline))
onGoAway := func(r transport.GoAwayReason) {
ac.mu.Lock()
diff --git a/vendor/google.golang.org/grpc/connectivity/connectivity.go b/vendor/google.golang.org/grpc/connectivity/connectivity.go
index b1d7dbc..34ec36f 100644
--- a/vendor/google.golang.org/grpc/connectivity/connectivity.go
+++ b/vendor/google.golang.org/grpc/connectivity/connectivity.go
@@ -52,7 +52,7 @@
const (
// Idle indicates the ClientConn is idle.
Idle State = iota
- // Connecting indicates the ClienConn is connecting.
+ // Connecting indicates the ClientConn is connecting.
Connecting
// Ready indicates the ClientConn is ready for work.
Ready
diff --git a/vendor/google.golang.org/grpc/dialoptions.go b/vendor/google.golang.org/grpc/dialoptions.go
index f286462..537b258 100644
--- a/vendor/google.golang.org/grpc/dialoptions.go
+++ b/vendor/google.golang.org/grpc/dialoptions.go
@@ -26,6 +26,7 @@
"google.golang.org/grpc/balancer"
"google.golang.org/grpc/credentials"
+ "google.golang.org/grpc/grpclog"
"google.golang.org/grpc/internal"
"google.golang.org/grpc/internal/backoff"
"google.golang.org/grpc/internal/envconfig"
@@ -164,7 +165,7 @@
// WithCodec returns a DialOption which sets a codec for message marshaling and
// unmarshaling.
//
-// Deprecated: use WithDefaultCallOptions(CallCustomCodec(c)) instead.
+// Deprecated: use WithDefaultCallOptions(ForceCodec(_)) instead.
func WithCodec(c Codec) DialOption {
return WithDefaultCallOptions(CallCustomCodec(c))
}
@@ -328,14 +329,17 @@
})
}
-func withContextDialer(f func(context.Context, string) (net.Conn, error)) DialOption {
+// WithContextDialer returns a DialOption that sets a dialer to create
+// connections. If FailOnNonTempDialError() is set to true, and an error is
+// returned by f, gRPC checks the error's Temporary() method to decide if it
+// should try to reconnect to the network address.
+func WithContextDialer(f func(context.Context, string) (net.Conn, error)) DialOption {
return newFuncDialOption(func(o *dialOptions) {
o.copts.Dialer = f
})
}
func init() {
- internal.WithContextDialer = withContextDialer
internal.WithResolverBuilder = withResolverBuilder
internal.WithHealthCheckFunc = withHealthCheckFunc
}
@@ -344,11 +348,13 @@
// network addresses. If FailOnNonTempDialError() is set to true, and an error
// is returned by f, gRPC checks the error's Temporary() method to decide if it
// should try to reconnect to the network address.
+//
+// Deprecated: use WithContextDialer instead
func WithDialer(f func(string, time.Duration) (net.Conn, error)) DialOption {
- return withContextDialer(
+ return WithContextDialer(
func(ctx context.Context, addr string) (net.Conn, error) {
if deadline, ok := ctx.Deadline(); ok {
- return f(addr, deadline.Sub(time.Now()))
+ return f(addr, time.Until(deadline))
}
return f(addr, 0)
})
@@ -388,6 +394,10 @@
// WithKeepaliveParams returns a DialOption that specifies keepalive parameters
// for the client transport.
func WithKeepaliveParams(kp keepalive.ClientParameters) DialOption {
+ if kp.Time < internal.KeepaliveMinPingTime {
+ grpclog.Warningf("Adjusting keepalive ping interval to minimum period of %v", internal.KeepaliveMinPingTime)
+ kp.Time = internal.KeepaliveMinPingTime
+ }
return newFuncDialOption(func(o *dialOptions) {
o.copts.KeepaliveParams = kp
})
diff --git a/vendor/google.golang.org/grpc/go.mod b/vendor/google.golang.org/grpc/go.mod
index f296dcf..0418807 100644
--- a/vendor/google.golang.org/grpc/go.mod
+++ b/vendor/google.golang.org/grpc/go.mod
@@ -2,19 +2,19 @@
require (
cloud.google.com/go v0.26.0 // indirect
+ github.com/BurntSushi/toml v0.3.1 // indirect
github.com/client9/misspell v0.3.4
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b
github.com/golang/mock v1.1.1
github.com/golang/protobuf v1.2.0
- github.com/kisielk/gotool v1.0.0 // indirect
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3
golang.org/x/net v0.0.0-20180826012351-8a410e7b638d
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f // indirect
golang.org/x/sys v0.0.0-20180830151530-49385e6e1522
golang.org/x/text v0.3.0 // indirect
- golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52
+ golang.org/x/tools v0.0.0-20190114222345-bf090417da8b
google.golang.org/appengine v1.1.0 // indirect
google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8
- honnef.co/go/tools v0.0.0-20180728063816-88497007e858
+ honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099
)
diff --git a/vendor/google.golang.org/grpc/go.sum b/vendor/google.golang.org/grpc/go.sum
index bfb6bb7..a79939d 100644
--- a/vendor/google.golang.org/grpc/go.sum
+++ b/vendor/google.golang.org/grpc/go.sum
@@ -1,5 +1,7 @@
cloud.google.com/go v0.26.0 h1:e0WKqKTd5BnrG8aKH3J3h+QvEIQtSUcf2n5UZ5ZgLtQ=
cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
+github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ=
+github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
github.com/client9/misspell v0.3.4 h1:ta993UF76GwbvJcIo3Y68y/M3WxlpEHPWIGDkJYwzJI=
github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58=
@@ -8,8 +10,6 @@
github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
github.com/golang/protobuf v1.2.0 h1:P3YflyNX/ehuJFLhxviNdFxQPkGK5cDcApsge1SqnvM=
github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
-github.com/kisielk/gotool v1.0.0 h1:AV2c/EiW3KqPNT9ZKl07ehoAGi4C5/01Cfbblndcapg=
-github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3 h1:x/bBzNauLQAlE3fLku/xy92Y8QwKX5HZymrMz2IiKFc=
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
golang.org/x/net v0.0.0-20180826012351-8a410e7b638d h1:g9qWBGx4puODJTMVyoPrpoxPFgVGd+z1DZwjfRu4d0I=
@@ -22,11 +22,11 @@
golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/text v0.3.0 h1:g61tztE5qeGQ89tm6NTjjM9VPIm088od1l6aSorWRWg=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
-golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52 h1:JG/0uqcGdTNgq7FdU+61l5Pdmb8putNZlXb65bJBROs=
-golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
+golang.org/x/tools v0.0.0-20190114222345-bf090417da8b h1:qMK98NmNCRVDIYFycQ5yVRkvgDUFfdP8Ip4KqmDEB7g=
+golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
google.golang.org/appengine v1.1.0 h1:igQkv0AAhEIvTEpD5LIpAfav2eeVO9HBTjvKHVJPRSs=
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8 h1:Nw54tB0rB7hY/N0NQvRW8DG4Yk3Q6T9cu9RcFQDu1tc=
google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc=
-honnef.co/go/tools v0.0.0-20180728063816-88497007e858 h1:wN+eVZ7U+gqdqkec6C6VXR1OFf9a5Ul9ETzeYsYv20g=
-honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
+honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099 h1:XJP7lxbSxWLOMNdBE4B/STaqVy6L73o0knwj2vIlxnw=
+honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
diff --git a/vendor/google.golang.org/grpc/internal/binarylog/env_config.go b/vendor/google.golang.org/grpc/internal/binarylog/env_config.go
index eb188ea..4cc2525 100644
--- a/vendor/google.golang.org/grpc/internal/binarylog/env_config.go
+++ b/vendor/google.golang.org/grpc/internal/binarylog/env_config.go
@@ -180,7 +180,7 @@
if s := match[1]; s != "" {
msgLenStr, err = strconv.ParseUint(s, 10, 64)
if err != nil {
- return 0, 0, fmt.Errorf("Failed to convert %q to uint", s)
+ return 0, 0, fmt.Errorf("failed to convert %q to uint", s)
}
return 0, msgLenStr, nil
}
@@ -195,13 +195,13 @@
if s := match[1]; s != "" {
hdrLenStr, err = strconv.ParseUint(s, 10, 64)
if err != nil {
- return 0, 0, fmt.Errorf("Failed to convert %q to uint", s)
+ return 0, 0, fmt.Errorf("failed to convert %q to uint", s)
}
}
if s := match[2]; s != "" {
msgLenStr, err = strconv.ParseUint(s, 10, 64)
if err != nil {
- return 0, 0, fmt.Errorf("Failed to convert %q to uint", s)
+ return 0, 0, fmt.Errorf("failed to convert %q to uint", s)
}
}
return hdrLenStr, msgLenStr, nil
diff --git a/vendor/google.golang.org/grpc/internal/binarylog/method_logger.go b/vendor/google.golang.org/grpc/internal/binarylog/method_logger.go
index b06cdd4..160f6e8 100644
--- a/vendor/google.golang.org/grpc/internal/binarylog/method_logger.go
+++ b/vendor/google.golang.org/grpc/internal/binarylog/method_logger.go
@@ -377,10 +377,7 @@
case "grpc-trace-bin": // grpc-trace-bin is special because it's visiable to users.
return false
}
- if strings.HasPrefix(key, "grpc-") {
- return true
- }
- return false
+ return strings.HasPrefix(key, "grpc-")
}
func mdToMetadataProto(md metadata.MD) *pb.Metadata {
diff --git a/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go b/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go
index d2193b3..62ed0f2 100644
--- a/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go
+++ b/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go
@@ -59,6 +59,7 @@
func init() {
switch strings.ToLower(os.Getenv(requireHandshakeStr)) {
case "on":
+ fallthrough
default:
RequireHandshake = RequireHandshakeOn
case "off":
diff --git a/vendor/google.golang.org/grpc/internal/internal.go b/vendor/google.golang.org/grpc/internal/internal.go
index eaa54d4..c1d2c69 100644
--- a/vendor/google.golang.org/grpc/internal/internal.go
+++ b/vendor/google.golang.org/grpc/internal/internal.go
@@ -20,11 +20,12 @@
// symbols to avoid circular dependencies.
package internal
-import "context"
+import (
+ "context"
+ "time"
+)
var (
- // WithContextDialer is exported by dialoptions.go
- WithContextDialer interface{} // func(context.Context, string) (net.Conn, error) grpc.DialOption
// WithResolverBuilder is exported by dialoptions.go
WithResolverBuilder interface{} // func (resolver.Builder) grpc.DialOption
// WithHealthCheckFunc is not exported by dialoptions.go
@@ -33,6 +34,9 @@
HealthCheckFunc HealthChecker
// BalancerUnregister is exported by package balancer to unregister a balancer.
BalancerUnregister func(name string)
+ // KeepaliveMinPingTime is the minimum ping interval. This must be 10s by
+ // default, but tests may wish to set it lower for convenience.
+ KeepaliveMinPingTime = 10 * time.Second
)
// HealthChecker defines the signature of the client-side LB channel health checking function.
diff --git a/vendor/google.golang.org/grpc/internal/transport/http2_client.go b/vendor/google.golang.org/grpc/internal/transport/http2_client.go
index babcaee..ff8f4db 100644
--- a/vendor/google.golang.org/grpc/internal/transport/http2_client.go
+++ b/vendor/google.golang.org/grpc/internal/transport/http2_client.go
@@ -322,7 +322,9 @@
}
}
- t.framer.writer.Flush()
+ if err := t.framer.writer.Flush(); err != nil {
+ return nil, err
+ }
go func() {
t.loopy = newLoopyWriter(clientSide, t.framer, t.controlBuf, t.bdpEst)
err := t.loopy.run()
@@ -417,7 +419,7 @@
if dl, ok := ctx.Deadline(); ok {
// Send out timeout regardless its value. The server can detect timeout context by itself.
// TODO(mmukhi): Perhaps this field should be updated when actually writing out to the wire.
- timeout := dl.Sub(time.Now())
+ timeout := time.Until(dl)
headerFields = append(headerFields, hpack.HeaderField{Name: "grpc-timeout", Value: encodeTimeout(timeout)})
}
for k, v := range authData {
diff --git a/vendor/google.golang.org/grpc/internal/transport/http2_server.go b/vendor/google.golang.org/grpc/internal/transport/http2_server.go
index df27403..d038b2d 100644
--- a/vendor/google.golang.org/grpc/internal/transport/http2_server.go
+++ b/vendor/google.golang.org/grpc/internal/transport/http2_server.go
@@ -1004,45 +1004,74 @@
return err
}
+// deleteStream deletes the stream s from transport's active streams.
+func (t *http2Server) deleteStream(s *Stream, eosReceived bool) {
+ t.mu.Lock()
+ if _, ok := t.activeStreams[s.id]; !ok {
+ t.mu.Unlock()
+ return
+ }
+
+ delete(t.activeStreams, s.id)
+ if len(t.activeStreams) == 0 {
+ t.idle = time.Now()
+ }
+ t.mu.Unlock()
+
+ if channelz.IsOn() {
+ if eosReceived {
+ atomic.AddInt64(&t.czData.streamsSucceeded, 1)
+ } else {
+ atomic.AddInt64(&t.czData.streamsFailed, 1)
+ }
+ }
+}
+
// closeStream clears the footprint of a stream when the stream is not needed
// any more.
func (t *http2Server) closeStream(s *Stream, rst bool, rstCode http2.ErrCode, hdr *headerFrame, eosReceived bool) {
- if s.swapState(streamDone) == streamDone {
- // If the stream was already done, return.
- return
- }
+ // Mark the stream as done
+ oldState := s.swapState(streamDone)
+
// In case stream sending and receiving are invoked in separate
// goroutines (e.g., bi-directional streaming), cancel needs to be
// called to interrupt the potential blocking on other goroutines.
s.cancel()
+
+ // Deletes the stream from active streams
+ t.deleteStream(s, eosReceived)
+
cleanup := &cleanupStream{
streamID: s.id,
rst: rst,
rstCode: rstCode,
- onWrite: func() {
- t.mu.Lock()
- if t.activeStreams != nil {
- delete(t.activeStreams, s.id)
- if len(t.activeStreams) == 0 {
- t.idle = time.Now()
- }
- }
- t.mu.Unlock()
- if channelz.IsOn() {
- if eosReceived {
- atomic.AddInt64(&t.czData.streamsSucceeded, 1)
- } else {
- atomic.AddInt64(&t.czData.streamsFailed, 1)
- }
- }
- },
+ onWrite: func() {},
}
- if hdr != nil {
- hdr.cleanup = cleanup
- t.controlBuf.put(hdr)
- } else {
+
+ // No trailer. Puts cleanupFrame into transport's control buffer.
+ if hdr == nil {
t.controlBuf.put(cleanup)
+ return
}
+
+ // We do the check here, because of the following scenario:
+ // 1. closeStream is called first with a trailer. A trailer item with a piggybacked cleanup item
+ // is put to control buffer.
+ // 2. Loopy writer is waiting on a stream quota. It will never get it because client errored at
+ // some point. So loopy can't act on trailer
+ // 3. Client sends a RST_STREAM due to the error. Then closeStream is called without a trailer as
+ // the result of the received RST_STREAM.
+ // If we do this check at the beginning of the closeStream, then we won't put a cleanup item in
+ // response to received RST_STREAM into the control buffer and outStream in loopy writer will
+ // never get cleaned up.
+
+ // If the stream is already done, don't send the trailer.
+ if oldState == streamDone {
+ return
+ }
+
+ hdr.cleanup = cleanup
+ t.controlBuf.put(hdr)
}
func (t *http2Server) RemoteAddr() net.Addr {
@@ -1155,7 +1184,7 @@
}
func (t *http2Server) getOutFlowWindow() int64 {
- resp := make(chan uint32)
+ resp := make(chan uint32, 1)
timer := time.NewTimer(time.Second)
defer timer.Stop()
t.controlBuf.put(&outFlowControlSizeRequest{resp})
diff --git a/vendor/google.golang.org/grpc/keepalive/keepalive.go b/vendor/google.golang.org/grpc/keepalive/keepalive.go
index 899e72d..34d31b5 100644
--- a/vendor/google.golang.org/grpc/keepalive/keepalive.go
+++ b/vendor/google.golang.org/grpc/keepalive/keepalive.go
@@ -33,6 +33,7 @@
type ClientParameters struct {
// After a duration of this time if the client doesn't see any activity it
// pings the server to see if the transport is still alive.
+ // If set below 10s, a minimum value of 10s will be used instead.
Time time.Duration // The current default value is infinity.
// After having pinged for keepalive check, the client waits for a duration
// of Timeout and if no activity is seen even after that the connection is
@@ -62,6 +63,7 @@
MaxConnectionAgeGrace time.Duration // The current default value is infinity.
// After a duration of this time if the server doesn't see any activity it
// pings the client to see if the transport is still alive.
+ // If set below 1s, a minimum value of 1s will be used instead.
Time time.Duration // The current default value is 2 hours.
// After having pinged for keepalive check, the server waits for a duration
// of Timeout and if no activity is seen even after that the connection is
diff --git a/vendor/google.golang.org/grpc/naming/dns_resolver.go b/vendor/google.golang.org/grpc/naming/dns_resolver.go
index fd8cd3b..c9f79dc 100644
--- a/vendor/google.golang.org/grpc/naming/dns_resolver.go
+++ b/vendor/google.golang.org/grpc/naming/dns_resolver.go
@@ -76,8 +76,8 @@
// parseTarget takes the user input target string, returns formatted host and port info.
// If target doesn't specify a port, set the port to be the defaultPort.
-// If target is in IPv6 format and host-name is enclosed in sqarue brackets, brackets
-// are strippd when setting the host.
+// If target is in IPv6 format and host-name is enclosed in square brackets, brackets
+// are stripped when setting the host.
// examples:
// target: "www.google.com" returns host: "www.google.com", port: "443"
// target: "ipv4-host:80" returns host: "ipv4-host", port: "80"
@@ -221,7 +221,7 @@
for _, s := range srvs {
lbAddrs, err := lookupHost(w.ctx, s.Target)
if err != nil {
- grpclog.Warningf("grpc: failed load banlacer address dns lookup due to %v.\n", err)
+ grpclog.Warningf("grpc: failed load balancer address dns lookup due to %v.\n", err)
continue
}
for _, a := range lbAddrs {
diff --git a/vendor/google.golang.org/grpc/naming/naming.go b/vendor/google.golang.org/grpc/naming/naming.go
index 8cc39e9..c99fdbe 100644
--- a/vendor/google.golang.org/grpc/naming/naming.go
+++ b/vendor/google.golang.org/grpc/naming/naming.go
@@ -17,7 +17,7 @@
*/
// Package naming defines the naming API and related data structures for gRPC.
-// The interface is EXPERIMENTAL and may be suject to change.
+// The interface is EXPERIMENTAL and may be subject to change.
//
// Deprecated: please use package resolver.
package naming
diff --git a/vendor/google.golang.org/grpc/picker_wrapper.go b/vendor/google.golang.org/grpc/picker_wrapper.go
index 14f915d..a2575c9 100644
--- a/vendor/google.golang.org/grpc/picker_wrapper.go
+++ b/vendor/google.golang.org/grpc/picker_wrapper.go
@@ -101,10 +101,7 @@
// - the subConn returned by the current picker is not READY
// When one of these situations happens, pick blocks until the picker gets updated.
func (bp *pickerWrapper) pick(ctx context.Context, failfast bool, opts balancer.PickOptions) (transport.ClientTransport, func(balancer.DoneInfo), error) {
- var (
- p balancer.Picker
- ch chan struct{}
- )
+ var ch chan struct{}
for {
bp.mu.Lock()
@@ -130,7 +127,7 @@
}
ch = bp.blockingCh
- p = bp.picker
+ p := bp.picker
bp.mu.Unlock()
subConn, done, err := p.Pick(ctx, opts)
@@ -144,15 +141,22 @@
continue
}
return nil, nil, status.Errorf(codes.Unavailable, "%v, latest connection error: %v", err, bp.connectionError())
+ case context.DeadlineExceeded:
+ return nil, nil, status.Error(codes.DeadlineExceeded, err.Error())
+ case context.Canceled:
+ return nil, nil, status.Error(codes.Canceled, err.Error())
default:
+ if _, ok := status.FromError(err); ok {
+ return nil, nil, err
+ }
// err is some other error.
- return nil, nil, toRPCErr(err)
+ return nil, nil, status.Error(codes.Unknown, err.Error())
}
}
acw, ok := subConn.(*acBalancerWrapper)
if !ok {
- grpclog.Infof("subconn returned from pick is not *acBalancerWrapper")
+ grpclog.Error("subconn returned from pick is not *acBalancerWrapper")
continue
}
if t, ok := acw.getAddrConn().getReadyTransport(); ok {
diff --git a/vendor/google.golang.org/grpc/resolver/dns/dns_resolver.go b/vendor/google.golang.org/grpc/resolver/dns/dns_resolver.go
index f33189f..2d8da33 100644
--- a/vendor/google.golang.org/grpc/resolver/dns/dns_resolver.go
+++ b/vendor/google.golang.org/grpc/resolver/dns/dns_resolver.go
@@ -346,8 +346,8 @@
// parseTarget takes the user input target string and default port, returns formatted host and port info.
// If target doesn't specify a port, set the port to be the defaultPort.
-// If target is in IPv6 format and host-name is enclosed in sqarue brackets, brackets
-// are strippd when setting the host.
+// If target is in IPv6 format and host-name is enclosed in square brackets, brackets
+// are stripped when setting the host.
// examples:
// target: "www.google.com" defaultPort: "443" returns host: "www.google.com", port: "443"
// target: "ipv4-host:80" defaultPort: "443" returns host: "ipv4-host", port: "80"
diff --git a/vendor/google.golang.org/grpc/rpc_util.go b/vendor/google.golang.org/grpc/rpc_util.go
index 8d0d3dc..2a59562 100644
--- a/vendor/google.golang.org/grpc/rpc_util.go
+++ b/vendor/google.golang.org/grpc/rpc_util.go
@@ -370,13 +370,13 @@
// https://github.com/grpc/grpc/blob/master/doc/PROTOCOL-HTTP2.md#requests for
// more details.
//
-// If CallCustomCodec is not also used, the content-subtype will be used to
-// look up the Codec to use in the registry controlled by RegisterCodec. See
-// the documentation on RegisterCodec for details on registration. The lookup
-// of content-subtype is case-insensitive. If no such Codec is found, the call
+// If ForceCodec is not also used, the content-subtype will be used to look up
+// the Codec to use in the registry controlled by RegisterCodec. See the
+// documentation on RegisterCodec for details on registration. The lookup of
+// content-subtype is case-insensitive. If no such Codec is found, the call
// will result in an error with code codes.Internal.
//
-// If CallCustomCodec is also used, that Codec will be used for all request and
+// If ForceCodec is also used, that Codec will be used for all request and
// response messages, with the content-subtype set to the given contentSubtype
// here for requests.
func CallContentSubtype(contentSubtype string) CallOption {
@@ -396,7 +396,7 @@
}
func (o ContentSubtypeCallOption) after(c *callInfo) {}
-// CallCustomCodec returns a CallOption that will set the given Codec to be
+// ForceCodec returns a CallOption that will set the given Codec to be
// used for all request and response messages for a call. The result of calling
// String() will be used as the content-subtype in a case-insensitive manner.
//
@@ -408,12 +408,37 @@
//
// This function is provided for advanced users; prefer to use only
// CallContentSubtype to select a registered codec instead.
+//
+// This is an EXPERIMENTAL API.
+func ForceCodec(codec encoding.Codec) CallOption {
+ return ForceCodecCallOption{Codec: codec}
+}
+
+// ForceCodecCallOption is a CallOption that indicates the codec used for
+// marshaling messages.
+//
+// This is an EXPERIMENTAL API.
+type ForceCodecCallOption struct {
+ Codec encoding.Codec
+}
+
+func (o ForceCodecCallOption) before(c *callInfo) error {
+ c.codec = o.Codec
+ return nil
+}
+func (o ForceCodecCallOption) after(c *callInfo) {}
+
+// CallCustomCodec behaves like ForceCodec, but accepts a grpc.Codec instead of
+// an encoding.Codec.
+//
+// Deprecated: use ForceCodec instead.
func CallCustomCodec(codec Codec) CallOption {
return CustomCodecCallOption{Codec: codec}
}
// CustomCodecCallOption is a CallOption that indicates the codec used for
// marshaling messages.
+//
// This is an EXPERIMENTAL API.
type CustomCodecCallOption struct {
Codec Codec
@@ -636,7 +661,9 @@
if err != nil {
return nil, status.Errorf(codes.Internal, "grpc: failed to decompress the received message %v", err)
}
- d, err = ioutil.ReadAll(dcReader)
+ // Read from LimitReader with limit max+1. So if the underlying
+ // reader is over limit, the result will be bigger than max.
+ d, err = ioutil.ReadAll(io.LimitReader(dcReader, int64(maxReceiveMessageSize)+1))
if err != nil {
return nil, status.Errorf(codes.Internal, "grpc: failed to decompress the received message %v", err)
}
diff --git a/vendor/google.golang.org/grpc/server.go b/vendor/google.golang.org/grpc/server.go
index d705d7a..33272a4 100644
--- a/vendor/google.golang.org/grpc/server.go
+++ b/vendor/google.golang.org/grpc/server.go
@@ -182,6 +182,11 @@
// KeepaliveParams returns a ServerOption that sets keepalive and max-age parameters for the server.
func KeepaliveParams(kp keepalive.ServerParameters) ServerOption {
+ if kp.Time > 0 && kp.Time < time.Second {
+ grpclog.Warning("Adjusting keepalive ping interval to minimum period of 1s")
+ kp.Time = time.Second
+ }
+
return func(o *options) {
o.keepaliveParams = kp
}
@@ -244,7 +249,7 @@
}
// MaxSendMsgSize returns a ServerOption to set the max message size in bytes the server can send.
-// If this is not set, gRPC uses the default 4MB.
+// If this is not set, gRPC uses the default `math.MaxInt32`.
func MaxSendMsgSize(m int) ServerOption {
return func(o *options) {
o.maxSendMessageSize = m
@@ -748,7 +753,7 @@
trInfo.firstLine.remoteAddr = st.RemoteAddr()
if dl, ok := stream.Context().Deadline(); ok {
- trInfo.firstLine.deadline = dl.Sub(time.Now())
+ trInfo.firstLine.deadline = time.Until(dl)
}
return trInfo
}
@@ -874,7 +879,7 @@
PeerAddr: nil,
}
if deadline, ok := ctx.Deadline(); ok {
- logEntry.Timeout = deadline.Sub(time.Now())
+ logEntry.Timeout = time.Until(deadline)
if logEntry.Timeout < 0 {
logEntry.Timeout = 0
}
@@ -1106,7 +1111,7 @@
PeerAddr: nil,
}
if deadline, ok := ctx.Deadline(); ok {
- logEntry.Timeout = deadline.Sub(time.Now())
+ logEntry.Timeout = time.Until(deadline)
if logEntry.Timeout < 0 {
logEntry.Timeout = 0
}
diff --git a/vendor/google.golang.org/grpc/stream.go b/vendor/google.golang.org/grpc/stream.go
index d06279a..ccf996b 100644
--- a/vendor/google.golang.org/grpc/stream.go
+++ b/vendor/google.golang.org/grpc/stream.go
@@ -235,7 +235,7 @@
trInfo.tr = trace.New("grpc.Sent."+methodFamily(method), method)
trInfo.firstLine.client = true
if deadline, ok := ctx.Deadline(); ok {
- trInfo.firstLine.deadline = deadline.Sub(time.Now())
+ trInfo.firstLine.deadline = time.Until(deadline)
}
trInfo.tr.LazyLog(&trInfo.firstLine, false)
ctx = trace.NewContext(ctx, trInfo.tr)
@@ -297,7 +297,7 @@
Authority: cs.cc.authority,
}
if deadline, ok := ctx.Deadline(); ok {
- logEntry.Timeout = deadline.Sub(time.Now())
+ logEntry.Timeout = time.Until(deadline)
if logEntry.Timeout < 0 {
logEntry.Timeout = 0
}
@@ -1086,7 +1086,6 @@
dc Decompressor
decomp encoding.Compressor
p *parser
- done func(balancer.DoneInfo)
mu sync.Mutex
finished bool
}
diff --git a/vendor/google.golang.org/grpc/version.go b/vendor/google.golang.org/grpc/version.go
index 45eace5..035b939 100644
--- a/vendor/google.golang.org/grpc/version.go
+++ b/vendor/google.golang.org/grpc/version.go
@@ -19,4 +19,4 @@
package grpc
// Version is the current grpc version.
-const Version = "1.18.0"
+const Version = "1.19.1"
diff --git a/vendor/google.golang.org/grpc/vet.sh b/vendor/google.golang.org/grpc/vet.sh
index 94a5064..7209aa5 100755
--- a/vendor/google.golang.org/grpc/vet.sh
+++ b/vendor/google.golang.org/grpc/vet.sh
@@ -13,26 +13,19 @@
exit 1
}
-# Check to make sure it's safe to modify the user's git repo.
-if git status --porcelain | read; then
- die "Uncommitted or untracked files found; commit changes first"
-fi
-
-if [[ -d "${GOPATH}/src" ]]; then
- die "\${GOPATH}/src (${GOPATH}/src) exists; this script will delete it."
-fi
-
-# Undo any edits made by this script.
-cleanup() {
- rm -rf "${GOPATH}/src"
- git reset --hard HEAD
-}
-trap cleanup EXIT
-
fail_on_output() {
tee /dev/stderr | (! read)
}
+# Check to make sure it's safe to modify the user's git repo.
+git status --porcelain | fail_on_output
+
+# Undo any edits made by this script.
+cleanup() {
+ git reset --hard HEAD
+}
+trap cleanup EXIT
+
PATH="${GOPATH}/bin:${GOROOT}/bin:${PATH}"
if [[ "$1" = "-install" ]]; then
@@ -112,30 +105,19 @@
fi
# - Collection of static analysis checks
-### HACK HACK HACK: Remove once staticcheck works with modules.
-# Make a symlink in ${GOPATH}/src to its ${GOPATH}/pkg/mod equivalent for every package we use.
-for x in $(find "${GOPATH}/pkg/mod" -name '*@*' | grep -v \/mod\/cache\/); do
- pkg="$(echo ${x#"${GOPATH}/pkg/mod/"} | cut -f1 -d@)";
- # If multiple versions exist, just use the existing one.
- if [[ -L "${GOPATH}/src/${pkg}" ]]; then continue; fi
- mkdir -p "$(dirname "${GOPATH}/src/${pkg}")";
- ln -s $x "${GOPATH}/src/${pkg}";
-done
-### END HACK HACK HACK
-
# TODO(menghanl): fix errors in transport_test.
-staticcheck -go 1.9 -ignore '
-balancer.go:SA1019
-balancer_test.go:SA1019
-clientconn_test.go:SA1019
-balancer/roundrobin/roundrobin_test.go:SA1019
-benchmark/benchmain/main.go:SA1019
-internal/transport/handler_server.go:SA1019
-internal/transport/handler_server_test.go:SA1019
-internal/transport/transport_test.go:SA2002
-stats/stats_test.go:SA1019
-test/channelz_test.go:SA1019
-test/end2end_test.go:SA1019
-test/healthcheck_test.go:SA1019
+staticcheck -go 1.9 -checks 'inherit,-ST1015' -ignore '
+google.golang.org/grpc/balancer.go:SA1019
+google.golang.org/grpc/balancer_test.go:SA1019
+google.golang.org/grpc/clientconn_test.go:SA1019
+google.golang.org/grpc/balancer/roundrobin/roundrobin_test.go:SA1019
+google.golang.org/grpc/benchmark/benchmain/main.go:SA1019
+google.golang.org/grpc/benchmark/worker/benchmark_client.go:SA1019
+google.golang.org/grpc/internal/transport/handler_server.go:SA1019
+google.golang.org/grpc/internal/transport/handler_server_test.go:SA1019
+google.golang.org/grpc/stats/stats_test.go:SA1019
+google.golang.org/grpc/test/channelz_test.go:SA1019
+google.golang.org/grpc/test/end2end_test.go:SA1019
+google.golang.org/grpc/test/healthcheck_test.go:SA1019
' ./...
misspell -error .
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/.travis.yml b/vendor/gopkg.in/Shopify/sarama.v1/.travis.yml
index eb54a0d..b7f7874 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/.travis.yml
+++ b/vendor/gopkg.in/Shopify/sarama.v1/.travis.yml
@@ -11,9 +11,9 @@
- KAFKA_HOSTNAME=localhost
- DEBUG=true
matrix:
- - KAFKA_VERSION=1.1.1
- - KAFKA_VERSION=2.0.1
- - KAFKA_VERSION=2.1.0
+ - KAFKA_VERSION=1.1.1 KAFKA_SCALA_VERSION=2.11
+ - KAFKA_VERSION=2.0.1 KAFKA_SCALA_VERSION=2.12
+ - KAFKA_VERSION=2.1.0 KAFKA_SCALA_VERSION=2.12
before_install:
- export REPOSITORY_ROOT=${TRAVIS_BUILD_DIR}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/CHANGELOG.md b/vendor/gopkg.in/Shopify/sarama.v1/CHANGELOG.md
index afc8511..0e69c2d 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/CHANGELOG.md
+++ b/vendor/gopkg.in/Shopify/sarama.v1/CHANGELOG.md
@@ -1,5 +1,41 @@
# Changelog
+#### Version 1.21.0 (2019-02-24)
+
+New Features:
+- Add CreateAclRequest, DescribeAclRequest, DeleteAclRequest
+ ([1236](https://github.com/Shopify/sarama/pull/1236)).
+- Add DescribeTopic, DescribeConsumerGroup, ListConsumerGroups, ListConsumerGroupOffsets admin requests
+ ([1178](https://github.com/Shopify/sarama/pull/1178)).
+- Implement SASL/OAUTHBEARER
+ ([1240](https://github.com/Shopify/sarama/pull/1240)).
+
+Improvements:
+- Add Go mod support
+ ([1282](https://github.com/Shopify/sarama/pull/1282)).
+- Add error codes 73—76
+ ([1239](https://github.com/Shopify/sarama/pull/1239)).
+- Add retry backoff function
+ ([1160](https://github.com/Shopify/sarama/pull/1160)).
+- Maintain metadata in the producer even when retries are disabled
+ ([1189](https://github.com/Shopify/sarama/pull/1189)).
+- Include ReplicaAssignment in ListTopics
+ ([1274](https://github.com/Shopify/sarama/pull/1274)).
+- Add producer performance tool
+ ([1222](https://github.com/Shopify/sarama/pull/1222)).
+- Add support LogAppend timestamps
+ ([1258](https://github.com/Shopify/sarama/pull/1258)).
+
+Bug Fixes:
+- Fix potential deadlock when a heartbeat request fails
+ ([1286](https://github.com/Shopify/sarama/pull/1286)).
+- Fix consuming compacted topic
+ ([1227](https://github.com/Shopify/sarama/pull/1227)).
+- Set correct Kafka version for DescribeConfigsRequest v1
+ ([1277](https://github.com/Shopify/sarama/pull/1277)).
+- Update kafka test version
+ ([1273](https://github.com/Shopify/sarama/pull/1273)).
+
#### Version 1.20.1 (2019-01-10)
New Features:
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/Makefile b/vendor/gopkg.in/Shopify/sarama.v1/Makefile
index 8fcf219..09f743c 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/Makefile
+++ b/vendor/gopkg.in/Shopify/sarama.v1/Makefile
@@ -1,3 +1,5 @@
+export GO111MODULE=on
+
default: fmt vet errcheck test
# Taken from https://github.com/codecov/example-go#caveat-multiple-files
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/acl_bindings.go b/vendor/gopkg.in/Shopify/sarama.v1/acl_bindings.go
index 5151735..b91c282 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/acl_bindings.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/acl_bindings.go
@@ -1,17 +1,26 @@
package sarama
type Resource struct {
- ResourceType AclResourceType
- ResourceName string
+ ResourceType AclResourceType
+ ResourceName string
+ ResoucePatternType AclResourcePatternType
}
-func (r *Resource) encode(pe packetEncoder) error {
+func (r *Resource) encode(pe packetEncoder, version int16) error {
pe.putInt8(int8(r.ResourceType))
if err := pe.putString(r.ResourceName); err != nil {
return err
}
+ if version == 1 {
+ if r.ResoucePatternType == AclPatternUnknown {
+ Logger.Print("Cannot encode an unknown resource pattern type, using Literal instead")
+ r.ResoucePatternType = AclPatternLiteral
+ }
+ pe.putInt8(int8(r.ResoucePatternType))
+ }
+
return nil
}
@@ -25,6 +34,13 @@
if r.ResourceName, err = pd.getString(); err != nil {
return err
}
+ if version == 1 {
+ pattern, err := pd.getInt8()
+ if err != nil {
+ return err
+ }
+ r.ResoucePatternType = AclResourcePatternType(pattern)
+ }
return nil
}
@@ -80,8 +96,8 @@
Acls []*Acl
}
-func (r *ResourceAcls) encode(pe packetEncoder) error {
- if err := r.Resource.encode(pe); err != nil {
+func (r *ResourceAcls) encode(pe packetEncoder, version int16) error {
+ if err := r.Resource.encode(pe, version); err != nil {
return err
}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/acl_create_request.go b/vendor/gopkg.in/Shopify/sarama.v1/acl_create_request.go
index 0b6ecbe..d3d5ad8 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/acl_create_request.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/acl_create_request.go
@@ -1,6 +1,7 @@
package sarama
type CreateAclsRequest struct {
+ Version int16
AclCreations []*AclCreation
}
@@ -10,7 +11,7 @@
}
for _, aclCreation := range c.AclCreations {
- if err := aclCreation.encode(pe); err != nil {
+ if err := aclCreation.encode(pe, c.Version); err != nil {
return err
}
}
@@ -19,6 +20,7 @@
}
func (c *CreateAclsRequest) decode(pd packetDecoder, version int16) (err error) {
+ c.Version = version
n, err := pd.getArrayLength()
if err != nil {
return err
@@ -41,11 +43,16 @@
}
func (d *CreateAclsRequest) version() int16 {
- return 0
+ return d.Version
}
func (d *CreateAclsRequest) requiredVersion() KafkaVersion {
- return V0_11_0_0
+ switch d.Version {
+ case 1:
+ return V2_0_0_0
+ default:
+ return V0_11_0_0
+ }
}
type AclCreation struct {
@@ -53,8 +60,8 @@
Acl
}
-func (a *AclCreation) encode(pe packetEncoder) error {
- if err := a.Resource.encode(pe); err != nil {
+func (a *AclCreation) encode(pe packetEncoder, version int16) error {
+ if err := a.Resource.encode(pe, version); err != nil {
return err
}
if err := a.Acl.encode(pe); err != nil {
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/acl_delete_request.go b/vendor/gopkg.in/Shopify/sarama.v1/acl_delete_request.go
index 4133dce..5e94ad7 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/acl_delete_request.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/acl_delete_request.go
@@ -1,6 +1,7 @@
package sarama
type DeleteAclsRequest struct {
+ Version int
Filters []*AclFilter
}
@@ -10,6 +11,7 @@
}
for _, filter := range d.Filters {
+ filter.Version = d.Version
if err := filter.encode(pe); err != nil {
return err
}
@@ -19,6 +21,7 @@
}
func (d *DeleteAclsRequest) decode(pd packetDecoder, version int16) (err error) {
+ d.Version = int(version)
n, err := pd.getArrayLength()
if err != nil {
return err
@@ -27,6 +30,7 @@
d.Filters = make([]*AclFilter, n)
for i := 0; i < n; i++ {
d.Filters[i] = new(AclFilter)
+ d.Filters[i].Version = int(version)
if err := d.Filters[i].decode(pd, version); err != nil {
return err
}
@@ -40,9 +44,14 @@
}
func (d *DeleteAclsRequest) version() int16 {
- return 0
+ return int16(d.Version)
}
func (d *DeleteAclsRequest) requiredVersion() KafkaVersion {
- return V0_11_0_0
+ switch d.Version {
+ case 1:
+ return V2_0_0_0
+ default:
+ return V0_11_0_0
+ }
}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/acl_delete_response.go b/vendor/gopkg.in/Shopify/sarama.v1/acl_delete_response.go
index b5e1c45..a885fe5 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/acl_delete_response.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/acl_delete_response.go
@@ -3,6 +3,7 @@
import "time"
type DeleteAclsResponse struct {
+ Version int16
ThrottleTime time.Duration
FilterResponses []*FilterResponse
}
@@ -15,7 +16,7 @@
}
for _, filterResponse := range a.FilterResponses {
- if err := filterResponse.encode(pe); err != nil {
+ if err := filterResponse.encode(pe, a.Version); err != nil {
return err
}
}
@@ -51,7 +52,7 @@
}
func (d *DeleteAclsResponse) version() int16 {
- return 0
+ return int16(d.Version)
}
func (d *DeleteAclsResponse) requiredVersion() KafkaVersion {
@@ -64,7 +65,7 @@
MatchingAcls []*MatchingAcl
}
-func (f *FilterResponse) encode(pe packetEncoder) error {
+func (f *FilterResponse) encode(pe packetEncoder, version int16) error {
pe.putInt16(int16(f.Err))
if err := pe.putNullableString(f.ErrMsg); err != nil {
return err
@@ -74,7 +75,7 @@
return err
}
for _, matchingAcl := range f.MatchingAcls {
- if err := matchingAcl.encode(pe); err != nil {
+ if err := matchingAcl.encode(pe, version); err != nil {
return err
}
}
@@ -115,13 +116,13 @@
Acl
}
-func (m *MatchingAcl) encode(pe packetEncoder) error {
+func (m *MatchingAcl) encode(pe packetEncoder, version int16) error {
pe.putInt16(int16(m.Err))
if err := pe.putNullableString(m.ErrMsg); err != nil {
return err
}
- if err := m.Resource.encode(pe); err != nil {
+ if err := m.Resource.encode(pe, version); err != nil {
return err
}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/acl_describe_request.go b/vendor/gopkg.in/Shopify/sarama.v1/acl_describe_request.go
index 02a5a1f..3c95320 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/acl_describe_request.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/acl_describe_request.go
@@ -1,14 +1,18 @@
package sarama
type DescribeAclsRequest struct {
+ Version int
AclFilter
}
func (d *DescribeAclsRequest) encode(pe packetEncoder) error {
+ d.AclFilter.Version = d.Version
return d.AclFilter.encode(pe)
}
func (d *DescribeAclsRequest) decode(pd packetDecoder, version int16) (err error) {
+ d.Version = int(version)
+ d.AclFilter.Version = int(version)
return d.AclFilter.decode(pd, version)
}
@@ -17,9 +21,14 @@
}
func (d *DescribeAclsRequest) version() int16 {
- return 0
+ return int16(d.Version)
}
func (d *DescribeAclsRequest) requiredVersion() KafkaVersion {
- return V0_11_0_0
+ switch d.Version {
+ case 1:
+ return V2_0_0_0
+ default:
+ return V0_11_0_0
+ }
}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/acl_describe_response.go b/vendor/gopkg.in/Shopify/sarama.v1/acl_describe_response.go
index 5bc9497..db3a88c 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/acl_describe_response.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/acl_describe_response.go
@@ -3,6 +3,7 @@
import "time"
type DescribeAclsResponse struct {
+ Version int16
ThrottleTime time.Duration
Err KError
ErrMsg *string
@@ -22,7 +23,7 @@
}
for _, resourceAcl := range d.ResourceAcls {
- if err := resourceAcl.encode(pe); err != nil {
+ if err := resourceAcl.encode(pe, d.Version); err != nil {
return err
}
}
@@ -72,9 +73,14 @@
}
func (d *DescribeAclsResponse) version() int16 {
- return 0
+ return int16(d.Version)
}
func (d *DescribeAclsResponse) requiredVersion() KafkaVersion {
- return V0_11_0_0
+ switch d.Version {
+ case 1:
+ return V2_0_0_0
+ default:
+ return V0_11_0_0
+ }
}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/acl_filter.go b/vendor/gopkg.in/Shopify/sarama.v1/acl_filter.go
index 9706354..fad5558 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/acl_filter.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/acl_filter.go
@@ -1,12 +1,14 @@
package sarama
type AclFilter struct {
- ResourceType AclResourceType
- ResourceName *string
- Principal *string
- Host *string
- Operation AclOperation
- PermissionType AclPermissionType
+ Version int
+ ResourceType AclResourceType
+ ResourceName *string
+ ResourcePatternTypeFilter AclResourcePatternType
+ Principal *string
+ Host *string
+ Operation AclOperation
+ PermissionType AclPermissionType
}
func (a *AclFilter) encode(pe packetEncoder) error {
@@ -14,6 +16,11 @@
if err := pe.putNullableString(a.ResourceName); err != nil {
return err
}
+
+ if a.Version == 1 {
+ pe.putInt8(int8(a.ResourcePatternTypeFilter))
+ }
+
if err := pe.putNullableString(a.Principal); err != nil {
return err
}
@@ -37,6 +44,16 @@
return err
}
+ if a.Version == 1 {
+ pattern, err := pd.getInt8()
+
+ if err != nil {
+ return err
+ }
+
+ a.ResourcePatternTypeFilter = AclResourcePatternType(pattern)
+ }
+
if a.Principal, err = pd.getNullableString(); err != nil {
return err
}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/acl_types.go b/vendor/gopkg.in/Shopify/sarama.v1/acl_types.go
index 19da6f2..72b7985 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/acl_types.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/acl_types.go
@@ -40,3 +40,15 @@
AclResourceCluster AclResourceType = 4
AclResourceTransactionalID AclResourceType = 5
)
+
+type AclResourcePatternType int
+
+// ref: https://github.com/apache/kafka/blob/trunk/clients/src/main/java/org/apache/kafka/common/resource/PatternType.java
+
+const (
+ AclPatternUnknown AclResourcePatternType = iota
+ AclPatternAny
+ AclPatternMatch
+ AclPatternLiteral
+ AclPatternPrefixed
+)
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/admin.go b/vendor/gopkg.in/Shopify/sarama.v1/admin.go
index 5272575..18b055a 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/admin.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/admin.go
@@ -1,6 +1,10 @@
package sarama
-import "errors"
+import (
+ "errors"
+ "math/rand"
+ "sync"
+)
// ClusterAdmin is the administrative client for Kafka, which supports managing and inspecting topics,
// brokers, configurations and ACLs. The minimum broker version required is 0.10.0.0.
@@ -13,6 +17,12 @@
// may not return information about the new topic.The validateOnly option is supported from version 0.10.2.0.
CreateTopic(topic string, detail *TopicDetail, validateOnly bool) error
+ // List the topics available in the cluster with the default options.
+ ListTopics() (map[string]TopicDetail, error)
+
+ // Describe some topics in the cluster
+ DescribeTopics(topics []string) (metadata []*TopicMetadata, err error)
+
// Delete a topic. It may take several seconds after the DeleteTopic to returns success
// and for all the brokers to become aware that the topics are gone.
// During this time, listTopics may continue to return information about the deleted topic.
@@ -65,6 +75,18 @@
// This operation is supported by brokers with version 0.11.0.0 or higher.
DeleteACL(filter AclFilter, validateOnly bool) ([]MatchingAcl, error)
+ // List the consumer groups available in the cluster.
+ ListConsumerGroups() (map[string]string, error)
+
+ // Describe the given consumer group
+ DescribeConsumerGroups(groups []string) ([]*GroupDescription, error)
+
+ // List the consumer group offsets available in the cluster.
+ ListConsumerGroupOffsets(group string, topicPartitions map[string][]int32) (*OffsetFetchResponse, error)
+
+ // Get information about the nodes in the cluster
+ DescribeCluster() (brokers []*Broker, controllerID int32, err error)
+
// Close shuts down the admin and closes underlying client.
Close() error
}
@@ -150,6 +172,127 @@
return nil
}
+func (ca *clusterAdmin) DescribeTopics(topics []string) (metadata []*TopicMetadata, err error) {
+ controller, err := ca.Controller()
+ if err != nil {
+ return nil, err
+ }
+
+ request := &MetadataRequest{
+ Topics: topics,
+ AllowAutoTopicCreation: false,
+ }
+
+ if ca.conf.Version.IsAtLeast(V0_11_0_0) {
+ request.Version = 4
+ }
+
+ response, err := controller.GetMetadata(request)
+ if err != nil {
+ return nil, err
+ }
+ return response.Topics, nil
+}
+
+func (ca *clusterAdmin) DescribeCluster() (brokers []*Broker, controllerID int32, err error) {
+ controller, err := ca.Controller()
+ if err != nil {
+ return nil, int32(0), err
+ }
+
+ request := &MetadataRequest{
+ Topics: []string{},
+ }
+
+ response, err := controller.GetMetadata(request)
+ if err != nil {
+ return nil, int32(0), err
+ }
+
+ return response.Brokers, response.ControllerID, nil
+}
+
+func (ca *clusterAdmin) findAnyBroker() (*Broker, error) {
+ brokers := ca.client.Brokers()
+ if len(brokers) > 0 {
+ index := rand.Intn(len(brokers))
+ return brokers[index], nil
+ }
+ return nil, errors.New("no available broker")
+}
+
+func (ca *clusterAdmin) ListTopics() (map[string]TopicDetail, error) {
+ // In order to build TopicDetails we need to first get the list of all
+ // topics using a MetadataRequest and then get their configs using a
+ // DescribeConfigsRequest request. To avoid sending many requests to the
+ // broker, we use a single DescribeConfigsRequest.
+
+ // Send the all-topic MetadataRequest
+ b, err := ca.findAnyBroker()
+ if err != nil {
+ return nil, err
+ }
+ _ = b.Open(ca.client.Config())
+
+ metadataReq := &MetadataRequest{}
+ metadataResp, err := b.GetMetadata(metadataReq)
+ if err != nil {
+ return nil, err
+ }
+
+ topicsDetailsMap := make(map[string]TopicDetail)
+
+ var describeConfigsResources []*ConfigResource
+
+ for _, topic := range metadataResp.Topics {
+ topicDetails := TopicDetail{
+ NumPartitions: int32(len(topic.Partitions)),
+ }
+ if len(topic.Partitions) > 0 {
+ topicDetails.ReplicaAssignment = map[int32][]int32{}
+ for _, partition := range topic.Partitions {
+ topicDetails.ReplicaAssignment[partition.ID] = partition.Replicas
+ }
+ topicDetails.ReplicationFactor = int16(len(topic.Partitions[0].Replicas))
+ }
+ topicsDetailsMap[topic.Name] = topicDetails
+
+ // we populate the resources we want to describe from the MetadataResponse
+ topicResource := ConfigResource{
+ Type: TopicResource,
+ Name: topic.Name,
+ }
+ describeConfigsResources = append(describeConfigsResources, &topicResource)
+ }
+
+ // Send the DescribeConfigsRequest
+ describeConfigsReq := &DescribeConfigsRequest{
+ Resources: describeConfigsResources,
+ }
+ describeConfigsResp, err := b.DescribeConfigs(describeConfigsReq)
+ if err != nil {
+ return nil, err
+ }
+
+ for _, resource := range describeConfigsResp.Resources {
+ topicDetails := topicsDetailsMap[resource.Name]
+ topicDetails.ConfigEntries = make(map[string]*string)
+
+ for _, entry := range resource.Configs {
+ // only include non-default non-sensitive config
+ // (don't actually think topic config will ever be sensitive)
+ if entry.Default || entry.Sensitive {
+ continue
+ }
+ topicDetails.ConfigEntries[entry.Name] = &entry.Value
+ }
+
+ topicsDetailsMap[resource.Name] = topicDetails
+ }
+
+ return topicsDetailsMap, nil
+}
+
func (ca *clusterAdmin) DeleteTopic(topic string) error {
if topic == "" {
@@ -380,3 +523,92 @@
}
return mAcls, nil
}
+
+func (ca *clusterAdmin) DescribeConsumerGroups(groups []string) (result []*GroupDescription, err error) {
+ groupsPerBroker := make(map[*Broker][]string)
+
+ for _, group := range groups {
+ controller, err := ca.client.Coordinator(group)
+ if err != nil {
+ return nil, err
+ }
+ groupsPerBroker[controller] = append(groupsPerBroker[controller], group)
+
+ }
+
+ for broker, brokerGroups := range groupsPerBroker {
+ response, err := broker.DescribeGroups(&DescribeGroupsRequest{
+ Groups: brokerGroups,
+ })
+ if err != nil {
+ return nil, err
+ }
+
+ result = append(result, response.Groups...)
+ }
+ return result, nil
+}
+
+func (ca *clusterAdmin) ListConsumerGroups() (allGroups map[string]string, err error) {
+ allGroups = make(map[string]string)
+
+ // Query brokers in parallel, since we have to query *all* brokers
+ brokers := ca.client.Brokers()
+ groupMaps := make(chan map[string]string, len(brokers))
+ errors := make(chan error, len(brokers))
+ wg := sync.WaitGroup{}
+
+ for _, b := range brokers {
+ wg.Add(1)
+ go func(b *Broker, conf *Config) {
+ defer wg.Done()
+ _ = b.Open(conf) // Ensure that broker is opened
+
+ response, err := b.ListGroups(&ListGroupsRequest{})
+ if err != nil {
+ errors <- err
+ return
+ }
+
+ groups := make(map[string]string)
+ for group, typ := range response.Groups {
+ groups[group] = typ
+ }
+
+ groupMaps <- groups
+
+ }(b, ca.conf)
+ }
+
+ wg.Wait()
+ close(groupMaps)
+ close(errors)
+
+ for groupMap := range groupMaps {
+ for group, protocolType := range groupMap {
+ allGroups[group] = protocolType
+ }
+ }
+
+ // Intentionally return only the first error for simplicity
+ err = <-errors
+ return
+}
+
+func (ca *clusterAdmin) ListConsumerGroupOffsets(group string, topicPartitions map[string][]int32) (*OffsetFetchResponse, error) {
+ coordinator, err := ca.client.Coordinator(group)
+ if err != nil {
+ return nil, err
+ }
+
+ request := &OffsetFetchRequest{
+ ConsumerGroup: group,
+ partitions: topicPartitions,
+ }
+
+ if ca.conf.Version.IsAtLeast(V0_8_2_2) {
+ request.Version = 1
+ }
+
+ return coordinator.FetchOffset(request)
+}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/async_producer.go b/vendor/gopkg.in/Shopify/sarama.v1/async_producer.go
index 89a0c70..5174a35 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/async_producer.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/async_producer.go
@@ -483,6 +483,19 @@
return input
}
+func (pp *partitionProducer) backoff(retries int) {
+ var backoff time.Duration
+ if pp.parent.conf.Producer.Retry.BackoffFunc != nil {
+ maxRetries := pp.parent.conf.Producer.Retry.Max
+ backoff = pp.parent.conf.Producer.Retry.BackoffFunc(retries, maxRetries)
+ } else {
+ backoff = pp.parent.conf.Producer.Retry.Backoff
+ }
+ if backoff > 0 {
+ time.Sleep(backoff)
+ }
+}
+
func (pp *partitionProducer) dispatch() {
// try to prefetch the leader; if this doesn't work, we'll do a proper call to `updateLeader`
// on the first message
@@ -493,11 +506,31 @@
pp.brokerProducer.input <- &ProducerMessage{Topic: pp.topic, Partition: pp.partition, flags: syn}
}
+ defer func() {
+ if pp.brokerProducer != nil {
+ pp.parent.unrefBrokerProducer(pp.leader, pp.brokerProducer)
+ }
+ }()
+
for msg := range pp.input {
+
+ if pp.brokerProducer != nil && pp.brokerProducer.abandoned != nil {
+ select {
+ case <-pp.brokerProducer.abandoned:
+ // a message on the abandoned channel means that our current broker selection is out of date
+ Logger.Printf("producer/leader/%s/%d abandoning broker %d\n", pp.topic, pp.partition, pp.leader.ID())
+ pp.parent.unrefBrokerProducer(pp.leader, pp.brokerProducer)
+ pp.brokerProducer = nil
+ time.Sleep(pp.parent.conf.Producer.Retry.Backoff)
+ default:
+ // producer connection is still open.
+ }
+ }
+
if msg.retries > pp.highWatermark {
// a new, higher, retry level; handle it and then back off
pp.newHighWatermark(msg.retries)
- time.Sleep(pp.parent.conf.Producer.Retry.Backoff)
+ pp.backoff(msg.retries)
} else if pp.highWatermark > 0 {
// we are retrying something (else highWatermark would be 0) but this message is not a *new* retry level
if msg.retries < pp.highWatermark {
@@ -525,7 +558,7 @@
if pp.brokerProducer == nil {
if err := pp.updateLeader(); err != nil {
pp.parent.returnError(msg, err)
- time.Sleep(pp.parent.conf.Producer.Retry.Backoff)
+ pp.backoff(msg.retries)
continue
}
Logger.Printf("producer/leader/%s/%d selected broker %d\n", pp.topic, pp.partition, pp.leader.ID())
@@ -533,10 +566,6 @@
pp.brokerProducer.input <- msg
}
-
- if pp.brokerProducer != nil {
- pp.parent.unrefBrokerProducer(pp.leader, pp.brokerProducer)
- }
}
func (pp *partitionProducer) newHighWatermark(hwm int) {
@@ -637,6 +666,10 @@
close(responses)
})
+ if p.conf.Producer.Retry.Max <= 0 {
+ bp.abandoned = make(chan struct{})
+ }
+
return bp
}
@@ -655,6 +688,7 @@
input chan *ProducerMessage
output chan<- *produceSet
responses <-chan *brokerProducerResponse
+ abandoned chan struct{}
buffer *produceSet
timer <-chan time.Time
@@ -829,9 +863,17 @@
// Retriable errors
case ErrInvalidMessage, ErrUnknownTopicOrPartition, ErrLeaderNotAvailable, ErrNotLeaderForPartition,
ErrRequestTimedOut, ErrNotEnoughReplicas, ErrNotEnoughReplicasAfterAppend:
- retryTopics = append(retryTopics, topic)
+ if bp.parent.conf.Producer.Retry.Max <= 0 {
+ bp.parent.abandonBrokerConnection(bp.broker)
+ bp.parent.returnErrors(pSet.msgs, block.Err)
+ } else {
+ retryTopics = append(retryTopics, topic)
+ }
// Other non-retriable errors
default:
+ if bp.parent.conf.Producer.Retry.Max <= 0 {
+ bp.parent.abandonBrokerConnection(bp.broker)
+ }
bp.parent.returnErrors(pSet.msgs, block.Err)
}
})
@@ -1048,5 +1090,10 @@
p.brokerLock.Lock()
defer p.brokerLock.Unlock()
+ bc, ok := p.brokers[broker]
+ if ok && bc.abandoned != nil {
+ close(bc.abandoned)
+ }
+
delete(p.brokers, broker)
}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/broker.go b/vendor/gopkg.in/Shopify/sarama.v1/broker.go
index 6a33b80..9129089 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/broker.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/broker.go
@@ -6,7 +6,9 @@
"fmt"
"io"
"net"
+ "sort"
"strconv"
+ "strings"
"sync"
"sync/atomic"
"time"
@@ -46,6 +48,50 @@
brokerResponseSize metrics.Histogram
}
+// SASLMechanism specifies the SASL mechanism the client uses to authenticate with the broker
+type SASLMechanism string
+
+const (
+ // SASLTypeOAuth represents the SASL/OAUTHBEARER mechanism (Kafka 2.0.0+)
+ SASLTypeOAuth = "OAUTHBEARER"
+ // SASLTypePlaintext represents the SASL/PLAIN mechanism
+ SASLTypePlaintext = "PLAIN"
+ // SASLHandshakeV0 is v0 of the Kafka SASL handshake protocol. Client and
+ // server negotiate SASL auth using opaque packets.
+ SASLHandshakeV0 = int16(0)
+ // SASLHandshakeV1 is v1 of the Kafka SASL handshake protocol. Client and
+ // server negotiate SASL by wrapping tokens with Kafka protocol headers.
+ SASLHandshakeV1 = int16(1)
+ // SASLExtKeyAuth is the reserved extension key name sent as part of the
+ // SASL/OAUTHBEARER intial client response
+ SASLExtKeyAuth = "auth"
+)
+
+// AccessToken contains an access token used to authenticate a
+// SASL/OAUTHBEARER client along with associated metadata.
+type AccessToken struct {
+ // Token is the access token payload.
+ Token string
+ // Extensions is a optional map of arbitrary key-value pairs that can be
+ // sent with the SASL/OAUTHBEARER initial client response. These values are
+ // ignored by the SASL server if they are unexpected. This feature is only
+ // supported by Kafka >= 2.1.0.
+ Extensions map[string]string
+}
+
+// AccessTokenProvider is the interface that encapsulates how implementors
+// can generate access tokens for Kafka broker authentication.
+type AccessTokenProvider interface {
+ // Token returns an access token. The implementation should ensure token
+ // reuse so that multiple calls at connect time do not create multiple
+ // tokens. The implementation should also periodically refresh the token in
+ // order to guarantee that each call returns an unexpired token. This
+ // method should not block indefinitely--a timeout error should be returned
+ // after a short period of inactivity so that the broker connection logic
+ // can log debugging information and retry.
+ Token() (*AccessToken, error)
+}
+
type responsePromise struct {
requestTime time.Time
correlationID int32
@@ -125,7 +171,9 @@
}
if conf.Net.SASL.Enable {
- b.connErr = b.sendAndReceiveSASLPlainAuth()
+
+ b.connErr = b.authenticateViaSASL()
+
if b.connErr != nil {
err = b.conn.Close()
if err == nil {
@@ -744,8 +792,16 @@
close(b.done)
}
-func (b *Broker) sendAndReceiveSASLPlainHandshake() error {
- rb := &SaslHandshakeRequest{"PLAIN"}
+func (b *Broker) authenticateViaSASL() error {
+ if b.conf.Net.SASL.Mechanism == SASLTypeOAuth {
+ return b.sendAndReceiveSASLOAuth(b.conf.Net.SASL.TokenProvider)
+ }
+ return b.sendAndReceiveSASLPlainAuth()
+}
+
+func (b *Broker) sendAndReceiveSASLHandshake(saslType string, version int16) error {
+ rb := &SaslHandshakeRequest{Mechanism: saslType, Version: version}
+
req := &request{correlationID: b.correlationID, clientID: b.conf.ClientID, body: rb}
buf, err := encode(req, b.conf.MetricRegistry)
if err != nil {
@@ -814,7 +870,7 @@
// of responding to bad credentials but thats how its being done today.
func (b *Broker) sendAndReceiveSASLPlainAuth() error {
if b.conf.Net.SASL.Handshake {
- handshakeErr := b.sendAndReceiveSASLPlainHandshake()
+ handshakeErr := b.sendAndReceiveSASLHandshake(SASLTypePlaintext, SASLHandshakeV0)
if handshakeErr != nil {
Logger.Printf("Error while performing SASL handshake %s\n", b.addr)
return handshakeErr
@@ -853,6 +909,157 @@
return nil
}
+// sendAndReceiveSASLOAuth performs the authentication flow as described by KIP-255
+// https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=75968876
+func (b *Broker) sendAndReceiveSASLOAuth(provider AccessTokenProvider) error {
+
+ if err := b.sendAndReceiveSASLHandshake(SASLTypeOAuth, SASLHandshakeV1); err != nil {
+ return err
+ }
+
+ token, err := provider.Token()
+
+ if err != nil {
+ return err
+ }
+
+ requestTime := time.Now()
+
+ correlationID := b.correlationID
+
+ bytesWritten, err := b.sendSASLOAuthBearerClientResponse(token, correlationID)
+
+ if err != nil {
+ return err
+ }
+
+ b.updateOutgoingCommunicationMetrics(bytesWritten)
+
+ b.correlationID++
+
+ bytesRead, err := b.receiveSASLOAuthBearerServerResponse(correlationID)
+
+ if err != nil {
+ return err
+ }
+
+ requestLatency := time.Since(requestTime)
+ b.updateIncomingCommunicationMetrics(bytesRead, requestLatency)
+
+ return nil
+}
+
+// Build SASL/OAUTHBEARER initial client response as described by RFC-7628
+// https://tools.ietf.org/html/rfc7628
+func buildClientInitialResponse(token *AccessToken) ([]byte, error) {
+
+ var ext string
+
+ if token.Extensions != nil && len(token.Extensions) > 0 {
+ if _, ok := token.Extensions[SASLExtKeyAuth]; ok {
+ return []byte{}, fmt.Errorf("The extension `%s` is invalid", SASLExtKeyAuth)
+ }
+ ext = "\x01" + mapToString(token.Extensions, "=", "\x01")
+ }
+
+ resp := []byte(fmt.Sprintf("n,,\x01auth=Bearer %s%s\x01\x01", token.Token, ext))
+
+ return resp, nil
+}
+
+// mapToString returns a list of key-value pairs ordered by key.
+// keyValSep separates the key from the value. elemSep separates each pair.
+func mapToString(extensions map[string]string, keyValSep string, elemSep string) string {
+
+ buf := make([]string, 0, len(extensions))
+
+ for k, v := range extensions {
+ buf = append(buf, k+keyValSep+v)
+ }
+
+ sort.Strings(buf)
+
+ return strings.Join(buf, elemSep)
+}
+
+func (b *Broker) sendSASLOAuthBearerClientResponse(token *AccessToken, correlationID int32) (int, error) {
+
+ initialResp, err := buildClientInitialResponse(token)
+
+ if err != nil {
+ return 0, err
+ }
+
+ rb := &SaslAuthenticateRequest{initialResp}
+
+ req := &request{correlationID: correlationID, clientID: b.conf.ClientID, body: rb}
+
+ buf, err := encode(req, b.conf.MetricRegistry)
+
+ if err != nil {
+ return 0, err
+ }
+
+ if err := b.conn.SetWriteDeadline(time.Now().Add(b.conf.Net.WriteTimeout)); err != nil {
+ return 0, err
+ }
+
+ return b.conn.Write(buf)
+}
+
+func (b *Broker) receiveSASLOAuthBearerServerResponse(correlationID int32) (int, error) {
+
+ buf := make([]byte, 8)
+
+ bytesRead, err := io.ReadFull(b.conn, buf)
+
+ if err != nil {
+ return bytesRead, err
+ }
+
+ header := responseHeader{}
+
+ err = decode(buf, &header)
+
+ if err != nil {
+ return bytesRead, err
+ }
+
+ if header.correlationID != correlationID {
+ return bytesRead, fmt.Errorf("correlation ID didn't match, wanted %d, got %d", b.correlationID, header.correlationID)
+ }
+
+ buf = make([]byte, header.length-4)
+
+ c, err := io.ReadFull(b.conn, buf)
+
+ bytesRead += c
+
+ if err != nil {
+ return bytesRead, err
+ }
+
+ res := &SaslAuthenticateResponse{}
+
+ if err := versionedDecode(buf, res, 0); err != nil {
+ return bytesRead, err
+ }
+
+ if err != nil {
+ return bytesRead, err
+ }
+
+ if res.Err != ErrNoError {
+ return bytesRead, res.Err
+ }
+
+ if len(res.SaslAuthBytes) > 0 {
+ Logger.Printf("Received SASL auth response: %s", res.SaslAuthBytes)
+ }
+
+ return bytesRead, nil
+}
+
func (b *Broker) updateIncomingCommunicationMetrics(bytes int, requestLatency time.Duration) {
b.updateRequestLatencyMetrics(requestLatency)
b.responseRate.Mark(1)
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/client.go b/vendor/gopkg.in/Shopify/sarama.v1/client.go
index 79be5ce..0016f8f 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/client.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/client.go
@@ -710,8 +710,11 @@
func (client *client) tryRefreshMetadata(topics []string, attemptsRemaining int) error {
retry := func(err error) error {
if attemptsRemaining > 0 {
+ backoff := client.computeBackoff(attemptsRemaining)
Logger.Printf("client/metadata retrying after %dms... (%d attempts remaining)\n", client.conf.Metadata.Retry.Backoff/time.Millisecond, attemptsRemaining)
- time.Sleep(client.conf.Metadata.Retry.Backoff)
+ if backoff > 0 {
+ time.Sleep(backoff)
+ }
return client.tryRefreshMetadata(topics, attemptsRemaining-1)
}
return err
@@ -839,11 +842,22 @@
return client.brokers[client.controllerID]
}
+func (client *client) computeBackoff(attemptsRemaining int) time.Duration {
+ if client.conf.Metadata.Retry.BackoffFunc != nil {
+ maxRetries := client.conf.Metadata.Retry.Max
+ retries := maxRetries - attemptsRemaining
+ return client.conf.Metadata.Retry.BackoffFunc(retries, maxRetries)
+ } else {
+ return client.conf.Metadata.Retry.Backoff
+ }
+}
+
func (client *client) getConsumerMetadata(consumerGroup string, attemptsRemaining int) (*FindCoordinatorResponse, error) {
retry := func(err error) (*FindCoordinatorResponse, error) {
if attemptsRemaining > 0 {
- Logger.Printf("client/coordinator retrying after %dms... (%d attempts remaining)\n", client.conf.Metadata.Retry.Backoff/time.Millisecond, attemptsRemaining)
- time.Sleep(client.conf.Metadata.Retry.Backoff)
+ backoff := client.computeBackoff(attemptsRemaining)
+ Logger.Printf("client/coordinator retrying after %dms... (%d attempts remaining)\n", backoff/time.Millisecond, attemptsRemaining)
+ time.Sleep(backoff)
return client.getConsumerMetadata(consumerGroup, attemptsRemaining-1)
}
return nil, err
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/config.go b/vendor/gopkg.in/Shopify/sarama.v1/config.go
index ed20522..9495b7f 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/config.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/config.go
@@ -54,6 +54,9 @@
// Whether or not to use SASL authentication when connecting to the broker
// (defaults to false).
Enable bool
+ // SASLMechanism is the name of the enabled SASL mechanism.
+ // Possible values: OAUTHBEARER, PLAIN (defaults to PLAIN).
+ Mechanism SASLMechanism
// Whether or not to send the Kafka SASL handshake first if enabled
// (defaults to true). You should only set this to false if you're using
// a non-Kafka SASL proxy.
@@ -61,6 +64,11 @@
//username and password for SASL/PLAIN authentication
User string
Password string
+ // TokenProvider is a user-defined callback for generating
+ // access tokens for SASL/OAUTHBEARER auth. See the
+ // AccessTokenProvider interface docs for proper implementation
+ // guidelines.
+ TokenProvider AccessTokenProvider
}
// KeepAlive specifies the keep-alive period for an active network connection.
@@ -84,6 +92,10 @@
// How long to wait for leader election to occur before retrying
// (default 250ms). Similar to the JVM's `retry.backoff.ms`.
Backoff time.Duration
+ // Called to compute backoff time dynamically. Useful for implementing
+ // more sophisticated backoff strategies. This takes precedence over
+ // `Backoff` if set.
+ BackoffFunc func(retries, maxRetries int) time.Duration
}
// How frequently to refresh the cluster metadata in the background.
// Defaults to 10 minutes. Set to 0 to disable. Similar to
@@ -171,6 +183,10 @@
// (default 100ms). Similar to the `retry.backoff.ms` setting of the
// JVM producer.
Backoff time.Duration
+ // Called to compute backoff time dynamically. Useful for implementing
+ // more sophisticated backoff strategies. This takes precedence over
+ // `Backoff` if set.
+ BackoffFunc func(retries, maxRetries int) time.Duration
}
}
@@ -229,6 +245,10 @@
// How long to wait after a failing to read from a partition before
// trying again (default 2s).
Backoff time.Duration
+ // Called to compute backoff time dynamically. Useful for implementing
+ // more sophisticated backoff strategies. This takes precedence over
+ // `Backoff` if set.
+ BackoffFunc func(retries int) time.Duration
}
// Fetch is the namespace for controlling how many bytes are retrieved by any
@@ -454,10 +474,25 @@
return ConfigurationError("Net.WriteTimeout must be > 0")
case c.Net.KeepAlive < 0:
return ConfigurationError("Net.KeepAlive must be >= 0")
- case c.Net.SASL.Enable == true && c.Net.SASL.User == "":
- return ConfigurationError("Net.SASL.User must not be empty when SASL is enabled")
- case c.Net.SASL.Enable == true && c.Net.SASL.Password == "":
- return ConfigurationError("Net.SASL.Password must not be empty when SASL is enabled")
+ case c.Net.SASL.Enable:
+ // For backwards compatibility, empty mechanism value defaults to PLAIN
+ isSASLPlain := len(c.Net.SASL.Mechanism) == 0 || c.Net.SASL.Mechanism == SASLTypePlaintext
+ if isSASLPlain {
+ if c.Net.SASL.User == "" {
+ return ConfigurationError("Net.SASL.User must not be empty when SASL is enabled")
+ }
+ if c.Net.SASL.Password == "" {
+ return ConfigurationError("Net.SASL.Password must not be empty when SASL is enabled")
+ }
+ } else if c.Net.SASL.Mechanism == SASLTypeOAuth {
+ if c.Net.SASL.TokenProvider == nil {
+ return ConfigurationError("An AccessTokenProvider instance must be provided to Net.SASL.User.TokenProvider")
+ }
+ } else {
+ msg := fmt.Sprintf("The SASL mechanism configuration is invalid. Possible values are `%s` and `%s`",
+ SASLTypeOAuth, SASLTypePlaintext)
+ return ConfigurationError(msg)
+ }
}
// validate the Admin values
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/consumer.go b/vendor/gopkg.in/Shopify/sarama.v1/consumer.go
index 33d9d14..ce72ff1 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/consumer.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/consumer.go
@@ -314,6 +314,8 @@
fetchSize int32
offset int64
+
+ retries int32
}
var errTimedOut = errors.New("timed out feeding messages to the user") // not user-facing
@@ -332,12 +334,21 @@
}
}
+func (child *partitionConsumer) computeBackoff() time.Duration {
+ if child.conf.Consumer.Retry.BackoffFunc != nil {
+ retries := atomic.AddInt32(&child.retries, 1)
+ return child.conf.Consumer.Retry.BackoffFunc(int(retries))
+ } else {
+ return child.conf.Consumer.Retry.Backoff
+ }
+}
+
func (child *partitionConsumer) dispatcher() {
for range child.trigger {
select {
case <-child.dying:
close(child.trigger)
- case <-time.After(child.conf.Consumer.Retry.Backoff):
+ case <-time.After(child.computeBackoff()):
if child.broker != nil {
child.consumer.unrefBrokerConsumer(child.broker)
child.broker = nil
@@ -451,6 +462,10 @@
for response := range child.feeder {
msgs, child.responseResult = child.parseResponse(response)
+ if child.responseResult == nil {
+ atomic.StoreInt32(&child.retries, 0)
+ }
+
for i, msg := range msgs {
messageSelect:
select {
@@ -487,9 +502,13 @@
for _, msgBlock := range msgSet.Messages {
for _, msg := range msgBlock.Messages() {
offset := msg.Offset
+ timestamp := msg.Msg.Timestamp
if msg.Msg.Version >= 1 {
baseOffset := msgBlock.Offset - msgBlock.Messages()[len(msgBlock.Messages())-1].Offset
offset += baseOffset
+ if msg.Msg.LogAppendTime {
+ timestamp = msgBlock.Msg.Timestamp
+ }
}
if offset < child.offset {
continue
@@ -500,14 +519,14 @@
Key: msg.Msg.Key,
Value: msg.Msg.Value,
Offset: offset,
- Timestamp: msg.Msg.Timestamp,
+ Timestamp: timestamp,
BlockTimestamp: msgBlock.Msg.Timestamp,
})
child.offset = offset + 1
}
}
if len(messages) == 0 {
- return nil, ErrIncompleteResponse
+ child.offset++
}
return messages, nil
}
@@ -519,19 +538,23 @@
if offset < child.offset {
continue
}
+ timestamp := batch.FirstTimestamp.Add(rec.TimestampDelta)
+ if batch.LogAppendTime {
+ timestamp = batch.MaxTimestamp
+ }
messages = append(messages, &ConsumerMessage{
Topic: child.topic,
Partition: child.partition,
Key: rec.Key,
Value: rec.Value,
Offset: offset,
- Timestamp: batch.FirstTimestamp.Add(rec.TimestampDelta),
+ Timestamp: timestamp,
Headers: rec.Headers,
})
child.offset = offset + 1
}
if len(messages) == 0 {
- child.offset += 1
+ child.offset++
}
return messages, nil
}
@@ -787,6 +810,9 @@
MinBytes: bc.consumer.conf.Consumer.Fetch.Min,
MaxWaitTime: int32(bc.consumer.conf.Consumer.MaxWaitTime / time.Millisecond),
}
+ if bc.consumer.conf.Version.IsAtLeast(V0_9_0_0) {
+ request.Version = 1
+ }
if bc.consumer.conf.Version.IsAtLeast(V0_10_0_0) {
request.Version = 2
}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/consumer_group.go b/vendor/gopkg.in/Shopify/sarama.v1/consumer_group.go
index bb6a2c2..8c8babc 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/consumer_group.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/consumer_group.go
@@ -657,6 +657,12 @@
resp, err := s.parent.heartbeatRequest(coordinator, s.memberID, s.generationID)
if err != nil {
_ = coordinator.Close()
+
+ if retries <= 0 {
+ s.parent.handleError(err, "", -1)
+ return
+ }
+
retries--
continue
}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/describe_configs_request.go b/vendor/gopkg.in/Shopify/sarama.v1/describe_configs_request.go
index 416a4fe..ccb587b 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/describe_configs_request.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/describe_configs_request.go
@@ -103,7 +103,7 @@
func (r *DescribeConfigsRequest) requiredVersion() KafkaVersion {
switch r.Version {
case 1:
- return V1_0_0_0
+ return V1_1_0_0
case 2:
return V2_0_0_0
default:
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/errors.go b/vendor/gopkg.in/Shopify/sarama.v1/errors.go
index c11421d..87a4c61 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/errors.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/errors.go
@@ -157,6 +157,10 @@
ErrFetchSessionIDNotFound KError = 70
ErrInvalidFetchSessionEpoch KError = 71
ErrListenerNotFound KError = 72
+ ErrTopicDeletionDisabled KError = 73
+ ErrFencedLeaderEpoch KError = 74
+ ErrUnknownLeaderEpoch KError = 75
+ ErrUnsupportedCompressionType KError = 76
)
func (err KError) Error() string {
@@ -311,6 +315,14 @@
return "kafka server: The fetch session epoch is invalid."
case ErrListenerNotFound:
return "kafka server: There is no listener on the leader broker that matches the listener on which metadata request was processed."
+ case ErrTopicDeletionDisabled:
+ return "kafka server: Topic deletion is disabled."
+ case ErrFencedLeaderEpoch:
+ return "kafka server: The leader epoch in the request is older than the epoch on the broker."
+ case ErrUnknownLeaderEpoch:
+ return "kafka server: The leader epoch in the request is newer than the epoch on the broker."
+ case ErrUnsupportedCompressionType:
+ return "kafka server: The requesting client does not support the compression type of given partition."
}
return fmt.Sprintf("Unknown error, how did this happen? Error code = %d", err)
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/fetch_response.go b/vendor/gopkg.in/Shopify/sarama.v1/fetch_response.go
index 90acfc2..9df99c1 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/fetch_response.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/fetch_response.go
@@ -186,9 +186,11 @@
}
type FetchResponse struct {
- Blocks map[string]map[int32]*FetchResponseBlock
- ThrottleTime time.Duration
- Version int16 // v1 requires 0.9+, v2 requires 0.10+
+ Blocks map[string]map[int32]*FetchResponseBlock
+ ThrottleTime time.Duration
+ Version int16 // v1 requires 0.9+, v2 requires 0.10+
+ LogAppendTime bool
+ Timestamp time.Time
}
func (r *FetchResponse) decode(pd packetDecoder, version int16) (err error) {
@@ -355,10 +357,13 @@
return kb, vb
}
-func (r *FetchResponse) AddMessage(topic string, partition int32, key, value Encoder, offset int64) {
+func (r *FetchResponse) AddMessageWithTimestamp(topic string, partition int32, key, value Encoder, offset int64, timestamp time.Time, version int8) {
frb := r.getOrCreateBlock(topic, partition)
kb, vb := encodeKV(key, value)
- msg := &Message{Key: kb, Value: vb}
+ if r.LogAppendTime {
+ timestamp = r.Timestamp
+ }
+ msg := &Message{Key: kb, Value: vb, LogAppendTime: r.LogAppendTime, Timestamp: timestamp, Version: version}
msgBlock := &MessageBlock{Msg: msg, Offset: offset}
if len(frb.RecordsSet) == 0 {
records := newLegacyRecords(&MessageSet{})
@@ -368,18 +373,26 @@
set.Messages = append(set.Messages, msgBlock)
}
-func (r *FetchResponse) AddRecord(topic string, partition int32, key, value Encoder, offset int64) {
+func (r *FetchResponse) AddRecordWithTimestamp(topic string, partition int32, key, value Encoder, offset int64, timestamp time.Time) {
frb := r.getOrCreateBlock(topic, partition)
kb, vb := encodeKV(key, value)
- rec := &Record{Key: kb, Value: vb, OffsetDelta: offset}
if len(frb.RecordsSet) == 0 {
- records := newDefaultRecords(&RecordBatch{Version: 2})
+ records := newDefaultRecords(&RecordBatch{Version: 2, LogAppendTime: r.LogAppendTime, FirstTimestamp: timestamp, MaxTimestamp: r.Timestamp})
frb.RecordsSet = []*Records{&records}
}
batch := frb.RecordsSet[0].RecordBatch
+ rec := &Record{Key: kb, Value: vb, OffsetDelta: offset, TimestampDelta: timestamp.Sub(batch.FirstTimestamp)}
batch.addRecord(rec)
}
+func (r *FetchResponse) AddMessage(topic string, partition int32, key, value Encoder, offset int64) {
+ r.AddMessageWithTimestamp(topic, partition, key, value, offset, time.Time{}, 0)
+}
+
+func (r *FetchResponse) AddRecord(topic string, partition int32, key, value Encoder, offset int64) {
+ r.AddRecordWithTimestamp(topic, partition, key, value, offset, time.Time{})
+}
+
func (r *FetchResponse) SetLastOffsetDelta(topic string, partition int32, offset int32) {
frb := r.getOrCreateBlock(topic, partition)
if len(frb.RecordsSet) == 0 {
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/message.go b/vendor/gopkg.in/Shopify/sarama.v1/message.go
index 51d3309..f64c79b 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/message.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/message.go
@@ -5,12 +5,15 @@
"time"
)
-// CompressionCodec represents the various compression codecs recognized by Kafka in messages.
-type CompressionCodec int8
-
// The lowest 3 bits contain the compression codec used for the message
const compressionCodecMask int8 = 0x07
+// Bit 3 set for "LogAppend" timestamps
+const timestampTypeMask = 0x08
+
+// CompressionCodec represents the various compression codecs recognized by Kafka in messages.
+type CompressionCodec int8
+
const (
CompressionNone CompressionCodec = 0
CompressionGZIP CompressionCodec = 1
@@ -36,6 +39,7 @@
type Message struct {
Codec CompressionCodec // codec used to compress the message contents
CompressionLevel int // compression level
+ LogAppendTime bool // the used timestamp is LogAppendTime
Key []byte // the message key, may be nil
Value []byte // the message contents
Set *MessageSet // the message set a message might wrap
@@ -52,6 +56,9 @@
pe.putInt8(m.Version)
attributes := int8(m.Codec) & compressionCodecMask
+ if m.LogAppendTime {
+ attributes |= timestampTypeMask
+ }
pe.putInt8(attributes)
if m.Version >= 1 {
@@ -108,6 +115,7 @@
return err
}
m.Codec = CompressionCodec(attribute & compressionCodecMask)
+ m.LogAppendTime = attribute×tampTypeMask == timestampTypeMask
if m.Version == 1 {
if err := (Timestamp{&m.Timestamp}).decode(pd); err != nil {
@@ -149,7 +157,7 @@
return pd.pop()
}
-// decodes a message set from a previousy encoded bulk-message
+// decodes a message set from a previously encoded bulk-message
func (m *Message) decodeSet() (err error) {
pd := realDecoder{raw: m.Value}
m.Set = &MessageSet{}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/mockresponses.go b/vendor/gopkg.in/Shopify/sarama.v1/mockresponses.go
index fe55200..348c223 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/mockresponses.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/mockresponses.go
@@ -66,6 +66,69 @@
return res
}
+type MockListGroupsResponse struct {
+ groups map[string]string
+ t TestReporter
+}
+
+func NewMockListGroupsResponse(t TestReporter) *MockListGroupsResponse {
+ return &MockListGroupsResponse{
+ groups: make(map[string]string),
+ t: t,
+ }
+}
+
+func (m *MockListGroupsResponse) For(reqBody versionedDecoder) encoder {
+ request := reqBody.(*ListGroupsRequest)
+ _ = request
+ response := &ListGroupsResponse{
+ Groups: m.groups,
+ }
+ return response
+}
+
+func (m *MockListGroupsResponse) AddGroup(groupID, protocolType string) *MockListGroupsResponse {
+ m.groups[groupID] = protocolType
+ return m
+}
+
+type MockDescribeGroupsResponse struct {
+ groups map[string]*GroupDescription
+ t TestReporter
+}
+
+func NewMockDescribeGroupsResponse(t TestReporter) *MockDescribeGroupsResponse {
+ return &MockDescribeGroupsResponse{
+ t: t,
+ groups: make(map[string]*GroupDescription),
+ }
+}
+
+func (m *MockDescribeGroupsResponse) AddGroupDescription(groupID string, description *GroupDescription) *MockDescribeGroupsResponse {
+ m.groups[groupID] = description
+ return m
+}
+
+func (m *MockDescribeGroupsResponse) For(reqBody versionedDecoder) encoder {
+ request := reqBody.(*DescribeGroupsRequest)
+
+ response := &DescribeGroupsResponse{}
+ for _, requestedGroup := range request.Groups {
+ if group, ok := m.groups[requestedGroup]; ok {
+ response.Groups = append(response.Groups, group)
+ } else {
+ // Mimic real kafka - if a group doesn't exist, return
+ // an entry with state "Dead"
+ response.Groups = append(response.Groups, &GroupDescription{
+ GroupId: requestedGroup,
+ State: "Dead",
+ })
+ }
+ }
+
+ return response
+}
+
// MockMetadataResponse is a `MetadataResponse` builder.
type MockMetadataResponse struct {
controllerID int32
@@ -111,17 +174,25 @@
for addr, brokerID := range mmr.brokers {
metadataResponse.AddBroker(addr, brokerID)
}
+
+ // Generate set of replicas
+ replicas := []int32{}
+
+ for _, brokerID := range mmr.brokers {
+ replicas = append(replicas, brokerID)
+ }
+
if len(metadataRequest.Topics) == 0 {
for topic, partitions := range mmr.leaders {
for partition, brokerID := range partitions {
- metadataResponse.AddTopicPartition(topic, partition, brokerID, nil, nil, ErrNoError)
+ metadataResponse.AddTopicPartition(topic, partition, brokerID, replicas, replicas, ErrNoError)
}
}
return metadataResponse
}
for _, topic := range metadataRequest.Topics {
for partition, brokerID := range mmr.leaders[topic] {
- metadataResponse.AddTopicPartition(topic, partition, brokerID, nil, nil, ErrNoError)
+ metadataResponse.AddTopicPartition(topic, partition, brokerID, replicas, replicas, ErrNoError)
}
}
return metadataResponse
@@ -631,16 +702,32 @@
req := reqBody.(*DescribeConfigsRequest)
res := &DescribeConfigsResponse{}
- var configEntries []*ConfigEntry
- configEntries = append(configEntries, &ConfigEntry{Name: "my_topic",
- Value: "my_topic",
- ReadOnly: true,
- Default: true,
- Sensitive: false,
- })
-
for _, r := range req.Resources {
- res.Resources = append(res.Resources, &ResourceResponse{Name: r.Name, Configs: configEntries})
+ var configEntries []*ConfigEntry
+ switch r.Type {
+ case TopicResource:
+ configEntries = append(configEntries,
+ &ConfigEntry{Name: "max.message.bytes",
+ Value: "1000000",
+ ReadOnly: false,
+ Default: true,
+ Sensitive: false,
+ }, &ConfigEntry{Name: "retention.ms",
+ Value: "5000",
+ ReadOnly: false,
+ Default: false,
+ Sensitive: false,
+ }, &ConfigEntry{Name: "password",
+ Value: "12345",
+ ReadOnly: false,
+ Default: false,
+ Sensitive: true,
+ })
+ res.Resources = append(res.Resources, &ResourceResponse{
+ Name: r.Name,
+ Configs: configEntries,
+ })
+ }
}
return res
}
@@ -706,10 +793,64 @@
return res
}
+type MockSaslAuthenticateResponse struct {
+ t TestReporter
+ kerror KError
+ saslAuthBytes []byte
+}
+
+func NewMockSaslAuthenticateResponse(t TestReporter) *MockSaslAuthenticateResponse {
+ return &MockSaslAuthenticateResponse{t: t}
+}
+
+func (msar *MockSaslAuthenticateResponse) For(reqBody versionedDecoder) encoder {
+ res := &SaslAuthenticateResponse{}
+ res.Err = msar.kerror
+ res.SaslAuthBytes = msar.saslAuthBytes
+ return res
+}
+
+func (msar *MockSaslAuthenticateResponse) SetError(kerror KError) *MockSaslAuthenticateResponse {
+ msar.kerror = kerror
+ return msar
+}
+
+func (msar *MockSaslAuthenticateResponse) SetAuthBytes(saslAuthBytes []byte) *MockSaslAuthenticateResponse {
+ msar.saslAuthBytes = saslAuthBytes
+ return msar
+}
+
type MockDeleteAclsResponse struct {
t TestReporter
}
+type MockSaslHandshakeResponse struct {
+ enabledMechanisms []string
+ kerror KError
+ t TestReporter
+}
+
+func NewMockSaslHandshakeResponse(t TestReporter) *MockSaslHandshakeResponse {
+ return &MockSaslHandshakeResponse{t: t}
+}
+
+func (mshr *MockSaslHandshakeResponse) For(reqBody versionedDecoder) encoder {
+ res := &SaslHandshakeResponse{}
+ res.Err = mshr.kerror
+ res.EnabledMechanisms = mshr.enabledMechanisms
+ return res
+}
+
+func (mshr *MockSaslHandshakeResponse) SetError(kerror KError) *MockSaslHandshakeResponse {
+ mshr.kerror = kerror
+ return mshr
+}
+
+func (mshr *MockSaslHandshakeResponse) SetEnabledMechanisms(enabledMechanisms []string) *MockSaslHandshakeResponse {
+ mshr.enabledMechanisms = enabledMechanisms
+ return mshr
+}
+
func NewMockDeleteAclsResponse(t TestReporter) *MockDeleteAclsResponse {
return &MockDeleteAclsResponse{t: t}
}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/offset_manager.go b/vendor/gopkg.in/Shopify/sarama.v1/offset_manager.go
index 8ea857f..2432f7b 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/offset_manager.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/offset_manager.go
@@ -120,6 +120,14 @@
return nil
}
+func (om *offsetManager) computeBackoff(retries int) time.Duration {
+ if om.conf.Metadata.Retry.BackoffFunc != nil {
+ return om.conf.Metadata.Retry.BackoffFunc(retries, om.conf.Metadata.Retry.Max)
+ } else {
+ return om.conf.Metadata.Retry.Backoff
+ }
+}
+
func (om *offsetManager) fetchInitialOffset(topic string, partition int32, retries int) (int64, string, error) {
broker, err := om.coordinator()
if err != nil {
@@ -161,10 +169,11 @@
if retries <= 0 {
return 0, "", block.Err
}
+ backoff := om.computeBackoff(retries)
select {
case <-om.closing:
return 0, "", block.Err
- case <-time.After(om.conf.Metadata.Retry.Backoff):
+ case <-time.After(backoff):
}
return om.fetchInitialOffset(topic, partition, retries-1)
default:
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/record_batch.go b/vendor/gopkg.in/Shopify/sarama.v1/record_batch.go
index e0f183f..a36f7e6 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/record_batch.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/record_batch.go
@@ -36,6 +36,7 @@
Codec CompressionCodec
CompressionLevel int
Control bool
+ LogAppendTime bool
LastOffsetDelta int32
FirstTimestamp time.Time
MaxTimestamp time.Time
@@ -120,6 +121,7 @@
}
b.Codec = CompressionCodec(int8(attributes) & compressionCodecMask)
b.Control = attributes&controlMask == controlMask
+ b.LogAppendTime = attributes×tampTypeMask == timestampTypeMask
if b.LastOffsetDelta, err = pd.getInt32(); err != nil {
return err
@@ -200,6 +202,9 @@
if b.Control {
attr |= controlMask
}
+ if b.LogAppendTime {
+ attr |= timestampTypeMask
+ }
return attr
}
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/request.go b/vendor/gopkg.in/Shopify/sarama.v1/request.go
index 4d211a1..f7eea59 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/request.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/request.go
@@ -140,6 +140,8 @@
return &DescribeConfigsRequest{}
case 33:
return &AlterConfigsRequest{}
+ case 36:
+ return &SaslAuthenticateRequest{}
case 37:
return &CreatePartitionsRequest{}
case 42:
diff --git a/vendor/gopkg.in/Shopify/sarama.v1/sasl_handshake_request.go b/vendor/gopkg.in/Shopify/sarama.v1/sasl_handshake_request.go
index fbbc894..fe5ba05 100644
--- a/vendor/gopkg.in/Shopify/sarama.v1/sasl_handshake_request.go
+++ b/vendor/gopkg.in/Shopify/sarama.v1/sasl_handshake_request.go
@@ -2,6 +2,7 @@
type SaslHandshakeRequest struct {
Mechanism string
+ Version int16
}
func (r *SaslHandshakeRequest) encode(pe packetEncoder) error {
@@ -25,7 +26,7 @@
}
func (r *SaslHandshakeRequest) version() int16 {
- return 0
+ return r.Version
}
func (r *SaslHandshakeRequest) requiredVersion() KafkaVersion {
diff --git a/vendor/k8s.io/api/core/v1/generated.proto b/vendor/k8s.io/api/core/v1/generated.proto
index 165aa2a..b13a2db 100644
--- a/vendor/k8s.io/api/core/v1/generated.proto
+++ b/vendor/k8s.io/api/core/v1/generated.proto
@@ -3156,6 +3156,7 @@
// EnableServiceLinks indicates whether information about services should be injected into pod's
// environment variables, matching the syntax of Docker links.
+ // Optional: Defaults to true.
// +optional
optional bool enableServiceLinks = 30;
}
diff --git a/vendor/k8s.io/api/core/v1/types.go b/vendor/k8s.io/api/core/v1/types.go
index 43e70b9..87f3f0c 100644
--- a/vendor/k8s.io/api/core/v1/types.go
+++ b/vendor/k8s.io/api/core/v1/types.go
@@ -2920,6 +2920,7 @@
RuntimeClassName *string `json:"runtimeClassName,omitempty" protobuf:"bytes,29,opt,name=runtimeClassName"`
// EnableServiceLinks indicates whether information about services should be injected into pod's
// environment variables, matching the syntax of Docker links.
+ // Optional: Defaults to true.
// +optional
EnableServiceLinks *bool `json:"enableServiceLinks,omitempty" protobuf:"varint,30,opt,name=enableServiceLinks"`
}
diff --git a/vendor/k8s.io/api/core/v1/types_swagger_doc_generated.go b/vendor/k8s.io/api/core/v1/types_swagger_doc_generated.go
index 71f9068..13ea6d2 100644
--- a/vendor/k8s.io/api/core/v1/types_swagger_doc_generated.go
+++ b/vendor/k8s.io/api/core/v1/types_swagger_doc_generated.go
@@ -1540,7 +1540,7 @@
"dnsConfig": "Specifies the DNS parameters of a pod. Parameters specified here will be merged to the generated DNS configuration based on DNSPolicy.",
"readinessGates": "If specified, all readiness gates will be evaluated for pod readiness. A pod is ready when all its containers are ready AND all conditions specified in the readiness gates have status equal to \"True\" More info: https://github.com/kubernetes/community/blob/master/keps/sig-network/0007-pod-ready%2B%2B.md",
"runtimeClassName": "RuntimeClassName refers to a RuntimeClass object in the node.k8s.io group, which should be used to run this pod. If no RuntimeClass resource matches the named class, the pod will not be run. If unset or empty, the \"legacy\" RuntimeClass will be used, which is an implicit class with an empty definition that uses the default runtime handler. More info: https://github.com/kubernetes/community/blob/master/keps/sig-node/0014-runtime-class.md This is an alpha feature and may change in the future.",
- "enableServiceLinks": "EnableServiceLinks indicates whether information about services should be injected into pod's environment variables, matching the syntax of Docker links.",
+ "enableServiceLinks": "EnableServiceLinks indicates whether information about services should be injected into pod's environment variables, matching the syntax of Docker links. Optional: Defaults to true.",
}
func (PodSpec) SwaggerDoc() map[string]string {
diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go
index 4556889..69e6509 100644
--- a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go
+++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go
@@ -598,6 +598,10 @@
i += copy(dAtA[i:], s)
}
}
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintGenerated(dAtA, i, uint64(len(m.FieldManager)))
+ i += copy(dAtA[i:], m.FieldManager)
return i, nil
}
@@ -1559,6 +1563,10 @@
}
i++
}
+ dAtA[i] = 0x1a
+ i++
+ i = encodeVarintGenerated(dAtA, i, uint64(len(m.FieldManager)))
+ i += copy(dAtA[i:], m.FieldManager)
return i, nil
}
@@ -1583,6 +1591,12 @@
i = encodeVarintGenerated(dAtA, i, uint64(len(*m.UID)))
i += copy(dAtA[i:], *m.UID)
}
+ if m.ResourceVersion != nil {
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintGenerated(dAtA, i, uint64(len(*m.ResourceVersion)))
+ i += copy(dAtA[i:], *m.ResourceVersion)
+ }
return i, nil
}
@@ -1855,6 +1869,10 @@
i += copy(dAtA[i:], s)
}
}
+ dAtA[i] = 0x12
+ i++
+ i = encodeVarintGenerated(dAtA, i, uint64(len(m.FieldManager)))
+ i += copy(dAtA[i:], m.FieldManager)
return i, nil
}
@@ -2040,6 +2058,8 @@
n += 1 + l + sovGenerated(uint64(l))
}
}
+ l = len(m.FieldManager)
+ n += 1 + l + sovGenerated(uint64(l))
return n
}
@@ -2402,6 +2422,8 @@
if m.Force != nil {
n += 2
}
+ l = len(m.FieldManager)
+ n += 1 + l + sovGenerated(uint64(l))
return n
}
@@ -2412,6 +2434,10 @@
l = len(*m.UID)
n += 1 + l + sovGenerated(uint64(l))
}
+ if m.ResourceVersion != nil {
+ l = len(*m.ResourceVersion)
+ n += 1 + l + sovGenerated(uint64(l))
+ }
return n
}
@@ -2516,6 +2542,8 @@
n += 1 + l + sovGenerated(uint64(l))
}
}
+ l = len(m.FieldManager)
+ n += 1 + l + sovGenerated(uint64(l))
return n
}
@@ -2613,6 +2641,7 @@
}
s := strings.Join([]string{`&CreateOptions{`,
`DryRun:` + fmt.Sprintf("%v", this.DryRun) + `,`,
+ `FieldManager:` + fmt.Sprintf("%v", this.FieldManager) + `,`,
`}`,
}, "")
return s
@@ -2877,6 +2906,7 @@
s := strings.Join([]string{`&PatchOptions{`,
`DryRun:` + fmt.Sprintf("%v", this.DryRun) + `,`,
`Force:` + valueToStringGenerated(this.Force) + `,`,
+ `FieldManager:` + fmt.Sprintf("%v", this.FieldManager) + `,`,
`}`,
}, "")
return s
@@ -2887,6 +2917,7 @@
}
s := strings.Join([]string{`&Preconditions{`,
`UID:` + valueToStringGenerated(this.UID) + `,`,
+ `ResourceVersion:` + valueToStringGenerated(this.ResourceVersion) + `,`,
`}`,
}, "")
return s
@@ -2982,6 +3013,7 @@
}
s := strings.Join([]string{`&UpdateOptions{`,
`DryRun:` + fmt.Sprintf("%v", this.DryRun) + `,`,
+ `FieldManager:` + fmt.Sprintf("%v", this.FieldManager) + `,`,
`}`,
}, "")
return s
@@ -3870,6 +3902,35 @@
}
m.DryRun = append(m.DryRun, string(dAtA[iNdEx:postIndex]))
iNdEx = postIndex
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field FieldManager", wireType)
+ }
+ var stringLen uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowGenerated
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ stringLen |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ intStringLen := int(stringLen)
+ if intStringLen < 0 {
+ return ErrInvalidLengthGenerated
+ }
+ postIndex := iNdEx + intStringLen
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.FieldManager = string(dAtA[iNdEx:postIndex])
+ iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipGenerated(dAtA[iNdEx:])
@@ -7448,6 +7509,35 @@
}
b := bool(v != 0)
m.Force = &b
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field FieldManager", wireType)
+ }
+ var stringLen uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowGenerated
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ stringLen |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ intStringLen := int(stringLen)
+ if intStringLen < 0 {
+ return ErrInvalidLengthGenerated
+ }
+ postIndex := iNdEx + intStringLen
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.FieldManager = string(dAtA[iNdEx:postIndex])
+ iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipGenerated(dAtA[iNdEx:])
@@ -7528,6 +7618,36 @@
s := k8s_io_apimachinery_pkg_types.UID(dAtA[iNdEx:postIndex])
m.UID = &s
iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field ResourceVersion", wireType)
+ }
+ var stringLen uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowGenerated
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ stringLen |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ intStringLen := int(stringLen)
+ if intStringLen < 0 {
+ return ErrInvalidLengthGenerated
+ }
+ postIndex := iNdEx + intStringLen
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ s := string(dAtA[iNdEx:postIndex])
+ m.ResourceVersion = &s
+ iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipGenerated(dAtA[iNdEx:])
@@ -8562,6 +8682,35 @@
}
m.DryRun = append(m.DryRun, string(dAtA[iNdEx:postIndex]))
iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field FieldManager", wireType)
+ }
+ var stringLen uint64
+ for shift := uint(0); ; shift += 7 {
+ if shift >= 64 {
+ return ErrIntOverflowGenerated
+ }
+ if iNdEx >= l {
+ return io.ErrUnexpectedEOF
+ }
+ b := dAtA[iNdEx]
+ iNdEx++
+ stringLen |= (uint64(b) & 0x7F) << shift
+ if b < 0x80 {
+ break
+ }
+ }
+ intStringLen := int(stringLen)
+ if intStringLen < 0 {
+ return ErrInvalidLengthGenerated
+ }
+ postIndex := iNdEx + intStringLen
+ if postIndex > l {
+ return io.ErrUnexpectedEOF
+ }
+ m.FieldManager = string(dAtA[iNdEx:postIndex])
+ iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipGenerated(dAtA[iNdEx:])
@@ -8881,171 +9030,173 @@
}
var fileDescriptorGenerated = []byte{
- // 2643 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x39, 0x4d, 0x6c, 0x23, 0x49,
- 0xd5, 0x69, 0x3b, 0x76, 0xec, 0xe7, 0x38, 0x3f, 0xb5, 0xb3, 0xdf, 0xe7, 0xb5, 0x44, 0x9c, 0xed,
- 0x45, 0xab, 0x2c,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0xee, 0x9e, 0xc0, 0xa0, 0x3b, 0x90, 0xf7, 0xc4, 0x78, 0xa9, 0xb6, 0x9b, 0x13,
- 0x2e, 0x8a, 0xa2, 0x54, 0x95, 0x33, 0x2a, 0x56, 0xc2, 0x9a, 0x2b, 0x4f, 0x9e, 0x2e, 0x4d, 0x7d,
- 0xf4, 0x74, 0x69, 0xea, 0xe3, 0xa7, 0x4b, 0x53, 0xef, 0x9f, 0x2d, 0x19, 0x4f, 0xce, 0x96, 0x8c,
- 0x8f, 0xce, 0x96, 0x8c, 0x8f, 0xcf, 0x96, 0x8c, 0x4f, 0xce, 0x96, 0x8c, 0x47, 0x7f, 0x59, 0x9a,
- 0xba, 0x97, 0x39, 0x59, 0xfd, 0x57, 0x00, 0x00, 0x00, 0xff, 0xff, 0x0c, 0xb1, 0xa3, 0x81, 0x52,
- 0x23, 0x00, 0x00,
+ // 2674 bytes of a gzipped FileDescriptorProto
+ 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x19, 0x4d, 0x6c, 0x23, 0x57,
+ 0x39, 0x63, 0xc7, 0x8e, 0xfd, 0x39, 0xce, 0xcf, 0xeb, 0x16, 0x5c, 0x4b, 0xc4, 0xe9, 0x14, 0x55,
+ 0x29, 0x6c, 0x6d, 0x92, 0xd2, 0x6a, 0x59, 0x68, 0x21, 0x8e, 0x93, 0x6d, 0xe8, 0xa6, 0x89, 0x5e,
+ 0xba, 0x8b, 0x58, 0x56, 0x88, 0x89, 0xe7, 0xc5, 0x19, 0x62, 0xcf, 0x4c, 0xdf, 0x1b, 0x67, 0x37,
+ 0x70, 0xa0, 0x07, 0x10, 0x20, 0x41, 0xb5, 0x47, 0x4e, 0xa8, 0x2b, 0xb8, 0x70, 0xe5, 0xc4, 0x89,
+ 0x53, 0x25, 0xf6, 0x58, 0x89, 0x4b, 0x0f, 0xc8, 0xea, 0x06, 0x24, 0xb8, 0x71, 0xcf, 0x01, 0xa1,
+ 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, 0x90, 0xf7, 0xc4, 0x4c, 0xac, 0x56, 0xb2, 0x13, 0x6e,
+ 0xb7, 0xa2, 0x24, 0x97, 0x83, 0x35, 0x56, 0xc2, 0x9a, 0x2b, 0x8f, 0x1e, 0x2f, 0x4d, 0x7d, 0xf4,
+ 0x78, 0x69, 0xea, 0xe3, 0xc7, 0x4b, 0x53, 0xef, 0x9d, 0x2d, 0x19, 0x8f, 0xce, 0x96, 0x8c, 0x8f,
+ 0xce, 0x96, 0x8c, 0x8f, 0xcf, 0x96, 0x8c, 0x4f, 0xce, 0x96, 0x8c, 0x07, 0x7f, 0x5d, 0x9a, 0xba,
+ 0x93, 0x39, 0x59, 0xfd, 0x77, 0x00, 0x00, 0x00, 0xff, 0xff, 0xc3, 0x66, 0x55, 0x2c, 0x41, 0x24,
+ 0x00, 0x00,
}
diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto
index 9e564f3..36bda1f 100644
--- a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto
+++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto
@@ -143,6 +143,13 @@
// - All: all dry run stages will be processed
// +optional
repeated string dryRun = 1;
+
+ // fieldManager is a name associated with the actor or entity
+ // that is making these changes. The value must be less than or
+ // 128 characters long, and only contain printable characters,
+ // as defined by https://golang.org/pkg/unicode/#IsPrint.
+ // +optional
+ optional string fieldManager = 3;
}
// DeleteOptions may be provided when deleting an API object.
@@ -730,6 +737,16 @@
// flag must be unset for non-apply patch requests.
// +optional
optional bool force = 2;
+
+ // fieldManager is a name associated with the actor or entity
+ // that is making these changes. The value must be less than or
+ // 128 characters long, and only contain printable characters,
+ // as defined by https://golang.org/pkg/unicode/#IsPrint. This
+ // field is required for apply requests
+ // (application/apply-patch) but optional for non-apply patch
+ // types (JsonPatch, MergePatch, StrategicMergePatch).
+ // +optional
+ optional string fieldManager = 3;
}
// Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.
@@ -737,6 +754,10 @@
// Specifies the target UID.
// +optional
optional string uid = 1;
+
+ // Specifies the target ResourceVersion
+ // +optional
+ optional string resourceVersion = 2;
}
// RootPaths lists the paths available at root.
@@ -926,6 +947,13 @@
// - All: all dry run stages will be processed
// +optional
repeated string dryRun = 1;
+
+ // fieldManager is a name associated with the actor or entity
+ // that is making these changes. The value must be less than or
+ // 128 characters long, and only contain printable characters,
+ // as defined by https://golang.org/pkg/unicode/#IsPrint.
+ // +optional
+ optional string fieldManager = 2;
}
// Verbs masks the value so protobuf can generate
diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/helpers.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/helpers.go
index b41d549..b4dc78b 100644
--- a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/helpers.go
+++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/helpers.go
@@ -228,6 +228,12 @@
return &Preconditions{UID: &u}
}
+// NewRVDeletionPrecondition returns a DeleteOptions with a ResourceVersion precondition set.
+func NewRVDeletionPrecondition(rv string) *DeleteOptions {
+ p := Preconditions{ResourceVersion: &rv}
+ return &DeleteOptions{Preconditions: &p}
+}
+
// HasObjectMetaSystemFieldValues returns true if fields that are managed by the system on ObjectMeta have values.
func HasObjectMetaSystemFieldValues(meta Object) bool {
return !meta.GetCreationTimestamp().Time.IsZero() ||
diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types.go
index e957849..fd63952 100644
--- a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types.go
+++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types.go
@@ -506,6 +506,13 @@
// +optional
DryRun []string `json:"dryRun,omitempty" protobuf:"bytes,1,rep,name=dryRun"`
// +k8s:deprecated=includeUninitialized,protobuf=2
+
+ // fieldManager is a name associated with the actor or entity
+ // that is making these changes. The value must be less than or
+ // 128 characters long, and only contain printable characters,
+ // as defined by https://golang.org/pkg/unicode/#IsPrint.
+ // +optional
+ FieldManager string `json:"fieldManager,omitempty" protobuf:"bytes,3,name=fieldManager"`
}
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
@@ -528,6 +535,16 @@
// flag must be unset for non-apply patch requests.
// +optional
Force *bool `json:"force,omitempty" protobuf:"varint,2,opt,name=force"`
+
+ // fieldManager is a name associated with the actor or entity
+ // that is making these changes. The value must be less than or
+ // 128 characters long, and only contain printable characters,
+ // as defined by https://golang.org/pkg/unicode/#IsPrint. This
+ // field is required for apply requests
+ // (application/apply-patch) but optional for non-apply patch
+ // types (JsonPatch, MergePatch, StrategicMergePatch).
+ // +optional
+ FieldManager string `json:"fieldManager,omitempty" protobuf:"bytes,3,name=fieldManager"`
}
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
@@ -544,6 +561,13 @@
// - All: all dry run stages will be processed
// +optional
DryRun []string `json:"dryRun,omitempty" protobuf:"bytes,1,rep,name=dryRun"`
+
+ // fieldManager is a name associated with the actor or entity
+ // that is making these changes. The value must be less than or
+ // 128 characters long, and only contain printable characters,
+ // as defined by https://golang.org/pkg/unicode/#IsPrint.
+ // +optional
+ FieldManager string `json:"fieldManager,omitempty" protobuf:"bytes,2,name=fieldManager"`
}
// Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.
@@ -551,6 +575,9 @@
// Specifies the target UID.
// +optional
UID *types.UID `json:"uid,omitempty" protobuf:"bytes,1,opt,name=uid,casttype=k8s.io/apimachinery/pkg/types.UID"`
+ // Specifies the target ResourceVersion
+ // +optional
+ ResourceVersion *string `json:"resourceVersion,omitempty" protobuf:"bytes,2,opt,name=resourceVersion"`
}
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types_swagger_doc_generated.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types_swagger_doc_generated.go
index 71b2969..3b1a09e 100644
--- a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types_swagger_doc_generated.go
+++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types_swagger_doc_generated.go
@@ -87,8 +87,9 @@
}
var map_CreateOptions = map[string]string{
- "": "CreateOptions may be provided when creating an API object.",
- "dryRun": "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed",
+ "": "CreateOptions may be provided when creating an API object.",
+ "dryRun": "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed",
+ "fieldManager": "fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.",
}
func (CreateOptions) SwaggerDoc() map[string]string {
@@ -282,9 +283,10 @@
}
var map_PatchOptions = map[string]string{
- "": "PatchOptions may be provided when patching an API object. PatchOptions is meant to be a superset of UpdateOptions.",
- "dryRun": "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed",
- "force": "Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.",
+ "": "PatchOptions may be provided when patching an API object. PatchOptions is meant to be a superset of UpdateOptions.",
+ "dryRun": "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed",
+ "force": "Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.",
+ "fieldManager": "fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).",
}
func (PatchOptions) SwaggerDoc() map[string]string {
@@ -292,8 +294,9 @@
}
var map_Preconditions = map[string]string{
- "": "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.",
- "uid": "Specifies the target UID.",
+ "": "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.",
+ "uid": "Specifies the target UID.",
+ "resourceVersion": "Specifies the target ResourceVersion",
}
func (Preconditions) SwaggerDoc() map[string]string {
@@ -369,8 +372,9 @@
}
var map_UpdateOptions = map[string]string{
- "": "UpdateOptions may be provided when updating an API object. All fields in UpdateOptions should also be present in PatchOptions.",
- "dryRun": "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed",
+ "": "UpdateOptions may be provided when updating an API object. All fields in UpdateOptions should also be present in PatchOptions.",
+ "dryRun": "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed",
+ "fieldManager": "fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.",
}
func (UpdateOptions) SwaggerDoc() map[string]string {
diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go
index 5b09ac5..68498b8 100644
--- a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go
+++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go
@@ -831,6 +831,11 @@
*out = new(types.UID)
**out = **in
}
+ if in.ResourceVersion != nil {
+ in, out := &in.ResourceVersion, &out.ResourceVersion
+ *out = new(string)
+ **out = **in
+ }
return
}
diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1beta1/types.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1beta1/types.go
index 344c533..0462f08 100644
--- a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1beta1/types.go
+++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1beta1/types.go
@@ -133,6 +133,10 @@
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
type TableOptions struct {
v1.TypeMeta `json:",inline"`
+
+ // NoHeaders is only exposed for internal callers.
+ NoHeaders bool `json:"-"`
+
// includeObject decides whether to include each object along with its columnar information.
// Specifying "None" will return no object, specifying "Object" will return the full object contents, and
// specifying "Metadata" (the default) will return the object's metadata in the PartialObjectMetadata kind
diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/types.go b/vendor/k8s.io/apimachinery/pkg/runtime/types.go
index 1f7f662..eb284ea 100644
--- a/vendor/k8s.io/apimachinery/pkg/runtime/types.go
+++ b/vendor/k8s.io/apimachinery/pkg/runtime/types.go
@@ -43,6 +43,8 @@
const (
ContentTypeJSON string = "application/json"
ContentTypeYAML string = "application/yaml"
+
+ ContentTypeProtobuf string = "application/vnd.kubernetes.protobuf"
)
// RawExtension is used to hold extensions in external versions.