diff --git a/Makefile b/Makefile index 012aae22f0c0303042b33823d91aaf1ef30e4ff9..950bf7b88d980f143fabf6690bca4630ccac1a6c 100644 --- a/Makefile +++ b/Makefile @@ -69,6 +69,9 @@ deploy: manifests generate: go generate ./pkg/... ./cmd/... +mockgen: + mockgen -package=openpitrix -source=pkg/simple/client/openpitrix/openpitrix.go -destination=pkg/simple/client/openpitrix/mock.go + deepcopy: GO111MODULE=on go install -mod=vendor k8s.io/code-generator/cmd/deepcopy-gen ${GOPATH}/bin/deepcopy-gen -i kubesphere.io/kubesphere/pkg/apis/... -h ./hack/boilerplate.go.txt -O zz_generated.deepcopy diff --git a/cmd/controller-manager/app/server.go b/cmd/controller-manager/app/server.go index 44984de10a3a8a15d103bc869c319e8e48636893..5ed428acbe7d409ae12449558ab74a7ea7b87a09 100644 --- a/cmd/controller-manager/app/server.go +++ b/cmd/controller-manager/app/server.go @@ -20,7 +20,7 @@ import ( "context" "fmt" "github.com/spf13/cobra" - v1 "k8s.io/api/core/v1" + "k8s.io/api/core/v1" utilerrors "k8s.io/apimachinery/pkg/util/errors" "k8s.io/apimachinery/pkg/util/uuid" "k8s.io/client-go/tools/leaderelection" @@ -40,7 +40,6 @@ import ( "kubesphere.io/kubesphere/pkg/simple/client/devops" "kubesphere.io/kubesphere/pkg/simple/client/devops/jenkins" "kubesphere.io/kubesphere/pkg/simple/client/k8s" - "kubesphere.io/kubesphere/pkg/simple/client/openpitrix" "kubesphere.io/kubesphere/pkg/simple/client/s3" "kubesphere.io/kubesphere/pkg/utils/term" "os" @@ -103,15 +102,6 @@ func Run(s *options.KubeSphereControllerManagerOptions, stopCh <-chan struct{}) return err } - var openpitrixClient openpitrix.Client - if s.OpenPitrixOptions != nil && !s.OpenPitrixOptions.IsEmpty() { - openpitrixClient, err = openpitrix.NewClient(s.OpenPitrixOptions) - if err != nil { - klog.Errorf("Failed to create openpitrix client %v", err) - return err - } - } - var devopsClient devops.Interface if s.DevopsOptions != nil && len(s.DevopsOptions.Host) != 0 { devopsClient, err = jenkins.NewDevopsClient(s.DevopsOptions) @@ -151,7 +141,7 @@ func Run(s *options.KubeSphereControllerManagerOptions, stopCh <-chan struct{}) klog.Fatal("Unable to create workspace controller") } - err = namespace.Add(mgr, openpitrixClient) + err = namespace.Add(mgr) if err != nil { klog.Fatal("Unable to create namespace controller") } diff --git a/go.mod b/go.mod index 37b5b3a4c71146fcafa84d509bf528423b539435..61273d359f11f2ca629f84e44c46013e95e7efa3 100644 --- a/go.mod +++ b/go.mod @@ -8,32 +8,27 @@ go 1.12 require ( code.cloudfoundry.org/bytefmt v0.0.0-20190710193110-1eb035ffe2b6 - github.com/Masterminds/semver v1.5.0 // indirect - github.com/Microsoft/go-winio v0.4.12 // indirect github.com/NYTimes/gziphandler v1.1.1 // indirect github.com/PuerkitoBio/goquery v1.5.0 github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a - github.com/aws/aws-sdk-go v1.22.2 + github.com/aws/aws-sdk-go v1.25.21 github.com/beevik/etree v1.1.0 github.com/container-storage-interface/spec v1.2.0 github.com/dgrijalva/jwt-go v3.2.0+incompatible github.com/docker/distribution v2.7.1+incompatible github.com/docker/docker v1.4.2-0.20190822205725-ed20165a37b4 - github.com/docker/go-connections v0.3.0 // indirect - github.com/docker/spdystream v0.0.0-20181023171402-6480d4af844c // indirect github.com/elastic/go-elasticsearch/v5 v5.6.1 github.com/elastic/go-elasticsearch/v6 v6.8.2 github.com/elastic/go-elasticsearch/v7 v7.3.0 - github.com/elazarl/goproxy v0.0.0-20190711103511-473e67f1d7d2 // indirect github.com/elazarl/goproxy/ext v0.0.0-20190711103511-473e67f1d7d2 // indirect - github.com/emicklei/go-restful v2.9.5+incompatible + github.com/emicklei/go-restful v2.11.1+incompatible github.com/emicklei/go-restful-openapi v1.0.0 github.com/emirpasic/gods v1.12.0 // indirect github.com/fatih/structs v1.1.0 github.com/go-ldap/ldap v3.0.3+incompatible github.com/go-logr/zapr v0.1.1 // indirect github.com/go-openapi/loads v0.19.2 - github.com/go-openapi/spec v0.19.3 + github.com/go-openapi/spec v0.19.4 github.com/go-openapi/strfmt v0.19.3 github.com/go-openapi/validate v0.19.5 github.com/go-redis/redis v6.15.2+incompatible @@ -46,7 +41,7 @@ require ( github.com/google/go-querystring v1.0.0 // indirect github.com/google/uuid v1.1.1 github.com/gorilla/mux v1.7.1 // indirect - github.com/gorilla/websocket v1.4.0 + github.com/gorilla/websocket v1.4.1 github.com/hashicorp/go-version v1.2.0 // indirect github.com/json-iterator/go v1.1.9 github.com/kelseyhightower/envconfig v1.4.0 // indirect @@ -56,22 +51,20 @@ require ( github.com/kubesphere/sonargo v0.0.2 github.com/lib/pq v1.2.0 // indirect github.com/mattn/go-sqlite3 v1.11.0 // indirect - github.com/morikuni/aec v0.0.0-20170113033406-39771216ff4c // indirect github.com/onsi/ginkgo v1.12.0 github.com/onsi/gomega v1.9.0 github.com/open-policy-agent/opa v0.18.0 github.com/opencontainers/go-digest v1.0.0-rc1 - github.com/opencontainers/image-spec v1.0.1 // indirect github.com/openshift/api v0.0.0-20180801171038-322a19404e37 // indirect github.com/opentracing/opentracing-go v1.1.0 // indirect github.com/patrickmn/go-cache v2.1.0+incompatible // indirect github.com/pkg/errors v0.9.1 github.com/projectcalico/kube-controllers v3.8.8+incompatible github.com/projectcalico/libcalico-go v1.7.2-0.20191104213956-8f81e1e344ce - github.com/prometheus/client_golang v1.0.0 + github.com/prometheus/client_golang v1.2.1 github.com/prometheus/common v0.4.1 github.com/prometheus/prometheus v1.8.2 - github.com/sony/sonyflake v0.0.0-20181109022403-6d5bd6181009 + github.com/sony/sonyflake v1.0.0 github.com/speps/go-hashids v2.0.0+incompatible github.com/spf13/cobra v0.0.5 github.com/spf13/pflag v1.0.5 @@ -79,7 +72,7 @@ require ( github.com/stretchr/testify v1.4.0 github.com/syndtr/goleveldb v1.0.0 // indirect github.com/xanzy/ssh-agent v0.2.1 // indirect - golang.org/x/crypto v0.0.0-20190923035154-9ee001bba392 + golang.org/x/crypto v0.0.0-20200220183623-bac4c82f6975 golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553 golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45 google.golang.org/grpc v1.26.0 @@ -102,9 +95,7 @@ require ( k8s.io/klog v1.0.0 k8s.io/kube-openapi v0.0.0-20191107075043-30be4d16710a k8s.io/kubectl v0.17.3 - kubesphere.io/im v0.1.0 // indirect - openpitrix.io/iam v0.1.0 // indirect - openpitrix.io/openpitrix v0.4.1-0.20190920134345-4d2be6e4965c + openpitrix.io/openpitrix v0.4.9-0.20200611125425-ae07f141e797 sigs.k8s.io/controller-runtime v0.5.0 sigs.k8s.io/controller-tools v0.2.4 sigs.k8s.io/kubefed v0.2.0-alpha.1 @@ -123,13 +114,20 @@ replace ( github.com/Azure/go-autorest/tracing => github.com/Azure/go-autorest/tracing v0.5.0 github.com/BurntSushi/toml => github.com/BurntSushi/toml v0.3.1 github.com/MakeNowJust/heredoc => github.com/MakeNowJust/heredoc v0.0.0-20170808103936-bb23615498cd + github.com/Masterminds/goutils => github.com/Masterminds/goutils v1.1.0 github.com/Masterminds/semver => github.com/Masterminds/semver v1.5.0 + github.com/Masterminds/semver/v3 => github.com/Masterminds/semver/v3 v3.0.1 + github.com/Masterminds/sprig/v3 => github.com/Masterminds/sprig/v3 v3.0.0 + github.com/Masterminds/vcs => github.com/Masterminds/vcs v1.13.0 github.com/Microsoft/go-winio => github.com/Microsoft/go-winio v0.4.12 + github.com/Microsoft/hcsshim => github.com/Microsoft/hcsshim v0.8.6 github.com/NYTimes/gziphandler => github.com/NYTimes/gziphandler v1.1.1 + github.com/Nvveen/Gotty => github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5 github.com/OneOfOne/xxhash => github.com/OneOfOne/xxhash v1.2.2 github.com/PuerkitoBio/goquery => github.com/PuerkitoBio/goquery v1.5.0 github.com/PuerkitoBio/purell => github.com/PuerkitoBio/purell v1.1.1 github.com/PuerkitoBio/urlesc => github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 + github.com/Shopify/logrus-bugsnag => github.com/Shopify/logrus-bugsnag v0.0.0-20171204204709-577dee27f20d github.com/StackExchange/wmi => github.com/StackExchange/wmi v0.0.0-20170410192909-ea383cf3ba6e github.com/alcortesm/tgz => github.com/alcortesm/tgz v0.0.0-20161220082320-9c5fe88206d7 github.com/alecthomas/template => github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc @@ -145,11 +143,17 @@ replace ( github.com/bitly/go-simplejson => github.com/bitly/go-simplejson v0.5.0 github.com/blang/semver => github.com/blang/semver v3.5.0+incompatible github.com/bmizerany/assert => github.com/bmizerany/assert v0.0.0-20160611221934-b7ed37b82869 + github.com/bshuster-repo/logrus-logstash-hook => github.com/bshuster-repo/logrus-logstash-hook v0.4.1 + github.com/bugsnag/bugsnag-go => github.com/bugsnag/bugsnag-go v1.5.0 + github.com/bugsnag/panicwrap => github.com/bugsnag/panicwrap v1.2.0 github.com/cespare/xxhash => github.com/cespare/xxhash v1.1.0 github.com/chai2010/gettext-go => github.com/chai2010/gettext-go v0.0.0-20160711120539-c6fed771bfd5 + github.com/chai2010/jsonmap => github.com/chai2010/jsonmap v1.0.0 github.com/client9/misspell => github.com/client9/misspell v0.3.4 github.com/cockroachdb/datadriven => github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa github.com/container-storage-interface/spec => github.com/container-storage-interface/spec v1.2.0 + github.com/containerd/containerd => github.com/containerd/containerd v1.3.0 + github.com/containerd/continuity => github.com/containerd/continuity v0.0.0-20181203112020-004b46473808 github.com/coreos/bbolt => github.com/coreos/bbolt v1.3.3 github.com/coreos/etcd => github.com/coreos/etcd v3.3.17+incompatible github.com/coreos/go-oidc => github.com/coreos/go-oidc v2.1.0+incompatible @@ -158,15 +162,22 @@ replace ( github.com/coreos/pkg => github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f github.com/cpuguy83/go-md2man => github.com/cpuguy83/go-md2man v1.0.10 github.com/creack/pty => github.com/creack/pty v1.1.7 + github.com/cyphar/filepath-securejoin => github.com/cyphar/filepath-securejoin v0.2.2 github.com/davecgh/go-spew => github.com/davecgh/go-spew v1.1.1 github.com/daviddengcn/go-colortext => github.com/daviddengcn/go-colortext v0.0.0-20160507010035-511bcaf42ccd github.com/deckarep/golang-set => github.com/deckarep/golang-set v1.7.1 + github.com/deislabs/oras => github.com/deislabs/oras v0.7.0 github.com/denisenkom/go-mssqldb => github.com/denisenkom/go-mssqldb v0.0.0-20190204142019-df6d76eb9289 github.com/dgrijalva/jwt-go => github.com/dgrijalva/jwt-go v3.2.0+incompatible + github.com/disintegration/imaging => github.com/disintegration/imaging v1.6.1 + github.com/docker/cli => github.com/docker/cli v0.0.0-20190506213505-d88565df0c2d github.com/docker/distribution => github.com/docker/distribution v2.7.1+incompatible github.com/docker/docker => github.com/docker/engine v1.4.2-0.20190822205725-ed20165a37b4 + github.com/docker/docker-credential-helpers => github.com/docker/docker-credential-helpers v0.6.1 github.com/docker/go-connections => github.com/docker/go-connections v0.3.0 + github.com/docker/go-metrics => github.com/docker/go-metrics v0.0.0-20181218153428-b84716841b82 github.com/docker/go-units => github.com/docker/go-units v0.3.3 + github.com/docker/libtrust => github.com/docker/libtrust v0.0.0-20160708172513-aabc10ec26b7 github.com/docker/spdystream => github.com/docker/spdystream v0.0.0-20181023171402-6480d4af844c github.com/docopt/docopt-go => github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815 github.com/dustin/go-humanize => github.com/dustin/go-humanize v1.0.0 @@ -186,7 +197,10 @@ replace ( github.com/fatih/structs => github.com/fatih/structs v1.1.0 github.com/flynn/go-shlex => github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568 github.com/fsnotify/fsnotify => github.com/fsnotify/fsnotify v1.4.7 + github.com/garyburd/redigo => github.com/garyburd/redigo v1.6.0 github.com/ghodss/yaml => github.com/ghodss/yaml v1.0.0 + github.com/gin-contrib/sse => github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3 + github.com/gin-gonic/gin => github.com/gin-gonic/gin v1.4.0 github.com/gliderlabs/ssh => github.com/gliderlabs/ssh v0.1.1 github.com/globalsign/mgo => github.com/globalsign/mgo v0.0.0-20181015135952-eeefdecb41b8 github.com/go-kit/kit => github.com/go-kit/kit v0.8.0 @@ -213,6 +227,7 @@ replace ( github.com/gobuffalo/flect => github.com/gobuffalo/flect v0.1.5 github.com/gobwas/glob => github.com/gobwas/glob v0.2.3 github.com/gocraft/dbr => github.com/gocraft/dbr v0.0.0-20180507214907-a0fd650918f6 + github.com/gofrs/flock => github.com/gofrs/flock v0.7.1 github.com/gofrs/uuid => github.com/gofrs/uuid v3.2.0+incompatible github.com/gogo/protobuf => github.com/gogo/protobuf v1.3.0 github.com/golang/example => github.com/golang/example v0.0.0-20170904185048-46695d81d1fa @@ -235,16 +250,19 @@ replace ( github.com/googleapis/gax-go/v2 => github.com/googleapis/gax-go/v2 v2.0.4 github.com/googleapis/gnostic => github.com/googleapis/gnostic v0.3.1 github.com/gophercloud/gophercloud => github.com/gophercloud/gophercloud v0.3.0 + github.com/gorilla/handlers => github.com/gorilla/handlers v1.4.0 github.com/gorilla/mux => github.com/gorilla/mux v1.7.1 github.com/gorilla/websocket => github.com/gorilla/websocket v1.4.0 + github.com/gosuri/uitable => github.com/gosuri/uitable v0.0.1 github.com/gregjones/httpcache => github.com/gregjones/httpcache v0.0.0-20170728041850-787624de3eb7 github.com/grpc-ecosystem/go-grpc-middleware => github.com/grpc-ecosystem/go-grpc-middleware v1.0.0 github.com/grpc-ecosystem/go-grpc-prometheus => github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 - github.com/grpc-ecosystem/grpc-gateway => github.com/grpc-ecosystem/grpc-gateway v1.9.6 + github.com/grpc-ecosystem/grpc-gateway => github.com/grpc-ecosystem/grpc-gateway v1.11.3 github.com/hashicorp/go-version => github.com/hashicorp/go-version v1.2.0 github.com/hashicorp/golang-lru => github.com/hashicorp/golang-lru v0.5.3 github.com/hashicorp/hcl => github.com/hashicorp/hcl v1.0.0 github.com/hpcloud/tail => github.com/hpcloud/tail v1.0.0 + github.com/huandu/xstrings => github.com/huandu/xstrings v1.2.0 github.com/imdario/mergo => github.com/imdario/mergo v0.3.7 github.com/inconshreveable/mousetrap => github.com/inconshreveable/mousetrap v1.0.0 github.com/jbenet/go-context => github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 @@ -284,11 +302,15 @@ replace ( github.com/mattn/go-colorable => github.com/mattn/go-colorable v0.1.2 github.com/mattn/go-isatty => github.com/mattn/go-isatty v0.0.8 github.com/mattn/go-runewidth => github.com/mattn/go-runewidth v0.0.0-20181025052659-b20a3daf6a39 + github.com/mattn/go-shellwords => github.com/mattn/go-shellwords v1.0.5 github.com/mattn/go-sqlite3 => github.com/mattn/go-sqlite3 v1.11.0 github.com/matttproud/golang_protobuf_extensions => github.com/matttproud/golang_protobuf_extensions v1.0.1 + github.com/miekg/dns => github.com/miekg/dns v0.0.0-20181005163659-0d29b283ac0f + github.com/mitchellh/copystructure => github.com/mitchellh/copystructure v1.0.0 github.com/mitchellh/go-homedir => github.com/mitchellh/go-homedir v1.1.0 github.com/mitchellh/go-wordwrap => github.com/mitchellh/go-wordwrap v1.0.0 github.com/mitchellh/mapstructure => github.com/mitchellh/mapstructure v1.1.2 + github.com/mitchellh/reflectwalk => github.com/mitchellh/reflectwalk v1.0.0 github.com/mna/pigeon => github.com/mna/pigeon v0.0.0-20180808201053-bb0192cfc2ae github.com/modern-go/concurrent => github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd github.com/modern-go/reflect2 => github.com/modern-go/reflect2 v1.0.1 @@ -302,6 +324,7 @@ replace ( github.com/open-policy-agent/opa => github.com/open-policy-agent/opa v0.18.0 github.com/opencontainers/go-digest => github.com/opencontainers/go-digest v1.0.0-rc1 github.com/opencontainers/image-spec => github.com/opencontainers/image-spec v1.0.1 + github.com/opencontainers/runc => github.com/opencontainers/runc v0.1.1 github.com/openshift/api => github.com/openshift/api v0.0.0-20180801171038-322a19404e37 github.com/openshift/generic-admission-server => github.com/openshift/generic-admission-server v1.14.0 github.com/opentracing/opentracing-go => github.com/opentracing/opentracing-go v1.1.0 @@ -311,6 +334,7 @@ replace ( github.com/pelletier/go-toml => github.com/pelletier/go-toml v1.2.0 github.com/peterbourgon/diskv => github.com/peterbourgon/diskv v2.0.1+incompatible github.com/peterh/liner => github.com/peterh/liner v0.0.0-20170211195444-bf27d3ba8e1d + github.com/phayes/freeport => github.com/phayes/freeport v0.0.0-20171002181615-b8543db493a5 github.com/philhofer/fwd => github.com/philhofer/fwd v1.0.0 github.com/pkg/errors => github.com/pkg/errors v0.8.1 github.com/pmezard/go-difflib => github.com/pmezard/go-difflib v1.0.0 @@ -328,6 +352,7 @@ replace ( github.com/prometheus/prometheus => github.com/prometheus/prometheus v1.8.2 github.com/rcrowley/go-metrics => github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a github.com/remyoudompheng/bigfft => github.com/remyoudompheng/bigfft v0.0.0-20170806203942-52369c62f446 + github.com/robfig/cron => github.com/robfig/cron v1.2.0 github.com/rogpeppe/fastuuid => github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af github.com/rogpeppe/go-charset => github.com/rogpeppe/go-charset v0.0.0-20180617210344-2471d30d28b4 github.com/russross/blackfriday => github.com/russross/blackfriday v1.5.2 @@ -353,13 +378,21 @@ replace ( github.com/tinylib/msgp => github.com/tinylib/msgp v1.1.0 github.com/tmc/grpc-websocket-proxy => github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5 github.com/ugorji/go => github.com/ugorji/go v1.1.4 + github.com/ugorji/go/codec => github.com/ugorji/go/codec v0.0.0-20190128213124-ee1426cffec0 github.com/urfave/cli => github.com/urfave/cli v1.20.0 github.com/xanzy/ssh-agent => github.com/xanzy/ssh-agent v0.2.1 + github.com/xeipuuv/gojsonpointer => github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f + github.com/xeipuuv/gojsonreference => github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 + github.com/xeipuuv/gojsonschema => github.com/xeipuuv/gojsonschema v1.2.0 + github.com/xenolf/lego => github.com/xenolf/lego v0.3.2-0.20160613233155-a9d8cec0e656 github.com/xiang90/probing => github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2 github.com/xlab/handysort => github.com/xlab/handysort v0.0.0-20150421192137-fb3537ed64a1 github.com/xlab/treeprint => github.com/xlab/treeprint v0.0.0-20180616005107-d6fb6747feb6 github.com/xordataexchange/crypt => github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77 github.com/yashtewari/glob-intersection => github.com/yashtewari/glob-intersection v0.0.0-20180916065949-5c77d914dd0b + github.com/yvasiyarov/go-metrics => github.com/yvasiyarov/go-metrics v0.0.0-20150112132944-c25f46c4b940 + github.com/yvasiyarov/gorelic => github.com/yvasiyarov/gorelic v0.0.6 + github.com/yvasiyarov/newrelic_platform_go => github.com/yvasiyarov/newrelic_platform_go v0.0.0-20140908184405-b21fdbd4370f go.etcd.io/bbolt => go.etcd.io/bbolt v1.3.3 go.etcd.io/etcd => go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738 go.opencensus.io => go.opencensus.io v0.21.0 @@ -368,6 +401,7 @@ replace ( go.uber.org/zap => go.uber.org/zap v1.10.0 golang.org/x/crypto => golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2 golang.org/x/exp => golang.org/x/exp v0.0.0-20190121172915-509febef88a4 + golang.org/x/image => golang.org/x/image v0.0.0-20180708004352-c73c2afc3b81 golang.org/x/lint => golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f golang.org/x/net => golang.org/x/net v0.0.0-20190620200207-3b0461eec859 golang.org/x/oauth2 => golang.org/x/oauth2 v0.0.0-20190402181905-9f3314589c9a @@ -386,16 +420,21 @@ replace ( google.golang.org/grpc => google.golang.org/grpc v1.23.1 gopkg.in/airbrake/gobrake.v2 => gopkg.in/airbrake/gobrake.v2 v2.0.9 gopkg.in/alecthomas/kingpin.v2 => gopkg.in/alecthomas/kingpin.v2 v2.2.6 + gopkg.in/alexcesaro/quotedprintable.v3 => gopkg.in/alexcesaro/quotedprintable.v3 v3.0.0-20150716171945-2caba252f4dc gopkg.in/asn1-ber.v1 => gopkg.in/asn1-ber.v1 v1.0.0-20181015200546-f715ec2f112d gopkg.in/check.v1 => gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 gopkg.in/cheggaaa/pb.v1 => gopkg.in/cheggaaa/pb.v1 v1.0.25 gopkg.in/fsnotify.v1 => gopkg.in/fsnotify.v1 v1.4.7 gopkg.in/gemnasium/logrus-airbrake-hook.v2 => gopkg.in/gemnasium/logrus-airbrake-hook.v2 v2.1.2 gopkg.in/go-playground/assert.v1 => gopkg.in/go-playground/assert.v1 v1.2.1 + gopkg.in/go-playground/validator.v8 => gopkg.in/go-playground/validator.v8 v8.18.2 gopkg.in/go-playground/validator.v9 => gopkg.in/go-playground/validator.v9 v9.29.1 + gopkg.in/gomail.v2 => gopkg.in/gomail.v2 v2.0.0-20160411212932-81ebce5c23df gopkg.in/inf.v0 => gopkg.in/inf.v0 v0.9.1 + gopkg.in/mail.v2 => gopkg.in/mail.v2 v2.3.1 gopkg.in/natefinch/lumberjack.v2 => gopkg.in/natefinch/lumberjack.v2 v2.0.0 gopkg.in/resty.v1 => gopkg.in/resty.v1 v1.12.0 + gopkg.in/square/go-jose.v1 => gopkg.in/square/go-jose.v1 v1.1.2 gopkg.in/square/go-jose.v2 => gopkg.in/square/go-jose.v2 v2.3.1 gopkg.in/src-d/go-billy.v4 => gopkg.in/src-d/go-billy.v4 v4.3.0 gopkg.in/src-d/go-git-fixtures.v3 => gopkg.in/src-d/go-git-fixtures.v3 v3.1.1 @@ -407,6 +446,7 @@ replace ( gopkg.in/yaml.v2 => gopkg.in/yaml.v2 v2.2.8 gopkg.in/yaml.v3 => gopkg.in/yaml.v3 v3.0.0-20190905181640-827449938966 gotest.tools => gotest.tools v2.2.0+incompatible + helm.sh/helm/v3 => helm.sh/helm/v3 v3.0.1 honnef.co/go/tools => honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc istio.io/api => istio.io/api v0.0.0-20191111210003-35e06ef8d838 istio.io/client-go => istio.io/client-go v0.0.0-20191113122552-9bd0ba57c3d2 @@ -434,9 +474,12 @@ replace ( modernc.org/strutil => modernc.org/strutil v1.0.0 modernc.org/xc => modernc.org/xc v1.0.0 openpitrix.io/iam => openpitrix.io/iam v0.1.0 + openpitrix.io/libqueue => openpitrix.io/libqueue v0.4.1 openpitrix.io/logger => openpitrix.io/logger v0.1.0 - openpitrix.io/openpitrix => openpitrix.io/openpitrix v0.4.1-0.20190920134345-4d2be6e4965c + openpitrix.io/notification => openpitrix.io/notification v0.2.2 + openpitrix.io/openpitrix => openpitrix.io/openpitrix v0.4.9-0.20200611125425-ae07f141e797 rsc.io/goversion => rsc.io/goversion v1.0.0 + rsc.io/letsencrypt => rsc.io/letsencrypt v0.0.1 sigs.k8s.io/controller-runtime => sigs.k8s.io/controller-runtime v0.4.0 sigs.k8s.io/controller-tools => sigs.k8s.io/controller-tools v0.2.4 sigs.k8s.io/kubefed => sigs.k8s.io/kubefed v0.2.0-alpha.1 diff --git a/go.sum b/go.sum index dc1b64f6d3ad4b5ba036fb5263a52c2b9c5cda83..bb2747712cfa72f89d3faba911da7c39e0b77b35 100644 --- a/go.sum +++ b/go.sum @@ -12,12 +12,18 @@ github.com/Azure/go-autorest/tracing v0.5.0/go.mod h1:r/s2XiOKccPW3HrqB+W0TQzfbt github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/MakeNowJust/heredoc v0.0.0-20170808103936-bb23615498cd/go.mod h1:64YHyfSL2R96J44Nlwm39UHepQbyR5q10x7iYa1ks2E= +github.com/Masterminds/goutils v1.1.0/go.mod h1:8cTjp+g8YejhMuvIA5y2vz3BpJxksy863GQaJW2MFNU= github.com/Masterminds/semver v1.5.0 h1:H65muMkzWKEuNDnfl9d70GUjFniHKHRbFPGBuZ3QEww= github.com/Masterminds/semver v1.5.0/go.mod h1:MB6lktGJrhw8PrUyiEoblNEGEQ+RzHPF078ddwwvV3Y= +github.com/Masterminds/semver/v3 v3.0.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= +github.com/Masterminds/sprig/v3 v3.0.0/go.mod h1:NEUY/Qq8Gdm2xgYA+NwJM6wmfdRV9xkh8h/Rld20R0U= +github.com/Masterminds/vcs v1.13.0/go.mod h1:N09YCmOQr6RLxC6UNHzuVwAdodYbbnycGHSmwVJjcKA= github.com/Microsoft/go-winio v0.4.12 h1:xAfWHN1IrQ0NJ9TBC0KBZoqLjzDTr1ML+4MywiUOryc= github.com/Microsoft/go-winio v0.4.12/go.mod h1:VhR8bwka0BXejwEJY73c50VrPtXAaKcyvVC4A4RozmA= +github.com/Microsoft/hcsshim v0.8.6/go.mod h1:Op3hHsoHPAvb6lceZHDtd9OkTew38wNoXnJs8iY7rUg= github.com/NYTimes/gziphandler v1.1.1 h1:ZUDjpQae29j0ryrS0u/B8HZfJBtBQHjqw2rQ2cqUQ3I= github.com/NYTimes/gziphandler v1.1.1/go.mod h1:n/CVRwUEOgIxrgPvAQhUUr9oeUtvrhMomdKFjzJNB0c= +github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5/go.mod h1:lmUJ/7eu/Q8D7ML55dXQrVaamCz2vxCfdQBasLZfHKk= github.com/OneOfOne/xxhash v1.2.2 h1:KMrpdQIwFcEqXDklaen+P1axHaj9BSKzvpUUfnHldSE= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/PuerkitoBio/goquery v1.5.0 h1:uGvmFXOA73IKluu/F84Xd1tt/z07GYm8X49XKHP7EJk= @@ -26,6 +32,7 @@ github.com/PuerkitoBio/purell v1.1.1 h1:WEQqlqaGbrPkxLJWfBwQmfEAE1Z7ONdDLqrN38tN github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 h1:d+Bc7a5rLufV/sSk/8dngufqelfh6jnri85riMAaF/M= github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= +github.com/Shopify/logrus-bugsnag v0.0.0-20171204204709-577dee27f20d/go.mod h1:HI8ITrYtUY+O+ZhtlqUnD8+KwNPOyugEhfP9fdUIaEQ= github.com/StackExchange/wmi v0.0.0-20170410192909-ea383cf3ba6e/go.mod h1:3eOhrUMpNV+6aFIbp5/iudMxNCF27Vw2OZgy4xEx0Fg= github.com/alcortesm/tgz v0.0.0-20161220082320-9c5fe88206d7 h1:uSoVVbwJiQipAclBbw+8quDsfcvFjOpI5iCf4p/cqCs= github.com/alcortesm/tgz v0.0.0-20161220082320-9c5fe88206d7/go.mod h1:6zEj6s6u/ghQa61ZWa/C2Aw3RkjiTBOix7dkqa1VLIs= @@ -53,14 +60,21 @@ github.com/blang/semver v3.5.0+incompatible h1:CGxCgetQ64DKk7rdZ++Vfnb1+ogGNnB17 github.com/blang/semver v3.5.0+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk= github.com/bmizerany/assert v0.0.0-20160611221934-b7ed37b82869 h1:DDGfHa7BWjL4YnC6+E63dPcxHo2sUxDIu8g3QgEJdRY= github.com/bmizerany/assert v0.0.0-20160611221934-b7ed37b82869/go.mod h1:Ekp36dRnpXw/yCqJaO+ZrUyxD+3VXMFFr56k5XYrpB4= +github.com/bshuster-repo/logrus-logstash-hook v0.4.1/go.mod h1:zsTqEiSzDgAa/8GZR7E1qaXrhYNDKBYy5/dWPTIflbk= +github.com/bugsnag/bugsnag-go v1.5.0/go.mod h1:2oa8nejYd4cQ/b0hMIopN0lCRxU0bueqREvZLWFrtK8= +github.com/bugsnag/panicwrap v1.2.0/go.mod h1:D/8v3kj0zr8ZAKg1AQ6crr+5VwKN5eIywRkfhyM/+dE= github.com/cespare/xxhash v1.1.0 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko= github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= github.com/chai2010/gettext-go v0.0.0-20160711120539-c6fed771bfd5/go.mod h1:/iP1qXHoty45bqomnu2LM+VVyAEdWN+vtSHGlQgyxbw= +github.com/chai2010/jsonmap v1.0.0/go.mod h1:+30HSZixzW7NVqyqXTDyQi0hsexrb6hnpvhuW0bot6s= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa h1:OaNxuTZr7kxeODyLWsRMC+OD03aFUH+mW6r2d+MWa5Y= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= github.com/container-storage-interface/spec v1.2.0 h1:bD9KIVgaVKKkQ/UbVUY9kCaH/CJbhNxe0eeB4JeJV2s= github.com/container-storage-interface/spec v1.2.0/go.mod h1:6URME8mwIBbpVyZV93Ce5St17xBiQJQY67NDsuohiy4= +github.com/containerd/containerd v1.3.0/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA= +github.com/containerd/continuity v0.0.0-20181203112020-004b46473808/go.mod h1:GL3xCUCBDV3CZiTSEKksMWbLE66hEyuu9qyDOOqM47Y= +github.com/coreos/bbolt v1.3.3 h1:n6AiVyVRKQFNb6mJlwESEvvLoDyiTzXX7ORAUlkeBdY= github.com/coreos/bbolt v1.3.3/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= github.com/coreos/etcd v3.3.17+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= github.com/coreos/go-oidc v2.1.0+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc= @@ -72,22 +86,29 @@ github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f h1:lBNOc5arjvs8E5mO2tbp github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= +github.com/cyphar/filepath-securejoin v0.2.2/go.mod h1:FpkQEhXnPnOthhzymB7CGsFk2G9VLXONKD9G7QGMM+4= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/daviddengcn/go-colortext v0.0.0-20160507010035-511bcaf42ccd/go.mod h1:dv4zxwHi5C/8AeI+4gX4dCWOIvNi7I6JCSX0HvlKPgE= github.com/deckarep/golang-set v1.7.1 h1:SCQV0S6gTtp6itiFrTqI+pfmJ4LN85S1YzhDf9rTHJQ= github.com/deckarep/golang-set v1.7.1/go.mod h1:93vsz/8Wt4joVM7c2AVqh+YRMiUSc14yDtF28KmMOgQ= +github.com/deislabs/oras v0.7.0/go.mod h1:sqMKPG3tMyIX9xwXUBRLhZ24o+uT4y6jgBD2RzUTKDM= github.com/denisenkom/go-mssqldb v0.0.0-20190204142019-df6d76eb9289/go.mod h1:xN/JuLBIz4bjkxNmByTiV1IbhfnYb6oo99phBn4Eqhc= github.com/dgrijalva/jwt-go v3.2.0+incompatible h1:7qlOGliEKZXTDg6OTjfoBKDXWrumCAMpl/TFQ4/5kLM= github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= +github.com/disintegration/imaging v1.6.1/go.mod h1:xuIt+sRxDFrHS0drzXUlCJthkJ8k7lkkUojDSR247MQ= +github.com/docker/cli v0.0.0-20190506213505-d88565df0c2d/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= github.com/docker/distribution v2.7.1+incompatible h1:a5mlkVzth6W5A4fOsS3D2EO5BUmsJpcB+cRlLU7cSug= github.com/docker/distribution v2.7.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= +github.com/docker/docker-credential-helpers v0.6.1/go.mod h1:WRaJzqw3CTB9bk10avuGsjVBZsD05qeibJ1/TYlvc0Y= github.com/docker/engine v1.4.2-0.20190822205725-ed20165a37b4 h1:+VAGRKyn9Ca+ckzV/PJsaRO7UXO9KQjFmSffcSDrWdE= github.com/docker/engine v1.4.2-0.20190822205725-ed20165a37b4/go.mod h1:3CPr2caMgTHxxIAZgEMd3uLYPDlRvPqCpyeRf6ncPcY= github.com/docker/go-connections v0.3.0 h1:3lOnM9cSzgGwx8VfK/NGOW5fLQ0GjIlCkaktF+n1M6o= github.com/docker/go-connections v0.3.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= +github.com/docker/go-metrics v0.0.0-20181218153428-b84716841b82/go.mod h1:/u0gXw0Gay3ceNrsHubL3BtdOL2fHf93USgMTe0W5dI= github.com/docker/go-units v0.3.3 h1:Xk8S3Xj5sLGlG5g67hJmYMmUgXv5N4PhkjJHHqrwnTk= github.com/docker/go-units v0.3.3/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= +github.com/docker/libtrust v0.0.0-20160708172513-aabc10ec26b7/go.mod h1:cyGadeNEkKy96OOhEzfZl+yxihPEzKnqJwvfuSUqbZE= github.com/docker/spdystream v0.0.0-20181023171402-6480d4af844c h1:ZfSZ3P3BedhKGUhzj7BQlPSU4OvT6tfOKe3DVHzOA7s= github.com/docker/spdystream v0.0.0-20181023171402-6480d4af844c/go.mod h1:Qh8CwZgvJUkLughtfhJv5dyTYa91l1fOUCrgjqmcifM= github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE= @@ -123,8 +144,11 @@ github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568 h1:BHsljHzVlRcyQhjr github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568/go.mod h1:xEzjJPgXI435gkrCt3MPfRiAkVrwSbHsst4LCFVfpJc= github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= +github.com/garyburd/redigo v1.6.0/go.mod h1:NR3MbYisc3/PwhQ00EMzDiPmrwpPxAn5GI05/YaO1SY= github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= +github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3/go.mod h1:VJ0WA2NBN22VlZ2dKZQPAPnyWw5XTlK1KymzLKsr59s= +github.com/gin-gonic/gin v1.4.0/go.mod h1:OW2EZn3DO8Ln9oIKOvM++LBO+5UPHJJDH72/q/3rZdM= github.com/gliderlabs/ssh v0.1.1 h1:j3L6gSLQalDETeEg/Jg0mGY0/y/N6zI2xX1978P0Uqw= github.com/gliderlabs/ssh v0.1.1/go.mod h1:U7qILu1NlMHj9FlMhZLlkCdDnU1DBEAqr0aevW3Awn0= github.com/globalsign/mgo v0.0.0-20181015135952-eeefdecb41b8 h1:DujepqpGd1hyOd7aW59XpK7Qymp8iy83xq74fLr21is= @@ -171,6 +195,7 @@ github.com/gobwas/glob v0.2.3 h1:A4xDbljILXROh+kObIiy5kIaPYD8e96x1tgBhUI5J+Y= github.com/gobwas/glob v0.2.3/go.mod h1:d3Ez4x06l9bZtSvzIay5+Yzi0fmZzPgnTbPcKjJAkT8= github.com/gocraft/dbr v0.0.0-20180507214907-a0fd650918f6 h1:kumyNm8Vr8cbVm/aLQYTbDE3SKCbbn5HEVoDp/Dyyfc= github.com/gocraft/dbr v0.0.0-20180507214907-a0fd650918f6/go.mod h1:K/9g3pPouf13kP5K7pdriQEJAy272R9yXuWuDIEWJTM= +github.com/gofrs/flock v0.7.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/uuid v3.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gogo/protobuf v1.3.0 h1:G8O7TerXerS4F6sx9OV7/nRfJdnXgHZu/S/7F2SN+UE= github.com/gogo/protobuf v1.3.0/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= @@ -206,17 +231,19 @@ github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+ github.com/googleapis/gnostic v0.3.1 h1:WeAefnSUHlBb0iJKwxFDZdbfGwkd7xRNuV+IpXMJhYk= github.com/googleapis/gnostic v0.3.1/go.mod h1:on+2t9HRStVgn95RSsFWFz+6Q0Snyqv1awfrALZdbtU= github.com/gophercloud/gophercloud v0.3.0/go.mod h1:vxM41WHh5uqHVBMZHzuwNOHh8XEoIEcSTewFxm1c5g8= +github.com/gorilla/handlers v1.4.0/go.mod h1:Qkdc/uu4tH4g6mTK6auzZ766c4CA0Ng8+o/OAirnOIQ= github.com/gorilla/mux v1.7.1 h1:Dw4jY2nghMMRsh1ol8dv1axHkDwMQK2DHerMNJsIpJU= github.com/gorilla/mux v1.7.1/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= github.com/gorilla/websocket v1.4.0 h1:WDFjx/TMzVgy9VdMMQi2K2Emtwi2QcUQsztZ/zLaH/Q= github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= +github.com/gosuri/uitable v0.0.1/go.mod h1:tKR86bXuXPZazfOTG1FIzvjIdXzd0mo4Vtn16vt0PJo= github.com/gregjones/httpcache v0.0.0-20170728041850-787624de3eb7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0 h1:Iju5GlWwrvL6UBg4zJJt3btmonfrMlCDdsejg4CZE7c= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92BcuyuQ/YW4NSIpoGtfXNho= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= -github.com/grpc-ecosystem/grpc-gateway v1.9.6 h1:8p0pcgLlw2iuZVsdHdPaMUXFOA+6gDixcXbHEMzSyW8= -github.com/grpc-ecosystem/grpc-gateway v1.9.6/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= +github.com/grpc-ecosystem/grpc-gateway v1.11.3 h1:h8+NsYENhxNTuq+dobk3+ODoJtwY4Fu0WQXsxJfL8aM= +github.com/grpc-ecosystem/grpc-gateway v1.11.3/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= github.com/hashicorp/go-version v1.2.0 h1:3vNe/fWF5CBgRIguda1meWhsZHy3m8gCJ5wx+dIzX/E= github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/golang-lru v0.5.3 h1:YPkqC67at8FYaadspW/6uE0COsBxS2656RLEr8Bppgk= @@ -225,6 +252,7 @@ github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/hpcloud/tail v1.0.0 h1:nfCOvKYfkgYP8hkirhJocXT2+zOD8yUNjXaWfTlyFKI= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= +github.com/huandu/xstrings v1.2.0/go.mod h1:DvyZB1rfVYsBIigL8HwpZgxHwXozlTgGqn63UyNX5k4= github.com/imdario/mergo v0.3.7 h1:Y+UAYTZ7gDEuOfhxKWy+dvb5dRQ6rJjFSdX2HZY1/gI= github.com/imdario/mergo v0.3.7/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA= github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM= @@ -286,15 +314,19 @@ github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVc github.com/mattn/go-isatty v0.0.8 h1:HLtExJ+uU2HOZ+wI0Tt5DtUDrx8yhUqDcp7fYERX4CE= github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= github.com/mattn/go-runewidth v0.0.0-20181025052659-b20a3daf6a39/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= +github.com/mattn/go-shellwords v1.0.5/go.mod h1:3xCvwCdWdlDJUrvuMn7Wuy9eWs4pE8vqg+NOMyg4B2o= github.com/mattn/go-sqlite3 v1.11.0 h1:LDdKkqtYlom37fkvqs8rMPFKAMe8+SgjbwZ6ex1/A/Q= github.com/mattn/go-sqlite3 v1.11.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= github.com/matttproud/golang_protobuf_extensions v1.0.1 h1:4hp9jkHxhMHkqkrB3Ix0jegS5sx/RkqARlsWZ6pIwiU= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= +github.com/miekg/dns v0.0.0-20181005163659-0d29b283ac0f/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= +github.com/mitchellh/copystructure v1.0.0/go.mod h1:SNtv71yrdKgLRyLFxmLdkAbkKEFWgYaq1OVrnRcwhnw= github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y= github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-wordwrap v1.0.0/go.mod h1:ZXFpozHsX6DPmq2I0TCekCxypsnAUbP2oI0UX1GXzOo= github.com/mitchellh/mapstructure v1.1.2 h1:fmNYVwqnSfB9mZU6OS2O6GsXM+wcskZDuKQzvN1EDeE= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= +github.com/mitchellh/reflectwalk v1.0.0/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= github.com/mna/pigeon v0.0.0-20180808201053-bb0192cfc2ae/go.mod h1:Iym28+kJVnC1hfQvv5MUtI6AiFFzvQjHcvI4RFTG/04= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -318,6 +350,7 @@ github.com/opencontainers/go-digest v1.0.0-rc1 h1:WzifXhOVOEOuFYOJAW6aQqW0TooG2i github.com/opencontainers/go-digest v1.0.0-rc1/go.mod h1:cMLVZDEM3+U2I4VmLI6N8jQYUd2OVphdqWwCJHrFt2s= github.com/opencontainers/image-spec v1.0.1 h1:JMemWkRwHx4Zj+fVxWoMCFm/8sYGGrUVojFA6h/TRcI= github.com/opencontainers/image-spec v1.0.1/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0= +github.com/opencontainers/runc v0.1.1/go.mod h1:qT5XzbpPznkRYVz/mWwUaVBUv2rmF59PVA73FjuZG0U= github.com/openshift/api v0.0.0-20180801171038-322a19404e37 h1:05irGU4HK4IauGGDbsk+ZHrm1wOzMLYjMlfaiqMrBYc= github.com/openshift/api v0.0.0-20180801171038-322a19404e37/go.mod h1:dh9o4Fs58gpFXGSYfnVxGR9PnV53I8TW84pQaJDdGiY= github.com/openshift/generic-admission-server v1.14.0/go.mod h1:GD9KN/W4KxqRQGVMbqQHpHzb2XcQVvLCaBaSciqXvfM= @@ -332,6 +365,7 @@ github.com/pelletier/go-toml v1.2.0 h1:T5zMGML61Wp+FlcbWjRDT7yAxhJNAiPPLOFECq181 github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= github.com/peterh/liner v0.0.0-20170211195444-bf27d3ba8e1d/go.mod h1:xIteQHvHuaLYG9IFj6mSxM0fCKrs34IrEQUhOYuGPHc= +github.com/phayes/freeport v0.0.0-20171002181615-b8543db493a5/go.mod h1:iIss55rKnNBTvrwdmkUpLnDpZoAHvWaiq5+iMmen4AE= github.com/philhofer/fwd v1.0.0/go.mod h1:gk3iGcWd9+svBvR0sR+KPcfE+RNWozjowpeBVG3ZVNU= github.com/pkg/errors v0.8.1 h1:iURUrRGxPUNPdy5/HRSm+Yj6okJ6UtLINN0Q9M4+h3I= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -362,6 +396,7 @@ github.com/prometheus/prometheus v1.8.2/go.mod h1:oAIUtOny2rjMX0OWN5vPR5/q/twIRO github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a h1:9ZKAASQSHhDYGoxY8uLVpewe1GDZ2vu2Tr/vTdVAkFQ= github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= github.com/remyoudompheng/bigfft v0.0.0-20170806203942-52369c62f446/go.mod h1:uYEyJGbgTkfkS4+E/PavXkNJcbFIpEtjt2B0KDQ5+9M= +github.com/robfig/cron v1.2.0/go.mod h1:JGuDeoQd7Z6yL4zQhZ3OPEVHB7fL6Ka6skscFHfmt2k= github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= github.com/rogpeppe/go-charset v0.0.0-20180617210344-2471d30d28b4/go.mod h1:qgYeAmZ5ZIpBWTGllZSQnw97Dj+woV0toclVaRGI8pc= github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= @@ -404,9 +439,14 @@ github.com/tinylib/msgp v1.1.0/go.mod h1:+d+yLhGm8mzTaHzB+wgMYrodPfmZrzkirds8fDW github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5 h1:LnC5Kc/wtumK+WB441p7ynQJzVuNRJiqddSIE3IlSEQ= github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc= +github.com/ugorji/go/codec v0.0.0-20190128213124-ee1426cffec0/go.mod h1:iT03XoTwV7xq/+UGwKO3UbC1nNNlopQiY61beSdrtOA= github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA= github.com/xanzy/ssh-agent v0.2.1 h1:TCbipTQL2JiiCprBWx9frJ2eJlCYT00NmctrHxVAr70= github.com/xanzy/ssh-agent v0.2.1/go.mod h1:mLlQY/MoOhWBj+gOGMQkOeiEvkx+8pJSI+0Bx9h2kr4= +github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= +github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= +github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= +github.com/xenolf/lego v0.3.2-0.20160613233155-a9d8cec0e656/go.mod h1:fwiGnfsIjG7OHPfOvgK7Y/Qo6+2Ox0iozjNTkZICKbY= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2 h1:eY9dn8+vbi4tKz5Qo6v2eYzo7kUS51QINcR5jNpbZS8= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= github.com/xlab/handysort v0.0.0-20150421192137-fb3537ed64a1/go.mod h1:QcJo0QPSfTONNIgpN5RA8prR7fF8nkF6cTWTcNerRO8= @@ -414,6 +454,9 @@ github.com/xlab/treeprint v0.0.0-20180616005107-d6fb6747feb6/go.mod h1:ce1O1j6Ut github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= github.com/yashtewari/glob-intersection v0.0.0-20180916065949-5c77d914dd0b h1:vVRagRXf67ESqAb72hG2C/ZwI8NtJF2u2V76EsuOHGY= github.com/yashtewari/glob-intersection v0.0.0-20180916065949-5c77d914dd0b/go.mod h1:HptNXiXVDcJjXe9SqMd0v2FsL9f8dz4GnXgltU6q/co= +github.com/yvasiyarov/go-metrics v0.0.0-20150112132944-c25f46c4b940/go.mod h1:aX5oPXxHm3bOH+xeAttToC8pqch2ScQN/JoXYupl6xs= +github.com/yvasiyarov/gorelic v0.0.6/go.mod h1:NUSPSUX/bi6SeDMUh6brw0nXpxHnc96TguQh0+r/ssA= +github.com/yvasiyarov/newrelic_platform_go v0.0.0-20140908184405-b21fdbd4370f/go.mod h1:GlGEuHIJweS1mbCqG+7vt2nvWLzLLnRHbXz5JKd/Qbg= go.etcd.io/bbolt v1.3.3 h1:MUGmc65QhB3pIlaQ5bB4LwqSj6GIonVJXpZiaKNyaKk= go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738 h1:VcrIfasaLFkyjk6KNlXQSzO+B0fZcnECiDrKJsfxka0= @@ -428,6 +471,7 @@ go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2 h1:VklqNMn3ovrHsnt90PveolxSbWFaJdECFbxSq0Mqo2M= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/image v0.0.0-20180708004352-c73c2afc3b81/go.mod h1:ux5Hcp/YLpHSI86hEcLt0YII63i6oz57MZXIpbrjZUs= golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/net v0.0.0-20190620200207-3b0461eec859 h1:R/3boaszxrf1GEUWTVDzSKVwLmSJpwZ1yqXm8j0v2QI= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -458,6 +502,7 @@ google.golang.org/grpc v1.23.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyac gopkg.in/airbrake/gobrake.v2 v2.0.9/go.mod h1:/h5ZAUhDkGaJfjzjKLSjv6zCL6O0LLBxU4K+aSYdM/U= gopkg.in/alecthomas/kingpin.v2 v2.2.6 h1:jMFz6MfLP0/4fUyZle81rXUoxOBFi19VUFKVDOQfozc= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= +gopkg.in/alexcesaro/quotedprintable.v3 v3.0.0-20150716171945-2caba252f4dc/go.mod h1:m7x9LTH6d71AHyAX77c9yqWCCa3UKHcVEj9y7hAtKDk= gopkg.in/asn1-ber.v1 v1.0.0-20181015200546-f715ec2f112d h1:TxyelI5cVkbREznMhfzycHdkp5cLA7DpE+GKjSslYhM= gopkg.in/asn1-ber.v1 v1.0.0-20181015200546-f715ec2f112d/go.mod h1:cuepJuh7vyXfUyUwEgHQXw849cJrilpS5NeIjOWESAw= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo= @@ -467,12 +512,17 @@ gopkg.in/fsnotify.v1 v1.4.7 h1:xOHLXZwVvI9hhs+cLKq5+I5onOuwQLhQwiu63xxlHs4= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= gopkg.in/gemnasium/logrus-airbrake-hook.v2 v2.1.2/go.mod h1:Xk6kEKp8OKb+X14hQBKWaSkCsqBpgog8nAV2xsGOxlo= gopkg.in/go-playground/assert.v1 v1.2.1/go.mod h1:9RXL0bg/zibRAgZUYszZSwO/z8Y/a8bDuhia5mkpMnE= +gopkg.in/go-playground/validator.v8 v8.18.2/go.mod h1:RX2a/7Ha8BgOhfk7j780h4/u/RRjR0eouCJSH80/M2Y= +gopkg.in/go-playground/validator.v9 v9.29.1 h1:SvGtYmN60a5CVKTOzMSyfzWDeZRxRuGvRQyEAKbw1xc= gopkg.in/go-playground/validator.v9 v9.29.1/go.mod h1:+c9/zcJMFNgbLvly1L1V+PpxWdVbfP1avr/N00E2vyQ= +gopkg.in/gomail.v2 v2.0.0-20160411212932-81ebce5c23df/go.mod h1:LRQQ+SO6ZHR7tOkpBDuZnXENFzX8qRjMDMyPD6BRkCw= gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= +gopkg.in/mail.v2 v2.3.1/go.mod h1:htwXN1Qh09vZJ1NVKxQqHPBaCBbzKhp5GzuJEA4VJWw= gopkg.in/natefinch/lumberjack.v2 v2.0.0 h1:1Lc07Kr7qY4U2YPouBjpCLxpiyxIVoxqXgkXLknAOE8= gopkg.in/natefinch/lumberjack.v2 v2.0.0/go.mod h1:l0ndWWf7gzL7RNwBG7wST/UCcT4T24xpD6X8LsfU/+k= gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= +gopkg.in/square/go-jose.v1 v1.1.2/go.mod h1:QpYS+a4WhS+DTlyQIi6Ka7MS3SuR9a055rgXNEe6EiA= gopkg.in/square/go-jose.v2 v2.3.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI= gopkg.in/src-d/go-billy.v4 v4.3.0 h1:KtlZ4c1OWbIs4jCv5ZXrTqG8EQocr0g/d4DjNg70aek= gopkg.in/src-d/go-billy.v4 v4.3.0/go.mod h1:tm33zBoOwxjYHZIE+OV8bxTWFMJLrconzFMd38aARFk= @@ -492,6 +542,7 @@ gopkg.in/yaml.v3 v3.0.0-20190905181640-827449938966 h1:B0J02caTR6tpSJozBJyiAzT6C gopkg.in/yaml.v3 v3.0.0-20190905181640-827449938966/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw= +helm.sh/helm/v3 v3.0.1/go.mod h1:sI7B9yfvMgxtTPMWdk1jSKJ2aa59UyP9qhPydqW6mgo= honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= istio.io/api v0.0.0-20191111210003-35e06ef8d838 h1:6cTt4JYrfqWmOXvRm9OB6yQ535Dlbauv4xlVHVP/rdo= istio.io/api v0.0.0-20191111210003-35e06ef8d838/go.mod h1:+cyHH83OwC0rFpwk8eXctzPNpiCAbB+r6kmMiAxxBHw= @@ -537,10 +588,13 @@ modernc.org/strutil v1.0.0/go.mod h1:lstksw84oURvj9y3tn8lGvRxyRC1S2+g5uuIzNfIOBs modernc.org/xc v1.0.0/go.mod h1:mRNCo0bvLjGhHO9WsyuKVU4q0ceiDDDoEeWDJHrNx8I= openpitrix.io/iam v0.1.0 h1:cb1mCusim7EGeoXEfuaVa1m7Co/pzim3keoxxKdv944= openpitrix.io/iam v0.1.0/go.mod h1:EcZE8CPBg+1fEKCDEhpsIZ8isWWO7javpu84mSqoVn4= +openpitrix.io/libqueue v0.4.1/go.mod h1:qUuS2viIR86Fm1rLfLRFMMAyltUeGxNt8zoCNkmf/Gk= openpitrix.io/logger v0.1.0/go.mod h1:SV8Btt2cTSmeL9H/1XCkYmQ+WQ2upVY4e0wlr07RP28= -openpitrix.io/openpitrix v0.4.1-0.20190920134345-4d2be6e4965c h1:r/wQNNzFE0Blbf42Dl8pRNSRc+YiYdgOclNcP3VMeTs= -openpitrix.io/openpitrix v0.4.1-0.20190920134345-4d2be6e4965c/go.mod h1:8rZSFeUp2Np5kfKAXfRL/1HSh6BYywNCALt+ZnxFQ/4= +openpitrix.io/notification v0.2.2/go.mod h1:2YRxpnrFk2Z3fXpRXWzbDY9j6Sztrd860Vm8qh5hZzY= +openpitrix.io/openpitrix v0.4.9-0.20200611125425-ae07f141e797 h1:zWzbsWTu2wKovmSXqFgsQTDN7Ckx9TBiD9SQ9qDWQpg= +openpitrix.io/openpitrix v0.4.9-0.20200611125425-ae07f141e797/go.mod h1:sLaDrxic8mrYWWJop4GkBSRwQ0AqVIy7TZzbCOynr8o= rsc.io/goversion v1.0.0/go.mod h1:Eih9y/uIBS3ulggl7KNJ09xGSLcuNaLgmvvqa07sgfo= +rsc.io/letsencrypt v0.0.1/go.mod h1:buyQKZ6IXrRnB7TdkHP0RyEybLx18HHyOSoTyoOLqNY= sigs.k8s.io/controller-runtime v0.4.0 h1:wATM6/m+3w8lj8FXNaO6Fs/rq/vqoOjO1Q116Z9NPsg= sigs.k8s.io/controller-runtime v0.4.0/go.mod h1:ApC79lpY3PHW9xj/w9pj+lYkLgwAAUZwfXkME1Lajns= sigs.k8s.io/controller-tools v0.2.4 h1:la1h46EzElvWefWLqfsXrnsO3lZjpkI0asTpX6h8PLA= diff --git a/pkg/constants/constants.go b/pkg/constants/constants.go index b09a772989cb344c72dbda601f5d6ad68cc1cb62..4530686a8c1f0dba690221f3b673f42b4c98ce78 100644 --- a/pkg/constants/constants.go +++ b/pkg/constants/constants.go @@ -34,6 +34,7 @@ const ( WorkspaceLabelKey = "kubesphere.io/workspace" NamespaceLabelKey = "kubesphere.io/namespace" + RuntimeLabelKey = "openpitrix.io/namespace" DisplayNameAnnotationKey = "kubesphere.io/alias-name" DescriptionAnnotationKey = "kubesphere.io/description" CreatorAnnotationKey = "kubesphere.io/creator" diff --git a/pkg/controller/namespace/namespace_controller.go b/pkg/controller/namespace/namespace_controller.go index a1ac705980bed375adcbf5195d7311bcaa460425..37cb07334d42c89745d3e0d68948297b22d444b0 100644 --- a/pkg/controller/namespace/namespace_controller.go +++ b/pkg/controller/namespace/namespace_controller.go @@ -18,8 +18,6 @@ package namespace import ( "context" - "fmt" - "github.com/golang/protobuf/ptypes/wrappers" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/api/errors" @@ -29,9 +27,7 @@ import ( "k8s.io/klog" "kubesphere.io/kubesphere/pkg/apis/tenant/v1alpha1" "kubesphere.io/kubesphere/pkg/constants" - "kubesphere.io/kubesphere/pkg/simple/client/openpitrix" "kubesphere.io/kubesphere/pkg/utils/sliceutil" - "openpitrix.io/openpitrix/pkg/pb" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/controller" "sigs.k8s.io/controller-runtime/pkg/controller/controllerutil" @@ -48,16 +44,15 @@ import ( // Add creates a new Namespace Controller and adds it to the Manager with default RBAC. The Manager will set fields on the Controller // and Start it when the Manager is Started. -func Add(mgr manager.Manager, openpitrixClient openpitrix.Client) error { - return add(mgr, newReconciler(mgr, openpitrixClient)) +func Add(mgr manager.Manager) error { + return add(mgr, newReconciler(mgr)) } // newReconciler returns a new reconcile.Reconciler -func newReconciler(mgr manager.Manager, openpitrixClient openpitrix.Client) reconcile.Reconciler { +func newReconciler(mgr manager.Manager) reconcile.Reconciler { return &ReconcileNamespace{ - Client: mgr.GetClient(), - scheme: mgr.GetScheme(), - openpitrixClient: openpitrixClient, + Client: mgr.GetClient(), + scheme: mgr.GetScheme(), } } @@ -83,8 +78,7 @@ var _ reconcile.Reconciler = &ReconcileNamespace{} // ReconcileNamespace reconciles a Namespace object type ReconcileNamespace struct { client.Client - openpitrixClient openpitrix.Client - scheme *runtime.Scheme + scheme *runtime.Scheme } // Reconcile reads that state of the cluster for a Namespace object and makes changes based on the state read @@ -130,11 +124,6 @@ func (r *ReconcileNamespace) Reconcile(request reconcile.Request) (reconcile.Res return reconcile.Result{}, err } - // delete runtime - if err = r.deleteRuntime(instance); err != nil { - return reconcile.Result{}, err - } - // remove our finalizer from the list and update it. instance.ObjectMeta.Finalizers = sliceutil.RemoveString(instance.ObjectMeta.Finalizers, func(item string) bool { return item == finalizer @@ -153,13 +142,6 @@ func (r *ReconcileNamespace) Reconcile(request reconcile.Request) (reconcile.Res return reconcile.Result{}, err } - // skip if openpitrix is not enabled - if r.openpitrixClient != nil { - if err := r.checkAndCreateRuntime(instance); err != nil { - return reconcile.Result{}, err - } - } - return reconcile.Result{}, nil } @@ -175,88 +157,6 @@ func (r *ReconcileNamespace) isControlledByWorkspace(namespace *corev1.Namespace return true, nil } -// Create openpitrix runtime -func (r *ReconcileNamespace) checkAndCreateRuntime(namespace *corev1.Namespace) error { - - if runtimeId := namespace.Annotations[constants.OpenPitrixRuntimeAnnotationKey]; runtimeId != "" { - return nil - } - - adminKubeConfigName := fmt.Sprintf("kubeconfig-%s", constants.AdminUserName) - - runtimeCredentials, err := r.openpitrixClient.DescribeRuntimeCredentials(openpitrix.SystemContext(), &pb.DescribeRuntimeCredentialsRequest{SearchWord: &wrappers.StringValue{Value: adminKubeConfigName}, Limit: 1}) - - if err != nil { - klog.Error(fmt.Sprintf("create runtime, namespace: %s, error: %s", namespace.Name, err)) - return err - } - - var kubesphereRuntimeCredentialId string - - // runtime credential exist - if len(runtimeCredentials.GetRuntimeCredentialSet()) > 0 { - kubesphereRuntimeCredentialId = runtimeCredentials.GetRuntimeCredentialSet()[0].GetRuntimeCredentialId().GetValue() - } else { - adminKubeConfig := corev1.ConfigMap{} - err := r.Get(context.TODO(), types.NamespacedName{Namespace: constants.KubeSphereControlNamespace, Name: adminKubeConfigName}, &adminKubeConfig) - - if err != nil { - klog.Error(fmt.Sprintf("create runtime, namespace: %s, error: %s", namespace.Name, err)) - return err - } - - resp, err := r.openpitrixClient.CreateRuntimeCredential(openpitrix.SystemContext(), &pb.CreateRuntimeCredentialRequest{ - Name: &wrappers.StringValue{Value: adminKubeConfigName}, - Provider: &wrappers.StringValue{Value: "kubernetes"}, - Description: &wrappers.StringValue{Value: "kubeconfig"}, - RuntimeUrl: &wrappers.StringValue{Value: "kubesphere"}, - RuntimeCredentialContent: &wrappers.StringValue{Value: adminKubeConfig.Data["config"]}, - }) - - if err != nil { - klog.Error(fmt.Sprintf("create runtime, namespace: %s, error: %s", namespace.Name, err)) - return err - } - - kubesphereRuntimeCredentialId = resp.GetRuntimeCredentialId().GetValue() - } - - // TODO runtime id is invalid when recreate runtime - runtimeId, err := r.openpitrixClient.CreateRuntime(openpitrix.SystemContext(), &pb.CreateRuntimeRequest{ - Name: &wrappers.StringValue{Value: namespace.Name}, - RuntimeCredentialId: &wrappers.StringValue{Value: kubesphereRuntimeCredentialId}, - Provider: &wrappers.StringValue{Value: openpitrix.KubernetesProvider}, - Zone: &wrappers.StringValue{Value: namespace.Name}, - }) - - if err != nil { - klog.Error(fmt.Sprintf("create runtime, namespace: %s, error: %s", namespace.Name, err)) - return err - } - - klog.V(4).Infof("runtime created successfully, namespace: %s, runtime id: %s", namespace.Name, runtimeId) - - return nil -} - -// Delete openpitrix runtime -func (r *ReconcileNamespace) deleteRuntime(namespace *corev1.Namespace) error { - - if runtimeId := namespace.Annotations[constants.OpenPitrixRuntimeAnnotationKey]; runtimeId != "" { - _, err := r.openpitrixClient.DeleteRuntimes(openpitrix.SystemContext(), &pb.DeleteRuntimesRequest{RuntimeId: []string{runtimeId}, Force: &wrappers.BoolValue{Value: true}}) - - if err == nil || openpitrix.IsNotFound(err) || openpitrix.IsDeleted(err) { - return nil - } else { - klog.Errorf("delete openpitrix runtime: %s, error: %s", runtimeId, err) - return err - } - } - - return nil -} - -// Create openpitrix runtime func (r *ReconcileNamespace) checkAndBindWorkspace(namespace *corev1.Namespace) error { workspaceName := namespace.Labels[constants.WorkspaceLabelKey] diff --git a/pkg/kapis/openpitrix/v1/handler.go b/pkg/kapis/openpitrix/v1/handler.go index 09ca9c3e8a5c78a0b3c2705522e073f5fac4f0b1..edc63c2f6d26320f81d76f7dc4bc355749292a24 100644 --- a/pkg/kapis/openpitrix/v1/handler.go +++ b/pkg/kapis/openpitrix/v1/handler.go @@ -1,3 +1,16 @@ +/* +Copyright 2020 The KubeSphere 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. +*/ + package v1 import ( @@ -10,7 +23,6 @@ import ( "kubesphere.io/kubesphere/pkg/api" "kubesphere.io/kubesphere/pkg/constants" "kubesphere.io/kubesphere/pkg/informers" - "kubesphere.io/kubesphere/pkg/models" "kubesphere.io/kubesphere/pkg/models/openpitrix" "kubesphere.io/kubesphere/pkg/server/errors" "kubesphere.io/kubesphere/pkg/server/params" @@ -32,57 +44,40 @@ func newOpenpitrixHandler(factory informers.InformerFactory, opClient op.Client) } } -func (h *openpitrixHandler) ListApplications(request *restful.Request, response *restful.Response) { - limit, offset := params.ParsePaging(request) - namespace := request.PathParameter("namespace") - orderBy := params.GetStringValueWithDefault(request, params.OrderByParam, openpitrix.CreateTime) - reverse := params.GetBoolValueWithDefault(request, params.ReverseParam, false) - conditions, err := params.ParseConditions(request) +func (h *openpitrixHandler) ListApplications(req *restful.Request, resp *restful.Response) { + limit, offset := params.ParsePaging(req) + clusterName := req.PathParameter("cluster") + namespace := req.PathParameter("namespace") + orderBy := params.GetStringValueWithDefault(req, params.OrderByParam, openpitrix.CreateTime) + reverse := params.GetBoolValueWithDefault(req, params.ReverseParam, false) + conditions, err := params.ParseConditions(req) if err != nil { klog.V(4).Infoln(err) - api.HandleBadRequest(response, nil, err) + api.HandleBadRequest(resp, nil, err) return } - - // filter namespaced applications by runtime_id - if namespace != "" { - ns, err := h.informers.Core().V1().Namespaces().Lister().Get(namespace) - - if err != nil { - klog.Errorln(err) - api.HandleInternalError(response, nil, err) - return - } - - runtimeId := ns.Annotations[constants.OpenPitrixRuntimeAnnotationKey] - - if runtimeId == "" { - // runtime id not exist,return empty response - response.WriteAsJson(models.PageableResponse{Items: []interface{}{}, TotalCount: 0}) - return - } else { - // filter by runtime id - conditions.Match[openpitrix.RuntimeId] = runtimeId - } - } + conditions.Match[openpitrix.Zone] = namespace + // in openpitrix, runtime id is the cluster name + conditions.Match[openpitrix.RuntimeId] = clusterName result, err := h.openpitrix.ListApplications(conditions, limit, offset, orderBy, reverse) if err != nil { klog.Errorln(err) - api.HandleInternalError(response, nil, err) + api.HandleInternalError(resp, nil, err) return } - response.WriteAsJson(result) + resp.WriteAsJson(result) } func (h *openpitrixHandler) DescribeApplication(req *restful.Request, resp *restful.Response) { - clusterId := req.PathParameter("application") + clusterName := req.PathParameter("cluster") namespace := req.PathParameter("namespace") + applicationId := req.PathParameter("application") - app, err := h.openpitrix.DescribeApplication(namespace, clusterId) + app, err := h.openpitrix.DescribeApplication(namespace, applicationId, clusterName) if err != nil { klog.Errorln(err) @@ -90,28 +85,12 @@ func (h *openpitrixHandler) DescribeApplication(req *restful.Request, resp *rest return } - ns, err := h.informers.Core().V1().Namespaces().Lister().Get(namespace) - - if err != nil { - klog.Errorln(err) - api.HandleInternalError(resp, nil, err) - return - } - - runtimeId := ns.Annotations[constants.OpenPitrixRuntimeAnnotationKey] - - if runtimeId != app.Cluster.RuntimeId { - err = fmt.Errorf("rumtime not match %s,%s", app.Cluster.RuntimeId, runtimeId) - klog.V(4).Infoln(err) - api.HandleForbidden(resp, nil, err) - return - } - resp.WriteEntity(app) return } func (h *openpitrixHandler) CreateApplication(req *restful.Request, resp *restful.Response) { + clusterName := req.PathParameter("cluster") namespace := req.PathParameter("namespace") var createClusterRequest openpitrix.CreateClusterRequest err := req.ReadEntity(&createClusterRequest) @@ -123,7 +102,7 @@ func (h *openpitrixHandler) CreateApplication(req *restful.Request, resp *restfu createClusterRequest.Username = req.HeaderParameter(constants.UserNameHeader) - err = h.openpitrix.CreateApplication(namespace, createClusterRequest) + err = h.openpitrix.CreateApplication(clusterName, namespace, createClusterRequest) if err != nil { klog.Errorln(err) @@ -136,7 +115,8 @@ func (h *openpitrixHandler) CreateApplication(req *restful.Request, resp *restfu func (h *openpitrixHandler) ModifyApplication(req *restful.Request, resp *restful.Response) { var modifyClusterAttributesRequest openpitrix.ModifyClusterAttributesRequest - clusterId := req.PathParameter("application") + clusterName := req.PathParameter("cluster") + applicationId := req.PathParameter("application") namespace := req.PathParameter("namespace") err := req.ReadEntity(&modifyClusterAttributesRequest) if err != nil { @@ -145,7 +125,7 @@ func (h *openpitrixHandler) ModifyApplication(req *restful.Request, resp *restfu return } - app, err := h.openpitrix.DescribeApplication(namespace, clusterId) + app, err := h.openpitrix.DescribeApplication(namespace, applicationId, clusterName) if err != nil { klog.Errorln(err) @@ -153,24 +133,44 @@ func (h *openpitrixHandler) ModifyApplication(req *restful.Request, resp *restfu return } - ns, err := h.informers.Core().V1().Namespaces().Lister().Get(namespace) + if clusterName != app.Cluster.RuntimeId { + err = fmt.Errorf("runtime and cluster not match %s,%s", app.Cluster.RuntimeId, clusterName) + klog.V(4).Infoln(err) + api.HandleForbidden(resp, nil, err) + return + } + + err = h.openpitrix.ModifyApplication(modifyClusterAttributesRequest) if err != nil { klog.Errorln(err) - api.HandleInternalError(resp, nil, err) + handleOpenpitrixError(resp, err) return } - runtimeId := ns.Annotations[constants.OpenPitrixRuntimeAnnotationKey] + resp.WriteEntity(errors.None) +} + +func (h *openpitrixHandler) DeleteApplication(req *restful.Request, resp *restful.Response) { + clusterName := req.PathParameter("cluster") + applicationId := req.PathParameter("application") + namespace := req.PathParameter("namespace") + app, err := h.openpitrix.DescribeApplication(namespace, applicationId, clusterName) + + if err != nil { + klog.Errorln(err) + handleOpenpitrixError(resp, err) + return + } - if runtimeId != app.Cluster.RuntimeId { - err = fmt.Errorf("rumtime not match %s,%s", app.Cluster.RuntimeId, runtimeId) + if clusterName != app.Cluster.RuntimeId { + err = fmt.Errorf("runtime and cluster not match %s,%s", app.Cluster.RuntimeId, clusterName) klog.V(4).Infoln(err) api.HandleForbidden(resp, nil, err) return } - err = h.openpitrix.ModifyApplication(modifyClusterAttributesRequest) + err = h.openpitrix.DeleteApplication(applicationId) if err != nil { klog.Errorln(err) @@ -181,39 +181,40 @@ func (h *openpitrixHandler) ModifyApplication(req *restful.Request, resp *restfu resp.WriteEntity(errors.None) } -func (h *openpitrixHandler) DeleteApplication(req *restful.Request, resp *restful.Response) { - clusterId := req.PathParameter("application") +func (h *openpitrixHandler) UpgradeApplication(req *restful.Request, resp *restful.Response) { + clusterName := req.PathParameter("cluster") namespace := req.PathParameter("namespace") - app, err := h.openpitrix.DescribeApplication(namespace, clusterId) - + applicationId := req.PathParameter("application") + var upgradeClusterRequest openpitrix.UpgradeClusterRequest + err := req.ReadEntity(&upgradeClusterRequest) if err != nil { - klog.Errorln(err) - handleOpenpitrixError(resp, err) + klog.V(4).Infoln(err) + api.HandleBadRequest(resp, nil, err) return } - ns, err := h.informers.Core().V1().Namespaces().Lister().Get(namespace) + upgradeClusterRequest.Username = req.HeaderParameter(constants.UserNameHeader) + + app, err := h.openpitrix.DescribeApplication(namespace, applicationId, clusterName) if err != nil { klog.Errorln(err) - api.HandleInternalError(resp, nil, err) + handleOpenpitrixError(resp, err) return } - runtimeId := ns.Annotations[constants.OpenPitrixRuntimeAnnotationKey] - - if runtimeId != app.Cluster.RuntimeId { - err = fmt.Errorf("rumtime not match %s,%s", app.Cluster.RuntimeId, runtimeId) + if clusterName != app.Cluster.RuntimeId { + err = fmt.Errorf("runtime and cluster not match %s,%s", app.Cluster.RuntimeId, clusterName) klog.V(4).Infoln(err) api.HandleForbidden(resp, nil, err) return } - err = h.openpitrix.DeleteApplication(clusterId) + err = h.openpitrix.UpgradeApplication(upgradeClusterRequest) if err != nil { klog.Errorln(err) - handleOpenpitrixError(resp, err) + api.HandleInternalError(resp, nil, err) return } @@ -833,6 +834,7 @@ func (h *openpitrixHandler) DescribeRepo(req *restful.Request, resp *restful.Res resp.WriteEntity(result) } + func (h *openpitrixHandler) ListRepos(req *restful.Request, resp *restful.Response) { limit, offset := params.ParsePaging(req) orderBy := params.GetStringValueWithDefault(req, params.OrderByParam, openpitrix.CreateTime) @@ -856,6 +858,29 @@ func (h *openpitrixHandler) ListRepos(req *restful.Request, resp *restful.Respon resp.WriteEntity(result) } +func (h *openpitrixHandler) ListEvents(req *restful.Request, resp *restful.Response) { + limit, offset := params.ParsePaging(req) + orderBy := params.GetStringValueWithDefault(req, params.OrderByParam, openpitrix.CreateTime) + reverse := params.GetBoolValueWithDefault(req, params.ReverseParam, false) + conditions, err := params.ParseConditions(req) + + if err != nil { + klog.V(4).Infoln(err) + api.HandleBadRequest(resp, nil, err) + return + } + + result, err := h.openpitrix.ListEvents(conditions, orderBy, reverse, limit, offset) + + if err != nil { + klog.Errorln(err) + handleOpenpitrixError(resp, err) + return + } + + resp.WriteEntity(result) +} + func (h *openpitrixHandler) ListRepoEvents(req *restful.Request, resp *restful.Response) { repoId := req.PathParameter("repo") limit, offset := params.ParsePaging(req) diff --git a/pkg/kapis/openpitrix/v1/register.go b/pkg/kapis/openpitrix/v1/register.go index e52af6ac58e2ac317b52d63ee6ae95f831564c33..107288129c7af50131c5d6d0c58d12e807d4e0c6 100644 --- a/pkg/kapis/openpitrix/v1/register.go +++ b/pkg/kapis/openpitrix/v1/register.go @@ -1,18 +1,16 @@ /* -Copyright 2019 The KubeSphere Authors. - +Copyright 2020 The KubeSphere 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. */ + package v1 import ( @@ -54,13 +52,27 @@ func AddToContainer(c *restful.Container, factory informers.InformerFactory, op Required(false). DataFormat("key=value,key~value"). DefaultValue("")). - Param(webservice.PathParameter("namespace", "the name of the project")). Param(webservice.QueryParameter(params.PagingParam, "paging query, e.g. limit=100,page=1"). Required(false). DataFormat("limit=%d,page=%d"). DefaultValue("limit=10,page=1"))) - webservice.Route(webservice.GET("/namespaces/{namespace}/applications"). + webservice.Route(webservice.GET("/clusters/{cluster}/applications"). + To(handler.ListApplications). + Returns(http.StatusOK, api.StatusOK, models.PageableResponse{}). + Metadata(restfulspec.KeyOpenAPITags, []string{constants.NamespaceResourcesTag}). + Doc("List all applications in special cluster"). + Param(webservice.QueryParameter(params.ConditionsParam, "query conditions, connect multiple conditions with commas, equal symbol for exact query, wave symbol for fuzzy query e.g. name~a"). + Required(false). + DataFormat("key=value,key~value"). + DefaultValue("")). + Param(webservice.PathParameter("cluster", "the name of the cluster.").Required(true)). + Param(webservice.QueryParameter(params.PagingParam, "paging query, e.g. limit=100,page=1"). + Required(false). + DataFormat("limit=%d,page=%d"). + DefaultValue("limit=10,page=1"))) + + webservice.Route(webservice.GET("/clusters/{cluster}/namespaces/{namespace}/applications"). To(handler.ListApplications). Returns(http.StatusOK, api.StatusOK, models.PageableResponse{}). Metadata(restfulspec.KeyOpenAPITags, []string{constants.NamespaceResourcesTag}). @@ -69,45 +81,61 @@ func AddToContainer(c *restful.Container, factory informers.InformerFactory, op Required(false). DataFormat("key=value,key~value"). DefaultValue("")). - Param(webservice.PathParameter("namespace", "the name of the project")). + Param(webservice.PathParameter("cluster", "the name of the cluster.").Required(true)). + Param(webservice.PathParameter("namespace", "the name of the project").Required(true)). Param(webservice.QueryParameter(params.PagingParam, "paging query, e.g. limit=100,page=1"). Required(false). DataFormat("limit=%d,page=%d"). DefaultValue("limit=10,page=1"))) - webservice.Route(webservice.GET("/namespaces/{namespace}/applications/{application}"). + webservice.Route(webservice.GET("/clusters/{cluster}/namespaces/{namespace}/applications/{application}"). To(handler.DescribeApplication). Returns(http.StatusOK, api.StatusOK, openpitrix2.Application{}). Metadata(restfulspec.KeyOpenAPITags, []string{constants.NamespaceResourcesTag}). Doc("Describe the specified application of the namespace"). - Param(webservice.PathParameter("namespace", "the name of the project")). - Param(webservice.PathParameter("application", "application ID"))) + Param(webservice.PathParameter("cluster", "the name of the cluster.").Required(true)). + Param(webservice.PathParameter("namespace", "the name of the project").Required(true)). + Param(webservice.PathParameter("application", "the id of the application").Required(true))) - webservice.Route(webservice.POST("/namespaces/{namespace}/applications"). + webservice.Route(webservice.POST("/clusters/{cluster}/namespaces/{namespace}/applications"). To(handler.CreateApplication). Doc("Deploy a new application"). Metadata(restfulspec.KeyOpenAPITags, []string{constants.NamespaceResourcesTag}). Reads(openpitrix2.CreateClusterRequest{}). Returns(http.StatusOK, api.StatusOK, errors.Error{}). - Param(webservice.PathParameter("namespace", "the name of the project"))) + Param(webservice.PathParameter("cluster", "the name of the cluster.").Required(true)). + Param(webservice.PathParameter("namespace", "the name of the project").Required(true))) - webservice.Route(webservice.PATCH("/namespaces/{namespace}/applications/{application}"). + webservice.Route(webservice.PATCH("/clusters/{cluster}/namespaces/{namespace}/applications/{application}"). Consumes(mimePatch...). To(handler.ModifyApplication). Doc("Modify application"). Metadata(restfulspec.KeyOpenAPITags, []string{constants.NamespaceResourcesTag}). Reads(openpitrix2.ModifyClusterAttributesRequest{}). Returns(http.StatusOK, api.StatusOK, errors.Error{}). - Param(webservice.PathParameter("namespace", "the name of the project")). - Param(webservice.PathParameter("application", "the id of the application cluster"))) + Param(webservice.PathParameter("cluster", "the name of the cluster.").Required(true)). + Param(webservice.PathParameter("namespace", "the name of the project").Required(true)). + Param(webservice.PathParameter("application", "the id of the application").Required(true))) - webservice.Route(webservice.DELETE("/namespaces/{namespace}/applications/{application}"). + webservice.Route(webservice.DELETE("/clusters/{cluster}/namespaces/{namespace}/applications/{application}"). To(handler.DeleteApplication). Doc("Delete the specified application"). Metadata(restfulspec.KeyOpenAPITags, []string{constants.NamespaceResourcesTag}). Returns(http.StatusOK, api.StatusOK, errors.Error{}). - Param(webservice.PathParameter("namespace", "the name of the project")). - Param(webservice.PathParameter("application", "the id of the application cluster"))) + Param(webservice.PathParameter("cluster", "the name of the cluster.").Required(true)). + Param(webservice.PathParameter("namespace", "the name of the project").Required(true)). + Param(webservice.PathParameter("application", "the id of the application").Required(true))) + + webservice.Route(webservice.POST("/clusters/{cluster}/namespaces/{namespace}/applications/{application}"). + Consumes(mimePatch...). + To(handler.UpgradeApplication). + Doc("Upgrade application"). + Metadata(restfulspec.KeyOpenAPITags, []string{constants.NamespaceResourcesTag}). + Reads(openpitrix2.UpgradeClusterRequest{}). + Returns(http.StatusOK, api.StatusOK, errors.Error{}). + Param(webservice.PathParameter("cluster", "the name of the cluster.").Required(true)). + Param(webservice.PathParameter("namespace", "the name of the project").Required(true)). + Param(webservice.PathParameter("application", "the id of the application").Required(true))) webservice.Route(webservice.POST("/apps/{app}/versions"). To(handler.CreateAppVersion). @@ -333,6 +361,13 @@ func AddToContainer(c *restful.Container, factory informers.InformerFactory, op Reads(openpitrix2.RepoActionRequest{}). Returns(http.StatusOK, api.StatusOK, errors.Error{}). Param(webservice.PathParameter("repo", "repo id"))) + webservice.Route(webservice.GET("/events"). + To(handler.ListEvents). + Doc("Get events"). + Param(webservice.QueryParameter(params.ConditionsParam, "query conditions,connect multiple conditions with commas, equal symbol for exact query, wave symbol for fuzzy query e.g. name~a"). + Required(false). + DataFormat("key=%s,key~%s")). + Returns(http.StatusOK, api.StatusOK, models.PageableResponse{})) webservice.Route(webservice.GET("/repos/{repo}/events"). To(handler.ListRepoEvents). Doc("Get repository events"). diff --git a/pkg/models/openpitrix/applications.go b/pkg/models/openpitrix/applications.go index c2de1a2f9c56bc4e461a006d03f2262c84268ed3..e81f1fb8010d505d60ebb1ac88182ca35fc1d551 100644 --- a/pkg/models/openpitrix/applications.go +++ b/pkg/models/openpitrix/applications.go @@ -1,22 +1,20 @@ /* Copyright 2020 The KubeSphere 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. */ + package openpitrix import ( - "fmt" + "encoding/json" "github.com/golang/protobuf/ptypes/wrappers" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" @@ -27,20 +25,21 @@ import ( "k8s.io/apimachinery/pkg/labels" "k8s.io/client-go/informers" "k8s.io/klog" - "kubesphere.io/kubesphere/pkg/constants" "kubesphere.io/kubesphere/pkg/models" "kubesphere.io/kubesphere/pkg/server/params" "kubesphere.io/kubesphere/pkg/simple/client/openpitrix" "openpitrix.io/openpitrix/pkg/pb" + "openpitrix.io/openpitrix/pkg/util/pbutil" "strings" ) type ApplicationInterface interface { ListApplications(conditions *params.Conditions, limit, offset int, orderBy string, reverse bool) (*models.PageableResponse, error) - DescribeApplication(namespace, clusterId string) (*Application, error) - CreateApplication(namespace string, request CreateClusterRequest) error + DescribeApplication(namespace, applicationId, clusterName string) (*Application, error) + CreateApplication(clusterName, namespace string, request CreateClusterRequest) error ModifyApplication(request ModifyClusterAttributesRequest) error DeleteApplication(id string) error + UpgradeApplication(request UpgradeClusterRequest) error } type applicationOperator struct { @@ -68,6 +67,14 @@ type workLoads struct { Daemonsets []appsv1.DaemonSet `json:"daemonsets,omitempty" description:"daemonset list"` } +type resourceInfo struct { + Deployments []appsv1.Deployment `json:"deployments,omitempty" description:"deployment list"` + Statefulsets []appsv1.StatefulSet `json:"statefulsets,omitempty" description:"statefulset list"` + Daemonsets []appsv1.DaemonSet `json:"daemonsets,omitempty" description:"daemonset list"` + Services []v1.Service `json:"services,omitempty" description:"application services"` + Ingresses []v1beta1.Ingress `json:"ingresses,omitempty" description:"application ingresses"` +} + func (c *applicationOperator) ListApplications(conditions *params.Conditions, limit, offset int, orderBy string, reverse bool) (*models.PageableResponse, error) { describeClustersRequest := &pb.DescribeClustersRequest{ Limit: uint32(limit), @@ -87,6 +94,9 @@ func (c *applicationOperator) ListApplications(conditions *params.Conditions, li if status := conditions.Match[Status]; status != "" { describeClustersRequest.Status = strings.Split(status, "|") } + if zone := conditions.Match[Zone]; zone != "" { + describeClustersRequest.Zone = []string{zone} + } if orderBy != "" { describeClustersRequest.SortKey = &wrappers.StringValue{Value: orderBy} } @@ -133,9 +143,15 @@ func (c *applicationOperator) describeApplication(cluster *pb.Cluster) (*Applica return &app, nil } -func (c *applicationOperator) DescribeApplication(namespace string, clusterId string) (*Application, error) { - - clusters, err := c.opClient.DescribeClusters(openpitrix.SystemContext(), &pb.DescribeClustersRequest{ClusterId: []string{clusterId}, Limit: 1}) +func (c *applicationOperator) DescribeApplication(namespace string, applicationId string, clusterName string) (*Application, error) { + describeClusterRequest := &pb.DescribeClustersRequest{ + ClusterId: []string{applicationId}, + RuntimeId: []string{clusterName}, + Zone: []string{namespace}, + WithDetail: pbutil.ToProtoBool(true), + Limit: 1, + } + clusters, err := c.opClient.DescribeClusters(openpitrix.SystemContext(), describeClusterRequest) if err != nil { klog.Errorln(err) @@ -156,16 +172,26 @@ func (c *applicationOperator) DescribeApplication(namespace string, clusterId st return nil, err } - workloads, err := c.getWorkLoads(namespace, cluster.ClusterRoleSet) - + resource := new(resourceInfo) + workloads := cluster.AdditionalInfo.GetValue() + if workloads == "" { + err := status.New(codes.NotFound, "cannot get workload").Err() + klog.Errorln(err) + return nil, err + } + err = json.Unmarshal([]byte(workloads), resource) if err != nil { klog.Errorln(err) return nil, err } - app.WorkLoads = workloads - workloadLabels := c.getLabels(namespace, app.WorkLoads) - app.Services = c.getSvcs(namespace, workloadLabels) - app.Ingresses = c.getIng(namespace, app.Services) + + app.WorkLoads = &workLoads{ + Deployments: resource.Deployments, + Statefulsets: resource.Statefulsets, + Daemonsets: resource.Daemonsets, + } + app.Services = resource.Services + app.Ingresses = resource.Ingresses return app, nil } @@ -332,24 +358,13 @@ func (c *applicationOperator) getIng(namespace string, services []v1.Service) [] return ings } -func (c *applicationOperator) CreateApplication(namespace string, request CreateClusterRequest) error { - ns, err := c.informers.Core().V1().Namespaces().Lister().Get(namespace) - if err != nil { - klog.Error(err) - return err - } - - if runtimeId := ns.Annotations[constants.OpenPitrixRuntimeAnnotationKey]; runtimeId != "" { - request.RuntimeId = runtimeId - } else { - return fmt.Errorf("runtime not init: namespace %s", namespace) - } - - _, err = c.opClient.CreateCluster(openpitrix.ContextWithUsername(request.Username), &pb.CreateClusterRequest{ +func (c *applicationOperator) CreateApplication(clusterName, namespace string, request CreateClusterRequest) error { + _, err := c.opClient.CreateCluster(openpitrix.ContextWithUsername(request.Username), &pb.CreateClusterRequest{ AppId: &wrappers.StringValue{Value: request.AppId}, VersionId: &wrappers.StringValue{Value: request.VersionId}, - RuntimeId: &wrappers.StringValue{Value: request.RuntimeId}, + RuntimeId: &wrappers.StringValue{Value: clusterName}, Conf: &wrappers.StringValue{Value: request.Conf}, + Zone: &wrappers.StringValue{Value: namespace}, }) if err != nil { @@ -380,8 +395,22 @@ func (c *applicationOperator) ModifyApplication(request ModifyClusterAttributesR return nil } -func (c *applicationOperator) DeleteApplication(clusterId string) error { - _, err := c.opClient.DeleteClusters(openpitrix.SystemContext(), &pb.DeleteClustersRequest{ClusterId: []string{clusterId}, Force: &wrappers.BoolValue{Value: true}}) +func (c *applicationOperator) DeleteApplication(applicationId string) error { + _, err := c.opClient.DeleteClusters(openpitrix.SystemContext(), &pb.DeleteClustersRequest{ClusterId: []string{applicationId}, Force: &wrappers.BoolValue{Value: true}}) + + if err != nil { + klog.Errorln(err) + return err + } + + return nil +} + +func (c *applicationOperator) UpgradeApplication(request UpgradeClusterRequest) error { + _, err := c.opClient.UpgradeCluster(openpitrix.ContextWithUsername(request.Username), &pb.UpgradeClusterRequest{ + ClusterId: &wrappers.StringValue{Value: request.ClusterId}, + VersionId: &wrappers.StringValue{Value: request.VersionId}, + }) if err != nil { klog.Errorln(err) diff --git a/pkg/models/openpitrix/applications_test.go b/pkg/models/openpitrix/applications_test.go index 48d33d84b9493de7f15182efc6b68486177dc786..d3c1882761ea8d4f0facc82ff527f6dfa0b58832 100644 --- a/pkg/models/openpitrix/applications_test.go +++ b/pkg/models/openpitrix/applications_test.go @@ -1,12 +1,9 @@ /* Copyright 2020 The KubeSphere 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. @@ -97,11 +94,12 @@ func TestApplicationOperator_CreateApplication(t *testing.T) { VersionId: &wrappers.StringValue{Value: test.createClusterRequest.VersionId}, RuntimeId: &wrappers.StringValue{Value: test.createClusterRequest.RuntimeId}, Conf: &wrappers.StringValue{Value: test.createClusterRequest.Conf}, + Zone: &wrappers.StringValue{Value: test.targetNamespace}, }).Return(&pb.CreateClusterResponse{}, nil).AnyTimes() t.Run(test.description, func(t *testing.T) { - err := applicationOperator.CreateApplication(test.targetNamespace, test.createClusterRequest) + err := applicationOperator.CreateApplication(test.createClusterRequest.RuntimeId, test.targetNamespace, test.createClusterRequest) if err != nil && err.Error() != test.expected.Error() { t.Error(err) diff --git a/pkg/models/openpitrix/apps.go b/pkg/models/openpitrix/apps.go index f5b1d70425b78183391b34a6bf275c14dbef2988..ee0540627ee8eae3791070df3371331417cdb21e 100644 --- a/pkg/models/openpitrix/apps.go +++ b/pkg/models/openpitrix/apps.go @@ -1,12 +1,9 @@ /* Copyright 2020 The KubeSphere 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. diff --git a/pkg/models/openpitrix/attachments.go b/pkg/models/openpitrix/attachments.go index 4d19c2d05f9b218fd79eac1c2c79548888d5609f..7b77c5b24f3d6da8e0909af4101d0e7f3ea2a7c5 100644 --- a/pkg/models/openpitrix/attachments.go +++ b/pkg/models/openpitrix/attachments.go @@ -1,12 +1,9 @@ /* -Copyright 2019 The KubeSphere Authors. - +Copyright 2020 The KubeSphere 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. diff --git a/pkg/models/openpitrix/categories.go b/pkg/models/openpitrix/categories.go index 519e32b7f92388f6aba98b237aeb6f1dbb48c449..74992ba8fca6d8e1b9e7a7f4ccc9b8aef16bcf89 100644 --- a/pkg/models/openpitrix/categories.go +++ b/pkg/models/openpitrix/categories.go @@ -1,12 +1,9 @@ /* Copyright 2020 The KubeSphere 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. diff --git a/pkg/models/openpitrix/interface.go b/pkg/models/openpitrix/interface.go index 63f414c473c89e52e62eeeebc8d7f082759d5394..174637838923fb5b9dba35d820ee08fbc4586e51 100644 --- a/pkg/models/openpitrix/interface.go +++ b/pkg/models/openpitrix/interface.go @@ -1,12 +1,9 @@ /* Copyright 2020 The KubeSphere 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. diff --git a/pkg/models/openpitrix/repos.go b/pkg/models/openpitrix/repos.go index 25d75821bf7b3d0721e3e0e75078a2fdc497d35b..e8d169d45c5b3a97bbdc267ddb74855de96c2448 100644 --- a/pkg/models/openpitrix/repos.go +++ b/pkg/models/openpitrix/repos.go @@ -1,12 +1,9 @@ /* Copyright 2020 The KubeSphere 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. @@ -37,6 +34,7 @@ type RepoInterface interface { ListRepos(conditions *params.Conditions, orderBy string, reverse bool, limit, offset int) (*models.PageableResponse, error) ValidateRepo(request *ValidateRepoRequest) (*ValidateRepoResponse, error) DoRepoAction(repoId string, request *RepoActionRequest) error + ListEvents(conditions *params.Conditions, orderBy string, reverse bool, limit, offset int) (*models.PageableResponse, error) ListRepoEvents(repoId string, conditions *params.Conditions, limit, offset int) (*models.PageableResponse, error) } @@ -267,3 +265,33 @@ func (c *repoOperator) ListRepoEvents(repoId string, conditions *params.Conditio return &models.PageableResponse{Items: items, TotalCount: int(resp.TotalCount)}, nil } + +func (c *repoOperator) ListEvents(conditions *params.Conditions, orderBy string, reverse bool, limit, offset int) (*models.PageableResponse, error) { + describeRepoEventsRequest := &pb.DescribeRepoEventsRequest{} + if repoId := conditions.Match["repo_id"]; repoId != "" { + describeRepoEventsRequest.RepoId = strings.Split(repoId, "|") + } + if eventId := conditions.Match["repo_event_id"]; eventId != "" { + describeRepoEventsRequest.RepoEventId = strings.Split(eventId, "|") + } + if status := conditions.Match["status"]; status != "" { + describeRepoEventsRequest.Status = strings.Split(status, "|") + } + describeRepoEventsRequest.Limit = uint32(limit) + describeRepoEventsRequest.Offset = uint32(offset) + + resp, err := c.opClient.DescribeRepoEvents(openpitrix.SystemContext(), describeRepoEventsRequest) + + if err != nil { + klog.Error(err) + return nil, err + } + + items := make([]interface{}, 0) + + for _, item := range resp.RepoEventSet { + items = append(items, convertRepoEvent(item)) + } + + return &models.PageableResponse{Items: items, TotalCount: int(resp.TotalCount)}, nil +} diff --git a/pkg/models/openpitrix/types.go b/pkg/models/openpitrix/types.go index 92f1e021eeeafc9d6981e6ee280fd318f01da5ca..8c6608796bc3074df69346f62d3d3f7ebaa9da21 100644 --- a/pkg/models/openpitrix/types.go +++ b/pkg/models/openpitrix/types.go @@ -1,3 +1,16 @@ +/* +Copyright 2020 The KubeSphere 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. +*/ + package openpitrix import ( @@ -737,6 +750,25 @@ type CreateClusterRequest struct { Username string `json:"-"` } +type UpgradeClusterRequest struct { + // cluster id + ClusterId string `json:"cluster_id"` + + // advanced param + AdvancedParam []string `json:"advanced_param"` + + // required, conf a json string, include cpu, memory info of cluster + Conf string `json:"conf,omitempty"` + + // required, id of runtime + RuntimeId string `json:"runtime_id,omitempty"` + + // required, id of app version + VersionId string `json:"version_id,omitempty"` + + Username string `json:"-"` +} + type Cluster struct { // additional info @@ -840,6 +872,7 @@ const ( CreateTime = "create_time" StatusTime = "status_time" RuntimeId = "runtime_id" + Zone = "zone" VersionId = "version_id" RepoId = "repo_id" CategoryId = "category_id" diff --git a/pkg/models/openpitrix/utils.go b/pkg/models/openpitrix/utils.go index a660aef12135d4fcfd4c212c7e1e08e91fd06e9a..848c70f26af1a6cda6daa2f546245fd676473253 100644 --- a/pkg/models/openpitrix/utils.go +++ b/pkg/models/openpitrix/utils.go @@ -1,12 +1,9 @@ /* -Copyright 2019 The KubeSphere Authors. - +Copyright 2020 The KubeSphere 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. diff --git a/pkg/simple/client/openpitrix/mock.go b/pkg/simple/client/openpitrix/mock.go index dc4d51e50be11d696aa1665e9b670c02267bd55b..14393d66feb5c3c7f617795b5d29c580f14a2758 100644 --- a/pkg/simple/client/openpitrix/mock.go +++ b/pkg/simple/client/openpitrix/mock.go @@ -13,30 +13,30 @@ import ( reflect "reflect" ) -// MockClient is a mock of Client interface +// MockClient is a mock of Client interface. type MockClient struct { ctrl *gomock.Controller recorder *MockClientMockRecorder } -// MockClientMockRecorder is the mock recorder for MockClient +// MockClientMockRecorder is the mock recorder for MockClient. type MockClientMockRecorder struct { mock *MockClient } -// NewMockClient creates a new mock instance +// NewMockClient creates a new mock instance. func NewMockClient(ctrl *gomock.Controller) *MockClient { mock := &MockClient{ctrl: ctrl} mock.recorder = &MockClientMockRecorder{mock} return mock } -// EXPECT returns an object that allows the caller to indicate expected use +// EXPECT returns an object that allows the caller to indicate expected use. func (m *MockClient) EXPECT() *MockClientMockRecorder { return m.recorder } -// CreateRuntime mocks base method +// CreateRuntime mocks base method. func (m *MockClient) CreateRuntime(ctx context.Context, in *pb.CreateRuntimeRequest, opts ...grpc.CallOption) (*pb.CreateRuntimeResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -49,14 +49,14 @@ func (m *MockClient) CreateRuntime(ctx context.Context, in *pb.CreateRuntimeRequ return ret0, ret1 } -// CreateRuntime indicates an expected call of CreateRuntime +// CreateRuntime indicates an expected call of CreateRuntime. func (mr *MockClientMockRecorder) CreateRuntime(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateRuntime", reflect.TypeOf((*MockClient)(nil).CreateRuntime), varargs...) } -// CreateDebugRuntime mocks base method +// CreateDebugRuntime mocks base method. func (m *MockClient) CreateDebugRuntime(ctx context.Context, in *pb.CreateRuntimeRequest, opts ...grpc.CallOption) (*pb.CreateRuntimeResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -69,14 +69,14 @@ func (m *MockClient) CreateDebugRuntime(ctx context.Context, in *pb.CreateRuntim return ret0, ret1 } -// CreateDebugRuntime indicates an expected call of CreateDebugRuntime +// CreateDebugRuntime indicates an expected call of CreateDebugRuntime. func (mr *MockClientMockRecorder) CreateDebugRuntime(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateDebugRuntime", reflect.TypeOf((*MockClient)(nil).CreateDebugRuntime), varargs...) } -// DescribeRuntimeDetails mocks base method +// DescribeRuntimeDetails mocks base method. func (m *MockClient) DescribeRuntimeDetails(ctx context.Context, in *pb.DescribeRuntimesRequest, opts ...grpc.CallOption) (*pb.DescribeRuntimeDetailsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -89,14 +89,14 @@ func (m *MockClient) DescribeRuntimeDetails(ctx context.Context, in *pb.Describe return ret0, ret1 } -// DescribeRuntimeDetails indicates an expected call of DescribeRuntimeDetails +// DescribeRuntimeDetails indicates an expected call of DescribeRuntimeDetails. func (mr *MockClientMockRecorder) DescribeRuntimeDetails(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeRuntimeDetails", reflect.TypeOf((*MockClient)(nil).DescribeRuntimeDetails), varargs...) } -// DescribeRuntimes mocks base method +// DescribeRuntimes mocks base method. func (m *MockClient) DescribeRuntimes(ctx context.Context, in *pb.DescribeRuntimesRequest, opts ...grpc.CallOption) (*pb.DescribeRuntimesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -109,14 +109,14 @@ func (m *MockClient) DescribeRuntimes(ctx context.Context, in *pb.DescribeRuntim return ret0, ret1 } -// DescribeRuntimes indicates an expected call of DescribeRuntimes +// DescribeRuntimes indicates an expected call of DescribeRuntimes. func (mr *MockClientMockRecorder) DescribeRuntimes(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeRuntimes", reflect.TypeOf((*MockClient)(nil).DescribeRuntimes), varargs...) } -// DescribeDebugRuntimes mocks base method +// DescribeDebugRuntimes mocks base method. func (m *MockClient) DescribeDebugRuntimes(ctx context.Context, in *pb.DescribeRuntimesRequest, opts ...grpc.CallOption) (*pb.DescribeRuntimesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -129,14 +129,14 @@ func (m *MockClient) DescribeDebugRuntimes(ctx context.Context, in *pb.DescribeR return ret0, ret1 } -// DescribeDebugRuntimes indicates an expected call of DescribeDebugRuntimes +// DescribeDebugRuntimes indicates an expected call of DescribeDebugRuntimes. func (mr *MockClientMockRecorder) DescribeDebugRuntimes(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeDebugRuntimes", reflect.TypeOf((*MockClient)(nil).DescribeDebugRuntimes), varargs...) } -// ModifyRuntime mocks base method +// ModifyRuntime mocks base method. func (m *MockClient) ModifyRuntime(ctx context.Context, in *pb.ModifyRuntimeRequest, opts ...grpc.CallOption) (*pb.ModifyRuntimeResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -149,14 +149,14 @@ func (m *MockClient) ModifyRuntime(ctx context.Context, in *pb.ModifyRuntimeRequ return ret0, ret1 } -// ModifyRuntime indicates an expected call of ModifyRuntime +// ModifyRuntime indicates an expected call of ModifyRuntime. func (mr *MockClientMockRecorder) ModifyRuntime(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ModifyRuntime", reflect.TypeOf((*MockClient)(nil).ModifyRuntime), varargs...) } -// DeleteRuntimes mocks base method +// DeleteRuntimes mocks base method. func (m *MockClient) DeleteRuntimes(ctx context.Context, in *pb.DeleteRuntimesRequest, opts ...grpc.CallOption) (*pb.DeleteRuntimesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -169,14 +169,14 @@ func (m *MockClient) DeleteRuntimes(ctx context.Context, in *pb.DeleteRuntimesRe return ret0, ret1 } -// DeleteRuntimes indicates an expected call of DeleteRuntimes +// DeleteRuntimes indicates an expected call of DeleteRuntimes. func (mr *MockClientMockRecorder) DeleteRuntimes(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteRuntimes", reflect.TypeOf((*MockClient)(nil).DeleteRuntimes), varargs...) } -// CreateRuntimeCredential mocks base method +// CreateRuntimeCredential mocks base method. func (m *MockClient) CreateRuntimeCredential(ctx context.Context, in *pb.CreateRuntimeCredentialRequest, opts ...grpc.CallOption) (*pb.CreateRuntimeCredentialResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -189,14 +189,14 @@ func (m *MockClient) CreateRuntimeCredential(ctx context.Context, in *pb.CreateR return ret0, ret1 } -// CreateRuntimeCredential indicates an expected call of CreateRuntimeCredential +// CreateRuntimeCredential indicates an expected call of CreateRuntimeCredential. func (mr *MockClientMockRecorder) CreateRuntimeCredential(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateRuntimeCredential", reflect.TypeOf((*MockClient)(nil).CreateRuntimeCredential), varargs...) } -// CreateDebugRuntimeCredential mocks base method +// CreateDebugRuntimeCredential mocks base method. func (m *MockClient) CreateDebugRuntimeCredential(ctx context.Context, in *pb.CreateRuntimeCredentialRequest, opts ...grpc.CallOption) (*pb.CreateRuntimeCredentialResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -209,14 +209,14 @@ func (m *MockClient) CreateDebugRuntimeCredential(ctx context.Context, in *pb.Cr return ret0, ret1 } -// CreateDebugRuntimeCredential indicates an expected call of CreateDebugRuntimeCredential +// CreateDebugRuntimeCredential indicates an expected call of CreateDebugRuntimeCredential. func (mr *MockClientMockRecorder) CreateDebugRuntimeCredential(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateDebugRuntimeCredential", reflect.TypeOf((*MockClient)(nil).CreateDebugRuntimeCredential), varargs...) } -// DescribeRuntimeCredentials mocks base method +// DescribeRuntimeCredentials mocks base method. func (m *MockClient) DescribeRuntimeCredentials(ctx context.Context, in *pb.DescribeRuntimeCredentialsRequest, opts ...grpc.CallOption) (*pb.DescribeRuntimeCredentialsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -229,14 +229,14 @@ func (m *MockClient) DescribeRuntimeCredentials(ctx context.Context, in *pb.Desc return ret0, ret1 } -// DescribeRuntimeCredentials indicates an expected call of DescribeRuntimeCredentials +// DescribeRuntimeCredentials indicates an expected call of DescribeRuntimeCredentials. func (mr *MockClientMockRecorder) DescribeRuntimeCredentials(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeRuntimeCredentials", reflect.TypeOf((*MockClient)(nil).DescribeRuntimeCredentials), varargs...) } -// DescribeDebugRuntimeCredentials mocks base method +// DescribeDebugRuntimeCredentials mocks base method. func (m *MockClient) DescribeDebugRuntimeCredentials(ctx context.Context, in *pb.DescribeRuntimeCredentialsRequest, opts ...grpc.CallOption) (*pb.DescribeRuntimeCredentialsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -249,14 +249,14 @@ func (m *MockClient) DescribeDebugRuntimeCredentials(ctx context.Context, in *pb return ret0, ret1 } -// DescribeDebugRuntimeCredentials indicates an expected call of DescribeDebugRuntimeCredentials +// DescribeDebugRuntimeCredentials indicates an expected call of DescribeDebugRuntimeCredentials. func (mr *MockClientMockRecorder) DescribeDebugRuntimeCredentials(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeDebugRuntimeCredentials", reflect.TypeOf((*MockClient)(nil).DescribeDebugRuntimeCredentials), varargs...) } -// ModifyRuntimeCredential mocks base method +// ModifyRuntimeCredential mocks base method. func (m *MockClient) ModifyRuntimeCredential(ctx context.Context, in *pb.ModifyRuntimeCredentialRequest, opts ...grpc.CallOption) (*pb.ModifyRuntimeCredentialResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -269,14 +269,14 @@ func (m *MockClient) ModifyRuntimeCredential(ctx context.Context, in *pb.ModifyR return ret0, ret1 } -// ModifyRuntimeCredential indicates an expected call of ModifyRuntimeCredential +// ModifyRuntimeCredential indicates an expected call of ModifyRuntimeCredential. func (mr *MockClientMockRecorder) ModifyRuntimeCredential(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ModifyRuntimeCredential", reflect.TypeOf((*MockClient)(nil).ModifyRuntimeCredential), varargs...) } -// DeleteRuntimeCredentials mocks base method +// DeleteRuntimeCredentials mocks base method. func (m *MockClient) DeleteRuntimeCredentials(ctx context.Context, in *pb.DeleteRuntimeCredentialsRequest, opts ...grpc.CallOption) (*pb.DeleteRuntimeCredentialsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -289,14 +289,14 @@ func (m *MockClient) DeleteRuntimeCredentials(ctx context.Context, in *pb.Delete return ret0, ret1 } -// DeleteRuntimeCredentials indicates an expected call of DeleteRuntimeCredentials +// DeleteRuntimeCredentials indicates an expected call of DeleteRuntimeCredentials. func (mr *MockClientMockRecorder) DeleteRuntimeCredentials(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteRuntimeCredentials", reflect.TypeOf((*MockClient)(nil).DeleteRuntimeCredentials), varargs...) } -// ValidateRuntimeCredential mocks base method +// ValidateRuntimeCredential mocks base method. func (m *MockClient) ValidateRuntimeCredential(ctx context.Context, in *pb.ValidateRuntimeCredentialRequest, opts ...grpc.CallOption) (*pb.ValidateRuntimeCredentialResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -309,14 +309,14 @@ func (m *MockClient) ValidateRuntimeCredential(ctx context.Context, in *pb.Valid return ret0, ret1 } -// ValidateRuntimeCredential indicates an expected call of ValidateRuntimeCredential +// ValidateRuntimeCredential indicates an expected call of ValidateRuntimeCredential. func (mr *MockClientMockRecorder) ValidateRuntimeCredential(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ValidateRuntimeCredential", reflect.TypeOf((*MockClient)(nil).ValidateRuntimeCredential), varargs...) } -// DescribeRuntimeProviderZones mocks base method +// DescribeRuntimeProviderZones mocks base method. func (m *MockClient) DescribeRuntimeProviderZones(ctx context.Context, in *pb.DescribeRuntimeProviderZonesRequest, opts ...grpc.CallOption) (*pb.DescribeRuntimeProviderZonesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -329,14 +329,14 @@ func (m *MockClient) DescribeRuntimeProviderZones(ctx context.Context, in *pb.De return ret0, ret1 } -// DescribeRuntimeProviderZones indicates an expected call of DescribeRuntimeProviderZones +// DescribeRuntimeProviderZones indicates an expected call of DescribeRuntimeProviderZones. func (mr *MockClientMockRecorder) DescribeRuntimeProviderZones(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeRuntimeProviderZones", reflect.TypeOf((*MockClient)(nil).DescribeRuntimeProviderZones), varargs...) } -// GetRuntimeStatistics mocks base method +// GetRuntimeStatistics mocks base method. func (m *MockClient) GetRuntimeStatistics(ctx context.Context, in *pb.GetRuntimeStatisticsRequest, opts ...grpc.CallOption) (*pb.GetRuntimeStatisticsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -349,14 +349,14 @@ func (m *MockClient) GetRuntimeStatistics(ctx context.Context, in *pb.GetRuntime return ret0, ret1 } -// GetRuntimeStatistics indicates an expected call of GetRuntimeStatistics +// GetRuntimeStatistics indicates an expected call of GetRuntimeStatistics. func (mr *MockClientMockRecorder) GetRuntimeStatistics(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetRuntimeStatistics", reflect.TypeOf((*MockClient)(nil).GetRuntimeStatistics), varargs...) } -// AddNodeKeyPairs mocks base method +// AddNodeKeyPairs mocks base method. func (m *MockClient) AddNodeKeyPairs(ctx context.Context, in *pb.AddNodeKeyPairsRequest, opts ...grpc.CallOption) (*pb.AddNodeKeyPairsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -369,14 +369,14 @@ func (m *MockClient) AddNodeKeyPairs(ctx context.Context, in *pb.AddNodeKeyPairs return ret0, ret1 } -// AddNodeKeyPairs indicates an expected call of AddNodeKeyPairs +// AddNodeKeyPairs indicates an expected call of AddNodeKeyPairs. func (mr *MockClientMockRecorder) AddNodeKeyPairs(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddNodeKeyPairs", reflect.TypeOf((*MockClient)(nil).AddNodeKeyPairs), varargs...) } -// DeleteNodeKeyPairs mocks base method +// DeleteNodeKeyPairs mocks base method. func (m *MockClient) DeleteNodeKeyPairs(ctx context.Context, in *pb.DeleteNodeKeyPairsRequest, opts ...grpc.CallOption) (*pb.DeleteNodeKeyPairsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -389,14 +389,14 @@ func (m *MockClient) DeleteNodeKeyPairs(ctx context.Context, in *pb.DeleteNodeKe return ret0, ret1 } -// DeleteNodeKeyPairs indicates an expected call of DeleteNodeKeyPairs +// DeleteNodeKeyPairs indicates an expected call of DeleteNodeKeyPairs. func (mr *MockClientMockRecorder) DeleteNodeKeyPairs(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteNodeKeyPairs", reflect.TypeOf((*MockClient)(nil).DeleteNodeKeyPairs), varargs...) } -// CreateKeyPair mocks base method +// CreateKeyPair mocks base method. func (m *MockClient) CreateKeyPair(ctx context.Context, in *pb.CreateKeyPairRequest, opts ...grpc.CallOption) (*pb.CreateKeyPairResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -409,14 +409,14 @@ func (m *MockClient) CreateKeyPair(ctx context.Context, in *pb.CreateKeyPairRequ return ret0, ret1 } -// CreateKeyPair indicates an expected call of CreateKeyPair +// CreateKeyPair indicates an expected call of CreateKeyPair. func (mr *MockClientMockRecorder) CreateKeyPair(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateKeyPair", reflect.TypeOf((*MockClient)(nil).CreateKeyPair), varargs...) } -// DescribeKeyPairs mocks base method +// DescribeKeyPairs mocks base method. func (m *MockClient) DescribeKeyPairs(ctx context.Context, in *pb.DescribeKeyPairsRequest, opts ...grpc.CallOption) (*pb.DescribeKeyPairsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -429,14 +429,14 @@ func (m *MockClient) DescribeKeyPairs(ctx context.Context, in *pb.DescribeKeyPai return ret0, ret1 } -// DescribeKeyPairs indicates an expected call of DescribeKeyPairs +// DescribeKeyPairs indicates an expected call of DescribeKeyPairs. func (mr *MockClientMockRecorder) DescribeKeyPairs(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeKeyPairs", reflect.TypeOf((*MockClient)(nil).DescribeKeyPairs), varargs...) } -// DeleteKeyPairs mocks base method +// DeleteKeyPairs mocks base method. func (m *MockClient) DeleteKeyPairs(ctx context.Context, in *pb.DeleteKeyPairsRequest, opts ...grpc.CallOption) (*pb.DeleteKeyPairsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -449,14 +449,14 @@ func (m *MockClient) DeleteKeyPairs(ctx context.Context, in *pb.DeleteKeyPairsRe return ret0, ret1 } -// DeleteKeyPairs indicates an expected call of DeleteKeyPairs +// DeleteKeyPairs indicates an expected call of DeleteKeyPairs. func (mr *MockClientMockRecorder) DeleteKeyPairs(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteKeyPairs", reflect.TypeOf((*MockClient)(nil).DeleteKeyPairs), varargs...) } -// AttachKeyPairs mocks base method +// AttachKeyPairs mocks base method. func (m *MockClient) AttachKeyPairs(ctx context.Context, in *pb.AttachKeyPairsRequest, opts ...grpc.CallOption) (*pb.AttachKeyPairsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -469,14 +469,14 @@ func (m *MockClient) AttachKeyPairs(ctx context.Context, in *pb.AttachKeyPairsRe return ret0, ret1 } -// AttachKeyPairs indicates an expected call of AttachKeyPairs +// AttachKeyPairs indicates an expected call of AttachKeyPairs. func (mr *MockClientMockRecorder) AttachKeyPairs(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AttachKeyPairs", reflect.TypeOf((*MockClient)(nil).AttachKeyPairs), varargs...) } -// DetachKeyPairs mocks base method +// DetachKeyPairs mocks base method. func (m *MockClient) DetachKeyPairs(ctx context.Context, in *pb.DetachKeyPairsRequest, opts ...grpc.CallOption) (*pb.DetachKeyPairsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -489,14 +489,14 @@ func (m *MockClient) DetachKeyPairs(ctx context.Context, in *pb.DetachKeyPairsRe return ret0, ret1 } -// DetachKeyPairs indicates an expected call of DetachKeyPairs +// DetachKeyPairs indicates an expected call of DetachKeyPairs. func (mr *MockClientMockRecorder) DetachKeyPairs(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DetachKeyPairs", reflect.TypeOf((*MockClient)(nil).DetachKeyPairs), varargs...) } -// DescribeSubnets mocks base method +// DescribeSubnets mocks base method. func (m *MockClient) DescribeSubnets(ctx context.Context, in *pb.DescribeSubnetsRequest, opts ...grpc.CallOption) (*pb.DescribeSubnetsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -509,14 +509,14 @@ func (m *MockClient) DescribeSubnets(ctx context.Context, in *pb.DescribeSubnets return ret0, ret1 } -// DescribeSubnets indicates an expected call of DescribeSubnets +// DescribeSubnets indicates an expected call of DescribeSubnets. func (mr *MockClientMockRecorder) DescribeSubnets(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeSubnets", reflect.TypeOf((*MockClient)(nil).DescribeSubnets), varargs...) } -// CreateCluster mocks base method +// CreateCluster mocks base method. func (m *MockClient) CreateCluster(ctx context.Context, in *pb.CreateClusterRequest, opts ...grpc.CallOption) (*pb.CreateClusterResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -529,14 +529,14 @@ func (m *MockClient) CreateCluster(ctx context.Context, in *pb.CreateClusterRequ return ret0, ret1 } -// CreateCluster indicates an expected call of CreateCluster +// CreateCluster indicates an expected call of CreateCluster. func (mr *MockClientMockRecorder) CreateCluster(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateCluster", reflect.TypeOf((*MockClient)(nil).CreateCluster), varargs...) } -// CreateDebugCluster mocks base method +// CreateDebugCluster mocks base method. func (m *MockClient) CreateDebugCluster(ctx context.Context, in *pb.CreateClusterRequest, opts ...grpc.CallOption) (*pb.CreateClusterResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -549,14 +549,14 @@ func (m *MockClient) CreateDebugCluster(ctx context.Context, in *pb.CreateCluste return ret0, ret1 } -// CreateDebugCluster indicates an expected call of CreateDebugCluster +// CreateDebugCluster indicates an expected call of CreateDebugCluster. func (mr *MockClientMockRecorder) CreateDebugCluster(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateDebugCluster", reflect.TypeOf((*MockClient)(nil).CreateDebugCluster), varargs...) } -// ModifyCluster mocks base method +// ModifyCluster mocks base method. func (m *MockClient) ModifyCluster(ctx context.Context, in *pb.ModifyClusterRequest, opts ...grpc.CallOption) (*pb.ModifyClusterResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -569,14 +569,14 @@ func (m *MockClient) ModifyCluster(ctx context.Context, in *pb.ModifyClusterRequ return ret0, ret1 } -// ModifyCluster indicates an expected call of ModifyCluster +// ModifyCluster indicates an expected call of ModifyCluster. func (mr *MockClientMockRecorder) ModifyCluster(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ModifyCluster", reflect.TypeOf((*MockClient)(nil).ModifyCluster), varargs...) } -// ModifyClusterNode mocks base method +// ModifyClusterNode mocks base method. func (m *MockClient) ModifyClusterNode(ctx context.Context, in *pb.ModifyClusterNodeRequest, opts ...grpc.CallOption) (*pb.ModifyClusterNodeResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -589,14 +589,14 @@ func (m *MockClient) ModifyClusterNode(ctx context.Context, in *pb.ModifyCluster return ret0, ret1 } -// ModifyClusterNode indicates an expected call of ModifyClusterNode +// ModifyClusterNode indicates an expected call of ModifyClusterNode. func (mr *MockClientMockRecorder) ModifyClusterNode(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ModifyClusterNode", reflect.TypeOf((*MockClient)(nil).ModifyClusterNode), varargs...) } -// ModifyClusterAttributes mocks base method +// ModifyClusterAttributes mocks base method. func (m *MockClient) ModifyClusterAttributes(ctx context.Context, in *pb.ModifyClusterAttributesRequest, opts ...grpc.CallOption) (*pb.ModifyClusterAttributesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -609,14 +609,14 @@ func (m *MockClient) ModifyClusterAttributes(ctx context.Context, in *pb.ModifyC return ret0, ret1 } -// ModifyClusterAttributes indicates an expected call of ModifyClusterAttributes +// ModifyClusterAttributes indicates an expected call of ModifyClusterAttributes. func (mr *MockClientMockRecorder) ModifyClusterAttributes(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ModifyClusterAttributes", reflect.TypeOf((*MockClient)(nil).ModifyClusterAttributes), varargs...) } -// ModifyClusterNodeAttributes mocks base method +// ModifyClusterNodeAttributes mocks base method. func (m *MockClient) ModifyClusterNodeAttributes(ctx context.Context, in *pb.ModifyClusterNodeAttributesRequest, opts ...grpc.CallOption) (*pb.ModifyClusterNodeAttributesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -629,14 +629,14 @@ func (m *MockClient) ModifyClusterNodeAttributes(ctx context.Context, in *pb.Mod return ret0, ret1 } -// ModifyClusterNodeAttributes indicates an expected call of ModifyClusterNodeAttributes +// ModifyClusterNodeAttributes indicates an expected call of ModifyClusterNodeAttributes. func (mr *MockClientMockRecorder) ModifyClusterNodeAttributes(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ModifyClusterNodeAttributes", reflect.TypeOf((*MockClient)(nil).ModifyClusterNodeAttributes), varargs...) } -// AddTableClusterNodes mocks base method +// AddTableClusterNodes mocks base method. func (m *MockClient) AddTableClusterNodes(ctx context.Context, in *pb.AddTableClusterNodesRequest, opts ...grpc.CallOption) (*empty.Empty, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -649,14 +649,14 @@ func (m *MockClient) AddTableClusterNodes(ctx context.Context, in *pb.AddTableCl return ret0, ret1 } -// AddTableClusterNodes indicates an expected call of AddTableClusterNodes +// AddTableClusterNodes indicates an expected call of AddTableClusterNodes. func (mr *MockClientMockRecorder) AddTableClusterNodes(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddTableClusterNodes", reflect.TypeOf((*MockClient)(nil).AddTableClusterNodes), varargs...) } -// DeleteTableClusterNodes mocks base method +// DeleteTableClusterNodes mocks base method. func (m *MockClient) DeleteTableClusterNodes(ctx context.Context, in *pb.DeleteTableClusterNodesRequest, opts ...grpc.CallOption) (*empty.Empty, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -669,14 +669,14 @@ func (m *MockClient) DeleteTableClusterNodes(ctx context.Context, in *pb.DeleteT return ret0, ret1 } -// DeleteTableClusterNodes indicates an expected call of DeleteTableClusterNodes +// DeleteTableClusterNodes indicates an expected call of DeleteTableClusterNodes. func (mr *MockClientMockRecorder) DeleteTableClusterNodes(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteTableClusterNodes", reflect.TypeOf((*MockClient)(nil).DeleteTableClusterNodes), varargs...) } -// DeleteClusters mocks base method +// DeleteClusters mocks base method. func (m *MockClient) DeleteClusters(ctx context.Context, in *pb.DeleteClustersRequest, opts ...grpc.CallOption) (*pb.DeleteClustersResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -689,14 +689,14 @@ func (m *MockClient) DeleteClusters(ctx context.Context, in *pb.DeleteClustersRe return ret0, ret1 } -// DeleteClusters indicates an expected call of DeleteClusters +// DeleteClusters indicates an expected call of DeleteClusters. func (mr *MockClientMockRecorder) DeleteClusters(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteClusters", reflect.TypeOf((*MockClient)(nil).DeleteClusters), varargs...) } -// UpgradeCluster mocks base method +// UpgradeCluster mocks base method. func (m *MockClient) UpgradeCluster(ctx context.Context, in *pb.UpgradeClusterRequest, opts ...grpc.CallOption) (*pb.UpgradeClusterResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -709,14 +709,14 @@ func (m *MockClient) UpgradeCluster(ctx context.Context, in *pb.UpgradeClusterRe return ret0, ret1 } -// UpgradeCluster indicates an expected call of UpgradeCluster +// UpgradeCluster indicates an expected call of UpgradeCluster. func (mr *MockClientMockRecorder) UpgradeCluster(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpgradeCluster", reflect.TypeOf((*MockClient)(nil).UpgradeCluster), varargs...) } -// RollbackCluster mocks base method +// RollbackCluster mocks base method. func (m *MockClient) RollbackCluster(ctx context.Context, in *pb.RollbackClusterRequest, opts ...grpc.CallOption) (*pb.RollbackClusterResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -729,14 +729,14 @@ func (m *MockClient) RollbackCluster(ctx context.Context, in *pb.RollbackCluster return ret0, ret1 } -// RollbackCluster indicates an expected call of RollbackCluster +// RollbackCluster indicates an expected call of RollbackCluster. func (mr *MockClientMockRecorder) RollbackCluster(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RollbackCluster", reflect.TypeOf((*MockClient)(nil).RollbackCluster), varargs...) } -// ResizeCluster mocks base method +// ResizeCluster mocks base method. func (m *MockClient) ResizeCluster(ctx context.Context, in *pb.ResizeClusterRequest, opts ...grpc.CallOption) (*pb.ResizeClusterResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -749,14 +749,14 @@ func (m *MockClient) ResizeCluster(ctx context.Context, in *pb.ResizeClusterRequ return ret0, ret1 } -// ResizeCluster indicates an expected call of ResizeCluster +// ResizeCluster indicates an expected call of ResizeCluster. func (mr *MockClientMockRecorder) ResizeCluster(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ResizeCluster", reflect.TypeOf((*MockClient)(nil).ResizeCluster), varargs...) } -// AddClusterNodes mocks base method +// AddClusterNodes mocks base method. func (m *MockClient) AddClusterNodes(ctx context.Context, in *pb.AddClusterNodesRequest, opts ...grpc.CallOption) (*pb.AddClusterNodesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -769,14 +769,14 @@ func (m *MockClient) AddClusterNodes(ctx context.Context, in *pb.AddClusterNodes return ret0, ret1 } -// AddClusterNodes indicates an expected call of AddClusterNodes +// AddClusterNodes indicates an expected call of AddClusterNodes. func (mr *MockClientMockRecorder) AddClusterNodes(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddClusterNodes", reflect.TypeOf((*MockClient)(nil).AddClusterNodes), varargs...) } -// DeleteClusterNodes mocks base method +// DeleteClusterNodes mocks base method. func (m *MockClient) DeleteClusterNodes(ctx context.Context, in *pb.DeleteClusterNodesRequest, opts ...grpc.CallOption) (*pb.DeleteClusterNodesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -789,14 +789,14 @@ func (m *MockClient) DeleteClusterNodes(ctx context.Context, in *pb.DeleteCluste return ret0, ret1 } -// DeleteClusterNodes indicates an expected call of DeleteClusterNodes +// DeleteClusterNodes indicates an expected call of DeleteClusterNodes. func (mr *MockClientMockRecorder) DeleteClusterNodes(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteClusterNodes", reflect.TypeOf((*MockClient)(nil).DeleteClusterNodes), varargs...) } -// UpdateClusterEnv mocks base method +// UpdateClusterEnv mocks base method. func (m *MockClient) UpdateClusterEnv(ctx context.Context, in *pb.UpdateClusterEnvRequest, opts ...grpc.CallOption) (*pb.UpdateClusterEnvResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -809,14 +809,14 @@ func (m *MockClient) UpdateClusterEnv(ctx context.Context, in *pb.UpdateClusterE return ret0, ret1 } -// UpdateClusterEnv indicates an expected call of UpdateClusterEnv +// UpdateClusterEnv indicates an expected call of UpdateClusterEnv. func (mr *MockClientMockRecorder) UpdateClusterEnv(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdateClusterEnv", reflect.TypeOf((*MockClient)(nil).UpdateClusterEnv), varargs...) } -// DescribeClusters mocks base method +// DescribeClusters mocks base method. func (m *MockClient) DescribeClusters(ctx context.Context, in *pb.DescribeClustersRequest, opts ...grpc.CallOption) (*pb.DescribeClustersResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -829,14 +829,14 @@ func (m *MockClient) DescribeClusters(ctx context.Context, in *pb.DescribeCluste return ret0, ret1 } -// DescribeClusters indicates an expected call of DescribeClusters +// DescribeClusters indicates an expected call of DescribeClusters. func (mr *MockClientMockRecorder) DescribeClusters(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeClusters", reflect.TypeOf((*MockClient)(nil).DescribeClusters), varargs...) } -// DescribeDebugClusters mocks base method +// DescribeDebugClusters mocks base method. func (m *MockClient) DescribeDebugClusters(ctx context.Context, in *pb.DescribeClustersRequest, opts ...grpc.CallOption) (*pb.DescribeClustersResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -849,14 +849,14 @@ func (m *MockClient) DescribeDebugClusters(ctx context.Context, in *pb.DescribeC return ret0, ret1 } -// DescribeDebugClusters indicates an expected call of DescribeDebugClusters +// DescribeDebugClusters indicates an expected call of DescribeDebugClusters. func (mr *MockClientMockRecorder) DescribeDebugClusters(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeDebugClusters", reflect.TypeOf((*MockClient)(nil).DescribeDebugClusters), varargs...) } -// DescribeAppClusters mocks base method +// DescribeAppClusters mocks base method. func (m *MockClient) DescribeAppClusters(ctx context.Context, in *pb.DescribeAppClustersRequest, opts ...grpc.CallOption) (*pb.DescribeAppClustersResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -869,14 +869,14 @@ func (m *MockClient) DescribeAppClusters(ctx context.Context, in *pb.DescribeApp return ret0, ret1 } -// DescribeAppClusters indicates an expected call of DescribeAppClusters +// DescribeAppClusters indicates an expected call of DescribeAppClusters. func (mr *MockClientMockRecorder) DescribeAppClusters(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeAppClusters", reflect.TypeOf((*MockClient)(nil).DescribeAppClusters), varargs...) } -// DescribeDebugAppClusters mocks base method +// DescribeDebugAppClusters mocks base method. func (m *MockClient) DescribeDebugAppClusters(ctx context.Context, in *pb.DescribeAppClustersRequest, opts ...grpc.CallOption) (*pb.DescribeAppClustersResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -889,14 +889,14 @@ func (m *MockClient) DescribeDebugAppClusters(ctx context.Context, in *pb.Descri return ret0, ret1 } -// DescribeDebugAppClusters indicates an expected call of DescribeDebugAppClusters +// DescribeDebugAppClusters indicates an expected call of DescribeDebugAppClusters. func (mr *MockClientMockRecorder) DescribeDebugAppClusters(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeDebugAppClusters", reflect.TypeOf((*MockClient)(nil).DescribeDebugAppClusters), varargs...) } -// DescribeClusterNodes mocks base method +// DescribeClusterNodes mocks base method. func (m *MockClient) DescribeClusterNodes(ctx context.Context, in *pb.DescribeClusterNodesRequest, opts ...grpc.CallOption) (*pb.DescribeClusterNodesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -909,14 +909,14 @@ func (m *MockClient) DescribeClusterNodes(ctx context.Context, in *pb.DescribeCl return ret0, ret1 } -// DescribeClusterNodes indicates an expected call of DescribeClusterNodes +// DescribeClusterNodes indicates an expected call of DescribeClusterNodes. func (mr *MockClientMockRecorder) DescribeClusterNodes(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeClusterNodes", reflect.TypeOf((*MockClient)(nil).DescribeClusterNodes), varargs...) } -// StopClusters mocks base method +// StopClusters mocks base method. func (m *MockClient) StopClusters(ctx context.Context, in *pb.StopClustersRequest, opts ...grpc.CallOption) (*pb.StopClustersResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -929,14 +929,14 @@ func (m *MockClient) StopClusters(ctx context.Context, in *pb.StopClustersReques return ret0, ret1 } -// StopClusters indicates an expected call of StopClusters +// StopClusters indicates an expected call of StopClusters. func (mr *MockClientMockRecorder) StopClusters(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "StopClusters", reflect.TypeOf((*MockClient)(nil).StopClusters), varargs...) } -// StartClusters mocks base method +// StartClusters mocks base method. func (m *MockClient) StartClusters(ctx context.Context, in *pb.StartClustersRequest, opts ...grpc.CallOption) (*pb.StartClustersResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -949,14 +949,14 @@ func (m *MockClient) StartClusters(ctx context.Context, in *pb.StartClustersRequ return ret0, ret1 } -// StartClusters indicates an expected call of StartClusters +// StartClusters indicates an expected call of StartClusters. func (mr *MockClientMockRecorder) StartClusters(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "StartClusters", reflect.TypeOf((*MockClient)(nil).StartClusters), varargs...) } -// RecoverClusters mocks base method +// RecoverClusters mocks base method. func (m *MockClient) RecoverClusters(ctx context.Context, in *pb.RecoverClustersRequest, opts ...grpc.CallOption) (*pb.RecoverClustersResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -969,14 +969,14 @@ func (m *MockClient) RecoverClusters(ctx context.Context, in *pb.RecoverClusters return ret0, ret1 } -// RecoverClusters indicates an expected call of RecoverClusters +// RecoverClusters indicates an expected call of RecoverClusters. func (mr *MockClientMockRecorder) RecoverClusters(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RecoverClusters", reflect.TypeOf((*MockClient)(nil).RecoverClusters), varargs...) } -// CeaseClusters mocks base method +// CeaseClusters mocks base method. func (m *MockClient) CeaseClusters(ctx context.Context, in *pb.CeaseClustersRequest, opts ...grpc.CallOption) (*pb.CeaseClustersResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -989,14 +989,14 @@ func (m *MockClient) CeaseClusters(ctx context.Context, in *pb.CeaseClustersRequ return ret0, ret1 } -// CeaseClusters indicates an expected call of CeaseClusters +// CeaseClusters indicates an expected call of CeaseClusters. func (mr *MockClientMockRecorder) CeaseClusters(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CeaseClusters", reflect.TypeOf((*MockClient)(nil).CeaseClusters), varargs...) } -// GetClusterStatistics mocks base method +// GetClusterStatistics mocks base method. func (m *MockClient) GetClusterStatistics(ctx context.Context, in *pb.GetClusterStatisticsRequest, opts ...grpc.CallOption) (*pb.GetClusterStatisticsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1009,14 +1009,54 @@ func (m *MockClient) GetClusterStatistics(ctx context.Context, in *pb.GetCluster return ret0, ret1 } -// GetClusterStatistics indicates an expected call of GetClusterStatistics +// GetClusterStatistics indicates an expected call of GetClusterStatistics. func (mr *MockClientMockRecorder) GetClusterStatistics(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetClusterStatistics", reflect.TypeOf((*MockClient)(nil).GetClusterStatistics), varargs...) } -// SyncRepo mocks base method +// DeleteClusterInRuntime mocks base method. +func (m *MockClient) DeleteClusterInRuntime(ctx context.Context, in *pb.DeleteClusterInRuntimeRequest, opts ...grpc.CallOption) (*pb.DeleteClusterInRuntimeResponse, error) { + m.ctrl.T.Helper() + varargs := []interface{}{ctx, in} + for _, a := range opts { + varargs = append(varargs, a) + } + ret := m.ctrl.Call(m, "DeleteClusterInRuntime", varargs...) + ret0, _ := ret[0].(*pb.DeleteClusterInRuntimeResponse) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +// DeleteClusterInRuntime indicates an expected call of DeleteClusterInRuntime. +func (mr *MockClientMockRecorder) DeleteClusterInRuntime(ctx, in interface{}, opts ...interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + varargs := append([]interface{}{ctx, in}, opts...) + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteClusterInRuntime", reflect.TypeOf((*MockClient)(nil).DeleteClusterInRuntime), varargs...) +} + +// MigrateClusterInRuntime mocks base method. +func (m *MockClient) MigrateClusterInRuntime(ctx context.Context, in *pb.MigrateClusterInRuntimeRequest, opts ...grpc.CallOption) (*pb.MigrateClusterInRuntimeResponse, error) { + m.ctrl.T.Helper() + varargs := []interface{}{ctx, in} + for _, a := range opts { + varargs = append(varargs, a) + } + ret := m.ctrl.Call(m, "MigrateClusterInRuntime", varargs...) + ret0, _ := ret[0].(*pb.MigrateClusterInRuntimeResponse) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +// MigrateClusterInRuntime indicates an expected call of MigrateClusterInRuntime. +func (mr *MockClientMockRecorder) MigrateClusterInRuntime(ctx, in interface{}, opts ...interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + varargs := append([]interface{}{ctx, in}, opts...) + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "MigrateClusterInRuntime", reflect.TypeOf((*MockClient)(nil).MigrateClusterInRuntime), varargs...) +} + +// SyncRepo mocks base method. func (m *MockClient) SyncRepo(ctx context.Context, in *pb.SyncRepoRequest, opts ...grpc.CallOption) (*pb.SyncRepoResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1029,14 +1069,14 @@ func (m *MockClient) SyncRepo(ctx context.Context, in *pb.SyncRepoRequest, opts return ret0, ret1 } -// SyncRepo indicates an expected call of SyncRepo +// SyncRepo indicates an expected call of SyncRepo. func (mr *MockClientMockRecorder) SyncRepo(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SyncRepo", reflect.TypeOf((*MockClient)(nil).SyncRepo), varargs...) } -// CreateApp mocks base method +// CreateApp mocks base method. func (m *MockClient) CreateApp(ctx context.Context, in *pb.CreateAppRequest, opts ...grpc.CallOption) (*pb.CreateAppResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1049,14 +1089,14 @@ func (m *MockClient) CreateApp(ctx context.Context, in *pb.CreateAppRequest, opt return ret0, ret1 } -// CreateApp indicates an expected call of CreateApp +// CreateApp indicates an expected call of CreateApp. func (mr *MockClientMockRecorder) CreateApp(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateApp", reflect.TypeOf((*MockClient)(nil).CreateApp), varargs...) } -// ValidatePackage mocks base method +// ValidatePackage mocks base method. func (m *MockClient) ValidatePackage(ctx context.Context, in *pb.ValidatePackageRequest, opts ...grpc.CallOption) (*pb.ValidatePackageResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1069,14 +1109,14 @@ func (m *MockClient) ValidatePackage(ctx context.Context, in *pb.ValidatePackage return ret0, ret1 } -// ValidatePackage indicates an expected call of ValidatePackage +// ValidatePackage indicates an expected call of ValidatePackage. func (mr *MockClientMockRecorder) ValidatePackage(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ValidatePackage", reflect.TypeOf((*MockClient)(nil).ValidatePackage), varargs...) } -// GetAppStatistics mocks base method +// GetAppStatistics mocks base method. func (m *MockClient) GetAppStatistics(ctx context.Context, in *pb.GetAppStatisticsRequest, opts ...grpc.CallOption) (*pb.GetAppStatisticsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1089,14 +1129,14 @@ func (m *MockClient) GetAppStatistics(ctx context.Context, in *pb.GetAppStatisti return ret0, ret1 } -// GetAppStatistics indicates an expected call of GetAppStatistics +// GetAppStatistics indicates an expected call of GetAppStatistics. func (mr *MockClientMockRecorder) GetAppStatistics(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetAppStatistics", reflect.TypeOf((*MockClient)(nil).GetAppStatistics), varargs...) } -// DescribeApps mocks base method +// DescribeApps mocks base method. func (m *MockClient) DescribeApps(ctx context.Context, in *pb.DescribeAppsRequest, opts ...grpc.CallOption) (*pb.DescribeAppsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1109,14 +1149,14 @@ func (m *MockClient) DescribeApps(ctx context.Context, in *pb.DescribeAppsReques return ret0, ret1 } -// DescribeApps indicates an expected call of DescribeApps +// DescribeApps indicates an expected call of DescribeApps. func (mr *MockClientMockRecorder) DescribeApps(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeApps", reflect.TypeOf((*MockClient)(nil).DescribeApps), varargs...) } -// DescribeActiveApps mocks base method +// DescribeActiveApps mocks base method. func (m *MockClient) DescribeActiveApps(ctx context.Context, in *pb.DescribeAppsRequest, opts ...grpc.CallOption) (*pb.DescribeAppsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1129,14 +1169,14 @@ func (m *MockClient) DescribeActiveApps(ctx context.Context, in *pb.DescribeApps return ret0, ret1 } -// DescribeActiveApps indicates an expected call of DescribeActiveApps +// DescribeActiveApps indicates an expected call of DescribeActiveApps. func (mr *MockClientMockRecorder) DescribeActiveApps(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeActiveApps", reflect.TypeOf((*MockClient)(nil).DescribeActiveApps), varargs...) } -// ModifyApp mocks base method +// ModifyApp mocks base method. func (m *MockClient) ModifyApp(ctx context.Context, in *pb.ModifyAppRequest, opts ...grpc.CallOption) (*pb.ModifyAppResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1149,14 +1189,14 @@ func (m *MockClient) ModifyApp(ctx context.Context, in *pb.ModifyAppRequest, opt return ret0, ret1 } -// ModifyApp indicates an expected call of ModifyApp +// ModifyApp indicates an expected call of ModifyApp. func (mr *MockClientMockRecorder) ModifyApp(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ModifyApp", reflect.TypeOf((*MockClient)(nil).ModifyApp), varargs...) } -// UploadAppAttachment mocks base method +// UploadAppAttachment mocks base method. func (m *MockClient) UploadAppAttachment(ctx context.Context, in *pb.UploadAppAttachmentRequest, opts ...grpc.CallOption) (*pb.UploadAppAttachmentResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1169,14 +1209,14 @@ func (m *MockClient) UploadAppAttachment(ctx context.Context, in *pb.UploadAppAt return ret0, ret1 } -// UploadAppAttachment indicates an expected call of UploadAppAttachment +// UploadAppAttachment indicates an expected call of UploadAppAttachment. func (mr *MockClientMockRecorder) UploadAppAttachment(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UploadAppAttachment", reflect.TypeOf((*MockClient)(nil).UploadAppAttachment), varargs...) } -// DeleteApps mocks base method +// DeleteApps mocks base method. func (m *MockClient) DeleteApps(ctx context.Context, in *pb.DeleteAppsRequest, opts ...grpc.CallOption) (*pb.DeleteAppsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1189,14 +1229,14 @@ func (m *MockClient) DeleteApps(ctx context.Context, in *pb.DeleteAppsRequest, o return ret0, ret1 } -// DeleteApps indicates an expected call of DeleteApps +// DeleteApps indicates an expected call of DeleteApps. func (mr *MockClientMockRecorder) DeleteApps(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteApps", reflect.TypeOf((*MockClient)(nil).DeleteApps), varargs...) } -// CreateAppVersion mocks base method +// CreateAppVersion mocks base method. func (m *MockClient) CreateAppVersion(ctx context.Context, in *pb.CreateAppVersionRequest, opts ...grpc.CallOption) (*pb.CreateAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1209,14 +1249,14 @@ func (m *MockClient) CreateAppVersion(ctx context.Context, in *pb.CreateAppVersi return ret0, ret1 } -// CreateAppVersion indicates an expected call of CreateAppVersion +// CreateAppVersion indicates an expected call of CreateAppVersion. func (mr *MockClientMockRecorder) CreateAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateAppVersion", reflect.TypeOf((*MockClient)(nil).CreateAppVersion), varargs...) } -// DescribeAppVersions mocks base method +// DescribeAppVersions mocks base method. func (m *MockClient) DescribeAppVersions(ctx context.Context, in *pb.DescribeAppVersionsRequest, opts ...grpc.CallOption) (*pb.DescribeAppVersionsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1229,14 +1269,14 @@ func (m *MockClient) DescribeAppVersions(ctx context.Context, in *pb.DescribeApp return ret0, ret1 } -// DescribeAppVersions indicates an expected call of DescribeAppVersions +// DescribeAppVersions indicates an expected call of DescribeAppVersions. func (mr *MockClientMockRecorder) DescribeAppVersions(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeAppVersions", reflect.TypeOf((*MockClient)(nil).DescribeAppVersions), varargs...) } -// DescribeActiveAppVersions mocks base method +// DescribeActiveAppVersions mocks base method. func (m *MockClient) DescribeActiveAppVersions(ctx context.Context, in *pb.DescribeAppVersionsRequest, opts ...grpc.CallOption) (*pb.DescribeAppVersionsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1249,14 +1289,14 @@ func (m *MockClient) DescribeActiveAppVersions(ctx context.Context, in *pb.Descr return ret0, ret1 } -// DescribeActiveAppVersions indicates an expected call of DescribeActiveAppVersions +// DescribeActiveAppVersions indicates an expected call of DescribeActiveAppVersions. func (mr *MockClientMockRecorder) DescribeActiveAppVersions(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeActiveAppVersions", reflect.TypeOf((*MockClient)(nil).DescribeActiveAppVersions), varargs...) } -// DescribeAppVersionAudits mocks base method +// DescribeAppVersionAudits mocks base method. func (m *MockClient) DescribeAppVersionAudits(ctx context.Context, in *pb.DescribeAppVersionAuditsRequest, opts ...grpc.CallOption) (*pb.DescribeAppVersionAuditsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1269,14 +1309,14 @@ func (m *MockClient) DescribeAppVersionAudits(ctx context.Context, in *pb.Descri return ret0, ret1 } -// DescribeAppVersionAudits indicates an expected call of DescribeAppVersionAudits +// DescribeAppVersionAudits indicates an expected call of DescribeAppVersionAudits. func (mr *MockClientMockRecorder) DescribeAppVersionAudits(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeAppVersionAudits", reflect.TypeOf((*MockClient)(nil).DescribeAppVersionAudits), varargs...) } -// DescribeAppVersionReviews mocks base method +// DescribeAppVersionReviews mocks base method. func (m *MockClient) DescribeAppVersionReviews(ctx context.Context, in *pb.DescribeAppVersionReviewsRequest, opts ...grpc.CallOption) (*pb.DescribeAppVersionReviewsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1289,14 +1329,14 @@ func (m *MockClient) DescribeAppVersionReviews(ctx context.Context, in *pb.Descr return ret0, ret1 } -// DescribeAppVersionReviews indicates an expected call of DescribeAppVersionReviews +// DescribeAppVersionReviews indicates an expected call of DescribeAppVersionReviews. func (mr *MockClientMockRecorder) DescribeAppVersionReviews(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeAppVersionReviews", reflect.TypeOf((*MockClient)(nil).DescribeAppVersionReviews), varargs...) } -// ModifyAppVersion mocks base method +// ModifyAppVersion mocks base method. func (m *MockClient) ModifyAppVersion(ctx context.Context, in *pb.ModifyAppVersionRequest, opts ...grpc.CallOption) (*pb.ModifyAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1309,14 +1349,14 @@ func (m *MockClient) ModifyAppVersion(ctx context.Context, in *pb.ModifyAppVersi return ret0, ret1 } -// ModifyAppVersion indicates an expected call of ModifyAppVersion +// ModifyAppVersion indicates an expected call of ModifyAppVersion. func (mr *MockClientMockRecorder) ModifyAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ModifyAppVersion", reflect.TypeOf((*MockClient)(nil).ModifyAppVersion), varargs...) } -// GetAppVersionPackage mocks base method +// GetAppVersionPackage mocks base method. func (m *MockClient) GetAppVersionPackage(ctx context.Context, in *pb.GetAppVersionPackageRequest, opts ...grpc.CallOption) (*pb.GetAppVersionPackageResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1329,14 +1369,14 @@ func (m *MockClient) GetAppVersionPackage(ctx context.Context, in *pb.GetAppVers return ret0, ret1 } -// GetAppVersionPackage indicates an expected call of GetAppVersionPackage +// GetAppVersionPackage indicates an expected call of GetAppVersionPackage. func (mr *MockClientMockRecorder) GetAppVersionPackage(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetAppVersionPackage", reflect.TypeOf((*MockClient)(nil).GetAppVersionPackage), varargs...) } -// GetAppVersionPackageFiles mocks base method +// GetAppVersionPackageFiles mocks base method. func (m *MockClient) GetAppVersionPackageFiles(ctx context.Context, in *pb.GetAppVersionPackageFilesRequest, opts ...grpc.CallOption) (*pb.GetAppVersionPackageFilesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1349,14 +1389,14 @@ func (m *MockClient) GetAppVersionPackageFiles(ctx context.Context, in *pb.GetAp return ret0, ret1 } -// GetAppVersionPackageFiles indicates an expected call of GetAppVersionPackageFiles +// GetAppVersionPackageFiles indicates an expected call of GetAppVersionPackageFiles. func (mr *MockClientMockRecorder) GetAppVersionPackageFiles(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetAppVersionPackageFiles", reflect.TypeOf((*MockClient)(nil).GetAppVersionPackageFiles), varargs...) } -// SubmitAppVersion mocks base method +// SubmitAppVersion mocks base method. func (m *MockClient) SubmitAppVersion(ctx context.Context, in *pb.SubmitAppVersionRequest, opts ...grpc.CallOption) (*pb.SubmitAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1369,14 +1409,14 @@ func (m *MockClient) SubmitAppVersion(ctx context.Context, in *pb.SubmitAppVersi return ret0, ret1 } -// SubmitAppVersion indicates an expected call of SubmitAppVersion +// SubmitAppVersion indicates an expected call of SubmitAppVersion. func (mr *MockClientMockRecorder) SubmitAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SubmitAppVersion", reflect.TypeOf((*MockClient)(nil).SubmitAppVersion), varargs...) } -// CancelAppVersion mocks base method +// CancelAppVersion mocks base method. func (m *MockClient) CancelAppVersion(ctx context.Context, in *pb.CancelAppVersionRequest, opts ...grpc.CallOption) (*pb.CancelAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1389,14 +1429,14 @@ func (m *MockClient) CancelAppVersion(ctx context.Context, in *pb.CancelAppVersi return ret0, ret1 } -// CancelAppVersion indicates an expected call of CancelAppVersion +// CancelAppVersion indicates an expected call of CancelAppVersion. func (mr *MockClientMockRecorder) CancelAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CancelAppVersion", reflect.TypeOf((*MockClient)(nil).CancelAppVersion), varargs...) } -// ReleaseAppVersion mocks base method +// ReleaseAppVersion mocks base method. func (m *MockClient) ReleaseAppVersion(ctx context.Context, in *pb.ReleaseAppVersionRequest, opts ...grpc.CallOption) (*pb.ReleaseAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1409,14 +1449,14 @@ func (m *MockClient) ReleaseAppVersion(ctx context.Context, in *pb.ReleaseAppVer return ret0, ret1 } -// ReleaseAppVersion indicates an expected call of ReleaseAppVersion +// ReleaseAppVersion indicates an expected call of ReleaseAppVersion. func (mr *MockClientMockRecorder) ReleaseAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReleaseAppVersion", reflect.TypeOf((*MockClient)(nil).ReleaseAppVersion), varargs...) } -// DeleteAppVersion mocks base method +// DeleteAppVersion mocks base method. func (m *MockClient) DeleteAppVersion(ctx context.Context, in *pb.DeleteAppVersionRequest, opts ...grpc.CallOption) (*pb.DeleteAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1429,14 +1469,14 @@ func (m *MockClient) DeleteAppVersion(ctx context.Context, in *pb.DeleteAppVersi return ret0, ret1 } -// DeleteAppVersion indicates an expected call of DeleteAppVersion +// DeleteAppVersion indicates an expected call of DeleteAppVersion. func (mr *MockClientMockRecorder) DeleteAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteAppVersion", reflect.TypeOf((*MockClient)(nil).DeleteAppVersion), varargs...) } -// IsvReviewAppVersion mocks base method +// IsvReviewAppVersion mocks base method. func (m *MockClient) IsvReviewAppVersion(ctx context.Context, in *pb.ReviewAppVersionRequest, opts ...grpc.CallOption) (*pb.ReviewAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1449,14 +1489,14 @@ func (m *MockClient) IsvReviewAppVersion(ctx context.Context, in *pb.ReviewAppVe return ret0, ret1 } -// IsvReviewAppVersion indicates an expected call of IsvReviewAppVersion +// IsvReviewAppVersion indicates an expected call of IsvReviewAppVersion. func (mr *MockClientMockRecorder) IsvReviewAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IsvReviewAppVersion", reflect.TypeOf((*MockClient)(nil).IsvReviewAppVersion), varargs...) } -// IsvPassAppVersion mocks base method +// IsvPassAppVersion mocks base method. func (m *MockClient) IsvPassAppVersion(ctx context.Context, in *pb.PassAppVersionRequest, opts ...grpc.CallOption) (*pb.PassAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1469,14 +1509,14 @@ func (m *MockClient) IsvPassAppVersion(ctx context.Context, in *pb.PassAppVersio return ret0, ret1 } -// IsvPassAppVersion indicates an expected call of IsvPassAppVersion +// IsvPassAppVersion indicates an expected call of IsvPassAppVersion. func (mr *MockClientMockRecorder) IsvPassAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IsvPassAppVersion", reflect.TypeOf((*MockClient)(nil).IsvPassAppVersion), varargs...) } -// IsvRejectAppVersion mocks base method +// IsvRejectAppVersion mocks base method. func (m *MockClient) IsvRejectAppVersion(ctx context.Context, in *pb.RejectAppVersionRequest, opts ...grpc.CallOption) (*pb.RejectAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1489,14 +1529,14 @@ func (m *MockClient) IsvRejectAppVersion(ctx context.Context, in *pb.RejectAppVe return ret0, ret1 } -// IsvRejectAppVersion indicates an expected call of IsvRejectAppVersion +// IsvRejectAppVersion indicates an expected call of IsvRejectAppVersion. func (mr *MockClientMockRecorder) IsvRejectAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IsvRejectAppVersion", reflect.TypeOf((*MockClient)(nil).IsvRejectAppVersion), varargs...) } -// BusinessReviewAppVersion mocks base method +// BusinessReviewAppVersion mocks base method. func (m *MockClient) BusinessReviewAppVersion(ctx context.Context, in *pb.ReviewAppVersionRequest, opts ...grpc.CallOption) (*pb.ReviewAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1509,14 +1549,14 @@ func (m *MockClient) BusinessReviewAppVersion(ctx context.Context, in *pb.Review return ret0, ret1 } -// BusinessReviewAppVersion indicates an expected call of BusinessReviewAppVersion +// BusinessReviewAppVersion indicates an expected call of BusinessReviewAppVersion. func (mr *MockClientMockRecorder) BusinessReviewAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BusinessReviewAppVersion", reflect.TypeOf((*MockClient)(nil).BusinessReviewAppVersion), varargs...) } -// BusinessPassAppVersion mocks base method +// BusinessPassAppVersion mocks base method. func (m *MockClient) BusinessPassAppVersion(ctx context.Context, in *pb.PassAppVersionRequest, opts ...grpc.CallOption) (*pb.PassAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1529,14 +1569,14 @@ func (m *MockClient) BusinessPassAppVersion(ctx context.Context, in *pb.PassAppV return ret0, ret1 } -// BusinessPassAppVersion indicates an expected call of BusinessPassAppVersion +// BusinessPassAppVersion indicates an expected call of BusinessPassAppVersion. func (mr *MockClientMockRecorder) BusinessPassAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BusinessPassAppVersion", reflect.TypeOf((*MockClient)(nil).BusinessPassAppVersion), varargs...) } -// BusinessRejectAppVersion mocks base method +// BusinessRejectAppVersion mocks base method. func (m *MockClient) BusinessRejectAppVersion(ctx context.Context, in *pb.RejectAppVersionRequest, opts ...grpc.CallOption) (*pb.RejectAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1549,14 +1589,14 @@ func (m *MockClient) BusinessRejectAppVersion(ctx context.Context, in *pb.Reject return ret0, ret1 } -// BusinessRejectAppVersion indicates an expected call of BusinessRejectAppVersion +// BusinessRejectAppVersion indicates an expected call of BusinessRejectAppVersion. func (mr *MockClientMockRecorder) BusinessRejectAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BusinessRejectAppVersion", reflect.TypeOf((*MockClient)(nil).BusinessRejectAppVersion), varargs...) } -// TechnicalReviewAppVersion mocks base method +// TechnicalReviewAppVersion mocks base method. func (m *MockClient) TechnicalReviewAppVersion(ctx context.Context, in *pb.ReviewAppVersionRequest, opts ...grpc.CallOption) (*pb.ReviewAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1569,14 +1609,14 @@ func (m *MockClient) TechnicalReviewAppVersion(ctx context.Context, in *pb.Revie return ret0, ret1 } -// TechnicalReviewAppVersion indicates an expected call of TechnicalReviewAppVersion +// TechnicalReviewAppVersion indicates an expected call of TechnicalReviewAppVersion. func (mr *MockClientMockRecorder) TechnicalReviewAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "TechnicalReviewAppVersion", reflect.TypeOf((*MockClient)(nil).TechnicalReviewAppVersion), varargs...) } -// TechnicalPassAppVersion mocks base method +// TechnicalPassAppVersion mocks base method. func (m *MockClient) TechnicalPassAppVersion(ctx context.Context, in *pb.PassAppVersionRequest, opts ...grpc.CallOption) (*pb.PassAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1589,14 +1629,14 @@ func (m *MockClient) TechnicalPassAppVersion(ctx context.Context, in *pb.PassApp return ret0, ret1 } -// TechnicalPassAppVersion indicates an expected call of TechnicalPassAppVersion +// TechnicalPassAppVersion indicates an expected call of TechnicalPassAppVersion. func (mr *MockClientMockRecorder) TechnicalPassAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "TechnicalPassAppVersion", reflect.TypeOf((*MockClient)(nil).TechnicalPassAppVersion), varargs...) } -// TechnicalRejectAppVersion mocks base method +// TechnicalRejectAppVersion mocks base method. func (m *MockClient) TechnicalRejectAppVersion(ctx context.Context, in *pb.RejectAppVersionRequest, opts ...grpc.CallOption) (*pb.RejectAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1609,14 +1649,14 @@ func (m *MockClient) TechnicalRejectAppVersion(ctx context.Context, in *pb.Rejec return ret0, ret1 } -// TechnicalRejectAppVersion indicates an expected call of TechnicalRejectAppVersion +// TechnicalRejectAppVersion indicates an expected call of TechnicalRejectAppVersion. func (mr *MockClientMockRecorder) TechnicalRejectAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "TechnicalRejectAppVersion", reflect.TypeOf((*MockClient)(nil).TechnicalRejectAppVersion), varargs...) } -// AdminPassAppVersion mocks base method +// AdminPassAppVersion mocks base method. func (m *MockClient) AdminPassAppVersion(ctx context.Context, in *pb.PassAppVersionRequest, opts ...grpc.CallOption) (*pb.PassAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1629,14 +1669,14 @@ func (m *MockClient) AdminPassAppVersion(ctx context.Context, in *pb.PassAppVers return ret0, ret1 } -// AdminPassAppVersion indicates an expected call of AdminPassAppVersion +// AdminPassAppVersion indicates an expected call of AdminPassAppVersion. func (mr *MockClientMockRecorder) AdminPassAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AdminPassAppVersion", reflect.TypeOf((*MockClient)(nil).AdminPassAppVersion), varargs...) } -// AdminRejectAppVersion mocks base method +// AdminRejectAppVersion mocks base method. func (m *MockClient) AdminRejectAppVersion(ctx context.Context, in *pb.RejectAppVersionRequest, opts ...grpc.CallOption) (*pb.RejectAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1649,14 +1689,14 @@ func (m *MockClient) AdminRejectAppVersion(ctx context.Context, in *pb.RejectApp return ret0, ret1 } -// AdminRejectAppVersion indicates an expected call of AdminRejectAppVersion +// AdminRejectAppVersion indicates an expected call of AdminRejectAppVersion. func (mr *MockClientMockRecorder) AdminRejectAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AdminRejectAppVersion", reflect.TypeOf((*MockClient)(nil).AdminRejectAppVersion), varargs...) } -// SuspendAppVersion mocks base method +// SuspendAppVersion mocks base method. func (m *MockClient) SuspendAppVersion(ctx context.Context, in *pb.SuspendAppVersionRequest, opts ...grpc.CallOption) (*pb.SuspendAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1669,14 +1709,14 @@ func (m *MockClient) SuspendAppVersion(ctx context.Context, in *pb.SuspendAppVer return ret0, ret1 } -// SuspendAppVersion indicates an expected call of SuspendAppVersion +// SuspendAppVersion indicates an expected call of SuspendAppVersion. func (mr *MockClientMockRecorder) SuspendAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SuspendAppVersion", reflect.TypeOf((*MockClient)(nil).SuspendAppVersion), varargs...) } -// RecoverAppVersion mocks base method +// RecoverAppVersion mocks base method. func (m *MockClient) RecoverAppVersion(ctx context.Context, in *pb.RecoverAppVersionRequest, opts ...grpc.CallOption) (*pb.RecoverAppVersionResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1689,14 +1729,14 @@ func (m *MockClient) RecoverAppVersion(ctx context.Context, in *pb.RecoverAppVer return ret0, ret1 } -// RecoverAppVersion indicates an expected call of RecoverAppVersion +// RecoverAppVersion indicates an expected call of RecoverAppVersion. func (mr *MockClientMockRecorder) RecoverAppVersion(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RecoverAppVersion", reflect.TypeOf((*MockClient)(nil).RecoverAppVersion), varargs...) } -// CreateRepo mocks base method +// CreateRepo mocks base method. func (m *MockClient) CreateRepo(ctx context.Context, in *pb.CreateRepoRequest, opts ...grpc.CallOption) (*pb.CreateRepoResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1709,14 +1749,14 @@ func (m *MockClient) CreateRepo(ctx context.Context, in *pb.CreateRepoRequest, o return ret0, ret1 } -// CreateRepo indicates an expected call of CreateRepo +// CreateRepo indicates an expected call of CreateRepo. func (mr *MockClientMockRecorder) CreateRepo(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateRepo", reflect.TypeOf((*MockClient)(nil).CreateRepo), varargs...) } -// DescribeRepos mocks base method +// DescribeRepos mocks base method. func (m *MockClient) DescribeRepos(ctx context.Context, in *pb.DescribeReposRequest, opts ...grpc.CallOption) (*pb.DescribeReposResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1729,14 +1769,14 @@ func (m *MockClient) DescribeRepos(ctx context.Context, in *pb.DescribeReposRequ return ret0, ret1 } -// DescribeRepos indicates an expected call of DescribeRepos +// DescribeRepos indicates an expected call of DescribeRepos. func (mr *MockClientMockRecorder) DescribeRepos(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeRepos", reflect.TypeOf((*MockClient)(nil).DescribeRepos), varargs...) } -// ModifyRepo mocks base method +// ModifyRepo mocks base method. func (m *MockClient) ModifyRepo(ctx context.Context, in *pb.ModifyRepoRequest, opts ...grpc.CallOption) (*pb.ModifyRepoResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1749,14 +1789,14 @@ func (m *MockClient) ModifyRepo(ctx context.Context, in *pb.ModifyRepoRequest, o return ret0, ret1 } -// ModifyRepo indicates an expected call of ModifyRepo +// ModifyRepo indicates an expected call of ModifyRepo. func (mr *MockClientMockRecorder) ModifyRepo(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ModifyRepo", reflect.TypeOf((*MockClient)(nil).ModifyRepo), varargs...) } -// DeleteRepos mocks base method +// DeleteRepos mocks base method. func (m *MockClient) DeleteRepos(ctx context.Context, in *pb.DeleteReposRequest, opts ...grpc.CallOption) (*pb.DeleteReposResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1769,14 +1809,14 @@ func (m *MockClient) DeleteRepos(ctx context.Context, in *pb.DeleteReposRequest, return ret0, ret1 } -// DeleteRepos indicates an expected call of DeleteRepos +// DeleteRepos indicates an expected call of DeleteRepos. func (mr *MockClientMockRecorder) DeleteRepos(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteRepos", reflect.TypeOf((*MockClient)(nil).DeleteRepos), varargs...) } -// ValidateRepo mocks base method +// ValidateRepo mocks base method. func (m *MockClient) ValidateRepo(ctx context.Context, in *pb.ValidateRepoRequest, opts ...grpc.CallOption) (*pb.ValidateRepoResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1789,14 +1829,14 @@ func (m *MockClient) ValidateRepo(ctx context.Context, in *pb.ValidateRepoReques return ret0, ret1 } -// ValidateRepo indicates an expected call of ValidateRepo +// ValidateRepo indicates an expected call of ValidateRepo. func (mr *MockClientMockRecorder) ValidateRepo(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ValidateRepo", reflect.TypeOf((*MockClient)(nil).ValidateRepo), varargs...) } -// DescribeCategories mocks base method +// DescribeCategories mocks base method. func (m *MockClient) DescribeCategories(ctx context.Context, in *pb.DescribeCategoriesRequest, opts ...grpc.CallOption) (*pb.DescribeCategoriesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1809,14 +1849,14 @@ func (m *MockClient) DescribeCategories(ctx context.Context, in *pb.DescribeCate return ret0, ret1 } -// DescribeCategories indicates an expected call of DescribeCategories +// DescribeCategories indicates an expected call of DescribeCategories. func (mr *MockClientMockRecorder) DescribeCategories(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeCategories", reflect.TypeOf((*MockClient)(nil).DescribeCategories), varargs...) } -// CreateCategory mocks base method +// CreateCategory mocks base method. func (m *MockClient) CreateCategory(ctx context.Context, in *pb.CreateCategoryRequest, opts ...grpc.CallOption) (*pb.CreateCategoryResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1829,14 +1869,14 @@ func (m *MockClient) CreateCategory(ctx context.Context, in *pb.CreateCategoryRe return ret0, ret1 } -// CreateCategory indicates an expected call of CreateCategory +// CreateCategory indicates an expected call of CreateCategory. func (mr *MockClientMockRecorder) CreateCategory(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateCategory", reflect.TypeOf((*MockClient)(nil).CreateCategory), varargs...) } -// ModifyCategory mocks base method +// ModifyCategory mocks base method. func (m *MockClient) ModifyCategory(ctx context.Context, in *pb.ModifyCategoryRequest, opts ...grpc.CallOption) (*pb.ModifyCategoryResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1849,14 +1889,14 @@ func (m *MockClient) ModifyCategory(ctx context.Context, in *pb.ModifyCategoryRe return ret0, ret1 } -// ModifyCategory indicates an expected call of ModifyCategory +// ModifyCategory indicates an expected call of ModifyCategory. func (mr *MockClientMockRecorder) ModifyCategory(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ModifyCategory", reflect.TypeOf((*MockClient)(nil).ModifyCategory), varargs...) } -// DeleteCategories mocks base method +// DeleteCategories mocks base method. func (m *MockClient) DeleteCategories(ctx context.Context, in *pb.DeleteCategoriesRequest, opts ...grpc.CallOption) (*pb.DeleteCategoriesResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1869,14 +1909,14 @@ func (m *MockClient) DeleteCategories(ctx context.Context, in *pb.DeleteCategori return ret0, ret1 } -// DeleteCategories indicates an expected call of DeleteCategories +// DeleteCategories indicates an expected call of DeleteCategories. func (mr *MockClientMockRecorder) DeleteCategories(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteCategories", reflect.TypeOf((*MockClient)(nil).DeleteCategories), varargs...) } -// CreateAttachment mocks base method +// CreateAttachment mocks base method. func (m *MockClient) CreateAttachment(ctx context.Context, in *pb.CreateAttachmentRequest, opts ...grpc.CallOption) (*pb.CreateAttachmentResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1889,14 +1929,14 @@ func (m *MockClient) CreateAttachment(ctx context.Context, in *pb.CreateAttachme return ret0, ret1 } -// CreateAttachment indicates an expected call of CreateAttachment +// CreateAttachment indicates an expected call of CreateAttachment. func (mr *MockClientMockRecorder) CreateAttachment(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateAttachment", reflect.TypeOf((*MockClient)(nil).CreateAttachment), varargs...) } -// AppendAttachment mocks base method +// AppendAttachment mocks base method. func (m *MockClient) AppendAttachment(ctx context.Context, in *pb.AppendAttachmentRequest, opts ...grpc.CallOption) (*pb.AppendAttachmentResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1909,14 +1949,14 @@ func (m *MockClient) AppendAttachment(ctx context.Context, in *pb.AppendAttachme return ret0, ret1 } -// AppendAttachment indicates an expected call of AppendAttachment +// AppendAttachment indicates an expected call of AppendAttachment. func (mr *MockClientMockRecorder) AppendAttachment(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AppendAttachment", reflect.TypeOf((*MockClient)(nil).AppendAttachment), varargs...) } -// ReplaceAttachment mocks base method +// ReplaceAttachment mocks base method. func (m *MockClient) ReplaceAttachment(ctx context.Context, in *pb.ReplaceAttachmentRequest, opts ...grpc.CallOption) (*pb.ReplaceAttachmentResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1929,14 +1969,14 @@ func (m *MockClient) ReplaceAttachment(ctx context.Context, in *pb.ReplaceAttach return ret0, ret1 } -// ReplaceAttachment indicates an expected call of ReplaceAttachment +// ReplaceAttachment indicates an expected call of ReplaceAttachment. func (mr *MockClientMockRecorder) ReplaceAttachment(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReplaceAttachment", reflect.TypeOf((*MockClient)(nil).ReplaceAttachment), varargs...) } -// GetAttachments mocks base method +// GetAttachments mocks base method. func (m *MockClient) GetAttachments(ctx context.Context, in *pb.GetAttachmentsRequest, opts ...grpc.CallOption) (*pb.GetAttachmentsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1949,14 +1989,14 @@ func (m *MockClient) GetAttachments(ctx context.Context, in *pb.GetAttachmentsRe return ret0, ret1 } -// GetAttachments indicates an expected call of GetAttachments +// GetAttachments indicates an expected call of GetAttachments. func (mr *MockClientMockRecorder) GetAttachments(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetAttachments", reflect.TypeOf((*MockClient)(nil).GetAttachments), varargs...) } -// DeleteAttachments mocks base method +// DeleteAttachments mocks base method. func (m *MockClient) DeleteAttachments(ctx context.Context, in *pb.DeleteAttachmentsRequest, opts ...grpc.CallOption) (*pb.DeleteAttachmentsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1969,14 +2009,14 @@ func (m *MockClient) DeleteAttachments(ctx context.Context, in *pb.DeleteAttachm return ret0, ret1 } -// DeleteAttachments indicates an expected call of DeleteAttachments +// DeleteAttachments indicates an expected call of DeleteAttachments. func (mr *MockClientMockRecorder) DeleteAttachments(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteAttachments", reflect.TypeOf((*MockClient)(nil).DeleteAttachments), varargs...) } -// IndexRepo mocks base method +// IndexRepo mocks base method. func (m *MockClient) IndexRepo(ctx context.Context, in *pb.IndexRepoRequest, opts ...grpc.CallOption) (*pb.IndexRepoResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -1989,14 +2029,14 @@ func (m *MockClient) IndexRepo(ctx context.Context, in *pb.IndexRepoRequest, opt return ret0, ret1 } -// IndexRepo indicates an expected call of IndexRepo +// IndexRepo indicates an expected call of IndexRepo. func (mr *MockClientMockRecorder) IndexRepo(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IndexRepo", reflect.TypeOf((*MockClient)(nil).IndexRepo), varargs...) } -// DescribeRepoEvents mocks base method +// DescribeRepoEvents mocks base method. func (m *MockClient) DescribeRepoEvents(ctx context.Context, in *pb.DescribeRepoEventsRequest, opts ...grpc.CallOption) (*pb.DescribeRepoEventsResponse, error) { m.ctrl.T.Helper() varargs := []interface{}{ctx, in} @@ -2009,9 +2049,51 @@ func (m *MockClient) DescribeRepoEvents(ctx context.Context, in *pb.DescribeRepo return ret0, ret1 } -// DescribeRepoEvents indicates an expected call of DescribeRepoEvents +// DescribeRepoEvents indicates an expected call of DescribeRepoEvents. func (mr *MockClientMockRecorder) DescribeRepoEvents(ctx, in interface{}, opts ...interface{}) *gomock.Call { mr.mock.ctrl.T.Helper() varargs := append([]interface{}{ctx, in}, opts...) return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeRepoEvents", reflect.TypeOf((*MockClient)(nil).DescribeRepoEvents), varargs...) } + +// UpsertRuntime mocks base method. +func (m *MockClient) UpsertRuntime(cluster, kubeConfig string) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "UpsertRuntime", cluster, kubeConfig) + ret0, _ := ret[0].(error) + return ret0 +} + +// UpsertRuntime indicates an expected call of UpsertRuntime. +func (mr *MockClientMockRecorder) UpsertRuntime(cluster, kubeConfig interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpsertRuntime", reflect.TypeOf((*MockClient)(nil).UpsertRuntime), cluster, kubeConfig) +} + +// CleanupRuntime mocks base method. +func (m *MockClient) CleanupRuntime(cluster string) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "CleanupRuntime", cluster) + ret0, _ := ret[0].(error) + return ret0 +} + +// CleanupRuntime indicates an expected call of CleanupRuntime. +func (mr *MockClientMockRecorder) CleanupRuntime(cluster interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CleanupRuntime", reflect.TypeOf((*MockClient)(nil).CleanupRuntime), cluster) +} + +// MigrateRuntime mocks base method. +func (m *MockClient) MigrateRuntime(runtimeId, cluster string) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "MigrateRuntime", runtimeId, cluster) + ret0, _ := ret[0].(error) + return ret0 +} + +// MigrateRuntime indicates an expected call of MigrateRuntime. +func (mr *MockClientMockRecorder) MigrateRuntime(runtimeId, cluster interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "MigrateRuntime", reflect.TypeOf((*MockClient)(nil).MigrateRuntime), runtimeId, cluster) +} diff --git a/pkg/simple/client/openpitrix/openpitrix.go b/pkg/simple/client/openpitrix/openpitrix.go index b06acd98c9ed1d25fa2d086cf3ce73ed7d722a45..f1cf48e17b989fc8eef0211364cce1449d537b0e 100644 --- a/pkg/simple/client/openpitrix/openpitrix.go +++ b/pkg/simple/client/openpitrix/openpitrix.go @@ -1,6 +1,6 @@ /* - Copyright 2019 The KubeSphere Authors. + Copyright 2020 The KubeSphere Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -20,6 +20,7 @@ package openpitrix import ( "context" "fmt" + "github.com/golang/protobuf/ptypes/wrappers" "k8s.io/klog" "openpitrix.io/openpitrix/pkg/manager" "openpitrix.io/openpitrix/pkg/pb" @@ -48,6 +49,12 @@ type Client interface { pb.CategoryManagerClient pb.AttachmentManagerClient pb.RepoIndexerClient + // upsert the openpitrix runtime when cluster is updated or created + UpsertRuntime(cluster string, kubeConfig string) error + // clean up the openpitrix runtime when cluster is deleted + CleanupRuntime(cluster string) error + // migrate the openpitrix runtime when upgrade ks2.x to ks3.x + MigrateRuntime(runtimeId string, cluster string) error } type client struct { @@ -60,6 +67,47 @@ type client struct { pb.RepoIndexerClient } +func (c *client) UpsertRuntime(cluster string, kubeConfig string) error { + ctx := SystemContext() + req := &pb.CreateRuntimeCredentialRequest{ + Name: &wrappers.StringValue{Value: fmt.Sprintf("kubeconfig-%s", cluster)}, + Provider: &wrappers.StringValue{Value: "kubernetes"}, + Description: &wrappers.StringValue{Value: "kubeconfig"}, + RuntimeUrl: &wrappers.StringValue{Value: "kubesphere"}, + RuntimeCredentialContent: &wrappers.StringValue{Value: kubeConfig}, + RuntimeCredentialId: &wrappers.StringValue{Value: cluster}, + } + _, err := c.CreateRuntimeCredential(ctx, req) + if err != nil { + return err + } + _, err = c.CreateRuntime(ctx, &pb.CreateRuntimeRequest{ + Name: &wrappers.StringValue{Value: cluster}, + RuntimeCredentialId: &wrappers.StringValue{Value: cluster}, + Provider: &wrappers.StringValue{Value: KubernetesProvider}, + Zone: &wrappers.StringValue{Value: cluster}, + }) + + return err +} + +func (c *client) CleanupRuntime(cluster string) error { + ctx := SystemContext() + _, err := c.DeleteClusterInRuntime(ctx, &pb.DeleteClusterInRuntimeRequest{ + RuntimeId: []string{cluster}, + }) + return err +} + +func (c *client) MigrateRuntime(runtimeId string, cluster string) error { + ctx := SystemContext() + _, err := c.MigrateClusterInRuntime(ctx, &pb.MigrateClusterInRuntimeRequest{ + FromRuntimeId: runtimeId, + ToRuntimeId: cluster, + }) + return err +} + func parseToHostPort(endpoint string) (string, int, error) { args := strings.Split(endpoint, ":") if len(args) != 2 { diff --git a/vendor/github.com/globalsign/mgo/bson/bson_corpus_spec_test_generator.go b/vendor/github.com/globalsign/mgo/bson/bson_corpus_spec_test_generator.go deleted file mode 100644 index 3525a004b6c8d636aa84423900c0f886c28dedfb..0000000000000000000000000000000000000000 --- a/vendor/github.com/globalsign/mgo/bson/bson_corpus_spec_test_generator.go +++ /dev/null @@ -1,294 +0,0 @@ -// +build ignore - -package main - -import ( - "bytes" - "fmt" - "go/format" - "html/template" - "io/ioutil" - "log" - "path/filepath" - "strings" - - "github.com/globalsign/mgo/internal/json" -) - -func main() { - log.SetFlags(0) - log.SetPrefix(name + ": ") - - var g Generator - - fmt.Fprintf(&g, "// Code generated by \"%s.go\"; DO NOT EDIT\n\n", name) - - src := g.generate() - - err := ioutil.WriteFile(fmt.Sprintf("%s.go", strings.TrimSuffix(name, "_generator")), src, 0644) - if err != nil { - log.Fatalf("writing output: %s", err) - } -} - -// Generator holds the state of the analysis. Primarily used to buffer -// the output for format.Source. -type Generator struct { - bytes.Buffer // Accumulated output. -} - -// format returns the gofmt-ed contents of the Generator's buffer. -func (g *Generator) format() []byte { - src, err := format.Source(g.Bytes()) - if err != nil { - // Should never happen, but can arise when developing this code. - // The user can compile the output to see the error. - log.Printf("warning: internal error: invalid Go generated: %s", err) - log.Printf("warning: compile the package to analyze the error") - return g.Bytes() - } - return src -} - -// EVERYTHING ABOVE IS CONSTANT BETWEEN THE GENERATORS - -const name = "bson_corpus_spec_test_generator" - -func (g *Generator) generate() []byte { - - testFiles, err := filepath.Glob("./specdata/specifications/source/bson-corpus/tests/*.json") - if err != nil { - log.Fatalf("error reading bson-corpus files: %s", err) - } - - tests, err := g.loadTests(testFiles) - if err != nil { - log.Fatalf("error loading tests: %s", err) - } - - tmpl, err := g.getTemplate() - if err != nil { - log.Fatalf("error loading template: %s", err) - } - - tmpl.Execute(&g.Buffer, tests) - - return g.format() -} - -func (g *Generator) loadTests(filenames []string) ([]*testDef, error) { - var tests []*testDef - for _, filename := range filenames { - test, err := g.loadTest(filename) - if err != nil { - return nil, err - } - - tests = append(tests, test) - } - - return tests, nil -} - -func (g *Generator) loadTest(filename string) (*testDef, error) { - content, err := ioutil.ReadFile(filename) - if err != nil { - return nil, err - } - - var testDef testDef - err = json.Unmarshal(content, &testDef) - if err != nil { - return nil, err - } - - names := make(map[string]struct{}) - - for i := len(testDef.Valid) - 1; i >= 0; i-- { - if testDef.BsonType == "0x05" && testDef.Valid[i].Description == "subtype 0x02" { - testDef.Valid = append(testDef.Valid[:i], testDef.Valid[i+1:]...) - continue - } - - name := cleanupFuncName(testDef.Description + "_" + testDef.Valid[i].Description) - nameIdx := name - j := 1 - for { - if _, ok := names[nameIdx]; !ok { - break - } - - nameIdx = fmt.Sprintf("%s_%d", name, j) - } - - names[nameIdx] = struct{}{} - - testDef.Valid[i].TestDef = &testDef - testDef.Valid[i].Name = nameIdx - testDef.Valid[i].StructTest = testDef.TestKey != "" && - (testDef.BsonType != "0x05" || strings.Contains(testDef.Valid[i].Description, "0x00")) && - !testDef.Deprecated - } - - for i := len(testDef.DecodeErrors) - 1; i >= 0; i-- { - if strings.Contains(testDef.DecodeErrors[i].Description, "UTF-8") { - testDef.DecodeErrors = append(testDef.DecodeErrors[:i], testDef.DecodeErrors[i+1:]...) - continue - } - - name := cleanupFuncName(testDef.Description + "_" + testDef.DecodeErrors[i].Description) - nameIdx := name - j := 1 - for { - if _, ok := names[nameIdx]; !ok { - break - } - - nameIdx = fmt.Sprintf("%s_%d", name, j) - } - names[nameIdx] = struct{}{} - - testDef.DecodeErrors[i].Name = nameIdx - } - - return &testDef, nil -} - -func (g *Generator) getTemplate() (*template.Template, error) { - content := `package bson_test - -import ( - "encoding/hex" - "time" - - . "gopkg.in/check.v1" - "github.com/globalsign/mgo/bson" -) - -func testValid(c *C, in []byte, expected []byte, result interface{}) { - err := bson.Unmarshal(in, result) - c.Assert(err, IsNil) - - out, err := bson.Marshal(result) - c.Assert(err, IsNil) - - c.Assert(string(expected), Equals, string(out), Commentf("roundtrip failed for %T, expected '%x' but got '%x'", result, expected, out)) -} - -func testDecodeSkip(c *C, in []byte) { - err := bson.Unmarshal(in, &struct{}{}) - c.Assert(err, IsNil) -} - -func testDecodeError(c *C, in []byte, result interface{}) { - err := bson.Unmarshal(in, result) - c.Assert(err, Not(IsNil)) -} - -{{range .}} -{{range .Valid}} -func (s *S) Test{{.Name}}(c *C) { - b, err := hex.DecodeString("{{.Bson}}") - c.Assert(err, IsNil) - - {{if .CanonicalBson}} - cb, err := hex.DecodeString("{{.CanonicalBson}}") - c.Assert(err, IsNil) - {{else}} - cb := b - {{end}} - - var resultD bson.D - testValid(c, b, cb, &resultD) - {{if .StructTest}}var resultS struct { - Element {{.TestDef.GoType}} ` + "`bson:\"{{.TestDef.TestKey}}\"`" + ` - } - testValid(c, b, cb, &resultS){{end}} - - testDecodeSkip(c, b) -} -{{end}} - -{{range .DecodeErrors}} -func (s *S) Test{{.Name}}(c *C) { - b, err := hex.DecodeString("{{.Bson}}") - c.Assert(err, IsNil) - - var resultD bson.D - testDecodeError(c, b, &resultD) -} -{{end}} -{{end}} -` - tmpl, err := template.New("").Parse(content) - if err != nil { - return nil, err - } - return tmpl, nil -} - -func cleanupFuncName(name string) string { - return strings.Map(func(r rune) rune { - if (r >= 48 && r <= 57) || (r >= 65 && r <= 90) || (r >= 97 && r <= 122) { - return r - } - return '_' - }, name) -} - -type testDef struct { - Description string `json:"description"` - BsonType string `json:"bson_type"` - TestKey string `json:"test_key"` - Valid []*valid `json:"valid"` - DecodeErrors []*decodeError `json:"decodeErrors"` - Deprecated bool `json:"deprecated"` -} - -func (t *testDef) GoType() string { - switch t.BsonType { - case "0x01": - return "float64" - case "0x02": - return "string" - case "0x03": - return "bson.D" - case "0x04": - return "[]interface{}" - case "0x05": - return "[]byte" - case "0x07": - return "bson.ObjectId" - case "0x08": - return "bool" - case "0x09": - return "time.Time" - case "0x0E": - return "string" - case "0x10": - return "int32" - case "0x12": - return "int64" - case "0x13": - return "bson.Decimal" - default: - return "interface{}" - } -} - -type valid struct { - Description string `json:"description"` - Bson string `json:"bson"` - CanonicalBson string `json:"canonical_bson"` - - Name string - StructTest bool - TestDef *testDef -} - -type decodeError struct { - Description string `json:"description"` - Bson string `json:"bson"` - - Name string -} diff --git a/vendor/github.com/golang/protobuf/descriptor/descriptor.go b/vendor/github.com/golang/protobuf/descriptor/descriptor.go new file mode 100644 index 0000000000000000000000000000000000000000..ac7e51bfb19c6c2e197bcd3ba61f554d2985a9f8 --- /dev/null +++ b/vendor/github.com/golang/protobuf/descriptor/descriptor.go @@ -0,0 +1,93 @@ +// Go support for Protocol Buffers - Google's data interchange format +// +// Copyright 2016 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 descriptor provides functions for obtaining protocol buffer +// descriptors for generated Go types. +// +// These functions cannot go in package proto because they depend on the +// generated protobuf descriptor messages, which themselves depend on proto. +package descriptor + +import ( + "bytes" + "compress/gzip" + "fmt" + "io/ioutil" + + "github.com/golang/protobuf/proto" + protobuf "github.com/golang/protobuf/protoc-gen-go/descriptor" +) + +// extractFile extracts a FileDescriptorProto from a gzip'd buffer. +func extractFile(gz []byte) (*protobuf.FileDescriptorProto, error) { + r, err := gzip.NewReader(bytes.NewReader(gz)) + if err != nil { + return nil, fmt.Errorf("failed to open gzip reader: %v", err) + } + defer r.Close() + + b, err := ioutil.ReadAll(r) + if err != nil { + return nil, fmt.Errorf("failed to uncompress descriptor: %v", err) + } + + fd := new(protobuf.FileDescriptorProto) + if err := proto.Unmarshal(b, fd); err != nil { + return nil, fmt.Errorf("malformed FileDescriptorProto: %v", err) + } + + return fd, nil +} + +// Message is a proto.Message with a method to return its descriptor. +// +// Message types generated by the protocol compiler always satisfy +// the Message interface. +type Message interface { + proto.Message + Descriptor() ([]byte, []int) +} + +// ForMessage returns a FileDescriptorProto and a DescriptorProto from within it +// describing the given message. +func ForMessage(msg Message) (fd *protobuf.FileDescriptorProto, md *protobuf.DescriptorProto) { + gz, path := msg.Descriptor() + fd, err := extractFile(gz) + if err != nil { + panic(fmt.Sprintf("invalid FileDescriptorProto for %T: %v", msg, err)) + } + + md = fd.MessageType[path[0]] + for _, i := range path[1:] { + md = md.NestedType[i] + } + return fd, md +} 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 deleted file mode 100644 index 6f4a902b5be567afb016211819f730a87df48368..0000000000000000000000000000000000000000 --- a/vendor/github.com/golang/protobuf/protoc-gen-go/generator/generator.go +++ /dev/null @@ -1,2806 +0,0 @@ -// Go support for Protocol Buffers - Google's data interchange format -// -// Copyright 2010 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. - -/* - The code generator for the plugin for the Google protocol buffer compiler. - It generates Go code from the protocol buffer description files read by the - main routine. -*/ -package generator - -import ( - "bufio" - "bytes" - "compress/gzip" - "crypto/sha256" - "encoding/hex" - "fmt" - "go/ast" - "go/build" - "go/parser" - "go/printer" - "go/token" - "log" - "os" - "path" - "sort" - "strconv" - "strings" - "unicode" - "unicode/utf8" - - "github.com/golang/protobuf/proto" - "github.com/golang/protobuf/protoc-gen-go/generator/internal/remap" - - "github.com/golang/protobuf/protoc-gen-go/descriptor" - plugin "github.com/golang/protobuf/protoc-gen-go/plugin" -) - -// generatedCodeVersion indicates a version of the generated code. -// 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 = 3 - -// A Plugin provides functionality to add to the output during Go code generation, -// such as to produce RPC stubs. -type Plugin interface { - // Name identifies the plugin. - Name() string - // Init is called once after data structures are built but before - // code generation begins. - Init(g *Generator) - // Generate produces the code generated by the plugin for this file, - // except for the imports, by calling the generator's methods P, In, and Out. - Generate(file *FileDescriptor) - // GenerateImports produces the import declarations for this file. - // It is called after Generate. - GenerateImports(file *FileDescriptor) -} - -var plugins []Plugin - -// RegisterPlugin installs a (second-order) plugin to be run when the Go output is generated. -// It is typically called during initialization. -func RegisterPlugin(p Plugin) { - plugins = append(plugins, p) -} - -// A GoImportPath is the import path of a Go package. e.g., "google.golang.org/genproto/protobuf". -type GoImportPath string - -func (p GoImportPath) String() string { return strconv.Quote(string(p)) } - -// A GoPackageName is the name of a Go package. e.g., "protobuf". -type GoPackageName string - -// Each type we import as a protocol buffer (other than FileDescriptorProto) needs -// a pointer to the FileDescriptorProto that represents it. These types achieve that -// wrapping by placing each Proto inside a struct with the pointer to its File. The -// structs have the same names as their contents, with "Proto" removed. -// FileDescriptor is used to store the things that it points to. - -// The file and package name method are common to messages and enums. -type common struct { - file *FileDescriptor // File this object comes from. -} - -// GoImportPath is the import path of the Go package containing the type. -func (c *common) GoImportPath() GoImportPath { - return c.file.importPath -} - -func (c *common) File() *FileDescriptor { return c.file } - -func fileIsProto3(file *descriptor.FileDescriptorProto) bool { - return file.GetSyntax() == "proto3" -} - -func (c *common) proto3() bool { return fileIsProto3(c.file.FileDescriptorProto) } - -// Descriptor represents a protocol buffer message. -type Descriptor struct { - common - *descriptor.DescriptorProto - parent *Descriptor // The containing message, if any. - nested []*Descriptor // Inner messages, if any. - enums []*EnumDescriptor // Inner enums, if any. - ext []*ExtensionDescriptor // Extensions, if any. - typename []string // Cached typename vector. - index int // The index into the container, whether the file or another message. - path string // The SourceCodeInfo path as comma-separated integers. - group bool -} - -// TypeName returns the elements of the dotted type name. -// The package name is not part of this name. -func (d *Descriptor) TypeName() []string { - if d.typename != nil { - return d.typename - } - n := 0 - for parent := d; parent != nil; parent = parent.parent { - n++ - } - s := make([]string, n) - for parent := d; parent != nil; parent = parent.parent { - n-- - s[n] = parent.GetName() - } - d.typename = s - return s -} - -// EnumDescriptor describes an enum. If it's at top level, its parent will be nil. -// Otherwise it will be the descriptor of the message in which it is defined. -type EnumDescriptor struct { - common - *descriptor.EnumDescriptorProto - parent *Descriptor // The containing message, if any. - typename []string // Cached typename vector. - index int // The index into the container, whether the file or a message. - path string // The SourceCodeInfo path as comma-separated integers. -} - -// TypeName returns the elements of the dotted type name. -// The package name is not part of this name. -func (e *EnumDescriptor) TypeName() (s []string) { - if e.typename != nil { - return e.typename - } - name := e.GetName() - if e.parent == nil { - s = make([]string, 1) - } else { - pname := e.parent.TypeName() - s = make([]string, len(pname)+1) - copy(s, pname) - } - s[len(s)-1] = name - e.typename = s - return s -} - -// Everything but the last element of the full type name, CamelCased. -// The values of type Foo.Bar are call Foo_value1... not Foo_Bar_value1... . -func (e *EnumDescriptor) prefix() string { - if e.parent == nil { - // If the enum is not part of a message, the prefix is just the type name. - return CamelCase(*e.Name) + "_" - } - typeName := e.TypeName() - return CamelCaseSlice(typeName[0:len(typeName)-1]) + "_" -} - -// The integer value of the named constant in this enumerated type. -func (e *EnumDescriptor) integerValueAsString(name string) string { - for _, c := range e.Value { - if c.GetName() == name { - return fmt.Sprint(c.GetNumber()) - } - } - log.Fatal("cannot find value for enum constant") - return "" -} - -// ExtensionDescriptor describes an extension. If it's at top level, its parent will be nil. -// Otherwise it will be the descriptor of the message in which it is defined. -type ExtensionDescriptor struct { - common - *descriptor.FieldDescriptorProto - parent *Descriptor // The containing message, if any. -} - -// TypeName returns the elements of the dotted type name. -// The package name is not part of this name. -func (e *ExtensionDescriptor) TypeName() (s []string) { - name := e.GetName() - if e.parent == nil { - // top-level extension - s = make([]string, 1) - } else { - pname := e.parent.TypeName() - s = make([]string, len(pname)+1) - copy(s, pname) - } - s[len(s)-1] = name - return s -} - -// DescName returns the variable name used for the generated descriptor. -func (e *ExtensionDescriptor) DescName() string { - // The full type name. - typeName := e.TypeName() - // Each scope of the extension is individually CamelCased, and all are joined with "_" with an "E_" prefix. - for i, s := range typeName { - typeName[i] = CamelCase(s) - } - return "E_" + strings.Join(typeName, "_") -} - -// ImportedDescriptor describes a type that has been publicly imported from another file. -type ImportedDescriptor struct { - common - o Object -} - -func (id *ImportedDescriptor) TypeName() []string { return id.o.TypeName() } - -// FileDescriptor describes an protocol buffer descriptor file (.proto). -// It includes slices of all the messages and enums defined within it. -// Those slices are constructed by WrapTypes. -type FileDescriptor struct { - *descriptor.FileDescriptorProto - desc []*Descriptor // All the messages defined in this file. - enum []*EnumDescriptor // All the enums defined in this file. - ext []*ExtensionDescriptor // All the top-level extensions defined in this file. - imp []*ImportedDescriptor // All types defined in files publicly imported by this file. - - // Comments, stored as a map of path (comma-separated integers) to the comment. - comments map[string]*descriptor.SourceCodeInfo_Location - - // The full list of symbols that are exported, - // as a map from the exported object to its symbols. - // This is used for supporting public imports. - exported map[Object][]symbol - - importPath GoImportPath // Import path of this file's package. - packageName GoPackageName // Name of this file's Go package. - - proto3 bool // whether to generate proto3 code for this file -} - -// VarName is the variable name we'll use in the generated code to refer -// 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 { - h := sha256.Sum256([]byte(d.GetName())) - return fmt.Sprintf("fileDescriptor_%s", hex.EncodeToString(h[:8])) -} - -// goPackageOption interprets the file's go_package option. -// If there is no go_package, it returns ("", "", false). -// If there's a simple name, it returns ("", pkg, true). -// If the option implies an import path, it returns (impPath, pkg, true). -func (d *FileDescriptor) goPackageOption() (impPath GoImportPath, pkg GoPackageName, ok bool) { - opt := d.GetOptions().GetGoPackage() - if opt == "" { - return "", "", false - } - // A semicolon-delimited suffix delimits the import path and package name. - sc := strings.Index(opt, ";") - if sc >= 0 { - return GoImportPath(opt[:sc]), cleanPackageName(opt[sc+1:]), true - } - // The presence of a slash implies there's an import path. - slash := strings.LastIndex(opt, "/") - if slash >= 0 { - return GoImportPath(opt), cleanPackageName(opt[slash+1:]), true - } - return "", cleanPackageName(opt), true -} - -// goFileName returns the output name for the generated Go file. -func (d *FileDescriptor) goFileName(pathType pathType) string { - name := *d.Name - if ext := path.Ext(name); ext == ".proto" || ext == ".protodevel" { - name = name[:len(name)-len(ext)] - } - name += ".pb.go" - - if pathType == pathTypeSourceRelative { - return name - } - - // Does the file have a "go_package" option? - // If it does, it may override the filename. - if impPath, _, ok := d.goPackageOption(); ok && impPath != "" { - // Replace the existing dirname with the declared import path. - _, name = path.Split(name) - name = path.Join(string(impPath), name) - return name - } - - return name -} - -func (d *FileDescriptor) addExport(obj Object, sym symbol) { - d.exported[obj] = append(d.exported[obj], sym) -} - -// symbol is an interface representing an exported Go symbol. -type symbol interface { - // GenerateAlias should generate an appropriate alias - // for the symbol from the named package. - GenerateAlias(g *Generator, filename string, pkg GoPackageName) -} - -type messageSymbol struct { - sym string - hasExtensions, isMessageSet bool - oneofTypes []string -} - -type getterSymbol struct { - name string - typ string - typeName string // canonical name in proto world; empty for proto.Message and similar - genType bool // whether typ contains a generated type (message/group/enum) -} - -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) - } -} - -type enumSymbol struct { - name string - proto3 bool // Whether this came from a proto3 file. -} - -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") -} - -type constOrVarSymbol struct { - sym string - typ string // either "const" or "var" - cast string // if non-empty, a type cast is required (used for enums) -} - -func (cs constOrVarSymbol) GenerateAlias(g *Generator, filename string, pkg GoPackageName) { - v := string(pkg) + "." + cs.sym - if cs.cast != "" { - v = cs.cast + "(" + v + ")" - } - g.P(cs.typ, " ", cs.sym, " = ", v) -} - -// Object is an interface abstracting the abilities shared by enums, messages, extensions and imported objects. -type Object interface { - GoImportPath() GoImportPath - TypeName() []string - File() *FileDescriptor -} - -// Generator is the type whose methods generate the output, stored in the associated response structure. -type Generator struct { - *bytes.Buffer - - Request *plugin.CodeGeneratorRequest // The input. - Response *plugin.CodeGeneratorResponse // The output. - - Param map[string]string // Command-line parameters. - PackageImportPath string // Go import path of the package we're generating code for - ImportPrefix string // String to prefix to imported package file names. - ImportMap map[string]string // Mapping from .proto file name to import path - - Pkg map[string]string // The names under which we import support packages - - outputImportPath GoImportPath // Package we're generating code for. - allFiles []*FileDescriptor // All files in the tree - allFilesByName map[string]*FileDescriptor // All files by filename. - genFiles []*FileDescriptor // Those files we will generate output for. - file *FileDescriptor // The file we are compiling now. - 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 - pathType pathType // How to generate output filenames. - writeOutput bool - annotateCode bool // whether to store annotations - annotations []*descriptor.GeneratedCodeInfo_Annotation // annotations to store -} - -type pathType int - -const ( - pathTypeImport pathType = iota - pathTypeSourceRelative -) - -// New creates a new generator and allocates the request and response protobufs. -func New() *Generator { - g := new(Generator) - g.Buffer = new(bytes.Buffer) - g.Request = new(plugin.CodeGeneratorRequest) - g.Response = new(plugin.CodeGeneratorResponse) - return g -} - -// Error reports a problem, including an error, and exits the program. -func (g *Generator) Error(err error, msgs ...string) { - s := strings.Join(msgs, " ") + ":" + err.Error() - log.Print("protoc-gen-go: error:", s) - os.Exit(1) -} - -// Fail reports a problem and exits the program. -func (g *Generator) Fail(msgs ...string) { - s := strings.Join(msgs, " ") - log.Print("protoc-gen-go: error:", s) - os.Exit(1) -} - -// CommandLineParameters breaks the comma-separated list of key=value pairs -// in the parameter (a member of the request protobuf) into a key/value map. -// It then sets file name mappings defined by those entries. -func (g *Generator) CommandLineParameters(parameter string) { - g.Param = make(map[string]string) - for _, p := range strings.Split(parameter, ",") { - if i := strings.Index(p, "="); i < 0 { - g.Param[p] = "" - } else { - g.Param[p[0:i]] = p[i+1:] - } - } - - g.ImportMap = make(map[string]string) - pluginList := "none" // Default list of plugin names to enable (empty means all). - for k, v := range g.Param { - switch k { - case "import_prefix": - g.ImportPrefix = v - case "import_path": - g.PackageImportPath = v - case "paths": - switch v { - case "import": - g.pathType = pathTypeImport - case "source_relative": - g.pathType = pathTypeSourceRelative - default: - g.Fail(fmt.Sprintf(`Unknown path type %q: want "import" or "source_relative".`, v)) - } - case "plugins": - pluginList = v - case "annotate_code": - if v == "true" { - g.annotateCode = true - } - default: - if len(k) > 0 && k[0] == 'M' { - g.ImportMap[k[1:]] = v - } - } - } - if pluginList != "" { - // Amend the set of plugins. - enabled := make(map[string]bool) - for _, name := range strings.Split(pluginList, "+") { - enabled[name] = true - } - var nplugins []Plugin - for _, p := range plugins { - if enabled[p.Name()] { - nplugins = append(nplugins, p) - } - } - plugins = nplugins - } -} - -// DefaultPackageName returns the package name printed for the object. -// If its file is in a different package, it returns the package name we're using for this file, plus ".". -// Otherwise it returns the empty string. -func (g *Generator) DefaultPackageName(obj Object) string { - importPath := obj.GoImportPath() - if importPath == g.outputImportPath { - return "" - } - return string(g.GoPackageName(importPath)) + "." -} - -// GoPackageName returns the name used for a package. -func (g *Generator) GoPackageName(importPath GoImportPath) GoPackageName { - if name, ok := g.packageNames[importPath]; ok { - return name - } - name := cleanPackageName(baseName(string(importPath))) - for i, orig := 1, name; g.usedPackageNames[name] || isGoPredeclaredIdentifier[string(name)]; i++ { - name = orig + GoPackageName(strconv.Itoa(i)) - } - g.packageNames[importPath] = name - g.usedPackageNames[name] = true - 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, - "proto": true, -} - -// Create and remember a guaranteed unique package name. Pkg is the candidate name. -// The FileDescriptor parameter is unused. -func RegisterUniquePackageName(pkg string, f *FileDescriptor) string { - name := cleanPackageName(pkg) - for i, orig := 1, name; globalPackageNames[name]; i++ { - name = orig + GoPackageName(strconv.Itoa(i)) - } - globalPackageNames[name] = true - return string(name) -} - -var isGoKeyword = map[string]bool{ - "break": true, - "case": true, - "chan": true, - "const": true, - "continue": true, - "default": true, - "else": true, - "defer": true, - "fallthrough": true, - "for": true, - "func": true, - "go": true, - "goto": true, - "if": true, - "import": true, - "interface": true, - "map": true, - "package": true, - "range": true, - "return": true, - "select": true, - "struct": true, - "switch": true, - "type": true, - "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 or predeclared identifier: insert _. - if isGoKeyword[name] { - name = "_" + name - } - // Identifier must not begin with digit: insert _. - if r, _ := utf8.DecodeRuneInString(name); unicode.IsDigit(r) { - name = "_" + name - } - return GoPackageName(name) -} - -// defaultGoPackage returns the package name to use, -// derived from the import path of the package we're building code for. -func (g *Generator) defaultGoPackage() GoPackageName { - p := g.PackageImportPath - if i := strings.LastIndex(p, "/"); i >= 0 { - p = p[i+1:] - } - return cleanPackageName(p) -} - -// SetPackageNames sets the package name for this run. -// The package name must agree across all files being generated. -// It also defines unique package names for all imported files. -func (g *Generator) SetPackageNames() { - g.outputImportPath = g.genFiles[0].importPath - - defaultPackageNames := make(map[GoImportPath]GoPackageName) - for _, f := range g.genFiles { - if _, p, ok := f.goPackageOption(); ok { - defaultPackageNames[f.importPath] = p - } - } - for _, f := range g.genFiles { - if _, p, ok := f.goPackageOption(); ok { - // Source file: option go_package = "quux/bar"; - f.packageName = p - } else if p, ok := defaultPackageNames[f.importPath]; ok { - // A go_package option in another file in the same package. - // - // This is a poor choice in general, since every source file should - // contain a go_package option. Supported mainly for historical - // compatibility. - f.packageName = p - } else if p := g.defaultGoPackage(); p != "" { - // Command-line: import_path=quux/bar. - // - // The import_path flag sets a package name for files which don't - // contain a go_package option. - f.packageName = p - } else if p := f.GetPackage(); p != "" { - // Source file: package quux.bar; - f.packageName = cleanPackageName(p) - } else { - // Source filename. - f.packageName = cleanPackageName(baseName(f.GetName())) - } - } - - // Check that all files have a consistent package name and import path. - for _, f := range g.genFiles[1:] { - if a, b := g.genFiles[0].importPath, f.importPath; a != b { - g.Fail(fmt.Sprintf("inconsistent package import paths: %v, %v", a, b)) - } - if a, b := g.genFiles[0].packageName, f.packageName; a != b { - g.Fail(fmt.Sprintf("inconsistent package names: %v, %v", a, b)) - } - } - - // Names of support packages. These never vary (if there are conflicts, - // we rename the conflicting package), so this could be removed someday. - g.Pkg = map[string]string{ - "fmt": "fmt", - "math": "math", - "proto": "proto", - } -} - -// WrapTypes walks the incoming data, wrapping DescriptorProtos, EnumDescriptorProtos -// and FileDescriptorProtos into file-referenced objects within the Generator. -// It also creates the list of files to generate and so should be called before GenerateAllFiles. -func (g *Generator) WrapTypes() { - g.allFiles = make([]*FileDescriptor, 0, len(g.Request.ProtoFile)) - g.allFilesByName = make(map[string]*FileDescriptor, len(g.allFiles)) - genFileNames := make(map[string]bool) - for _, n := range g.Request.FileToGenerate { - genFileNames[n] = true - } - for _, f := range g.Request.ProtoFile { - fd := &FileDescriptor{ - FileDescriptorProto: f, - exported: make(map[Object][]symbol), - proto3: fileIsProto3(f), - } - // The import path may be set in a number of ways. - if substitution, ok := g.ImportMap[f.GetName()]; ok { - // Command-line: M=foo.proto=quux/bar. - // - // Explicit mapping of source file to import path. - fd.importPath = GoImportPath(substitution) - } else if genFileNames[f.GetName()] && g.PackageImportPath != "" { - // Command-line: import_path=quux/bar. - // - // The import_path flag sets the import path for every file that - // we generate code for. - fd.importPath = GoImportPath(g.PackageImportPath) - } else if p, _, _ := fd.goPackageOption(); p != "" { - // Source file: option go_package = "quux/bar"; - // - // The go_package option sets the import path. Most users should use this. - fd.importPath = p - } else { - // Source filename. - // - // Last resort when nothing else is available. - fd.importPath = GoImportPath(path.Dir(f.GetName())) - } - // We must wrap the descriptors before we wrap the enums - fd.desc = wrapDescriptors(fd) - g.buildNestedDescriptors(fd.desc) - fd.enum = wrapEnumDescriptors(fd, fd.desc) - g.buildNestedEnums(fd.desc, fd.enum) - fd.ext = wrapExtensions(fd) - extractComments(fd) - g.allFiles = append(g.allFiles, fd) - g.allFilesByName[f.GetName()] = fd - } - for _, fd := range g.allFiles { - fd.imp = wrapImported(fd, g) - } - - g.genFiles = make([]*FileDescriptor, 0, len(g.Request.FileToGenerate)) - for _, fileName := range g.Request.FileToGenerate { - fd := g.allFilesByName[fileName] - if fd == nil { - g.Fail("could not find file named", fileName) - } - g.genFiles = append(g.genFiles, fd) - } -} - -// 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 { - if len(desc.NestedType) != 0 { - for _, nest := range descs { - if nest.parent == desc { - desc.nested = append(desc.nested, nest) - } - } - if len(desc.nested) != len(desc.NestedType) { - g.Fail("internal error: nesting failure for", desc.GetName()) - } - } - } -} - -func (g *Generator) buildNestedEnums(descs []*Descriptor, enums []*EnumDescriptor) { - for _, desc := range descs { - if len(desc.EnumType) != 0 { - for _, enum := range enums { - if enum.parent == desc { - desc.enums = append(desc.enums, enum) - } - } - if len(desc.enums) != len(desc.EnumType) { - g.Fail("internal error: enum nesting failure for", desc.GetName()) - } - } - } -} - -// Construct the Descriptor -func newDescriptor(desc *descriptor.DescriptorProto, parent *Descriptor, file *FileDescriptor, index int) *Descriptor { - d := &Descriptor{ - common: common{file}, - DescriptorProto: desc, - parent: parent, - index: index, - } - if parent == nil { - d.path = fmt.Sprintf("%d,%d", messagePath, index) - } else { - d.path = fmt.Sprintf("%s,%d,%d", parent.path, messageMessagePath, index) - } - - // The only way to distinguish a group from a message is whether - // the containing message has a TYPE_GROUP field that matches. - if parent != nil { - parts := d.TypeName() - if file.Package != nil { - parts = append([]string{*file.Package}, parts...) - } - exp := "." + strings.Join(parts, ".") - for _, field := range parent.Field { - if field.GetType() == descriptor.FieldDescriptorProto_TYPE_GROUP && field.GetTypeName() == exp { - d.group = true - break - } - } - } - - for _, field := range desc.Extension { - d.ext = append(d.ext, &ExtensionDescriptor{common{file}, field, d}) - } - - return d -} - -// Return a slice of all the Descriptors defined within this file -func wrapDescriptors(file *FileDescriptor) []*Descriptor { - sl := make([]*Descriptor, 0, len(file.MessageType)+10) - for i, desc := range file.MessageType { - sl = wrapThisDescriptor(sl, desc, nil, file, i) - } - return sl -} - -// Wrap this Descriptor, recursively -func wrapThisDescriptor(sl []*Descriptor, desc *descriptor.DescriptorProto, parent *Descriptor, file *FileDescriptor, index int) []*Descriptor { - sl = append(sl, newDescriptor(desc, parent, file, index)) - me := sl[len(sl)-1] - for i, nested := range desc.NestedType { - sl = wrapThisDescriptor(sl, nested, me, file, i) - } - return sl -} - -// Construct the EnumDescriptor -func newEnumDescriptor(desc *descriptor.EnumDescriptorProto, parent *Descriptor, file *FileDescriptor, index int) *EnumDescriptor { - ed := &EnumDescriptor{ - common: common{file}, - EnumDescriptorProto: desc, - parent: parent, - index: index, - } - if parent == nil { - ed.path = fmt.Sprintf("%d,%d", enumPath, index) - } else { - ed.path = fmt.Sprintf("%s,%d,%d", parent.path, messageEnumPath, index) - } - return ed -} - -// Return a slice of all the EnumDescriptors defined within this file -func wrapEnumDescriptors(file *FileDescriptor, descs []*Descriptor) []*EnumDescriptor { - sl := make([]*EnumDescriptor, 0, len(file.EnumType)+10) - // Top-level enums. - for i, enum := range file.EnumType { - sl = append(sl, newEnumDescriptor(enum, nil, file, i)) - } - // Enums within messages. Enums within embedded messages appear in the outer-most message. - for _, nested := range descs { - for i, enum := range nested.EnumType { - sl = append(sl, newEnumDescriptor(enum, nested, file, i)) - } - } - return sl -} - -// Return a slice of all the top-level ExtensionDescriptors defined within this file. -func wrapExtensions(file *FileDescriptor) []*ExtensionDescriptor { - var sl []*ExtensionDescriptor - for _, field := range file.Extension { - sl = append(sl, &ExtensionDescriptor{common{file}, field, nil}) - } - return sl -} - -// Return a slice of all the types that are publicly imported into this file. -func wrapImported(file *FileDescriptor, g *Generator) (sl []*ImportedDescriptor) { - for _, index := range file.PublicDependency { - df := g.fileByName(file.Dependency[index]) - for _, d := range df.desc { - if d.GetOptions().GetMapEntry() { - continue - } - sl = append(sl, &ImportedDescriptor{common{file}, d}) - } - for _, e := range df.enum { - sl = append(sl, &ImportedDescriptor{common{file}, e}) - } - for _, ext := range df.ext { - sl = append(sl, &ImportedDescriptor{common{file}, ext}) - } - } - return -} - -func extractComments(file *FileDescriptor) { - file.comments = make(map[string]*descriptor.SourceCodeInfo_Location) - for _, loc := range file.GetSourceCodeInfo().GetLocation() { - if loc.LeadingComments == nil { - continue - } - var p []string - for _, n := range loc.Path { - p = append(p, strconv.Itoa(int(n))) - } - file.comments[strings.Join(p, ",")] = loc - } -} - -// BuildTypeNameMap builds the map from fully qualified type names to objects. -// The key names for the map come from the input data, which puts a period at the beginning. -// It should be called after SetPackageNames and before GenerateAllFiles. -func (g *Generator) BuildTypeNameMap() { - g.typeNameToObject = make(map[string]Object) - for _, f := range g.allFiles { - // The names in this loop are defined by the proto world, not us, so the - // package name may be empty. If so, the dotted package name of X will - // be ".X"; otherwise it will be ".pkg.X". - dottedPkg := "." + f.GetPackage() - if dottedPkg != "." { - dottedPkg += "." - } - for _, enum := range f.enum { - name := dottedPkg + dottedSlice(enum.TypeName()) - g.typeNameToObject[name] = enum - } - for _, desc := range f.desc { - name := dottedPkg + dottedSlice(desc.TypeName()) - g.typeNameToObject[name] = desc - } - } -} - -// ObjectNamed, given a fully-qualified input type name as it appears in the input data, -// returns the descriptor for the message or enum with that name. -func (g *Generator) ObjectNamed(typeName string) Object { - o, ok := g.typeNameToObject[typeName] - if !ok { - g.Fail("can't find object with type", typeName) - } - return o -} - -// AnnotatedAtoms is a list of atoms (as consumed by P) that records the file name and proto AST path from which they originated. -type AnnotatedAtoms struct { - source string - path string - atoms []interface{} -} - -// Annotate records the file name and proto AST path of a list of atoms -// so that a later call to P can emit a link from each atom to its origin. -func Annotate(file *FileDescriptor, path string, atoms ...interface{}) *AnnotatedAtoms { - return &AnnotatedAtoms{source: *file.Name, path: path, atoms: atoms} -} - -// printAtom prints the (atomic, non-annotation) argument to the generated output. -func (g *Generator) printAtom(v interface{}) { - switch v := v.(type) { - case string: - g.WriteString(v) - case *string: - g.WriteString(*v) - case bool: - fmt.Fprint(g, v) - case *bool: - fmt.Fprint(g, *v) - case int: - fmt.Fprint(g, v) - case *int32: - fmt.Fprint(g, *v) - case *int64: - fmt.Fprint(g, *v) - case float64: - fmt.Fprint(g, v) - case *float64: - fmt.Fprint(g, *v) - case GoPackageName: - g.WriteString(string(v)) - case GoImportPath: - g.WriteString(strconv.Quote(string(v))) - default: - g.Fail(fmt.Sprintf("unknown type in printer: %T", v)) - } -} - -// P prints the arguments to the generated output. It handles strings and int32s, plus -// handling indirections because they may be *string, etc. Any inputs of type AnnotatedAtoms may emit -// annotations in a .meta file in addition to outputting the atoms themselves (if g.annotateCode -// is true). -func (g *Generator) P(str ...interface{}) { - if !g.writeOutput { - return - } - g.WriteString(g.indent) - for _, v := range str { - switch v := v.(type) { - case *AnnotatedAtoms: - begin := int32(g.Len()) - for _, v := range v.atoms { - g.printAtom(v) - } - if g.annotateCode { - end := int32(g.Len()) - var path []int32 - for _, token := range strings.Split(v.path, ",") { - val, err := strconv.ParseInt(token, 10, 32) - if err != nil { - g.Fail("could not parse proto AST path: ", err.Error()) - } - path = append(path, int32(val)) - } - g.annotations = append(g.annotations, &descriptor.GeneratedCodeInfo_Annotation{ - Path: path, - SourceFile: &v.source, - Begin: &begin, - End: &end, - }) - } - default: - g.printAtom(v) - } - } - g.WriteByte('\n') -} - -// addInitf stores the given statement to be printed inside the file's init function. -// The statement is given as a format specifier and arguments. -func (g *Generator) addInitf(stmt string, a ...interface{}) { - g.init = append(g.init, fmt.Sprintf(stmt, a...)) -} - -// In Indents the output one tab stop. -func (g *Generator) In() { g.indent += "\t" } - -// Out unindents the output one tab stop. -func (g *Generator) Out() { - if len(g.indent) > 0 { - g.indent = g.indent[1:] - } -} - -// GenerateAllFiles generates the output for all the files we're outputting. -func (g *Generator) GenerateAllFiles() { - // Initialize the plugins - for _, p := range plugins { - p.Init(g) - } - // Generate the output. The generator runs for every file, even the files - // that we don't generate output for, so that we can collate the full list - // of exported symbols to support public imports. - genFileMap := make(map[*FileDescriptor]bool, len(g.genFiles)) - for _, file := range g.genFiles { - genFileMap[file] = true - } - for _, file := range g.allFiles { - g.Reset() - g.annotations = nil - g.writeOutput = genFileMap[file] - g.generate(file) - if !g.writeOutput { - continue - } - fname := file.goFileName(g.pathType) - g.Response.File = append(g.Response.File, &plugin.CodeGeneratorResponse_File{ - Name: proto.String(fname), - Content: proto.String(g.String()), - }) - if g.annotateCode { - // Store the generated code annotations in text, as the protoc plugin protocol requires that - // strings contain valid UTF-8. - g.Response.File = append(g.Response.File, &plugin.CodeGeneratorResponse_File{ - Name: proto.String(file.goFileName(g.pathType) + ".meta"), - Content: proto.String(proto.CompactTextString(&descriptor.GeneratedCodeInfo{Annotation: g.annotations})), - }) - } - } -} - -// Run all the plugins associated with the file. -func (g *Generator) runPlugins(file *FileDescriptor) { - for _, p := range plugins { - p.Generate(file) - } -} - -// Fill the response protocol buffer with the generated output for all the files we're -// supposed to generate. -func (g *Generator) generate(file *FileDescriptor) { - g.file = file - 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 - } - - g.P("// This is a compile-time assertion to ensure that this generated file") - g.P("// is compatible with the proto package it is being compiled against.") - g.P("// A compilation error at this line likely means your copy of the") - g.P("// proto package needs to be updated.") - g.P("const _ = ", g.Pkg["proto"], ".ProtoPackageIsVersion", generatedCodeVersion, " // please upgrade the proto package") - g.P() - - for _, td := range g.file.imp { - g.generateImported(td) - } - for _, enum := range g.file.enum { - g.generateEnum(enum) - } - for _, desc := range g.file.desc { - // Don't generate virtual messages for maps. - if desc.GetOptions().GetMapEntry() { - continue - } - g.generateMessage(desc) - } - for _, ext := range g.file.ext { - g.generateExtension(ext) - } - g.generateInitFunction() - g.generateFileDescriptor(file) - - // Run the plugins before the imports so we know which imports are necessary. - g.runPlugins(file) - - // Generate header and imports last, though they appear first in the output. - rem := g.Buffer - remAnno := g.annotations - g.Buffer = new(bytes.Buffer) - g.annotations = nil - g.generateHeader() - g.generateImports() - if !g.writeOutput { - return - } - // Adjust the offsets for annotations displaced by the header and imports. - for _, anno := range remAnno { - *anno.Begin += int32(g.Len()) - *anno.End += int32(g.Len()) - g.annotations = append(g.annotations, anno) - } - g.Write(rem.Bytes()) - - // Reformat generated code and patch annotation locations. - fset := token.NewFileSet() - original := g.Bytes() - if g.annotateCode { - // make a copy independent of g; we'll need it after Reset. - original = append([]byte(nil), original...) - } - 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, - // so consider this a debugging aid. - var src bytes.Buffer - s := bufio.NewScanner(bytes.NewReader(original)) - for line := 1; s.Scan(); line++ { - fmt.Fprintf(&src, "%5d\t%s\n", line, s.Bytes()) - } - 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, fileAST) - if err != nil { - g.Fail("generated Go source code could not be reformatted:", err.Error()) - } - if g.annotateCode { - m, err := remap.Compute(original, g.Bytes()) - if err != nil { - g.Fail("formatted generated Go source code could not be mapped back to the original code:", err.Error()) - } - for _, anno := range g.annotations { - new, ok := m.Find(int(*anno.Begin), int(*anno.End)) - if !ok { - g.Fail("span in formatted generated Go source code could not be mapped back to the original code") - } - *anno.Begin = int32(new.Pos) - *anno.End = int32(new.End) - } - } -} - -// Generate the header, including package definition -func (g *Generator) generateHeader() { - g.P("// Code generated by protoc-gen-go. DO NOT EDIT.") - if g.file.GetOptions().GetDeprecated() { - g.P("// ", g.file.Name, " is a deprecated file.") - } else { - g.P("// source: ", g.file.Name) - } - g.P() - g.PrintComments(strconv.Itoa(packagePath)) - g.P() - g.P("package ", g.file.packageName) - g.P() -} - -// deprecationComment is the standard comment added to deprecated -// messages, fields, enums, and enum values. -var deprecationComment = "// Deprecated: Do not use." - -// PrintComments prints any comments from the source .proto file. -// The path is a comma-separated list of integers. -// It returns an indication of whether any comments were printed. -// See descriptor.proto for its format. -func (g *Generator) PrintComments(path string) bool { - if !g.writeOutput { - return false - } - if c, ok := g.makeComments(path); ok { - g.P(c) - return true - } - return false -} - -// makeComments generates the comment string for the field, no "\n" at the end -func (g *Generator) makeComments(path string) (string, bool) { - loc, ok := g.file.comments[path] - if !ok { - return "", false - } - w := new(bytes.Buffer) - nl := "" - for _, line := range strings.Split(strings.TrimSuffix(loc.GetLeadingComments(), "\n"), "\n") { - fmt.Fprintf(w, "%s//%s", nl, line) - nl = "\n" - } - return w.String(), true -} - -func (g *Generator) fileByName(filename string) *FileDescriptor { - return g.allFilesByName[filename] -} - -// weak returns whether the ith import of the current file is a weak import. -func (g *Generator) weak(i int32) bool { - for _, j := range g.file.WeakDependency { - if j == i { - return true - } - } - return false -} - -// Generate the imports -func (g *Generator) generateImports() { - imports := make(map[GoImportPath]GoPackageName) - for i, s := range g.file.Dependency { - fd := g.fileByName(s) - importPath := fd.importPath - // Do not import our own package. - if importPath == g.file.importPath { - continue - } - // Do not import weak imports. - if g.weak(int32(i)) { - continue - } - // 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 = "_" - } - 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 { - p.GenerateImports(g.file) - g.P() - } - g.P("// Reference imports to suppress errors if they are not otherwise used.") - g.P("var _ = ", g.Pkg["proto"], ".Marshal") - g.P("var _ = ", g.Pkg["fmt"], ".Errorf") - g.P("var _ = ", g.Pkg["math"], ".Inf") - g.P() -} - -func (g *Generator) generateImported(id *ImportedDescriptor) { - 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. - return - } - if !supportTypeAliases { - g.Fail(fmt.Sprintf("%s: public imports require at least go1.9", filename)) - } - g.usedPackages[df.importPath] = true - - for _, sym := range df.exported[id.o] { - sym.GenerateAlias(g, filename, g.GoPackageName(df.importPath)) - } - - g.P() -} - -// Generate the enum definitions for this EnumDescriptor. -func (g *Generator) generateEnum(enum *EnumDescriptor) { - // The full type name - typeName := enum.TypeName() - // The full type name, CamelCased. - ccTypeName := CamelCaseSlice(typeName) - ccPrefix := enum.prefix() - - deprecatedEnum := "" - if enum.GetOptions().GetDeprecated() { - deprecatedEnum = deprecationComment - } - g.PrintComments(enum.path) - g.P("type ", Annotate(enum.file, enum.path, ccTypeName), " int32", deprecatedEnum) - g.file.addExport(enum, enumSymbol{ccTypeName, enum.proto3()}) - g.P("const (") - for i, e := range enum.Value { - etorPath := fmt.Sprintf("%s,%d,%d", enum.path, enumValuePath, i) - g.PrintComments(etorPath) - - deprecatedValue := "" - if e.GetOptions().GetDeprecated() { - deprecatedValue = deprecationComment - } - - name := ccPrefix + *e.Name - g.P(Annotate(enum.file, etorPath, name), " ", ccTypeName, " = ", e.Number, " ", deprecatedValue) - 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 { - duplicate := "" - if _, present := generated[*e.Number]; present { - duplicate = "// Duplicate value: " - } - g.P(duplicate, e.Number, ": ", strconv.Quote(*e.Name), ",") - 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, " {") - g.P("p := new(", ccTypeName, ")") - 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 {") - g.P("value, err := ", g.Pkg["proto"], ".UnmarshalJSONEnum(", ccTypeName, `_value, data, "`, ccTypeName, `")`) - g.P("if err != nil {") - g.P("return err") - g.P("}") - g.P("*x = ", ccTypeName, "(value)") - g.P("return nil") - g.P("}") - g.P() - } - - var indexes []string - for m := enum.parent; m != nil; m = m.parent { - // XXX: skip groups? - indexes = append([]string{strconv.Itoa(m.index)}, indexes...) - } - indexes = append(indexes, strconv.Itoa(enum.index)) - 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.generateEnumRegistration(enum) -} - -// The tag is a string like "varint,2,opt,name=fieldname,def=7" that -// identifies details of the field for the protocol buffer marshaling and unmarshaling -// code. The fields are: -// wire encoding -// protocol tag number -// opt,req,rep for optional, required, or repeated -// packed whether the encoding is "packed" (optional; repeated primitives only) -// name= the original declared name -// enum= the name of the enum type if it is an enum-typed field. -// proto3 if this field is in a proto3 message -// def= string representation of the default value, if any. -// The default value must be in a representation that can be used at run-time -// to generate the default value. Thus bools become 0 and 1, for instance. -func (g *Generator) goTag(message *Descriptor, field *descriptor.FieldDescriptorProto, wiretype string) string { - optrepreq := "" - switch { - case isOptional(field): - optrepreq = "opt" - case isRequired(field): - optrepreq = "req" - case isRepeated(field): - optrepreq = "rep" - } - var defaultValue string - if dv := field.DefaultValue; dv != nil { // set means an explicit default - defaultValue = *dv - // Some types need tweaking. - switch *field.Type { - case descriptor.FieldDescriptorProto_TYPE_BOOL: - if defaultValue == "true" { - defaultValue = "1" - } else { - defaultValue = "0" - } - case descriptor.FieldDescriptorProto_TYPE_STRING, - descriptor.FieldDescriptorProto_TYPE_BYTES: - // Nothing to do. Quoting is done for the whole tag. - case descriptor.FieldDescriptorProto_TYPE_ENUM: - // For enums we need to provide the integer constant. - obj := g.ObjectNamed(field.GetTypeName()) - if id, ok := obj.(*ImportedDescriptor); ok { - // It is an enum that was publicly imported. - // We need the underlying type. - obj = id.o - } - enum, ok := obj.(*EnumDescriptor) - if !ok { - log.Printf("obj is a %T", obj) - if id, ok := obj.(*ImportedDescriptor); ok { - log.Printf("id.o is a %T", id.o) - } - 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 - } - enum := "" - if *field.Type == descriptor.FieldDescriptorProto_TYPE_ENUM { - // We avoid using obj.GoPackageName(), because we want to use the - // original (proto-world) package name. - obj := g.ObjectNamed(field.GetTypeName()) - if id, ok := obj.(*ImportedDescriptor); ok { - obj = id.o - } - enum = ",enum=" - if pkg := obj.File().GetPackage(); pkg != "" { - enum += pkg + "." - } - enum += CamelCaseSlice(obj.TypeName()) - } - packed := "" - if (field.Options != nil && field.Options.GetPacked()) || - // Per https://developers.google.com/protocol-buffers/docs/proto3#simple: - // "In proto3, repeated fields of scalar numeric types use packed encoding by default." - (message.proto3() && (field.Options == nil || field.Options.Packed == nil) && - isRepeated(field) && isScalar(field)) { - packed = ",packed" - } - fieldName := field.GetName() - name := fieldName - if *field.Type == descriptor.FieldDescriptorProto_TYPE_GROUP { - // We must use the type name for groups instead of - // the field name to preserve capitalization. - // type_name in FieldDescriptorProto is fully-qualified, - // but we only want the local part. - name = *field.TypeName - if i := strings.LastIndex(name, "."); i >= 0 { - name = name[i+1:] - } - } - 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 - } - name = ",name=" + name - if message.proto3() { - name += ",proto3" - } - oneof := "" - if field.OneofIndex != nil { - oneof = ",oneof" - } - return strconv.Quote(fmt.Sprintf("%s,%d,%s%s%s%s%s%s", - wiretype, - field.GetNumber(), - optrepreq, - packed, - name, - enum, - oneof, - defaultValue)) -} - -func needsStar(typ descriptor.FieldDescriptorProto_Type) bool { - switch typ { - case descriptor.FieldDescriptorProto_TYPE_GROUP: - return false - case descriptor.FieldDescriptorProto_TYPE_MESSAGE: - return false - case descriptor.FieldDescriptorProto_TYPE_BYTES: - return false - } - return true -} - -// TypeName is the printed name appropriate for an item. If the object is in the current file, -// TypeName drops the package name and underscores the rest. -// Otherwise the object is from another package; and the result is the underscored -// package name followed by the item name. -// The result always has an initial capital. -func (g *Generator) TypeName(obj Object) string { - return g.DefaultPackageName(obj) + CamelCaseSlice(obj.TypeName()) -} - -// GoType returns a string representing the type name, and the wire type -func (g *Generator) GoType(message *Descriptor, field *descriptor.FieldDescriptorProto) (typ string, wire string) { - // TODO: Options. - switch *field.Type { - case descriptor.FieldDescriptorProto_TYPE_DOUBLE: - typ, wire = "float64", "fixed64" - case descriptor.FieldDescriptorProto_TYPE_FLOAT: - typ, wire = "float32", "fixed32" - case descriptor.FieldDescriptorProto_TYPE_INT64: - typ, wire = "int64", "varint" - case descriptor.FieldDescriptorProto_TYPE_UINT64: - typ, wire = "uint64", "varint" - case descriptor.FieldDescriptorProto_TYPE_INT32: - typ, wire = "int32", "varint" - case descriptor.FieldDescriptorProto_TYPE_UINT32: - typ, wire = "uint32", "varint" - case descriptor.FieldDescriptorProto_TYPE_FIXED64: - typ, wire = "uint64", "fixed64" - case descriptor.FieldDescriptorProto_TYPE_FIXED32: - typ, wire = "uint32", "fixed32" - case descriptor.FieldDescriptorProto_TYPE_BOOL: - typ, wire = "bool", "varint" - case descriptor.FieldDescriptorProto_TYPE_STRING: - typ, wire = "string", "bytes" - case descriptor.FieldDescriptorProto_TYPE_GROUP: - desc := g.ObjectNamed(field.GetTypeName()) - typ, wire = "*"+g.TypeName(desc), "group" - case descriptor.FieldDescriptorProto_TYPE_MESSAGE: - desc := g.ObjectNamed(field.GetTypeName()) - typ, wire = "*"+g.TypeName(desc), "bytes" - case descriptor.FieldDescriptorProto_TYPE_BYTES: - typ, wire = "[]byte", "bytes" - case descriptor.FieldDescriptorProto_TYPE_ENUM: - desc := g.ObjectNamed(field.GetTypeName()) - typ, wire = g.TypeName(desc), "varint" - case descriptor.FieldDescriptorProto_TYPE_SFIXED32: - typ, wire = "int32", "fixed32" - case descriptor.FieldDescriptorProto_TYPE_SFIXED64: - typ, wire = "int64", "fixed64" - case descriptor.FieldDescriptorProto_TYPE_SINT32: - typ, wire = "int32", "zigzag32" - case descriptor.FieldDescriptorProto_TYPE_SINT64: - typ, wire = "int64", "zigzag64" - default: - g.Fail("unknown type for", field.GetName()) - } - if isRepeated(field) { - typ = "[]" + typ - } else if message != nil && message.proto3() { - return - } else if field.OneofIndex != nil && message != nil { - return - } else if needsStar(*field.Type) { - typ = "*" + typ - } - return -} - -func (g *Generator) RecordTypeUse(t string) { - 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 -// underscore appended. Any change to this set is a potential incompatible -// API change because it changes generated field names. -var methodNames = [...]string{ - "Reset", - "String", - "ProtoMessage", - "Marshal", - "Unmarshal", - "ExtensionRangeArray", - "ExtensionMap", - "Descriptor", -} - -// Names of messages in the `google.protobuf` package for which -// we will generate XXX_WellKnownType methods. -var wellKnownTypes = map[string]bool{ - "Any": true, - "Duration": true, - "Empty": true, - "Struct": true, - "Timestamp": true, - - "Value": true, - "ListValue": true, - "DoubleValue": true, - "FloatValue": true, - "Int64Value": true, - "UInt64Value": true, - "Int32Value": true, - "UInt32Value": true, - "BoolValue": true, - "StringValue": true, - "BytesValue": true, -} - -// getterDefault finds the default value for the field to return from a getter, -// regardless of if it's a built in default or explicit from the source. Returns e.g. "nil", `""`, "Default_MessageType_FieldName" -func (g *Generator) getterDefault(field *descriptor.FieldDescriptorProto, goMessageType string) string { - if isRepeated(field) { - return "nil" - } - if def := field.GetDefaultValue(); def != "" { - defaultConstant := g.defaultConstantName(goMessageType, field.GetName()) - if *field.Type != descriptor.FieldDescriptorProto_TYPE_BYTES { - return defaultConstant - } - return "append([]byte(nil), " + defaultConstant + "...)" - } - switch *field.Type { - case descriptor.FieldDescriptorProto_TYPE_BOOL: - return "false" - case descriptor.FieldDescriptorProto_TYPE_STRING: - return `""` - case descriptor.FieldDescriptorProto_TYPE_GROUP, descriptor.FieldDescriptorProto_TYPE_MESSAGE, descriptor.FieldDescriptorProto_TYPE_BYTES: - return "nil" - case descriptor.FieldDescriptorProto_TYPE_ENUM: - obj := g.ObjectNamed(field.GetTypeName()) - var enum *EnumDescriptor - if id, ok := obj.(*ImportedDescriptor); ok { - // The enum type has been publicly imported. - enum, _ = id.o.(*EnumDescriptor) - } else { - enum, _ = obj.(*EnumDescriptor) - } - if enum == nil { - log.Printf("don't know how to generate getter for %s", field.GetName()) - return "nil" - } - if len(enum.Value) == 0 { - return "0 // empty enum" - } - first := enum.Value[0].GetName() - return g.DefaultPackageName(obj) + enum.prefix() + first - default: - return "0" - } -} - -// defaultConstantName builds the name of the default constant from the message -// type name and the untouched field name, e.g. "Default_MessageType_FieldName" -func (g *Generator) defaultConstantName(goMessageType, protoFieldName string) string { - return "Default_" + goMessageType + "_" + CamelCase(protoFieldName) -} - -// The different types of fields in a message and how to actually print them -// Most of the logic for generateMessage is in the methods of these types. -// -// Note that the content of the field is irrelevant, a simpleField can contain -// anything from a scalar to a group (which is just a message). -// -// Extension fields (and message sets) are however handled separately. -// -// simpleField - a field that is neiter weak nor oneof, possibly repeated -// oneofField - field containing list of subfields: -// - oneofSubField - a field within the oneof - -// 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 -} - -// fieldCommon contains data common to all types of fields. -type fieldCommon struct { - goName string // Go name of field, e.g. "FieldName" or "Descriptor_" - protoName string // Name of field in proto language, e.g. "field_name" or "descriptor" - getterName string // Name of the getter, e.g. "GetFieldName" or "GetDescriptor_" - goType string // The Go type as a string, e.g. "*int32" or "*OtherMessage" - tags string // The tag string/annotation for the type, e.g. `protobuf:"varint,8,opt,name=region_id,json=regionId"` - fullPath string // The full path of the field as used by Annotate etc, e.g. "4,0,2,0" -} - -// getProtoName gets the proto name of a field, e.g. "field_name" or "descriptor". -func (f *fieldCommon) getProtoName() string { - return f.protoName -} - -// getGoType returns the go type of the field as a string, e.g. "*int32". -func (f *fieldCommon) getGoType() string { - return f.goType -} - -// simpleField is not weak, not a oneof, not an extension. Can be required, optional or repeated. -type simpleField struct { - fieldCommon - protoTypeName string // Proto type name, empty if primitive, e.g. ".google.protobuf.Duration" - protoType descriptor.FieldDescriptorProto_Type // Actual type enum value, e.g. descriptor.FieldDescriptorProto_TYPE_FIXED64 - deprecated string // Deprecation comment, if any, e.g. "// Deprecated: Do not use." - 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" - comment string // The full comment for the field, e.g. "// Useful information" -} - -// decl prints the declaration of the field in the struct (if any). -func (f *simpleField) decl(g *Generator, mc *msgCtx) { - g.P(f.comment, Annotate(mc.message.file, f.fullPath, f.goName), "\t", f.goType, "\t`", f.tags, "`", f.deprecated) -} - -// getter prints the getter for the field. -func (f *simpleField) getter(g *Generator, mc *msgCtx) { - star := "" - tname := f.goType - if needsStar(f.protoType) && tname[0] == '*' { - tname = tname[1:] - star = "*" - } - if f.deprecated != "" { - g.P(f.deprecated) - } - g.P("func (m *", mc.goName, ") ", Annotate(mc.message.file, f.fullPath, f.getterName), "() "+tname+" {") - if f.getterDef == "nil" { // Simpler getter - g.P("if m != nil {") - g.P("return m." + f.goName) - g.P("}") - g.P("return nil") - g.P("}") - g.P() - return - } - if mc.message.proto3() { - g.P("if m != nil {") - } else { - g.P("if m != nil && m." + f.goName + " != nil {") - } - g.P("return " + star + "m." + f.goName) - g.P("}") - g.P("return ", f.getterDef) - g.P("}") - g.P() -} - -// setter prints the setter method of the field. -func (f *simpleField) setter(g *Generator, mc *msgCtx) { - // No setter for regular fields yet -} - -// getProtoDef returns the default value explicitly stated in the proto file, e.g "yoshi" or "5". -func (f *simpleField) getProtoDef() string { - return f.protoDef -} - -// getProtoTypeName returns the protobuf type name for the field as returned by field.GetTypeName(), e.g. ".google.protobuf.Duration". -func (f *simpleField) getProtoTypeName() string { - return f.protoTypeName -} - -// getProtoType returns the *field.Type value, e.g. descriptor.FieldDescriptorProto_TYPE_FIXED64. -func (f *simpleField) getProtoType() descriptor.FieldDescriptorProto_Type { - return f.protoType -} - -// oneofSubFields are kept slize held by each oneofField. They do not appear in the top level slize of fields for the message. -type oneofSubField struct { - fieldCommon - protoTypeName string // Proto type name, empty if primitive, e.g. ".google.protobuf.Duration" - protoType descriptor.FieldDescriptorProto_Type // Actual type enum value, e.g. descriptor.FieldDescriptorProto_TYPE_FIXED64 - oneofTypeName string // Type name of the enclosing struct, e.g. "MessageName_FieldName" - 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" - deprecated string // Deprecation comment, if any. -} - -// typedNil prints a nil casted to the pointer to this field. -// - for XXX_OneofWrappers -func (f *oneofSubField) typedNil(g *Generator) { - g.P("(*", f.oneofTypeName, ")(nil),") -} - -// getProtoDef returns the default value explicitly stated in the proto file, e.g "yoshi" or "5". -func (f *oneofSubField) getProtoDef() string { - return f.protoDef -} - -// getProtoTypeName returns the protobuf type name for the field as returned by field.GetTypeName(), e.g. ".google.protobuf.Duration". -func (f *oneofSubField) getProtoTypeName() string { - return f.protoTypeName -} - -// getProtoType returns the *field.Type value, e.g. descriptor.FieldDescriptorProto_TYPE_FIXED64. -func (f *oneofSubField) getProtoType() descriptor.FieldDescriptorProto_Type { - return f.protoType -} - -// oneofField represents the oneof on top level. -// The alternative fields within the oneof are represented by oneofSubField. -type oneofField struct { - fieldCommon - subFields []*oneofSubField // All the possible oneof fields - comment string // The full comment for the field, e.g. "// Types that are valid to be assigned to MyOneof:\n\\" -} - -// decl prints the declaration of the field in the struct (if any). -func (f *oneofField) decl(g *Generator, mc *msgCtx) { - comment := f.comment - for _, sf := range f.subFields { - comment += "//\t*" + sf.oneofTypeName + "\n" - } - g.P(comment, Annotate(mc.message.file, f.fullPath, f.goName), " ", f.goType, " `", f.tags, "`") -} - -// getter for a oneof field will print additional discriminators and interfaces for the oneof, -// also it prints all the getters for the sub fields. -func (f *oneofField) getter(g *Generator, mc *msgCtx) { - // The discriminator type - g.P("type ", f.goType, " interface {") - g.P(f.goType, "()") - g.P("}") - g.P() - // The subField types, fulfilling the discriminator type contract - for _, sf := range f.subFields { - g.P("type ", Annotate(mc.message.file, sf.fullPath, sf.oneofTypeName), " struct {") - g.P(Annotate(mc.message.file, sf.fullPath, sf.goName), " ", sf.goType, " `", sf.tags, "`") - g.P("}") - g.P() - } - for _, sf := range f.subFields { - g.P("func (*", sf.oneofTypeName, ") ", f.goType, "() {}") - g.P() - } - // Getter for the oneof field - g.P("func (m *", mc.goName, ") ", Annotate(mc.message.file, f.fullPath, f.getterName), "() ", f.goType, " {") - g.P("if m != nil { return m.", f.goName, " }") - g.P("return nil") - g.P("}") - 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) - g.P("}") - g.P("return ", sf.getterDef) - g.P("}") - g.P() - } -} - -// setter prints the setter method of the field. -func (f *oneofField) setter(g *Generator, mc *msgCtx) { - // No setters for oneof yet -} - -// topLevelField interface implemented by all types of fields on the top level (not oneofSubField). -type topLevelField interface { - decl(g *Generator, mc *msgCtx) // print declaration within the struct - getter(g *Generator, mc *msgCtx) // print getter - setter(g *Generator, mc *msgCtx) // print setter if applicable -} - -// defField interface implemented by all types of fields that can have defaults (not oneofField, but instead oneofSubField). -type defField interface { - getProtoDef() string // default value explicitly stated in the proto file, e.g "yoshi" or "5" - getProtoName() string // proto name of a field, e.g. "field_name" or "descriptor" - getGoType() string // go type of the field as a string, e.g. "*int32" - getProtoTypeName() string // protobuf type name for the field, e.g. ".google.protobuf.Duration" - getProtoType() descriptor.FieldDescriptorProto_Type // *field.Type value, e.g. descriptor.FieldDescriptorProto_TYPE_FIXED64 -} - -// generateDefaultConstants adds constants for default values if needed, which is only if the default value is. -// explicit in the proto. -func (g *Generator) generateDefaultConstants(mc *msgCtx, topLevelFields []topLevelField) { - // Collect fields that can have defaults - dFields := []defField{} - for _, pf := range topLevelFields { - if f, ok := pf.(*oneofField); ok { - for _, osf := range f.subFields { - dFields = append(dFields, osf) - } - continue - } - dFields = append(dFields, pf.(defField)) - } - for _, df := range dFields { - def := df.getProtoDef() - if def == "" { - continue - } - fieldname := g.defaultConstantName(mc.goName, df.getProtoName()) - typename := df.getGoType() - if typename[0] == '*' { - typename = typename[1:] - } - kind := "const " - switch { - case typename == "bool": - case typename == "string": - def = strconv.Quote(def) - case typename == "[]byte": - def = "[]byte(" + strconv.Quote(unescape(def)) + ")" - kind = "var " - case def == "inf", def == "-inf", def == "nan": - // These names are known to, and defined by, the protocol language. - switch def { - case "inf": - def = "math.Inf(1)" - case "-inf": - def = "math.Inf(-1)" - case "nan": - def = "math.NaN()" - } - if df.getProtoType() == descriptor.FieldDescriptorProto_TYPE_FLOAT { - 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()) - var enum *EnumDescriptor - if id, ok := obj.(*ImportedDescriptor); ok { - // The enum type has been publicly imported. - enum, _ = id.o.(*EnumDescriptor) - } else { - enum, _ = obj.(*EnumDescriptor) - } - if enum == nil { - log.Printf("don't know how to generate constant for %s", fieldname) - continue - } - def = g.DefaultPackageName(obj) + enum.prefix() + def - } - g.P(kind, fieldname, " ", typename, " = ", def) - g.file.addExport(mc.message, constOrVarSymbol{fieldname, kind, ""}) - } - g.P() -} - -// generateInternalStructFields just adds the XXX_ fields to the message struct. -func (g *Generator) generateInternalStructFields(mc *msgCtx, topLevelFields []topLevelField) { - g.P("XXX_NoUnkeyedLiteral\tstruct{} `json:\"-\"`") // prevent unkeyed struct literals - if len(mc.message.ExtensionRange) > 0 { - messageset := "" - if opts := mc.message.Options; opts != nil && opts.GetMessageSetWireFormat() { - messageset = "protobuf_messageset:\"1\" " - } - g.P(g.Pkg["proto"], ".XXX_InternalExtensions `", messageset, "json:\"-\"`") - } - g.P("XXX_unrecognized\t[]byte `json:\"-\"`") - g.P("XXX_sizecache\tint32 `json:\"-\"`") - -} - -// generateOneofFuncs adds all the utility functions for oneof, including marshalling, unmarshalling and sizer. -func (g *Generator) generateOneofFuncs(mc *msgCtx, topLevelFields []topLevelField) { - ofields := []*oneofField{} - for _, f := range topLevelFields { - if o, ok := f.(*oneofField); ok { - ofields = append(ofields, o) - } - } - if len(ofields) == 0 { - return - } - - // OneofFuncs - 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) - } - } - g.P("}") - g.P("}") - g.P() -} - -// generateMessageStruct adds the actual struct with it's members (but not methods) to the output. -func (g *Generator) generateMessageStruct(mc *msgCtx, topLevelFields []topLevelField) { - comments := g.PrintComments(mc.message.path) - - // Guarantee deprecation comments appear after user-provided comments. - if mc.message.GetOptions().GetDeprecated() { - if comments { - // Convention: Separate deprecation comments from original - // comments with an empty line. - g.P("//") - } - g.P(deprecationComment) - } - - g.P("type ", Annotate(mc.message.file, mc.message.path, mc.goName), " struct {") - for _, pf := range topLevelFields { - pf.decl(g, mc) - } - g.generateInternalStructFields(mc, topLevelFields) - g.P("}") -} - -// generateGetters adds getters for all fields, including oneofs and weak fields when applicable. -func (g *Generator) generateGetters(mc *msgCtx, topLevelFields []topLevelField) { - for _, pf := range topLevelFields { - pf.getter(g, mc) - } -} - -// generateSetters add setters for all fields, including oneofs and weak fields when applicable. -func (g *Generator) generateSetters(mc *msgCtx, topLevelFields []topLevelField) { - for _, pf := range topLevelFields { - pf.setter(g, mc) - } -} - -// generateCommonMethods adds methods to the message that are not on a per field basis. -func (g *Generator) generateCommonMethods(mc *msgCtx) { - // Reset, String and ProtoMessage methods. - g.P("func (m *", mc.goName, ") Reset() { *m = ", mc.goName, "{} }") - g.P("func (m *", mc.goName, ") String() string { return ", g.Pkg["proto"], ".CompactTextString(m) }") - g.P("func (*", mc.goName, ") ProtoMessage() {}") - var indexes []string - for m := mc.message; m != nil; m = m.parent { - indexes = append([]string{strconv.Itoa(m.index)}, indexes...) - } - 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 { - g.P() - g.P("var extRange_", mc.goName, " = []", g.Pkg["proto"], ".ExtensionRange{") - for _, r := range mc.message.ExtensionRange { - end := fmt.Sprint(*r.End - 1) // make range inclusive on both ends - g.P("{Start: ", r.Start, ", End: ", end, "},") - } - g.P("}") - 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 - // operation on protos that we want to switch over to using the - // table-driven approach. Instead, we should only add a single method - // that allows getting access to the *InternalMessageInfo struct and then - // calling Unmarshal, Marshal, Merge, Size, and Discard directly on that. - - // Wrapper for table-driven marshaling and unmarshaling. - g.P("func (m *", mc.goName, ") XXX_Unmarshal(b []byte) error {") - g.P("return xxx_messageInfo_", mc.goName, ".Unmarshal(m, b)") - g.P("}") - - g.P("func (m *", mc.goName, ") XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {") - g.P("return xxx_messageInfo_", mc.goName, ".Marshal(b, m, deterministic)") - g.P("}") - - 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 - g.P("return xxx_messageInfo_", mc.goName, ".Size(m)") - g.P("}") - - g.P("func (m *", mc.goName, ") XXX_DiscardUnknown() {") - g.P("xxx_messageInfo_", mc.goName, ".DiscardUnknown(m)") - g.P("}") - - g.P("var xxx_messageInfo_", mc.goName, " ", g.Pkg["proto"], ".InternalMessageInfo") - g.P() -} - -// Generate the type, methods and default constant definitions for this Descriptor. -func (g *Generator) generateMessage(message *Descriptor) { - topLevelFields := []topLevelField{} - oFields := make(map[int32]*oneofField) - // The full type name - typeName := message.TypeName() - // The full type name, CamelCased. - goTypeName := CamelCaseSlice(typeName) - - usedNames := make(map[string]bool) - for _, n := range methodNames { - usedNames[n] = true - } - - // allocNames finds a conflict-free variation of the given strings, - // consistently mutating their suffixes. - // It returns the same number of strings. - allocNames := func(ns ...string) []string { - Loop: - for { - for _, n := range ns { - if usedNames[n] { - for i := range ns { - ns[i] += "_" - } - continue Loop - } - } - for _, n := range ns { - usedNames[n] = true - } - return ns - } - } - - mapFieldTypes := make(map[*descriptor.FieldDescriptorProto]string) // keep track of the map fields to be added later - - // Build a structure more suitable for generating the text in one pass - for i, field := range message.Field { - // Allocate the getter and the field at the same time so name - // collisions create field/method consistent names. - // TODO: This allocation occurs based on the order of the fields - // in the proto file, meaning that a change in the field - // ordering can change generated Method/Field names. - base := CamelCase(*field.Name) - ns := allocNames(base, "Get"+base) - fieldName, fieldGetterName := ns[0], ns[1] - typename, wiretype := g.GoType(message, field) - jsonName := *field.Name - tag := fmt.Sprintf("protobuf:%s json:%q", g.goTag(message, field, wiretype), jsonName+",omitempty") - - oneof := field.OneofIndex != nil - if oneof && oFields[*field.OneofIndex] == nil { - odp := message.OneofDecl[int(*field.OneofIndex)] - base := CamelCase(odp.GetName()) - fname := allocNames(base)[0] - - // This is the first field of a oneof we haven't seen before. - // Generate the union field. - oneofFullPath := fmt.Sprintf("%s,%d,%d", message.path, messageOneofPath, *field.OneofIndex) - c, ok := g.makeComments(oneofFullPath) - if ok { - c += "\n//\n" - } - c += "// Types that are valid to be assigned to " + fname + ":\n" - // Generate the rest of this comment later, - // when we've computed any disambiguation. - - dname := "is" + goTypeName + "_" + fname - tag := `protobuf_oneof:"` + odp.GetName() + `"` - of := oneofField{ - fieldCommon: fieldCommon{ - goName: fname, - getterName: "Get"+fname, - goType: dname, - tags: tag, - protoName: odp.GetName(), - fullPath: oneofFullPath, - }, - comment: c, - } - topLevelFields = append(topLevelFields, &of) - oFields[*field.OneofIndex] = &of - } - - if *field.Type == descriptor.FieldDescriptorProto_TYPE_MESSAGE { - desc := g.ObjectNamed(field.GetTypeName()) - if d, ok := desc.(*Descriptor); ok && d.GetOptions().GetMapEntry() { - // Figure out the Go types and tags for the key and value types. - keyField, valField := d.Field[0], d.Field[1] - keyType, keyWire := g.GoType(d, keyField) - valType, valWire := g.GoType(d, valField) - keyTag, valTag := g.goTag(d, keyField, keyWire), g.goTag(d, valField, valWire) - - // We don't use stars, except for message-typed values. - // Message and enum types are the only two possibly foreign types used in maps, - // so record their use. They are not permitted as map keys. - keyType = strings.TrimPrefix(keyType, "*") - switch *valField.Type { - case descriptor.FieldDescriptorProto_TYPE_ENUM: - valType = strings.TrimPrefix(valType, "*") - g.RecordTypeUse(valField.GetTypeName()) - case descriptor.FieldDescriptorProto_TYPE_MESSAGE: - g.RecordTypeUse(valField.GetTypeName()) - default: - valType = strings.TrimPrefix(valType, "*") - } - - typename = fmt.Sprintf("map[%s]%s", keyType, valType) - mapFieldTypes[field] = typename // record for the getter generation - - tag += fmt.Sprintf(" protobuf_key:%s protobuf_val:%s", keyTag, valTag) - } - } - - fieldDeprecated := "" - if field.GetOptions().GetDeprecated() { - fieldDeprecated = deprecationComment - } - - dvalue := g.getterDefault(field, goTypeName) - if oneof { - tname := goTypeName + "_" + fieldName - // It is possible for this to collide with a message or enum - // nested in this message. Check for collisions. - for { - ok := true - for _, desc := range message.nested { - if CamelCaseSlice(desc.TypeName()) == tname { - ok = false - break - } - } - for _, enum := range message.enums { - if CamelCaseSlice(enum.TypeName()) == tname { - ok = false - break - } - } - if !ok { - tname += "_" - continue - } - break - } - - oneofField := oFields[*field.OneofIndex] - tag := "protobuf:" + g.goTag(message, field, wiretype) - sf := oneofSubField{ - fieldCommon: fieldCommon{ - goName: fieldName, - getterName: fieldGetterName, - goType: typename, - tags: tag, - protoName: field.GetName(), - fullPath: fmt.Sprintf("%s,%d,%d", message.path, messageFieldPath, i), - }, - protoTypeName: field.GetTypeName(), - fieldNumber: int(*field.Number), - protoType: *field.Type, - getterDef: dvalue, - protoDef: field.GetDefaultValue(), - oneofTypeName: tname, - deprecated: fieldDeprecated, - } - oneofField.subFields = append(oneofField.subFields, &sf) - g.RecordTypeUse(field.GetTypeName()) - continue - } - - fieldFullPath := fmt.Sprintf("%s,%d,%d", message.path, messageFieldPath, i) - c, ok := g.makeComments(fieldFullPath) - if ok { - c += "\n" - } - rf := simpleField{ - fieldCommon: fieldCommon{ - goName: fieldName, - getterName: fieldGetterName, - goType: typename, - tags: tag, - protoName: field.GetName(), - fullPath: fieldFullPath, - }, - protoTypeName: field.GetTypeName(), - protoType: *field.Type, - deprecated: fieldDeprecated, - getterDef: dvalue, - protoDef: field.GetDefaultValue(), - comment: c, - } - var pf topLevelField = &rf - - topLevelFields = append(topLevelFields, pf) - g.RecordTypeUse(field.GetTypeName()) - } - - mc := &msgCtx{ - goName: goTypeName, - message: message, - } - - g.generateMessageStruct(mc, topLevelFields) - g.P() - g.generateCommonMethods(mc) - g.P() - g.generateDefaultConstants(mc, topLevelFields) - g.P() - g.generateGetters(mc, topLevelFields) - g.P() - g.generateSetters(mc, topLevelFields) - g.P() - g.generateOneofFuncs(mc, topLevelFields) - g.P() - - 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) - - for _, ext := range message.ext { - g.generateExtension(ext) - } - - fullName := strings.Join(message.TypeName(), ".") - if g.file.Package != nil { - fullName = *g.file.Package + "." + fullName - } - - g.addInitf("%s.RegisterType((*%s)(nil), %q)", g.Pkg["proto"], goTypeName, fullName) - // Register types for native map types. - for _, k := range mapFieldKeys(mapFieldTypes) { - fullName := strings.TrimPrefix(*k.TypeName, ".") - g.addInitf("%s.RegisterMapType((%s)(nil), %q)", g.Pkg["proto"], mapFieldTypes[k], fullName) - } - -} - -type byTypeName []*descriptor.FieldDescriptorProto - -func (a byTypeName) Len() int { return len(a) } -func (a byTypeName) Swap(i, j int) { a[i], a[j] = a[j], a[i] } -func (a byTypeName) Less(i, j int) bool { return *a[i].TypeName < *a[j].TypeName } - -// mapFieldKeys returns the keys of m in a consistent order. -func mapFieldKeys(m map[*descriptor.FieldDescriptorProto]string) []*descriptor.FieldDescriptorProto { - keys := make([]*descriptor.FieldDescriptorProto, 0, len(m)) - for k := range m { - keys = append(keys, k) - } - sort.Sort(byTypeName(keys)) - return keys -} - -var escapeChars = [256]byte{ - 'a': '\a', 'b': '\b', 'f': '\f', 'n': '\n', 'r': '\r', 't': '\t', 'v': '\v', '\\': '\\', '"': '"', '\'': '\'', '?': '?', -} - -// unescape reverses the "C" escaping that protoc does for default values of bytes fields. -// It is best effort in that it effectively ignores malformed input. Seemingly invalid escape -// sequences are conveyed, unmodified, into the decoded result. -func unescape(s string) string { - // NB: Sadly, we can't use strconv.Unquote because protoc will escape both - // single and double quotes, but strconv.Unquote only allows one or the - // other (based on actual surrounding quotes of its input argument). - - var out []byte - for len(s) > 0 { - // regular character, or too short to be valid escape - if s[0] != '\\' || len(s) < 2 { - out = append(out, s[0]) - s = s[1:] - } else if c := escapeChars[s[1]]; c != 0 { - // escape sequence - out = append(out, c) - s = s[2:] - } else if s[1] == 'x' || s[1] == 'X' { - // hex escape, e.g. "\x80 - if len(s) < 4 { - // too short to be valid - out = append(out, s[:2]...) - s = s[2:] - continue - } - v, err := strconv.ParseUint(s[2:4], 16, 8) - if err != nil { - out = append(out, s[:4]...) - } else { - out = append(out, byte(v)) - } - s = s[4:] - } else if '0' <= s[1] && s[1] <= '7' { - // octal escape, can vary from 1 to 3 octal digits; e.g., "\0" "\40" or "\164" - // so consume up to 2 more bytes or up to end-of-string - n := len(s[1:]) - len(strings.TrimLeft(s[1:], "01234567")) - if n > 3 { - n = 3 - } - v, err := strconv.ParseUint(s[1:1+n], 8, 8) - if err != nil { - out = append(out, s[:1+n]...) - } else { - out = append(out, byte(v)) - } - s = s[1+n:] - } else { - // bad escape, just propagate the slash as-is - out = append(out, s[0]) - s = s[1:] - } - } - - return string(out) -} - -func (g *Generator) generateExtension(ext *ExtensionDescriptor) { - ccTypeName := ext.DescName() - - extObj := g.ObjectNamed(*ext.Extendee) - var extDesc *Descriptor - if id, ok := extObj.(*ImportedDescriptor); ok { - // This is extending a publicly imported message. - // We need the underlying type for goTag. - extDesc = id.o.(*Descriptor) - } else { - extDesc = extObj.(*Descriptor) - } - extendedType := "*" + g.TypeName(extObj) // always use the original - field := ext.FieldDescriptorProto - fieldType, wireType := g.GoType(ext.parent, field) - tag := g.goTag(extDesc, field, wireType) - g.RecordTypeUse(*ext.Extendee) - if n := ext.FieldDescriptorProto.TypeName; n != nil { - // foreign extension type - g.RecordTypeUse(*n) - } - - typeName := ext.TypeName() - - // Special case for proto2 message sets: If this extension is extending - // proto2.bridge.MessageSet, and its final name component is "message_set_extension", - // then drop that last component. - // - // TODO: This should be implemented in the text formatter rather than the generator. - // 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 - if extDesc.GetOptions().GetMessageSetWireFormat() && typeName[len(typeName)-1] == "message_set_extension" { - typeName = typeName[:len(typeName)-1] - } - - // For text formatting, the package must be exactly what the .proto file declares, - // ignoring overrides such as the go_package option, and with no dot/underscore mapping. - extName := strings.Join(typeName, ".") - if g.file.Package != nil { - extName = *g.file.Package + "." + extName - } - - g.P("var ", ccTypeName, " = &", g.Pkg["proto"], ".ExtensionDesc{") - g.P("ExtendedType: (", extendedType, ")(nil),") - g.P("ExtensionType: (", fieldType, ")(nil),") - g.P("Field: ", field.Number, ",") - g.P(`Name: "`, extName, `",`) - g.P("Tag: ", tag, ",") - g.P(`Filename: "`, g.file.GetName(), `",`) - - g.P("}") - g.P() - - g.addInitf("%s.RegisterExtension(%s)", g.Pkg["proto"], ext.DescName()) - - g.file.addExport(ext, constOrVarSymbol{ccTypeName, "var", ""}) -} - -func (g *Generator) generateInitFunction() { - if len(g.init) == 0 { - return - } - g.P("func init() {") - for _, l := range g.init { - g.P(l) - } - g.P("}") - g.init = nil -} - -func (g *Generator) generateFileDescriptor(file *FileDescriptor) { - // Make a copy and trim source_code_info data. - // TODO: Trim this more when we know exactly what we need. - pb := proto.Clone(file.FileDescriptorProto).(*descriptor.FileDescriptorProto) - pb.SourceCodeInfo = nil - - b, err := proto.Marshal(pb) - if err != nil { - g.Fail(err.Error()) - } - - var buf bytes.Buffer - w, _ := gzip.NewWriterLevel(&buf, gzip.BestCompression) - w.Write(b) - w.Close() - b = buf.Bytes() - - v := file.VarName() - g.P() - g.P("func init() { ", g.Pkg["proto"], ".RegisterFile(", strconv.Quote(*file.Name), ", ", v, ") }") - g.P("var ", v, " = []byte{") - g.P("// ", len(b), " bytes of a gzipped FileDescriptorProto") - for len(b) > 0 { - n := 16 - if n > len(b) { - n = len(b) - } - - s := "" - for _, c := range b[:n] { - s += fmt.Sprintf("0x%02x,", c) - } - g.P(s) - - b = b[n:] - } - g.P("}") -} - -func (g *Generator) generateEnumRegistration(enum *EnumDescriptor) { - // // We always print the full (proto-world) package name here. - pkg := enum.File().GetPackage() - if pkg != "" { - pkg += "." - } - // The full type name - typeName := enum.TypeName() - // The full type name, CamelCased. - ccTypeName := CamelCaseSlice(typeName) - g.addInitf("%s.RegisterEnum(%q, %[3]s_name, %[3]s_value)", g.Pkg["proto"], pkg+ccTypeName, ccTypeName) -} - -// And now lots of helper functions. - -// Is c an ASCII lower-case letter? -func isASCIILower(c byte) bool { - return 'a' <= c && c <= 'z' -} - -// Is c an ASCII digit? -func isASCIIDigit(c byte) bool { - return '0' <= c && c <= '9' -} - -// CamelCase returns the CamelCased name. -// If there is an interior underscore followed by a lower case letter, -// drop the underscore and convert the letter to upper case. -// There is a remote possibility of this rewrite causing a name collision, -// but it's so remote we're prepared to pretend it's nonexistent - since the -// C++ generator lowercases names, it's extremely unlikely to have two fields -// with different capitalizations. -// In short, _my_field_name_2 becomes XMyFieldName_2. -func CamelCase(s string) string { - if s == "" { - return "" - } - t := make([]byte, 0, 32) - i := 0 - if s[0] == '_' { - // Need a capital letter; drop the '_'. - t = append(t, 'X') - i++ - } - // Invariant: if the next letter is lower case, it must be converted - // to upper case. - // That is, we process a word at a time, where words are marked by _ or - // upper case letter. Digits are treated as words. - for ; i < len(s); i++ { - c := s[i] - if c == '_' && i+1 < len(s) && isASCIILower(s[i+1]) { - continue // Skip the underscore in s. - } - if isASCIIDigit(c) { - t = append(t, c) - continue - } - // Assume we have a letter now - if not, it's a bogus identifier. - // The next word is a sequence of characters that must start upper case. - if isASCIILower(c) { - c ^= ' ' // Make it a capital letter. - } - t = append(t, c) // Guaranteed not lower case. - // Accept lower case sequence that follows. - for i+1 < len(s) && isASCIILower(s[i+1]) { - i++ - t = append(t, s[i]) - } - } - return string(t) -} - -// CamelCaseSlice is like CamelCase, but the argument is a slice of strings to -// be joined with "_". -func CamelCaseSlice(elem []string) string { return CamelCase(strings.Join(elem, "_")) } - -// dottedSlice turns a sliced name into a dotted name. -func dottedSlice(elem []string) string { return strings.Join(elem, ".") } - -// Is this field optional? -func isOptional(field *descriptor.FieldDescriptorProto) bool { - return field.Label != nil && *field.Label == descriptor.FieldDescriptorProto_LABEL_OPTIONAL -} - -// Is this field required? -func isRequired(field *descriptor.FieldDescriptorProto) bool { - return field.Label != nil && *field.Label == descriptor.FieldDescriptorProto_LABEL_REQUIRED -} - -// Is this field repeated? -func isRepeated(field *descriptor.FieldDescriptorProto) bool { - return field.Label != nil && *field.Label == descriptor.FieldDescriptorProto_LABEL_REPEATED -} - -// Is this field a scalar numeric type? -func isScalar(field *descriptor.FieldDescriptorProto) bool { - if field.Type == nil { - return false - } - switch *field.Type { - case descriptor.FieldDescriptorProto_TYPE_DOUBLE, - descriptor.FieldDescriptorProto_TYPE_FLOAT, - descriptor.FieldDescriptorProto_TYPE_INT64, - descriptor.FieldDescriptorProto_TYPE_UINT64, - descriptor.FieldDescriptorProto_TYPE_INT32, - descriptor.FieldDescriptorProto_TYPE_FIXED64, - descriptor.FieldDescriptorProto_TYPE_FIXED32, - descriptor.FieldDescriptorProto_TYPE_BOOL, - descriptor.FieldDescriptorProto_TYPE_UINT32, - descriptor.FieldDescriptorProto_TYPE_ENUM, - descriptor.FieldDescriptorProto_TYPE_SFIXED32, - descriptor.FieldDescriptorProto_TYPE_SFIXED64, - descriptor.FieldDescriptorProto_TYPE_SINT32, - descriptor.FieldDescriptorProto_TYPE_SINT64: - return true - default: - return false - } -} - -// badToUnderscore is the mapping function used to generate Go names from package names, -// which can be dotted in the input .proto file. It replaces non-identifier characters such as -// dot or dash with underscore. -func badToUnderscore(r rune) rune { - if unicode.IsLetter(r) || unicode.IsDigit(r) || r == '_' { - return r - } - return '_' -} - -// baseName returns the last path element of the name, with the last dotted suffix removed. -func baseName(name string) string { - // First, find the last element - if i := strings.LastIndex(name, "/"); i >= 0 { - name = name[i+1:] - } - // Now drop the suffix - if i := strings.LastIndex(name, "."); i >= 0 { - name = name[0:i] - } - return name -} - -// The SourceCodeInfo message describes the location of elements of a parsed -// .proto file by way of a "path", which is a sequence of integers that -// describe the route from a FileDescriptorProto to the relevant submessage. -// The path alternates between a field number of a repeated field, and an index -// into that repeated field. The constants below define the field numbers that -// are used. -// -// See descriptor.proto for more information about this. -const ( - // tag numbers in FileDescriptorProto - packagePath = 2 // package - messagePath = 4 // message_type - enumPath = 5 // enum_type - // tag numbers in DescriptorProto - messageFieldPath = 2 // field - messageMessagePath = 3 // nested_type - messageEnumPath = 4 // enum_type - messageOneofPath = 8 // oneof_decl - // tag numbers in EnumDescriptorProto - enumValuePath = 2 // value -) - -var supportTypeAliases bool - -func init() { - for _, tag := range build.Default.ReleaseTags { - if tag == "go1.9" { - supportTypeAliases = true - return - } - } -} diff --git a/vendor/github.com/golang/protobuf/protoc-gen-go/generator/internal/remap/remap.go b/vendor/github.com/golang/protobuf/protoc-gen-go/generator/internal/remap/remap.go deleted file mode 100644 index a9b61036cc0f23fb1cba74b35a9c2a9c9b95f68f..0000000000000000000000000000000000000000 --- a/vendor/github.com/golang/protobuf/protoc-gen-go/generator/internal/remap/remap.go +++ /dev/null @@ -1,117 +0,0 @@ -// Go support for Protocol Buffers - Google's data interchange format -// -// Copyright 2017 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 remap handles tracking the locations of Go tokens in a source text -across a rewrite by the Go formatter. -*/ -package remap - -import ( - "fmt" - "go/scanner" - "go/token" -) - -// A Location represents a span of byte offsets in the source text. -type Location struct { - Pos, End int // End is exclusive -} - -// A Map represents a mapping between token locations in an input source text -// and locations in the correspnding output text. -type Map map[Location]Location - -// Find reports whether the specified span is recorded by m, and if so returns -// the new location it was mapped to. If the input span was not found, the -// returned location is the same as the input. -func (m Map) Find(pos, end int) (Location, bool) { - key := Location{ - Pos: pos, - End: end, - } - if loc, ok := m[key]; ok { - return loc, true - } - return key, false -} - -func (m Map) add(opos, oend, npos, nend int) { - m[Location{Pos: opos, End: oend}] = Location{Pos: npos, End: nend} -} - -// Compute constructs a location mapping from input to output. An error is -// reported if any of the tokens of output cannot be mapped. -func Compute(input, output []byte) (Map, error) { - itok := tokenize(input) - otok := tokenize(output) - if len(itok) != len(otok) { - return nil, fmt.Errorf("wrong number of tokens, %d ≠ %d", len(itok), len(otok)) - } - m := make(Map) - for i, ti := range itok { - to := otok[i] - if ti.Token != to.Token { - return nil, fmt.Errorf("token %d type mismatch: %s ≠ %s", i+1, ti, to) - } - m.add(ti.pos, ti.end, to.pos, to.end) - } - return m, nil -} - -// tokinfo records the span and type of a source token. -type tokinfo struct { - pos, end int - token.Token -} - -func tokenize(src []byte) []tokinfo { - fs := token.NewFileSet() - var s scanner.Scanner - s.Init(fs.AddFile("src", fs.Base(), len(src)), src, nil, scanner.ScanComments) - var info []tokinfo - for { - pos, next, lit := s.Scan() - switch next { - case token.SEMICOLON: - continue - } - info = append(info, tokinfo{ - pos: int(pos - 1), - end: int(pos + token.Pos(len(lit)) - 1), - Token: next, - }) - if next == token.EOF { - break - } - } - return info -} diff --git a/vendor/github.com/golang/protobuf/protoc-gen-go/plugin/plugin.pb.go b/vendor/github.com/golang/protobuf/protoc-gen-go/plugin/plugin.pb.go deleted file mode 100644 index 61bfc10e02e7cd626dc18c29c2bcc2f5b79bf454..0000000000000000000000000000000000000000 --- a/vendor/github.com/golang/protobuf/protoc-gen-go/plugin/plugin.pb.go +++ /dev/null @@ -1,369 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// source: google/protobuf/compiler/plugin.proto - -/* -Package plugin_go is a generated protocol buffer package. - -It is generated from these files: - google/protobuf/compiler/plugin.proto - -It has these top-level messages: - Version - CodeGeneratorRequest - CodeGeneratorResponse -*/ -package plugin_go - -import proto "github.com/golang/protobuf/proto" -import fmt "fmt" -import math "math" -import google_protobuf "github.com/golang/protobuf/protoc-gen-go/descriptor" - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// 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 - -// The version number of protocol compiler. -type Version struct { - Major *int32 `protobuf:"varint,1,opt,name=major" json:"major,omitempty"` - Minor *int32 `protobuf:"varint,2,opt,name=minor" json:"minor,omitempty"` - Patch *int32 `protobuf:"varint,3,opt,name=patch" json:"patch,omitempty"` - // A suffix for alpha, beta or rc release, e.g., "alpha-1", "rc2". It should - // be empty for mainline stable releases. - Suffix *string `protobuf:"bytes,4,opt,name=suffix" json:"suffix,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *Version) Reset() { *m = Version{} } -func (m *Version) String() string { return proto.CompactTextString(m) } -func (*Version) ProtoMessage() {} -func (*Version) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} } -func (m *Version) Unmarshal(b []byte) error { - return xxx_messageInfo_Version.Unmarshal(m, b) -} -func (m *Version) Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_Version.Marshal(b, m, deterministic) -} -func (dst *Version) XXX_Merge(src proto.Message) { - xxx_messageInfo_Version.Merge(dst, src) -} -func (m *Version) XXX_Size() int { - return xxx_messageInfo_Version.Size(m) -} -func (m *Version) XXX_DiscardUnknown() { - xxx_messageInfo_Version.DiscardUnknown(m) -} - -var xxx_messageInfo_Version proto.InternalMessageInfo - -func (m *Version) GetMajor() int32 { - if m != nil && m.Major != nil { - return *m.Major - } - return 0 -} - -func (m *Version) GetMinor() int32 { - if m != nil && m.Minor != nil { - return *m.Minor - } - return 0 -} - -func (m *Version) GetPatch() int32 { - if m != nil && m.Patch != nil { - return *m.Patch - } - return 0 -} - -func (m *Version) GetSuffix() string { - if m != nil && m.Suffix != nil { - return *m.Suffix - } - return "" -} - -// An encoded CodeGeneratorRequest is written to the plugin's stdin. -type CodeGeneratorRequest struct { - // The .proto files that were explicitly listed on the command-line. The - // code generator should generate code only for these files. Each file's - // descriptor will be included in proto_file, below. - FileToGenerate []string `protobuf:"bytes,1,rep,name=file_to_generate,json=fileToGenerate" json:"file_to_generate,omitempty"` - // The generator parameter passed on the command-line. - Parameter *string `protobuf:"bytes,2,opt,name=parameter" json:"parameter,omitempty"` - // FileDescriptorProtos for all files in files_to_generate and everything - // they import. The files will appear in topological order, so each file - // appears before any file that imports it. - // - // protoc guarantees that all proto_files will be written after - // the fields above, even though this is not technically guaranteed by the - // protobuf wire format. This theoretically could allow a plugin to stream - // in the FileDescriptorProtos and handle them one by one rather than read - // the entire set into memory at once. However, as of this writing, this - // is not similarly optimized on protoc's end -- it will store all fields in - // memory at once before sending them to the plugin. - // - // Type names of fields and extensions in the FileDescriptorProto are always - // fully qualified. - ProtoFile []*google_protobuf.FileDescriptorProto `protobuf:"bytes,15,rep,name=proto_file,json=protoFile" json:"proto_file,omitempty"` - // The version number of protocol compiler. - CompilerVersion *Version `protobuf:"bytes,3,opt,name=compiler_version,json=compilerVersion" json:"compiler_version,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *CodeGeneratorRequest) Reset() { *m = CodeGeneratorRequest{} } -func (m *CodeGeneratorRequest) String() string { return proto.CompactTextString(m) } -func (*CodeGeneratorRequest) ProtoMessage() {} -func (*CodeGeneratorRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} } -func (m *CodeGeneratorRequest) Unmarshal(b []byte) error { - return xxx_messageInfo_CodeGeneratorRequest.Unmarshal(m, b) -} -func (m *CodeGeneratorRequest) Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_CodeGeneratorRequest.Marshal(b, m, deterministic) -} -func (dst *CodeGeneratorRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_CodeGeneratorRequest.Merge(dst, src) -} -func (m *CodeGeneratorRequest) XXX_Size() int { - return xxx_messageInfo_CodeGeneratorRequest.Size(m) -} -func (m *CodeGeneratorRequest) XXX_DiscardUnknown() { - xxx_messageInfo_CodeGeneratorRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_CodeGeneratorRequest proto.InternalMessageInfo - -func (m *CodeGeneratorRequest) GetFileToGenerate() []string { - if m != nil { - return m.FileToGenerate - } - return nil -} - -func (m *CodeGeneratorRequest) GetParameter() string { - if m != nil && m.Parameter != nil { - return *m.Parameter - } - return "" -} - -func (m *CodeGeneratorRequest) GetProtoFile() []*google_protobuf.FileDescriptorProto { - if m != nil { - return m.ProtoFile - } - return nil -} - -func (m *CodeGeneratorRequest) GetCompilerVersion() *Version { - if m != nil { - return m.CompilerVersion - } - return nil -} - -// The plugin writes an encoded CodeGeneratorResponse to stdout. -type CodeGeneratorResponse struct { - // Error message. If non-empty, code generation failed. The plugin process - // should exit with status code zero even if it reports an error in this way. - // - // This should be used to indicate errors in .proto files which prevent the - // code generator from generating correct code. Errors which indicate a - // problem in protoc itself -- such as the input CodeGeneratorRequest being - // unparseable -- should be reported by writing a message to stderr and - // exiting with a non-zero status code. - Error *string `protobuf:"bytes,1,opt,name=error" json:"error,omitempty"` - File []*CodeGeneratorResponse_File `protobuf:"bytes,15,rep,name=file" json:"file,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *CodeGeneratorResponse) Reset() { *m = CodeGeneratorResponse{} } -func (m *CodeGeneratorResponse) String() string { return proto.CompactTextString(m) } -func (*CodeGeneratorResponse) ProtoMessage() {} -func (*CodeGeneratorResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} } -func (m *CodeGeneratorResponse) Unmarshal(b []byte) error { - return xxx_messageInfo_CodeGeneratorResponse.Unmarshal(m, b) -} -func (m *CodeGeneratorResponse) Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_CodeGeneratorResponse.Marshal(b, m, deterministic) -} -func (dst *CodeGeneratorResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_CodeGeneratorResponse.Merge(dst, src) -} -func (m *CodeGeneratorResponse) XXX_Size() int { - return xxx_messageInfo_CodeGeneratorResponse.Size(m) -} -func (m *CodeGeneratorResponse) XXX_DiscardUnknown() { - xxx_messageInfo_CodeGeneratorResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_CodeGeneratorResponse proto.InternalMessageInfo - -func (m *CodeGeneratorResponse) GetError() string { - if m != nil && m.Error != nil { - return *m.Error - } - return "" -} - -func (m *CodeGeneratorResponse) GetFile() []*CodeGeneratorResponse_File { - if m != nil { - return m.File - } - return nil -} - -// Represents a single generated file. -type CodeGeneratorResponse_File struct { - // The file name, relative to the output directory. The name must not - // contain "." or ".." components and must be relative, not be absolute (so, - // the file cannot lie outside the output directory). "/" must be used as - // the path separator, not "\". - // - // If the name is omitted, the content will be appended to the previous - // file. This allows the generator to break large files into small chunks, - // and allows the generated text to be streamed back to protoc so that large - // files need not reside completely in memory at one time. Note that as of - // this writing protoc does not optimize for this -- it will read the entire - // CodeGeneratorResponse before writing files to disk. - Name *string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` - // If non-empty, indicates that the named file should already exist, and the - // content here is to be inserted into that file at a defined insertion - // point. This feature allows a code generator to extend the output - // produced by another code generator. The original generator may provide - // insertion points by placing special annotations in the file that look - // like: - // @@protoc_insertion_point(NAME) - // The annotation can have arbitrary text before and after it on the line, - // which allows it to be placed in a comment. NAME should be replaced with - // an identifier naming the point -- this is what other generators will use - // as the insertion_point. Code inserted at this point will be placed - // immediately above the line containing the insertion point (thus multiple - // insertions to the same point will come out in the order they were added). - // The double-@ is intended to make it unlikely that the generated code - // could contain things that look like insertion points by accident. - // - // For example, the C++ code generator places the following line in the - // .pb.h files that it generates: - // // @@protoc_insertion_point(namespace_scope) - // This line appears within the scope of the file's package namespace, but - // outside of any particular class. Another plugin can then specify the - // insertion_point "namespace_scope" to generate additional classes or - // other declarations that should be placed in this scope. - // - // Note that if the line containing the insertion point begins with - // whitespace, the same whitespace will be added to every line of the - // inserted text. This is useful for languages like Python, where - // indentation matters. In these languages, the insertion point comment - // should be indented the same amount as any inserted code will need to be - // in order to work correctly in that context. - // - // The code generator that generates the initial file and the one which - // inserts into it must both run as part of a single invocation of protoc. - // Code generators are executed in the order in which they appear on the - // command line. - // - // If |insertion_point| is present, |name| must also be present. - InsertionPoint *string `protobuf:"bytes,2,opt,name=insertion_point,json=insertionPoint" json:"insertion_point,omitempty"` - // The file contents. - Content *string `protobuf:"bytes,15,opt,name=content" json:"content,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *CodeGeneratorResponse_File) Reset() { *m = CodeGeneratorResponse_File{} } -func (m *CodeGeneratorResponse_File) String() string { return proto.CompactTextString(m) } -func (*CodeGeneratorResponse_File) ProtoMessage() {} -func (*CodeGeneratorResponse_File) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2, 0} } -func (m *CodeGeneratorResponse_File) Unmarshal(b []byte) error { - return xxx_messageInfo_CodeGeneratorResponse_File.Unmarshal(m, b) -} -func (m *CodeGeneratorResponse_File) Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_CodeGeneratorResponse_File.Marshal(b, m, deterministic) -} -func (dst *CodeGeneratorResponse_File) XXX_Merge(src proto.Message) { - xxx_messageInfo_CodeGeneratorResponse_File.Merge(dst, src) -} -func (m *CodeGeneratorResponse_File) XXX_Size() int { - return xxx_messageInfo_CodeGeneratorResponse_File.Size(m) -} -func (m *CodeGeneratorResponse_File) XXX_DiscardUnknown() { - xxx_messageInfo_CodeGeneratorResponse_File.DiscardUnknown(m) -} - -var xxx_messageInfo_CodeGeneratorResponse_File proto.InternalMessageInfo - -func (m *CodeGeneratorResponse_File) GetName() string { - if m != nil && m.Name != nil { - return *m.Name - } - return "" -} - -func (m *CodeGeneratorResponse_File) GetInsertionPoint() string { - if m != nil && m.InsertionPoint != nil { - return *m.InsertionPoint - } - return "" -} - -func (m *CodeGeneratorResponse_File) GetContent() string { - if m != nil && m.Content != nil { - return *m.Content - } - return "" -} - -func init() { - proto.RegisterType((*Version)(nil), "google.protobuf.compiler.Version") - proto.RegisterType((*CodeGeneratorRequest)(nil), "google.protobuf.compiler.CodeGeneratorRequest") - proto.RegisterType((*CodeGeneratorResponse)(nil), "google.protobuf.compiler.CodeGeneratorResponse") - proto.RegisterType((*CodeGeneratorResponse_File)(nil), "google.protobuf.compiler.CodeGeneratorResponse.File") -} - -func init() { proto.RegisterFile("google/protobuf/compiler/plugin.proto", fileDescriptor0) } - -var fileDescriptor0 = []byte{ - // 417 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x92, 0xcf, 0x6a, 0x14, 0x41, - 0x10, 0xc6, 0x19, 0x77, 0x63, 0x98, 0x8a, 0x64, 0x43, 0x13, 0xa5, 0x09, 0x39, 0x8c, 0x8b, 0xe2, - 0x5c, 0x32, 0x0b, 0xc1, 0x8b, 0x78, 0x4b, 0x44, 0x3d, 0x78, 0x58, 0x1a, 0xf1, 0x20, 0xc8, 0x30, - 0x99, 0xd4, 0x74, 0x5a, 0x66, 0xba, 0xc6, 0xee, 0x1e, 0xf1, 0x49, 0x7d, 0x0f, 0xdf, 0x40, 0xfa, - 0xcf, 0x24, 0xb2, 0xb8, 0xa7, 0xee, 0xef, 0x57, 0xd5, 0xd5, 0x55, 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d, - 0x84, 0x7d, 0x82, 0x93, 0xd9, 0xb8, 0xfa, 0x67, 0xf4, 0x24, 0x8c, 0x77, 0x74, 0xf9, 0xbc, 0xda, - 0xe7, 0x70, 0x95, 0xcc, 0x13, 0xab, 0x99, 0x24, 0xb0, 0xfe, 0x9d, 0xc1, 0xd3, 0x9d, 0x99, 0xed, - 0x48, 0xda, 0xa2, 0xf7, 0x0e, 0x8d, 0x49, 0x3e, 0xe7, 0x22, 0x0a, 0xf6, 0x11, 0x96, 0xff, 0x34, - 0xff, 0x7a, 0xff, 0x8f, 0xff, 0x2d, 0x1a, 0x66, 0x13, 0xa1, 0xc2, 0xd9, 0x37, 0x58, 0x86, 0x79, - 0x18, 0x2c, 0x75, 0x33, 0x60, 0xfa, 0x26, 0xdc, 0xd9, 0x2b, 0x58, 0x29, 0x6d, 0xd1, 0x38, 0x45, - 0xba, 0x1e, 0x49, 0x69, 0x97, 0xcc, 0x3c, 0xbe, 0xc7, 0x5b, 0x4f, 0x19, 0x87, 0xc3, 0x96, 0xb4, - 0x43, 0xed, 0xf8, 0x2a, 0x24, 0xcc, 0xf2, 0x4a, 0xc2, 0x79, 0x4b, 0xc3, 0xde, 0xfe, 0xae, 0x9e, - 0x6c, 0xc3, 0x6e, 0x06, 0x7b, 0xed, 0xd7, 0x37, 0x52, 0xb9, 0xbb, 0xe9, 0xc6, 0x87, 0x37, 0x92, - 0xfa, 0x46, 0xcb, 0x87, 0x65, 0x0c, 0x97, 0xf6, 0x42, 0xa2, 0xbe, 0x90, 0x94, 0x56, 0xfa, 0x6d, - 0x3c, 0x6a, 0x49, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0xf7, 0x15, 0x40, 0xc5, 0xfe, 0x02, 0x00, - 0x00, -} diff --git a/vendor/github.com/golang/protobuf/protoc-gen-go/plugin/plugin.pb.golden b/vendor/github.com/golang/protobuf/protoc-gen-go/plugin/plugin.pb.golden deleted file mode 100644 index 8953d0ff827ee6f4cdafaf6a39d5a2580bceb63d..0000000000000000000000000000000000000000 --- a/vendor/github.com/golang/protobuf/protoc-gen-go/plugin/plugin.pb.golden +++ /dev/null @@ -1,83 +0,0 @@ -// Code generated by protoc-gen-go. -// source: google/protobuf/compiler/plugin.proto -// DO NOT EDIT! - -package google_protobuf_compiler - -import proto "github.com/golang/protobuf/proto" -import "math" -import google_protobuf "github.com/golang/protobuf/protoc-gen-go/descriptor" - -// Reference proto and math imports to suppress error if they are not otherwise used. -var _ = proto.GetString -var _ = math.Inf - -type CodeGeneratorRequest struct { - FileToGenerate []string `protobuf:"bytes,1,rep,name=file_to_generate" json:"file_to_generate,omitempty"` - Parameter *string `protobuf:"bytes,2,opt,name=parameter" json:"parameter,omitempty"` - ProtoFile []*google_protobuf.FileDescriptorProto `protobuf:"bytes,15,rep,name=proto_file" json:"proto_file,omitempty"` - XXX_unrecognized []byte `json:"-"` -} - -func (this *CodeGeneratorRequest) Reset() { *this = CodeGeneratorRequest{} } -func (this *CodeGeneratorRequest) String() string { return proto.CompactTextString(this) } -func (*CodeGeneratorRequest) ProtoMessage() {} - -func (this *CodeGeneratorRequest) GetParameter() string { - if this != nil && this.Parameter != nil { - return *this.Parameter - } - return "" -} - -type CodeGeneratorResponse struct { - Error *string `protobuf:"bytes,1,opt,name=error" json:"error,omitempty"` - File []*CodeGeneratorResponse_File `protobuf:"bytes,15,rep,name=file" json:"file,omitempty"` - XXX_unrecognized []byte `json:"-"` -} - -func (this *CodeGeneratorResponse) Reset() { *this = CodeGeneratorResponse{} } -func (this *CodeGeneratorResponse) String() string { return proto.CompactTextString(this) } -func (*CodeGeneratorResponse) ProtoMessage() {} - -func (this *CodeGeneratorResponse) GetError() string { - if this != nil && this.Error != nil { - return *this.Error - } - return "" -} - -type CodeGeneratorResponse_File struct { - Name *string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` - InsertionPoint *string `protobuf:"bytes,2,opt,name=insertion_point" json:"insertion_point,omitempty"` - Content *string `protobuf:"bytes,15,opt,name=content" json:"content,omitempty"` - XXX_unrecognized []byte `json:"-"` -} - -func (this *CodeGeneratorResponse_File) Reset() { *this = CodeGeneratorResponse_File{} } -func (this *CodeGeneratorResponse_File) String() string { return proto.CompactTextString(this) } -func (*CodeGeneratorResponse_File) ProtoMessage() {} - -func (this *CodeGeneratorResponse_File) GetName() string { - if this != nil && this.Name != nil { - return *this.Name - } - return "" -} - -func (this *CodeGeneratorResponse_File) GetInsertionPoint() string { - if this != nil && this.InsertionPoint != nil { - return *this.InsertionPoint - } - return "" -} - -func (this *CodeGeneratorResponse_File) GetContent() string { - if this != nil && this.Content != nil { - return *this.Content - } - return "" -} - -func init() { -} diff --git a/vendor/github.com/golang/protobuf/protoc-gen-go/plugin/plugin.proto b/vendor/github.com/golang/protobuf/protoc-gen-go/plugin/plugin.proto deleted file mode 100644 index 5b5574529ed4890ee04ac13c4a1cfa50146f9ac3..0000000000000000000000000000000000000000 --- a/vendor/github.com/golang/protobuf/protoc-gen-go/plugin/plugin.proto +++ /dev/null @@ -1,167 +0,0 @@ -// Protocol Buffers - Google's data interchange format -// Copyright 2008 Google Inc. All rights reserved. -// https://developers.google.com/protocol-buffers/ -// -// 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. - -// Author: kenton@google.com (Kenton Varda) -// -// WARNING: The plugin interface is currently EXPERIMENTAL and is subject to -// change. -// -// protoc (aka the Protocol Compiler) can be extended via plugins. A plugin is -// just a program that reads a CodeGeneratorRequest from stdin and writes a -// CodeGeneratorResponse to stdout. -// -// Plugins written using C++ can use google/protobuf/compiler/plugin.h instead -// of dealing with the raw protocol defined here. -// -// A plugin executable needs only to be placed somewhere in the path. The -// plugin should be named "protoc-gen-$NAME", and will then be used when the -// flag "--${NAME}_out" is passed to protoc. - -syntax = "proto2"; -package google.protobuf.compiler; -option java_package = "com.google.protobuf.compiler"; -option java_outer_classname = "PluginProtos"; - -option go_package = "github.com/golang/protobuf/protoc-gen-go/plugin;plugin_go"; - -import "google/protobuf/descriptor.proto"; - -// The version number of protocol compiler. -message Version { - optional int32 major = 1; - optional int32 minor = 2; - optional int32 patch = 3; - // A suffix for alpha, beta or rc release, e.g., "alpha-1", "rc2". It should - // be empty for mainline stable releases. - optional string suffix = 4; -} - -// An encoded CodeGeneratorRequest is written to the plugin's stdin. -message CodeGeneratorRequest { - // The .proto files that were explicitly listed on the command-line. The - // code generator should generate code only for these files. Each file's - // descriptor will be included in proto_file, below. - repeated string file_to_generate = 1; - - // The generator parameter passed on the command-line. - optional string parameter = 2; - - // FileDescriptorProtos for all files in files_to_generate and everything - // they import. The files will appear in topological order, so each file - // appears before any file that imports it. - // - // protoc guarantees that all proto_files will be written after - // the fields above, even though this is not technically guaranteed by the - // protobuf wire format. This theoretically could allow a plugin to stream - // in the FileDescriptorProtos and handle them one by one rather than read - // the entire set into memory at once. However, as of this writing, this - // is not similarly optimized on protoc's end -- it will store all fields in - // memory at once before sending them to the plugin. - // - // Type names of fields and extensions in the FileDescriptorProto are always - // fully qualified. - repeated FileDescriptorProto proto_file = 15; - - // The version number of protocol compiler. - optional Version compiler_version = 3; - -} - -// The plugin writes an encoded CodeGeneratorResponse to stdout. -message CodeGeneratorResponse { - // Error message. If non-empty, code generation failed. The plugin process - // should exit with status code zero even if it reports an error in this way. - // - // This should be used to indicate errors in .proto files which prevent the - // code generator from generating correct code. Errors which indicate a - // problem in protoc itself -- such as the input CodeGeneratorRequest being - // unparseable -- should be reported by writing a message to stderr and - // exiting with a non-zero status code. - optional string error = 1; - - // Represents a single generated file. - message File { - // The file name, relative to the output directory. The name must not - // contain "." or ".." components and must be relative, not be absolute (so, - // the file cannot lie outside the output directory). "/" must be used as - // the path separator, not "\". - // - // If the name is omitted, the content will be appended to the previous - // file. This allows the generator to break large files into small chunks, - // and allows the generated text to be streamed back to protoc so that large - // files need not reside completely in memory at one time. Note that as of - // this writing protoc does not optimize for this -- it will read the entire - // CodeGeneratorResponse before writing files to disk. - optional string name = 1; - - // If non-empty, indicates that the named file should already exist, and the - // content here is to be inserted into that file at a defined insertion - // point. This feature allows a code generator to extend the output - // produced by another code generator. The original generator may provide - // insertion points by placing special annotations in the file that look - // like: - // @@protoc_insertion_point(NAME) - // The annotation can have arbitrary text before and after it on the line, - // which allows it to be placed in a comment. NAME should be replaced with - // an identifier naming the point -- this is what other generators will use - // as the insertion_point. Code inserted at this point will be placed - // immediately above the line containing the insertion point (thus multiple - // insertions to the same point will come out in the order they were added). - // The double-@ is intended to make it unlikely that the generated code - // could contain things that look like insertion points by accident. - // - // For example, the C++ code generator places the following line in the - // .pb.h files that it generates: - // // @@protoc_insertion_point(namespace_scope) - // This line appears within the scope of the file's package namespace, but - // outside of any particular class. Another plugin can then specify the - // insertion_point "namespace_scope" to generate additional classes or - // other declarations that should be placed in this scope. - // - // Note that if the line containing the insertion point begins with - // whitespace, the same whitespace will be added to every line of the - // inserted text. This is useful for languages like Python, where - // indentation matters. In these languages, the insertion point comment - // should be indented the same amount as any inserted code will need to be - // in order to work correctly in that context. - // - // The code generator that generates the initial file and the one which - // inserts into it must both run as part of a single invocation of protoc. - // Code generators are executed in the order in which they appear on the - // command line. - // - // If |insertion_point| is present, |name| must also be present. - optional string insertion_point = 2; - - // The file contents. - optional string content = 15; - } - repeated File file = 15; -} diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/BUILD.bazel b/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/BUILD.bazel index 7a51fd7c7f4030fc644900b93c337d9f031a04f9..8dea43d297d2028db10e8158c5bbaadac592967b 100644 --- a/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/BUILD.bazel +++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/BUILD.bazel @@ -26,6 +26,7 @@ proto_library( deps = [ "@com_google_protobuf//:any_proto", "@com_google_protobuf//:descriptor_proto", + "@com_google_protobuf//:struct_proto", ], ) diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/openapiv2.pb.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/openapiv2.pb.go index f52414a5ef9ef1356bd78bfc90d0b9c338db8ecd..6720071bde078408914a5bed63c8dafd432e5ed2 100644 --- a/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/openapiv2.pb.go +++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/openapiv2.pb.go @@ -7,6 +7,7 @@ import proto "github.com/golang/protobuf/proto" import fmt "fmt" import math "math" import any "github.com/golang/protobuf/ptypes/any" +import _struct "github.com/golang/protobuf/ptypes/struct" // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal @@ -48,7 +49,7 @@ func (x Swagger_SwaggerScheme) String() string { return proto.EnumName(Swagger_SwaggerScheme_name, int32(x)) } func (Swagger_SwaggerScheme) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{0, 0} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{0, 0} } type JSONSchema_JSONSchemaSimpleTypes int32 @@ -89,7 +90,7 @@ func (x JSONSchema_JSONSchemaSimpleTypes) String() string { return proto.EnumName(JSONSchema_JSONSchemaSimpleTypes_name, int32(x)) } func (JSONSchema_JSONSchemaSimpleTypes) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{8, 0} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{8, 0} } // Required. The type of the security scheme. Valid values are "basic", @@ -120,7 +121,7 @@ func (x SecurityScheme_Type) String() string { return proto.EnumName(SecurityScheme_Type_name, int32(x)) } func (SecurityScheme_Type) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{11, 0} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{11, 0} } // Required. The location of the API key. Valid values are "query" or "header". @@ -147,7 +148,7 @@ func (x SecurityScheme_In) String() string { return proto.EnumName(SecurityScheme_In_name, int32(x)) } func (SecurityScheme_In) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{11, 1} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{11, 1} } // Required. The flow used by the OAuth2 security scheme. Valid values are @@ -181,7 +182,7 @@ func (x SecurityScheme_Flow) String() string { return proto.EnumName(SecurityScheme_Flow_name, int32(x)) } func (SecurityScheme_Flow) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{11, 2} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{11, 2} } // `Swagger` is a representation of OpenAPI v2 specification's Swagger object. @@ -199,24 +200,25 @@ type Swagger struct { // Swagger file. If you wish to use `base_path` with relatively generated Swagger paths, the // `base_path` prefix must be manually removed from your `google.api.http` paths and your code changed to // serve the API from the `base_path`. - BasePath string `protobuf:"bytes,4,opt,name=base_path,json=basePath,proto3" json:"base_path,omitempty"` - Schemes []Swagger_SwaggerScheme `protobuf:"varint,5,rep,packed,name=schemes,proto3,enum=grpc.gateway.protoc_gen_swagger.options.Swagger_SwaggerScheme" json:"schemes,omitempty"` - Consumes []string `protobuf:"bytes,6,rep,name=consumes,proto3" json:"consumes,omitempty"` - Produces []string `protobuf:"bytes,7,rep,name=produces,proto3" json:"produces,omitempty"` - Responses map[string]*Response `protobuf:"bytes,10,rep,name=responses,proto3" json:"responses,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` - SecurityDefinitions *SecurityDefinitions `protobuf:"bytes,11,opt,name=security_definitions,json=securityDefinitions,proto3" json:"security_definitions,omitempty"` - Security []*SecurityRequirement `protobuf:"bytes,12,rep,name=security,proto3" json:"security,omitempty"` - ExternalDocs *ExternalDocumentation `protobuf:"bytes,14,opt,name=external_docs,json=externalDocs,proto3" json:"external_docs,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + BasePath string `protobuf:"bytes,4,opt,name=base_path,json=basePath,proto3" json:"base_path,omitempty"` + Schemes []Swagger_SwaggerScheme `protobuf:"varint,5,rep,packed,name=schemes,proto3,enum=grpc.gateway.protoc_gen_swagger.options.Swagger_SwaggerScheme" json:"schemes,omitempty"` + Consumes []string `protobuf:"bytes,6,rep,name=consumes,proto3" json:"consumes,omitempty"` + Produces []string `protobuf:"bytes,7,rep,name=produces,proto3" json:"produces,omitempty"` + Responses map[string]*Response `protobuf:"bytes,10,rep,name=responses,proto3" json:"responses,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + SecurityDefinitions *SecurityDefinitions `protobuf:"bytes,11,opt,name=security_definitions,json=securityDefinitions,proto3" json:"security_definitions,omitempty"` + Security []*SecurityRequirement `protobuf:"bytes,12,rep,name=security,proto3" json:"security,omitempty"` + ExternalDocs *ExternalDocumentation `protobuf:"bytes,14,opt,name=external_docs,json=externalDocs,proto3" json:"external_docs,omitempty"` + Extensions map[string]*_struct.Value `protobuf:"bytes,15,rep,name=extensions,proto3" json:"extensions,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *Swagger) Reset() { *m = Swagger{} } func (m *Swagger) String() string { return proto.CompactTextString(m) } func (*Swagger) ProtoMessage() {} func (*Swagger) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{0} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{0} } func (m *Swagger) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Swagger.Unmarshal(m, b) @@ -313,33 +315,41 @@ func (m *Swagger) GetExternalDocs() *ExternalDocumentation { return nil } +func (m *Swagger) GetExtensions() map[string]*_struct.Value { + if m != nil { + return m.Extensions + } + return nil +} + // `Operation` is a representation of OpenAPI v2 specification's Operation object. // // See: https://github.com/OAI/OpenAPI-Specification/blob/3.0.0/versions/2.0.md#operationObject // // TODO(ivucica): document fields type Operation struct { - Tags []string `protobuf:"bytes,1,rep,name=tags,proto3" json:"tags,omitempty"` - Summary string `protobuf:"bytes,2,opt,name=summary,proto3" json:"summary,omitempty"` - Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"` - ExternalDocs *ExternalDocumentation `protobuf:"bytes,4,opt,name=external_docs,json=externalDocs,proto3" json:"external_docs,omitempty"` - OperationId string `protobuf:"bytes,5,opt,name=operation_id,json=operationId,proto3" json:"operation_id,omitempty"` - Consumes []string `protobuf:"bytes,6,rep,name=consumes,proto3" json:"consumes,omitempty"` - Produces []string `protobuf:"bytes,7,rep,name=produces,proto3" json:"produces,omitempty"` - Responses map[string]*Response `protobuf:"bytes,9,rep,name=responses,proto3" json:"responses,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` - Schemes []string `protobuf:"bytes,10,rep,name=schemes,proto3" json:"schemes,omitempty"` - Deprecated bool `protobuf:"varint,11,opt,name=deprecated,proto3" json:"deprecated,omitempty"` - Security []*SecurityRequirement `protobuf:"bytes,12,rep,name=security,proto3" json:"security,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + Tags []string `protobuf:"bytes,1,rep,name=tags,proto3" json:"tags,omitempty"` + Summary string `protobuf:"bytes,2,opt,name=summary,proto3" json:"summary,omitempty"` + Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"` + ExternalDocs *ExternalDocumentation `protobuf:"bytes,4,opt,name=external_docs,json=externalDocs,proto3" json:"external_docs,omitempty"` + OperationId string `protobuf:"bytes,5,opt,name=operation_id,json=operationId,proto3" json:"operation_id,omitempty"` + Consumes []string `protobuf:"bytes,6,rep,name=consumes,proto3" json:"consumes,omitempty"` + Produces []string `protobuf:"bytes,7,rep,name=produces,proto3" json:"produces,omitempty"` + Responses map[string]*Response `protobuf:"bytes,9,rep,name=responses,proto3" json:"responses,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + Schemes []string `protobuf:"bytes,10,rep,name=schemes,proto3" json:"schemes,omitempty"` + Deprecated bool `protobuf:"varint,11,opt,name=deprecated,proto3" json:"deprecated,omitempty"` + Security []*SecurityRequirement `protobuf:"bytes,12,rep,name=security,proto3" json:"security,omitempty"` + Extensions map[string]*_struct.Value `protobuf:"bytes,13,rep,name=extensions,proto3" json:"extensions,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *Operation) Reset() { *m = Operation{} } func (m *Operation) String() string { return proto.CompactTextString(m) } func (*Operation) ProtoMessage() {} func (*Operation) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{1} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{1} } func (m *Operation) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Operation.Unmarshal(m, b) @@ -436,6 +446,13 @@ func (m *Operation) GetSecurity() []*SecurityRequirement { return nil } +func (m *Operation) GetExtensions() map[string]*_struct.Value { + if m != nil { + return m.Extensions + } + return nil +} + // `Response` is a representation of OpenAPI v2 specification's Response object. // // See: https://github.com/OAI/OpenAPI-Specification/blob/3.0.0/versions/2.0.md#responseObject @@ -446,17 +463,18 @@ type Response struct { Description string `protobuf:"bytes,1,opt,name=description,proto3" json:"description,omitempty"` // `Schema` optionally defines the structure of the response. // If `Schema` is not provided, it means there is no content to the response. - Schema *Schema `protobuf:"bytes,2,opt,name=schema,proto3" json:"schema,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + Schema *Schema `protobuf:"bytes,2,opt,name=schema,proto3" json:"schema,omitempty"` + Extensions map[string]*_struct.Value `protobuf:"bytes,5,rep,name=extensions,proto3" json:"extensions,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *Response) Reset() { *m = Response{} } func (m *Response) String() string { return proto.CompactTextString(m) } func (*Response) ProtoMessage() {} func (*Response) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{2} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{2} } func (m *Response) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Response.Unmarshal(m, b) @@ -490,28 +508,36 @@ func (m *Response) GetSchema() *Schema { return nil } +func (m *Response) GetExtensions() map[string]*_struct.Value { + if m != nil { + return m.Extensions + } + return nil +} + // `Info` is a representation of OpenAPI v2 specification's Info object. // // See: https://github.com/OAI/OpenAPI-Specification/blob/3.0.0/versions/2.0.md#infoObject // // TODO(ivucica): document fields type Info struct { - Title string `protobuf:"bytes,1,opt,name=title,proto3" json:"title,omitempty"` - Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"` - TermsOfService string `protobuf:"bytes,3,opt,name=terms_of_service,json=termsOfService,proto3" json:"terms_of_service,omitempty"` - Contact *Contact `protobuf:"bytes,4,opt,name=contact,proto3" json:"contact,omitempty"` - License *License `protobuf:"bytes,5,opt,name=license,proto3" json:"license,omitempty"` - Version string `protobuf:"bytes,6,opt,name=version,proto3" json:"version,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + Title string `protobuf:"bytes,1,opt,name=title,proto3" json:"title,omitempty"` + Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"` + TermsOfService string `protobuf:"bytes,3,opt,name=terms_of_service,json=termsOfService,proto3" json:"terms_of_service,omitempty"` + Contact *Contact `protobuf:"bytes,4,opt,name=contact,proto3" json:"contact,omitempty"` + License *License `protobuf:"bytes,5,opt,name=license,proto3" json:"license,omitempty"` + Version string `protobuf:"bytes,6,opt,name=version,proto3" json:"version,omitempty"` + Extensions map[string]*_struct.Value `protobuf:"bytes,7,rep,name=extensions,proto3" json:"extensions,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *Info) Reset() { *m = Info{} } func (m *Info) String() string { return proto.CompactTextString(m) } func (*Info) ProtoMessage() {} func (*Info) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{3} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{3} } func (m *Info) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Info.Unmarshal(m, b) @@ -573,6 +599,13 @@ func (m *Info) GetVersion() string { return "" } +func (m *Info) GetExtensions() map[string]*_struct.Value { + if m != nil { + return m.Extensions + } + return nil +} + // `Contact` is a representation of OpenAPI v2 specification's Contact object. // // See: https://github.com/OAI/OpenAPI-Specification/blob/3.0.0/versions/2.0.md#contactObject @@ -591,7 +624,7 @@ func (m *Contact) Reset() { *m = Contact{} } func (m *Contact) String() string { return proto.CompactTextString(m) } func (*Contact) ProtoMessage() {} func (*Contact) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{4} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{4} } func (m *Contact) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Contact.Unmarshal(m, b) @@ -650,7 +683,7 @@ func (m *License) Reset() { *m = License{} } func (m *License) String() string { return proto.CompactTextString(m) } func (*License) ProtoMessage() {} func (*License) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{5} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{5} } func (m *License) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_License.Unmarshal(m, b) @@ -702,7 +735,7 @@ func (m *ExternalDocumentation) Reset() { *m = ExternalDocumentation{} } func (m *ExternalDocumentation) String() string { return proto.CompactTextString(m) } func (*ExternalDocumentation) ProtoMessage() {} func (*ExternalDocumentation) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{6} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{6} } func (m *ExternalDocumentation) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_ExternalDocumentation.Unmarshal(m, b) @@ -756,7 +789,7 @@ func (m *Schema) Reset() { *m = Schema{} } func (m *Schema) String() string { return proto.CompactTextString(m) } func (*Schema) ProtoMessage() {} func (*Schema) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{7} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{7} } func (m *Schema) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Schema.Unmarshal(m, b) @@ -860,7 +893,7 @@ func (m *JSONSchema) Reset() { *m = JSONSchema{} } func (m *JSONSchema) String() string { return proto.CompactTextString(m) } func (*JSONSchema) ProtoMessage() {} func (*JSONSchema) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{8} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{8} } func (m *JSONSchema) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_JSONSchema.Unmarshal(m, b) @@ -1046,7 +1079,7 @@ func (m *Tag) Reset() { *m = Tag{} } func (m *Tag) String() string { return proto.CompactTextString(m) } func (*Tag) ProtoMessage() {} func (*Tag) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{9} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{9} } func (m *Tag) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Tag.Unmarshal(m, b) @@ -1100,7 +1133,7 @@ func (m *SecurityDefinitions) Reset() { *m = SecurityDefinitions{} } func (m *SecurityDefinitions) String() string { return proto.CompactTextString(m) } func (*SecurityDefinitions) ProtoMessage() {} func (*SecurityDefinitions) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{10} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{10} } func (m *SecurityDefinitions) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_SecurityDefinitions.Unmarshal(m, b) @@ -1168,17 +1201,18 @@ type SecurityScheme struct { // Required. The available scopes for the OAuth2 security scheme. // // Valid for oauth2. - Scopes *Scopes `protobuf:"bytes,8,opt,name=scopes,proto3" json:"scopes,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + Scopes *Scopes `protobuf:"bytes,8,opt,name=scopes,proto3" json:"scopes,omitempty"` + Extensions map[string]*_struct.Value `protobuf:"bytes,9,rep,name=extensions,proto3" json:"extensions,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *SecurityScheme) Reset() { *m = SecurityScheme{} } func (m *SecurityScheme) String() string { return proto.CompactTextString(m) } func (*SecurityScheme) ProtoMessage() {} func (*SecurityScheme) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{11} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{11} } func (m *SecurityScheme) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_SecurityScheme.Unmarshal(m, b) @@ -1254,6 +1288,13 @@ func (m *SecurityScheme) GetScopes() *Scopes { return nil } +func (m *SecurityScheme) GetExtensions() map[string]*_struct.Value { + if m != nil { + return m.Extensions + } + return nil +} + // `SecurityRequirement` is a representation of OpenAPI v2 specification's // Security Requirement object. // @@ -1280,7 +1321,7 @@ func (m *SecurityRequirement) Reset() { *m = SecurityRequirement{} } func (m *SecurityRequirement) String() string { return proto.CompactTextString(m) } func (*SecurityRequirement) ProtoMessage() {} func (*SecurityRequirement) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{12} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{12} } func (m *SecurityRequirement) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_SecurityRequirement.Unmarshal(m, b) @@ -1325,7 +1366,7 @@ func (m *SecurityRequirement_SecurityRequirementValue) String() string { } func (*SecurityRequirement_SecurityRequirementValue) ProtoMessage() {} func (*SecurityRequirement_SecurityRequirementValue) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{12, 0} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{12, 0} } func (m *SecurityRequirement_SecurityRequirementValue) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_SecurityRequirement_SecurityRequirementValue.Unmarshal(m, b) @@ -1370,7 +1411,7 @@ func (m *Scopes) Reset() { *m = Scopes{} } func (m *Scopes) String() string { return proto.CompactTextString(m) } func (*Scopes) ProtoMessage() {} func (*Scopes) Descriptor() ([]byte, []int) { - return fileDescriptor_openapiv2_78431ddfac00899a, []int{13} + return fileDescriptor_openapiv2_7182f700aabb5117, []int{13} } func (m *Scopes) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Scopes.Unmarshal(m, b) @@ -1399,11 +1440,15 @@ func (m *Scopes) GetScope() map[string]string { func init() { proto.RegisterType((*Swagger)(nil), "grpc.gateway.protoc_gen_swagger.options.Swagger") + proto.RegisterMapType((map[string]*_struct.Value)(nil), "grpc.gateway.protoc_gen_swagger.options.Swagger.ExtensionsEntry") proto.RegisterMapType((map[string]*Response)(nil), "grpc.gateway.protoc_gen_swagger.options.Swagger.ResponsesEntry") proto.RegisterType((*Operation)(nil), "grpc.gateway.protoc_gen_swagger.options.Operation") + proto.RegisterMapType((map[string]*_struct.Value)(nil), "grpc.gateway.protoc_gen_swagger.options.Operation.ExtensionsEntry") proto.RegisterMapType((map[string]*Response)(nil), "grpc.gateway.protoc_gen_swagger.options.Operation.ResponsesEntry") proto.RegisterType((*Response)(nil), "grpc.gateway.protoc_gen_swagger.options.Response") + proto.RegisterMapType((map[string]*_struct.Value)(nil), "grpc.gateway.protoc_gen_swagger.options.Response.ExtensionsEntry") proto.RegisterType((*Info)(nil), "grpc.gateway.protoc_gen_swagger.options.Info") + proto.RegisterMapType((map[string]*_struct.Value)(nil), "grpc.gateway.protoc_gen_swagger.options.Info.ExtensionsEntry") proto.RegisterType((*Contact)(nil), "grpc.gateway.protoc_gen_swagger.options.Contact") proto.RegisterType((*License)(nil), "grpc.gateway.protoc_gen_swagger.options.License") proto.RegisterType((*ExternalDocumentation)(nil), "grpc.gateway.protoc_gen_swagger.options.ExternalDocumentation") @@ -1413,6 +1458,7 @@ func init() { proto.RegisterType((*SecurityDefinitions)(nil), "grpc.gateway.protoc_gen_swagger.options.SecurityDefinitions") proto.RegisterMapType((map[string]*SecurityScheme)(nil), "grpc.gateway.protoc_gen_swagger.options.SecurityDefinitions.SecurityEntry") proto.RegisterType((*SecurityScheme)(nil), "grpc.gateway.protoc_gen_swagger.options.SecurityScheme") + proto.RegisterMapType((map[string]*_struct.Value)(nil), "grpc.gateway.protoc_gen_swagger.options.SecurityScheme.ExtensionsEntry") proto.RegisterType((*SecurityRequirement)(nil), "grpc.gateway.protoc_gen_swagger.options.SecurityRequirement") proto.RegisterMapType((map[string]*SecurityRequirement_SecurityRequirementValue)(nil), "grpc.gateway.protoc_gen_swagger.options.SecurityRequirement.SecurityRequirementEntry") proto.RegisterType((*SecurityRequirement_SecurityRequirementValue)(nil), "grpc.gateway.protoc_gen_swagger.options.SecurityRequirement.SecurityRequirementValue") @@ -1426,121 +1472,127 @@ func init() { } func init() { - proto.RegisterFile("protoc-gen-swagger/options/openapiv2.proto", fileDescriptor_openapiv2_78431ddfac00899a) -} - -var fileDescriptor_openapiv2_78431ddfac00899a = []byte{ - // 1777 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x58, 0xdd, 0x73, 0xdb, 0xc6, - 0x11, 0x0f, 0x48, 0x90, 0x04, 0x97, 0x22, 0x73, 0x3e, 0xcb, 0x2d, 0xa2, 0xc4, 0xae, 0xc2, 0xa6, - 0x53, 0x8d, 0x3d, 0xa6, 0x12, 0xe5, 0xa1, 0x99, 0x4c, 0xa7, 0x1d, 0x4a, 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0x81, 0x73, 0xe5, - 0x05, 0x59, 0xc0, 0xef, 0x50, 0xc5, 0xca, 0x49, 0xfc, 0x08, 0xee, 0x90, 0x2b, 0xd7, 0xcf, 0x12, - 0xef, 0x82, 0xd8, 0xb9, 0xce, 0x16, 0xc7, 0x47, 0x0b, 0xc1, 0x73, 0xa9, 0xcc, 0x60, 0x3c, 0xca, - 0x55, 0x9a, 0x12, 0x46, 0x90, 0xd7, 0x60, 0xa4, 0x4e, 0xeb, 0x3a, 0x8c, 0x54, 0xbe, 0x0f, 0x10, - 0x38, 0x57, 0xb6, 0x4f, 0xe8, 0x2c, 0x3d, 0xd7, 0xdf, 0xdf, 0x55, 0xf6, 0x54, 0xab, 0x1e, 0x38, - 0x57, 0x27, 0x9c, 0xc1, 0xc5, 0x1e, 0xcd, 0xc5, 0x48, 0x8a, 0x3d, 0x2a, 0xc5, 0x3a, 0xd4, 0x22, - 0x27, 0x65, 0x67, 0xa8, 0xdf, 0x11, 0x39, 0x92, 0x24, 0xcb, 0x11, 0xc3, 0xf5, 0x52, 0x12, 0x24, - 0xfa, 0x36, 0xb7, 0xd3, 0x02, 0xe7, 0xca, 0x60, 0x34, 0x17, 0x7a, 0x54, 0x0a, 0xef, 0x49, 0xa1, - 0x47, 0x85, 0xf0, 0x63, 0xd8, 0xca, 0xa8, 0xf7, 0x7d, 0x46, 0xa4, 0xfc, 0x67, 0xdc, 0xf3, 0x86, - 0xe0, 0x09, 0x95, 0x5f, 0x41, 0x8b, 0x81, 0x47, 0x31, 0x7b, 0x51, 0x53, 0x8f, 0x24, 0xba, 0xce, - 0x41, 0x9a, 0x81, 0x73, 0x35, 0x5c, 0x30, 0xb9, 0x9a, 0x47, 0x8b, 0x6a, 0x1f, 0x48, 0x35, 0x8f, - 0x16, 0xd4, 0x76, 0x40, 0x8b, 0xc5, 0xb3, 0x33, 0xd1, 0x77, 0xc4, 0x73, 0x9b, 0xd3, 0xac, 0x78, - 0x9c, 0x38, 0x76, 0xe6, 0x7a, 0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x77, 0xb5, 0x78, 0x59, 0xfc, 0x5d, - 0x61, 0x63, 0x29, 0xab, 0x35, 0x3c, 0x2c, 0x06, 0xd0, 0xb8, 0x4d, 0x7f, 0x72, 0x7b, 0xf1, 0x23, - 0x92, 0x27, 0x83, 0xff, 0x02, 0x60, 0xc9, 0x5c, 0x13, 0xed, 0x76, 0x31, 0xda, 0x7a, 0xc1, 0xad, - 0xc3, 0xa3, 0x3f, 0x76, 0x67, 0x5e, 0x7a, 0x9e, 0xbd, 0xec, 0xb8, 0x61, 0xb0, 0xcf, 0x1c, 0x79, - 0x4c, 0xdc, 0x30, 0x99, 0x27, 0x29, 0x91, 0xa4, 0xf4, 0x6b, 0xff, 0xc7, 0xff, 0x38, 0x7c, 0x59, - 0xe5, 0xb2, 0xcf, 0xff, 0x17, 0x00, 0x00, 0xff, 0xff, 0xb3, 0xec, 0xbb, 0xdf, 0x5d, 0x14, 0x00, - 0x00, + proto.RegisterFile("protoc-gen-swagger/options/openapiv2.proto", fileDescriptor_openapiv2_7182f700aabb5117) +} + +var fileDescriptor_openapiv2_7182f700aabb5117 = []byte{ + // 1884 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x58, 0x5b, 0x73, 0xdb, 0xc6, + 0xf5, 0x0f, 0x48, 0x90, 0x04, 0x0f, 0x45, 0x7a, 0xbd, 0x96, 0xf3, 0x47, 0x18, 0xdb, 0x7f, 0x85, + 0x4d, 0xa7, 0x1a, 0xbb, 0xa6, 0x12, 0xe5, 0xa1, 0x99, 0x4c, 0x6f, 0x94, 0xc4, 0xc8, 0x80, 0x65, + 0x92, 0x05, 0xa9, 0x28, 0xee, 0x8c, 0x07, 0x85, 0xc0, 0x25, 0x85, 0x18, 0x17, 0x06, 0x17, 0x49, + 0xec, 0x27, 0xe8, 0x73, 0xa7, 0xaf, 0xf9, 0x1e, 0x9d, 0x69, 0x9f, 0xfa, 0x09, 0x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08, 0x1e, 0x90, 0x0c, 0x66, + 0x3d, 0x80, 0xda, 0x62, 0xb8, 0x30, 0x82, 0xfc, 0x6b, 0x32, 0x15, 0xe9, 0x41, 0x97, 0xf8, 0x18, + 0x0a, 0x97, 0x96, 0x9b, 0x10, 0x91, 0x1b, 0x9f, 0xae, 0x7d, 0x80, 0x14, 0xd9, 0xe0, 0xf6, 0x5f, + 0xe4, 0x3e, 0x97, 0xea, 0xa7, 0x70, 0xe7, 0xc6, 0x79, 0x56, 0xec, 0xf8, 0xf3, 0xc5, 0x1d, 0xdf, + 0x6f, 0xf2, 0x04, 0x6f, 0xa6, 0x09, 0xde, 0xfc, 0x8a, 0x4a, 0x33, 0xb0, 0x8d, 0x03, 0xa8, 0x2e, + 0xa4, 0x02, 0xae, 0x40, 0xe9, 0xb4, 0xf3, 0xbc, 0xd3, 0x3d, 0xeb, 0xa0, 0xf7, 0xb0, 0x02, 0xf2, + 0xb3, 0xc1, 0xa0, 0x87, 0x24, 0x5c, 0x86, 0x02, 0x5d, 0xf5, 0x51, 0x0e, 0x17, 0x21, 0x77, 0xd6, + 0x47, 0x79, 0x5c, 0x82, 0xfc, 0x59, 0xbf, 0x8f, 0x64, 0x5d, 0x56, 0x14, 0x54, 0xd6, 0x65, 0xa5, + 0x8c, 0x40, 0x97, 0x95, 0x2a, 0xaa, 0x35, 0xfe, 0x51, 0x84, 0x72, 0x77, 0x42, 0x42, 0x16, 0x1b, + 0x9a, 0xdf, 0xb1, 0x35, 0x8e, 0x54, 0x89, 0x25, 0x0d, 0x5b, 0xb3, 0x82, 0x92, 0x78, 0x9e, 0x15, + 0x4e, 0xd9, 0x59, 0x69, 0x41, 0xe1, 0x24, 0xde, 0x81, 0xca, 0x90, 0x44, 0x76, 0xe8, 0x30, 0x67, + 0x88, 0xa2, 0x90, 0x65, 0x2d, 0x3f, 0x21, 0xf9, 0x1d, 0x3c, 0xa1, 0x8f, 0x60, 0x2b, 0x48, 0x6f, + 0x60, 0x3a, 0x43, 0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+ 0x80, 0xf9, 0xc5, 0xa9, 0x7f, 0x43, 0x32, 0x12, 0xf1, 0xa5, 0xcb, 0x79, 0xba, 0x17, 0xde, 0x90, + 0xee, 0xc5, 0xe5, 0x48, 0xa9, 0x50, 0x1a, 0x92, 0x91, 0x95, 0xb8, 0xb1, 0x5a, 0xe2, 0xc9, 0x22, + 0xc8, 0x45, 0x57, 0x29, 0x37, 0x5c, 0xf5, 0xff, 0x50, 0xf1, 0x12, 0x37, 0x76, 0x26, 0x2e, 0x31, + 0x83, 0x91, 0x0a, 0x3b, 0xd2, 0xae, 0x64, 0x40, 0xca, 0xea, 0x8e, 0x28, 0xae, 0x67, 0x5d, 0x3b, + 0x5e, 0xe2, 0xb1, 0x76, 0x2b, 0x19, 0x29, 0x89, 0x9f, 0xc0, 0x5d, 0x72, 0x6d, 0xbb, 0x49, 0xe4, + 0x5c, 0x12, 0x33, 0xd5, 0xd9, 0x62, 0xf8, 0x68, 0x26, 0x78, 0x21, 0x94, 0x29, 0x8c, 0xe3, 0x33, + 0x95, 0xaa, 0x80, 0xe1, 0xe4, 0x0d, 0x18, 0xa1, 0x53, 0xbb, 0x09, 0x23, 0x94, 0x1f, 0x02, 0x78, + 0xd6, 0xb5, 0xe9, 0x12, 0x7f, 0x1c, 0x5f, 0xa8, 0x77, 0x76, 0xa4, 0x5d, 0xd9, 0x28, 0x7b, 0xd6, + 0xf5, 0x09, 0x63, 0x30, 0xb1, 0xe3, 0xa7, 0x62, 0x24, 0xc4, 0x8e, 0x2f, 0xc4, 0x2a, 0x94, 0x26, + 0x56, 0x4c, 0x63, 0xa8, 0xde, 0xe5, 0x3e, 0x12, 0x24, 0xf5, 0x11, 0xc5, 0x75, 0x62, 0xe2, 0x45, + 0xea, 0x36, 0xb3, 0x53, 0x3c, 0xeb, 0x5a, 0xa3, 0x34, 0x13, 0x3a, 0xbe, 0x10, 0xde, 0x17, 0x42, + 0xc7, 0xe7, 0xc2, 0x8f, 0x60, 0x2b, 0xf1, 0x9d, 0x6f, 0x13, 0x22, 0xe4, 0xef, 0xb3, 0x93, 0x57, + 0x38, 0x8f, 0xab, 0xfc, 0x14, 0x6a, 0x14, 0x7c, 0x12, 0xd2, 0xe1, 0x2b, 0x76, 0x48, 0xa4, 0xaa, + 0x0c, 0xa4, 0xea, 0x59, 0xd7, 0xbd, 0x19, 0x93, 0xa9, 0x39, 0x7e, 0x56, 0xed, 0x03, 0xa1, 0xe6, + 0xf8, 0x19, 0xb5, 0x3a, 0x28, 0x21, 0x9f, 0x50, 0x86, 0x6a, 0x9d, 0x4f, 0x66, 0x29, 0x4d, 0x1f, + 0x8f, 0x15, 0x86, 0xd6, 0x54, 0x6d, 0x30, 0x01, 0x27, 0xf0, 0x2b, 0x90, 0xe3, 0xe9, 0x84, 0xa8, + 0x3f, 0x61, 0xdf, 0x9a, 0xda, 0x2d, 0x12, 0x34, 0xb3, 0xec, 0x3b, 0xf4, 0x35, 0x0f, 0xa6, 0x13, + 0x12, 0x19, 0x0c, 0xb6, 0x71, 0x05, 0xf7, 0x57, 0x8a, 0x17, 0x47, 0xf1, 0x32, 0x14, 0x5a, 0x86, + 0xd1, 0x7a, 0x89, 0x24, 0xca, 0x3f, 0xe8, 0x76, 0x4f, 0xda, 0xad, 0x0e, 0xca, 0x51, 0x42, 0xeb, + 0x0c, 0xda, 0xc7, 0x6d, 0x03, 0xe5, 0xe9, 0xbc, 0xde, 0x39, 0x3d, 0x39, 0x41, 0x32, 0x06, 0x28, + 0x76, 0x4e, 0x5f, 0x1c, 0xb4, 0x0d, 0x54, 0xa0, 0xeb, 0xee, 0x81, 0xde, 0x3e, 0x1c, 0xa0, 0x22, + 0x5d, 0xf7, 0x07, 0x86, 0xd6, 0x39, 0x46, 0x25, 0x5d, 0x56, 0x24, 0x94, 0xd3, 0x65, 0x25, 0x87, + 0xf2, 0x3c, 0xbb, 0x66, 0x33, 0x3c, 0x46, 0xf7, 0x74, 0x59, 0xb9, 0x87, 0xb6, 0x75, 0x59, 0xf9, + 0x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xf7, 0xf0, 0xb0, 0xdd, 0xef, + 0x9b, 0x87, 0xdd, 0xa3, 0x36, 0x92, 0x1b, 0xff, 0xca, 0xcd, 0xab, 0x4d, 0xe6, 0x5b, 0x18, 0xff, + 0x49, 0xca, 0xfc, 0x8b, 0x17, 0xce, 0x05, 0xa2, 0xf4, 0x9c, 0xbe, 0xcd, 0x87, 0xf6, 0x2a, 0x1e, + 0x0f, 0xee, 0xec, 0xef, 0xbd, 0x8c, 0xa4, 0xfe, 0x09, 0xa8, 0x2b, 0x0c, 0x58, 0xd4, 0x68, 0x0f, + 0x64, 0x8f, 0x4e, 0xfc, 0x5d, 0xc3, 0x89, 0xfa, 0x77, 0xd2, 0x4a, 0x93, 0xef, 0x7b, 0x21, 0xaf, + 0x17, 0x5f, 0xc8, 0x0f, 0x7e, 0xb7, 0xa5, 0x07, 0xf6, 0x17, 0x89, 0x8e, 0xd5, 0x2c, 0x57, 0x7a, + 0xd9, 0x0b, 0x54, 0x36, 0xa9, 0x2f, 0xcc, 0x9e, 0xff, 0x70, 0xe7, 0x89, 0xcb, 0x7f, 0x0e, 0x30, + 0x67, 0xae, 0xb8, 0xed, 0x76, 0xf6, 0xb6, 0xe5, 0xcc, 0xb1, 0x0e, 0x0e, 0x7f, 0xdf, 0x1a, 0x3b, + 0xf1, 0x45, 0x72, 0xde, 0xb4, 0x03, 0x6f, 0x8f, 0x1e, 0xe4, 0x29, 0xb1, 0x83, 0x68, 0x1a, 0xc5, + 0x44, 0x90, 0xe2, 0x5c, 0x7b, 0xdf, 0xff, 0xd7, 0xff, 0x79, 0x91, 0xc9, 0x3e, 0xfb, 0x6f, 0x00, + 0x00, 0x00, 0xff, 0xff, 0x29, 0x5a, 0xd3, 0x93, 0x1f, 0x18, 0x00, 0x00, } diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/openapiv2.proto b/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/openapiv2.proto index 1fb248ca144afd53ec839417e1ca4304878bec3c..83cb564fa582a3f3430e2c3487a3b11d38e425a4 100644 --- a/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/openapiv2.proto +++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options/openapiv2.proto @@ -5,6 +5,7 @@ package grpc.gateway.protoc_gen_swagger.options; option go_package = "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options"; import "google/protobuf/any.proto"; +import "google/protobuf/struct.proto"; // `Swagger` is a representation of OpenAPI v2 specification's Swagger object. // @@ -45,6 +46,7 @@ message Swagger { // service objects into OpenAPI v2 Tag objects. reserved 13; ExternalDocumentation external_docs = 14; + map extensions = 15; } // `Operation` is a representation of OpenAPI v2 specification's Operation object. @@ -66,6 +68,7 @@ message Operation { repeated string schemes = 10; bool deprecated = 11; repeated SecurityRequirement security = 12; + map extensions = 13; } // `Response` is a representation of OpenAPI v2 specification's Response object. @@ -83,6 +86,7 @@ message Response { reserved 3; // field 3 is reserved for 'example'. reserved 4; + map extensions = 5; } // `Info` is a representation of OpenAPI v2 specification's Info object. @@ -97,6 +101,7 @@ message Info { Contact contact = 4; License license = 5; string version = 6; + map extensions = 7; } // `Contact` is a representation of OpenAPI v2 specification's Contact object. @@ -334,6 +339,7 @@ message SecurityScheme { // // Valid for oauth2. Scopes scopes = 8; + map extensions = 9; } // `SecurityRequirement` is a representation of OpenAPI v2 specification's diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/BUILD.bazel b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/BUILD.bazel index 20862228ef8722dd0ca70cdba24cba1387b41234..819c45a7657fa83f984f35861ff66c14484de8f6 100644 --- a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/BUILD.bazel +++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/BUILD.bazel @@ -27,11 +27,12 @@ go_library( deps = [ "//internal:go_default_library", "//utilities:go_default_library", + "@com_github_golang_protobuf//descriptor:go_default_library_gen", "@com_github_golang_protobuf//jsonpb:go_default_library_gen", "@com_github_golang_protobuf//proto:go_default_library", - "@com_github_golang_protobuf//protoc-gen-go/generator:go_default_library_gen", "@go_googleapis//google/api:httpbody_go_proto", "@io_bazel_rules_go//proto/wkt:any_go_proto", + "@io_bazel_rules_go//proto/wkt:descriptor_go_proto", "@io_bazel_rules_go//proto/wkt:duration_go_proto", "@io_bazel_rules_go//proto/wkt:field_mask_go_proto", "@io_bazel_rules_go//proto/wkt:timestamp_go_proto", @@ -48,6 +49,7 @@ go_test( size = "small", srcs = [ "context_test.go", + "convert_test.go", "errors_test.go", "fieldmask_test.go", "handler_test.go", diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/context.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/context.go index 896057e1e1e108304604e0ac7e27fd4add0c9204..f8083821f3d4b8b3de68521a5055d7d17988e8f7 100644 --- a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/context.go +++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/context.go @@ -57,13 +57,39 @@ except that the forwarded destination is not another HTTP service but rather a gRPC service. */ func AnnotateContext(ctx context.Context, mux *ServeMux, req *http.Request) (context.Context, error) { + ctx, md, err := annotateContext(ctx, mux, req) + if err != nil { + return nil, err + } + if md == nil { + return ctx, nil + } + + return metadata.NewOutgoingContext(ctx, md), nil +} + +// AnnotateIncomingContext adds context information such as metadata from the request. +// Attach metadata as incoming context. +func AnnotateIncomingContext(ctx context.Context, mux *ServeMux, req *http.Request) (context.Context, error) { + ctx, md, err := annotateContext(ctx, mux, req) + if err != nil { + return nil, err + } + if md == nil { + return ctx, nil + } + + return metadata.NewIncomingContext(ctx, md), nil +} + +func annotateContext(ctx context.Context, mux *ServeMux, req *http.Request) (context.Context, metadata.MD, error) { var pairs []string timeout := DefaultContextTimeout if tm := req.Header.Get(metadataGrpcTimeout); tm != "" { var err error timeout, err = timeoutDecode(tm) if err != nil { - return nil, status.Errorf(codes.InvalidArgument, "invalid grpc-timeout: %s", tm) + return nil, nil, status.Errorf(codes.InvalidArgument, "invalid grpc-timeout: %s", tm) } } @@ -80,7 +106,7 @@ func AnnotateContext(ctx context.Context, mux *ServeMux, req *http.Request) (con if strings.HasSuffix(key, metadataHeaderBinarySuffix) { b, err := decodeBinHeader(val) if err != nil { - return nil, status.Errorf(codes.InvalidArgument, "invalid binary header %s: %s", key, err) + return nil, nil, status.Errorf(codes.InvalidArgument, "invalid binary header %s: %s", key, err) } val = string(b) @@ -111,13 +137,13 @@ func AnnotateContext(ctx context.Context, mux *ServeMux, req *http.Request) (con ctx, _ = context.WithTimeout(ctx, timeout) } if len(pairs) == 0 { - return ctx, nil + return ctx, nil, nil } md := metadata.Pairs(pairs...) for _, mda := range mux.metadataAnnotators { md = metadata.Join(md, mda(ctx, req)) } - return metadata.NewOutgoingContext(ctx, md), nil + return ctx, md, nil } // ServerMetadata consists of metadata sent from gRPC server. diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/convert.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/convert.go index a5b3bd6a792c7ba177c5b49a200f4224824ae8f8..2c279344dc414adeda2b7675328afbd4650fee60 100644 --- a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/convert.go +++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/convert.go @@ -206,16 +206,22 @@ func BytesSlice(val, sep string) ([][]byte, error) { // Timestamp converts the given RFC3339 formatted string into a timestamp.Timestamp. func Timestamp(val string) (*timestamp.Timestamp, error) { - var r *timestamp.Timestamp - err := jsonpb.UnmarshalString(val, r) - return r, err + var r timestamp.Timestamp + err := jsonpb.UnmarshalString(val, &r) + if err != nil { + return nil, err + } + return &r, nil } // Duration converts the given string into a timestamp.Duration. func Duration(val string) (*duration.Duration, error) { - var r *duration.Duration - err := jsonpb.UnmarshalString(val, r) - return r, err + var r duration.Duration + err := jsonpb.UnmarshalString(val, &r) + if err != nil { + return nil, err + } + return &r, nil } // Enum converts the given string into an int32 that should be type casted into the diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/errors.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/errors.go index ad945788dc60b039bbdc2f57ab31e1b81024cead..a36080713ce3fd510ade3990596e67eddcfafa0c 100644 --- a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/errors.go +++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/errors.go @@ -66,12 +66,12 @@ var ( ) type errorBody struct { - Error string `protobuf:"bytes,1,name=error" json:"error"` + Error string `protobuf:"bytes,100,name=error" json:"error"` // This is to make the error more compatible with users that expect errors to be Status objects: // https://github.com/grpc/grpc/blob/master/src/proto/grpc/status/status.proto // It should be the exact same message as the Error field. - Message string `protobuf:"bytes,1,name=message" json:"message"` - Code int32 `protobuf:"varint,2,name=code" json:"code"` + Code int32 `protobuf:"varint,1,name=code" json:"code"` + Message string `protobuf:"bytes,2,name=message" json:"message"` Details []*any.Any `protobuf:"bytes,3,rep,name=details" json:"details,omitempty"` } diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/fieldmask.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/fieldmask.go index e1cf7a91461f86bf9473c4d80748abf490dc70e9..341aad5a3ea6cec04d128019f739b5c2f071399d 100644 --- a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/fieldmask.go +++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/fieldmask.go @@ -5,12 +5,37 @@ import ( "io" "strings" - "github.com/golang/protobuf/protoc-gen-go/generator" + descriptor2 "github.com/golang/protobuf/descriptor" + "github.com/golang/protobuf/protoc-gen-go/descriptor" "google.golang.org/genproto/protobuf/field_mask" ) +func translateName(name string, md *descriptor.DescriptorProto) (string, *descriptor.DescriptorProto) { + // TODO - should really gate this with a test that the marshaller has used json names + if md != nil { + for _, f := range md.Field { + if f.JsonName != nil && f.Name != nil && *f.JsonName == name { + var subType *descriptor.DescriptorProto + + // If the field has a TypeName then we retrieve the nested type for translating the embedded message names. + if f.TypeName != nil { + typeSplit := strings.Split(*f.TypeName, ".") + typeName := typeSplit[len(typeSplit)-1] + for _, t := range md.NestedType { + if typeName == *t.Name { + subType = t + } + } + } + return *f.Name, subType + } + } + } + return name, nil +} + // FieldMaskFromRequestBody creates a FieldMask printing all complete paths from the JSON body. -func FieldMaskFromRequestBody(r io.Reader) (*field_mask.FieldMask, error) { +func FieldMaskFromRequestBody(r io.Reader, md *descriptor.DescriptorProto) (*field_mask.FieldMask, error) { fm := &field_mask.FieldMask{} var root interface{} if err := json.NewDecoder(r).Decode(&root); err != nil { @@ -20,7 +45,7 @@ func FieldMaskFromRequestBody(r io.Reader) (*field_mask.FieldMask, error) { return nil, err } - queue := []fieldMaskPathItem{{node: root}} + queue := []fieldMaskPathItem{{node: root, md: md}} for len(queue) > 0 { // dequeue an item item := queue[0] @@ -29,7 +54,11 @@ func FieldMaskFromRequestBody(r io.Reader) (*field_mask.FieldMask, error) { if m, ok := item.node.(map[string]interface{}); ok { // if the item is an object, then enqueue all of its children for k, v := range m { - queue = append(queue, fieldMaskPathItem{path: append(item.path, generator.CamelCase(k)), node: v}) + protoName, subMd := translateName(k, item.md) + if subMsg, ok := v.(descriptor2.Message); ok { + _, subMd = descriptor2.ForMessage(subMsg) + } + queue = append(queue, fieldMaskPathItem{path: append(item.path, protoName), node: v, md: subMd}) } } else if len(item.path) > 0 { // otherwise, it's a leaf node so print its path @@ -47,24 +76,7 @@ type fieldMaskPathItem struct { // a generic decoded json object the current item to inspect for further path extraction node interface{} -} - -// CamelCaseFieldMask updates the given FieldMask by converting all of its paths to CamelCase, using the same heuristic -// that's used for naming protobuf fields in Go. -func CamelCaseFieldMask(mask *field_mask.FieldMask) { - if mask == nil || mask.Paths == nil { - return - } - - var newPaths []string - for _, path := range mask.Paths { - lowerCasedParts := strings.Split(path, ".") - var camelCasedParts []string - for _, part := range lowerCasedParts { - camelCasedParts = append(camelCasedParts, generator.CamelCase(part)) - } - newPaths = append(newPaths, strings.Join(camelCasedParts, ".")) - } - mask.Paths = newPaths + // descriptor for parent message + md *descriptor.DescriptorProto } diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/query.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/query.go index 5fbba5e8e8b5f5d5a69c7b92b84ea9b9357823c0..ee0207e461e0ea9b879e7025a6fa1931ad3a678d 100644 --- a/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/query.go +++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/runtime/query.go @@ -15,15 +15,13 @@ import ( "google.golang.org/grpc/grpclog" ) +var valuesKeyRegexp = regexp.MustCompile("^(.*)\\[(.*)\\]$") + // PopulateQueryParameters populates "values" into "msg". // A value is ignored if its key starts with one of the elements in "filter". func PopulateQueryParameters(msg proto.Message, values url.Values, filter *utilities.DoubleArray) error { for key, values := range values { - re, err := regexp.Compile("^(.*)\\[(.*)\\]$") - if err != nil { - return err - } - match := re.FindStringSubmatch(key) + match := valuesKeyRegexp.FindStringSubmatch(key) if len(match) == 3 { key = match[1] values = append([]string{match[2]}, values...) diff --git a/vendor/github.com/hashicorp/hcl/.gitignore b/vendor/github.com/hashicorp/hcl/.gitignore index 822fa09f527a5c35703685a2aa50a83f902efe9c..15586a2b540d6d58644ff6db5af4378c7fe94bdc 100644 --- a/vendor/github.com/hashicorp/hcl/.gitignore +++ b/vendor/github.com/hashicorp/hcl/.gitignore @@ -1,9 +1,9 @@ -y.output - -# ignore intellij files -.idea -*.iml -*.ipr -*.iws - -*.test +y.output + +# ignore intellij files +.idea +*.iml +*.ipr +*.iws + +*.test diff --git a/vendor/github.com/hashicorp/hcl/Makefile b/vendor/github.com/hashicorp/hcl/Makefile index 9fafd5017cfab5a4505dec97f541c2efe96c2dde..84fd743f5cc28a747e8004be2adad093e5ca65cf 100644 --- a/vendor/github.com/hashicorp/hcl/Makefile +++ b/vendor/github.com/hashicorp/hcl/Makefile @@ -1,18 +1,18 @@ -TEST?=./... - -default: test - -fmt: generate - go fmt ./... - -test: generate - go get -t ./... - go test $(TEST) $(TESTARGS) - -generate: - go generate ./... - -updatedeps: - go get -u golang.org/x/tools/cmd/stringer - -.PHONY: default generate test updatedeps +TEST?=./... + +default: test + +fmt: generate + go fmt ./... + +test: generate + go get -t ./... + go test $(TEST) $(TESTARGS) + +generate: + go generate ./... + +updatedeps: + go get -u golang.org/x/tools/cmd/stringer + +.PHONY: default generate test updatedeps diff --git a/vendor/github.com/pelletier/go-toml/example-crlf.toml b/vendor/github.com/pelletier/go-toml/example-crlf.toml index 3d902f28207e12f34bb16065c23a8253098eca45..12950a163d33e15fe5901393b9f10df1c1ee74a1 100644 --- a/vendor/github.com/pelletier/go-toml/example-crlf.toml +++ b/vendor/github.com/pelletier/go-toml/example-crlf.toml @@ -1,29 +1,29 @@ -# This is a TOML document. Boom. - -title = "TOML Example" - -[owner] -name = "Tom Preston-Werner" -organization = "GitHub" -bio = "GitHub Cofounder & CEO\nLikes tater tots and beer." -dob = 1979-05-27T07:32:00Z # First class dates? Why not? - -[database] -server = "192.168.1.1" -ports = [ 8001, 8001, 8002 ] -connection_max = 5000 -enabled = true - -[servers] - - # You can indent as you please. Tabs or spaces. TOML don't care. - [servers.alpha] - ip = "10.0.0.1" - dc = "eqdc10" - - [servers.beta] - ip = "10.0.0.2" - dc = "eqdc10" - -[clients] -data = [ ["gamma", "delta"], [1, 2] ] # just an update to make sure parsers support it +# This is a TOML document. Boom. + +title = "TOML Example" + +[owner] +name = "Tom Preston-Werner" +organization = "GitHub" +bio = "GitHub Cofounder & CEO\nLikes tater tots and beer." +dob = 1979-05-27T07:32:00Z # First class dates? Why not? + +[database] +server = "192.168.1.1" +ports = [ 8001, 8001, 8002 ] +connection_max = 5000 +enabled = true + +[servers] + + # You can indent as you please. Tabs or spaces. TOML don't care. + [servers.alpha] + ip = "10.0.0.1" + dc = "eqdc10" + + [servers.beta] + ip = "10.0.0.2" + dc = "eqdc10" + +[clients] +data = [ ["gamma", "delta"], [1, 2] ] # just an update to make sure parsers support it diff --git a/vendor/github.com/sirupsen/logrus/appveyor.yml b/vendor/github.com/sirupsen/logrus/appveyor.yml index b4ffca2758c8e01190f2bffe484d65b31763cc27..96c2ce15f842b92c87952ba5702d33c37ccf1344 100644 --- a/vendor/github.com/sirupsen/logrus/appveyor.yml +++ b/vendor/github.com/sirupsen/logrus/appveyor.yml @@ -1,14 +1,14 @@ -version: "{build}" -platform: x64 -clone_folder: c:\gopath\src\github.com\sirupsen\logrus -environment: - GOPATH: c:\gopath -branches: - only: - - master -install: - - set PATH=%GOPATH%\bin;c:\go\bin;%PATH% - - go version -build_script: - - go get -t - - go test +version: "{build}" +platform: x64 +clone_folder: c:\gopath\src\github.com\sirupsen\logrus +environment: + GOPATH: c:\gopath +branches: + only: + - master +install: + - set PATH=%GOPATH%\bin;c:\go\bin;%PATH% + - go version +build_script: + - go get -t + - go test diff --git a/vendor/github.com/spf13/afero/.travis.yml b/vendor/github.com/spf13/afero/.travis.yml index 8fc1261cb7913c4dd0c652f9df6892a9fa3ac024..0637db726dee970868dea6a9c05ff2728371c378 100644 --- a/vendor/github.com/spf13/afero/.travis.yml +++ b/vendor/github.com/spf13/afero/.travis.yml @@ -1,21 +1,21 @@ -sudo: false -language: go - -go: - - 1.9 - - "1.10" - - tip - -os: - - linux - - osx - -matrix: - allow_failures: - - go: tip - fast_finish: true - -script: - - go build - - go test -race -v ./... - +sudo: false +language: go + +go: + - 1.9 + - "1.10" + - tip + +os: + - linux + - osx + +matrix: + allow_failures: + - go: tip + fast_finish: true + +script: + - go build + - go test -race -v ./... + diff --git a/vendor/golang.org/x/net/html/atom/gen.go b/vendor/golang.org/x/net/html/atom/gen.go deleted file mode 100644 index 5d052781bceaf8504923cff6da7d4a5f22044169..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/net/html/atom/gen.go +++ /dev/null @@ -1,712 +0,0 @@ -// Copyright 2012 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -//go:generate go run gen.go -//go:generate go run gen.go -test - -package main - -import ( - "bytes" - "flag" - "fmt" - "go/format" - "io/ioutil" - "math/rand" - "os" - "sort" - "strings" -) - -// identifier converts s to a Go exported identifier. -// It converts "div" to "Div" and "accept-charset" to "AcceptCharset". -func identifier(s string) string { - b := make([]byte, 0, len(s)) - cap := true - for _, c := range s { - if c == '-' { - cap = true - continue - } - if cap && 'a' <= c && c <= 'z' { - c -= 'a' - 'A' - } - cap = false - b = append(b, byte(c)) - } - return string(b) -} - -var test = flag.Bool("test", false, "generate table_test.go") - -func genFile(name string, buf *bytes.Buffer) { - b, err := format.Source(buf.Bytes()) - if err != nil { - fmt.Fprintln(os.Stderr, err) - os.Exit(1) - } - if err := ioutil.WriteFile(name, b, 0644); err != nil { - fmt.Fprintln(os.Stderr, err) - os.Exit(1) - } -} - -func main() { - flag.Parse() - - var all []string - all = append(all, elements...) - all = append(all, attributes...) - all = append(all, eventHandlers...) - all = append(all, extra...) - sort.Strings(all) - - // uniq - lists have dups - w := 0 - for _, s := range all { - if w == 0 || all[w-1] != s { - all[w] = s - w++ - } - } - all = all[:w] - - if *test { - var buf bytes.Buffer - fmt.Fprintln(&buf, "// Code generated by go generate gen.go; DO NOT EDIT.\n") - fmt.Fprintln(&buf, "//go:generate go run gen.go -test\n") - fmt.Fprintln(&buf, "package atom\n") - fmt.Fprintln(&buf, "var testAtomList = []string{") - for _, s := range all { - fmt.Fprintf(&buf, "\t%q,\n", s) - } - fmt.Fprintln(&buf, "}") - - genFile("table_test.go", &buf) - return - } - - // Find hash that minimizes table size. - var best *table - for i := 0; i < 1000000; i++ { - if best != nil && 1<<(best.k-1) < len(all) { - break - } - h := rand.Uint32() - for k := uint(0); k <= 16; k++ { - if best != nil && k >= best.k { - break - } - var t table - if t.init(h, k, all) { - best = &t - break - } - } - } - if best == nil { - fmt.Fprintf(os.Stderr, "failed to construct string table\n") - os.Exit(1) - } - - // Lay out strings, using overlaps when possible. - layout := append([]string{}, all...) - - // Remove strings that are substrings of other strings - for changed := true; changed; { - changed = false - for i, s := range layout { - if s == "" { - continue - } - for j, t := range layout { - if i != j && t != "" && strings.Contains(s, t) { - changed = true - layout[j] = "" - } - } - } - } - - // Join strings where one suffix matches another prefix. - for { - // Find best i, j, k such that layout[i][len-k:] == layout[j][:k], - // maximizing overlap length k. - besti := -1 - bestj := -1 - bestk := 0 - for i, s := range layout { - if s == "" { - continue - } - for j, t := range layout { - if i == j { - continue - } - for k := bestk + 1; k <= len(s) && k <= len(t); k++ { - if s[len(s)-k:] == t[:k] { - besti = i - bestj = j - bestk = k - } - } - } - } - if bestk > 0 { - layout[besti] += layout[bestj][bestk:] - layout[bestj] = "" - continue - } - break - } - - text := strings.Join(layout, "") - - atom := map[string]uint32{} - for _, s := range all { - off := strings.Index(text, s) - if off < 0 { - panic("lost string " + s) - } - atom[s] = uint32(off<<8 | len(s)) - } - - var buf bytes.Buffer - // Generate the Go code. - fmt.Fprintln(&buf, "// Code generated by go generate gen.go; DO NOT EDIT.\n") - fmt.Fprintln(&buf, "//go:generate go run gen.go\n") - fmt.Fprintln(&buf, "package atom\n\nconst (") - - // compute max len - maxLen := 0 - for _, s := range all { - if maxLen < len(s) { - maxLen = len(s) - } - fmt.Fprintf(&buf, "\t%s Atom = %#x\n", identifier(s), atom[s]) - } - fmt.Fprintln(&buf, ")\n") - - fmt.Fprintf(&buf, "const hash0 = %#x\n\n", best.h0) - fmt.Fprintf(&buf, "const maxAtomLen = %d\n\n", maxLen) - - fmt.Fprintf(&buf, "var table = [1<<%d]Atom{\n", best.k) - for i, s := range best.tab { - if s == "" { - continue - } - fmt.Fprintf(&buf, "\t%#x: %#x, // %s\n", i, atom[s], s) - } - fmt.Fprintf(&buf, "}\n") - datasize := (1 << best.k) * 4 - - fmt.Fprintln(&buf, "const atomText =") - textsize := len(text) - for len(text) > 60 { - fmt.Fprintf(&buf, "\t%q +\n", text[:60]) - text = text[60:] - } - fmt.Fprintf(&buf, "\t%q\n\n", text) - - genFile("table.go", &buf) - - fmt.Fprintf(os.Stdout, "%d atoms; %d string bytes + %d tables = %d total data\n", len(all), textsize, datasize, textsize+datasize) -} - -type byLen []string - -func (x byLen) Less(i, j int) bool { return len(x[i]) > len(x[j]) } -func (x byLen) Swap(i, j int) { x[i], x[j] = x[j], x[i] } -func (x byLen) Len() int { return len(x) } - -// fnv computes the FNV hash with an arbitrary starting value h. -func fnv(h uint32, s string) uint32 { - for i := 0; i < len(s); i++ { - h ^= uint32(s[i]) - h *= 16777619 - } - return h -} - -// A table represents an attempt at constructing the lookup table. -// The lookup table uses cuckoo hashing, meaning that each string -// can be found in one of two positions. -type table struct { - h0 uint32 - k uint - mask uint32 - tab []string -} - -// hash returns the two hashes for s. -func (t *table) hash(s string) (h1, h2 uint32) { - h := fnv(t.h0, s) - h1 = h & t.mask - h2 = (h >> 16) & t.mask - return -} - -// init initializes the table with the given parameters. -// h0 is the initial hash value, -// k is the number of bits of hash value to use, and -// x is the list of strings to store in the table. -// init returns false if the table cannot be constructed. -func (t *table) init(h0 uint32, k uint, x []string) bool { - t.h0 = h0 - t.k = k - t.tab = make([]string, 1< len(t.tab) { - return false - } - s := t.tab[i] - h1, h2 := t.hash(s) - j := h1 + h2 - i - if t.tab[j] != "" && !t.push(j, depth+1) { - return false - } - t.tab[j] = s - return true -} - -// The lists of element names and attribute keys were taken from -// https://html.spec.whatwg.org/multipage/indices.html#index -// as of the "HTML Living Standard - Last Updated 16 April 2018" version. - -// "command", "keygen" and "menuitem" have been removed from the spec, -// but are kept here for backwards compatibility. -var elements = []string{ - "a", - "abbr", - "address", - "area", - "article", - "aside", - "audio", - "b", - "base", - "bdi", - "bdo", - "blockquote", - "body", - "br", - "button", - "canvas", - "caption", - "cite", - "code", - "col", - "colgroup", - "command", - "data", - "datalist", - "dd", - "del", - "details", - "dfn", - "dialog", - "div", - "dl", - "dt", - "em", - "embed", - "fieldset", - "figcaption", - "figure", - "footer", - "form", - "h1", - "h2", - "h3", - "h4", - "h5", - "h6", - "head", - "header", - "hgroup", - "hr", - "html", - "i", - "iframe", - "img", - "input", - "ins", - "kbd", - "keygen", - "label", - "legend", - "li", - "link", - "main", - "map", - "mark", - "menu", - "menuitem", - "meta", - "meter", - "nav", - "noscript", - "object", - "ol", - "optgroup", - "option", - "output", - "p", - "param", - "picture", - "pre", - "progress", - "q", - "rp", - "rt", - "ruby", - "s", - "samp", - "script", - "section", - "select", - "slot", - "small", - "source", - "span", - "strong", - "style", - "sub", - "summary", - "sup", - "table", - "tbody", - "td", - "template", - "textarea", - "tfoot", - "th", - "thead", - "time", - "title", - "tr", - "track", - "u", - "ul", - "var", - "video", - "wbr", -} - -// https://html.spec.whatwg.org/multipage/indices.html#attributes-3 -// -// "challenge", "command", "contextmenu", "dropzone", "icon", "keytype", "mediagroup", -// "radiogroup", "spellcheck", "scoped", "seamless", "sortable" and "sorted" have been removed from the spec, -// but are kept here for backwards compatibility. -var attributes = []string{ - "abbr", - "accept", - "accept-charset", - "accesskey", - "action", - "allowfullscreen", - "allowpaymentrequest", - "allowusermedia", - "alt", - "as", - "async", - "autocomplete", - "autofocus", - "autoplay", - "challenge", - "charset", - "checked", - "cite", - "class", - "color", - "cols", - "colspan", - "command", - "content", - "contenteditable", - "contextmenu", - "controls", - "coords", - "crossorigin", - "data", - "datetime", - "default", - "defer", - "dir", - "dirname", - "disabled", - "download", - "draggable", - "dropzone", - "enctype", - "for", - "form", - "formaction", - "formenctype", - "formmethod", - "formnovalidate", - "formtarget", - "headers", - "height", - "hidden", - "high", - "href", - "hreflang", - "http-equiv", - "icon", - "id", - "inputmode", - "integrity", - "is", - "ismap", - "itemid", - "itemprop", - "itemref", - "itemscope", - "itemtype", - "keytype", - "kind", - "label", - "lang", - "list", - "loop", - "low", - "manifest", - "max", - "maxlength", - "media", - "mediagroup", - "method", - "min", - "minlength", - "multiple", - "muted", - "name", - "nomodule", - "nonce", - "novalidate", - "open", - "optimum", - "pattern", - "ping", - "placeholder", - "playsinline", - "poster", - "preload", - "radiogroup", - "readonly", - "referrerpolicy", - "rel", - "required", - "reversed", - "rows", - "rowspan", - "sandbox", - "spellcheck", - "scope", - "scoped", - "seamless", - "selected", - "shape", - "size", - "sizes", - "sortable", - "sorted", - "slot", - "span", - "spellcheck", - "src", - "srcdoc", - "srclang", - "srcset", - "start", - "step", - "style", - "tabindex", - "target", - "title", - "translate", - "type", - "typemustmatch", - "updateviacache", - "usemap", - "value", - "width", - "workertype", - "wrap", -} - -// "onautocomplete", "onautocompleteerror", "onmousewheel", -// "onshow" and "onsort" have been removed from the spec, -// but are kept here for backwards compatibility. -var eventHandlers = []string{ - "onabort", - "onautocomplete", - "onautocompleteerror", - "onauxclick", - "onafterprint", - "onbeforeprint", - "onbeforeunload", - "onblur", - "oncancel", - "oncanplay", - "oncanplaythrough", - "onchange", - "onclick", - "onclose", - "oncontextmenu", - "oncopy", - "oncuechange", - "oncut", - "ondblclick", - "ondrag", - "ondragend", - "ondragenter", - "ondragexit", - "ondragleave", - "ondragover", - "ondragstart", - "ondrop", - "ondurationchange", - "onemptied", - "onended", - "onerror", - "onfocus", - "onhashchange", - "oninput", - "oninvalid", - "onkeydown", - "onkeypress", - "onkeyup", - "onlanguagechange", - "onload", - "onloadeddata", - "onloadedmetadata", - "onloadend", - "onloadstart", - "onmessage", - "onmessageerror", - "onmousedown", - "onmouseenter", - "onmouseleave", - "onmousemove", - "onmouseout", - "onmouseover", - "onmouseup", - "onmousewheel", - "onwheel", - "onoffline", - "ononline", - "onpagehide", - "onpageshow", - "onpaste", - "onpause", - "onplay", - "onplaying", - "onpopstate", - "onprogress", - "onratechange", - "onreset", - "onresize", - "onrejectionhandled", - "onscroll", - "onsecuritypolicyviolation", - "onseeked", - "onseeking", - "onselect", - "onshow", - "onsort", - "onstalled", - "onstorage", - "onsubmit", - "onsuspend", - "ontimeupdate", - "ontoggle", - "onunhandledrejection", - "onunload", - "onvolumechange", - "onwaiting", -} - -// extra are ad-hoc values not covered by any of the lists above. -var extra = []string{ - "acronym", - "align", - "annotation", - "annotation-xml", - "applet", - "basefont", - "bgsound", - "big", - "blink", - "center", - "color", - "desc", - "face", - "font", - "foreignObject", // HTML is case-insensitive, but SVG-embedded-in-HTML is case-sensitive. - "foreignobject", - "frame", - "frameset", - "image", - "isindex", - "listing", - "malignmark", - "marquee", - "math", - "mglyph", - "mi", - "mn", - "mo", - "ms", - "mtext", - "nobr", - "noembed", - "noframes", - "plaintext", - "prompt", - "public", - "rb", - "rtc", - "spacer", - "strike", - "svg", - "system", - "tt", - "xmp", -} diff --git a/vendor/golang.org/x/sys/unix/mkasm_darwin.go b/vendor/golang.org/x/sys/unix/mkasm_darwin.go deleted file mode 100644 index 4548b993dbcc52a83ba7e944a6d7d8dd9de3b049..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/mkasm_darwin.go +++ /dev/null @@ -1,61 +0,0 @@ -// Copyright 2018 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -// mkasm_darwin.go generates assembly trampolines to call libSystem routines from Go. -//This program must be run after mksyscall.go. -package main - -import ( - "bytes" - "fmt" - "io/ioutil" - "log" - "os" - "strings" -) - -func main() { - in1, err := ioutil.ReadFile("syscall_darwin.go") - if err != nil { - log.Fatalf("can't open syscall_darwin.go: %s", err) - } - arch := os.Args[1] - in2, err := ioutil.ReadFile(fmt.Sprintf("syscall_darwin_%s.go", arch)) - if err != nil { - log.Fatalf("can't open syscall_darwin_%s.go: %s", arch, err) - } - in3, err := ioutil.ReadFile(fmt.Sprintf("zsyscall_darwin_%s.go", arch)) - if err != nil { - log.Fatalf("can't open zsyscall_darwin_%s.go: %s", arch, err) - } - in := string(in1) + string(in2) + string(in3) - - trampolines := map[string]bool{} - - var out bytes.Buffer - - fmt.Fprintf(&out, "// go run mkasm_darwin.go %s\n", strings.Join(os.Args[1:], " ")) - fmt.Fprintf(&out, "// Code generated by the command above; DO NOT EDIT.\n") - fmt.Fprintf(&out, "\n") - fmt.Fprintf(&out, "// +build go1.12\n") - fmt.Fprintf(&out, "\n") - fmt.Fprintf(&out, "#include \"textflag.h\"\n") - for _, line := range strings.Split(in, "\n") { - if !strings.HasPrefix(line, "func ") || !strings.HasSuffix(line, "_trampoline()") { - continue - } - fn := line[5 : len(line)-13] - if !trampolines[fn] { - trampolines[fn] = true - fmt.Fprintf(&out, "TEXT ·%s_trampoline(SB),NOSPLIT,$0-0\n", fn) - fmt.Fprintf(&out, "\tJMP\t%s(SB)\n", fn) - } - } - err = ioutil.WriteFile(fmt.Sprintf("zsyscall_darwin_%s.s", arch), out.Bytes(), 0644) - if err != nil { - log.Fatalf("can't write zsyscall_darwin_%s.s: %s", arch, err) - } -} diff --git a/vendor/golang.org/x/sys/unix/mkpost.go b/vendor/golang.org/x/sys/unix/mkpost.go deleted file mode 100644 index 9feddd00c4b4d018e68fed15380c2a3be4bcd17d..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/mkpost.go +++ /dev/null @@ -1,106 +0,0 @@ -// Copyright 2016 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -// mkpost processes the output of cgo -godefs to -// modify the generated types. It is used to clean up -// the sys API in an architecture specific manner. -// -// mkpost is run after cgo -godefs; see README.md. -package main - -import ( - "bytes" - "fmt" - "go/format" - "io/ioutil" - "log" - "os" - "regexp" -) - -func main() { - // Get the OS and architecture (using GOARCH_TARGET if it exists) - goos := os.Getenv("GOOS") - goarch := os.Getenv("GOARCH_TARGET") - if goarch == "" { - goarch = os.Getenv("GOARCH") - } - // Check that we are using the Docker-based build system if we should be. - if goos == "linux" { - if os.Getenv("GOLANG_SYS_BUILD") != "docker" { - os.Stderr.WriteString("In the Docker-based build system, mkpost should not be called directly.\n") - os.Stderr.WriteString("See README.md\n") - os.Exit(1) - } - } - - b, err := ioutil.ReadAll(os.Stdin) - if err != nil { - log.Fatal(err) - } - - // Intentionally export __val fields in Fsid and Sigset_t - valRegex := regexp.MustCompile(`type (Fsid|Sigset_t) struct {(\s+)X__val(\s+\S+\s+)}`) - b = valRegex.ReplaceAll(b, []byte("type $1 struct {${2}Val$3}")) - - // Intentionally export __fds_bits field in FdSet - fdSetRegex := regexp.MustCompile(`type (FdSet) struct {(\s+)X__fds_bits(\s+\S+\s+)}`) - b = fdSetRegex.ReplaceAll(b, []byte("type $1 struct {${2}Bits$3}")) - - // If we have empty Ptrace structs, we should delete them. Only s390x emits - // nonempty Ptrace structs. - ptraceRexexp := regexp.MustCompile(`type Ptrace((Psw|Fpregs|Per) struct {\s*})`) - b = ptraceRexexp.ReplaceAll(b, nil) - - // Replace the control_regs union with a blank identifier for now. - controlRegsRegex := regexp.MustCompile(`(Control_regs)\s+\[0\]uint64`) - b = controlRegsRegex.ReplaceAll(b, []byte("_ [0]uint64")) - - // Remove fields that are added by glibc - // Note that this is unstable as the identifers are private. - removeFieldsRegex := regexp.MustCompile(`X__glibc\S*`) - b = removeFieldsRegex.ReplaceAll(b, []byte("_")) - - // Convert [65]int8 to [65]byte in Utsname members to simplify - // conversion to string; see golang.org/issue/20753 - convertUtsnameRegex := regexp.MustCompile(`((Sys|Node|Domain)name|Release|Version|Machine)(\s+)\[(\d+)\]u?int8`) - b = convertUtsnameRegex.ReplaceAll(b, []byte("$1$3[$4]byte")) - - // Convert [1024]int8 to [1024]byte in Ptmget members - convertPtmget := regexp.MustCompile(`([SC]n)(\s+)\[(\d+)\]u?int8`) - b = convertPtmget.ReplaceAll(b, []byte("$1[$3]byte")) - - // Remove spare fields (e.g. in Statx_t) - spareFieldsRegex := regexp.MustCompile(`X__spare\S*`) - b = spareFieldsRegex.ReplaceAll(b, []byte("_")) - - // Remove cgo padding fields - removePaddingFieldsRegex := regexp.MustCompile(`Pad_cgo_\d+`) - b = removePaddingFieldsRegex.ReplaceAll(b, []byte("_")) - - // Remove padding, hidden, or unused fields - removeFieldsRegex = regexp.MustCompile(`\b(X_\S+|Padding)`) - b = removeFieldsRegex.ReplaceAll(b, []byte("_")) - - // Remove the first line of warning from cgo - b = b[bytes.IndexByte(b, '\n')+1:] - // Modify the command in the header to include: - // mkpost, our own warning, and a build tag. - replacement := fmt.Sprintf(`$1 | go run mkpost.go -// Code generated by the command above; see README.md. DO NOT EDIT. - -// +build %s,%s`, goarch, goos) - cgoCommandRegex := regexp.MustCompile(`(cgo -godefs .*)`) - b = cgoCommandRegex.ReplaceAll(b, []byte(replacement)) - - // gofmt - b, err = format.Source(b) - if err != nil { - log.Fatal(err) - } - - os.Stdout.Write(b) -} diff --git a/vendor/golang.org/x/sys/unix/mksyscall.go b/vendor/golang.org/x/sys/unix/mksyscall.go deleted file mode 100644 index e06e4253ea3c3a7f03f49eb0662806808cb4e4c5..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/mksyscall.go +++ /dev/null @@ -1,402 +0,0 @@ -// Copyright 2018 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -/* -This program reads a file containing function prototypes -(like syscall_darwin.go) and generates system call bodies. -The prototypes are marked by lines beginning with "//sys" -and read like func declarations if //sys is replaced by func, but: - * The parameter lists must give a name for each argument. - This includes return parameters. - * The parameter lists must give a type for each argument: - the (x, y, z int) shorthand is not allowed. - * If the return parameter is an error number, it must be named errno. - -A line beginning with //sysnb is like //sys, except that the -goroutine will not be suspended during the execution of the system -call. This must only be used for system calls which can never -block, as otherwise the system call could cause all goroutines to -hang. -*/ -package main - -import ( - "bufio" - "flag" - "fmt" - "os" - "regexp" - "strings" -) - -var ( - b32 = flag.Bool("b32", false, "32bit big-endian") - l32 = flag.Bool("l32", false, "32bit little-endian") - plan9 = flag.Bool("plan9", false, "plan9") - openbsd = flag.Bool("openbsd", false, "openbsd") - netbsd = flag.Bool("netbsd", false, "netbsd") - dragonfly = flag.Bool("dragonfly", false, "dragonfly") - arm = flag.Bool("arm", false, "arm") // 64-bit value should use (even, odd)-pair - tags = flag.String("tags", "", "build tags") - filename = flag.String("output", "", "output file name (standard output if omitted)") -) - -// cmdLine returns this programs's commandline arguments -func cmdLine() string { - return "go run mksyscall.go " + strings.Join(os.Args[1:], " ") -} - -// buildTags returns build tags -func buildTags() string { - return *tags -} - -// Param is function parameter -type Param struct { - Name string - Type string -} - -// usage prints the program usage -func usage() { - fmt.Fprintf(os.Stderr, "usage: go run mksyscall.go [-b32 | -l32] [-tags x,y] [file ...]\n") - os.Exit(1) -} - -// parseParamList parses parameter list and returns a slice of parameters -func parseParamList(list string) []string { - list = strings.TrimSpace(list) - if list == "" { - return []string{} - } - return regexp.MustCompile(`\s*,\s*`).Split(list, -1) -} - -// parseParam splits a parameter into name and type -func parseParam(p string) Param { - ps := regexp.MustCompile(`^(\S*) (\S*)$`).FindStringSubmatch(p) - if ps == nil { - fmt.Fprintf(os.Stderr, "malformed parameter: %s\n", p) - os.Exit(1) - } - return Param{ps[1], ps[2]} -} - -func main() { - // Get the OS and architecture (using GOARCH_TARGET if it exists) - goos := os.Getenv("GOOS") - if goos == "" { - fmt.Fprintln(os.Stderr, "GOOS not defined in environment") - os.Exit(1) - } - goarch := os.Getenv("GOARCH_TARGET") - if goarch == "" { - goarch = os.Getenv("GOARCH") - } - - // Check that we are using the Docker-based build system if we should - if goos == "linux" { - if os.Getenv("GOLANG_SYS_BUILD") != "docker" { - fmt.Fprintf(os.Stderr, "In the Docker-based build system, mksyscall should not be called directly.\n") - fmt.Fprintf(os.Stderr, "See README.md\n") - os.Exit(1) - } - } - - flag.Usage = usage - flag.Parse() - if len(flag.Args()) <= 0 { - fmt.Fprintf(os.Stderr, "no files to parse provided\n") - usage() - } - - endianness := "" - if *b32 { - endianness = "big-endian" - } else if *l32 { - endianness = "little-endian" - } - - libc := false - if goos == "darwin" && strings.Contains(buildTags(), ",go1.12") { - libc = true - } - trampolines := map[string]bool{} - - text := "" - for _, path := range flag.Args() { - file, err := os.Open(path) - if err != nil { - fmt.Fprintf(os.Stderr, err.Error()) - os.Exit(1) - } - s := bufio.NewScanner(file) - for s.Scan() { - t := s.Text() - t = strings.TrimSpace(t) - t = regexp.MustCompile(`\s+`).ReplaceAllString(t, ` `) - nonblock := regexp.MustCompile(`^\/\/sysnb `).FindStringSubmatch(t) - if regexp.MustCompile(`^\/\/sys `).FindStringSubmatch(t) == nil && nonblock == nil { - continue - } - - // Line must be of the form - // func Open(path string, mode int, perm int) (fd int, errno error) - // Split into name, in params, out params. - f := regexp.MustCompile(`^\/\/sys(nb)? (\w+)\(([^()]*)\)\s*(?:\(([^()]+)\))?\s*(?:=\s*((?i)SYS_[A-Z0-9_]+))?$`).FindStringSubmatch(t) - if f == nil { - fmt.Fprintf(os.Stderr, "%s:%s\nmalformed //sys declaration\n", path, t) - os.Exit(1) - } - funct, inps, outps, sysname := f[2], f[3], f[4], f[5] - - // Split argument lists on comma. - in := parseParamList(inps) - out := parseParamList(outps) - - // Try in vain to keep people from editing this file. - // The theory is that they jump into the middle of the file - // without reading the header. - text += "// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT\n\n" - - // Go function header. - outDecl := "" - if len(out) > 0 { - outDecl = fmt.Sprintf(" (%s)", strings.Join(out, ", ")) - } - text += fmt.Sprintf("func %s(%s)%s {\n", funct, strings.Join(in, ", "), outDecl) - - // Check if err return available - errvar := "" - for _, param := range out { - p := parseParam(param) - if p.Type == "error" { - errvar = p.Name - break - } - } - - // Prepare arguments to Syscall. - var args []string - n := 0 - for _, param := range in { - p := parseParam(param) - if regexp.MustCompile(`^\*`).FindStringSubmatch(p.Type) != nil { - args = append(args, "uintptr(unsafe.Pointer("+p.Name+"))") - } else if p.Type == "string" && errvar != "" { - text += fmt.Sprintf("\tvar _p%d *byte\n", n) - text += fmt.Sprintf("\t_p%d, %s = BytePtrFromString(%s)\n", n, errvar, p.Name) - text += fmt.Sprintf("\tif %s != nil {\n\t\treturn\n\t}\n", errvar) - args = append(args, fmt.Sprintf("uintptr(unsafe.Pointer(_p%d))", n)) - n++ - } else if p.Type == "string" { - fmt.Fprintf(os.Stderr, path+":"+funct+" uses string arguments, but has no error return\n") - text += fmt.Sprintf("\tvar _p%d *byte\n", n) - text += fmt.Sprintf("\t_p%d, _ = BytePtrFromString(%s)\n", n, p.Name) - args = append(args, fmt.Sprintf("uintptr(unsafe.Pointer(_p%d))", n)) - n++ - } else if regexp.MustCompile(`^\[\](.*)`).FindStringSubmatch(p.Type) != nil { - // Convert slice into pointer, length. - // Have to be careful not to take address of &a[0] if len == 0: - // pass dummy pointer in that case. - // Used to pass nil, but some OSes or simulators reject write(fd, nil, 0). - text += fmt.Sprintf("\tvar _p%d unsafe.Pointer\n", n) - text += fmt.Sprintf("\tif len(%s) > 0 {\n\t\t_p%d = unsafe.Pointer(&%s[0])\n\t}", p.Name, n, p.Name) - text += fmt.Sprintf(" else {\n\t\t_p%d = unsafe.Pointer(&_zero)\n\t}\n", n) - args = append(args, fmt.Sprintf("uintptr(_p%d)", n), fmt.Sprintf("uintptr(len(%s))", p.Name)) - n++ - } else if p.Type == "int64" && (*openbsd || *netbsd) { - args = append(args, "0") - if endianness == "big-endian" { - args = append(args, fmt.Sprintf("uintptr(%s>>32)", p.Name), fmt.Sprintf("uintptr(%s)", p.Name)) - } else if endianness == "little-endian" { - args = append(args, fmt.Sprintf("uintptr(%s)", p.Name), fmt.Sprintf("uintptr(%s>>32)", p.Name)) - } else { - args = append(args, fmt.Sprintf("uintptr(%s)", p.Name)) - } - } else if p.Type == "int64" && *dragonfly { - if regexp.MustCompile(`^(?i)extp(read|write)`).FindStringSubmatch(funct) == nil { - args = append(args, "0") - } - if endianness == "big-endian" { - args = append(args, fmt.Sprintf("uintptr(%s>>32)", p.Name), fmt.Sprintf("uintptr(%s)", p.Name)) - } else if endianness == "little-endian" { - args = append(args, fmt.Sprintf("uintptr(%s)", p.Name), fmt.Sprintf("uintptr(%s>>32)", p.Name)) - } else { - args = append(args, fmt.Sprintf("uintptr(%s)", p.Name)) - } - } else if p.Type == "int64" && endianness != "" { - if len(args)%2 == 1 && *arm { - // arm abi specifies 64-bit argument uses - // (even, odd) pair - args = append(args, "0") - } - if endianness == "big-endian" { - args = append(args, fmt.Sprintf("uintptr(%s>>32)", p.Name), fmt.Sprintf("uintptr(%s)", p.Name)) - } else { - args = append(args, fmt.Sprintf("uintptr(%s)", p.Name), fmt.Sprintf("uintptr(%s>>32)", p.Name)) - } - } else { - args = append(args, fmt.Sprintf("uintptr(%s)", p.Name)) - } - } - - // Determine which form to use; pad args with zeros. - asm := "Syscall" - if nonblock != nil { - if errvar == "" && goos == "linux" { - asm = "RawSyscallNoError" - } else { - asm = "RawSyscall" - } - } else { - if errvar == "" && goos == "linux" { - asm = "SyscallNoError" - } - } - if len(args) <= 3 { - for len(args) < 3 { - args = append(args, "0") - } - } else if len(args) <= 6 { - asm += "6" - for len(args) < 6 { - args = append(args, "0") - } - } else if len(args) <= 9 { - asm += "9" - for len(args) < 9 { - args = append(args, "0") - } - } else { - fmt.Fprintf(os.Stderr, "%s:%s too many arguments to system call\n", path, funct) - } - - // System call number. - if sysname == "" { - sysname = "SYS_" + funct - sysname = regexp.MustCompile(`([a-z])([A-Z])`).ReplaceAllString(sysname, `${1}_$2`) - sysname = strings.ToUpper(sysname) - } - - var libcFn string - if libc { - asm = "syscall_" + strings.ToLower(asm[:1]) + asm[1:] // internal syscall call - sysname = strings.TrimPrefix(sysname, "SYS_") // remove SYS_ - sysname = strings.ToLower(sysname) // lowercase - if sysname == "getdirentries64" { - // Special case - libSystem name and - // raw syscall name don't match. - sysname = "__getdirentries64" - } - libcFn = sysname - sysname = "funcPC(libc_" + sysname + "_trampoline)" - } - - // Actual call. - arglist := strings.Join(args, ", ") - call := fmt.Sprintf("%s(%s, %s)", asm, sysname, arglist) - - // Assign return values. - body := "" - ret := []string{"_", "_", "_"} - doErrno := false - for i := 0; i < len(out); i++ { - p := parseParam(out[i]) - reg := "" - if p.Name == "err" && !*plan9 { - reg = "e1" - ret[2] = reg - doErrno = true - } else if p.Name == "err" && *plan9 { - ret[0] = "r0" - ret[2] = "e1" - break - } else { - reg = fmt.Sprintf("r%d", i) - ret[i] = reg - } - if p.Type == "bool" { - reg = fmt.Sprintf("%s != 0", reg) - } - if p.Type == "int64" && endianness != "" { - // 64-bit number in r1:r0 or r0:r1. - if i+2 > len(out) { - fmt.Fprintf(os.Stderr, "%s:%s not enough registers for int64 return\n", path, funct) - } - if endianness == "big-endian" { - reg = fmt.Sprintf("int64(r%d)<<32 | int64(r%d)", i, i+1) - } else { - reg = fmt.Sprintf("int64(r%d)<<32 | int64(r%d)", i+1, i) - } - ret[i] = fmt.Sprintf("r%d", i) - ret[i+1] = fmt.Sprintf("r%d", i+1) - } - if reg != "e1" || *plan9 { - body += fmt.Sprintf("\t%s = %s(%s)\n", p.Name, p.Type, reg) - } - } - if ret[0] == "_" && ret[1] == "_" && ret[2] == "_" { - text += fmt.Sprintf("\t%s\n", call) - } else { - if errvar == "" && goos == "linux" { - // raw syscall without error on Linux, see golang.org/issue/22924 - text += fmt.Sprintf("\t%s, %s := %s\n", ret[0], ret[1], call) - } else { - text += fmt.Sprintf("\t%s, %s, %s := %s\n", ret[0], ret[1], ret[2], call) - } - } - text += body - - if *plan9 && ret[2] == "e1" { - text += "\tif int32(r0) == -1 {\n" - text += "\t\terr = e1\n" - text += "\t}\n" - } else if doErrno { - text += "\tif e1 != 0 {\n" - text += "\t\terr = errnoErr(e1)\n" - text += "\t}\n" - } - text += "\treturn\n" - text += "}\n\n" - - if libc && !trampolines[libcFn] { - // some system calls share a trampoline, like read and readlen. - trampolines[libcFn] = true - // Declare assembly trampoline. - text += fmt.Sprintf("func libc_%s_trampoline()\n", libcFn) - // Assembly trampoline calls the libc_* function, which this magic - // redirects to use the function from libSystem. - text += fmt.Sprintf("//go:linkname libc_%s libc_%s\n", libcFn, libcFn) - text += fmt.Sprintf("//go:cgo_import_dynamic libc_%s %s \"/usr/lib/libSystem.B.dylib\"\n", libcFn, libcFn) - text += "\n" - } - } - if err := s.Err(); err != nil { - fmt.Fprintf(os.Stderr, err.Error()) - os.Exit(1) - } - file.Close() - } - fmt.Printf(srcTemplate, cmdLine(), buildTags(), text) -} - -const srcTemplate = `// %s -// Code generated by the command above; see README.md. DO NOT EDIT. - -// +build %s - -package unix - -import ( - "syscall" - "unsafe" -) - -var _ syscall.Errno - -%s -` diff --git a/vendor/golang.org/x/sys/unix/mksyscall_aix_ppc.go b/vendor/golang.org/x/sys/unix/mksyscall_aix_ppc.go deleted file mode 100644 index f2c58fb7cc7f6957484c6ddae9026f42d58b0c3d..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/mksyscall_aix_ppc.go +++ /dev/null @@ -1,404 +0,0 @@ -// Copyright 2019 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -/* -This program reads a file containing function prototypes -(like syscall_aix.go) and generates system call bodies. -The prototypes are marked by lines beginning with "//sys" -and read like func declarations if //sys is replaced by func, but: - * The parameter lists must give a name for each argument. - This includes return parameters. - * The parameter lists must give a type for each argument: - the (x, y, z int) shorthand is not allowed. - * If the return parameter is an error number, it must be named err. - * If go func name needs to be different than its libc name, - * or the function is not in libc, name could be specified - * at the end, after "=" sign, like - //sys getsockopt(s int, level int, name int, val uintptr, vallen *_Socklen) (err error) = libsocket.getsockopt -*/ -package main - -import ( - "bufio" - "flag" - "fmt" - "os" - "regexp" - "strings" -) - -var ( - b32 = flag.Bool("b32", false, "32bit big-endian") - l32 = flag.Bool("l32", false, "32bit little-endian") - aix = flag.Bool("aix", false, "aix") - tags = flag.String("tags", "", "build tags") -) - -// cmdLine returns this programs's commandline arguments -func cmdLine() string { - return "go run mksyscall_aix_ppc.go " + strings.Join(os.Args[1:], " ") -} - -// buildTags returns build tags -func buildTags() string { - return *tags -} - -// Param is function parameter -type Param struct { - Name string - Type string -} - -// usage prints the program usage -func usage() { - fmt.Fprintf(os.Stderr, "usage: go run mksyscall_aix_ppc.go [-b32 | -l32] [-tags x,y] [file ...]\n") - os.Exit(1) -} - -// parseParamList parses parameter list and returns a slice of parameters -func parseParamList(list string) []string { - list = strings.TrimSpace(list) - if list == "" { - return []string{} - } - return regexp.MustCompile(`\s*,\s*`).Split(list, -1) -} - -// parseParam splits a parameter into name and type -func parseParam(p string) Param { - ps := regexp.MustCompile(`^(\S*) (\S*)$`).FindStringSubmatch(p) - if ps == nil { - fmt.Fprintf(os.Stderr, "malformed parameter: %s\n", p) - os.Exit(1) - } - return Param{ps[1], ps[2]} -} - -func main() { - flag.Usage = usage - flag.Parse() - if len(flag.Args()) <= 0 { - fmt.Fprintf(os.Stderr, "no files to parse provided\n") - usage() - } - - endianness := "" - if *b32 { - endianness = "big-endian" - } else if *l32 { - endianness = "little-endian" - } - - pack := "" - text := "" - cExtern := "/*\n#include \n#include \n" - for _, path := range flag.Args() { - file, err := os.Open(path) - if err != nil { - fmt.Fprintf(os.Stderr, err.Error()) - os.Exit(1) - } - s := bufio.NewScanner(file) - for s.Scan() { - t := s.Text() - t = strings.TrimSpace(t) - t = regexp.MustCompile(`\s+`).ReplaceAllString(t, ` `) - if p := regexp.MustCompile(`^package (\S+)$`).FindStringSubmatch(t); p != nil && pack == "" { - pack = p[1] - } - nonblock := regexp.MustCompile(`^\/\/sysnb `).FindStringSubmatch(t) - if regexp.MustCompile(`^\/\/sys `).FindStringSubmatch(t) == nil && nonblock == nil { - continue - } - - // Line must be of the form - // func Open(path string, mode int, perm int) (fd int, err error) - // Split into name, in params, out params. - f := regexp.MustCompile(`^\/\/sys(nb)? (\w+)\(([^()]*)\)\s*(?:\(([^()]+)\))?\s*(?:=\s*(?:(\w*)\.)?(\w*))?$`).FindStringSubmatch(t) - if f == nil { - fmt.Fprintf(os.Stderr, "%s:%s\nmalformed //sys declaration\n", path, t) - os.Exit(1) - } - funct, inps, outps, modname, sysname := f[2], f[3], f[4], f[5], f[6] - - // Split argument lists on comma. - in := parseParamList(inps) - out := parseParamList(outps) - - inps = strings.Join(in, ", ") - outps = strings.Join(out, ", ") - - // Try in vain to keep people from editing this file. - // The theory is that they jump into the middle of the file - // without reading the header. - text += "// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT\n\n" - - // Check if value return, err return available - errvar := "" - retvar := "" - rettype := "" - for _, param := range out { - p := parseParam(param) - if p.Type == "error" { - errvar = p.Name - } else { - retvar = p.Name - rettype = p.Type - } - } - - // System call name. - if sysname == "" { - sysname = funct - } - sysname = regexp.MustCompile(`([a-z])([A-Z])`).ReplaceAllString(sysname, `${1}_$2`) - sysname = strings.ToLower(sysname) // All libc functions are lowercase. - - cRettype := "" - if rettype == "unsafe.Pointer" { - cRettype = "uintptr_t" - } else if rettype == "uintptr" { - cRettype = "uintptr_t" - } else if regexp.MustCompile(`^_`).FindStringSubmatch(rettype) != nil { - cRettype = "uintptr_t" - } else if rettype == "int" { - cRettype = "int" - } else if rettype == "int32" { - cRettype = "int" - } else if rettype == "int64" { - cRettype = "long long" - } else if rettype == "uint32" { - cRettype = "unsigned int" - } else if rettype == "uint64" { - cRettype = "unsigned long long" - } else { - cRettype = "int" - } - if sysname == "exit" { - cRettype = "void" - } - - // Change p.Types to c - var cIn []string - for _, param := range in { - p := parseParam(param) - if regexp.MustCompile(`^\*`).FindStringSubmatch(p.Type) != nil { - cIn = append(cIn, "uintptr_t") - } else if p.Type == "string" { - cIn = append(cIn, "uintptr_t") - } else if regexp.MustCompile(`^\[\](.*)`).FindStringSubmatch(p.Type) != nil { - cIn = append(cIn, "uintptr_t", "size_t") - } else if p.Type == "unsafe.Pointer" { - cIn = append(cIn, "uintptr_t") - } else if p.Type == "uintptr" { - cIn = append(cIn, "uintptr_t") - } else if regexp.MustCompile(`^_`).FindStringSubmatch(p.Type) != nil { - cIn = append(cIn, "uintptr_t") - } else if p.Type == "int" { - cIn = append(cIn, "int") - } else if p.Type == "int32" { - cIn = append(cIn, "int") - } else if p.Type == "int64" { - cIn = append(cIn, "long long") - } else if p.Type == "uint32" { - cIn = append(cIn, "unsigned int") - } else if p.Type == "uint64" { - cIn = append(cIn, "unsigned long long") - } else { - cIn = append(cIn, "int") - } - } - - if funct != "fcntl" && funct != "FcntlInt" && funct != "readlen" && funct != "writelen" { - // Imports of system calls from libc - cExtern += fmt.Sprintf("%s %s", cRettype, sysname) - cIn := strings.Join(cIn, ", ") - cExtern += fmt.Sprintf("(%s);\n", cIn) - } - - // So file name. - if *aix { - if modname == "" { - modname = "libc.a/shr_64.o" - } else { - fmt.Fprintf(os.Stderr, "%s: only syscall using libc are available\n", funct) - os.Exit(1) - } - } - - strconvfunc := "C.CString" - - // Go function header. - if outps != "" { - outps = fmt.Sprintf(" (%s)", outps) - } - if text != "" { - text += "\n" - } - - text += fmt.Sprintf("func %s(%s)%s {\n", funct, strings.Join(in, ", "), outps) - - // Prepare arguments to Syscall. - var args []string - n := 0 - argN := 0 - for _, param := range in { - p := parseParam(param) - if regexp.MustCompile(`^\*`).FindStringSubmatch(p.Type) != nil { - args = append(args, "C.uintptr_t(uintptr(unsafe.Pointer("+p.Name+")))") - } else if p.Type == "string" && errvar != "" { - text += fmt.Sprintf("\t_p%d := uintptr(unsafe.Pointer(%s(%s)))\n", n, strconvfunc, p.Name) - args = append(args, fmt.Sprintf("C.uintptr_t(_p%d)", n)) - n++ - } else if p.Type == "string" { - fmt.Fprintf(os.Stderr, path+":"+funct+" uses string arguments, but has no error return\n") - text += fmt.Sprintf("\t_p%d := uintptr(unsafe.Pointer(%s(%s)))\n", n, strconvfunc, p.Name) - args = append(args, fmt.Sprintf("C.uintptr_t(_p%d)", n)) - n++ - } else if m := regexp.MustCompile(`^\[\](.*)`).FindStringSubmatch(p.Type); m != nil { - // Convert slice into pointer, length. - // Have to be careful not to take address of &a[0] if len == 0: - // pass nil in that case. - text += fmt.Sprintf("\tvar _p%d *%s\n", n, m[1]) - text += fmt.Sprintf("\tif len(%s) > 0 {\n\t\t_p%d = &%s[0]\n\t}\n", p.Name, n, p.Name) - args = append(args, fmt.Sprintf("C.uintptr_t(uintptr(unsafe.Pointer(_p%d)))", n)) - n++ - text += fmt.Sprintf("\tvar _p%d int\n", n) - text += fmt.Sprintf("\t_p%d = len(%s)\n", n, p.Name) - args = append(args, fmt.Sprintf("C.size_t(_p%d)", n)) - n++ - } else if p.Type == "int64" && endianness != "" { - if endianness == "big-endian" { - args = append(args, fmt.Sprintf("uintptr(%s>>32)", p.Name), fmt.Sprintf("uintptr(%s)", p.Name)) - } else { - args = append(args, fmt.Sprintf("uintptr(%s)", p.Name), fmt.Sprintf("uintptr(%s>>32)", p.Name)) - } - n++ - } else if p.Type == "bool" { - text += fmt.Sprintf("\tvar _p%d uint32\n", n) - text += fmt.Sprintf("\tif %s {\n\t\t_p%d = 1\n\t} else {\n\t\t_p%d = 0\n\t}\n", p.Name, n, n) - args = append(args, fmt.Sprintf("_p%d", n)) - } else if regexp.MustCompile(`^_`).FindStringSubmatch(p.Type) != nil { - args = append(args, fmt.Sprintf("C.uintptr_t(uintptr(%s))", p.Name)) - } else if p.Type == "unsafe.Pointer" { - args = append(args, fmt.Sprintf("C.uintptr_t(uintptr(%s))", p.Name)) - } else if p.Type == "int" { - if (argN == 2) && ((funct == "readlen") || (funct == "writelen")) { - args = append(args, fmt.Sprintf("C.size_t(%s)", p.Name)) - } else if argN == 0 && funct == "fcntl" { - args = append(args, fmt.Sprintf("C.uintptr_t(%s)", p.Name)) - } else if (argN == 2) && ((funct == "fcntl") || (funct == "FcntlInt")) { - args = append(args, fmt.Sprintf("C.uintptr_t(%s)", p.Name)) - } else { - args = append(args, fmt.Sprintf("C.int(%s)", p.Name)) - } - } else if p.Type == "int32" { - args = append(args, fmt.Sprintf("C.int(%s)", p.Name)) - } else if p.Type == "int64" { - args = append(args, fmt.Sprintf("C.longlong(%s)", p.Name)) - } else if p.Type == "uint32" { - args = append(args, fmt.Sprintf("C.uint(%s)", p.Name)) - } else if p.Type == "uint64" { - args = append(args, fmt.Sprintf("C.ulonglong(%s)", p.Name)) - } else if p.Type == "uintptr" { - args = append(args, fmt.Sprintf("C.uintptr_t(%s)", p.Name)) - } else { - args = append(args, fmt.Sprintf("C.int(%s)", p.Name)) - } - argN++ - } - - // Actual call. - arglist := strings.Join(args, ", ") - call := "" - if sysname == "exit" { - if errvar != "" { - call += "er :=" - } else { - call += "" - } - } else if errvar != "" { - call += "r0,er :=" - } else if retvar != "" { - call += "r0,_ :=" - } else { - call += "" - } - call += fmt.Sprintf("C.%s(%s)", sysname, arglist) - - // Assign return values. - body := "" - for i := 0; i < len(out); i++ { - p := parseParam(out[i]) - reg := "" - if p.Name == "err" { - reg = "e1" - } else { - reg = "r0" - } - if reg != "e1" { - body += fmt.Sprintf("\t%s = %s(%s)\n", p.Name, p.Type, reg) - } - } - - // verify return - if sysname != "exit" && errvar != "" { - if regexp.MustCompile(`^uintptr`).FindStringSubmatch(cRettype) != nil { - body += "\tif (uintptr(r0) ==^uintptr(0) && er != nil) {\n" - body += fmt.Sprintf("\t\t%s = er\n", errvar) - body += "\t}\n" - } else { - body += "\tif (r0 ==-1 && er != nil) {\n" - body += fmt.Sprintf("\t\t%s = er\n", errvar) - body += "\t}\n" - } - } else if errvar != "" { - body += "\tif (er != nil) {\n" - body += fmt.Sprintf("\t\t%s = er\n", errvar) - body += "\t}\n" - } - - text += fmt.Sprintf("\t%s\n", call) - text += body - - text += "\treturn\n" - text += "}\n" - } - if err := s.Err(); err != nil { - fmt.Fprintf(os.Stderr, err.Error()) - os.Exit(1) - } - file.Close() - } - imp := "" - if pack != "unix" { - imp = "import \"golang.org/x/sys/unix\"\n" - - } - fmt.Printf(srcTemplate, cmdLine(), buildTags(), pack, cExtern, imp, text) -} - -const srcTemplate = `// %s -// Code generated by the command above; see README.md. DO NOT EDIT. - -// +build %s - -package %s - - -%s -*/ -import "C" -import ( - "unsafe" -) - - -%s - -%s -` diff --git a/vendor/golang.org/x/sys/unix/mksyscall_aix_ppc64.go b/vendor/golang.org/x/sys/unix/mksyscall_aix_ppc64.go deleted file mode 100644 index 45b4429088fea0f4e71e4bf7bfccdb71b6c64704..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/mksyscall_aix_ppc64.go +++ /dev/null @@ -1,602 +0,0 @@ -// Copyright 2019 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -/* -This program reads a file containing function prototypes -(like syscall_aix.go) and generates system call bodies. -The prototypes are marked by lines beginning with "//sys" -and read like func declarations if //sys is replaced by func, but: - * The parameter lists must give a name for each argument. - This includes return parameters. - * The parameter lists must give a type for each argument: - the (x, y, z int) shorthand is not allowed. - * If the return parameter is an error number, it must be named err. - * If go func name needs to be different than its libc name, - * or the function is not in libc, name could be specified - * at the end, after "=" sign, like - //sys getsockopt(s int, level int, name int, val uintptr, vallen *_Socklen) (err error) = libsocket.getsockopt - - -This program will generate three files and handle both gc and gccgo implementation: - - zsyscall_aix_ppc64.go: the common part of each implementation (error handler, pointer creation) - - zsyscall_aix_ppc64_gc.go: gc part with //go_cgo_import_dynamic and a call to syscall6 - - zsyscall_aix_ppc64_gccgo.go: gccgo part with C function and conversion to C type. - - The generated code looks like this - -zsyscall_aix_ppc64.go -func asyscall(...) (n int, err error) { - // Pointer Creation - r1, e1 := callasyscall(...) - // Type Conversion - // Error Handler - return -} - -zsyscall_aix_ppc64_gc.go -//go:cgo_import_dynamic libc_asyscall asyscall "libc.a/shr_64.o" -//go:linkname libc_asyscall libc_asyscall -var asyscall syscallFunc - -func callasyscall(...) (r1 uintptr, e1 Errno) { - r1, _, e1 = syscall6(uintptr(unsafe.Pointer(&libc_asyscall)), "nb_args", ... ) - return -} - -zsyscall_aix_ppc64_ggcgo.go - -// int asyscall(...) - -import "C" - -func callasyscall(...) (r1 uintptr, e1 Errno) { - r1 = uintptr(C.asyscall(...)) - e1 = syscall.GetErrno() - return -} -*/ - -package main - -import ( - "bufio" - "flag" - "fmt" - "io/ioutil" - "os" - "regexp" - "strings" -) - -var ( - b32 = flag.Bool("b32", false, "32bit big-endian") - l32 = flag.Bool("l32", false, "32bit little-endian") - aix = flag.Bool("aix", false, "aix") - tags = flag.String("tags", "", "build tags") -) - -// cmdLine returns this programs's commandline arguments -func cmdLine() string { - return "go run mksyscall_aix_ppc64.go " + strings.Join(os.Args[1:], " ") -} - -// buildTags returns build tags -func buildTags() string { - return *tags -} - -// Param is function parameter -type Param struct { - Name string - Type string -} - -// usage prints the program usage -func usage() { - fmt.Fprintf(os.Stderr, "usage: go run mksyscall_aix_ppc64.go [-b32 | -l32] [-tags x,y] [file ...]\n") - os.Exit(1) -} - -// parseParamList parses parameter list and returns a slice of parameters -func parseParamList(list string) []string { - list = strings.TrimSpace(list) - if list == "" { - return []string{} - } - return regexp.MustCompile(`\s*,\s*`).Split(list, -1) -} - -// parseParam splits a parameter into name and type -func parseParam(p string) Param { - ps := regexp.MustCompile(`^(\S*) (\S*)$`).FindStringSubmatch(p) - if ps == nil { - fmt.Fprintf(os.Stderr, "malformed parameter: %s\n", p) - os.Exit(1) - } - return Param{ps[1], ps[2]} -} - -func main() { - flag.Usage = usage - flag.Parse() - if len(flag.Args()) <= 0 { - fmt.Fprintf(os.Stderr, "no files to parse provided\n") - usage() - } - - endianness := "" - if *b32 { - endianness = "big-endian" - } else if *l32 { - endianness = "little-endian" - } - - pack := "" - // GCCGO - textgccgo := "" - cExtern := "/*\n#include \n" - // GC - textgc := "" - dynimports := "" - linknames := "" - var vars []string - // COMMON - textcommon := "" - for _, path := range flag.Args() { - file, err := os.Open(path) - if err != nil { - fmt.Fprintf(os.Stderr, err.Error()) - os.Exit(1) - } - s := bufio.NewScanner(file) - for s.Scan() { - t := s.Text() - t = strings.TrimSpace(t) - t = regexp.MustCompile(`\s+`).ReplaceAllString(t, ` `) - if p := regexp.MustCompile(`^package (\S+)$`).FindStringSubmatch(t); p != nil && pack == "" { - pack = p[1] - } - nonblock := regexp.MustCompile(`^\/\/sysnb `).FindStringSubmatch(t) - if regexp.MustCompile(`^\/\/sys `).FindStringSubmatch(t) == nil && nonblock == nil { - continue - } - - // Line must be of the form - // func Open(path string, mode int, perm int) (fd int, err error) - // Split into name, in params, out params. - f := regexp.MustCompile(`^\/\/sys(nb)? (\w+)\(([^()]*)\)\s*(?:\(([^()]+)\))?\s*(?:=\s*(?:(\w*)\.)?(\w*))?$`).FindStringSubmatch(t) - if f == nil { - fmt.Fprintf(os.Stderr, "%s:%s\nmalformed //sys declaration\n", path, t) - os.Exit(1) - } - funct, inps, outps, modname, sysname := f[2], f[3], f[4], f[5], f[6] - - // Split argument lists on comma. - in := parseParamList(inps) - out := parseParamList(outps) - - inps = strings.Join(in, ", ") - outps = strings.Join(out, ", ") - - if sysname == "" { - sysname = funct - } - - onlyCommon := false - if funct == "readlen" || funct == "writelen" || funct == "FcntlInt" || funct == "FcntlFlock" { - // This function call another syscall which is already implemented. - // Therefore, the gc and gccgo part must not be generated. - onlyCommon = true - } - - // Try in vain to keep people from editing this file. - // The theory is that they jump into the middle of the file - // without reading the header. - - textcommon += "// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT\n\n" - if !onlyCommon { - textgccgo += "// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT\n\n" - textgc += "// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT\n\n" - } - - // Check if value return, err return available - errvar := "" - rettype := "" - for _, param := range out { - p := parseParam(param) - if p.Type == "error" { - errvar = p.Name - } else { - rettype = p.Type - } - } - - sysname = regexp.MustCompile(`([a-z])([A-Z])`).ReplaceAllString(sysname, `${1}_$2`) - sysname = strings.ToLower(sysname) // All libc functions are lowercase. - - // GCCGO Prototype return type - cRettype := "" - if rettype == "unsafe.Pointer" { - cRettype = "uintptr_t" - } else if rettype == "uintptr" { - cRettype = "uintptr_t" - } else if regexp.MustCompile(`^_`).FindStringSubmatch(rettype) != nil { - cRettype = "uintptr_t" - } else if rettype == "int" { - cRettype = "int" - } else if rettype == "int32" { - cRettype = "int" - } else if rettype == "int64" { - cRettype = "long long" - } else if rettype == "uint32" { - cRettype = "unsigned int" - } else if rettype == "uint64" { - cRettype = "unsigned long long" - } else { - cRettype = "int" - } - if sysname == "exit" { - cRettype = "void" - } - - // GCCGO Prototype arguments type - var cIn []string - for i, param := range in { - p := parseParam(param) - if regexp.MustCompile(`^\*`).FindStringSubmatch(p.Type) != nil { - cIn = append(cIn, "uintptr_t") - } else if p.Type == "string" { - cIn = append(cIn, "uintptr_t") - } else if regexp.MustCompile(`^\[\](.*)`).FindStringSubmatch(p.Type) != nil { - cIn = append(cIn, "uintptr_t", "size_t") - } else if p.Type == "unsafe.Pointer" { - cIn = append(cIn, "uintptr_t") - } else if p.Type == "uintptr" { - cIn = append(cIn, "uintptr_t") - } else if regexp.MustCompile(`^_`).FindStringSubmatch(p.Type) != nil { - cIn = append(cIn, "uintptr_t") - } else if p.Type == "int" { - if (i == 0 || i == 2) && funct == "fcntl" { - // These fcntl arguments needs to be uintptr to be able to call FcntlInt and FcntlFlock - cIn = append(cIn, "uintptr_t") - } else { - cIn = append(cIn, "int") - } - - } else if p.Type == "int32" { - cIn = append(cIn, "int") - } else if p.Type == "int64" { - cIn = append(cIn, "long long") - } else if p.Type == "uint32" { - cIn = append(cIn, "unsigned int") - } else if p.Type == "uint64" { - cIn = append(cIn, "unsigned long long") - } else { - cIn = append(cIn, "int") - } - } - - if !onlyCommon { - // GCCGO Prototype Generation - // Imports of system calls from libc - cExtern += fmt.Sprintf("%s %s", cRettype, sysname) - cIn := strings.Join(cIn, ", ") - cExtern += fmt.Sprintf("(%s);\n", cIn) - } - // GC Library name - if modname == "" { - modname = "libc.a/shr_64.o" - } else { - fmt.Fprintf(os.Stderr, "%s: only syscall using libc are available\n", funct) - os.Exit(1) - } - sysvarname := fmt.Sprintf("libc_%s", sysname) - - if !onlyCommon { - // GC Runtime import of function to allow cross-platform builds. - dynimports += fmt.Sprintf("//go:cgo_import_dynamic %s %s \"%s\"\n", sysvarname, sysname, modname) - // GC Link symbol to proc address variable. - linknames += fmt.Sprintf("//go:linkname %s %s\n", sysvarname, sysvarname) - // GC Library proc address variable. - vars = append(vars, sysvarname) - } - - strconvfunc := "BytePtrFromString" - strconvtype := "*byte" - - // Go function header. - if outps != "" { - outps = fmt.Sprintf(" (%s)", outps) - } - if textcommon != "" { - textcommon += "\n" - } - - textcommon += fmt.Sprintf("func %s(%s)%s {\n", funct, strings.Join(in, ", "), outps) - - // Prepare arguments tocall. - var argscommon []string // Arguments in the common part - var argscall []string // Arguments for call prototype - var argsgc []string // Arguments for gc call (with syscall6) - var argsgccgo []string // Arguments for gccgo call (with C.name_of_syscall) - n := 0 - argN := 0 - for _, param := range in { - p := parseParam(param) - if regexp.MustCompile(`^\*`).FindStringSubmatch(p.Type) != nil { - argscommon = append(argscommon, fmt.Sprintf("uintptr(unsafe.Pointer(%s))", p.Name)) - argscall = append(argscall, fmt.Sprintf("%s uintptr", p.Name)) - argsgc = append(argsgc, p.Name) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.uintptr_t(%s)", p.Name)) - } else if p.Type == "string" && errvar != "" { - textcommon += fmt.Sprintf("\tvar _p%d %s\n", n, strconvtype) - textcommon += fmt.Sprintf("\t_p%d, %s = %s(%s)\n", n, errvar, strconvfunc, p.Name) - textcommon += fmt.Sprintf("\tif %s != nil {\n\t\treturn\n\t}\n", errvar) - - argscommon = append(argscommon, fmt.Sprintf("uintptr(unsafe.Pointer(_p%d))", n)) - argscall = append(argscall, fmt.Sprintf("_p%d uintptr ", n)) - argsgc = append(argsgc, fmt.Sprintf("_p%d", n)) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.uintptr_t(_p%d)", n)) - n++ - } else if p.Type == "string" { - fmt.Fprintf(os.Stderr, path+":"+funct+" uses string arguments, but has no error return\n") - textcommon += fmt.Sprintf("\tvar _p%d %s\n", n, strconvtype) - textcommon += fmt.Sprintf("\t_p%d, %s = %s(%s)\n", n, errvar, strconvfunc, p.Name) - textcommon += fmt.Sprintf("\tif %s != nil {\n\t\treturn\n\t}\n", errvar) - - argscommon = append(argscommon, fmt.Sprintf("uintptr(unsafe.Pointer(_p%d))", n)) - argscall = append(argscall, fmt.Sprintf("_p%d uintptr", n)) - argsgc = append(argsgc, fmt.Sprintf("_p%d", n)) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.uintptr_t(_p%d)", n)) - n++ - } else if m := regexp.MustCompile(`^\[\](.*)`).FindStringSubmatch(p.Type); m != nil { - // Convert slice into pointer, length. - // Have to be careful not to take address of &a[0] if len == 0: - // pass nil in that case. - textcommon += fmt.Sprintf("\tvar _p%d *%s\n", n, m[1]) - textcommon += fmt.Sprintf("\tif len(%s) > 0 {\n\t\t_p%d = &%s[0]\n\t}\n", p.Name, n, p.Name) - argscommon = append(argscommon, fmt.Sprintf("uintptr(unsafe.Pointer(_p%d))", n), fmt.Sprintf("len(%s)", p.Name)) - argscall = append(argscall, fmt.Sprintf("_p%d uintptr", n), fmt.Sprintf("_lenp%d int", n)) - argsgc = append(argsgc, fmt.Sprintf("_p%d", n), fmt.Sprintf("uintptr(_lenp%d)", n)) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.uintptr_t(_p%d)", n), fmt.Sprintf("C.size_t(_lenp%d)", n)) - n++ - } else if p.Type == "int64" && endianness != "" { - fmt.Fprintf(os.Stderr, path+":"+funct+" uses int64 with 32 bits mode. Case not yet implemented\n") - } else if p.Type == "bool" { - fmt.Fprintf(os.Stderr, path+":"+funct+" uses bool. Case not yet implemented\n") - } else if regexp.MustCompile(`^_`).FindStringSubmatch(p.Type) != nil || p.Type == "unsafe.Pointer" { - argscommon = append(argscommon, fmt.Sprintf("uintptr(%s)", p.Name)) - argscall = append(argscall, fmt.Sprintf("%s uintptr", p.Name)) - argsgc = append(argsgc, p.Name) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.uintptr_t(%s)", p.Name)) - } else if p.Type == "int" { - if (argN == 0 || argN == 2) && ((funct == "fcntl") || (funct == "FcntlInt") || (funct == "FcntlFlock")) { - // These fcntl arguments need to be uintptr to be able to call FcntlInt and FcntlFlock - argscommon = append(argscommon, fmt.Sprintf("uintptr(%s)", p.Name)) - argscall = append(argscall, fmt.Sprintf("%s uintptr", p.Name)) - argsgc = append(argsgc, p.Name) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.uintptr_t(%s)", p.Name)) - - } else { - argscommon = append(argscommon, p.Name) - argscall = append(argscall, fmt.Sprintf("%s int", p.Name)) - argsgc = append(argsgc, fmt.Sprintf("uintptr(%s)", p.Name)) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.int(%s)", p.Name)) - } - } else if p.Type == "int32" { - argscommon = append(argscommon, p.Name) - argscall = append(argscall, fmt.Sprintf("%s int32", p.Name)) - argsgc = append(argsgc, fmt.Sprintf("uintptr(%s)", p.Name)) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.int(%s)", p.Name)) - } else if p.Type == "int64" { - argscommon = append(argscommon, p.Name) - argscall = append(argscall, fmt.Sprintf("%s int64", p.Name)) - argsgc = append(argsgc, fmt.Sprintf("uintptr(%s)", p.Name)) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.longlong(%s)", p.Name)) - } else if p.Type == "uint32" { - argscommon = append(argscommon, p.Name) - argscall = append(argscall, fmt.Sprintf("%s uint32", p.Name)) - argsgc = append(argsgc, fmt.Sprintf("uintptr(%s)", p.Name)) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.uint(%s)", p.Name)) - } else if p.Type == "uint64" { - argscommon = append(argscommon, p.Name) - argscall = append(argscall, fmt.Sprintf("%s uint64", p.Name)) - argsgc = append(argsgc, fmt.Sprintf("uintptr(%s)", p.Name)) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.ulonglong(%s)", p.Name)) - } else if p.Type == "uintptr" { - argscommon = append(argscommon, p.Name) - argscall = append(argscall, fmt.Sprintf("%s uintptr", p.Name)) - argsgc = append(argsgc, p.Name) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.uintptr_t(%s)", p.Name)) - } else { - argscommon = append(argscommon, fmt.Sprintf("int(%s)", p.Name)) - argscall = append(argscall, fmt.Sprintf("%s int", p.Name)) - argsgc = append(argsgc, fmt.Sprintf("uintptr(%s)", p.Name)) - argsgccgo = append(argsgccgo, fmt.Sprintf("C.int(%s)", p.Name)) - } - argN++ - } - nargs := len(argsgc) - - // COMMON function generation - argscommonlist := strings.Join(argscommon, ", ") - callcommon := fmt.Sprintf("call%s(%s)", sysname, argscommonlist) - ret := []string{"_", "_"} - body := "" - doErrno := false - for i := 0; i < len(out); i++ { - p := parseParam(out[i]) - reg := "" - if p.Name == "err" { - reg = "e1" - ret[1] = reg - doErrno = true - } else { - reg = "r0" - ret[0] = reg - } - if p.Type == "bool" { - reg = fmt.Sprintf("%s != 0", reg) - } - if reg != "e1" { - body += fmt.Sprintf("\t%s = %s(%s)\n", p.Name, p.Type, reg) - } - } - if ret[0] == "_" && ret[1] == "_" { - textcommon += fmt.Sprintf("\t%s\n", callcommon) - } else { - textcommon += fmt.Sprintf("\t%s, %s := %s\n", ret[0], ret[1], callcommon) - } - textcommon += body - - if doErrno { - textcommon += "\tif e1 != 0 {\n" - textcommon += "\t\terr = errnoErr(e1)\n" - textcommon += "\t}\n" - } - textcommon += "\treturn\n" - textcommon += "}\n" - - if onlyCommon { - continue - } - - // CALL Prototype - callProto := fmt.Sprintf("func call%s(%s) (r1 uintptr, e1 Errno) {\n", sysname, strings.Join(argscall, ", ")) - - // GC function generation - asm := "syscall6" - if nonblock != nil { - asm = "rawSyscall6" - } - - if len(argsgc) <= 6 { - for len(argsgc) < 6 { - argsgc = append(argsgc, "0") - } - } else { - fmt.Fprintf(os.Stderr, "%s: too many arguments to system call", funct) - os.Exit(1) - } - argsgclist := strings.Join(argsgc, ", ") - callgc := fmt.Sprintf("%s(uintptr(unsafe.Pointer(&%s)), %d, %s)", asm, sysvarname, nargs, argsgclist) - - textgc += callProto - textgc += fmt.Sprintf("\tr1, _, e1 = %s\n", callgc) - textgc += "\treturn\n}\n" - - // GCCGO function generation - argsgccgolist := strings.Join(argsgccgo, ", ") - callgccgo := fmt.Sprintf("C.%s(%s)", sysname, argsgccgolist) - textgccgo += callProto - textgccgo += fmt.Sprintf("\tr1 = uintptr(%s)\n", callgccgo) - textgccgo += "\te1 = syscall.GetErrno()\n" - textgccgo += "\treturn\n}\n" - } - if err := s.Err(); err != nil { - fmt.Fprintf(os.Stderr, err.Error()) - os.Exit(1) - } - file.Close() - } - imp := "" - if pack != "unix" { - imp = "import \"golang.org/x/sys/unix\"\n" - - } - - // Print zsyscall_aix_ppc64.go - err := ioutil.WriteFile("zsyscall_aix_ppc64.go", - []byte(fmt.Sprintf(srcTemplate1, cmdLine(), buildTags(), pack, imp, textcommon)), - 0644) - if err != nil { - fmt.Fprintf(os.Stderr, err.Error()) - os.Exit(1) - } - - // Print zsyscall_aix_ppc64_gc.go - vardecls := "\t" + strings.Join(vars, ",\n\t") - vardecls += " syscallFunc" - err = ioutil.WriteFile("zsyscall_aix_ppc64_gc.go", - []byte(fmt.Sprintf(srcTemplate2, cmdLine(), buildTags(), pack, imp, dynimports, linknames, vardecls, textgc)), - 0644) - if err != nil { - fmt.Fprintf(os.Stderr, err.Error()) - os.Exit(1) - } - - // Print zsyscall_aix_ppc64_gccgo.go - err = ioutil.WriteFile("zsyscall_aix_ppc64_gccgo.go", - []byte(fmt.Sprintf(srcTemplate3, cmdLine(), buildTags(), pack, cExtern, imp, textgccgo)), - 0644) - if err != nil { - fmt.Fprintf(os.Stderr, err.Error()) - os.Exit(1) - } -} - -const srcTemplate1 = `// %s -// Code generated by the command above; see README.md. DO NOT EDIT. - -// +build %s - -package %s - -import ( - "unsafe" -) - - -%s - -%s -` -const srcTemplate2 = `// %s -// Code generated by the command above; see README.md. DO NOT EDIT. - -// +build %s -// +build !gccgo - -package %s - -import ( - "unsafe" -) -%s -%s -%s -type syscallFunc uintptr - -var ( -%s -) - -// Implemented in runtime/syscall_aix.go. -func rawSyscall6(trap, nargs, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err Errno) -func syscall6(trap, nargs, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err Errno) - -%s -` -const srcTemplate3 = `// %s -// Code generated by the command above; see README.md. DO NOT EDIT. - -// +build %s -// +build gccgo - -package %s - -%s -*/ -import "C" -import ( - "syscall" -) - - -%s - -%s -` diff --git a/vendor/golang.org/x/sys/unix/mksyscall_solaris.go b/vendor/golang.org/x/sys/unix/mksyscall_solaris.go deleted file mode 100644 index 3d864738b69594aaf1b7e60e6c191ac9168039b2..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/mksyscall_solaris.go +++ /dev/null @@ -1,335 +0,0 @@ -// Copyright 2019 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -/* - This program reads a file containing function prototypes - (like syscall_solaris.go) and generates system call bodies. - The prototypes are marked by lines beginning with "//sys" - and read like func declarations if //sys is replaced by func, but: - * The parameter lists must give a name for each argument. - This includes return parameters. - * The parameter lists must give a type for each argument: - the (x, y, z int) shorthand is not allowed. - * If the return parameter is an error number, it must be named err. - * If go func name needs to be different than its libc name, - * or the function is not in libc, name could be specified - * at the end, after "=" sign, like - //sys getsockopt(s int, level int, name int, val uintptr, vallen *_Socklen) (err error) = libsocket.getsockopt -*/ - -package main - -import ( - "bufio" - "flag" - "fmt" - "os" - "regexp" - "strings" -) - -var ( - b32 = flag.Bool("b32", false, "32bit big-endian") - l32 = flag.Bool("l32", false, "32bit little-endian") - tags = flag.String("tags", "", "build tags") -) - -// cmdLine returns this programs's commandline arguments -func cmdLine() string { - return "go run mksyscall_solaris.go " + strings.Join(os.Args[1:], " ") -} - -// buildTags returns build tags -func buildTags() string { - return *tags -} - -// Param is function parameter -type Param struct { - Name string - Type string -} - -// usage prints the program usage -func usage() { - fmt.Fprintf(os.Stderr, "usage: go run mksyscall_solaris.go [-b32 | -l32] [-tags x,y] [file ...]\n") - os.Exit(1) -} - -// parseParamList parses parameter list and returns a slice of parameters -func parseParamList(list string) []string { - list = strings.TrimSpace(list) - if list == "" { - return []string{} - } - return regexp.MustCompile(`\s*,\s*`).Split(list, -1) -} - -// parseParam splits a parameter into name and type -func parseParam(p string) Param { - ps := regexp.MustCompile(`^(\S*) (\S*)$`).FindStringSubmatch(p) - if ps == nil { - fmt.Fprintf(os.Stderr, "malformed parameter: %s\n", p) - os.Exit(1) - } - return Param{ps[1], ps[2]} -} - -func main() { - flag.Usage = usage - flag.Parse() - if len(flag.Args()) <= 0 { - fmt.Fprintf(os.Stderr, "no files to parse provided\n") - usage() - } - - endianness := "" - if *b32 { - endianness = "big-endian" - } else if *l32 { - endianness = "little-endian" - } - - pack := "" - text := "" - dynimports := "" - linknames := "" - var vars []string - for _, path := range flag.Args() { - file, err := os.Open(path) - if err != nil { - fmt.Fprintf(os.Stderr, err.Error()) - os.Exit(1) - } - s := bufio.NewScanner(file) - for s.Scan() { - t := s.Text() - t = strings.TrimSpace(t) - t = regexp.MustCompile(`\s+`).ReplaceAllString(t, ` `) - if p := regexp.MustCompile(`^package (\S+)$`).FindStringSubmatch(t); p != nil && pack == "" { - pack = p[1] - } - nonblock := regexp.MustCompile(`^\/\/sysnb `).FindStringSubmatch(t) - if regexp.MustCompile(`^\/\/sys `).FindStringSubmatch(t) == nil && nonblock == nil { - continue - } - - // Line must be of the form - // func Open(path string, mode int, perm int) (fd int, err error) - // Split into name, in params, out params. - f := regexp.MustCompile(`^\/\/sys(nb)? (\w+)\(([^()]*)\)\s*(?:\(([^()]+)\))?\s*(?:=\s*(?:(\w*)\.)?(\w*))?$`).FindStringSubmatch(t) - if f == nil { - fmt.Fprintf(os.Stderr, "%s:%s\nmalformed //sys declaration\n", path, t) - os.Exit(1) - } - funct, inps, outps, modname, sysname := f[2], f[3], f[4], f[5], f[6] - - // Split argument lists on comma. - in := parseParamList(inps) - out := parseParamList(outps) - - inps = strings.Join(in, ", ") - outps = strings.Join(out, ", ") - - // Try in vain to keep people from editing this file. - // The theory is that they jump into the middle of the file - // without reading the header. - text += "// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT\n\n" - - // So file name. - if modname == "" { - modname = "libc" - } - - // System call name. - if sysname == "" { - sysname = funct - } - - // System call pointer variable name. - sysvarname := fmt.Sprintf("proc%s", sysname) - - strconvfunc := "BytePtrFromString" - strconvtype := "*byte" - - sysname = strings.ToLower(sysname) // All libc functions are lowercase. - - // Runtime import of function to allow cross-platform builds. - dynimports += fmt.Sprintf("//go:cgo_import_dynamic libc_%s %s \"%s.so\"\n", sysname, sysname, modname) - // Link symbol to proc address variable. - linknames += fmt.Sprintf("//go:linkname %s libc_%s\n", sysvarname, sysname) - // Library proc address variable. - vars = append(vars, sysvarname) - - // Go function header. - outlist := strings.Join(out, ", ") - if outlist != "" { - outlist = fmt.Sprintf(" (%s)", outlist) - } - if text != "" { - text += "\n" - } - text += fmt.Sprintf("func %s(%s)%s {\n", funct, strings.Join(in, ", "), outlist) - - // Check if err return available - errvar := "" - for _, param := range out { - p := parseParam(param) - if p.Type == "error" { - errvar = p.Name - continue - } - } - - // Prepare arguments to Syscall. - var args []string - n := 0 - for _, param := range in { - p := parseParam(param) - if regexp.MustCompile(`^\*`).FindStringSubmatch(p.Type) != nil { - args = append(args, "uintptr(unsafe.Pointer("+p.Name+"))") - } else if p.Type == "string" && errvar != "" { - text += fmt.Sprintf("\tvar _p%d %s\n", n, strconvtype) - text += fmt.Sprintf("\t_p%d, %s = %s(%s)\n", n, errvar, strconvfunc, p.Name) - text += fmt.Sprintf("\tif %s != nil {\n\t\treturn\n\t}\n", errvar) - args = append(args, fmt.Sprintf("uintptr(unsafe.Pointer(_p%d))", n)) - n++ - } else if p.Type == "string" { - fmt.Fprintf(os.Stderr, path+":"+funct+" uses string arguments, but has no error return\n") - text += fmt.Sprintf("\tvar _p%d %s\n", n, strconvtype) - text += fmt.Sprintf("\t_p%d, _ = %s(%s)\n", n, strconvfunc, p.Name) - args = append(args, fmt.Sprintf("uintptr(unsafe.Pointer(_p%d))", n)) - n++ - } else if s := regexp.MustCompile(`^\[\](.*)`).FindStringSubmatch(p.Type); s != nil { - // Convert slice into pointer, length. - // Have to be careful not to take address of &a[0] if len == 0: - // pass nil in that case. - text += fmt.Sprintf("\tvar _p%d *%s\n", n, s[1]) - text += fmt.Sprintf("\tif len(%s) > 0 {\n\t\t_p%d = &%s[0]\n\t}\n", p.Name, n, p.Name) - args = append(args, fmt.Sprintf("uintptr(unsafe.Pointer(_p%d))", n), fmt.Sprintf("uintptr(len(%s))", p.Name)) - n++ - } else if p.Type == "int64" && endianness != "" { - if endianness == "big-endian" { - args = append(args, fmt.Sprintf("uintptr(%s>>32)", p.Name), fmt.Sprintf("uintptr(%s)", p.Name)) - } else { - args = append(args, fmt.Sprintf("uintptr(%s)", p.Name), fmt.Sprintf("uintptr(%s>>32)", p.Name)) - } - } else if p.Type == "bool" { - text += fmt.Sprintf("\tvar _p%d uint32\n", n) - text += fmt.Sprintf("\tif %s {\n\t\t_p%d = 1\n\t} else {\n\t\t_p%d = 0\n\t}\n", p.Name, n, n) - args = append(args, fmt.Sprintf("uintptr(_p%d)", n)) - n++ - } else { - args = append(args, fmt.Sprintf("uintptr(%s)", p.Name)) - } - } - nargs := len(args) - - // Determine which form to use; pad args with zeros. - asm := "sysvicall6" - if nonblock != nil { - asm = "rawSysvicall6" - } - if len(args) <= 6 { - for len(args) < 6 { - args = append(args, "0") - } - } else { - fmt.Fprintf(os.Stderr, "%s: too many arguments to system call\n", path) - os.Exit(1) - } - - // Actual call. - arglist := strings.Join(args, ", ") - call := fmt.Sprintf("%s(uintptr(unsafe.Pointer(&%s)), %d, %s)", asm, sysvarname, nargs, arglist) - - // Assign return values. - body := "" - ret := []string{"_", "_", "_"} - doErrno := false - for i := 0; i < len(out); i++ { - p := parseParam(out[i]) - reg := "" - if p.Name == "err" { - reg = "e1" - ret[2] = reg - doErrno = true - } else { - reg = fmt.Sprintf("r%d", i) - ret[i] = reg - } - if p.Type == "bool" { - reg = fmt.Sprintf("%d != 0", reg) - } - if p.Type == "int64" && endianness != "" { - // 64-bit number in r1:r0 or r0:r1. - if i+2 > len(out) { - fmt.Fprintf(os.Stderr, "%s: not enough registers for int64 return\n", path) - os.Exit(1) - } - if endianness == "big-endian" { - reg = fmt.Sprintf("int64(r%d)<<32 | int64(r%d)", i, i+1) - } else { - reg = fmt.Sprintf("int64(r%d)<<32 | int64(r%d)", i+1, i) - } - ret[i] = fmt.Sprintf("r%d", i) - ret[i+1] = fmt.Sprintf("r%d", i+1) - } - if reg != "e1" { - body += fmt.Sprintf("\t%s = %s(%s)\n", p.Name, p.Type, reg) - } - } - if ret[0] == "_" && ret[1] == "_" && ret[2] == "_" { - text += fmt.Sprintf("\t%s\n", call) - } else { - text += fmt.Sprintf("\t%s, %s, %s := %s\n", ret[0], ret[1], ret[2], call) - } - text += body - - if doErrno { - text += "\tif e1 != 0 {\n" - text += "\t\terr = e1\n" - text += "\t}\n" - } - text += "\treturn\n" - text += "}\n" - } - if err := s.Err(); err != nil { - fmt.Fprintf(os.Stderr, err.Error()) - os.Exit(1) - } - file.Close() - } - imp := "" - if pack != "unix" { - imp = "import \"golang.org/x/sys/unix\"\n" - - } - vardecls := "\t" + strings.Join(vars, ",\n\t") - vardecls += " syscallFunc" - fmt.Printf(srcTemplate, cmdLine(), buildTags(), pack, imp, dynimports, linknames, vardecls, text) -} - -const srcTemplate = `// %s -// Code generated by the command above; see README.md. DO NOT EDIT. - -// +build %s - -package %s - -import ( - "syscall" - "unsafe" -) -%s -%s -%s -var ( -%s -) - -%s -` diff --git a/vendor/golang.org/x/sys/unix/mksysnum.go b/vendor/golang.org/x/sys/unix/mksysnum.go deleted file mode 100644 index 07f8960ff38c50eadfe01ae55ba442247f6b9a88..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/mksysnum.go +++ /dev/null @@ -1,190 +0,0 @@ -// Copyright 2018 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -// Generate system call table for DragonFly, NetBSD, -// FreeBSD, OpenBSD or Darwin from master list -// (for example, /usr/src/sys/kern/syscalls.master or -// sys/syscall.h). -package main - -import ( - "bufio" - "fmt" - "io" - "io/ioutil" - "net/http" - "os" - "regexp" - "strings" -) - -var ( - goos, goarch string -) - -// cmdLine returns this programs's commandline arguments -func cmdLine() string { - return "go run mksysnum.go " + strings.Join(os.Args[1:], " ") -} - -// buildTags returns build tags -func buildTags() string { - return fmt.Sprintf("%s,%s", goarch, goos) -} - -func checkErr(err error) { - if err != nil { - fmt.Fprintf(os.Stderr, "%v\n", err) - os.Exit(1) - } -} - -// source string and substring slice for regexp -type re struct { - str string // source string - sub []string // matched sub-string -} - -// Match performs regular expression match -func (r *re) Match(exp string) bool { - r.sub = regexp.MustCompile(exp).FindStringSubmatch(r.str) - if r.sub != nil { - return true - } - return false -} - -// fetchFile fetches a text file from URL -func fetchFile(URL string) io.Reader { - resp, err := http.Get(URL) - checkErr(err) - defer resp.Body.Close() - body, err := ioutil.ReadAll(resp.Body) - checkErr(err) - return strings.NewReader(string(body)) -} - -// readFile reads a text file from path -func readFile(path string) io.Reader { - file, err := os.Open(os.Args[1]) - checkErr(err) - return file -} - -func format(name, num, proto string) string { - name = strings.ToUpper(name) - // There are multiple entries for enosys and nosys, so comment them out. - nm := re{str: name} - if nm.Match(`^SYS_E?NOSYS$`) { - name = fmt.Sprintf("// %s", name) - } - if name == `SYS_SYS_EXIT` { - name = `SYS_EXIT` - } - return fmt.Sprintf(" %s = %s; // %s\n", name, num, proto) -} - -func main() { - // Get the OS (using GOOS_TARGET if it exist) - goos = os.Getenv("GOOS_TARGET") - if goos == "" { - goos = os.Getenv("GOOS") - } - // Get the architecture (using GOARCH_TARGET if it exists) - goarch = os.Getenv("GOARCH_TARGET") - if goarch == "" { - goarch = os.Getenv("GOARCH") - } - // Check if GOOS and GOARCH environment variables are defined - if goarch == "" || goos == "" { - fmt.Fprintf(os.Stderr, "GOARCH or GOOS not defined in environment\n") - os.Exit(1) - } - - file := strings.TrimSpace(os.Args[1]) - var syscalls io.Reader - if strings.HasPrefix(file, "https://") || strings.HasPrefix(file, "http://") { - // Download syscalls.master file - syscalls = fetchFile(file) - } else { - syscalls = readFile(file) - } - - var text, line string - s := bufio.NewScanner(syscalls) - for s.Scan() { - t := re{str: line} - if t.Match(`^(.*)\\$`) { - // Handle continuation - line = t.sub[1] - line += strings.TrimLeft(s.Text(), " \t") - } else { - // New line - line = s.Text() - } - t = re{str: line} - if t.Match(`\\$`) { - continue - } - t = re{str: line} - - switch goos { - case "dragonfly": - if t.Match(`^([0-9]+)\s+STD\s+({ \S+\s+(\w+).*)$`) { - num, proto := t.sub[1], t.sub[2] - name := fmt.Sprintf("SYS_%s", t.sub[3]) - text += format(name, num, proto) - } - case "freebsd": - if t.Match(`^([0-9]+)\s+\S+\s+(?:NO)?STD\s+({ \S+\s+(\w+).*)$`) { - num, proto := t.sub[1], t.sub[2] - name := fmt.Sprintf("SYS_%s", t.sub[3]) - text += format(name, num, proto) - } - case "openbsd": - if t.Match(`^([0-9]+)\s+STD\s+(NOLOCK\s+)?({ \S+\s+\*?(\w+).*)$`) { - num, proto, name := t.sub[1], t.sub[3], t.sub[4] - text += format(name, num, proto) - } - case "netbsd": - if t.Match(`^([0-9]+)\s+((STD)|(NOERR))\s+(RUMP\s+)?({\s+\S+\s*\*?\s*\|(\S+)\|(\S*)\|(\w+).*\s+})(\s+(\S+))?$`) { - num, proto, compat := t.sub[1], t.sub[6], t.sub[8] - name := t.sub[7] + "_" + t.sub[9] - if t.sub[11] != "" { - name = t.sub[7] + "_" + t.sub[11] - } - name = strings.ToUpper(name) - if compat == "" || compat == "13" || compat == "30" || compat == "50" { - text += fmt.Sprintf(" %s = %s; // %s\n", name, num, proto) - } - } - case "darwin": - if t.Match(`^#define\s+SYS_(\w+)\s+([0-9]+)`) { - name, num := t.sub[1], t.sub[2] - name = strings.ToUpper(name) - text += fmt.Sprintf(" SYS_%s = %s;\n", name, num) - } - default: - fmt.Fprintf(os.Stderr, "unrecognized GOOS=%s\n", goos) - os.Exit(1) - - } - } - err := s.Err() - checkErr(err) - - fmt.Printf(template, cmdLine(), buildTags(), text) -} - -const template = `// %s -// Code generated by the command above; see README.md. DO NOT EDIT. - -// +build %s - -package unix - -const( -%s)` diff --git a/vendor/golang.org/x/sys/unix/types_aix.go b/vendor/golang.org/x/sys/unix/types_aix.go deleted file mode 100644 index 25e834940d712121730d25922e7841f22ed71969..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/types_aix.go +++ /dev/null @@ -1,236 +0,0 @@ -// Copyright 2018 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore -// +build aix - -/* -Input to cgo -godefs. See also mkerrors.sh and mkall.sh -*/ - -// +godefs map struct_in_addr [4]byte /* in_addr */ -// +godefs map struct_in6_addr [16]byte /* in6_addr */ - -package unix - -/* -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include - -#include -#include -#include -#include - - -#include -#include - -enum { - sizeofPtr = sizeof(void*), -}; - -union sockaddr_all { - struct sockaddr s1; // this one gets used for fields - struct sockaddr_in s2; // these pad it out - struct sockaddr_in6 s3; - struct sockaddr_un s4; - struct sockaddr_dl s5; -}; - -struct sockaddr_any { - struct sockaddr addr; - char pad[sizeof(union sockaddr_all) - sizeof(struct sockaddr)]; -}; - -*/ -import "C" - -// Machine characteristics - -const ( - SizeofPtr = C.sizeofPtr - SizeofShort = C.sizeof_short - SizeofInt = C.sizeof_int - SizeofLong = C.sizeof_long - SizeofLongLong = C.sizeof_longlong - PathMax = C.PATH_MAX -) - -// Basic types - -type ( - _C_short C.short - _C_int C.int - _C_long C.long - _C_long_long C.longlong -) - -type off64 C.off64_t -type off C.off_t -type Mode_t C.mode_t - -// Time - -type Timespec C.struct_timespec - -type StTimespec C.struct_st_timespec - -type Timeval C.struct_timeval - -type Timeval32 C.struct_timeval32 - -type Timex C.struct_timex - -type Time_t C.time_t - -type Tms C.struct_tms - -type Utimbuf C.struct_utimbuf - -type Timezone C.struct_timezone - -// Processes - -type Rusage C.struct_rusage - -type Rlimit C.struct_rlimit64 - -type Pid_t C.pid_t - -type _Gid_t C.gid_t - -type dev_t C.dev_t - -// Files - -type Stat_t C.struct_stat - -type StatxTimestamp C.struct_statx_timestamp - -type Statx_t C.struct_statx - -type Dirent C.struct_dirent - -// Sockets - -type RawSockaddrInet4 C.struct_sockaddr_in - -type RawSockaddrInet6 C.struct_sockaddr_in6 - -type RawSockaddrUnix C.struct_sockaddr_un - -type RawSockaddr C.struct_sockaddr - -type RawSockaddrAny C.struct_sockaddr_any - -type _Socklen C.socklen_t - -type Cmsghdr C.struct_cmsghdr - -type ICMPv6Filter C.struct_icmp6_filter - -type Iovec C.struct_iovec - -type IPMreq C.struct_ip_mreq - -type IPv6Mreq C.struct_ipv6_mreq - -type IPv6MTUInfo C.struct_ip6_mtuinfo - -type Linger C.struct_linger - -type Msghdr C.struct_msghdr - -const ( - SizeofSockaddrInet4 = C.sizeof_struct_sockaddr_in - SizeofSockaddrInet6 = C.sizeof_struct_sockaddr_in6 - SizeofSockaddrAny = C.sizeof_struct_sockaddr_any - SizeofSockaddrUnix = C.sizeof_struct_sockaddr_un - SizeofLinger = C.sizeof_struct_linger - SizeofIPMreq = C.sizeof_struct_ip_mreq - SizeofIPv6Mreq = C.sizeof_struct_ipv6_mreq - SizeofIPv6MTUInfo = C.sizeof_struct_ip6_mtuinfo - SizeofMsghdr = C.sizeof_struct_msghdr - SizeofCmsghdr = C.sizeof_struct_cmsghdr - SizeofICMPv6Filter = C.sizeof_struct_icmp6_filter -) - -// Routing and interface messages - -const ( - SizeofIfMsghdr = C.sizeof_struct_if_msghdr -) - -type IfMsgHdr C.struct_if_msghdr - -// Misc - -type FdSet C.fd_set - -type Utsname C.struct_utsname - -type Ustat_t C.struct_ustat - -type Sigset_t C.sigset_t - -const ( - AT_FDCWD = C.AT_FDCWD - AT_REMOVEDIR = C.AT_REMOVEDIR - AT_SYMLINK_NOFOLLOW = C.AT_SYMLINK_NOFOLLOW -) - -// Terminal handling - -type Termios C.struct_termios - -type Termio C.struct_termio - -type Winsize C.struct_winsize - -//poll - -type PollFd struct { - Fd int32 - Events uint16 - Revents uint16 -} - -const ( - POLLERR = C.POLLERR - POLLHUP = C.POLLHUP - POLLIN = C.POLLIN - POLLNVAL = C.POLLNVAL - POLLOUT = C.POLLOUT - POLLPRI = C.POLLPRI - POLLRDBAND = C.POLLRDBAND - POLLRDNORM = C.POLLRDNORM - POLLWRBAND = C.POLLWRBAND - POLLWRNORM = C.POLLWRNORM -) - -//flock_t - -type Flock_t C.struct_flock64 - -// Statfs - -type Fsid_t C.struct_fsid_t -type Fsid64_t C.struct_fsid64_t - -type Statfs_t C.struct_statfs - -const RNDGETENTCNT = 0x80045200 diff --git a/vendor/golang.org/x/sys/unix/types_darwin.go b/vendor/golang.org/x/sys/unix/types_darwin.go deleted file mode 100644 index 9fd2aaa6a224decf7f702e07574cee0ac30527e4..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/types_darwin.go +++ /dev/null @@ -1,277 +0,0 @@ -// Copyright 2009 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -/* -Input to cgo -godefs. See README.md -*/ - -// +godefs map struct_in_addr [4]byte /* in_addr */ -// +godefs map struct_in6_addr [16]byte /* in6_addr */ - -package unix - -/* -#define __DARWIN_UNIX03 0 -#define KERNEL -#define _DARWIN_USE_64_BIT_INODE -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -enum { - sizeofPtr = sizeof(void*), -}; - -union sockaddr_all { - struct sockaddr s1; // this one gets used for fields - struct sockaddr_in s2; // these pad it out - struct sockaddr_in6 s3; - struct sockaddr_un s4; - struct sockaddr_dl s5; -}; - -struct sockaddr_any { - struct sockaddr addr; - char pad[sizeof(union sockaddr_all) - sizeof(struct sockaddr)]; -}; - -*/ -import "C" - -// Machine characteristics - -const ( - SizeofPtr = C.sizeofPtr - SizeofShort = C.sizeof_short - SizeofInt = C.sizeof_int - SizeofLong = C.sizeof_long - SizeofLongLong = C.sizeof_longlong -) - -// Basic types - -type ( - _C_short C.short - _C_int C.int - _C_long C.long - _C_long_long C.longlong -) - -// Time - -type Timespec C.struct_timespec - -type Timeval C.struct_timeval - -type Timeval32 C.struct_timeval32 - -// Processes - -type Rusage C.struct_rusage - -type Rlimit C.struct_rlimit - -type _Gid_t C.gid_t - -// Files - -type Stat_t C.struct_stat64 - -type Statfs_t C.struct_statfs64 - -type Flock_t C.struct_flock - -type Fstore_t C.struct_fstore - -type Radvisory_t C.struct_radvisory - -type Fbootstraptransfer_t C.struct_fbootstraptransfer - -type Log2phys_t C.struct_log2phys - -type Fsid C.struct_fsid - -type Dirent C.struct_dirent - -// Sockets - -type RawSockaddrInet4 C.struct_sockaddr_in - -type RawSockaddrInet6 C.struct_sockaddr_in6 - -type RawSockaddrUnix C.struct_sockaddr_un - -type RawSockaddrDatalink C.struct_sockaddr_dl - -type RawSockaddr C.struct_sockaddr - -type RawSockaddrAny C.struct_sockaddr_any - -type _Socklen C.socklen_t - -type Linger C.struct_linger - -type Iovec C.struct_iovec - -type IPMreq C.struct_ip_mreq - -type IPv6Mreq C.struct_ipv6_mreq - -type Msghdr C.struct_msghdr - -type Cmsghdr C.struct_cmsghdr - -type Inet4Pktinfo C.struct_in_pktinfo - -type Inet6Pktinfo C.struct_in6_pktinfo - -type IPv6MTUInfo C.struct_ip6_mtuinfo - -type ICMPv6Filter C.struct_icmp6_filter - -const ( - SizeofSockaddrInet4 = C.sizeof_struct_sockaddr_in - SizeofSockaddrInet6 = C.sizeof_struct_sockaddr_in6 - SizeofSockaddrAny = C.sizeof_struct_sockaddr_any - SizeofSockaddrUnix = C.sizeof_struct_sockaddr_un - SizeofSockaddrDatalink = C.sizeof_struct_sockaddr_dl - SizeofLinger = C.sizeof_struct_linger - SizeofIPMreq = C.sizeof_struct_ip_mreq - SizeofIPv6Mreq = C.sizeof_struct_ipv6_mreq - SizeofMsghdr = C.sizeof_struct_msghdr - SizeofCmsghdr = C.sizeof_struct_cmsghdr - SizeofInet4Pktinfo = C.sizeof_struct_in_pktinfo - SizeofInet6Pktinfo = C.sizeof_struct_in6_pktinfo - SizeofIPv6MTUInfo = C.sizeof_struct_ip6_mtuinfo - SizeofICMPv6Filter = C.sizeof_struct_icmp6_filter -) - -// Ptrace requests - -const ( - PTRACE_TRACEME = C.PT_TRACE_ME - PTRACE_CONT = C.PT_CONTINUE - PTRACE_KILL = C.PT_KILL -) - -// Events (kqueue, kevent) - -type Kevent_t C.struct_kevent - -// Select - -type FdSet C.fd_set - -// Routing and interface messages - -const ( - SizeofIfMsghdr = C.sizeof_struct_if_msghdr - SizeofIfData = C.sizeof_struct_if_data - SizeofIfaMsghdr = C.sizeof_struct_ifa_msghdr - SizeofIfmaMsghdr = C.sizeof_struct_ifma_msghdr - SizeofIfmaMsghdr2 = C.sizeof_struct_ifma_msghdr2 - SizeofRtMsghdr = C.sizeof_struct_rt_msghdr - SizeofRtMetrics = C.sizeof_struct_rt_metrics -) - -type IfMsghdr C.struct_if_msghdr - -type IfData C.struct_if_data - -type IfaMsghdr C.struct_ifa_msghdr - -type IfmaMsghdr C.struct_ifma_msghdr - -type IfmaMsghdr2 C.struct_ifma_msghdr2 - -type RtMsghdr C.struct_rt_msghdr - -type RtMetrics C.struct_rt_metrics - -// Berkeley packet filter - -const ( - SizeofBpfVersion = C.sizeof_struct_bpf_version - SizeofBpfStat = C.sizeof_struct_bpf_stat - SizeofBpfProgram = C.sizeof_struct_bpf_program - SizeofBpfInsn = C.sizeof_struct_bpf_insn - SizeofBpfHdr = C.sizeof_struct_bpf_hdr -) - -type BpfVersion C.struct_bpf_version - -type BpfStat C.struct_bpf_stat - -type BpfProgram C.struct_bpf_program - -type BpfInsn C.struct_bpf_insn - -type BpfHdr C.struct_bpf_hdr - -// Terminal handling - -type Termios C.struct_termios - -type Winsize C.struct_winsize - -// fchmodat-like syscalls. - -const ( - AT_FDCWD = C.AT_FDCWD - AT_REMOVEDIR = C.AT_REMOVEDIR - AT_SYMLINK_FOLLOW = C.AT_SYMLINK_FOLLOW - AT_SYMLINK_NOFOLLOW = C.AT_SYMLINK_NOFOLLOW -) - -// poll - -type PollFd C.struct_pollfd - -const ( - POLLERR = C.POLLERR - POLLHUP = C.POLLHUP - POLLIN = C.POLLIN - POLLNVAL = C.POLLNVAL - POLLOUT = C.POLLOUT - POLLPRI = C.POLLPRI - POLLRDBAND = C.POLLRDBAND - POLLRDNORM = C.POLLRDNORM - POLLWRBAND = C.POLLWRBAND - POLLWRNORM = C.POLLWRNORM -) - -// uname - -type Utsname C.struct_utsname diff --git a/vendor/golang.org/x/sys/unix/types_dragonfly.go b/vendor/golang.org/x/sys/unix/types_dragonfly.go deleted file mode 100644 index 3365dd79d082c232ec189b6d1dbcf0eb21ea8364..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/types_dragonfly.go +++ /dev/null @@ -1,263 +0,0 @@ -// Copyright 2009 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -/* -Input to cgo -godefs. See README.md -*/ - -// +godefs map struct_in_addr [4]byte /* in_addr */ -// +godefs map struct_in6_addr [16]byte /* in6_addr */ - -package unix - -/* -#define KERNEL -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -enum { - sizeofPtr = sizeof(void*), -}; - -union sockaddr_all { - struct sockaddr s1; // this one gets used for fields - struct sockaddr_in s2; // these pad it out - struct sockaddr_in6 s3; - struct sockaddr_un s4; - struct sockaddr_dl s5; -}; - -struct sockaddr_any { - struct sockaddr addr; - char pad[sizeof(union sockaddr_all) - sizeof(struct sockaddr)]; -}; - -*/ -import "C" - -// Machine characteristics - -const ( - SizeofPtr = C.sizeofPtr - SizeofShort = C.sizeof_short - SizeofInt = C.sizeof_int - SizeofLong = C.sizeof_long - SizeofLongLong = C.sizeof_longlong -) - -// Basic types - -type ( - _C_short C.short - _C_int C.int - _C_long C.long - _C_long_long C.longlong -) - -// Time - -type Timespec C.struct_timespec - -type Timeval C.struct_timeval - -// Processes - -type Rusage C.struct_rusage - -type Rlimit C.struct_rlimit - -type _Gid_t C.gid_t - -// Files - -type Stat_t C.struct_stat - -type Statfs_t C.struct_statfs - -type Flock_t C.struct_flock - -type Dirent C.struct_dirent - -type Fsid C.struct_fsid - -// File system limits - -const ( - PathMax = C.PATH_MAX -) - -// Sockets - -type RawSockaddrInet4 C.struct_sockaddr_in - -type RawSockaddrInet6 C.struct_sockaddr_in6 - -type RawSockaddrUnix C.struct_sockaddr_un - -type RawSockaddrDatalink C.struct_sockaddr_dl - -type RawSockaddr C.struct_sockaddr - -type RawSockaddrAny C.struct_sockaddr_any - -type _Socklen C.socklen_t - -type Linger C.struct_linger - -type Iovec C.struct_iovec - -type IPMreq C.struct_ip_mreq - -type IPv6Mreq C.struct_ipv6_mreq - -type Msghdr C.struct_msghdr - -type Cmsghdr C.struct_cmsghdr - -type Inet6Pktinfo C.struct_in6_pktinfo - -type IPv6MTUInfo C.struct_ip6_mtuinfo - -type ICMPv6Filter C.struct_icmp6_filter - -const ( - SizeofSockaddrInet4 = C.sizeof_struct_sockaddr_in - SizeofSockaddrInet6 = C.sizeof_struct_sockaddr_in6 - SizeofSockaddrAny = C.sizeof_struct_sockaddr_any - SizeofSockaddrUnix = C.sizeof_struct_sockaddr_un - SizeofSockaddrDatalink = C.sizeof_struct_sockaddr_dl - SizeofLinger = C.sizeof_struct_linger - SizeofIPMreq = C.sizeof_struct_ip_mreq - SizeofIPv6Mreq = C.sizeof_struct_ipv6_mreq - SizeofMsghdr = C.sizeof_struct_msghdr - SizeofCmsghdr = C.sizeof_struct_cmsghdr - SizeofInet6Pktinfo = C.sizeof_struct_in6_pktinfo - SizeofIPv6MTUInfo = C.sizeof_struct_ip6_mtuinfo - SizeofICMPv6Filter = C.sizeof_struct_icmp6_filter -) - -// Ptrace requests - -const ( - PTRACE_TRACEME = C.PT_TRACE_ME - PTRACE_CONT = C.PT_CONTINUE - PTRACE_KILL = C.PT_KILL -) - -// Events (kqueue, kevent) - -type Kevent_t C.struct_kevent - -// Select - -type FdSet C.fd_set - -// Routing and interface messages - -const ( - SizeofIfMsghdr = C.sizeof_struct_if_msghdr - SizeofIfData = C.sizeof_struct_if_data - SizeofIfaMsghdr = C.sizeof_struct_ifa_msghdr - SizeofIfmaMsghdr = C.sizeof_struct_ifma_msghdr - SizeofIfAnnounceMsghdr = C.sizeof_struct_if_announcemsghdr - SizeofRtMsghdr = C.sizeof_struct_rt_msghdr - SizeofRtMetrics = C.sizeof_struct_rt_metrics -) - -type IfMsghdr C.struct_if_msghdr - -type IfData C.struct_if_data - -type IfaMsghdr C.struct_ifa_msghdr - -type IfmaMsghdr C.struct_ifma_msghdr - -type IfAnnounceMsghdr C.struct_if_announcemsghdr - -type RtMsghdr C.struct_rt_msghdr - -type RtMetrics C.struct_rt_metrics - -// Berkeley packet filter - -const ( - SizeofBpfVersion = C.sizeof_struct_bpf_version - SizeofBpfStat = C.sizeof_struct_bpf_stat - SizeofBpfProgram = C.sizeof_struct_bpf_program - SizeofBpfInsn = C.sizeof_struct_bpf_insn - SizeofBpfHdr = C.sizeof_struct_bpf_hdr -) - -type BpfVersion C.struct_bpf_version - -type BpfStat C.struct_bpf_stat - -type BpfProgram C.struct_bpf_program - -type BpfInsn C.struct_bpf_insn - -type BpfHdr C.struct_bpf_hdr - -// Terminal handling - -type Termios C.struct_termios - -type Winsize C.struct_winsize - -// fchmodat-like syscalls. - -const ( - AT_FDCWD = C.AT_FDCWD - AT_SYMLINK_NOFOLLOW = C.AT_SYMLINK_NOFOLLOW -) - -// poll - -type PollFd C.struct_pollfd - -const ( - POLLERR = C.POLLERR - POLLHUP = C.POLLHUP - POLLIN = C.POLLIN - POLLNVAL = C.POLLNVAL - POLLOUT = C.POLLOUT - POLLPRI = C.POLLPRI - POLLRDBAND = C.POLLRDBAND - POLLRDNORM = C.POLLRDNORM - POLLWRBAND = C.POLLWRBAND - POLLWRNORM = C.POLLWRNORM -) - -// Uname - -type Utsname C.struct_utsname diff --git a/vendor/golang.org/x/sys/unix/types_freebsd.go b/vendor/golang.org/x/sys/unix/types_freebsd.go deleted file mode 100644 index 74707989512514f57373d407b71d697413888bf6..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/types_freebsd.go +++ /dev/null @@ -1,356 +0,0 @@ -// Copyright 2009 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -/* -Input to cgo -godefs. See README.md -*/ - -// +godefs map struct_in_addr [4]byte /* in_addr */ -// +godefs map struct_in6_addr [16]byte /* in6_addr */ - -package unix - -/* -#define _WANT_FREEBSD11_STAT 1 -#define _WANT_FREEBSD11_STATFS 1 -#define _WANT_FREEBSD11_DIRENT 1 -#define _WANT_FREEBSD11_KEVENT 1 - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -enum { - sizeofPtr = sizeof(void*), -}; - -union sockaddr_all { - struct sockaddr s1; // this one gets used for fields - struct sockaddr_in s2; // these pad it out - struct sockaddr_in6 s3; - struct sockaddr_un s4; - struct sockaddr_dl s5; -}; - -struct sockaddr_any { - struct sockaddr addr; - char pad[sizeof(union sockaddr_all) - sizeof(struct sockaddr)]; -}; - -// This structure is a duplicate of if_data on FreeBSD 8-STABLE. -// See /usr/include/net/if.h. -struct if_data8 { - u_char ifi_type; - u_char ifi_physical; - u_char ifi_addrlen; - u_char ifi_hdrlen; - u_char ifi_link_state; - u_char ifi_spare_char1; - u_char ifi_spare_char2; - u_char ifi_datalen; - u_long ifi_mtu; - u_long ifi_metric; - u_long ifi_baudrate; - u_long ifi_ipackets; - u_long ifi_ierrors; - u_long ifi_opackets; - u_long ifi_oerrors; - u_long ifi_collisions; - u_long ifi_ibytes; - u_long ifi_obytes; - u_long ifi_imcasts; - u_long ifi_omcasts; - u_long ifi_iqdrops; - u_long ifi_noproto; - u_long ifi_hwassist; -// FIXME: these are now unions, so maybe need to change definitions? -#undef ifi_epoch - time_t ifi_epoch; -#undef ifi_lastchange - struct timeval ifi_lastchange; -}; - -// This structure is a duplicate of if_msghdr on FreeBSD 8-STABLE. -// See /usr/include/net/if.h. -struct if_msghdr8 { - u_short ifm_msglen; - u_char ifm_version; - u_char ifm_type; - int ifm_addrs; - int ifm_flags; - u_short ifm_index; - struct if_data8 ifm_data; -}; -*/ -import "C" - -// Machine characteristics - -const ( - SizeofPtr = C.sizeofPtr - SizeofShort = C.sizeof_short - SizeofInt = C.sizeof_int - SizeofLong = C.sizeof_long - SizeofLongLong = C.sizeof_longlong -) - -// Basic types - -type ( - _C_short C.short - _C_int C.int - _C_long C.long - _C_long_long C.longlong -) - -// Time - -type Timespec C.struct_timespec - -type Timeval C.struct_timeval - -// Processes - -type Rusage C.struct_rusage - -type Rlimit C.struct_rlimit - -type _Gid_t C.gid_t - -// Files - -const ( - _statfsVersion = C.STATFS_VERSION - _dirblksiz = C.DIRBLKSIZ -) - -type Stat_t C.struct_stat - -type stat_freebsd11_t C.struct_freebsd11_stat - -type Statfs_t C.struct_statfs - -type statfs_freebsd11_t C.struct_freebsd11_statfs - -type Flock_t C.struct_flock - -type Dirent C.struct_dirent - -type dirent_freebsd11 C.struct_freebsd11_dirent - -type Fsid C.struct_fsid - -// File system limits - -const ( - PathMax = C.PATH_MAX -) - -// Advice to Fadvise - -const ( - FADV_NORMAL = C.POSIX_FADV_NORMAL - FADV_RANDOM = C.POSIX_FADV_RANDOM - FADV_SEQUENTIAL = C.POSIX_FADV_SEQUENTIAL - FADV_WILLNEED = C.POSIX_FADV_WILLNEED - FADV_DONTNEED = C.POSIX_FADV_DONTNEED - FADV_NOREUSE = C.POSIX_FADV_NOREUSE -) - -// Sockets - -type RawSockaddrInet4 C.struct_sockaddr_in - -type RawSockaddrInet6 C.struct_sockaddr_in6 - -type RawSockaddrUnix C.struct_sockaddr_un - -type RawSockaddrDatalink C.struct_sockaddr_dl - -type RawSockaddr C.struct_sockaddr - -type RawSockaddrAny C.struct_sockaddr_any - -type _Socklen C.socklen_t - -type Linger C.struct_linger - -type Iovec C.struct_iovec - -type IPMreq C.struct_ip_mreq - -type IPMreqn C.struct_ip_mreqn - -type IPv6Mreq C.struct_ipv6_mreq - -type Msghdr C.struct_msghdr - -type Cmsghdr C.struct_cmsghdr - -type Inet6Pktinfo C.struct_in6_pktinfo - -type IPv6MTUInfo C.struct_ip6_mtuinfo - -type ICMPv6Filter C.struct_icmp6_filter - -const ( - SizeofSockaddrInet4 = C.sizeof_struct_sockaddr_in - SizeofSockaddrInet6 = C.sizeof_struct_sockaddr_in6 - SizeofSockaddrAny = C.sizeof_struct_sockaddr_any - SizeofSockaddrUnix = C.sizeof_struct_sockaddr_un - SizeofSockaddrDatalink = C.sizeof_struct_sockaddr_dl - SizeofLinger = C.sizeof_struct_linger - SizeofIPMreq = C.sizeof_struct_ip_mreq - SizeofIPMreqn = C.sizeof_struct_ip_mreqn - SizeofIPv6Mreq = C.sizeof_struct_ipv6_mreq - SizeofMsghdr = C.sizeof_struct_msghdr - SizeofCmsghdr = C.sizeof_struct_cmsghdr - SizeofInet6Pktinfo = C.sizeof_struct_in6_pktinfo - SizeofIPv6MTUInfo = C.sizeof_struct_ip6_mtuinfo - SizeofICMPv6Filter = C.sizeof_struct_icmp6_filter -) - -// Ptrace requests - -const ( - PTRACE_TRACEME = C.PT_TRACE_ME - PTRACE_CONT = C.PT_CONTINUE - PTRACE_KILL = C.PT_KILL -) - -// Events (kqueue, kevent) - -type Kevent_t C.struct_kevent_freebsd11 - -// Select - -type FdSet C.fd_set - -// Routing and interface messages - -const ( - sizeofIfMsghdr = C.sizeof_struct_if_msghdr - SizeofIfMsghdr = C.sizeof_struct_if_msghdr8 - sizeofIfData = C.sizeof_struct_if_data - SizeofIfData = C.sizeof_struct_if_data8 - SizeofIfaMsghdr = C.sizeof_struct_ifa_msghdr - SizeofIfmaMsghdr = C.sizeof_struct_ifma_msghdr - SizeofIfAnnounceMsghdr = C.sizeof_struct_if_announcemsghdr - SizeofRtMsghdr = C.sizeof_struct_rt_msghdr - SizeofRtMetrics = C.sizeof_struct_rt_metrics -) - -type ifMsghdr C.struct_if_msghdr - -type IfMsghdr C.struct_if_msghdr8 - -type ifData C.struct_if_data - -type IfData C.struct_if_data8 - -type IfaMsghdr C.struct_ifa_msghdr - -type IfmaMsghdr C.struct_ifma_msghdr - -type IfAnnounceMsghdr C.struct_if_announcemsghdr - -type RtMsghdr C.struct_rt_msghdr - -type RtMetrics C.struct_rt_metrics - -// Berkeley packet filter - -const ( - SizeofBpfVersion = C.sizeof_struct_bpf_version - SizeofBpfStat = C.sizeof_struct_bpf_stat - SizeofBpfZbuf = C.sizeof_struct_bpf_zbuf - SizeofBpfProgram = C.sizeof_struct_bpf_program - SizeofBpfInsn = C.sizeof_struct_bpf_insn - SizeofBpfHdr = C.sizeof_struct_bpf_hdr - SizeofBpfZbufHeader = C.sizeof_struct_bpf_zbuf_header -) - -type BpfVersion C.struct_bpf_version - -type BpfStat C.struct_bpf_stat - -type BpfZbuf C.struct_bpf_zbuf - -type BpfProgram C.struct_bpf_program - -type BpfInsn C.struct_bpf_insn - -type BpfHdr C.struct_bpf_hdr - -type BpfZbufHeader C.struct_bpf_zbuf_header - -// Terminal handling - -type Termios C.struct_termios - -type Winsize C.struct_winsize - -// fchmodat-like syscalls. - -const ( - AT_FDCWD = C.AT_FDCWD - AT_REMOVEDIR = C.AT_REMOVEDIR - AT_SYMLINK_FOLLOW = C.AT_SYMLINK_FOLLOW - AT_SYMLINK_NOFOLLOW = C.AT_SYMLINK_NOFOLLOW -) - -// poll - -type PollFd C.struct_pollfd - -const ( - POLLERR = C.POLLERR - POLLHUP = C.POLLHUP - POLLIN = C.POLLIN - POLLINIGNEOF = C.POLLINIGNEOF - POLLNVAL = C.POLLNVAL - POLLOUT = C.POLLOUT - POLLPRI = C.POLLPRI - POLLRDBAND = C.POLLRDBAND - POLLRDNORM = C.POLLRDNORM - POLLWRBAND = C.POLLWRBAND - POLLWRNORM = C.POLLWRNORM -) - -// Capabilities - -type CapRights C.struct_cap_rights - -// Uname - -type Utsname C.struct_utsname diff --git a/vendor/golang.org/x/sys/unix/types_netbsd.go b/vendor/golang.org/x/sys/unix/types_netbsd.go deleted file mode 100644 index 2dd4f9542c9cba0cb663a21a538f00df904edce6..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/types_netbsd.go +++ /dev/null @@ -1,289 +0,0 @@ -// Copyright 2009 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -/* -Input to cgo -godefs. See README.md -*/ - -// +godefs map struct_in_addr [4]byte /* in_addr */ -// +godefs map struct_in6_addr [16]byte /* in6_addr */ - -package unix - -/* -#define KERNEL -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -enum { - sizeofPtr = sizeof(void*), -}; - -union sockaddr_all { - struct sockaddr s1; // this one gets used for fields - struct sockaddr_in s2; // these pad it out - struct sockaddr_in6 s3; - struct sockaddr_un s4; - struct sockaddr_dl s5; -}; - -struct sockaddr_any { - struct sockaddr addr; - char pad[sizeof(union sockaddr_all) - sizeof(struct sockaddr)]; -}; - -*/ -import "C" - -// Machine characteristics - -const ( - SizeofPtr = C.sizeofPtr - SizeofShort = C.sizeof_short - SizeofInt = C.sizeof_int - SizeofLong = C.sizeof_long - SizeofLongLong = C.sizeof_longlong -) - -// Basic types - -type ( - _C_short C.short - _C_int C.int - _C_long C.long - _C_long_long C.longlong -) - -// Time - -type Timespec C.struct_timespec - -type Timeval C.struct_timeval - -// Processes - -type Rusage C.struct_rusage - -type Rlimit C.struct_rlimit - -type _Gid_t C.gid_t - -// Files - -type Stat_t C.struct_stat - -type Statfs_t C.struct_statfs - -type Flock_t C.struct_flock - -type Dirent C.struct_dirent - -type Fsid C.fsid_t - -// File system limits - -const ( - PathMax = C.PATH_MAX -) - -// Advice to Fadvise - -const ( - FADV_NORMAL = C.POSIX_FADV_NORMAL - FADV_RANDOM = C.POSIX_FADV_RANDOM - FADV_SEQUENTIAL = C.POSIX_FADV_SEQUENTIAL - FADV_WILLNEED = C.POSIX_FADV_WILLNEED - FADV_DONTNEED = C.POSIX_FADV_DONTNEED - FADV_NOREUSE = C.POSIX_FADV_NOREUSE -) - -// Sockets - -type RawSockaddrInet4 C.struct_sockaddr_in - -type RawSockaddrInet6 C.struct_sockaddr_in6 - -type RawSockaddrUnix C.struct_sockaddr_un - -type RawSockaddrDatalink C.struct_sockaddr_dl - -type RawSockaddr C.struct_sockaddr - -type RawSockaddrAny C.struct_sockaddr_any - -type _Socklen C.socklen_t - -type Linger C.struct_linger - -type Iovec C.struct_iovec - -type IPMreq C.struct_ip_mreq - -type IPv6Mreq C.struct_ipv6_mreq - -type Msghdr C.struct_msghdr - -type Cmsghdr C.struct_cmsghdr - -type Inet6Pktinfo C.struct_in6_pktinfo - -type IPv6MTUInfo C.struct_ip6_mtuinfo - -type ICMPv6Filter C.struct_icmp6_filter - -const ( - SizeofSockaddrInet4 = C.sizeof_struct_sockaddr_in - SizeofSockaddrInet6 = C.sizeof_struct_sockaddr_in6 - SizeofSockaddrAny = C.sizeof_struct_sockaddr_any - SizeofSockaddrUnix = C.sizeof_struct_sockaddr_un - SizeofSockaddrDatalink = C.sizeof_struct_sockaddr_dl - SizeofLinger = C.sizeof_struct_linger - SizeofIPMreq = C.sizeof_struct_ip_mreq - SizeofIPv6Mreq = C.sizeof_struct_ipv6_mreq - SizeofMsghdr = C.sizeof_struct_msghdr - SizeofCmsghdr = C.sizeof_struct_cmsghdr - SizeofInet6Pktinfo = C.sizeof_struct_in6_pktinfo - SizeofIPv6MTUInfo = C.sizeof_struct_ip6_mtuinfo - SizeofICMPv6Filter = C.sizeof_struct_icmp6_filter -) - -// Ptrace requests - -const ( - PTRACE_TRACEME = C.PT_TRACE_ME - PTRACE_CONT = C.PT_CONTINUE - PTRACE_KILL = C.PT_KILL -) - -// Events (kqueue, kevent) - -type Kevent_t C.struct_kevent - -// Select - -type FdSet C.fd_set - -// Routing and interface messages - -const ( - SizeofIfMsghdr = C.sizeof_struct_if_msghdr - SizeofIfData = C.sizeof_struct_if_data - SizeofIfaMsghdr = C.sizeof_struct_ifa_msghdr - SizeofIfAnnounceMsghdr = C.sizeof_struct_if_announcemsghdr - SizeofRtMsghdr = C.sizeof_struct_rt_msghdr - SizeofRtMetrics = C.sizeof_struct_rt_metrics -) - -type IfMsghdr C.struct_if_msghdr - -type IfData C.struct_if_data - -type IfaMsghdr C.struct_ifa_msghdr - -type IfAnnounceMsghdr C.struct_if_announcemsghdr - -type RtMsghdr C.struct_rt_msghdr - -type RtMetrics C.struct_rt_metrics - -type Mclpool C.struct_mclpool - -// Berkeley packet filter - -const ( - SizeofBpfVersion = C.sizeof_struct_bpf_version - SizeofBpfStat = C.sizeof_struct_bpf_stat - SizeofBpfProgram = C.sizeof_struct_bpf_program - SizeofBpfInsn = C.sizeof_struct_bpf_insn - SizeofBpfHdr = C.sizeof_struct_bpf_hdr -) - -type BpfVersion C.struct_bpf_version - -type BpfStat C.struct_bpf_stat - -type BpfProgram C.struct_bpf_program - -type BpfInsn C.struct_bpf_insn - -type BpfHdr C.struct_bpf_hdr - -type BpfTimeval C.struct_bpf_timeval - -// Terminal handling - -type Termios C.struct_termios - -type Winsize C.struct_winsize - -type Ptmget C.struct_ptmget - -// fchmodat-like syscalls. - -const ( - AT_FDCWD = C.AT_FDCWD - AT_SYMLINK_NOFOLLOW = C.AT_SYMLINK_NOFOLLOW -) - -// poll - -type PollFd C.struct_pollfd - -const ( - POLLERR = C.POLLERR - POLLHUP = C.POLLHUP - POLLIN = C.POLLIN - POLLNVAL = C.POLLNVAL - POLLOUT = C.POLLOUT - POLLPRI = C.POLLPRI - POLLRDBAND = C.POLLRDBAND - POLLRDNORM = C.POLLRDNORM - POLLWRBAND = C.POLLWRBAND - POLLWRNORM = C.POLLWRNORM -) - -// Sysctl - -type Sysctlnode C.struct_sysctlnode - -// Uname - -type Utsname C.struct_utsname - -// Clockinfo - -const SizeofClockinfo = C.sizeof_struct_clockinfo - -type Clockinfo C.struct_clockinfo diff --git a/vendor/golang.org/x/sys/unix/types_openbsd.go b/vendor/golang.org/x/sys/unix/types_openbsd.go deleted file mode 100644 index 4e5e57f9a61a09dce8bd3ea7501038aefc870bab..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/types_openbsd.go +++ /dev/null @@ -1,276 +0,0 @@ -// Copyright 2009 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -/* -Input to cgo -godefs. See README.md -*/ - -// +godefs map struct_in_addr [4]byte /* in_addr */ -// +godefs map struct_in6_addr [16]byte /* in6_addr */ - -package unix - -/* -#define KERNEL -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -enum { - sizeofPtr = sizeof(void*), -}; - -union sockaddr_all { - struct sockaddr s1; // this one gets used for fields - struct sockaddr_in s2; // these pad it out - struct sockaddr_in6 s3; - struct sockaddr_un s4; - struct sockaddr_dl s5; -}; - -struct sockaddr_any { - struct sockaddr addr; - char pad[sizeof(union sockaddr_all) - sizeof(struct sockaddr)]; -}; - -*/ -import "C" - -// Machine characteristics - -const ( - SizeofPtr = C.sizeofPtr - SizeofShort = C.sizeof_short - SizeofInt = C.sizeof_int - SizeofLong = C.sizeof_long - SizeofLongLong = C.sizeof_longlong -) - -// Basic types - -type ( - _C_short C.short - _C_int C.int - _C_long C.long - _C_long_long C.longlong -) - -// Time - -type Timespec C.struct_timespec - -type Timeval C.struct_timeval - -// Processes - -type Rusage C.struct_rusage - -type Rlimit C.struct_rlimit - -type _Gid_t C.gid_t - -// Files - -type Stat_t C.struct_stat - -type Statfs_t C.struct_statfs - -type Flock_t C.struct_flock - -type Dirent C.struct_dirent - -type Fsid C.fsid_t - -// File system limits - -const ( - PathMax = C.PATH_MAX -) - -// Sockets - -type RawSockaddrInet4 C.struct_sockaddr_in - -type RawSockaddrInet6 C.struct_sockaddr_in6 - -type RawSockaddrUnix C.struct_sockaddr_un - -type RawSockaddrDatalink C.struct_sockaddr_dl - -type RawSockaddr C.struct_sockaddr - -type RawSockaddrAny C.struct_sockaddr_any - -type _Socklen C.socklen_t - -type Linger C.struct_linger - -type Iovec C.struct_iovec - -type IPMreq C.struct_ip_mreq - -type IPv6Mreq C.struct_ipv6_mreq - -type Msghdr C.struct_msghdr - -type Cmsghdr C.struct_cmsghdr - -type Inet6Pktinfo C.struct_in6_pktinfo - -type IPv6MTUInfo C.struct_ip6_mtuinfo - -type ICMPv6Filter C.struct_icmp6_filter - -const ( - SizeofSockaddrInet4 = C.sizeof_struct_sockaddr_in - SizeofSockaddrInet6 = C.sizeof_struct_sockaddr_in6 - SizeofSockaddrAny = C.sizeof_struct_sockaddr_any - SizeofSockaddrUnix = C.sizeof_struct_sockaddr_un - SizeofSockaddrDatalink = C.sizeof_struct_sockaddr_dl - SizeofLinger = C.sizeof_struct_linger - SizeofIPMreq = C.sizeof_struct_ip_mreq - SizeofIPv6Mreq = C.sizeof_struct_ipv6_mreq - SizeofMsghdr = C.sizeof_struct_msghdr - SizeofCmsghdr = C.sizeof_struct_cmsghdr - SizeofInet6Pktinfo = C.sizeof_struct_in6_pktinfo - SizeofIPv6MTUInfo = C.sizeof_struct_ip6_mtuinfo - SizeofICMPv6Filter = C.sizeof_struct_icmp6_filter -) - -// Ptrace requests - -const ( - PTRACE_TRACEME = C.PT_TRACE_ME - PTRACE_CONT = C.PT_CONTINUE - PTRACE_KILL = C.PT_KILL -) - -// Events (kqueue, kevent) - -type Kevent_t C.struct_kevent - -// Select - -type FdSet C.fd_set - -// Routing and interface messages - -const ( - SizeofIfMsghdr = C.sizeof_struct_if_msghdr - SizeofIfData = C.sizeof_struct_if_data - SizeofIfaMsghdr = C.sizeof_struct_ifa_msghdr - SizeofIfAnnounceMsghdr = C.sizeof_struct_if_announcemsghdr - SizeofRtMsghdr = C.sizeof_struct_rt_msghdr - SizeofRtMetrics = C.sizeof_struct_rt_metrics -) - -type IfMsghdr C.struct_if_msghdr - -type IfData C.struct_if_data - -type IfaMsghdr C.struct_ifa_msghdr - -type IfAnnounceMsghdr C.struct_if_announcemsghdr - -type RtMsghdr C.struct_rt_msghdr - -type RtMetrics C.struct_rt_metrics - -type Mclpool C.struct_mclpool - -// Berkeley packet filter - -const ( - SizeofBpfVersion = C.sizeof_struct_bpf_version - SizeofBpfStat = C.sizeof_struct_bpf_stat - SizeofBpfProgram = C.sizeof_struct_bpf_program - SizeofBpfInsn = C.sizeof_struct_bpf_insn - SizeofBpfHdr = C.sizeof_struct_bpf_hdr -) - -type BpfVersion C.struct_bpf_version - -type BpfStat C.struct_bpf_stat - -type BpfProgram C.struct_bpf_program - -type BpfInsn C.struct_bpf_insn - -type BpfHdr C.struct_bpf_hdr - -type BpfTimeval C.struct_bpf_timeval - -// Terminal handling - -type Termios C.struct_termios - -type Winsize C.struct_winsize - -// fchmodat-like syscalls. - -const ( - AT_FDCWD = C.AT_FDCWD - AT_SYMLINK_NOFOLLOW = C.AT_SYMLINK_NOFOLLOW -) - -// poll - -type PollFd C.struct_pollfd - -const ( - POLLERR = C.POLLERR - POLLHUP = C.POLLHUP - POLLIN = C.POLLIN - POLLNVAL = C.POLLNVAL - POLLOUT = C.POLLOUT - POLLPRI = C.POLLPRI - POLLRDBAND = C.POLLRDBAND - POLLRDNORM = C.POLLRDNORM - POLLWRBAND = C.POLLWRBAND - POLLWRNORM = C.POLLWRNORM -) - -// Signal Sets - -type Sigset_t C.sigset_t - -// Uname - -type Utsname C.struct_utsname - -// Uvmexp - -const SizeofUvmexp = C.sizeof_struct_uvmexp - -type Uvmexp C.struct_uvmexp diff --git a/vendor/golang.org/x/sys/unix/types_solaris.go b/vendor/golang.org/x/sys/unix/types_solaris.go deleted file mode 100644 index 2b716f93481d8bdb024efc7972a7d1b1de8391ba..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/sys/unix/types_solaris.go +++ /dev/null @@ -1,266 +0,0 @@ -// Copyright 2009 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -/* -Input to cgo -godefs. See README.md -*/ - -// +godefs map struct_in_addr [4]byte /* in_addr */ -// +godefs map struct_in6_addr [16]byte /* in6_addr */ - -package unix - -/* -#define KERNEL -// These defines ensure that builds done on newer versions of Solaris are -// backwards-compatible with older versions of Solaris and -// OpenSolaris-based derivatives. -#define __USE_SUNOS_SOCKETS__ // msghdr -#define __USE_LEGACY_PROTOTYPES__ // iovec -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -enum { - sizeofPtr = sizeof(void*), -}; - -union sockaddr_all { - struct sockaddr s1; // this one gets used for fields - struct sockaddr_in s2; // these pad it out - struct sockaddr_in6 s3; - struct sockaddr_un s4; - struct sockaddr_dl s5; -}; - -struct sockaddr_any { - struct sockaddr addr; - char pad[sizeof(union sockaddr_all) - sizeof(struct sockaddr)]; -}; - -*/ -import "C" - -// Machine characteristics - -const ( - SizeofPtr = C.sizeofPtr - SizeofShort = C.sizeof_short - SizeofInt = C.sizeof_int - SizeofLong = C.sizeof_long - SizeofLongLong = C.sizeof_longlong - PathMax = C.PATH_MAX - MaxHostNameLen = C.MAXHOSTNAMELEN -) - -// Basic types - -type ( - _C_short C.short - _C_int C.int - _C_long C.long - _C_long_long C.longlong -) - -// Time - -type Timespec C.struct_timespec - -type Timeval C.struct_timeval - -type Timeval32 C.struct_timeval32 - -type Tms C.struct_tms - -type Utimbuf C.struct_utimbuf - -// Processes - -type Rusage C.struct_rusage - -type Rlimit C.struct_rlimit - -type _Gid_t C.gid_t - -// Files - -type Stat_t C.struct_stat - -type Flock_t C.struct_flock - -type Dirent C.struct_dirent - -// Filesystems - -type _Fsblkcnt_t C.fsblkcnt_t - -type Statvfs_t C.struct_statvfs - -// Sockets - -type RawSockaddrInet4 C.struct_sockaddr_in - -type RawSockaddrInet6 C.struct_sockaddr_in6 - -type RawSockaddrUnix C.struct_sockaddr_un - -type RawSockaddrDatalink C.struct_sockaddr_dl - -type RawSockaddr C.struct_sockaddr - -type RawSockaddrAny C.struct_sockaddr_any - -type _Socklen C.socklen_t - -type Linger C.struct_linger - -type Iovec C.struct_iovec - -type IPMreq C.struct_ip_mreq - -type IPv6Mreq C.struct_ipv6_mreq - -type Msghdr C.struct_msghdr - -type Cmsghdr C.struct_cmsghdr - -type Inet6Pktinfo C.struct_in6_pktinfo - -type IPv6MTUInfo C.struct_ip6_mtuinfo - -type ICMPv6Filter C.struct_icmp6_filter - -const ( - SizeofSockaddrInet4 = C.sizeof_struct_sockaddr_in - SizeofSockaddrInet6 = C.sizeof_struct_sockaddr_in6 - SizeofSockaddrAny = C.sizeof_struct_sockaddr_any - SizeofSockaddrUnix = C.sizeof_struct_sockaddr_un - SizeofSockaddrDatalink = C.sizeof_struct_sockaddr_dl - SizeofLinger = C.sizeof_struct_linger - SizeofIPMreq = C.sizeof_struct_ip_mreq - SizeofIPv6Mreq = C.sizeof_struct_ipv6_mreq - SizeofMsghdr = C.sizeof_struct_msghdr - SizeofCmsghdr = C.sizeof_struct_cmsghdr - SizeofInet6Pktinfo = C.sizeof_struct_in6_pktinfo - SizeofIPv6MTUInfo = C.sizeof_struct_ip6_mtuinfo - SizeofICMPv6Filter = C.sizeof_struct_icmp6_filter -) - -// Select - -type FdSet C.fd_set - -// Misc - -type Utsname C.struct_utsname - -type Ustat_t C.struct_ustat - -const ( - AT_FDCWD = C.AT_FDCWD - AT_SYMLINK_NOFOLLOW = C.AT_SYMLINK_NOFOLLOW - AT_SYMLINK_FOLLOW = C.AT_SYMLINK_FOLLOW - AT_REMOVEDIR = C.AT_REMOVEDIR - AT_EACCESS = C.AT_EACCESS -) - -// Routing and interface messages - -const ( - SizeofIfMsghdr = C.sizeof_struct_if_msghdr - SizeofIfData = C.sizeof_struct_if_data - SizeofIfaMsghdr = C.sizeof_struct_ifa_msghdr - SizeofRtMsghdr = C.sizeof_struct_rt_msghdr - SizeofRtMetrics = C.sizeof_struct_rt_metrics -) - -type IfMsghdr C.struct_if_msghdr - -type IfData C.struct_if_data - -type IfaMsghdr C.struct_ifa_msghdr - -type RtMsghdr C.struct_rt_msghdr - -type RtMetrics C.struct_rt_metrics - -// Berkeley packet filter - -const ( - SizeofBpfVersion = C.sizeof_struct_bpf_version - SizeofBpfStat = C.sizeof_struct_bpf_stat - SizeofBpfProgram = C.sizeof_struct_bpf_program - SizeofBpfInsn = C.sizeof_struct_bpf_insn - SizeofBpfHdr = C.sizeof_struct_bpf_hdr -) - -type BpfVersion C.struct_bpf_version - -type BpfStat C.struct_bpf_stat - -type BpfProgram C.struct_bpf_program - -type BpfInsn C.struct_bpf_insn - -type BpfTimeval C.struct_bpf_timeval - -type BpfHdr C.struct_bpf_hdr - -// Terminal handling - -type Termios C.struct_termios - -type Termio C.struct_termio - -type Winsize C.struct_winsize - -// poll - -type PollFd C.struct_pollfd - -const ( - POLLERR = C.POLLERR - POLLHUP = C.POLLHUP - POLLIN = C.POLLIN - POLLNVAL = C.POLLNVAL - POLLOUT = C.POLLOUT - POLLPRI = C.POLLPRI - POLLRDBAND = C.POLLRDBAND - POLLRDNORM = C.POLLRDNORM - POLLWRBAND = C.POLLWRBAND - POLLWRNORM = C.POLLWRNORM -) diff --git a/vendor/golang.org/x/text/encoding/charmap/maketables.go b/vendor/golang.org/x/text/encoding/charmap/maketables.go deleted file mode 100644 index f7941701e8304a3bfaa969c406b48236dac7efb5..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/encoding/charmap/maketables.go +++ /dev/null @@ -1,556 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -import ( - "bufio" - "fmt" - "log" - "net/http" - "sort" - "strings" - "unicode/utf8" - - "golang.org/x/text/encoding" - "golang.org/x/text/internal/gen" -) - -const ascii = "\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f" + - "\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f" + - ` !"#$%&'()*+,-./0123456789:;<=>?` + - `@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_` + - "`abcdefghijklmnopqrstuvwxyz{|}~\u007f" - -var encodings = []struct { - name string - mib string - comment string - varName string - replacement byte - mapping string -}{ - { - "IBM Code Page 037", - "IBM037", - "", - "CodePage037", - 0x3f, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/glibc-IBM037-2.1.2.ucm", - }, - { - "IBM Code Page 437", - "PC8CodePage437", - "", - "CodePage437", - encoding.ASCIISub, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/glibc-IBM437-2.1.2.ucm", - }, - { - "IBM Code Page 850", - "PC850Multilingual", - "", - "CodePage850", - encoding.ASCIISub, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/glibc-IBM850-2.1.2.ucm", - }, - { - "IBM Code Page 852", - "PCp852", - "", - "CodePage852", - encoding.ASCIISub, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/glibc-IBM852-2.1.2.ucm", - }, - { - "IBM Code Page 855", - "IBM855", - "", - "CodePage855", - encoding.ASCIISub, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/glibc-IBM855-2.1.2.ucm", - }, - { - "Windows Code Page 858", // PC latin1 with Euro - "IBM00858", - "", - "CodePage858", - encoding.ASCIISub, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/windows-858-2000.ucm", - }, - { - "IBM Code Page 860", - "IBM860", - "", - "CodePage860", - encoding.ASCIISub, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/glibc-IBM860-2.1.2.ucm", - }, - { - "IBM Code Page 862", - "PC862LatinHebrew", - "", - "CodePage862", - encoding.ASCIISub, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/glibc-IBM862-2.1.2.ucm", - }, - { - "IBM Code Page 863", - "IBM863", - "", - "CodePage863", - encoding.ASCIISub, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/glibc-IBM863-2.1.2.ucm", - }, - { - "IBM Code Page 865", - "IBM865", - "", - "CodePage865", - encoding.ASCIISub, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/glibc-IBM865-2.1.2.ucm", - }, - { - "IBM Code Page 866", - "IBM866", - "", - "CodePage866", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-ibm866.txt", - }, - { - "IBM Code Page 1047", - "IBM1047", - "", - "CodePage1047", - 0x3f, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/glibc-IBM1047-2.1.2.ucm", - }, - { - "IBM Code Page 1140", - "IBM01140", - "", - "CodePage1140", - 0x3f, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/ibm-1140_P100-1997.ucm", - }, - { - "ISO 8859-1", - "ISOLatin1", - "", - "ISO8859_1", - encoding.ASCIISub, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/iso-8859_1-1998.ucm", - }, - { - "ISO 8859-2", - "ISOLatin2", - "", - "ISO8859_2", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-2.txt", - }, - { - "ISO 8859-3", - "ISOLatin3", - "", - "ISO8859_3", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-3.txt", - }, - { - "ISO 8859-4", - "ISOLatin4", - "", - "ISO8859_4", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-4.txt", - }, - { - "ISO 8859-5", - "ISOLatinCyrillic", - "", - "ISO8859_5", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-5.txt", - }, - { - "ISO 8859-6", - "ISOLatinArabic", - "", - "ISO8859_6,ISO8859_6E,ISO8859_6I", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-6.txt", - }, - { - "ISO 8859-7", - "ISOLatinGreek", - "", - "ISO8859_7", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-7.txt", - }, - { - "ISO 8859-8", - "ISOLatinHebrew", - "", - "ISO8859_8,ISO8859_8E,ISO8859_8I", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-8.txt", - }, - { - "ISO 8859-9", - "ISOLatin5", - "", - "ISO8859_9", - encoding.ASCIISub, - "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/iso-8859_9-1999.ucm", - }, - { - "ISO 8859-10", - "ISOLatin6", - "", - "ISO8859_10", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-10.txt", - }, - { - "ISO 8859-13", - "ISO885913", - "", - "ISO8859_13", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-13.txt", - }, - { - "ISO 8859-14", - "ISO885914", - "", - "ISO8859_14", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-14.txt", - }, - { - "ISO 8859-15", - "ISO885915", - "", - "ISO8859_15", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-15.txt", - }, - { - "ISO 8859-16", - "ISO885916", - "", - "ISO8859_16", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-iso-8859-16.txt", - }, - { - "KOI8-R", - "KOI8R", - "", - "KOI8R", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-koi8-r.txt", - }, - { - "KOI8-U", - "KOI8U", - "", - "KOI8U", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-koi8-u.txt", - }, - { - "Macintosh", - "Macintosh", - "", - "Macintosh", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-macintosh.txt", - }, - { - "Macintosh Cyrillic", - "MacintoshCyrillic", - "", - "MacintoshCyrillic", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-x-mac-cyrillic.txt", - }, - { - "Windows 874", - "Windows874", - "", - "Windows874", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-windows-874.txt", - }, - { - "Windows 1250", - "Windows1250", - "", - "Windows1250", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-windows-1250.txt", - }, - { - "Windows 1251", - "Windows1251", - "", - "Windows1251", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-windows-1251.txt", - }, - { - "Windows 1252", - "Windows1252", - "", - "Windows1252", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-windows-1252.txt", - }, - { - "Windows 1253", - "Windows1253", - "", - "Windows1253", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-windows-1253.txt", - }, - { - "Windows 1254", - "Windows1254", - "", - "Windows1254", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-windows-1254.txt", - }, - { - "Windows 1255", - "Windows1255", - "", - "Windows1255", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-windows-1255.txt", - }, - { - "Windows 1256", - "Windows1256", - "", - "Windows1256", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-windows-1256.txt", - }, - { - "Windows 1257", - "Windows1257", - "", - "Windows1257", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-windows-1257.txt", - }, - { - "Windows 1258", - "Windows1258", - "", - "Windows1258", - encoding.ASCIISub, - "http://encoding.spec.whatwg.org/index-windows-1258.txt", - }, - { - "X-User-Defined", - "XUserDefined", - "It is defined at http://encoding.spec.whatwg.org/#x-user-defined", - "XUserDefined", - encoding.ASCIISub, - ascii + - "\uf780\uf781\uf782\uf783\uf784\uf785\uf786\uf787" + - "\uf788\uf789\uf78a\uf78b\uf78c\uf78d\uf78e\uf78f" + - "\uf790\uf791\uf792\uf793\uf794\uf795\uf796\uf797" + - "\uf798\uf799\uf79a\uf79b\uf79c\uf79d\uf79e\uf79f" + - "\uf7a0\uf7a1\uf7a2\uf7a3\uf7a4\uf7a5\uf7a6\uf7a7" + - "\uf7a8\uf7a9\uf7aa\uf7ab\uf7ac\uf7ad\uf7ae\uf7af" + - "\uf7b0\uf7b1\uf7b2\uf7b3\uf7b4\uf7b5\uf7b6\uf7b7" + - "\uf7b8\uf7b9\uf7ba\uf7bb\uf7bc\uf7bd\uf7be\uf7bf" + - "\uf7c0\uf7c1\uf7c2\uf7c3\uf7c4\uf7c5\uf7c6\uf7c7" + - "\uf7c8\uf7c9\uf7ca\uf7cb\uf7cc\uf7cd\uf7ce\uf7cf" + - "\uf7d0\uf7d1\uf7d2\uf7d3\uf7d4\uf7d5\uf7d6\uf7d7" + - "\uf7d8\uf7d9\uf7da\uf7db\uf7dc\uf7dd\uf7de\uf7df" + - "\uf7e0\uf7e1\uf7e2\uf7e3\uf7e4\uf7e5\uf7e6\uf7e7" + - "\uf7e8\uf7e9\uf7ea\uf7eb\uf7ec\uf7ed\uf7ee\uf7ef" + - "\uf7f0\uf7f1\uf7f2\uf7f3\uf7f4\uf7f5\uf7f6\uf7f7" + - "\uf7f8\uf7f9\uf7fa\uf7fb\uf7fc\uf7fd\uf7fe\uf7ff", - }, -} - -func getWHATWG(url string) string { - res, err := http.Get(url) - if err != nil { - log.Fatalf("%q: Get: %v", url, err) - } - defer res.Body.Close() - - mapping := make([]rune, 128) - for i := range mapping { - mapping[i] = '\ufffd' - } - - scanner := bufio.NewScanner(res.Body) - for scanner.Scan() { - s := strings.TrimSpace(scanner.Text()) - if s == "" || s[0] == '#' { - continue - } - x, y := 0, 0 - if _, err := fmt.Sscanf(s, "%d\t0x%x", &x, &y); err != nil { - log.Fatalf("could not parse %q", s) - } - if x < 0 || 128 <= x { - log.Fatalf("code %d is out of range", x) - } - if 0x80 <= y && y < 0xa0 { - // We diverge from the WHATWG spec by mapping control characters - // in the range [0x80, 0xa0) to U+FFFD. - continue - } - mapping[x] = rune(y) - } - return ascii + string(mapping) -} - -func getUCM(url string) string { - res, err := http.Get(url) - if err != nil { - log.Fatalf("%q: Get: %v", url, err) - } - defer res.Body.Close() - - mapping := make([]rune, 256) - for i := range mapping { - mapping[i] = '\ufffd' - } - - charsFound := 0 - scanner := bufio.NewScanner(res.Body) - for scanner.Scan() { - s := strings.TrimSpace(scanner.Text()) - if s == "" || s[0] == '#' { - continue - } - var c byte - var r rune - if _, err := fmt.Sscanf(s, ` \x%x |0`, &r, &c); err != nil { - continue - } - mapping[c] = r - charsFound++ - } - - if charsFound < 200 { - log.Fatalf("%q: only %d characters found (wrong page format?)", url, charsFound) - } - - return string(mapping) -} - -func main() { - mibs := map[string]bool{} - all := []string{} - - w := gen.NewCodeWriter() - defer w.WriteGoFile("tables.go", "charmap") - - printf := func(s string, a ...interface{}) { fmt.Fprintf(w, s, a...) } - - printf("import (\n") - printf("\t\"golang.org/x/text/encoding\"\n") - printf("\t\"golang.org/x/text/encoding/internal/identifier\"\n") - printf(")\n\n") - for _, e := range encodings { - varNames := strings.Split(e.varName, ",") - all = append(all, varNames...) - varName := varNames[0] - switch { - case strings.HasPrefix(e.mapping, "http://encoding.spec.whatwg.org/"): - e.mapping = getWHATWG(e.mapping) - case strings.HasPrefix(e.mapping, "http://source.icu-project.org/repos/icu/data/trunk/charset/data/ucm/"): - e.mapping = getUCM(e.mapping) - } - - asciiSuperset, low := strings.HasPrefix(e.mapping, ascii), 0x00 - if asciiSuperset { - low = 0x80 - } - lvn := 1 - if strings.HasPrefix(varName, "ISO") || strings.HasPrefix(varName, "KOI") { - lvn = 3 - } - lowerVarName := strings.ToLower(varName[:lvn]) + varName[lvn:] - printf("// %s is the %s encoding.\n", varName, e.name) - if e.comment != "" { - printf("//\n// %s\n", e.comment) - } - printf("var %s *Charmap = &%s\n\nvar %s = Charmap{\nname: %q,\n", - varName, lowerVarName, lowerVarName, e.name) - if mibs[e.mib] { - log.Fatalf("MIB type %q declared multiple times.", e.mib) - } - printf("mib: identifier.%s,\n", e.mib) - printf("asciiSuperset: %t,\n", asciiSuperset) - printf("low: 0x%02x,\n", low) - printf("replacement: 0x%02x,\n", e.replacement) - - printf("decode: [256]utf8Enc{\n") - i, backMapping := 0, map[rune]byte{} - for _, c := range e.mapping { - if _, ok := backMapping[c]; !ok && c != utf8.RuneError { - backMapping[c] = byte(i) - } - var buf [8]byte - n := utf8.EncodeRune(buf[:], c) - if n > 3 { - panic(fmt.Sprintf("rune %q (%U) is too long", c, c)) - } - printf("{%d,[3]byte{0x%02x,0x%02x,0x%02x}},", n, buf[0], buf[1], buf[2]) - if i%2 == 1 { - printf("\n") - } - i++ - } - printf("},\n") - - printf("encode: [256]uint32{\n") - encode := make([]uint32, 0, 256) - for c, i := range backMapping { - encode = append(encode, uint32(i)<<24|uint32(c)) - } - sort.Sort(byRune(encode)) - for len(encode) < cap(encode) { - encode = append(encode, encode[len(encode)-1]) - } - for i, enc := range encode { - printf("0x%08x,", enc) - if i%8 == 7 { - printf("\n") - } - } - printf("},\n}\n") - - // Add an estimate of the size of a single Charmap{} struct value, which - // includes two 256 elem arrays of 4 bytes and some extra fields, which - // align to 3 uint64s on 64-bit architectures. - w.Size += 2*4*256 + 3*8 - } - // TODO: add proper line breaking. - printf("var listAll = []encoding.Encoding{\n%s,\n}\n\n", strings.Join(all, ",\n")) -} - -type byRune []uint32 - -func (b byRune) Len() int { return len(b) } -func (b byRune) Less(i, j int) bool { return b[i]&0xffffff < b[j]&0xffffff } -func (b byRune) Swap(i, j int) { b[i], b[j] = b[j], b[i] } diff --git a/vendor/golang.org/x/text/encoding/htmlindex/gen.go b/vendor/golang.org/x/text/encoding/htmlindex/gen.go deleted file mode 100644 index ac6b4a77fd7623a34f4ceb7ea0e0c97dc29ee557..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/encoding/htmlindex/gen.go +++ /dev/null @@ -1,173 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -import ( - "bytes" - "encoding/json" - "fmt" - "log" - "strings" - - "golang.org/x/text/internal/gen" -) - -type group struct { - Encodings []struct { - Labels []string - Name string - } -} - -func main() { - gen.Init() - - r := gen.Open("https://encoding.spec.whatwg.org", "whatwg", "encodings.json") - var groups []group - if err := json.NewDecoder(r).Decode(&groups); err != nil { - log.Fatalf("Error reading encodings.json: %v", err) - } - - w := &bytes.Buffer{} - fmt.Fprintln(w, "type htmlEncoding byte") - fmt.Fprintln(w, "const (") - for i, g := range groups { - for _, e := range g.Encodings { - key := strings.ToLower(e.Name) - name := consts[key] - if name == "" { - log.Fatalf("No const defined for %s.", key) - } - if i == 0 { - fmt.Fprintf(w, "%s htmlEncoding = iota\n", name) - } else { - fmt.Fprintf(w, "%s\n", name) - } - } - } - fmt.Fprintln(w, "numEncodings") - fmt.Fprint(w, ")\n\n") - - fmt.Fprintln(w, "var canonical = [numEncodings]string{") - for _, g := range groups { - for _, e := range g.Encodings { - fmt.Fprintf(w, "%q,\n", strings.ToLower(e.Name)) - } - } - fmt.Fprint(w, "}\n\n") - - fmt.Fprintln(w, "var nameMap = map[string]htmlEncoding{") - for _, g := range groups { - for _, e := range g.Encodings { - for _, l := range e.Labels { - key := strings.ToLower(e.Name) - name := consts[key] - fmt.Fprintf(w, "%q: %s,\n", l, name) - } - } - } - fmt.Fprint(w, "}\n\n") - - var tags []string - fmt.Fprintln(w, "var localeMap = []htmlEncoding{") - for _, loc := range locales { - tags = append(tags, loc.tag) - fmt.Fprintf(w, "%s, // %s \n", consts[loc.name], loc.tag) - } - fmt.Fprint(w, "}\n\n") - - fmt.Fprintf(w, "const locales = %q\n", strings.Join(tags, " ")) - - gen.WriteGoFile("tables.go", "htmlindex", w.Bytes()) -} - -// consts maps canonical encoding name to internal constant. -var consts = map[string]string{ - "utf-8": "utf8", - "ibm866": "ibm866", - "iso-8859-2": "iso8859_2", - "iso-8859-3": "iso8859_3", - "iso-8859-4": "iso8859_4", - "iso-8859-5": "iso8859_5", - "iso-8859-6": "iso8859_6", - "iso-8859-7": "iso8859_7", - "iso-8859-8": "iso8859_8", - "iso-8859-8-i": "iso8859_8I", - "iso-8859-10": "iso8859_10", - "iso-8859-13": "iso8859_13", - "iso-8859-14": "iso8859_14", - "iso-8859-15": "iso8859_15", - "iso-8859-16": "iso8859_16", - "koi8-r": "koi8r", - "koi8-u": "koi8u", - "macintosh": "macintosh", - "windows-874": "windows874", - "windows-1250": "windows1250", - "windows-1251": "windows1251", - "windows-1252": "windows1252", - "windows-1253": "windows1253", - "windows-1254": "windows1254", - "windows-1255": "windows1255", - "windows-1256": "windows1256", - "windows-1257": "windows1257", - "windows-1258": "windows1258", - "x-mac-cyrillic": "macintoshCyrillic", - "gbk": "gbk", - "gb18030": "gb18030", - // "hz-gb-2312": "hzgb2312", // Was removed from WhatWG - "big5": "big5", - "euc-jp": "eucjp", - "iso-2022-jp": "iso2022jp", - "shift_jis": "shiftJIS", - "euc-kr": "euckr", - "replacement": "replacement", - "utf-16be": "utf16be", - "utf-16le": "utf16le", - "x-user-defined": "xUserDefined", -} - -// locales is taken from -// https://html.spec.whatwg.org/multipage/syntax.html#encoding-sniffing-algorithm. -var locales = []struct{ tag, name string }{ - // The default value. Explicitly state latin to benefit from the exact - // script option, while still making 1252 the default encoding for languages - // written in Latin script. - {"und_Latn", "windows-1252"}, - {"ar", "windows-1256"}, - {"ba", "windows-1251"}, - {"be", "windows-1251"}, - {"bg", "windows-1251"}, - {"cs", "windows-1250"}, - {"el", "iso-8859-7"}, - {"et", "windows-1257"}, - {"fa", "windows-1256"}, - {"he", "windows-1255"}, - {"hr", "windows-1250"}, - {"hu", "iso-8859-2"}, - {"ja", "shift_jis"}, - {"kk", "windows-1251"}, - {"ko", "euc-kr"}, - {"ku", "windows-1254"}, - {"ky", "windows-1251"}, - {"lt", "windows-1257"}, - {"lv", "windows-1257"}, - {"mk", "windows-1251"}, - {"pl", "iso-8859-2"}, - {"ru", "windows-1251"}, - {"sah", "windows-1251"}, - {"sk", "windows-1250"}, - {"sl", "iso-8859-2"}, - {"sr", "windows-1251"}, - {"tg", "windows-1251"}, - {"th", "windows-874"}, - {"tr", "windows-1254"}, - {"tt", "windows-1251"}, - {"uk", "windows-1251"}, - {"vi", "windows-1258"}, - {"zh-hans", "gb18030"}, - {"zh-hant", "big5"}, -} diff --git a/vendor/golang.org/x/text/encoding/internal/identifier/gen.go b/vendor/golang.org/x/text/encoding/internal/identifier/gen.go deleted file mode 100644 index 0c8eba7e526c2abf2ee32087a93d4981b7bd1030..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/encoding/internal/identifier/gen.go +++ /dev/null @@ -1,137 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -import ( - "bytes" - "encoding/xml" - "fmt" - "io" - "log" - "strings" - - "golang.org/x/text/internal/gen" -) - -type registry struct { - XMLName xml.Name `xml:"registry"` - Updated string `xml:"updated"` - Registry []struct { - ID string `xml:"id,attr"` - Record []struct { - Name string `xml:"name"` - Xref []struct { - Type string `xml:"type,attr"` - Data string `xml:"data,attr"` - } `xml:"xref"` - Desc struct { - Data string `xml:",innerxml"` - // Any []struct { - // Data string `xml:",chardata"` - // } `xml:",any"` - // Data string `xml:",chardata"` - } `xml:"description,"` - MIB string `xml:"value"` - Alias []string `xml:"alias"` - MIME string `xml:"preferred_alias"` - } `xml:"record"` - } `xml:"registry"` -} - -func main() { - r := gen.OpenIANAFile("assignments/character-sets/character-sets.xml") - reg := ®istry{} - if err := xml.NewDecoder(r).Decode(®); err != nil && err != io.EOF { - log.Fatalf("Error decoding charset registry: %v", err) - } - if len(reg.Registry) == 0 || reg.Registry[0].ID != "character-sets-1" { - log.Fatalf("Unexpected ID %s", reg.Registry[0].ID) - } - - w := &bytes.Buffer{} - fmt.Fprintf(w, "const (\n") - for _, rec := range reg.Registry[0].Record { - constName := "" - for _, a := range rec.Alias { - if strings.HasPrefix(a, "cs") && strings.IndexByte(a, '-') == -1 { - // Some of the constant definitions have comments in them. Strip those. - constName = strings.Title(strings.SplitN(a[2:], "\n", 2)[0]) - } - } - if constName == "" { - switch rec.MIB { - case "2085": - constName = "HZGB2312" // Not listed as alias for some reason. - default: - log.Fatalf("No cs alias defined for %s.", rec.MIB) - } - } - if rec.MIME != "" { - rec.MIME = fmt.Sprintf(" (MIME: %s)", rec.MIME) - } - fmt.Fprintf(w, "// %s is the MIB identifier with IANA name %s%s.\n//\n", constName, rec.Name, rec.MIME) - if len(rec.Desc.Data) > 0 { - fmt.Fprint(w, "// ") - d := xml.NewDecoder(strings.NewReader(rec.Desc.Data)) - inElem := true - attr := "" - for { - t, err := d.Token() - if err != nil { - if err != io.EOF { - log.Fatal(err) - } - break - } - switch x := t.(type) { - case xml.CharData: - attr = "" // Don't need attribute info. - a := bytes.Split([]byte(x), []byte("\n")) - for i, b := range a { - if b = bytes.TrimSpace(b); len(b) != 0 { - if !inElem && i > 0 { - fmt.Fprint(w, "\n// ") - } - inElem = false - fmt.Fprintf(w, "%s ", string(b)) - } - } - case xml.StartElement: - if x.Name.Local == "xref" { - inElem = true - use := false - for _, a := range x.Attr { - if a.Name.Local == "type" { - use = use || a.Value != "person" - } - if a.Name.Local == "data" && use { - attr = a.Value + " " - } - } - } - case xml.EndElement: - inElem = false - fmt.Fprint(w, attr) - } - } - fmt.Fprint(w, "\n") - } - for _, x := range rec.Xref { - switch x.Type { - case "rfc": - fmt.Fprintf(w, "// Reference: %s\n", strings.ToUpper(x.Data)) - case "uri": - fmt.Fprintf(w, "// Reference: %s\n", x.Data) - } - } - fmt.Fprintf(w, "%s MIB = %s\n", constName, rec.MIB) - fmt.Fprintln(w) - } - fmt.Fprintln(w, ")") - - gen.WriteGoFile("mib.go", "identifier", w.Bytes()) -} diff --git a/vendor/golang.org/x/text/encoding/japanese/maketables.go b/vendor/golang.org/x/text/encoding/japanese/maketables.go deleted file mode 100644 index d6c10deb073c1d042d60177576324ee22ec3be50..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/encoding/japanese/maketables.go +++ /dev/null @@ -1,161 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -// This program generates tables.go: -// go run maketables.go | gofmt > tables.go - -// TODO: Emoji extensions? -// http://www.unicode.org/faq/emoji_dingbats.html -// http://www.unicode.org/Public/UNIDATA/EmojiSources.txt - -import ( - "bufio" - "fmt" - "log" - "net/http" - "sort" - "strings" -) - -type entry struct { - jisCode, table int -} - -func main() { - fmt.Printf("// generated by go run maketables.go; DO NOT EDIT\n\n") - fmt.Printf("// Package japanese provides Japanese encodings such as EUC-JP and Shift JIS.\n") - fmt.Printf(`package japanese // import "golang.org/x/text/encoding/japanese"` + "\n\n") - - reverse := [65536]entry{} - for i := range reverse { - reverse[i].table = -1 - } - - tables := []struct { - url string - name string - }{ - {"http://encoding.spec.whatwg.org/index-jis0208.txt", "0208"}, - {"http://encoding.spec.whatwg.org/index-jis0212.txt", "0212"}, - } - for i, table := range tables { - res, err := http.Get(table.url) - if err != nil { - log.Fatalf("%q: Get: %v", table.url, err) - } - defer res.Body.Close() - - mapping := [65536]uint16{} - - scanner := bufio.NewScanner(res.Body) - for scanner.Scan() { - s := strings.TrimSpace(scanner.Text()) - if s == "" || s[0] == '#' { - continue - } - x, y := 0, uint16(0) - if _, err := fmt.Sscanf(s, "%d 0x%x", &x, &y); err != nil { - log.Fatalf("%q: could not parse %q", table.url, s) - } - if x < 0 || 120*94 <= x { - log.Fatalf("%q: JIS code %d is out of range", table.url, x) - } - mapping[x] = y - if reverse[y].table == -1 { - reverse[y] = entry{jisCode: x, table: i} - } - } - if err := scanner.Err(); err != nil { - log.Fatalf("%q: scanner error: %v", table.url, err) - } - - fmt.Printf("// jis%sDecode is the decoding table from JIS %s code to Unicode.\n// It is defined at %s\n", - table.name, table.name, table.url) - fmt.Printf("var jis%sDecode = [...]uint16{\n", table.name) - for i, m := range mapping { - if m != 0 { - fmt.Printf("\t%d: 0x%04X,\n", i, m) - } - } - fmt.Printf("}\n\n") - } - - // Any run of at least separation continuous zero entries in the reverse map will - // be a separate encode table. - const separation = 1024 - - intervals := []interval(nil) - low, high := -1, -1 - for i, v := range reverse { - if v.table == -1 { - continue - } - if low < 0 { - low = i - } else if i-high >= separation { - if high >= 0 { - intervals = append(intervals, interval{low, high}) - } - low = i - } - high = i + 1 - } - if high >= 0 { - intervals = append(intervals, interval{low, high}) - } - sort.Sort(byDecreasingLength(intervals)) - - fmt.Printf("const (\n") - fmt.Printf("\tjis0208 = 1\n") - fmt.Printf("\tjis0212 = 2\n") - fmt.Printf("\tcodeMask = 0x7f\n") - fmt.Printf("\tcodeShift = 7\n") - fmt.Printf("\ttableShift = 14\n") - fmt.Printf(")\n\n") - - fmt.Printf("const numEncodeTables = %d\n\n", len(intervals)) - fmt.Printf("// encodeX are the encoding tables from Unicode to JIS code,\n") - fmt.Printf("// sorted by decreasing length.\n") - for i, v := range intervals { - fmt.Printf("// encode%d: %5d entries for runes in [%5d, %5d).\n", i, v.len(), v.low, v.high) - } - fmt.Printf("//\n") - fmt.Printf("// The high two bits of the value record whether the JIS code comes from the\n") - fmt.Printf("// JIS0208 table (high bits == 1) or the JIS0212 table (high bits == 2).\n") - fmt.Printf("// The low 14 bits are two 7-bit unsigned integers j1 and j2 that form the\n") - fmt.Printf("// JIS code (94*j1 + j2) within that table.\n") - fmt.Printf("\n") - - for i, v := range intervals { - fmt.Printf("const encode%dLow, encode%dHigh = %d, %d\n\n", i, i, v.low, v.high) - fmt.Printf("var encode%d = [...]uint16{\n", i) - for j := v.low; j < v.high; j++ { - x := reverse[j] - if x.table == -1 { - continue - } - fmt.Printf("\t%d - %d: jis%s<<14 | 0x%02X<<7 | 0x%02X,\n", - j, v.low, tables[x.table].name, x.jisCode/94, x.jisCode%94) - } - fmt.Printf("}\n\n") - } -} - -// interval is a half-open interval [low, high). -type interval struct { - low, high int -} - -func (i interval) len() int { return i.high - i.low } - -// byDecreasingLength sorts intervals by decreasing length. -type byDecreasingLength []interval - -func (b byDecreasingLength) Len() int { return len(b) } -func (b byDecreasingLength) Less(i, j int) bool { return b[i].len() > b[j].len() } -func (b byDecreasingLength) Swap(i, j int) { b[i], b[j] = b[j], b[i] } diff --git a/vendor/golang.org/x/text/encoding/korean/maketables.go b/vendor/golang.org/x/text/encoding/korean/maketables.go deleted file mode 100644 index c84034fb67d825bc36d9ab56d884e2791bb46ecb..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/encoding/korean/maketables.go +++ /dev/null @@ -1,143 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -// This program generates tables.go: -// go run maketables.go | gofmt > tables.go - -import ( - "bufio" - "fmt" - "log" - "net/http" - "sort" - "strings" -) - -func main() { - fmt.Printf("// generated by go run maketables.go; DO NOT EDIT\n\n") - fmt.Printf("// Package korean provides Korean encodings such as EUC-KR.\n") - fmt.Printf(`package korean // import "golang.org/x/text/encoding/korean"` + "\n\n") - - res, err := http.Get("http://encoding.spec.whatwg.org/index-euc-kr.txt") - if err != nil { - log.Fatalf("Get: %v", err) - } - defer res.Body.Close() - - mapping := [65536]uint16{} - reverse := [65536]uint16{} - - scanner := bufio.NewScanner(res.Body) - for scanner.Scan() { - s := strings.TrimSpace(scanner.Text()) - if s == "" || s[0] == '#' { - continue - } - x, y := uint16(0), uint16(0) - if _, err := fmt.Sscanf(s, "%d 0x%x", &x, &y); err != nil { - log.Fatalf("could not parse %q", s) - } - if x < 0 || 178*(0xc7-0x81)+(0xfe-0xc7)*94+(0xff-0xa1) <= x { - log.Fatalf("EUC-KR code %d is out of range", x) - } - mapping[x] = y - if reverse[y] == 0 { - c0, c1 := uint16(0), uint16(0) - if x < 178*(0xc7-0x81) { - c0 = uint16(x/178) + 0x81 - c1 = uint16(x % 178) - switch { - case c1 < 1*26: - c1 += 0x41 - case c1 < 2*26: - c1 += 0x47 - default: - c1 += 0x4d - } - } else { - x -= 178 * (0xc7 - 0x81) - c0 = uint16(x/94) + 0xc7 - c1 = uint16(x%94) + 0xa1 - } - reverse[y] = c0<<8 | c1 - } - } - if err := scanner.Err(); err != nil { - log.Fatalf("scanner error: %v", err) - } - - fmt.Printf("// decode is the decoding table from EUC-KR code to Unicode.\n") - fmt.Printf("// It is defined at http://encoding.spec.whatwg.org/index-euc-kr.txt\n") - fmt.Printf("var decode = [...]uint16{\n") - for i, v := range mapping { - if v != 0 { - fmt.Printf("\t%d: 0x%04X,\n", i, v) - } - } - fmt.Printf("}\n\n") - - // Any run of at least separation continuous zero entries in the reverse map will - // be a separate encode table. - const separation = 1024 - - intervals := []interval(nil) - low, high := -1, -1 - for i, v := range reverse { - if v == 0 { - continue - } - if low < 0 { - low = i - } else if i-high >= separation { - if high >= 0 { - intervals = append(intervals, interval{low, high}) - } - low = i - } - high = i + 1 - } - if high >= 0 { - intervals = append(intervals, interval{low, high}) - } - sort.Sort(byDecreasingLength(intervals)) - - fmt.Printf("const numEncodeTables = %d\n\n", len(intervals)) - fmt.Printf("// encodeX are the encoding tables from Unicode to EUC-KR code,\n") - fmt.Printf("// sorted by decreasing length.\n") - for i, v := range intervals { - fmt.Printf("// encode%d: %5d entries for runes in [%5d, %5d).\n", i, v.len(), v.low, v.high) - } - fmt.Printf("\n") - - for i, v := range intervals { - fmt.Printf("const encode%dLow, encode%dHigh = %d, %d\n\n", i, i, v.low, v.high) - fmt.Printf("var encode%d = [...]uint16{\n", i) - for j := v.low; j < v.high; j++ { - x := reverse[j] - if x == 0 { - continue - } - fmt.Printf("\t%d-%d: 0x%04X,\n", j, v.low, x) - } - fmt.Printf("}\n\n") - } -} - -// interval is a half-open interval [low, high). -type interval struct { - low, high int -} - -func (i interval) len() int { return i.high - i.low } - -// byDecreasingLength sorts intervals by decreasing length. -type byDecreasingLength []interval - -func (b byDecreasingLength) Len() int { return len(b) } -func (b byDecreasingLength) Less(i, j int) bool { return b[i].len() > b[j].len() } -func (b byDecreasingLength) Swap(i, j int) { b[i], b[j] = b[j], b[i] } diff --git a/vendor/golang.org/x/text/encoding/simplifiedchinese/maketables.go b/vendor/golang.org/x/text/encoding/simplifiedchinese/maketables.go deleted file mode 100644 index 55016c7862048a53d01b818addb78fc8c62a4ebd..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/encoding/simplifiedchinese/maketables.go +++ /dev/null @@ -1,161 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -// This program generates tables.go: -// go run maketables.go | gofmt > tables.go - -import ( - "bufio" - "fmt" - "log" - "net/http" - "sort" - "strings" -) - -func main() { - fmt.Printf("// generated by go run maketables.go; DO NOT EDIT\n\n") - fmt.Printf("// Package simplifiedchinese provides Simplified Chinese encodings such as GBK.\n") - fmt.Printf(`package simplifiedchinese // import "golang.org/x/text/encoding/simplifiedchinese"` + "\n\n") - - printGB18030() - printGBK() -} - -func printGB18030() { - res, err := http.Get("http://encoding.spec.whatwg.org/index-gb18030.txt") - if err != nil { - log.Fatalf("Get: %v", err) - } - defer res.Body.Close() - - fmt.Printf("// gb18030 is the table from http://encoding.spec.whatwg.org/index-gb18030.txt\n") - fmt.Printf("var gb18030 = [...][2]uint16{\n") - scanner := bufio.NewScanner(res.Body) - for scanner.Scan() { - s := strings.TrimSpace(scanner.Text()) - if s == "" || s[0] == '#' { - continue - } - x, y := uint32(0), uint32(0) - if _, err := fmt.Sscanf(s, "%d 0x%x", &x, &y); err != nil { - log.Fatalf("could not parse %q", s) - } - if x < 0x10000 && y < 0x10000 { - fmt.Printf("\t{0x%04x, 0x%04x},\n", x, y) - } - } - fmt.Printf("}\n\n") -} - -func printGBK() { - res, err := http.Get("http://encoding.spec.whatwg.org/index-gbk.txt") - if err != nil { - log.Fatalf("Get: %v", err) - } - defer res.Body.Close() - - mapping := [65536]uint16{} - reverse := [65536]uint16{} - - scanner := bufio.NewScanner(res.Body) - for scanner.Scan() { - s := strings.TrimSpace(scanner.Text()) - if s == "" || s[0] == '#' { - continue - } - x, y := uint16(0), uint16(0) - if _, err := fmt.Sscanf(s, "%d 0x%x", &x, &y); err != nil { - log.Fatalf("could not parse %q", s) - } - if x < 0 || 126*190 <= x { - log.Fatalf("GBK code %d is out of range", x) - } - mapping[x] = y - if reverse[y] == 0 { - c0, c1 := x/190, x%190 - if c1 >= 0x3f { - c1++ - } - reverse[y] = (0x81+c0)<<8 | (0x40 + c1) - } - } - if err := scanner.Err(); err != nil { - log.Fatalf("scanner error: %v", err) - } - - fmt.Printf("// decode is the decoding table from GBK code to Unicode.\n") - fmt.Printf("// It is defined at http://encoding.spec.whatwg.org/index-gbk.txt\n") - fmt.Printf("var decode = [...]uint16{\n") - for i, v := range mapping { - if v != 0 { - fmt.Printf("\t%d: 0x%04X,\n", i, v) - } - } - fmt.Printf("}\n\n") - - // Any run of at least separation continuous zero entries in the reverse map will - // be a separate encode table. - const separation = 1024 - - intervals := []interval(nil) - low, high := -1, -1 - for i, v := range reverse { - if v == 0 { - continue - } - if low < 0 { - low = i - } else if i-high >= separation { - if high >= 0 { - intervals = append(intervals, interval{low, high}) - } - low = i - } - high = i + 1 - } - if high >= 0 { - intervals = append(intervals, interval{low, high}) - } - sort.Sort(byDecreasingLength(intervals)) - - fmt.Printf("const numEncodeTables = %d\n\n", len(intervals)) - fmt.Printf("// encodeX are the encoding tables from Unicode to GBK code,\n") - fmt.Printf("// sorted by decreasing length.\n") - for i, v := range intervals { - fmt.Printf("// encode%d: %5d entries for runes in [%5d, %5d).\n", i, v.len(), v.low, v.high) - } - fmt.Printf("\n") - - for i, v := range intervals { - fmt.Printf("const encode%dLow, encode%dHigh = %d, %d\n\n", i, i, v.low, v.high) - fmt.Printf("var encode%d = [...]uint16{\n", i) - for j := v.low; j < v.high; j++ { - x := reverse[j] - if x == 0 { - continue - } - fmt.Printf("\t%d-%d: 0x%04X,\n", j, v.low, x) - } - fmt.Printf("}\n\n") - } -} - -// interval is a half-open interval [low, high). -type interval struct { - low, high int -} - -func (i interval) len() int { return i.high - i.low } - -// byDecreasingLength sorts intervals by decreasing length. -type byDecreasingLength []interval - -func (b byDecreasingLength) Len() int { return len(b) } -func (b byDecreasingLength) Less(i, j int) bool { return b[i].len() > b[j].len() } -func (b byDecreasingLength) Swap(i, j int) { b[i], b[j] = b[j], b[i] } diff --git a/vendor/golang.org/x/text/encoding/traditionalchinese/maketables.go b/vendor/golang.org/x/text/encoding/traditionalchinese/maketables.go deleted file mode 100644 index cf7fdb31a521bf63ba1cf3301c36bd08c00b0f21..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/encoding/traditionalchinese/maketables.go +++ /dev/null @@ -1,140 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -// This program generates tables.go: -// go run maketables.go | gofmt > tables.go - -import ( - "bufio" - "fmt" - "log" - "net/http" - "sort" - "strings" -) - -func main() { - fmt.Printf("// generated by go run maketables.go; DO NOT EDIT\n\n") - fmt.Printf("// Package traditionalchinese provides Traditional Chinese encodings such as Big5.\n") - fmt.Printf(`package traditionalchinese // import "golang.org/x/text/encoding/traditionalchinese"` + "\n\n") - - res, err := http.Get("http://encoding.spec.whatwg.org/index-big5.txt") - if err != nil { - log.Fatalf("Get: %v", err) - } - defer res.Body.Close() - - mapping := [65536]uint32{} - reverse := [65536 * 4]uint16{} - - scanner := bufio.NewScanner(res.Body) - for scanner.Scan() { - s := strings.TrimSpace(scanner.Text()) - if s == "" || s[0] == '#' { - continue - } - x, y := uint16(0), uint32(0) - if _, err := fmt.Sscanf(s, "%d 0x%x", &x, &y); err != nil { - log.Fatalf("could not parse %q", s) - } - if x < 0 || 126*157 <= x { - log.Fatalf("Big5 code %d is out of range", x) - } - mapping[x] = y - - // The WHATWG spec http://encoding.spec.whatwg.org/#indexes says that - // "The index pointer for code point in index is the first pointer - // corresponding to code point in index", which would normally mean - // that the code below should be guarded by "if reverse[y] == 0", but - // last instead of first seems to match the behavior of - // "iconv -f UTF-8 -t BIG5". For example, U+8005 者 occurs twice in - // http://encoding.spec.whatwg.org/index-big5.txt, as index 2148 - // (encoded as "\x8e\xcd") and index 6543 (encoded as "\xaa\xcc") - // and "echo 者 | iconv -f UTF-8 -t BIG5 | xxd" gives "\xaa\xcc". - c0, c1 := x/157, x%157 - if c1 < 0x3f { - c1 += 0x40 - } else { - c1 += 0x62 - } - reverse[y] = (0x81+c0)<<8 | c1 - } - if err := scanner.Err(); err != nil { - log.Fatalf("scanner error: %v", err) - } - - fmt.Printf("// decode is the decoding table from Big5 code to Unicode.\n") - fmt.Printf("// It is defined at http://encoding.spec.whatwg.org/index-big5.txt\n") - fmt.Printf("var decode = [...]uint32{\n") - for i, v := range mapping { - if v != 0 { - fmt.Printf("\t%d: 0x%08X,\n", i, v) - } - } - fmt.Printf("}\n\n") - - // Any run of at least separation continuous zero entries in the reverse map will - // be a separate encode table. - const separation = 1024 - - intervals := []interval(nil) - low, high := -1, -1 - for i, v := range reverse { - if v == 0 { - continue - } - if low < 0 { - low = i - } else if i-high >= separation { - if high >= 0 { - intervals = append(intervals, interval{low, high}) - } - low = i - } - high = i + 1 - } - if high >= 0 { - intervals = append(intervals, interval{low, high}) - } - sort.Sort(byDecreasingLength(intervals)) - - fmt.Printf("const numEncodeTables = %d\n\n", len(intervals)) - fmt.Printf("// encodeX are the encoding tables from Unicode to Big5 code,\n") - fmt.Printf("// sorted by decreasing length.\n") - for i, v := range intervals { - fmt.Printf("// encode%d: %5d entries for runes in [%6d, %6d).\n", i, v.len(), v.low, v.high) - } - fmt.Printf("\n") - - for i, v := range intervals { - fmt.Printf("const encode%dLow, encode%dHigh = %d, %d\n\n", i, i, v.low, v.high) - fmt.Printf("var encode%d = [...]uint16{\n", i) - for j := v.low; j < v.high; j++ { - x := reverse[j] - if x == 0 { - continue - } - fmt.Printf("\t%d-%d: 0x%04X,\n", j, v.low, x) - } - fmt.Printf("}\n\n") - } -} - -// interval is a half-open interval [low, high). -type interval struct { - low, high int -} - -func (i interval) len() int { return i.high - i.low } - -// byDecreasingLength sorts intervals by decreasing length. -type byDecreasingLength []interval - -func (b byDecreasingLength) Len() int { return len(b) } -func (b byDecreasingLength) Less(i, j int) bool { return b[i].len() > b[j].len() } -func (b byDecreasingLength) Swap(i, j int) { b[i], b[j] = b[j], b[i] } diff --git a/vendor/golang.org/x/text/language/gen.go b/vendor/golang.org/x/text/language/gen.go deleted file mode 100644 index 302f1940aaf487f4d8a87913ceed8194716365cc..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/language/gen.go +++ /dev/null @@ -1,1712 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -// Language tag table generator. -// Data read from the web. - -package main - -import ( - "bufio" - "flag" - "fmt" - "io" - "io/ioutil" - "log" - "math" - "reflect" - "regexp" - "sort" - "strconv" - "strings" - - "golang.org/x/text/internal/gen" - "golang.org/x/text/internal/tag" - "golang.org/x/text/unicode/cldr" -) - -var ( - test = flag.Bool("test", - false, - "test existing tables; can be used to compare web data with package data.") - outputFile = flag.String("output", - "tables.go", - "output file for generated tables") -) - -var comment = []string{ - ` -lang holds an alphabetically sorted list of ISO-639 language identifiers. -All entries are 4 bytes. The index of the identifier (divided by 4) is the language tag. -For 2-byte language identifiers, the two successive bytes have the following meaning: - - if the first letter of the 2- and 3-letter ISO codes are the same: - the second and third letter of the 3-letter ISO code. - - otherwise: a 0 and a by 2 bits right-shifted index into altLangISO3. -For 3-byte language identifiers the 4th byte is 0.`, - ` -langNoIndex is a bit vector of all 3-letter language codes that are not used as an index -in lookup tables. The language ids for these language codes are derived directly -from the letters and are not consecutive.`, - ` -altLangISO3 holds an alphabetically sorted list of 3-letter language code alternatives -to 2-letter language codes that cannot be derived using the method described above. -Each 3-letter code is followed by its 1-byte langID.`, - ` -altLangIndex is used to convert indexes in altLangISO3 to langIDs.`, - ` -langAliasMap maps langIDs to their suggested replacements.`, - ` -script is an alphabetically sorted list of ISO 15924 codes. The index -of the script in the string, divided by 4, is the internal scriptID.`, - ` -isoRegionOffset needs to be added to the index of regionISO to obtain the regionID -for 2-letter ISO codes. (The first isoRegionOffset regionIDs are reserved for -the UN.M49 codes used for groups.)`, - ` -regionISO holds a list of alphabetically sorted 2-letter ISO region codes. -Each 2-letter codes is followed by two bytes with the following meaning: - - [A-Z}{2}: the first letter of the 2-letter code plus these two - letters form the 3-letter ISO code. - - 0, n: index into altRegionISO3.`, - ` -regionTypes defines the status of a region for various standards.`, - ` -m49 maps regionIDs to UN.M49 codes. The first isoRegionOffset entries are -codes indicating collections of regions.`, - ` -m49Index gives indexes into fromM49 based on the three most significant bits -of a 10-bit UN.M49 code. To search an UN.M49 code in fromM49, search in - fromM49[m49Index[msb39(code)]:m49Index[msb3(code)+1]] -for an entry where the first 7 bits match the 7 lsb of the UN.M49 code. -The region code is stored in the 9 lsb of the indexed value.`, - ` -fromM49 contains entries to map UN.M49 codes to regions. See m49Index for details.`, - ` -altRegionISO3 holds a list of 3-letter region codes that cannot be -mapped to 2-letter codes using the default algorithm. This is a short list.`, - ` -altRegionIDs holds a list of regionIDs the positions of which match those -of the 3-letter ISO codes in altRegionISO3.`, - ` -variantNumSpecialized is the number of specialized variants in variants.`, - ` -suppressScript is an index from langID to the dominant script for that language, -if it exists. If a script is given, it should be suppressed from the language tag.`, - ` -likelyLang is a lookup table, indexed by langID, for the most likely -scripts and regions given incomplete information. If more entries exist for a -given language, region and script are the index and size respectively -of the list in likelyLangList.`, - ` -likelyLangList holds lists info associated with likelyLang.`, - ` -likelyRegion is a lookup table, indexed by regionID, for the most likely -languages and scripts given incomplete information. If more entries exist -for a given regionID, lang and script are the index and size respectively -of the list in likelyRegionList. -TODO: exclude containers and user-definable regions from the list.`, - ` -likelyRegionList holds lists info associated with likelyRegion.`, - ` -likelyScript is a lookup table, indexed by scriptID, for the most likely -languages and regions given a script.`, - ` -matchLang holds pairs of langIDs of base languages that are typically -mutually intelligible. Each pair is associated with a confidence and -whether the intelligibility goes one or both ways.`, - ` -matchScript holds pairs of scriptIDs where readers of one script -can typically also read the other. Each is associated with a confidence.`, - ` -nRegionGroups is the number of region groups.`, - ` -regionInclusion maps region identifiers to sets of regions in regionInclusionBits, -where each set holds all groupings that are directly connected in a region -containment graph.`, - ` -regionInclusionBits is an array of bit vectors where every vector represents -a set of region groupings. These sets are used to compute the distance -between two regions for the purpose of language matching.`, - ` -regionInclusionNext marks, for each entry in regionInclusionBits, the set of -all groups that are reachable from the groups set in the respective entry.`, -} - -// TODO: consider changing some of these structures to tries. This can reduce -// memory, but may increase the need for memory allocations. This could be -// mitigated if we can piggyback on language tags for common cases. - -func failOnError(e error) { - if e != nil { - log.Panic(e) - } -} - -type setType int - -const ( - Indexed setType = 1 + iota // all elements must be of same size - Linear -) - -type stringSet struct { - s []string - sorted, frozen bool - - // We often need to update values after the creation of an index is completed. - // We include a convenience map for keeping track of this. - update map[string]string - typ setType // used for checking. -} - -func (ss *stringSet) clone() stringSet { - c := *ss - c.s = append([]string(nil), c.s...) - return c -} - -func (ss *stringSet) setType(t setType) { - if ss.typ != t && ss.typ != 0 { - log.Panicf("type %d cannot be assigned as it was already %d", t, ss.typ) - } -} - -// parse parses a whitespace-separated string and initializes ss with its -// components. -func (ss *stringSet) parse(s string) { - scan := bufio.NewScanner(strings.NewReader(s)) - scan.Split(bufio.ScanWords) - for scan.Scan() { - ss.add(scan.Text()) - } -} - -func (ss *stringSet) assertChangeable() { - if ss.frozen { - log.Panic("attempt to modify a frozen stringSet") - } -} - -func (ss *stringSet) add(s string) { - ss.assertChangeable() - ss.s = append(ss.s, s) - ss.sorted = ss.frozen -} - -func (ss *stringSet) freeze() { - ss.compact() - ss.frozen = true -} - -func (ss *stringSet) compact() { - if ss.sorted { - return - } - a := ss.s - sort.Strings(a) - k := 0 - for i := 1; i < len(a); i++ { - if a[k] != a[i] { - a[k+1] = a[i] - k++ - } - } - ss.s = a[:k+1] - ss.sorted = ss.frozen -} - -type funcSorter struct { - fn func(a, b string) bool - sort.StringSlice -} - -func (s funcSorter) Less(i, j int) bool { - return s.fn(s.StringSlice[i], s.StringSlice[j]) -} - -func (ss *stringSet) sortFunc(f func(a, b string) bool) { - ss.compact() - sort.Sort(funcSorter{f, sort.StringSlice(ss.s)}) -} - -func (ss *stringSet) remove(s string) { - ss.assertChangeable() - if i, ok := ss.find(s); ok { - copy(ss.s[i:], ss.s[i+1:]) - ss.s = ss.s[:len(ss.s)-1] - } -} - -func (ss *stringSet) replace(ol, nu string) { - ss.s[ss.index(ol)] = nu - ss.sorted = ss.frozen -} - -func (ss *stringSet) index(s string) int { - ss.setType(Indexed) - i, ok := ss.find(s) - if !ok { - if i < len(ss.s) { - log.Panicf("find: item %q is not in list. Closest match is %q.", s, ss.s[i]) - } - log.Panicf("find: item %q is not in list", s) - - } - return i -} - -func (ss *stringSet) find(s string) (int, bool) { - ss.compact() - i := sort.SearchStrings(ss.s, s) - return i, i != len(ss.s) && ss.s[i] == s -} - -func (ss *stringSet) slice() []string { - ss.compact() - return ss.s -} - -func (ss *stringSet) updateLater(v, key string) { - if ss.update == nil { - ss.update = map[string]string{} - } - ss.update[v] = key -} - -// join joins the string and ensures that all entries are of the same length. -func (ss *stringSet) join() string { - ss.setType(Indexed) - n := len(ss.s[0]) - for _, s := range ss.s { - if len(s) != n { - log.Panicf("join: not all entries are of the same length: %q", s) - } - } - ss.s = append(ss.s, strings.Repeat("\xff", n)) - return strings.Join(ss.s, "") -} - -// ianaEntry holds information for an entry in the IANA Language Subtag Repository. -// All types use the same entry. -// See http://tools.ietf.org/html/bcp47#section-5.1 for a description of the various -// fields. -type ianaEntry struct { - typ string - description []string - scope string - added string - preferred string - deprecated string - suppressScript string - macro string - prefix []string -} - -type builder struct { - w *gen.CodeWriter - hw io.Writer // MultiWriter for w and w.Hash - data *cldr.CLDR - supp *cldr.SupplementalData - - // indices - locale stringSet // common locales - lang stringSet // canonical language ids (2 or 3 letter ISO codes) with data - langNoIndex stringSet // 3-letter ISO codes with no associated data - script stringSet // 4-letter ISO codes - region stringSet // 2-letter ISO or 3-digit UN M49 codes - variant stringSet // 4-8-alphanumeric variant code. - - // Region codes that are groups with their corresponding group IDs. - groups map[int]index - - // langInfo - registry map[string]*ianaEntry -} - -type index uint - -func newBuilder(w *gen.CodeWriter) *builder { - r := gen.OpenCLDRCoreZip() - defer r.Close() - d := &cldr.Decoder{} - data, err := d.DecodeZip(r) - failOnError(err) - b := builder{ - w: w, - hw: io.MultiWriter(w, w.Hash), - data: data, - supp: data.Supplemental(), - } - b.parseRegistry() - return &b -} - -func (b *builder) parseRegistry() { - r := gen.OpenIANAFile("assignments/language-subtag-registry") - defer r.Close() - b.registry = make(map[string]*ianaEntry) - - scan := bufio.NewScanner(r) - scan.Split(bufio.ScanWords) - var record *ianaEntry - for more := scan.Scan(); more; { - key := scan.Text() - more = scan.Scan() - value := scan.Text() - switch key { - case "Type:": - record = &ianaEntry{typ: value} - case "Subtag:", "Tag:": - if s := strings.SplitN(value, "..", 2); len(s) > 1 { - for a := s[0]; a <= s[1]; a = inc(a) { - b.addToRegistry(a, record) - } - } else { - b.addToRegistry(value, record) - } - case "Suppress-Script:": - record.suppressScript = value - case "Added:": - record.added = value - case "Deprecated:": - record.deprecated = value - case "Macrolanguage:": - record.macro = value - case "Preferred-Value:": - record.preferred = value - case "Prefix:": - record.prefix = append(record.prefix, value) - case "Scope:": - record.scope = value - case "Description:": - buf := []byte(value) - for more = scan.Scan(); more; more = scan.Scan() { - b := scan.Bytes() - if b[0] == '%' || b[len(b)-1] == ':' { - break - } - buf = append(buf, ' ') - buf = append(buf, b...) - } - record.description = append(record.description, string(buf)) - continue - default: - continue - } - more = scan.Scan() - } - if scan.Err() != nil { - log.Panic(scan.Err()) - } -} - -func (b *builder) addToRegistry(key string, entry *ianaEntry) { - if info, ok := b.registry[key]; ok { - if info.typ != "language" || entry.typ != "extlang" { - log.Fatalf("parseRegistry: tag %q already exists", key) - } - } else { - b.registry[key] = entry - } -} - -var commentIndex = make(map[string]string) - -func init() { - for _, s := range comment { - key := strings.TrimSpace(strings.SplitN(s, " ", 2)[0]) - commentIndex[key] = s - } -} - -func (b *builder) comment(name string) { - if s := commentIndex[name]; len(s) > 0 { - b.w.WriteComment(s) - } else { - fmt.Fprintln(b.w) - } -} - -func (b *builder) pf(f string, x ...interface{}) { - fmt.Fprintf(b.hw, f, x...) - fmt.Fprint(b.hw, "\n") -} - -func (b *builder) p(x ...interface{}) { - fmt.Fprintln(b.hw, x...) -} - -func (b *builder) addSize(s int) { - b.w.Size += s - b.pf("// Size: %d bytes", s) -} - -func (b *builder) writeConst(name string, x interface{}) { - b.comment(name) - b.w.WriteConst(name, x) -} - -// writeConsts computes f(v) for all v in values and writes the results -// as constants named _v to a single constant block. -func (b *builder) writeConsts(f func(string) int, values ...string) { - b.pf("const (") - for _, v := range values { - b.pf("\t_%s = %v", v, f(v)) - } - b.pf(")") -} - -// writeType writes the type of the given value, which must be a struct. -func (b *builder) writeType(value interface{}) { - b.comment(reflect.TypeOf(value).Name()) - b.w.WriteType(value) -} - -func (b *builder) writeSlice(name string, ss interface{}) { - b.writeSliceAddSize(name, 0, ss) -} - -func (b *builder) writeSliceAddSize(name string, extraSize int, ss interface{}) { - b.comment(name) - b.w.Size += extraSize - v := reflect.ValueOf(ss) - t := v.Type().Elem() - b.pf("// Size: %d bytes, %d elements", v.Len()*int(t.Size())+extraSize, v.Len()) - - fmt.Fprintf(b.w, "var %s = ", name) - b.w.WriteArray(ss) - b.p() -} - -type fromTo struct { - from, to uint16 -} - -func (b *builder) writeSortedMap(name string, ss *stringSet, index func(s string) uint16) { - ss.sortFunc(func(a, b string) bool { - return index(a) < index(b) - }) - m := []fromTo{} - for _, s := range ss.s { - m = append(m, fromTo{index(s), index(ss.update[s])}) - } - b.writeSlice(name, m) -} - -const base = 'z' - 'a' + 1 - -func strToInt(s string) uint { - v := uint(0) - for i := 0; i < len(s); i++ { - v *= base - v += uint(s[i] - 'a') - } - return v -} - -// converts the given integer to the original ASCII string passed to strToInt. -// len(s) must match the number of characters obtained. -func intToStr(v uint, s []byte) { - for i := len(s) - 1; i >= 0; i-- { - s[i] = byte(v%base) + 'a' - v /= base - } -} - -func (b *builder) writeBitVector(name string, ss []string) { - vec := make([]uint8, int(math.Ceil(math.Pow(base, float64(len(ss[0])))/8))) - for _, s := range ss { - v := strToInt(s) - vec[v/8] |= 1 << (v % 8) - } - b.writeSlice(name, vec) -} - -// TODO: convert this type into a list or two-stage trie. -func (b *builder) writeMapFunc(name string, m map[string]string, f func(string) uint16) { - b.comment(name) - v := reflect.ValueOf(m) - sz := v.Len() * (2 + int(v.Type().Key().Size())) - for _, k := range m { - sz += len(k) - } - b.addSize(sz) - keys := []string{} - b.pf(`var %s = map[string]uint16{`, name) - for k := range m { - keys = append(keys, k) - } - sort.Strings(keys) - for _, k := range keys { - b.pf("\t%q: %v,", k, f(m[k])) - } - b.p("}") -} - -func (b *builder) writeMap(name string, m interface{}) { - b.comment(name) - v := reflect.ValueOf(m) - sz := v.Len() * (2 + int(v.Type().Key().Size()) + int(v.Type().Elem().Size())) - b.addSize(sz) - f := strings.FieldsFunc(fmt.Sprintf("%#v", m), func(r rune) bool { - return strings.IndexRune("{}, ", r) != -1 - }) - sort.Strings(f[1:]) - b.pf(`var %s = %s{`, name, f[0]) - for _, kv := range f[1:] { - b.pf("\t%s,", kv) - } - b.p("}") -} - -func (b *builder) langIndex(s string) uint16 { - if s == "und" { - return 0 - } - if i, ok := b.lang.find(s); ok { - return uint16(i) - } - return uint16(strToInt(s)) + uint16(len(b.lang.s)) -} - -// inc advances the string to its lexicographical successor. -func inc(s string) string { - const maxTagLength = 4 - var buf [maxTagLength]byte - intToStr(strToInt(strings.ToLower(s))+1, buf[:len(s)]) - for i := 0; i < len(s); i++ { - if s[i] <= 'Z' { - buf[i] -= 'a' - 'A' - } - } - return string(buf[:len(s)]) -} - -func (b *builder) parseIndices() { - meta := b.supp.Metadata - - for k, v := range b.registry { - var ss *stringSet - switch v.typ { - case "language": - if len(k) == 2 || v.suppressScript != "" || v.scope == "special" { - b.lang.add(k) - continue - } else { - ss = &b.langNoIndex - } - case "region": - ss = &b.region - case "script": - ss = &b.script - case "variant": - ss = &b.variant - default: - continue - } - ss.add(k) - } - // Include any language for which there is data. - for _, lang := range b.data.Locales() { - if x := b.data.RawLDML(lang); false || - x.LocaleDisplayNames != nil || - x.Characters != nil || - x.Delimiters != nil || - x.Measurement != nil || - x.Dates != nil || - x.Numbers != nil || - x.Units != nil || - x.ListPatterns != nil || - x.Collations != nil || - x.Segmentations != nil || - x.Rbnf != nil || - x.Annotations != nil || - x.Metadata != nil { - - from := strings.Split(lang, "_") - if lang := from[0]; lang != "root" { - b.lang.add(lang) - } - } - } - // Include locales for plural rules, which uses a different structure. - for _, plurals := range b.data.Supplemental().Plurals { - for _, rules := range plurals.PluralRules { - for _, lang := range strings.Split(rules.Locales, " ") { - if lang = strings.Split(lang, "_")[0]; lang != "root" { - b.lang.add(lang) - } - } - } - } - // Include languages in likely subtags. - for _, m := range b.supp.LikelySubtags.LikelySubtag { - from := strings.Split(m.From, "_") - b.lang.add(from[0]) - } - // Include ISO-639 alpha-3 bibliographic entries. - for _, a := range meta.Alias.LanguageAlias { - if a.Reason == "bibliographic" { - b.langNoIndex.add(a.Type) - } - } - // Include regions in territoryAlias (not all are in the IANA registry!) - for _, reg := range b.supp.Metadata.Alias.TerritoryAlias { - if len(reg.Type) == 2 { - b.region.add(reg.Type) - } - } - - for _, s := range b.lang.s { - if len(s) == 3 { - b.langNoIndex.remove(s) - } - } - b.writeConst("numLanguages", len(b.lang.slice())+len(b.langNoIndex.slice())) - b.writeConst("numScripts", len(b.script.slice())) - b.writeConst("numRegions", len(b.region.slice())) - - // Add dummy codes at the start of each list to represent "unspecified". - b.lang.add("---") - b.script.add("----") - b.region.add("---") - - // common locales - b.locale.parse(meta.DefaultContent.Locales) -} - -// TODO: region inclusion data will probably not be use used in future matchers. - -func (b *builder) computeRegionGroups() { - b.groups = make(map[int]index) - - // Create group indices. - for i := 1; b.region.s[i][0] < 'A'; i++ { // Base M49 indices on regionID. - b.groups[i] = index(len(b.groups)) - } - for _, g := range b.supp.TerritoryContainment.Group { - // Skip UN and EURO zone as they are flattening the containment - // relationship. - if g.Type == "EZ" || g.Type == "UN" { - continue - } - group := b.region.index(g.Type) - if _, ok := b.groups[group]; !ok { - b.groups[group] = index(len(b.groups)) - } - } - if len(b.groups) > 64 { - log.Fatalf("only 64 groups supported, found %d", len(b.groups)) - } - b.writeConst("nRegionGroups", len(b.groups)) -} - -var langConsts = []string{ - "af", "am", "ar", "az", "bg", "bn", "ca", "cs", "da", "de", "el", "en", "es", - "et", "fa", "fi", "fil", "fr", "gu", "he", "hi", "hr", "hu", "hy", "id", "is", - "it", "ja", "ka", "kk", "km", "kn", "ko", "ky", "lo", "lt", "lv", "mk", "ml", - "mn", "mo", "mr", "ms", "mul", "my", "nb", "ne", "nl", "no", "pa", "pl", "pt", - "ro", "ru", "sh", "si", "sk", "sl", "sq", "sr", "sv", "sw", "ta", "te", "th", - "tl", "tn", "tr", "uk", "ur", "uz", "vi", "zh", "zu", - - // constants for grandfathered tags (if not already defined) - "jbo", "ami", "bnn", "hak", "tlh", "lb", "nv", "pwn", "tao", "tay", "tsu", - "nn", "sfb", "vgt", "sgg", "cmn", "nan", "hsn", -} - -// writeLanguage generates all tables needed for language canonicalization. -func (b *builder) writeLanguage() { - meta := b.supp.Metadata - - b.writeConst("nonCanonicalUnd", b.lang.index("und")) - b.writeConsts(func(s string) int { return int(b.langIndex(s)) }, langConsts...) - b.writeConst("langPrivateStart", b.langIndex("qaa")) - b.writeConst("langPrivateEnd", b.langIndex("qtz")) - - // Get language codes that need to be mapped (overlong 3-letter codes, - // deprecated 2-letter codes, legacy and grandfathered tags.) - langAliasMap := stringSet{} - aliasTypeMap := map[string]langAliasType{} - - // altLangISO3 get the alternative ISO3 names that need to be mapped. - altLangISO3 := stringSet{} - // Add dummy start to avoid the use of index 0. - altLangISO3.add("---") - altLangISO3.updateLater("---", "aa") - - lang := b.lang.clone() - for _, a := range meta.Alias.LanguageAlias { - if a.Replacement == "" { - a.Replacement = "und" - } - // TODO: support mapping to tags - repl := strings.SplitN(a.Replacement, "_", 2)[0] - if a.Reason == "overlong" { - if len(a.Replacement) == 2 && len(a.Type) == 3 { - lang.updateLater(a.Replacement, a.Type) - } - } else if len(a.Type) <= 3 { - switch a.Reason { - case "macrolanguage": - aliasTypeMap[a.Type] = langMacro - case "deprecated": - // handled elsewhere - continue - case "bibliographic", "legacy": - if a.Type == "no" { - continue - } - aliasTypeMap[a.Type] = langLegacy - default: - log.Fatalf("new %s alias: %s", a.Reason, a.Type) - } - langAliasMap.add(a.Type) - langAliasMap.updateLater(a.Type, repl) - } - } - // Manually add the mapping of "nb" (Norwegian) to its macro language. - // This can be removed if CLDR adopts this change. - langAliasMap.add("nb") - langAliasMap.updateLater("nb", "no") - aliasTypeMap["nb"] = langMacro - - for k, v := range b.registry { - // Also add deprecated values for 3-letter ISO codes, which CLDR omits. - if v.typ == "language" && v.deprecated != "" && v.preferred != "" { - langAliasMap.add(k) - langAliasMap.updateLater(k, v.preferred) - aliasTypeMap[k] = langDeprecated - } - } - // Fix CLDR mappings. - lang.updateLater("tl", "tgl") - lang.updateLater("sh", "hbs") - lang.updateLater("mo", "mol") - lang.updateLater("no", "nor") - lang.updateLater("tw", "twi") - lang.updateLater("nb", "nob") - lang.updateLater("ak", "aka") - lang.updateLater("bh", "bih") - - // Ensure that each 2-letter code is matched with a 3-letter code. - for _, v := range lang.s[1:] { - s, ok := lang.update[v] - if !ok { - if s, ok = lang.update[langAliasMap.update[v]]; !ok { - continue - } - lang.update[v] = s - } - if v[0] != s[0] { - altLangISO3.add(s) - altLangISO3.updateLater(s, v) - } - } - - // Complete canonicalized language tags. - lang.freeze() - for i, v := range lang.s { - // We can avoid these manual entries by using the IANA registry directly. - // Seems easier to update the list manually, as changes are rare. - // The panic in this loop will trigger if we miss an entry. - add := "" - if s, ok := lang.update[v]; ok { - if s[0] == v[0] { - add = s[1:] - } else { - add = string([]byte{0, byte(altLangISO3.index(s))}) - } - } else if len(v) == 3 { - add = "\x00" - } else { - log.Panicf("no data for long form of %q", v) - } - lang.s[i] += add - } - b.writeConst("lang", tag.Index(lang.join())) - - b.writeConst("langNoIndexOffset", len(b.lang.s)) - - // space of all valid 3-letter language identifiers. - b.writeBitVector("langNoIndex", b.langNoIndex.slice()) - - altLangIndex := []uint16{} - for i, s := range altLangISO3.slice() { - altLangISO3.s[i] += string([]byte{byte(len(altLangIndex))}) - if i > 0 { - idx := b.lang.index(altLangISO3.update[s]) - altLangIndex = append(altLangIndex, uint16(idx)) - } - } - b.writeConst("altLangISO3", tag.Index(altLangISO3.join())) - b.writeSlice("altLangIndex", altLangIndex) - - b.writeSortedMap("langAliasMap", &langAliasMap, b.langIndex) - types := make([]langAliasType, len(langAliasMap.s)) - for i, s := range langAliasMap.s { - types[i] = aliasTypeMap[s] - } - b.writeSlice("langAliasTypes", types) -} - -var scriptConsts = []string{ - "Latn", "Hani", "Hans", "Hant", "Qaaa", "Qaai", "Qabx", "Zinh", "Zyyy", - "Zzzz", -} - -func (b *builder) writeScript() { - b.writeConsts(b.script.index, scriptConsts...) - b.writeConst("script", tag.Index(b.script.join())) - - supp := make([]uint8, len(b.lang.slice())) - for i, v := range b.lang.slice()[1:] { - if sc := b.registry[v].suppressScript; sc != "" { - supp[i+1] = uint8(b.script.index(sc)) - } - } - b.writeSlice("suppressScript", supp) - - // There is only one deprecated script in CLDR. This value is hard-coded. - // We check here if the code must be updated. - for _, a := range b.supp.Metadata.Alias.ScriptAlias { - if a.Type != "Qaai" { - log.Panicf("unexpected deprecated stript %q", a.Type) - } - } -} - -func parseM49(s string) int16 { - if len(s) == 0 { - return 0 - } - v, err := strconv.ParseUint(s, 10, 10) - failOnError(err) - return int16(v) -} - -var regionConsts = []string{ - "001", "419", "BR", "CA", "ES", "GB", "MD", "PT", "UK", "US", - "ZZ", "XA", "XC", "XK", // Unofficial tag for Kosovo. -} - -func (b *builder) writeRegion() { - b.writeConsts(b.region.index, regionConsts...) - - isoOffset := b.region.index("AA") - m49map := make([]int16, len(b.region.slice())) - fromM49map := make(map[int16]int) - altRegionISO3 := "" - altRegionIDs := []uint16{} - - b.writeConst("isoRegionOffset", isoOffset) - - // 2-letter region lookup and mapping to numeric codes. - regionISO := b.region.clone() - regionISO.s = regionISO.s[isoOffset:] - regionISO.sorted = false - - regionTypes := make([]byte, len(b.region.s)) - - // Is the region valid BCP 47? - for s, e := range b.registry { - if len(s) == 2 && s == strings.ToUpper(s) { - i := b.region.index(s) - for _, d := range e.description { - if strings.Contains(d, "Private use") { - regionTypes[i] = iso3166UserAssigned - } - } - regionTypes[i] |= bcp47Region - } - } - - // Is the region a valid ccTLD? - r := gen.OpenIANAFile("domains/root/db") - defer r.Close() - - buf, err := ioutil.ReadAll(r) - failOnError(err) - re := regexp.MustCompile(`"/domains/root/db/([a-z]{2}).html"`) - for _, m := range re.FindAllSubmatch(buf, -1) { - i := b.region.index(strings.ToUpper(string(m[1]))) - regionTypes[i] |= ccTLD - } - - b.writeSlice("regionTypes", regionTypes) - - iso3Set := make(map[string]int) - update := func(iso2, iso3 string) { - i := regionISO.index(iso2) - if j, ok := iso3Set[iso3]; !ok && iso3[0] == iso2[0] { - regionISO.s[i] += iso3[1:] - iso3Set[iso3] = -1 - } else { - if ok && j >= 0 { - regionISO.s[i] += string([]byte{0, byte(j)}) - } else { - iso3Set[iso3] = len(altRegionISO3) - regionISO.s[i] += string([]byte{0, byte(len(altRegionISO3))}) - altRegionISO3 += iso3 - altRegionIDs = append(altRegionIDs, uint16(isoOffset+i)) - } - } - } - for _, tc := range b.supp.CodeMappings.TerritoryCodes { - i := regionISO.index(tc.Type) + isoOffset - if d := m49map[i]; d != 0 { - log.Panicf("%s found as a duplicate UN.M49 code of %03d", tc.Numeric, d) - } - m49 := parseM49(tc.Numeric) - m49map[i] = m49 - if r := fromM49map[m49]; r == 0 { - fromM49map[m49] = i - } else if r != i { - dep := b.registry[regionISO.s[r-isoOffset]].deprecated - if t := b.registry[tc.Type]; t != nil && dep != "" && (t.deprecated == "" || t.deprecated > dep) { - fromM49map[m49] = i - } - } - } - for _, ta := range b.supp.Metadata.Alias.TerritoryAlias { - if len(ta.Type) == 3 && ta.Type[0] <= '9' && len(ta.Replacement) == 2 { - from := parseM49(ta.Type) - if r := fromM49map[from]; r == 0 { - fromM49map[from] = regionISO.index(ta.Replacement) + isoOffset - } - } - } - for _, tc := range b.supp.CodeMappings.TerritoryCodes { - if len(tc.Alpha3) == 3 { - update(tc.Type, tc.Alpha3) - } - } - // This entries are not included in territoryCodes. Mostly 3-letter variants - // of deleted codes and an entry for QU. - for _, m := range []struct{ iso2, iso3 string }{ - {"CT", "CTE"}, - {"DY", "DHY"}, - {"HV", "HVO"}, - {"JT", "JTN"}, - {"MI", "MID"}, - {"NH", "NHB"}, - {"NQ", "ATN"}, - {"PC", "PCI"}, - {"PU", "PUS"}, - {"PZ", "PCZ"}, - {"RH", "RHO"}, - {"VD", "VDR"}, - {"WK", "WAK"}, - // These three-letter codes are used for others as well. - {"FQ", "ATF"}, - } { - update(m.iso2, m.iso3) - } - for i, s := range regionISO.s { - if len(s) != 4 { - regionISO.s[i] = s + " " - } - } - b.writeConst("regionISO", tag.Index(regionISO.join())) - b.writeConst("altRegionISO3", altRegionISO3) - b.writeSlice("altRegionIDs", altRegionIDs) - - // Create list of deprecated regions. - // TODO: consider inserting SF -> FI. Not included by CLDR, but is the only - // Transitionally-reserved mapping not included. - regionOldMap := stringSet{} - // Include regions in territoryAlias (not all are in the IANA registry!) - for _, reg := range b.supp.Metadata.Alias.TerritoryAlias { - if len(reg.Type) == 2 && reg.Reason == "deprecated" && len(reg.Replacement) == 2 { - regionOldMap.add(reg.Type) - regionOldMap.updateLater(reg.Type, reg.Replacement) - i, _ := regionISO.find(reg.Type) - j, _ := regionISO.find(reg.Replacement) - if k := m49map[i+isoOffset]; k == 0 { - m49map[i+isoOffset] = m49map[j+isoOffset] - } - } - } - b.writeSortedMap("regionOldMap", ®ionOldMap, func(s string) uint16 { - return uint16(b.region.index(s)) - }) - // 3-digit region lookup, groupings. - for i := 1; i < isoOffset; i++ { - m := parseM49(b.region.s[i]) - m49map[i] = m - fromM49map[m] = i - } - b.writeSlice("m49", m49map) - - const ( - searchBits = 7 - regionBits = 9 - ) - if len(m49map) >= 1< %d", len(m49map), 1<>searchBits] = int16(len(fromM49)) - } - b.writeSlice("m49Index", m49Index) - b.writeSlice("fromM49", fromM49) -} - -const ( - // TODO: put these lists in regionTypes as user data? Could be used for - // various optimizations and refinements and could be exposed in the API. - iso3166Except = "AC CP DG EA EU FX IC SU TA UK" - iso3166Trans = "AN BU CS NT TP YU ZR" // SF is not in our set of Regions. - // DY and RH are actually not deleted, but indeterminately reserved. - iso3166DelCLDR = "CT DD DY FQ HV JT MI NH NQ PC PU PZ RH VD WK YD" -) - -const ( - iso3166UserAssigned = 1 << iota - ccTLD - bcp47Region -) - -func find(list []string, s string) int { - for i, t := range list { - if t == s { - return i - } - } - return -1 -} - -// writeVariants generates per-variant information and creates a map from variant -// name to index value. We assign index values such that sorting multiple -// variants by index value will result in the correct order. -// There are two types of variants: specialized and general. Specialized variants -// are only applicable to certain language or language-script pairs. Generalized -// variants apply to any language. Generalized variants always sort after -// specialized variants. We will therefore always assign a higher index value -// to a generalized variant than any other variant. Generalized variants are -// sorted alphabetically among themselves. -// Specialized variants may also sort after other specialized variants. Such -// variants will be ordered after any of the variants they may follow. -// We assume that if a variant x is followed by a variant y, then for any prefix -// p of x, p-x is a prefix of y. This allows us to order tags based on the -// maximum of the length of any of its prefixes. -// TODO: it is possible to define a set of Prefix values on variants such that -// a total order cannot be defined to the point that this algorithm breaks. -// In other words, we cannot guarantee the same order of variants for the -// future using the same algorithm or for non-compliant combinations of -// variants. For this reason, consider using simple alphabetic sorting -// of variants and ignore Prefix restrictions altogether. -func (b *builder) writeVariant() { - generalized := stringSet{} - specialized := stringSet{} - specializedExtend := stringSet{} - // Collate the variants by type and check assumptions. - for _, v := range b.variant.slice() { - e := b.registry[v] - if len(e.prefix) == 0 { - generalized.add(v) - continue - } - c := strings.Split(e.prefix[0], "-") - hasScriptOrRegion := false - if len(c) > 1 { - _, hasScriptOrRegion = b.script.find(c[1]) - if !hasScriptOrRegion { - _, hasScriptOrRegion = b.region.find(c[1]) - - } - } - if len(c) == 1 || len(c) == 2 && hasScriptOrRegion { - // Variant is preceded by a language. - specialized.add(v) - continue - } - // Variant is preceded by another variant. - specializedExtend.add(v) - prefix := c[0] + "-" - if hasScriptOrRegion { - prefix += c[1] - } - for _, p := range e.prefix { - // Verify that the prefix minus the last element is a prefix of the - // predecessor element. - i := strings.LastIndex(p, "-") - pred := b.registry[p[i+1:]] - if find(pred.prefix, p[:i]) < 0 { - log.Fatalf("prefix %q for variant %q not consistent with predecessor spec", p, v) - } - // The sorting used below does not work in the general case. It works - // if we assume that variants that may be followed by others only have - // prefixes of the same length. Verify this. - count := strings.Count(p[:i], "-") - for _, q := range pred.prefix { - if c := strings.Count(q, "-"); c != count { - log.Fatalf("variant %q preceding %q has a prefix %q of size %d; want %d", p[i+1:], v, q, c, count) - } - } - if !strings.HasPrefix(p, prefix) { - log.Fatalf("prefix %q of variant %q should start with %q", p, v, prefix) - } - } - } - - // Sort extended variants. - a := specializedExtend.s - less := func(v, w string) bool { - // Sort by the maximum number of elements. - maxCount := func(s string) (max int) { - for _, p := range b.registry[s].prefix { - if c := strings.Count(p, "-"); c > max { - max = c - } - } - return - } - if cv, cw := maxCount(v), maxCount(w); cv != cw { - return cv < cw - } - // Sort by name as tie breaker. - return v < w - } - sort.Sort(funcSorter{less, sort.StringSlice(a)}) - specializedExtend.frozen = true - - // Create index from variant name to index. - variantIndex := make(map[string]uint8) - add := func(s []string) { - for _, v := range s { - variantIndex[v] = uint8(len(variantIndex)) - } - } - add(specialized.slice()) - add(specializedExtend.s) - numSpecialized := len(variantIndex) - add(generalized.slice()) - if n := len(variantIndex); n > 255 { - log.Fatalf("maximum number of variants exceeded: was %d; want <= 255", n) - } - b.writeMap("variantIndex", variantIndex) - b.writeConst("variantNumSpecialized", numSpecialized) -} - -func (b *builder) writeLanguageInfo() { -} - -// writeLikelyData writes tables that are used both for finding parent relations and for -// language matching. Each entry contains additional bits to indicate the status of the -// data to know when it cannot be used for parent relations. -func (b *builder) writeLikelyData() { - const ( - isList = 1 << iota - scriptInFrom - regionInFrom - ) - type ( // generated types - likelyScriptRegion struct { - region uint16 - script uint8 - flags uint8 - } - likelyLangScript struct { - lang uint16 - script uint8 - flags uint8 - } - likelyLangRegion struct { - lang uint16 - region uint16 - } - // likelyTag is used for getting likely tags for group regions, where - // the likely region might be a region contained in the group. - likelyTag struct { - lang uint16 - region uint16 - script uint8 - } - ) - var ( // generated variables - likelyRegionGroup = make([]likelyTag, len(b.groups)) - likelyLang = make([]likelyScriptRegion, len(b.lang.s)) - likelyRegion = make([]likelyLangScript, len(b.region.s)) - likelyScript = make([]likelyLangRegion, len(b.script.s)) - likelyLangList = []likelyScriptRegion{} - likelyRegionList = []likelyLangScript{} - ) - type fromTo struct { - from, to []string - } - langToOther := map[int][]fromTo{} - regionToOther := map[int][]fromTo{} - for _, m := range b.supp.LikelySubtags.LikelySubtag { - from := strings.Split(m.From, "_") - to := strings.Split(m.To, "_") - if len(to) != 3 { - log.Fatalf("invalid number of subtags in %q: found %d, want 3", m.To, len(to)) - } - if len(from) > 3 { - log.Fatalf("invalid number of subtags: found %d, want 1-3", len(from)) - } - if from[0] != to[0] && from[0] != "und" { - log.Fatalf("unexpected language change in expansion: %s -> %s", from, to) - } - if len(from) == 3 { - if from[2] != to[2] { - log.Fatalf("unexpected region change in expansion: %s -> %s", from, to) - } - if from[0] != "und" { - log.Fatalf("unexpected fully specified from tag: %s -> %s", from, to) - } - } - if len(from) == 1 || from[0] != "und" { - id := 0 - if from[0] != "und" { - id = b.lang.index(from[0]) - } - langToOther[id] = append(langToOther[id], fromTo{from, to}) - } else if len(from) == 2 && len(from[1]) == 4 { - sid := b.script.index(from[1]) - likelyScript[sid].lang = uint16(b.langIndex(to[0])) - likelyScript[sid].region = uint16(b.region.index(to[2])) - } else { - r := b.region.index(from[len(from)-1]) - if id, ok := b.groups[r]; ok { - if from[0] != "und" { - log.Fatalf("region changed unexpectedly: %s -> %s", from, to) - } - likelyRegionGroup[id].lang = uint16(b.langIndex(to[0])) - likelyRegionGroup[id].script = uint8(b.script.index(to[1])) - likelyRegionGroup[id].region = uint16(b.region.index(to[2])) - } else { - regionToOther[r] = append(regionToOther[r], fromTo{from, to}) - } - } - } - b.writeType(likelyLangRegion{}) - b.writeSlice("likelyScript", likelyScript) - - for id := range b.lang.s { - list := langToOther[id] - if len(list) == 1 { - likelyLang[id].region = uint16(b.region.index(list[0].to[2])) - likelyLang[id].script = uint8(b.script.index(list[0].to[1])) - } else if len(list) > 1 { - likelyLang[id].flags = isList - likelyLang[id].region = uint16(len(likelyLangList)) - likelyLang[id].script = uint8(len(list)) - for _, x := range list { - flags := uint8(0) - if len(x.from) > 1 { - if x.from[1] == x.to[2] { - flags = regionInFrom - } else { - flags = scriptInFrom - } - } - likelyLangList = append(likelyLangList, likelyScriptRegion{ - region: uint16(b.region.index(x.to[2])), - script: uint8(b.script.index(x.to[1])), - flags: flags, - }) - } - } - } - // TODO: merge suppressScript data with this table. - b.writeType(likelyScriptRegion{}) - b.writeSlice("likelyLang", likelyLang) - b.writeSlice("likelyLangList", likelyLangList) - - for id := range b.region.s { - list := regionToOther[id] - if len(list) == 1 { - likelyRegion[id].lang = uint16(b.langIndex(list[0].to[0])) - likelyRegion[id].script = uint8(b.script.index(list[0].to[1])) - if len(list[0].from) > 2 { - likelyRegion[id].flags = scriptInFrom - } - } else if len(list) > 1 { - likelyRegion[id].flags = isList - likelyRegion[id].lang = uint16(len(likelyRegionList)) - likelyRegion[id].script = uint8(len(list)) - for i, x := range list { - if len(x.from) == 2 && i != 0 || i > 0 && len(x.from) != 3 { - log.Fatalf("unspecified script must be first in list: %v at %d", x.from, i) - } - x := likelyLangScript{ - lang: uint16(b.langIndex(x.to[0])), - script: uint8(b.script.index(x.to[1])), - } - if len(list[0].from) > 2 { - x.flags = scriptInFrom - } - likelyRegionList = append(likelyRegionList, x) - } - } - } - b.writeType(likelyLangScript{}) - b.writeSlice("likelyRegion", likelyRegion) - b.writeSlice("likelyRegionList", likelyRegionList) - - b.writeType(likelyTag{}) - b.writeSlice("likelyRegionGroup", likelyRegionGroup) -} - -type mutualIntelligibility struct { - want, have uint16 - distance uint8 - oneway bool -} - -type scriptIntelligibility struct { - wantLang, haveLang uint16 - wantScript, haveScript uint8 - distance uint8 - // Always oneway -} - -type regionIntelligibility struct { - lang uint16 // compact language id - script uint8 // 0 means any - group uint8 // 0 means any; if bit 7 is set it means inverse - distance uint8 - // Always twoway. -} - -// writeMatchData writes tables with languages and scripts for which there is -// mutual intelligibility. The data is based on CLDR's languageMatching data. -// Note that we use a different algorithm than the one defined by CLDR and that -// we slightly modify the data. For example, we convert scores to confidence levels. -// We also drop all region-related data as we use a different algorithm to -// determine region equivalence. -func (b *builder) writeMatchData() { - lm := b.supp.LanguageMatching.LanguageMatches - cldr.MakeSlice(&lm).SelectAnyOf("type", "written_new") - - regionHierarchy := map[string][]string{} - for _, g := range b.supp.TerritoryContainment.Group { - regions := strings.Split(g.Contains, " ") - regionHierarchy[g.Type] = append(regionHierarchy[g.Type], regions...) - } - regionToGroups := make([]uint8, len(b.region.s)) - - idToIndex := map[string]uint8{} - for i, mv := range lm[0].MatchVariable { - if i > 6 { - log.Fatalf("Too many groups: %d", i) - } - idToIndex[mv.Id] = uint8(i + 1) - // TODO: also handle '-' - for _, r := range strings.Split(mv.Value, "+") { - todo := []string{r} - for k := 0; k < len(todo); k++ { - r := todo[k] - regionToGroups[b.region.index(r)] |= 1 << uint8(i) - todo = append(todo, regionHierarchy[r]...) - } - } - } - b.writeSlice("regionToGroups", regionToGroups) - - // maps language id to in- and out-of-group region. - paradigmLocales := [][3]uint16{} - locales := strings.Split(lm[0].ParadigmLocales[0].Locales, " ") - for i := 0; i < len(locales); i += 2 { - x := [3]uint16{} - for j := 0; j < 2; j++ { - pc := strings.SplitN(locales[i+j], "-", 2) - x[0] = b.langIndex(pc[0]) - if len(pc) == 2 { - x[1+j] = uint16(b.region.index(pc[1])) - } - } - paradigmLocales = append(paradigmLocales, x) - } - b.writeSlice("paradigmLocales", paradigmLocales) - - b.writeType(mutualIntelligibility{}) - b.writeType(scriptIntelligibility{}) - b.writeType(regionIntelligibility{}) - - matchLang := []mutualIntelligibility{} - matchScript := []scriptIntelligibility{} - matchRegion := []regionIntelligibility{} - // Convert the languageMatch entries in lists keyed by desired language. - for _, m := range lm[0].LanguageMatch { - // Different versions of CLDR use different separators. - desired := strings.Replace(m.Desired, "-", "_", -1) - supported := strings.Replace(m.Supported, "-", "_", -1) - d := strings.Split(desired, "_") - s := strings.Split(supported, "_") - if len(d) != len(s) { - log.Fatalf("not supported: desired=%q; supported=%q", desired, supported) - continue - } - distance, _ := strconv.ParseInt(m.Distance, 10, 8) - switch len(d) { - case 2: - if desired == supported && desired == "*_*" { - continue - } - // language-script pair. - matchScript = append(matchScript, scriptIntelligibility{ - wantLang: uint16(b.langIndex(d[0])), - haveLang: uint16(b.langIndex(s[0])), - wantScript: uint8(b.script.index(d[1])), - haveScript: uint8(b.script.index(s[1])), - distance: uint8(distance), - }) - if m.Oneway != "true" { - matchScript = append(matchScript, scriptIntelligibility{ - wantLang: uint16(b.langIndex(s[0])), - haveLang: uint16(b.langIndex(d[0])), - wantScript: uint8(b.script.index(s[1])), - haveScript: uint8(b.script.index(d[1])), - distance: uint8(distance), - }) - } - case 1: - if desired == supported && desired == "*" { - continue - } - if distance == 1 { - // nb == no is already handled by macro mapping. Check there - // really is only this case. - if d[0] != "no" || s[0] != "nb" { - log.Fatalf("unhandled equivalence %s == %s", s[0], d[0]) - } - continue - } - // TODO: consider dropping oneway field and just doubling the entry. - matchLang = append(matchLang, mutualIntelligibility{ - want: uint16(b.langIndex(d[0])), - have: uint16(b.langIndex(s[0])), - distance: uint8(distance), - oneway: m.Oneway == "true", - }) - case 3: - if desired == supported && desired == "*_*_*" { - continue - } - if desired != supported { - // This is now supported by CLDR, but only one case, which - // should already be covered by paradigm locales. For instance, - // test case "und, en, en-GU, en-IN, en-GB ; en-ZA ; en-GB" in - // testdata/CLDRLocaleMatcherTest.txt tests this. - if supported != "en_*_GB" { - log.Fatalf("not supported: desired=%q; supported=%q", desired, supported) - } - continue - } - ri := regionIntelligibility{ - lang: b.langIndex(d[0]), - distance: uint8(distance), - } - if d[1] != "*" { - ri.script = uint8(b.script.index(d[1])) - } - switch { - case d[2] == "*": - ri.group = 0x80 // not contained in anything - case strings.HasPrefix(d[2], "$!"): - ri.group = 0x80 - d[2] = "$" + d[2][len("$!"):] - fallthrough - case strings.HasPrefix(d[2], "$"): - ri.group |= idToIndex[d[2]] - } - matchRegion = append(matchRegion, ri) - default: - log.Fatalf("not supported: desired=%q; supported=%q", desired, supported) - } - } - sort.SliceStable(matchLang, func(i, j int) bool { - return matchLang[i].distance < matchLang[j].distance - }) - b.writeSlice("matchLang", matchLang) - - sort.SliceStable(matchScript, func(i, j int) bool { - return matchScript[i].distance < matchScript[j].distance - }) - b.writeSlice("matchScript", matchScript) - - sort.SliceStable(matchRegion, func(i, j int) bool { - return matchRegion[i].distance < matchRegion[j].distance - }) - b.writeSlice("matchRegion", matchRegion) -} - -func (b *builder) writeRegionInclusionData() { - var ( - // mm holds for each group the set of groups with a distance of 1. - mm = make(map[int][]index) - - // containment holds for each group the transitive closure of - // containment of other groups. - containment = make(map[index][]index) - ) - for _, g := range b.supp.TerritoryContainment.Group { - // Skip UN and EURO zone as they are flattening the containment - // relationship. - if g.Type == "EZ" || g.Type == "UN" { - continue - } - group := b.region.index(g.Type) - groupIdx := b.groups[group] - for _, mem := range strings.Split(g.Contains, " ") { - r := b.region.index(mem) - mm[r] = append(mm[r], groupIdx) - if g, ok := b.groups[r]; ok { - mm[group] = append(mm[group], g) - containment[groupIdx] = append(containment[groupIdx], g) - } - } - } - - regionContainment := make([]uint64, len(b.groups)) - for _, g := range b.groups { - l := containment[g] - - // Compute the transitive closure of containment. - for i := 0; i < len(l); i++ { - l = append(l, containment[l[i]]...) - } - - // Compute the bitmask. - regionContainment[g] = 1 << g - for _, v := range l { - regionContainment[g] |= 1 << v - } - } - b.writeSlice("regionContainment", regionContainment) - - regionInclusion := make([]uint8, len(b.region.s)) - bvs := make(map[uint64]index) - // Make the first bitvector positions correspond with the groups. - for r, i := range b.groups { - bv := uint64(1 << i) - for _, g := range mm[r] { - bv |= 1 << g - } - bvs[bv] = i - regionInclusion[r] = uint8(bvs[bv]) - } - for r := 1; r < len(b.region.s); r++ { - if _, ok := b.groups[r]; !ok { - bv := uint64(0) - for _, g := range mm[r] { - bv |= 1 << g - } - if bv == 0 { - // Pick the world for unspecified regions. - bv = 1 << b.groups[b.region.index("001")] - } - if _, ok := bvs[bv]; !ok { - bvs[bv] = index(len(bvs)) - } - regionInclusion[r] = uint8(bvs[bv]) - } - } - b.writeSlice("regionInclusion", regionInclusion) - regionInclusionBits := make([]uint64, len(bvs)) - for k, v := range bvs { - regionInclusionBits[v] = uint64(k) - } - // Add bit vectors for increasingly large distances until a fixed point is reached. - regionInclusionNext := []uint8{} - for i := 0; i < len(regionInclusionBits); i++ { - bits := regionInclusionBits[i] - next := bits - for i := uint(0); i < uint(len(b.groups)); i++ { - if bits&(1< b'. Using - // bytes.Replace will do. - out := bytes.Replace(buf.Bytes(), []byte("language."), nil, -1) - if err := ioutil.WriteFile("index.go", out, 0600); err != nil { - log.Fatalf("Could not create file index.go: %v", err) - } - }() - - m := map[language.Tag]bool{} - for _, lang := range data.Locales() { - // We include all locales unconditionally to be consistent with en_US. - // We want en_US, even though it has no data associated with it. - - // TODO: put any of the languages for which no data exists at the end - // of the index. This allows all components based on ICU to use that - // as the cutoff point. - // if x := data.RawLDML(lang); false || - // x.LocaleDisplayNames != nil || - // x.Characters != nil || - // x.Delimiters != nil || - // x.Measurement != nil || - // x.Dates != nil || - // x.Numbers != nil || - // x.Units != nil || - // x.ListPatterns != nil || - // x.Collations != nil || - // x.Segmentations != nil || - // x.Rbnf != nil || - // x.Annotations != nil || - // x.Metadata != nil { - - // TODO: support POSIX natively, albeit non-standard. - tag := language.Make(strings.Replace(lang, "_POSIX", "-u-va-posix", 1)) - m[tag] = true - // } - } - // Include locales for plural rules, which uses a different structure. - for _, plurals := range data.Supplemental().Plurals { - for _, rules := range plurals.PluralRules { - for _, lang := range strings.Split(rules.Locales, " ") { - m[language.Make(lang)] = true - } - } - } - - var core, special []language.Tag - - for t := range m { - if x := t.Extensions(); len(x) != 0 && fmt.Sprint(x) != "[u-va-posix]" { - log.Fatalf("Unexpected extension %v in %v", x, t) - } - if len(t.Variants()) == 0 && len(t.Extensions()) == 0 { - core = append(core, t) - } else { - special = append(special, t) - } - } - - w.WriteComment(` - NumCompactTags is the number of common tags. The maximum tag is - NumCompactTags-1.`) - w.WriteConst("NumCompactTags", len(core)+len(special)) - - sort.Sort(byAlpha(special)) - w.WriteVar("specialTags", special) - - // TODO: order by frequency? - sort.Sort(byAlpha(core)) - - // Size computations are just an estimate. - w.Size += int(reflect.TypeOf(map[uint32]uint16{}).Size()) - w.Size += len(core) * 6 // size of uint32 and uint16 - - fmt.Fprintln(w) - fmt.Fprintln(w, "var coreTags = map[uint32]uint16{") - fmt.Fprintln(w, "0x0: 0, // und") - i := len(special) + 1 // Und and special tags already written. - for _, t := range core { - if t == language.Und { - continue - } - fmt.Fprint(w.Hash, t, i) - b, s, r := t.Raw() - fmt.Fprintf(w, "0x%s%s%s: %d, // %s\n", - getIndex(b, 3), // 3 is enough as it is guaranteed to be a compact number - getIndex(s, 2), - getIndex(r, 3), - i, t) - i++ - } - fmt.Fprintln(w, "}") -} - -// getIndex prints the subtag type and extracts its index of size nibble. -// If the index is less than n nibbles, the result is prefixed with 0s. -func getIndex(x interface{}, n int) string { - s := fmt.Sprintf("%#v", x) // s is of form Type{typeID: 0x00} - s = s[strings.Index(s, "0x")+2 : len(s)-1] - return strings.Repeat("0", n-len(s)) + s -} - -type byAlpha []language.Tag - -func (a byAlpha) Len() int { return len(a) } -func (a byAlpha) Swap(i, j int) { a[i], a[j] = a[j], a[i] } -func (a byAlpha) Less(i, j int) bool { return a[i].String() < a[j].String() } diff --git a/vendor/golang.org/x/text/unicode/bidi/gen.go b/vendor/golang.org/x/text/unicode/bidi/gen.go deleted file mode 100644 index 4e1c7ba0bf4dd6bc86bd2a86b00d64d6c71b2ac0..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/unicode/bidi/gen.go +++ /dev/null @@ -1,133 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -import ( - "flag" - "log" - - "golang.org/x/text/internal/gen" - "golang.org/x/text/internal/triegen" - "golang.org/x/text/internal/ucd" -) - -var outputFile = flag.String("out", "tables.go", "output file") - -func main() { - gen.Init() - gen.Repackage("gen_trieval.go", "trieval.go", "bidi") - gen.Repackage("gen_ranges.go", "ranges_test.go", "bidi") - - genTables() -} - -// bidiClass names and codes taken from class "bc" in -// http://www.unicode.org/Public/8.0.0/ucd/PropertyValueAliases.txt -var bidiClass = map[string]Class{ - "AL": AL, // ArabicLetter - "AN": AN, // ArabicNumber - "B": B, // ParagraphSeparator - "BN": BN, // BoundaryNeutral - "CS": CS, // CommonSeparator - "EN": EN, // EuropeanNumber - "ES": ES, // EuropeanSeparator - "ET": ET, // EuropeanTerminator - "L": L, // LeftToRight - "NSM": NSM, // NonspacingMark - "ON": ON, // OtherNeutral - "R": R, // RightToLeft - "S": S, // SegmentSeparator - "WS": WS, // WhiteSpace - - "FSI": Control, - "PDF": Control, - "PDI": Control, - "LRE": Control, - "LRI": Control, - "LRO": Control, - "RLE": Control, - "RLI": Control, - "RLO": Control, -} - -func genTables() { - if numClass > 0x0F { - log.Fatalf("Too many Class constants (%#x > 0x0F).", numClass) - } - w := gen.NewCodeWriter() - defer w.WriteVersionedGoFile(*outputFile, "bidi") - - gen.WriteUnicodeVersion(w) - - t := triegen.NewTrie("bidi") - - // Build data about bracket mapping. These bits need to be or-ed with - // any other bits. - orMask := map[rune]uint64{} - - xorMap := map[rune]int{} - xorMasks := []rune{0} // First value is no-op. - - ucd.Parse(gen.OpenUCDFile("BidiBrackets.txt"), func(p *ucd.Parser) { - r1 := p.Rune(0) - r2 := p.Rune(1) - xor := r1 ^ r2 - if _, ok := xorMap[xor]; !ok { - xorMap[xor] = len(xorMasks) - xorMasks = append(xorMasks, xor) - } - entry := uint64(xorMap[xor]) << xorMaskShift - switch p.String(2) { - case "o": - entry |= openMask - case "c", "n": - default: - log.Fatalf("Unknown bracket class %q.", p.String(2)) - } - orMask[r1] = entry - }) - - w.WriteComment(` - xorMasks contains masks to be xor-ed with brackets to get the reverse - version.`) - w.WriteVar("xorMasks", xorMasks) - - done := map[rune]bool{} - - insert := func(r rune, c Class) { - if !done[r] { - t.Insert(r, orMask[r]|uint64(c)) - done[r] = true - } - } - - // Insert the derived BiDi properties. - ucd.Parse(gen.OpenUCDFile("extracted/DerivedBidiClass.txt"), func(p *ucd.Parser) { - r := p.Rune(0) - class, ok := bidiClass[p.String(1)] - if !ok { - log.Fatalf("%U: Unknown BiDi class %q", r, p.String(1)) - } - insert(r, class) - }) - visitDefaults(insert) - - // TODO: use sparse blocks. This would reduce table size considerably - // from the looks of it. - - sz, err := t.Gen(w) - if err != nil { - log.Fatal(err) - } - w.Size += sz -} - -// dummy values to make methods in gen_common compile. The real versions -// will be generated by this file to tables.go. -var ( - xorMasks []rune -) diff --git a/vendor/golang.org/x/text/unicode/bidi/gen_ranges.go b/vendor/golang.org/x/text/unicode/bidi/gen_ranges.go deleted file mode 100644 index 51bd68fa7f38cfbfb7c528208961c63f33468864..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/unicode/bidi/gen_ranges.go +++ /dev/null @@ -1,57 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -import ( - "unicode" - - "golang.org/x/text/internal/gen" - "golang.org/x/text/internal/ucd" - "golang.org/x/text/unicode/rangetable" -) - -// These tables are hand-extracted from: -// http://www.unicode.org/Public/8.0.0/ucd/extracted/DerivedBidiClass.txt -func visitDefaults(fn func(r rune, c Class)) { - // first write default values for ranges listed above. - visitRunes(fn, AL, []rune{ - 0x0600, 0x07BF, // Arabic - 0x08A0, 0x08FF, // Arabic Extended-A - 0xFB50, 0xFDCF, // Arabic Presentation Forms - 0xFDF0, 0xFDFF, - 0xFE70, 0xFEFF, - 0x0001EE00, 0x0001EEFF, // Arabic Mathematical Alpha Symbols - }) - visitRunes(fn, R, []rune{ - 0x0590, 0x05FF, // Hebrew - 0x07C0, 0x089F, // Nko et al. - 0xFB1D, 0xFB4F, - 0x00010800, 0x00010FFF, // Cypriot Syllabary et. al. - 0x0001E800, 0x0001EDFF, - 0x0001EF00, 0x0001EFFF, - }) - visitRunes(fn, ET, []rune{ // European Terminator - 0x20A0, 0x20Cf, // Currency symbols - }) - rangetable.Visit(unicode.Noncharacter_Code_Point, func(r rune) { - fn(r, BN) // Boundary Neutral - }) - ucd.Parse(gen.OpenUCDFile("DerivedCoreProperties.txt"), func(p *ucd.Parser) { - if p.String(1) == "Default_Ignorable_Code_Point" { - fn(p.Rune(0), BN) // Boundary Neutral - } - }) -} - -func visitRunes(fn func(r rune, c Class), c Class, runes []rune) { - for i := 0; i < len(runes); i += 2 { - lo, hi := runes[i], runes[i+1] - for j := lo; j <= hi; j++ { - fn(j, c) - } - } -} diff --git a/vendor/golang.org/x/text/unicode/bidi/gen_trieval.go b/vendor/golang.org/x/text/unicode/bidi/gen_trieval.go deleted file mode 100644 index 9cb9942894920a5c56440b73cc356b3b67fab9e5..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/unicode/bidi/gen_trieval.go +++ /dev/null @@ -1,64 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -// Class is the Unicode BiDi class. Each rune has a single class. -type Class uint - -const ( - L Class = iota // LeftToRight - R // RightToLeft - EN // EuropeanNumber - ES // EuropeanSeparator - ET // EuropeanTerminator - AN // ArabicNumber - CS // CommonSeparator - B // ParagraphSeparator - S // SegmentSeparator - WS // WhiteSpace - ON // OtherNeutral - BN // BoundaryNeutral - NSM // NonspacingMark - AL // ArabicLetter - Control // Control LRO - PDI - - numClass - - LRO // LeftToRightOverride - RLO // RightToLeftOverride - LRE // LeftToRightEmbedding - RLE // RightToLeftEmbedding - PDF // PopDirectionalFormat - LRI // LeftToRightIsolate - RLI // RightToLeftIsolate - FSI // FirstStrongIsolate - PDI // PopDirectionalIsolate - - unknownClass = ^Class(0) -) - -var controlToClass = map[rune]Class{ - 0x202D: LRO, // LeftToRightOverride, - 0x202E: RLO, // RightToLeftOverride, - 0x202A: LRE, // LeftToRightEmbedding, - 0x202B: RLE, // RightToLeftEmbedding, - 0x202C: PDF, // PopDirectionalFormat, - 0x2066: LRI, // LeftToRightIsolate, - 0x2067: RLI, // RightToLeftIsolate, - 0x2068: FSI, // FirstStrongIsolate, - 0x2069: PDI, // PopDirectionalIsolate, -} - -// A trie entry has the following bits: -// 7..5 XOR mask for brackets -// 4 1: Bracket open, 0: Bracket close -// 3..0 Class type - -const ( - openMask = 0x10 - xorMaskShift = 5 -) diff --git a/vendor/golang.org/x/text/unicode/norm/maketables.go b/vendor/golang.org/x/text/unicode/norm/maketables.go deleted file mode 100644 index 338c395ee6f8073e76e4401bed10a98273d226dc..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/unicode/norm/maketables.go +++ /dev/null @@ -1,976 +0,0 @@ -// Copyright 2011 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -// Normalization table generator. -// Data read from the web. -// See forminfo.go for a description of the trie values associated with each rune. - -package main - -import ( - "bytes" - "flag" - "fmt" - "io" - "log" - "sort" - "strconv" - "strings" - - "golang.org/x/text/internal/gen" - "golang.org/x/text/internal/triegen" - "golang.org/x/text/internal/ucd" -) - -func main() { - gen.Init() - loadUnicodeData() - compactCCC() - loadCompositionExclusions() - completeCharFields(FCanonical) - completeCharFields(FCompatibility) - computeNonStarterCounts() - verifyComputed() - printChars() - testDerived() - printTestdata() - makeTables() -} - -var ( - tablelist = flag.String("tables", - "all", - "comma-separated list of which tables to generate; "+ - "can be 'decomp', 'recomp', 'info' and 'all'") - test = flag.Bool("test", - false, - "test existing tables against DerivedNormalizationProps and generate test data for regression testing") - verbose = flag.Bool("verbose", - false, - "write data to stdout as it is parsed") -) - -const MaxChar = 0x10FFFF // anything above this shouldn't exist - -// Quick Check properties of runes allow us to quickly -// determine whether a rune may occur in a normal form. -// For a given normal form, a rune may be guaranteed to occur -// verbatim (QC=Yes), may or may not combine with another -// rune (QC=Maybe), or may not occur (QC=No). -type QCResult int - -const ( - QCUnknown QCResult = iota - QCYes - QCNo - QCMaybe -) - -func (r QCResult) String() string { - switch r { - case QCYes: - return "Yes" - case QCNo: - return "No" - case QCMaybe: - return "Maybe" - } - return "***UNKNOWN***" -} - -const ( - FCanonical = iota // NFC or NFD - FCompatibility // NFKC or NFKD - FNumberOfFormTypes -) - -const ( - MComposed = iota // NFC or NFKC - MDecomposed // NFD or NFKD - MNumberOfModes -) - -// This contains only the properties we're interested in. -type Char struct { - name string - codePoint rune // if zero, this index is not a valid code point. - ccc uint8 // canonical combining class - origCCC uint8 - excludeInComp bool // from CompositionExclusions.txt - compatDecomp bool // it has a compatibility expansion - - nTrailingNonStarters uint8 - nLeadingNonStarters uint8 // must be equal to trailing if non-zero - - forms [FNumberOfFormTypes]FormInfo // For FCanonical and FCompatibility - - state State -} - -var chars = make([]Char, MaxChar+1) -var cccMap = make(map[uint8]uint8) - -func (c Char) String() string { - buf := new(bytes.Buffer) - - fmt.Fprintf(buf, "%U [%s]:\n", c.codePoint, c.name) - fmt.Fprintf(buf, " ccc: %v\n", c.ccc) - fmt.Fprintf(buf, " excludeInComp: %v\n", c.excludeInComp) - fmt.Fprintf(buf, " compatDecomp: %v\n", c.compatDecomp) - fmt.Fprintf(buf, " state: %v\n", c.state) - fmt.Fprintf(buf, " NFC:\n") - fmt.Fprint(buf, c.forms[FCanonical]) - fmt.Fprintf(buf, " NFKC:\n") - fmt.Fprint(buf, c.forms[FCompatibility]) - - return buf.String() -} - -// In UnicodeData.txt, some ranges are marked like this: -// 3400;;Lo;0;L;;;;;N;;;;; -// 4DB5;;Lo;0;L;;;;;N;;;;; -// parseCharacter keeps a state variable indicating the weirdness. -type State int - -const ( - SNormal State = iota // known to be zero for the type - SFirst - SLast - SMissing -) - -var lastChar = rune('\u0000') - -func (c Char) isValid() bool { - return c.codePoint != 0 && c.state != SMissing -} - -type FormInfo struct { - quickCheck [MNumberOfModes]QCResult // index: MComposed or MDecomposed - verified [MNumberOfModes]bool // index: MComposed or MDecomposed - - combinesForward bool // May combine with rune on the right - combinesBackward bool // May combine with rune on the left - isOneWay bool // Never appears in result - inDecomp bool // Some decompositions result in this char. - decomp Decomposition - expandedDecomp Decomposition -} - -func (f FormInfo) String() string { - buf := bytes.NewBuffer(make([]byte, 0)) - - fmt.Fprintf(buf, " quickCheck[C]: %v\n", f.quickCheck[MComposed]) - fmt.Fprintf(buf, " quickCheck[D]: %v\n", f.quickCheck[MDecomposed]) - fmt.Fprintf(buf, " cmbForward: %v\n", f.combinesForward) - fmt.Fprintf(buf, " cmbBackward: %v\n", f.combinesBackward) - fmt.Fprintf(buf, " isOneWay: %v\n", f.isOneWay) - fmt.Fprintf(buf, " inDecomp: %v\n", f.inDecomp) - fmt.Fprintf(buf, " decomposition: %X\n", f.decomp) - fmt.Fprintf(buf, " expandedDecomp: %X\n", f.expandedDecomp) - - return buf.String() -} - -type Decomposition []rune - -func parseDecomposition(s string, skipfirst bool) (a []rune, err error) { - decomp := strings.Split(s, " ") - if len(decomp) > 0 && skipfirst { - decomp = decomp[1:] - } - for _, d := range decomp { - point, err := strconv.ParseUint(d, 16, 64) - if err != nil { - return a, err - } - a = append(a, rune(point)) - } - return a, nil -} - -func loadUnicodeData() { - f := gen.OpenUCDFile("UnicodeData.txt") - defer f.Close() - p := ucd.New(f) - for p.Next() { - r := p.Rune(ucd.CodePoint) - char := &chars[r] - - char.ccc = uint8(p.Uint(ucd.CanonicalCombiningClass)) - decmap := p.String(ucd.DecompMapping) - - exp, err := parseDecomposition(decmap, false) - isCompat := false - if err != nil { - if len(decmap) > 0 { - exp, err = parseDecomposition(decmap, true) - if err != nil { - log.Fatalf(`%U: bad decomp |%v|: "%s"`, r, decmap, err) - } - isCompat = true - } - } - - char.name = p.String(ucd.Name) - char.codePoint = r - char.forms[FCompatibility].decomp = exp - if !isCompat { - char.forms[FCanonical].decomp = exp - } else { - char.compatDecomp = true - } - if len(decmap) > 0 { - char.forms[FCompatibility].decomp = exp - } - } - if err := p.Err(); err != nil { - log.Fatal(err) - } -} - -// compactCCC converts the sparse set of CCC values to a continguous one, -// reducing the number of bits needed from 8 to 6. -func compactCCC() { - m := make(map[uint8]uint8) - for i := range chars { - c := &chars[i] - m[c.ccc] = 0 - } - cccs := []int{} - for v, _ := range m { - cccs = append(cccs, int(v)) - } - sort.Ints(cccs) - for i, c := range cccs { - cccMap[uint8(i)] = uint8(c) - m[uint8(c)] = uint8(i) - } - for i := range chars { - c := &chars[i] - c.origCCC = c.ccc - c.ccc = m[c.ccc] - } - if len(m) >= 1<<6 { - log.Fatalf("too many difference CCC values: %d >= 64", len(m)) - } -} - -// CompositionExclusions.txt has form: -// 0958 # ... -// See http://unicode.org/reports/tr44/ for full explanation -func loadCompositionExclusions() { - f := gen.OpenUCDFile("CompositionExclusions.txt") - defer f.Close() - p := ucd.New(f) - for p.Next() { - c := &chars[p.Rune(0)] - if c.excludeInComp { - log.Fatalf("%U: Duplicate entry in exclusions.", c.codePoint) - } - c.excludeInComp = true - } - if e := p.Err(); e != nil { - log.Fatal(e) - } -} - -// hasCompatDecomp returns true if any of the recursive -// decompositions contains a compatibility expansion. -// In this case, the character may not occur in NFK*. -func hasCompatDecomp(r rune) bool { - c := &chars[r] - if c.compatDecomp { - return true - } - for _, d := range c.forms[FCompatibility].decomp { - if hasCompatDecomp(d) { - return true - } - } - return false -} - -// Hangul related constants. -const ( - HangulBase = 0xAC00 - HangulEnd = 0xD7A4 // hangulBase + Jamo combinations (19 * 21 * 28) - - JamoLBase = 0x1100 - JamoLEnd = 0x1113 - JamoVBase = 0x1161 - JamoVEnd = 0x1176 - JamoTBase = 0x11A8 - JamoTEnd = 0x11C3 - - JamoLVTCount = 19 * 21 * 28 - JamoTCount = 28 -) - -func isHangul(r rune) bool { - return HangulBase <= r && r < HangulEnd -} - -func isHangulWithoutJamoT(r rune) bool { - if !isHangul(r) { - return false - } - r -= HangulBase - return r < JamoLVTCount && r%JamoTCount == 0 -} - -func ccc(r rune) uint8 { - return chars[r].ccc -} - -// Insert a rune in a buffer, ordered by Canonical Combining Class. -func insertOrdered(b Decomposition, r rune) Decomposition { - n := len(b) - b = append(b, 0) - cc := ccc(r) - if cc > 0 { - // Use bubble sort. - for ; n > 0; n-- { - if ccc(b[n-1]) <= cc { - break - } - b[n] = b[n-1] - } - } - b[n] = r - return b -} - -// Recursively decompose. -func decomposeRecursive(form int, r rune, d Decomposition) Decomposition { - dcomp := chars[r].forms[form].decomp - if len(dcomp) == 0 { - return insertOrdered(d, r) - } - for _, c := range dcomp { - d = decomposeRecursive(form, c, d) - } - return d -} - -func completeCharFields(form int) { - // Phase 0: pre-expand decomposition. - for i := range chars { - f := &chars[i].forms[form] - if len(f.decomp) == 0 { - continue - } - exp := make(Decomposition, 0) - for _, c := range f.decomp { - exp = decomposeRecursive(form, c, exp) - } - f.expandedDecomp = exp - } - - // Phase 1: composition exclusion, mark decomposition. - for i := range chars { - c := &chars[i] - f := &c.forms[form] - - // Marks script-specific exclusions and version restricted. - f.isOneWay = c.excludeInComp - - // Singletons - f.isOneWay = f.isOneWay || len(f.decomp) == 1 - - // Non-starter decompositions - if len(f.decomp) > 1 { - chk := c.ccc != 0 || chars[f.decomp[0]].ccc != 0 - f.isOneWay = f.isOneWay || chk - } - - // Runes that decompose into more than two runes. - f.isOneWay = f.isOneWay || len(f.decomp) > 2 - - if form == FCompatibility { - f.isOneWay = f.isOneWay || hasCompatDecomp(c.codePoint) - } - - for _, r := range f.decomp { - chars[r].forms[form].inDecomp = true - } - } - - // Phase 2: forward and backward combining. - for i := range chars { - c := &chars[i] - f := &c.forms[form] - - if !f.isOneWay && len(f.decomp) == 2 { - f0 := &chars[f.decomp[0]].forms[form] - f1 := &chars[f.decomp[1]].forms[form] - if !f0.isOneWay { - f0.combinesForward = true - } - if !f1.isOneWay { - f1.combinesBackward = true - } - } - if isHangulWithoutJamoT(rune(i)) { - f.combinesForward = true - } - } - - // Phase 3: quick check values. - for i := range chars { - c := &chars[i] - f := &c.forms[form] - - switch { - case len(f.decomp) > 0: - f.quickCheck[MDecomposed] = QCNo - case isHangul(rune(i)): - f.quickCheck[MDecomposed] = QCNo - default: - f.quickCheck[MDecomposed] = QCYes - } - switch { - case f.isOneWay: - f.quickCheck[MComposed] = QCNo - case (i & 0xffff00) == JamoLBase: - f.quickCheck[MComposed] = QCYes - if JamoLBase <= i && i < JamoLEnd { - f.combinesForward = true - } - if JamoVBase <= i && i < JamoVEnd { - f.quickCheck[MComposed] = QCMaybe - f.combinesBackward = true - f.combinesForward = true - } - if JamoTBase <= i && i < JamoTEnd { - f.quickCheck[MComposed] = QCMaybe - f.combinesBackward = true - } - case !f.combinesBackward: - f.quickCheck[MComposed] = QCYes - default: - f.quickCheck[MComposed] = QCMaybe - } - } -} - -func computeNonStarterCounts() { - // Phase 4: leading and trailing non-starter count - for i := range chars { - c := &chars[i] - - runes := []rune{rune(i)} - // We always use FCompatibility so that the CGJ insertion points do not - // change for repeated normalizations with different forms. - if exp := c.forms[FCompatibility].expandedDecomp; len(exp) > 0 { - runes = exp - } - // We consider runes that combine backwards to be non-starters for the - // purpose of Stream-Safe Text Processing. - for _, r := range runes { - if cr := &chars[r]; cr.ccc == 0 && !cr.forms[FCompatibility].combinesBackward { - break - } - c.nLeadingNonStarters++ - } - for i := len(runes) - 1; i >= 0; i-- { - if cr := &chars[runes[i]]; cr.ccc == 0 && !cr.forms[FCompatibility].combinesBackward { - break - } - c.nTrailingNonStarters++ - } - if c.nTrailingNonStarters > 3 { - log.Fatalf("%U: Decomposition with more than 3 (%d) trailing modifiers (%U)", i, c.nTrailingNonStarters, runes) - } - - if isHangul(rune(i)) { - c.nTrailingNonStarters = 2 - if isHangulWithoutJamoT(rune(i)) { - c.nTrailingNonStarters = 1 - } - } - - if l, t := c.nLeadingNonStarters, c.nTrailingNonStarters; l > 0 && l != t { - log.Fatalf("%U: number of leading and trailing non-starters should be equal (%d vs %d)", i, l, t) - } - if t := c.nTrailingNonStarters; t > 3 { - log.Fatalf("%U: number of trailing non-starters is %d > 3", t) - } - } -} - -func printBytes(w io.Writer, b []byte, name string) { - fmt.Fprintf(w, "// %s: %d bytes\n", name, len(b)) - fmt.Fprintf(w, "var %s = [...]byte {", name) - for i, c := range b { - switch { - case i%64 == 0: - fmt.Fprintf(w, "\n// Bytes %x - %x\n", i, i+63) - case i%8 == 0: - fmt.Fprintf(w, "\n") - } - fmt.Fprintf(w, "0x%.2X, ", c) - } - fmt.Fprint(w, "\n}\n\n") -} - -// See forminfo.go for format. -func makeEntry(f *FormInfo, c *Char) uint16 { - e := uint16(0) - if r := c.codePoint; HangulBase <= r && r < HangulEnd { - e |= 0x40 - } - if f.combinesForward { - e |= 0x20 - } - if f.quickCheck[MDecomposed] == QCNo { - e |= 0x4 - } - switch f.quickCheck[MComposed] { - case QCYes: - case QCNo: - e |= 0x10 - case QCMaybe: - e |= 0x18 - default: - log.Fatalf("Illegal quickcheck value %v.", f.quickCheck[MComposed]) - } - e |= uint16(c.nTrailingNonStarters) - return e -} - -// decompSet keeps track of unique decompositions, grouped by whether -// the decomposition is followed by a trailing and/or leading CCC. -type decompSet [7]map[string]bool - -const ( - normalDecomp = iota - firstMulti - firstCCC - endMulti - firstLeadingCCC - firstCCCZeroExcept - firstStarterWithNLead - lastDecomp -) - -var cname = []string{"firstMulti", "firstCCC", "endMulti", "firstLeadingCCC", "firstCCCZeroExcept", "firstStarterWithNLead", "lastDecomp"} - -func makeDecompSet() decompSet { - m := decompSet{} - for i := range m { - m[i] = make(map[string]bool) - } - return m -} -func (m *decompSet) insert(key int, s string) { - m[key][s] = true -} - -func printCharInfoTables(w io.Writer) int { - mkstr := func(r rune, f *FormInfo) (int, string) { - d := f.expandedDecomp - s := string([]rune(d)) - if max := 1 << 6; len(s) >= max { - const msg = "%U: too many bytes in decomposition: %d >= %d" - log.Fatalf(msg, r, len(s), max) - } - head := uint8(len(s)) - if f.quickCheck[MComposed] != QCYes { - head |= 0x40 - } - if f.combinesForward { - head |= 0x80 - } - s = string([]byte{head}) + s - - lccc := ccc(d[0]) - tccc := ccc(d[len(d)-1]) - cc := ccc(r) - if cc != 0 && lccc == 0 && tccc == 0 { - log.Fatalf("%U: trailing and leading ccc are 0 for non-zero ccc %d", r, cc) - } - if tccc < lccc && lccc != 0 { - const msg = "%U: lccc (%d) must be <= tcc (%d)" - log.Fatalf(msg, r, lccc, tccc) - } - index := normalDecomp - nTrail := chars[r].nTrailingNonStarters - nLead := chars[r].nLeadingNonStarters - if tccc > 0 || lccc > 0 || nTrail > 0 { - tccc <<= 2 - tccc |= nTrail - s += string([]byte{tccc}) - index = endMulti - for _, r := range d[1:] { - if ccc(r) == 0 { - index = firstCCC - } - } - if lccc > 0 || nLead > 0 { - s += string([]byte{lccc}) - if index == firstCCC { - log.Fatalf("%U: multi-segment decomposition not supported for decompositions with leading CCC != 0", r) - } - index = firstLeadingCCC - } - if cc != lccc { - if cc != 0 { - log.Fatalf("%U: for lccc != ccc, expected ccc to be 0; was %d", r, cc) - } - index = firstCCCZeroExcept - } - } else if len(d) > 1 { - index = firstMulti - } - return index, s - } - - decompSet := makeDecompSet() - const nLeadStr = "\x00\x01" // 0-byte length and tccc with nTrail. - decompSet.insert(firstStarterWithNLead, nLeadStr) - - // Store the uniqued decompositions in a byte buffer, - // preceded by their byte length. - for _, c := range chars { - for _, f := range c.forms { - if len(f.expandedDecomp) == 0 { - continue - } - if f.combinesBackward { - log.Fatalf("%U: combinesBackward and decompose", c.codePoint) - } - index, s := mkstr(c.codePoint, &f) - decompSet.insert(index, s) - } - } - - decompositions := bytes.NewBuffer(make([]byte, 0, 10000)) - size := 0 - positionMap := make(map[string]uint16) - decompositions.WriteString("\000") - fmt.Fprintln(w, "const (") - for i, m := range decompSet { - sa := []string{} - for s := range m { - sa = append(sa, s) - } - sort.Strings(sa) - for _, s := range sa { - p := decompositions.Len() - decompositions.WriteString(s) - positionMap[s] = uint16(p) - } - if cname[i] != "" { - fmt.Fprintf(w, "%s = 0x%X\n", cname[i], decompositions.Len()) - } - } - fmt.Fprintln(w, "maxDecomp = 0x8000") - fmt.Fprintln(w, ")") - b := decompositions.Bytes() - printBytes(w, b, "decomps") - size += len(b) - - varnames := []string{"nfc", "nfkc"} - for i := 0; i < FNumberOfFormTypes; i++ { - trie := triegen.NewTrie(varnames[i]) - - for r, c := range chars { - f := c.forms[i] - d := f.expandedDecomp - if len(d) != 0 { - _, key := mkstr(c.codePoint, &f) - trie.Insert(rune(r), uint64(positionMap[key])) - if c.ccc != ccc(d[0]) { - // We assume the lead ccc of a decomposition !=0 in this case. - if ccc(d[0]) == 0 { - log.Fatalf("Expected leading CCC to be non-zero; ccc is %d", c.ccc) - } - } - } else if c.nLeadingNonStarters > 0 && len(f.expandedDecomp) == 0 && c.ccc == 0 && !f.combinesBackward { - // Handle cases where it can't be detected that the nLead should be equal - // to nTrail. - trie.Insert(c.codePoint, uint64(positionMap[nLeadStr])) - } else if v := makeEntry(&f, &c)<<8 | uint16(c.ccc); v != 0 { - trie.Insert(c.codePoint, uint64(0x8000|v)) - } - } - sz, err := trie.Gen(w, triegen.Compact(&normCompacter{name: varnames[i]})) - if err != nil { - log.Fatal(err) - } - size += sz - } - return size -} - -func contains(sa []string, s string) bool { - for _, a := range sa { - if a == s { - return true - } - } - return false -} - -func makeTables() { - w := &bytes.Buffer{} - - size := 0 - if *tablelist == "" { - return - } - list := strings.Split(*tablelist, ",") - if *tablelist == "all" { - list = []string{"recomp", "info"} - } - - // Compute maximum decomposition size. - max := 0 - for _, c := range chars { - if n := len(string(c.forms[FCompatibility].expandedDecomp)); n > max { - max = n - } - } - - fmt.Fprintln(w, "const (") - fmt.Fprintln(w, "\t// Version is the Unicode edition from which the tables are derived.") - fmt.Fprintf(w, "\tVersion = %q\n", gen.UnicodeVersion()) - fmt.Fprintln(w) - fmt.Fprintln(w, "\t// MaxTransformChunkSize indicates the maximum number of bytes that Transform") - fmt.Fprintln(w, "\t// may need to write atomically for any Form. Making a destination buffer at") - fmt.Fprintln(w, "\t// least this size ensures that Transform can always make progress and that") - fmt.Fprintln(w, "\t// the user does not need to grow the buffer on an ErrShortDst.") - fmt.Fprintf(w, "\tMaxTransformChunkSize = %d+maxNonStarters*4\n", len(string(0x034F))+max) - fmt.Fprintln(w, ")\n") - - // Print the CCC remap table. - size += len(cccMap) - fmt.Fprintf(w, "var ccc = [%d]uint8{", len(cccMap)) - for i := 0; i < len(cccMap); i++ { - if i%8 == 0 { - fmt.Fprintln(w) - } - fmt.Fprintf(w, "%3d, ", cccMap[uint8(i)]) - } - fmt.Fprintln(w, "\n}\n") - - if contains(list, "info") { - size += printCharInfoTables(w) - } - - if contains(list, "recomp") { - // Note that we use 32 bit keys, instead of 64 bit. - // This clips the bits of three entries, but we know - // this won't cause a collision. The compiler will catch - // any changes made to UnicodeData.txt that introduces - // a collision. - // Note that the recomposition map for NFC and NFKC - // are identical. - - // Recomposition map - nrentries := 0 - for _, c := range chars { - f := c.forms[FCanonical] - if !f.isOneWay && len(f.decomp) > 0 { - nrentries++ - } - } - sz := nrentries * 8 - size += sz - fmt.Fprintf(w, "// recompMap: %d bytes (entries only)\n", sz) - fmt.Fprintln(w, "var recompMap = map[uint32]rune{") - for i, c := range chars { - f := c.forms[FCanonical] - d := f.decomp - if !f.isOneWay && len(d) > 0 { - key := uint32(uint16(d[0]))<<16 + uint32(uint16(d[1])) - fmt.Fprintf(w, "0x%.8X: 0x%.4X,\n", key, i) - } - } - fmt.Fprintf(w, "}\n\n") - } - - fmt.Fprintf(w, "// Total size of tables: %dKB (%d bytes)\n", (size+512)/1024, size) - gen.WriteVersionedGoFile("tables.go", "norm", w.Bytes()) -} - -func printChars() { - if *verbose { - for _, c := range chars { - if !c.isValid() || c.state == SMissing { - continue - } - fmt.Println(c) - } - } -} - -// verifyComputed does various consistency tests. -func verifyComputed() { - for i, c := range chars { - for _, f := range c.forms { - isNo := (f.quickCheck[MDecomposed] == QCNo) - if (len(f.decomp) > 0) != isNo && !isHangul(rune(i)) { - log.Fatalf("%U: NF*D QC must be No if rune decomposes", i) - } - - isMaybe := f.quickCheck[MComposed] == QCMaybe - if f.combinesBackward != isMaybe { - log.Fatalf("%U: NF*C QC must be Maybe if combinesBackward", i) - } - if len(f.decomp) > 0 && f.combinesForward && isMaybe { - log.Fatalf("%U: NF*C QC must be Yes or No if combinesForward and decomposes", i) - } - - if len(f.expandedDecomp) != 0 { - continue - } - if a, b := c.nLeadingNonStarters > 0, (c.ccc > 0 || f.combinesBackward); a != b { - // We accept these runes to be treated differently (it only affects - // segment breaking in iteration, most likely on improper use), but - // reconsider if more characters are added. - // U+FF9E HALFWIDTH KATAKANA VOICED SOUND MARK;Lm;0;L; 3099;;;;N;;;;; - // U+FF9F HALFWIDTH KATAKANA SEMI-VOICED SOUND MARK;Lm;0;L; 309A;;;;N;;;;; - // U+3133 HANGUL LETTER KIYEOK-SIOS;Lo;0;L; 11AA;;;;N;HANGUL LETTER GIYEOG SIOS;;;; - // U+318E HANGUL LETTER ARAEAE;Lo;0;L; 11A1;;;;N;HANGUL LETTER ALAE AE;;;; - // U+FFA3 HALFWIDTH HANGUL LETTER KIYEOK-SIOS;Lo;0;L; 3133;;;;N;HALFWIDTH HANGUL LETTER GIYEOG SIOS;;;; - // U+FFDC HALFWIDTH HANGUL LETTER I;Lo;0;L; 3163;;;;N;;;;; - if i != 0xFF9E && i != 0xFF9F && !(0x3133 <= i && i <= 0x318E) && !(0xFFA3 <= i && i <= 0xFFDC) { - log.Fatalf("%U: nLead was %v; want %v", i, a, b) - } - } - } - nfc := c.forms[FCanonical] - nfkc := c.forms[FCompatibility] - if nfc.combinesBackward != nfkc.combinesBackward { - log.Fatalf("%U: Cannot combine combinesBackward\n", c.codePoint) - } - } -} - -// Use values in DerivedNormalizationProps.txt to compare against the -// values we computed. -// DerivedNormalizationProps.txt has form: -// 00C0..00C5 ; NFD_QC; N # ... -// 0374 ; NFD_QC; N # ... -// See http://unicode.org/reports/tr44/ for full explanation -func testDerived() { - f := gen.OpenUCDFile("DerivedNormalizationProps.txt") - defer f.Close() - p := ucd.New(f) - for p.Next() { - r := p.Rune(0) - c := &chars[r] - - var ftype, mode int - qt := p.String(1) - switch qt { - case "NFC_QC": - ftype, mode = FCanonical, MComposed - case "NFD_QC": - ftype, mode = FCanonical, MDecomposed - case "NFKC_QC": - ftype, mode = FCompatibility, MComposed - case "NFKD_QC": - ftype, mode = FCompatibility, MDecomposed - default: - continue - } - var qr QCResult - switch p.String(2) { - case "Y": - qr = QCYes - case "N": - qr = QCNo - case "M": - qr = QCMaybe - default: - log.Fatalf(`Unexpected quick check value "%s"`, p.String(2)) - } - if got := c.forms[ftype].quickCheck[mode]; got != qr { - log.Printf("%U: FAILED %s (was %v need %v)\n", r, qt, got, qr) - } - c.forms[ftype].verified[mode] = true - } - if err := p.Err(); err != nil { - log.Fatal(err) - } - // Any unspecified value must be QCYes. Verify this. - for i, c := range chars { - for j, fd := range c.forms { - for k, qr := range fd.quickCheck { - if !fd.verified[k] && qr != QCYes { - m := "%U: FAIL F:%d M:%d (was %v need Yes) %s\n" - log.Printf(m, i, j, k, qr, c.name) - } - } - } - } -} - -var testHeader = `const ( - Yes = iota - No - Maybe -) - -type formData struct { - qc uint8 - combinesForward bool - decomposition string -} - -type runeData struct { - r rune - ccc uint8 - nLead uint8 - nTrail uint8 - f [2]formData // 0: canonical; 1: compatibility -} - -func f(qc uint8, cf bool, dec string) [2]formData { - return [2]formData{{qc, cf, dec}, {qc, cf, dec}} -} - -func g(qc, qck uint8, cf, cfk bool, d, dk string) [2]formData { - return [2]formData{{qc, cf, d}, {qck, cfk, dk}} -} - -var testData = []runeData{ -` - -func printTestdata() { - type lastInfo struct { - ccc uint8 - nLead uint8 - nTrail uint8 - f string - } - - last := lastInfo{} - w := &bytes.Buffer{} - fmt.Fprintf(w, testHeader) - for r, c := range chars { - f := c.forms[FCanonical] - qc, cf, d := f.quickCheck[MComposed], f.combinesForward, string(f.expandedDecomp) - f = c.forms[FCompatibility] - qck, cfk, dk := f.quickCheck[MComposed], f.combinesForward, string(f.expandedDecomp) - s := "" - if d == dk && qc == qck && cf == cfk { - s = fmt.Sprintf("f(%s, %v, %q)", qc, cf, d) - } else { - s = fmt.Sprintf("g(%s, %s, %v, %v, %q, %q)", qc, qck, cf, cfk, d, dk) - } - current := lastInfo{c.ccc, c.nLeadingNonStarters, c.nTrailingNonStarters, s} - if last != current { - fmt.Fprintf(w, "\t{0x%x, %d, %d, %d, %s},\n", r, c.origCCC, c.nLeadingNonStarters, c.nTrailingNonStarters, s) - last = current - } - } - fmt.Fprintln(w, "}") - gen.WriteVersionedGoFile("data_test.go", "norm", w.Bytes()) -} diff --git a/vendor/golang.org/x/text/unicode/norm/triegen.go b/vendor/golang.org/x/text/unicode/norm/triegen.go deleted file mode 100644 index 45d711900d144f5e66fb29941c1a8700049ab0c9..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/unicode/norm/triegen.go +++ /dev/null @@ -1,117 +0,0 @@ -// Copyright 2011 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -// Trie table generator. -// Used by make*tables tools to generate a go file with trie data structures -// for mapping UTF-8 to a 16-bit value. All but the last byte in a UTF-8 byte -// sequence are used to lookup offsets in the index table to be used for the -// next byte. The last byte is used to index into a table with 16-bit values. - -package main - -import ( - "fmt" - "io" -) - -const maxSparseEntries = 16 - -type normCompacter struct { - sparseBlocks [][]uint64 - sparseOffset []uint16 - sparseCount int - name string -} - -func mostFrequentStride(a []uint64) int { - counts := make(map[int]int) - var v int - for _, x := range a { - if stride := int(x) - v; v != 0 && stride >= 0 { - counts[stride]++ - } - v = int(x) - } - var maxs, maxc int - for stride, cnt := range counts { - if cnt > maxc || (cnt == maxc && stride < maxs) { - maxs, maxc = stride, cnt - } - } - return maxs -} - -func countSparseEntries(a []uint64) int { - stride := mostFrequentStride(a) - var v, count int - for _, tv := range a { - if int(tv)-v != stride { - if tv != 0 { - count++ - } - } - v = int(tv) - } - return count -} - -func (c *normCompacter) Size(v []uint64) (sz int, ok bool) { - if n := countSparseEntries(v); n <= maxSparseEntries { - return (n+1)*4 + 2, true - } - return 0, false -} - -func (c *normCompacter) Store(v []uint64) uint32 { - h := uint32(len(c.sparseOffset)) - c.sparseBlocks = append(c.sparseBlocks, v) - c.sparseOffset = append(c.sparseOffset, uint16(c.sparseCount)) - c.sparseCount += countSparseEntries(v) + 1 - return h -} - -func (c *normCompacter) Handler() string { - return c.name + "Sparse.lookup" -} - -func (c *normCompacter) Print(w io.Writer) (retErr error) { - p := func(f string, x ...interface{}) { - if _, err := fmt.Fprintf(w, f, x...); retErr == nil && err != nil { - retErr = err - } - } - - ls := len(c.sparseBlocks) - p("// %sSparseOffset: %d entries, %d bytes\n", c.name, ls, ls*2) - p("var %sSparseOffset = %#v\n\n", c.name, c.sparseOffset) - - ns := c.sparseCount - p("// %sSparseValues: %d entries, %d bytes\n", c.name, ns, ns*4) - p("var %sSparseValues = [%d]valueRange {", c.name, ns) - for i, b := range c.sparseBlocks { - p("\n// Block %#x, offset %#x", i, c.sparseOffset[i]) - var v int - stride := mostFrequentStride(b) - n := countSparseEntries(b) - p("\n{value:%#04x,lo:%#02x},", stride, uint8(n)) - for i, nv := range b { - if int(nv)-v != stride { - if v != 0 { - p(",hi:%#02x},", 0x80+i-1) - } - if nv != 0 { - p("\n{value:%#04x,lo:%#02x", nv, 0x80+i) - } - } - v = int(nv) - } - if v != 0 { - p(",hi:%#02x},", 0x80+len(b)-1) - } - } - p("\n}\n\n") - return -} diff --git a/vendor/golang.org/x/text/width/gen.go b/vendor/golang.org/x/text/width/gen.go deleted file mode 100644 index 092277e1f64b96a3475d9b4036d93ad9b0f00610..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/width/gen.go +++ /dev/null @@ -1,115 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -// This program generates the trie for width operations. The generated table -// includes width category information as well as the normalization mappings. -package main - -import ( - "bytes" - "fmt" - "io" - "log" - "math" - "unicode/utf8" - - "golang.org/x/text/internal/gen" - "golang.org/x/text/internal/triegen" -) - -// See gen_common.go for flags. - -func main() { - gen.Init() - genTables() - genTests() - gen.Repackage("gen_trieval.go", "trieval.go", "width") - gen.Repackage("gen_common.go", "common_test.go", "width") -} - -func genTables() { - t := triegen.NewTrie("width") - // fold and inverse mappings. See mapComment for a description of the format - // of each entry. Add dummy value to make an index of 0 mean no mapping. - inverse := [][4]byte{{}} - mapping := map[[4]byte]int{[4]byte{}: 0} - - getWidthData(func(r rune, tag elem, alt rune) { - idx := 0 - if alt != 0 { - var buf [4]byte - buf[0] = byte(utf8.EncodeRune(buf[1:], alt)) - s := string(r) - buf[buf[0]] ^= s[len(s)-1] - var ok bool - if idx, ok = mapping[buf]; !ok { - idx = len(mapping) - if idx > math.MaxUint8 { - log.Fatalf("Index %d does not fit in a byte.", idx) - } - mapping[buf] = idx - inverse = append(inverse, buf) - } - } - t.Insert(r, uint64(tag|elem(idx))) - }) - - w := &bytes.Buffer{} - gen.WriteUnicodeVersion(w) - - sz, err := t.Gen(w) - if err != nil { - log.Fatal(err) - } - - sz += writeMappings(w, inverse) - - fmt.Fprintf(w, "// Total table size %d bytes (%dKiB)\n", sz, sz/1024) - - gen.WriteVersionedGoFile(*outputFile, "width", w.Bytes()) -} - -const inverseDataComment = ` -// inverseData contains 4-byte entries of the following format: -// <0 padding> -// The last byte of the UTF-8-encoded rune is xor-ed with the last byte of the -// UTF-8 encoding of the original rune. Mappings often have the following -// pattern: -// A -> A (U+FF21 -> U+0041) -// ï¼¢ -> B (U+FF22 -> U+0042) -// ... -// By xor-ing the last byte the same entry can be shared by many mappings. This -// reduces the total number of distinct entries by about two thirds. -// The resulting entry for the aforementioned mappings is -// { 0x01, 0xE0, 0x00, 0x00 } -// Using this entry to map U+FF21 (UTF-8 [EF BC A1]), we get -// E0 ^ A1 = 41. -// Similarly, for U+FF22 (UTF-8 [EF BC A2]), we get -// E0 ^ A2 = 42. -// Note that because of the xor-ing, the byte sequence stored in the entry is -// not valid UTF-8.` - -func writeMappings(w io.Writer, data [][4]byte) int { - fmt.Fprintln(w, inverseDataComment) - fmt.Fprintf(w, "var inverseData = [%d][4]byte{\n", len(data)) - for _, x := range data { - fmt.Fprintf(w, "{ 0x%02x, 0x%02x, 0x%02x, 0x%02x },\n", x[0], x[1], x[2], x[3]) - } - fmt.Fprintln(w, "}") - return len(data) * 4 -} - -func genTests() { - w := &bytes.Buffer{} - fmt.Fprintf(w, "\nvar mapRunes = map[rune]struct{r rune; e elem}{\n") - getWidthData(func(r rune, tag elem, alt rune) { - if alt != 0 { - fmt.Fprintf(w, "\t0x%X: {0x%X, 0x%X},\n", r, alt, tag) - } - }) - fmt.Fprintln(w, "}") - gen.WriteGoFile("runes_test.go", "width", w.Bytes()) -} diff --git a/vendor/golang.org/x/text/width/gen_common.go b/vendor/golang.org/x/text/width/gen_common.go deleted file mode 100644 index 601e752684302d82835c5ac385155d339015177a..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/width/gen_common.go +++ /dev/null @@ -1,96 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -// This code is shared between the main code generator and the test code. - -import ( - "flag" - "log" - "strconv" - "strings" - - "golang.org/x/text/internal/gen" - "golang.org/x/text/internal/ucd" -) - -var ( - outputFile = flag.String("out", "tables.go", "output file") -) - -var typeMap = map[string]elem{ - "A": tagAmbiguous, - "N": tagNeutral, - "Na": tagNarrow, - "W": tagWide, - "F": tagFullwidth, - "H": tagHalfwidth, -} - -// getWidthData calls f for every entry for which it is defined. -// -// f may be called multiple times for the same rune. The last call to f is the -// correct value. f is not called for all runes. The default tag type is -// Neutral. -func getWidthData(f func(r rune, tag elem, alt rune)) { - // Set the default values for Unified Ideographs. In line with Annex 11, - // we encode full ranges instead of the defined runes in Unified_Ideograph. - for _, b := range []struct{ lo, hi rune }{ - {0x4E00, 0x9FFF}, // the CJK Unified Ideographs block, - {0x3400, 0x4DBF}, // the CJK Unified Ideographs Externsion A block, - {0xF900, 0xFAFF}, // the CJK Compatibility Ideographs block, - {0x20000, 0x2FFFF}, // the Supplementary Ideographic Plane, - {0x30000, 0x3FFFF}, // the Tertiary Ideographic Plane, - } { - for r := b.lo; r <= b.hi; r++ { - f(r, tagWide, 0) - } - } - - inverse := map[rune]rune{} - maps := map[string]bool{ - "": true, - "": true, - } - - // We cannot reuse package norm's decomposition, as we need an unexpanded - // decomposition. We make use of the opportunity to verify that the - // decomposition type is as expected. - ucd.Parse(gen.OpenUCDFile("UnicodeData.txt"), func(p *ucd.Parser) { - r := p.Rune(0) - s := strings.SplitN(p.String(ucd.DecompMapping), " ", 2) - if !maps[s[0]] { - return - } - x, err := strconv.ParseUint(s[1], 16, 32) - if err != nil { - log.Fatalf("Error parsing rune %q", s[1]) - } - if inverse[r] != 0 || inverse[rune(x)] != 0 { - log.Fatalf("Circular dependency in mapping between %U and %U", r, x) - } - inverse[r] = rune(x) - inverse[rune(x)] = r - }) - - // ; - ucd.Parse(gen.OpenUCDFile("EastAsianWidth.txt"), func(p *ucd.Parser) { - tag, ok := typeMap[p.String(1)] - if !ok { - log.Fatalf("Unknown width type %q", p.String(1)) - } - r := p.Rune(0) - alt, ok := inverse[r] - if tag == tagFullwidth || tag == tagHalfwidth && r != wonSign { - tag |= tagNeedsFold - if !ok { - log.Fatalf("Narrow or wide rune %U has no decomposition", r) - } - } - f(r, tag, alt) - }) -} diff --git a/vendor/golang.org/x/text/width/gen_trieval.go b/vendor/golang.org/x/text/width/gen_trieval.go deleted file mode 100644 index c17334aa618d9516c2b23a9efdb801538938aa3f..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/text/width/gen_trieval.go +++ /dev/null @@ -1,34 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -package main - -// elem is an entry of the width trie. The high byte is used to encode the type -// of the rune. The low byte is used to store the index to a mapping entry in -// the inverseData array. -type elem uint16 - -const ( - tagNeutral elem = iota << typeShift - tagAmbiguous - tagWide - tagNarrow - tagFullwidth - tagHalfwidth -) - -const ( - numTypeBits = 3 - typeShift = 16 - numTypeBits - - // tagNeedsFold is true for all fullwidth and halfwidth runes except for - // the Won sign U+20A9. - tagNeedsFold = 0x1000 - - // The Korean Won sign is halfwidth, but SHOULD NOT be mapped to a wide - // variant. - wonSign rune = 0x20A9 -) diff --git a/vendor/golang.org/x/tools/go/gcexportdata/main.go b/vendor/golang.org/x/tools/go/gcexportdata/main.go deleted file mode 100644 index 2713dce64a9bf2c427953e3f62d68152740c356a..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/tools/go/gcexportdata/main.go +++ /dev/null @@ -1,99 +0,0 @@ -// Copyright 2017 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build ignore - -// The gcexportdata command is a diagnostic tool that displays the -// contents of gc export data files. -package main - -import ( - "flag" - "fmt" - "go/token" - "go/types" - "log" - "os" - - "golang.org/x/tools/go/gcexportdata" - "golang.org/x/tools/go/types/typeutil" -) - -var packageFlag = flag.String("package", "", "alternative package to print") - -func main() { - log.SetPrefix("gcexportdata: ") - log.SetFlags(0) - flag.Usage = func() { - fmt.Fprintln(os.Stderr, "usage: gcexportdata [-package path] file.a") - } - flag.Parse() - if flag.NArg() != 1 { - flag.Usage() - os.Exit(2) - } - filename := flag.Args()[0] - - f, err := os.Open(filename) - if err != nil { - log.Fatal(err) - } - - r, err := gcexportdata.NewReader(f) - if err != nil { - log.Fatalf("%s: %s", filename, err) - } - - // Decode the package. - const primary = "" - imports := make(map[string]*types.Package) - fset := token.NewFileSet() - pkg, err := gcexportdata.Read(r, fset, imports, primary) - if err != nil { - log.Fatalf("%s: %s", filename, err) - } - - // Optionally select an indirectly mentioned package. - if *packageFlag != "" { - pkg = imports[*packageFlag] - if pkg == nil { - fmt.Fprintf(os.Stderr, "export data file %s does not mention %s; has:\n", - filename, *packageFlag) - for p := range imports { - if p != primary { - fmt.Fprintf(os.Stderr, "\t%s\n", p) - } - } - os.Exit(1) - } - } - - // Print all package-level declarations, including non-exported ones. - fmt.Printf("package %s\n", pkg.Name()) - for _, imp := range pkg.Imports() { - fmt.Printf("import %q\n", imp.Path()) - } - qual := func(p *types.Package) string { - if pkg == p { - return "" - } - return p.Name() - } - scope := pkg.Scope() - for _, name := range scope.Names() { - obj := scope.Lookup(name) - fmt.Printf("%s: %s\n", - fset.Position(obj.Pos()), - types.ObjectString(obj, qual)) - - // For types, print each method. - if _, ok := obj.(*types.TypeName); ok { - for _, method := range typeutil.IntuitiveMethodSet(obj.Type(), nil) { - fmt.Printf("%s: %s\n", - fset.Position(method.Obj().Pos()), - types.SelectionString(method, qual)) - } - } - } -} diff --git a/vendor/golang.org/x/tools/internal/imports/mkindex.go b/vendor/golang.org/x/tools/internal/imports/mkindex.go deleted file mode 100644 index ef8c0d2871f87dfc9ee41855576b0f0ac82a1513..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/tools/internal/imports/mkindex.go +++ /dev/null @@ -1,173 +0,0 @@ -// +build ignore - -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Command mkindex creates the file "pkgindex.go" containing an index of the Go -// standard library. The file is intended to be built as part of the imports -// package, so that the package may be used in environments where a GOROOT is -// not available (such as App Engine). -package imports - -import ( - "bytes" - "fmt" - "go/ast" - "go/build" - "go/format" - "go/parser" - "go/token" - "io/ioutil" - "log" - "os" - "path" - "path/filepath" - "strings" -) - -var ( - pkgIndex = make(map[string][]pkg) - exports = make(map[string]map[string]bool) -) - -func main() { - // Don't use GOPATH. - ctx := build.Default - ctx.GOPATH = "" - - // Populate pkgIndex global from GOROOT. - for _, path := range ctx.SrcDirs() { - f, err := os.Open(path) - if err != nil { - log.Print(err) - continue - } - children, err := f.Readdir(-1) - f.Close() - if err != nil { - log.Print(err) - continue - } - for _, child := range children { - if child.IsDir() { - loadPkg(path, child.Name()) - } - } - } - // Populate exports global. - for _, ps := range pkgIndex { - for _, p := range ps { - e := loadExports(p.dir) - if e != nil { - exports[p.dir] = e - } - } - } - - // Construct source file. - var buf bytes.Buffer - fmt.Fprint(&buf, pkgIndexHead) - fmt.Fprintf(&buf, "var pkgIndexMaster = %#v\n", pkgIndex) - fmt.Fprintf(&buf, "var exportsMaster = %#v\n", exports) - src := buf.Bytes() - - // Replace main.pkg type name with pkg. - src = bytes.Replace(src, []byte("main.pkg"), []byte("pkg"), -1) - // Replace actual GOROOT with "/go". - src = bytes.Replace(src, []byte(ctx.GOROOT), []byte("/go"), -1) - // Add some line wrapping. - src = bytes.Replace(src, []byte("}, "), []byte("},\n"), -1) - src = bytes.Replace(src, []byte("true, "), []byte("true,\n"), -1) - - var err error - src, err = format.Source(src) - if err != nil { - log.Fatal(err) - } - - // Write out source file. - err = ioutil.WriteFile("pkgindex.go", src, 0644) - if err != nil { - log.Fatal(err) - } -} - -const pkgIndexHead = `package imports - -func init() { - pkgIndexOnce.Do(func() { - pkgIndex.m = pkgIndexMaster - }) - loadExports = func(dir string) map[string]bool { - return exportsMaster[dir] - } -} -` - -type pkg struct { - importpath string // full pkg import path, e.g. "net/http" - dir string // absolute file path to pkg directory e.g. "/usr/lib/go/src/fmt" -} - -var fset = token.NewFileSet() - -func loadPkg(root, importpath string) { - shortName := path.Base(importpath) - if shortName == "testdata" { - return - } - - dir := filepath.Join(root, importpath) - pkgIndex[shortName] = append(pkgIndex[shortName], pkg{ - importpath: importpath, - dir: dir, - }) - - pkgDir, err := os.Open(dir) - if err != nil { - return - } - children, err := pkgDir.Readdir(-1) - pkgDir.Close() - if err != nil { - return - } - for _, child := range children { - name := child.Name() - if name == "" { - continue - } - if c := name[0]; c == '.' || ('0' <= c && c <= '9') { - continue - } - if child.IsDir() { - loadPkg(root, filepath.Join(importpath, name)) - } - } -} - -func loadExports(dir string) map[string]bool { - exports := make(map[string]bool) - buildPkg, err := build.ImportDir(dir, 0) - if err != nil { - if strings.Contains(err.Error(), "no buildable Go source files in") { - return nil - } - log.Printf("could not import %q: %v", dir, err) - return nil - } - for _, file := range buildPkg.GoFiles { - f, err := parser.ParseFile(fset, filepath.Join(dir, file), nil, 0) - if err != nil { - log.Printf("could not parse %q: %v", file, err) - continue - } - for name := range f.Scope.Objects { - if ast.IsExported(name) { - exports[name] = true - } - } - } - return exports -} diff --git a/vendor/golang.org/x/tools/internal/imports/mkstdlib.go b/vendor/golang.org/x/tools/internal/imports/mkstdlib.go deleted file mode 100644 index f67b5c1edb768fcfd79ea9ba7aad04a934041ec4..0000000000000000000000000000000000000000 --- a/vendor/golang.org/x/tools/internal/imports/mkstdlib.go +++ /dev/null @@ -1,132 +0,0 @@ -// +build ignore - -// mkstdlib generates the zstdlib.go file, containing the Go standard -// library API symbols. It's baked into the binary to avoid scanning -// GOPATH in the common case. -package imports - -import ( - "bufio" - "bytes" - "fmt" - "go/format" - "io" - "io/ioutil" - "log" - "os" - "os/exec" - "path/filepath" - "regexp" - "runtime" - "sort" - "strings" -) - -func mustOpen(name string) io.Reader { - f, err := os.Open(name) - if err != nil { - log.Fatal(err) - } - return f -} - -func api(base string) string { - return filepath.Join(runtime.GOROOT(), "api", base) -} - -var sym = regexp.MustCompile(`^pkg (\S+).*?, (?:var|func|type|const) ([A-Z]\w*)`) - -var unsafeSyms = map[string]bool{"Alignof": true, "ArbitraryType": true, "Offsetof": true, "Pointer": true, "Sizeof": true} - -func main() { - var buf bytes.Buffer - outf := func(format string, args ...interface{}) { - fmt.Fprintf(&buf, format, args...) - } - outf("// Code generated by mkstdlib.go. DO NOT EDIT.\n\n") - outf("package imports\n") - outf("var stdlib = map[string]map[string]bool{\n") - f := io.MultiReader( - mustOpen(api("go1.txt")), - mustOpen(api("go1.1.txt")), - mustOpen(api("go1.2.txt")), - mustOpen(api("go1.3.txt")), - mustOpen(api("go1.4.txt")), - mustOpen(api("go1.5.txt")), - mustOpen(api("go1.6.txt")), - mustOpen(api("go1.7.txt")), - mustOpen(api("go1.8.txt")), - mustOpen(api("go1.9.txt")), - mustOpen(api("go1.10.txt")), - mustOpen(api("go1.11.txt")), - mustOpen(api("go1.12.txt")), - - // The API of the syscall/js package needs to be computed explicitly, - // because it's not included in the GOROOT/api/go1.*.txt files at this time. - syscallJSAPI(), - ) - sc := bufio.NewScanner(f) - - pkgs := map[string]map[string]bool{ - "unsafe": unsafeSyms, - } - paths := []string{"unsafe"} - - for sc.Scan() { - l := sc.Text() - has := func(v string) bool { return strings.Contains(l, v) } - if has("struct, ") || has("interface, ") || has(", method (") { - continue - } - if m := sym.FindStringSubmatch(l); m != nil { - path, sym := m[1], m[2] - - if _, ok := pkgs[path]; !ok { - pkgs[path] = map[string]bool{} - paths = append(paths, path) - } - pkgs[path][sym] = true - } - } - if err := sc.Err(); err != nil { - log.Fatal(err) - } - sort.Strings(paths) - for _, path := range paths { - outf("\t%q: map[string]bool{\n", path) - pkg := pkgs[path] - var syms []string - for sym := range pkg { - syms = append(syms, sym) - } - sort.Strings(syms) - for _, sym := range syms { - outf("\t\t%q: true,\n", sym) - } - outf("},\n") - } - outf("}\n") - fmtbuf, err := format.Source(buf.Bytes()) - if err != nil { - log.Fatal(err) - } - err = ioutil.WriteFile("zstdlib.go", fmtbuf, 0666) - if err != nil { - log.Fatal(err) - } -} - -// syscallJSAPI returns the API of the syscall/js package. -// It's computed from the contents of $(go env GOROOT)/src/syscall/js. -func syscallJSAPI() io.Reader { - var exeSuffix string - if runtime.GOOS == "windows" { - exeSuffix = ".exe" - } - cmd := exec.Command("go"+exeSuffix, "run", "cmd/api", "-contexts", "js-wasm", "syscall/js") - out, err := cmd.Output() - if err != nil { - log.Fatalln(err) - } - return bytes.NewReader(out) -} diff --git a/vendor/modules.txt b/vendor/modules.txt index ce60fe37234eac70b3a84a3df097c16197ef662b..e624d94a1aa7ea79196e327b24acfea3af6636f2 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -26,7 +26,7 @@ github.com/alecthomas/units github.com/andybalholm/cascadia # github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a => github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a github.com/asaskevich/govalidator -# github.com/aws/aws-sdk-go v1.22.2 => github.com/aws/aws-sdk-go v1.22.2 +# github.com/aws/aws-sdk-go v1.25.21 => github.com/aws/aws-sdk-go v1.22.2 github.com/aws/aws-sdk-go/aws github.com/aws/aws-sdk-go/aws/awserr github.com/aws/aws-sdk-go/aws/awsutil @@ -110,11 +110,11 @@ github.com/docker/docker/client github.com/docker/docker/errdefs github.com/docker/docker/pkg/term github.com/docker/docker/pkg/term/windows -# github.com/docker/go-connections v0.3.0 => github.com/docker/go-connections v0.3.0 +# github.com/docker/go-connections v0.4.0 => github.com/docker/go-connections v0.3.0 github.com/docker/go-connections/nat github.com/docker/go-connections/sockets github.com/docker/go-connections/tlsconfig -# github.com/docker/go-units v0.3.3 => github.com/docker/go-units v0.3.3 +# github.com/docker/go-units v0.4.0 => github.com/docker/go-units v0.3.3 github.com/docker/go-units # github.com/docker/spdystream v0.0.0-20181023171402-6480d4af844c => github.com/docker/spdystream v0.0.0-20181023171402-6480d4af844c github.com/docker/spdystream @@ -134,7 +134,7 @@ github.com/elastic/go-elasticsearch/v7 github.com/elastic/go-elasticsearch/v7/esapi github.com/elastic/go-elasticsearch/v7/estransport github.com/elastic/go-elasticsearch/v7/internal/version -# github.com/emicklei/go-restful v2.9.5+incompatible => github.com/emicklei/go-restful v2.9.5+incompatible +# github.com/emicklei/go-restful v2.11.1+incompatible => github.com/emicklei/go-restful v2.9.5+incompatible github.com/emicklei/go-restful # github.com/emicklei/go-restful-openapi v1.0.0 => github.com/emicklei/go-restful-openapi v1.0.0 github.com/emicklei/go-restful-openapi @@ -176,9 +176,9 @@ github.com/go-openapi/jsonpointer github.com/go-openapi/jsonreference # github.com/go-openapi/loads v0.19.2 => github.com/go-openapi/loads v0.19.2 github.com/go-openapi/loads -# github.com/go-openapi/runtime v0.19.0 => github.com/go-openapi/runtime v0.19.0 +# github.com/go-openapi/runtime v0.19.7 => github.com/go-openapi/runtime v0.19.0 github.com/go-openapi/runtime -# github.com/go-openapi/spec v0.19.3 => github.com/go-openapi/spec v0.19.3 +# github.com/go-openapi/spec v0.19.4 => github.com/go-openapi/spec v0.19.3 github.com/go-openapi/spec # github.com/go-openapi/strfmt v0.19.3 => github.com/go-openapi/strfmt v0.19.0 github.com/go-openapi/strfmt @@ -210,7 +210,7 @@ github.com/gobwas/glob/util/strings # github.com/gocraft/dbr v0.0.0-20180507214907-a0fd650918f6 => github.com/gocraft/dbr v0.0.0-20180507214907-a0fd650918f6 github.com/gocraft/dbr github.com/gocraft/dbr/dialect -# github.com/gogo/protobuf v1.3.0 => github.com/gogo/protobuf v1.3.0 +# github.com/gogo/protobuf v1.3.1 => github.com/gogo/protobuf v1.3.0 github.com/gogo/protobuf/gogoproto github.com/gogo/protobuf/jsonpb github.com/gogo/protobuf/proto @@ -221,17 +221,15 @@ github.com/gogo/protobuf/types github.com/golang/example/stringutil # github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b => github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b github.com/golang/glog -# github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6 => github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6 +# github.com/golang/groupcache v0.0.0-20191027212112-611e8accdfc9 => github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6 github.com/golang/groupcache/lru # github.com/golang/mock v1.2.0 => github.com/golang/mock v1.2.0 github.com/golang/mock/gomock # github.com/golang/protobuf v1.3.2 => github.com/golang/protobuf v1.3.2 +github.com/golang/protobuf/descriptor github.com/golang/protobuf/jsonpb github.com/golang/protobuf/proto github.com/golang/protobuf/protoc-gen-go/descriptor -github.com/golang/protobuf/protoc-gen-go/generator -github.com/golang/protobuf/protoc-gen-go/generator/internal/remap -github.com/golang/protobuf/protoc-gen-go/plugin github.com/golang/protobuf/ptypes github.com/golang/protobuf/ptypes/any github.com/golang/protobuf/ptypes/duration @@ -259,15 +257,15 @@ github.com/googleapis/gnostic/compiler github.com/googleapis/gnostic/extensions # github.com/gorilla/mux v1.7.1 => github.com/gorilla/mux v1.7.1 github.com/gorilla/mux -# github.com/gorilla/websocket v1.4.0 => github.com/gorilla/websocket v1.4.0 +# github.com/gorilla/websocket v1.4.1 => github.com/gorilla/websocket v1.4.0 github.com/gorilla/websocket -# github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4 => github.com/grpc-ecosystem/go-grpc-middleware v1.0.0 +# github.com/grpc-ecosystem/go-grpc-middleware v1.1.0 => github.com/grpc-ecosystem/go-grpc-middleware v1.0.0 github.com/grpc-ecosystem/go-grpc-middleware github.com/grpc-ecosystem/go-grpc-middleware/recovery github.com/grpc-ecosystem/go-grpc-middleware/validator # github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 => github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 github.com/grpc-ecosystem/go-grpc-prometheus -# github.com/grpc-ecosystem/grpc-gateway v1.9.6 => github.com/grpc-ecosystem/grpc-gateway v1.9.6 +# github.com/grpc-ecosystem/grpc-gateway v1.11.3 => github.com/grpc-ecosystem/grpc-gateway v1.11.3 github.com/grpc-ecosystem/grpc-gateway/internal github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options github.com/grpc-ecosystem/grpc-gateway/runtime @@ -294,7 +292,7 @@ github.com/hpcloud/tail/ratelimiter github.com/hpcloud/tail/util github.com/hpcloud/tail/watch github.com/hpcloud/tail/winfile -# github.com/imdario/mergo v0.3.7 => github.com/imdario/mergo v0.3.7 +# github.com/imdario/mergo v0.3.8 => github.com/imdario/mergo v0.3.7 github.com/imdario/mergo # github.com/inconshreveable/mousetrap v1.0.0 => github.com/inconshreveable/mousetrap v1.0.0 github.com/inconshreveable/mousetrap @@ -498,7 +496,7 @@ github.com/projectcalico/libcalico-go/lib/scope github.com/projectcalico/libcalico-go/lib/selector github.com/projectcalico/libcalico-go/lib/selector/parser github.com/projectcalico/libcalico-go/lib/selector/tokenizer -# github.com/prometheus/client_golang v1.0.0 => github.com/prometheus/client_golang v0.9.4 +# github.com/prometheus/client_golang v1.2.1 => github.com/prometheus/client_golang v0.9.4 github.com/prometheus/client_golang/api github.com/prometheus/client_golang/api/prometheus/v1 github.com/prometheus/client_golang/prometheus @@ -532,7 +530,7 @@ github.com/rcrowley/go-metrics github.com/sergi/go-diff/diffmatchpatch # github.com/sirupsen/logrus v1.4.2 => github.com/sirupsen/logrus v1.4.2 github.com/sirupsen/logrus -# github.com/sony/sonyflake v0.0.0-20181109022403-6d5bd6181009 => github.com/sony/sonyflake v0.0.0-20181109022403-6d5bd6181009 +# github.com/sony/sonyflake v1.0.0 => github.com/sony/sonyflake v0.0.0-20181109022403-6d5bd6181009 github.com/sony/sonyflake # github.com/speps/go-hashids v2.0.0+incompatible => github.com/speps/go-hashids v2.0.0+incompatible github.com/speps/go-hashids @@ -576,7 +574,7 @@ github.com/syndtr/goleveldb/leveldb/util github.com/xanzy/ssh-agent # github.com/yashtewari/glob-intersection v0.0.0-20180916065949-5c77d914dd0b => github.com/yashtewari/glob-intersection v0.0.0-20180916065949-5c77d914dd0b github.com/yashtewari/glob-intersection -# go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738 => go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738 +# go.etcd.io/etcd v3.3.17+incompatible => go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738 go.etcd.io/etcd/auth/authpb go.etcd.io/etcd/clientv3 go.etcd.io/etcd/clientv3/balancer @@ -608,7 +606,7 @@ go.uber.org/zap/internal/bufferpool go.uber.org/zap/internal/color go.uber.org/zap/internal/exit go.uber.org/zap/zapcore -# golang.org/x/crypto v0.0.0-20190923035154-9ee001bba392 => golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2 +# golang.org/x/crypto v0.0.0-20200220183623-bac4c82f6975 => golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2 golang.org/x/crypto/bcrypt golang.org/x/crypto/blowfish golang.org/x/crypto/cast5 @@ -676,9 +674,9 @@ golang.org/x/text/transform golang.org/x/text/unicode/bidi golang.org/x/text/unicode/norm golang.org/x/text/width -# golang.org/x/time v0.0.0-20190921001708-c4c64cad1fd0 => golang.org/x/time v0.0.0-20190308202827-9d24e82272b4 +# golang.org/x/time v0.0.0-20191024005414-555d28b269f0 => golang.org/x/time v0.0.0-20190308202827-9d24e82272b4 golang.org/x/time/rate -# golang.org/x/tools v0.0.0-20190920225731-5eefd052ad72 => golang.org/x/tools v0.0.0-20190710153321-831012c29e42 +# golang.org/x/tools v0.0.0-20191029041327-9cc4af7d6b2c => golang.org/x/tools v0.0.0-20190710153321-831012c29e42 golang.org/x/tools/go/ast/astutil golang.org/x/tools/go/gcexportdata golang.org/x/tools/go/internal/gcimporter @@ -1361,7 +1359,7 @@ k8s.io/utils/net k8s.io/utils/path k8s.io/utils/pointer k8s.io/utils/trace -# openpitrix.io/openpitrix v0.4.1-0.20190920134345-4d2be6e4965c => openpitrix.io/openpitrix v0.4.1-0.20190920134345-4d2be6e4965c +# openpitrix.io/openpitrix v0.4.9-0.20200611125425-ae07f141e797 => openpitrix.io/openpitrix v0.4.9-0.20200611125425-ae07f141e797 openpitrix.io/openpitrix/pkg/config openpitrix.io/openpitrix/pkg/constants openpitrix.io/openpitrix/pkg/db diff --git a/vendor/openpitrix.io/openpitrix/pkg/config/config.go b/vendor/openpitrix.io/openpitrix/pkg/config/config.go index 8ccbe3aa3c629431755ae49dfac1812588eae296..ce7572de7236865c84072c963b8a5018f3342077 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/config/config.go +++ b/vendor/openpitrix.io/openpitrix/pkg/config/config.go @@ -21,6 +21,7 @@ type Config struct { Mysql MysqlConfig Etcd EtcdConfig IAM IAMConfig + Attachment AttachmentConfig DisableGops bool `default:"false"` } @@ -30,6 +31,13 @@ type IAMConfig struct { RefreshTokenExpireTime time.Duration `default:"336h"` // default is 2 week } +type AttachmentConfig struct { + AccessKey string `default:"openpitrixminioaccesskey"` + SecretKey string `default:"openpitrixminiosecretkey"` + Endpoint string `default:"http://openpitrix-minio:9000"` + BucketName string `default:"openpitrix-attachment"` +} + type LogConfig struct { Level string `default:"info"` // debug, info, warn, error, fatal } @@ -73,9 +81,9 @@ func ParseFlag() { GetFlagSet().Parse(os.Args[1:]) } -func LoadConf() *Config { - ParseFlag() +var conf Config +func loadConf() *Config { config := new(Config) m := &multiconfig.DefaultLoader{} m.Loader = multiconfig.MultiLoader(newLoader("openpitrix")) @@ -88,7 +96,18 @@ func LoadConf() *Config { panic(err) } logger.SetLevelByString(config.Log.Level) - logger.Debug(nil, "LoadConf: %+v", config) + logger.Debug(nil, "GetConf: %+v", config) return config } + +func init() { + conf = *loadConf() +} + +func GetConf() *Config { + ParseFlag() + var c = new(Config) + *c = conf + return c +} diff --git a/vendor/openpitrix.io/openpitrix/pkg/config/global_config.go b/vendor/openpitrix.io/openpitrix/pkg/config/global_config.go index ed0a2953a699ba22146109679f7b3232aa1638f4..29d9bea5ff7c4ccbf5e419bcf7254fd6f430849c 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/config/global_config.go +++ b/vendor/openpitrix.io/openpitrix/pkg/config/global_config.go @@ -83,7 +83,8 @@ func (r *RuntimeProviderConfig) GetPort() int { if r.Port > 0 { return r.Port } else { - return constants.RuntimeProviderManagerPort + //todo attention + return constants.KubernetesProviderPort } } diff --git a/vendor/openpitrix.io/openpitrix/pkg/constants/column.go b/vendor/openpitrix.io/openpitrix/pkg/constants/column.go index 0e4788180c947a74bc8b01af20c8ce607950b807..86c9809ba1b3bf3d00d0482e2e332a1ef63b692e 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/constants/column.go +++ b/vendor/openpitrix.io/openpitrix/pkg/constants/column.go @@ -4,6 +4,108 @@ package constants +var Fields = []string{ + "app_id", + "category_id", + "chart_name", + "cluster_id", + "cluster_type", + "create_time", + "credential", + "description", + "executor", + "frontgate_id", + "home", + "icon", + "instance_id", + "job_action", + "job_id", + "keywords", + "label_key", + "label_value", + "locale", + "maintainers", + "name", + "node_id", + "key_pair_id", + "owner", + "owner_path", + "package_name", + "private_ip", + "provider", + "readme", + "repo_event_id", + "repo_id", + "repo_label_id", + "repo_selector_id", + "resource_id", + "role", + "runtime_id", + "runtime_credential_id", + "runtime_url", + "debug", + "runtime_label_id", + "screenshots", + "selector_key", + "selector_value", + "sequence", + "sources", + "status", + "status_time", + "target", + "task_action", + "task_id", + "transition_status", + "type", + "update_time", + "url", + "version_id", + "visibility", + "volume_id", + "zone", + "vpc_id", + "env", + "loadbalancer_listener_id", + "result", + "directive", + "runtime_credential_content", + "user_id", + "group_id", + "reset_id", + "password", + "email", + "client_id", + "client_secret", + "refresh_token", + "access_token", + "token_id", + "scope", + "username", + "attachment_id", + "message", + "app_default_status", + "market_id", + "controller", + "active", + "operator", + "review_id", + "phase", + "reviewer", + "company_name", + "company_website", + "company_profile", + "authorizer_name", + "authorizer_email", + "authorizer_phone", + "bank_name", + "bank_account_name", + "bank_account_number", + "reject_message", + "submit_time", + "approver", + "isv", +} + const ( ColumnAppId = "app_id" ColumnCategoryId = "category_id" @@ -144,7 +246,7 @@ var IndexedColumns = map[string][]string{ ColumnAppDefaultStatus, ColumnOwner, ColumnController, }, TableRuntime: { - ColumnRuntimeId, ColumnProvider, ColumnZone, ColumnStatus, ColumnOwner, + ColumnRuntimeId, ColumnProvider, ColumnZone, ColumnStatus, ColumnOwner, ColumnRuntimeCredentialId, }, TableRuntimeCredential: { ColumnRuntimeCredentialId, ColumnStatus, ColumnProvider, ColumnOwner, @@ -160,7 +262,7 @@ var IndexedColumns = map[string][]string{ }, TableCluster: { ColumnClusterId, ColumnAppId, ColumnVersionId, ColumnStatus, - ColumnRuntimeId, ColumnFrontgateId, ColumnOwner, ColumnClusterType, + ColumnRuntimeId, ColumnFrontgateId, ColumnOwner, ColumnClusterType, ColumnZone, }, TableKeyPair: { ColumnKeyPairId, ColumnName, ColumnOwner, @@ -193,6 +295,7 @@ var SearchWordColumnTable = []string{ TableRuntimeCredential, TableApp, TableAppVersion, + TableAppVersionReview, TableRepo, TableJob, TableTask, @@ -210,6 +313,15 @@ var SearchColumns = map[string][]string{ TableAppVersion: { ColumnVersionId, ColumnAppId, ColumnName, ColumnDescription, ColumnOwner, ColumnPackageName, }, + TableAppVersionReview: { + TableAppVersionReview + "." + ColumnReviewId, + TableAppVersionReview + "." + ColumnVersionId, + TableAppVersionReview + "." + ColumnAppId, + TableAppVersionReview + "." + ColumnOwner, + "app.name", + "app_version.name", + "app.isv", + }, TableJob: { ColumnJobId, ColumnClusterId, ColumnOwner, ColumnJobAction, ColumnExecutor, ColumnProvider, ColumnExecutor, ColumnProvider, }, diff --git a/vendor/openpitrix.io/openpitrix/pkg/constants/common.go b/vendor/openpitrix.io/openpitrix/pkg/constants/common.go index 07ae2b4b96422a9702c658ec22d3ae4a19413e78..a113d5f3a681cd31a495a5b28bd122aebef3ec5c 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/constants/common.go +++ b/vendor/openpitrix.io/openpitrix/pkg/constants/common.go @@ -29,6 +29,7 @@ const ( MarketManagerHost = prefix + "market-manager" AttachmentManagerHost = prefix + "attachment-manager" IsvManagerHost = prefix + "isv-manager" + ReleaseManagerHost = prefix + "release-manager" ) const ( @@ -54,8 +55,11 @@ const ( EtcdServicePort = 2379 AttachmentManagerPort = 9122 RuntimeProviderManagerPort = 9121 + KubernetesProviderPort = 9123 + ReleaseManagerPort = 9124 NotificationPort = 9201 ServiceConfigPort = 9202 + ServicePushPort = 9203 ) const ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/db/Dockerfile b/vendor/openpitrix.io/openpitrix/pkg/db/Dockerfile index d014992ab887044ef287eb8c1bfa1351ff2db44c..8992068fca7f5fabdc52dd9ae3ce654759549eed 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/db/Dockerfile +++ b/vendor/openpitrix.io/openpitrix/pkg/db/Dockerfile @@ -2,9 +2,9 @@ # Use of this source code is governed by a Apache license # that can be found in the LICENSE file. -FROM dhoer/flyway:5.1.4-mysql-8.0.11-alpine +FROM openpitrix/flyway:alpine -RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/g' /etc/apk/repositories +USER root RUN apk add --no-cache mysql-client COPY ./schema /flyway/sql diff --git a/vendor/openpitrix.io/openpitrix/pkg/db/connection.go b/vendor/openpitrix.io/openpitrix/pkg/db/connection.go index c81777f62087d1f7e9752f0216f3927db546c0c0..a7e53fda13276ae7f193d426a902cb67201fb65a 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/db/connection.go +++ b/vendor/openpitrix.io/openpitrix/pkg/db/connection.go @@ -61,9 +61,11 @@ func FromContext(ctx context.Context) (*Database, bool) { func (db *Database) New(ctx context.Context) *Conn { actualDb, ok := FromContext(ctx) - conn := db.Conn - if ok { + var conn *dbr.Connection + if ok || db == nil { conn = actualDb.Conn + } else { + conn = db.Conn } return &Conn{ Session: conn.NewSession(&EventReceiver{ctx}), diff --git a/vendor/openpitrix.io/openpitrix/pkg/db/db.go b/vendor/openpitrix.io/openpitrix/pkg/db/db.go index b5777475ffbab79e62643dcb4aac832c175fa6e7..412d52cf2590a0be6b22945c310db8fc6a91779f 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/db/db.go +++ b/vendor/openpitrix.io/openpitrix/pkg/db/db.go @@ -4,7 +4,6 @@ import ( "context" "database/sql" "fmt" - "strings" _ "github.com/go-sql-driver/mysql" "github.com/gocraft/dbr" @@ -91,6 +90,14 @@ func (b *SelectQuery) Join(table, on interface{}) *SelectQuery { b.SelectBuilder.Join(table, on) return b } +func (b *SelectQuery) RightJoin(table, on interface{}) *SelectQuery { + b.SelectBuilder.RightJoin(table, on) + return b +} +func (b *SelectQuery) LeftJoin(table, on interface{}) *SelectQuery { + b.SelectBuilder.LeftJoin(table, on) + return b +} func (b *SelectQuery) JoinAs(table string, alias string, on interface{}) *SelectQuery { b.SelectBuilder.Join(dbr.I(table).As(alias), on) @@ -143,13 +150,12 @@ func (b *SelectQuery) LoadOne(value interface{}) error { } func getColumns(dbrColumns []interface{}) string { - var columns []string for _, column := range dbrColumns { if c, ok := column.(string); ok { - columns = append(columns, c) + return c } } - return strings.Join(columns, ", ") + return "*" } func (b *SelectQuery) Count() (count uint32, err error) { diff --git a/vendor/openpitrix.io/openpitrix/pkg/gerr/error.go b/vendor/openpitrix.io/openpitrix/pkg/gerr/error.go index 8a7f76c5bd260dfb42171446e8eebefb5fb5064d..623efbdc6099894b5396d61196fa00799b2cc8a4 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/gerr/error.go +++ b/vendor/openpitrix.io/openpitrix/pkg/gerr/error.go @@ -13,15 +13,20 @@ import ( "google.golang.org/grpc/status" "openpitrix.io/openpitrix/pkg/logger" + "openpitrix.io/openpitrix/pkg/pb" + "openpitrix.io/openpitrix/pkg/util/ctxutil" ) const En = "en" const ZhCN = "zh_cn" -const DefaultLocale = ZhCN +const DefaultLocale = En func newStatus(ctx context.Context, code codes.Code, err error, errMsg ErrorMessage, a ...interface{}) *status.Status { - locale := DefaultLocale + locale := ctxutil.GetLocale(ctx) + if len(locale) == 0 { + locale = DefaultLocale + } s := status.New(code, errMsg.Message(locale, err, a...)) diff --git a/vendor/openpitrix.io/openpitrix/pkg/manager/common.go b/vendor/openpitrix.io/openpitrix/pkg/manager/common.go index e3c882debe8ac80be26bec7111cfb2829596a51d..4d9f39df62fc6598780124aae2ca980f147db9ee 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/manager/common.go +++ b/vendor/openpitrix.io/openpitrix/pkg/manager/common.go @@ -201,12 +201,20 @@ func BuildUpdateAttributes(req Request, columns ...string) map[string]interface{ return attributes } +func AddQueryOrderDirWithPrefix(query *db.SelectQuery, req Request, defaultColumn, tableName string) *db.SelectQuery { + return addQueryOrderDir(query, req, defaultColumn, tableName) +} + func AddQueryOrderDir(query *db.SelectQuery, req Request, defaultColumn string) *db.SelectQuery { + return addQueryOrderDir(query, req, defaultColumn, "") +} + +func addQueryOrderDir(query *db.SelectQuery, req Request, defaultColumn string, tableName string) *db.SelectQuery { isAsc := false if r, ok := req.(RequestWithReverse); ok { reverse := r.GetReverse() if reverse != nil { - isAsc = reverse.GetValue() + isAsc = !reverse.GetValue() } } if r, ok := req.(RequestWithSortKey); ok { @@ -215,6 +223,12 @@ func AddQueryOrderDir(query *db.SelectQuery, req Request, defaultColumn string) defaultColumn = s.GetValue() } } + if !stringutil.StringIn(defaultColumn, constants.Fields) { + defaultColumn = constants.ColumnCreateTime + } + if len(tableName) > 0 { + defaultColumn = tableName + "." + defaultColumn + } query = query.OrderDir(defaultColumn, isAsc) return query } @@ -245,3 +259,15 @@ func BuildPermissionFilter(ctx context.Context) dbr.Builder { } return db.Or(ops...) } + +func BuildPermissionFilterWithPrefix(ctx context.Context, prefix string) dbr.Builder { + s := ctxutil.GetSender(ctx) + if s == nil { + return nil + } + ops := []dbr.Builder{ + db.Prefix(prefix+"."+constants.ColumnOwnerPath, string(s.GetAccessPath())), + db.Eq(prefix+"."+constants.ColumnOwner, s.UserId), + } + return db.Or(ops...) +} diff --git a/vendor/openpitrix.io/openpitrix/pkg/manager/grpc_client.go b/vendor/openpitrix.io/openpitrix/pkg/manager/grpc_client.go index 2e3438cf60c7863af8dd941bfb23449812bd23d8..5b4a50f1039c6ad95f0157340441a512970cf6fb 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/manager/grpc_client.go +++ b/vendor/openpitrix.io/openpitrix/pkg/manager/grpc_client.go @@ -37,7 +37,7 @@ func NewClient(host string, port int) (*grpc.ClientConn, error) { if err != nil { return nil, err } - clientCache.Store(endpoint, conn) + //clientCache.Store(endpoint, conn) return conn, nil } diff --git a/vendor/openpitrix.io/openpitrix/pkg/manager/grpc_server.go b/vendor/openpitrix.io/openpitrix/pkg/manager/grpc_server.go index 9d49acdece302a8cb3b40cdc0101f4c6b4f166c2..7b6b44a57a3109a6025a32e70d5fea548572b5f4 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/manager/grpc_server.go +++ b/vendor/openpitrix.io/openpitrix/pkg/manager/grpc_server.go @@ -168,6 +168,8 @@ func (g *GrpcServer) unaryServerLogInterceptor() grpc.UnaryServerInterceptor { requestId := ctxutil.GetRequestId(ctx) ctx = ctxutil.SetRequestId(ctx, requestId) ctx = ctxutil.ContextWithSender(ctx, s) + locale := ctxutil.GetLocale(ctx) + ctx = ctxutil.SetLocale(ctx, locale) method := strings.Split(info.FullMethod, "/") action := method[len(method)-1] diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/0.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/0.pb.go index dbc45d2258a829b6302fcf56dc0fa1eae96a5d65..36f2e000e0255d9b3078b1127814a8208c458928 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/0.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/0.pb.go @@ -20,7 +20,7 @@ var _ = math.Inf // 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 func init() { proto.RegisterFile("0.proto", fileDescriptor_b5d39afb3b422e60) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/account.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/account.pb.go index c0d596e4d8a1ad96ea3aaa2951067d6dca5cf3c9..3c7779a49360e0f0f144cafd75b2d794bdc17e1b 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/account.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/account.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -11,9 +12,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +27,7 @@ var _ = math.Inf // 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 User struct { // user id, user belong to different group and role, has different permissions @@ -3659,11 +3661,11 @@ type TokenResponse struct { TokenType string `protobuf:"bytes,1,opt,name=token_type,json=tokenType,proto3" json:"token_type,omitempty"` // default 2h ExpiresIn int32 `protobuf:"varint,2,opt,name=expires_in,json=expiresIn,proto3" json:"expires_in,omitempty"` - // access token, generator by jwt(key=secrete key) + //access token, generator by jwt(key=secrete key) AccessToken string `protobuf:"bytes,3,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"` - // refresh token, timeliness,default expired after 2 weeks + //refresh token, timeliness,default expired after 2 weeks RefreshToken string `protobuf:"bytes,4,opt,name=refresh_token,json=refreshToken,proto3" json:"refresh_token,omitempty"` - // id token, generator by jwt(key="") + //id token, generator by jwt(key="") IdToken string `protobuf:"bytes,5,opt,name=id_token,json=idToken,proto3" json:"id_token,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` @@ -4064,7 +4066,7 @@ type AccountManagerClient interface { DescribeGroups(ctx context.Context, in *DescribeGroupsRequest, opts ...grpc.CallOption) (*DescribeGroupsResponse, error) // Get groups, include all user in this group, can filter with these fields(group_id, parent_group_id, group_path, status), default return all groups DescribeGroupsDetail(ctx context.Context, in *DescribeGroupsRequest, opts ...grpc.CallOption) (*DescribeGroupsDetailResponse, error) - // Modify group info + //Modify group info ModifyGroup(ctx context.Context, in *ModifyGroupRequest, opts ...grpc.CallOption) (*ModifyGroupResponse, error) // Delete groups DeleteGroups(ctx context.Context, in *DeleteGroupsRequest, opts ...grpc.CallOption) (*DeleteGroupsResponse, error) @@ -4263,7 +4265,7 @@ type AccountManagerServer interface { DescribeGroups(context.Context, *DescribeGroupsRequest) (*DescribeGroupsResponse, error) // Get groups, include all user in this group, can filter with these fields(group_id, parent_group_id, group_path, status), default return all groups DescribeGroupsDetail(context.Context, *DescribeGroupsRequest) (*DescribeGroupsDetailResponse, error) - // Modify group info + //Modify group info ModifyGroup(context.Context, *ModifyGroupRequest) (*ModifyGroupResponse, error) // Delete groups DeleteGroups(context.Context, *DeleteGroupsRequest) (*DeleteGroupsResponse, error) @@ -4273,6 +4275,62 @@ type AccountManagerServer interface { LeaveGroup(context.Context, *LeaveGroupRequest) (*LeaveGroupResponse, error) } +// UnimplementedAccountManagerServer can be embedded to have forward compatible implementations. +type UnimplementedAccountManagerServer struct { +} + +func (*UnimplementedAccountManagerServer) DescribeUsers(ctx context.Context, req *DescribeUsersRequest) (*DescribeUsersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeUsers not implemented") +} +func (*UnimplementedAccountManagerServer) DescribeUsersDetail(ctx context.Context, req *DescribeUsersRequest) (*DescribeUsersDetailResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeUsersDetail not implemented") +} +func (*UnimplementedAccountManagerServer) ModifyUser(ctx context.Context, req *ModifyUserRequest) (*ModifyUserResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyUser not implemented") +} +func (*UnimplementedAccountManagerServer) DeleteUsers(ctx context.Context, req *DeleteUsersRequest) (*DeleteUsersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteUsers not implemented") +} +func (*UnimplementedAccountManagerServer) ChangePassword(ctx context.Context, req *ChangePasswordRequest) (*ChangePasswordResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ChangePassword not implemented") +} +func (*UnimplementedAccountManagerServer) CreatePasswordReset(ctx context.Context, req *CreatePasswordResetRequest) (*CreatePasswordResetResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreatePasswordReset not implemented") +} +func (*UnimplementedAccountManagerServer) IsvCreateUser(ctx context.Context, req *CreateUserRequest) (*CreateUserResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method IsvCreateUser not implemented") +} +func (*UnimplementedAccountManagerServer) CreateUser(ctx context.Context, req *CreateUserRequest) (*CreateUserResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateUser not implemented") +} +func (*UnimplementedAccountManagerServer) GetPasswordReset(ctx context.Context, req *GetPasswordResetRequest) (*GetPasswordResetResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetPasswordReset not implemented") +} +func (*UnimplementedAccountManagerServer) ValidateUserPassword(ctx context.Context, req *ValidateUserPasswordRequest) (*ValidateUserPasswordResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ValidateUserPassword not implemented") +} +func (*UnimplementedAccountManagerServer) CreateGroup(ctx context.Context, req *CreateGroupRequest) (*CreateGroupResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateGroup not implemented") +} +func (*UnimplementedAccountManagerServer) DescribeGroups(ctx context.Context, req *DescribeGroupsRequest) (*DescribeGroupsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeGroups not implemented") +} +func (*UnimplementedAccountManagerServer) DescribeGroupsDetail(ctx context.Context, req *DescribeGroupsRequest) (*DescribeGroupsDetailResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeGroupsDetail not implemented") +} +func (*UnimplementedAccountManagerServer) ModifyGroup(ctx context.Context, req *ModifyGroupRequest) (*ModifyGroupResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyGroup not implemented") +} +func (*UnimplementedAccountManagerServer) DeleteGroups(ctx context.Context, req *DeleteGroupsRequest) (*DeleteGroupsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteGroups not implemented") +} +func (*UnimplementedAccountManagerServer) JoinGroup(ctx context.Context, req *JoinGroupRequest) (*JoinGroupResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method JoinGroup not implemented") +} +func (*UnimplementedAccountManagerServer) LeaveGroup(ctx context.Context, req *LeaveGroupRequest) (*LeaveGroupResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method LeaveGroup not implemented") +} + func RegisterAccountManagerServer(s *grpc.Server, srv AccountManagerServer) { s.RegisterService(&_AccountManager_serviceDesc, srv) } @@ -4808,6 +4866,41 @@ type AccessManagerServer interface { UnbindUserRole(context.Context, *UnbindUserRoleRequest) (*UnbindUserRoleResponse, error) } +// UnimplementedAccessManagerServer can be embedded to have forward compatible implementations. +type UnimplementedAccessManagerServer struct { +} + +func (*UnimplementedAccessManagerServer) CanDo(ctx context.Context, req *CanDoRequest) (*CanDoResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CanDo not implemented") +} +func (*UnimplementedAccessManagerServer) GetRoleModule(ctx context.Context, req *GetRoleModuleRequest) (*GetRoleModuleResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetRoleModule not implemented") +} +func (*UnimplementedAccessManagerServer) ModifyRoleModule(ctx context.Context, req *ModifyRoleModuleRequest) (*ModifyRoleModuleResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyRoleModule not implemented") +} +func (*UnimplementedAccessManagerServer) CreateRole(ctx context.Context, req *CreateRoleRequest) (*CreateRoleResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateRole not implemented") +} +func (*UnimplementedAccessManagerServer) DeleteRoles(ctx context.Context, req *DeleteRolesRequest) (*DeleteRolesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteRoles not implemented") +} +func (*UnimplementedAccessManagerServer) ModifyRole(ctx context.Context, req *ModifyRoleRequest) (*ModifyRoleResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyRole not implemented") +} +func (*UnimplementedAccessManagerServer) GetRole(ctx context.Context, req *GetRoleRequest) (*GetRoleResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetRole not implemented") +} +func (*UnimplementedAccessManagerServer) DescribeRoles(ctx context.Context, req *DescribeRolesRequest) (*DescribeRolesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeRoles not implemented") +} +func (*UnimplementedAccessManagerServer) BindUserRole(ctx context.Context, req *BindUserRoleRequest) (*BindUserRoleResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method BindUserRole not implemented") +} +func (*UnimplementedAccessManagerServer) UnbindUserRole(ctx context.Context, req *UnbindUserRoleRequest) (*UnbindUserRoleResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UnbindUserRole not implemented") +} + func RegisterAccessManagerServer(s *grpc.Server, srv AccessManagerServer) { s.RegisterService(&_AccessManager_serviceDesc, srv) } @@ -5107,6 +5200,17 @@ type TokenManagerServer interface { Token(context.Context, *TokenRequest) (*TokenResponse, error) } +// UnimplementedTokenManagerServer can be embedded to have forward compatible implementations. +type UnimplementedTokenManagerServer struct { +} + +func (*UnimplementedTokenManagerServer) CreateClient(ctx context.Context, req *CreateClientRequest) (*CreateClientResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateClient not implemented") +} +func (*UnimplementedTokenManagerServer) Token(ctx context.Context, req *TokenRequest) (*TokenResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Token not implemented") +} + func RegisterTokenManagerServer(s *grpc.Server, srv TokenManagerServer) { s.RegisterService(&_TokenManager_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/account.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/account.pb.gw.go index 866f4d90ebe392b91633cb21f331b98c68e7447a..214c08e7596a9ec2fb206c5ebdb869149061afbc 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/account.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/account.pb.gw.go @@ -9,24 +9,27 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage var ( filter_AccountManager_DescribeUsers_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} @@ -36,7 +39,10 @@ func request_AccountManager_DescribeUsers_0(ctx context.Context, marshaler runti var protoReq DescribeUsersRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccountManager_DescribeUsers_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AccountManager_DescribeUsers_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -45,6 +51,19 @@ func request_AccountManager_DescribeUsers_0(ctx context.Context, marshaler runti } +func local_request_AccountManager_DescribeUsers_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeUsersRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccountManager_DescribeUsers_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeUsers(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AccountManager_DescribeUsersDetail_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -53,7 +72,10 @@ func request_AccountManager_DescribeUsersDetail_0(ctx context.Context, marshaler var protoReq DescribeUsersRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccountManager_DescribeUsersDetail_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AccountManager_DescribeUsersDetail_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -62,11 +84,28 @@ func request_AccountManager_DescribeUsersDetail_0(ctx context.Context, marshaler } +func local_request_AccountManager_DescribeUsersDetail_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeUsersRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccountManager_DescribeUsersDetail_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeUsersDetail(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_ModifyUser_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyUserRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -75,11 +114,32 @@ func request_AccountManager_ModifyUser_0(ctx context.Context, marshaler runtime. } +func local_request_AccountManager_ModifyUser_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyUserRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyUser(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_DeleteUsers_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DeleteUsersRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -88,11 +148,32 @@ func request_AccountManager_DeleteUsers_0(ctx context.Context, marshaler runtime } +func local_request_AccountManager_DeleteUsers_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteUsersRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteUsers(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_ChangePassword_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ChangePasswordRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -101,11 +182,32 @@ func request_AccountManager_ChangePassword_0(ctx context.Context, marshaler runt } +func local_request_AccountManager_ChangePassword_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ChangePasswordRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ChangePassword(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_CreatePasswordReset_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreatePasswordResetRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -114,11 +216,32 @@ func request_AccountManager_CreatePasswordReset_0(ctx context.Context, marshaler } +func local_request_AccountManager_CreatePasswordReset_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreatePasswordResetRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreatePasswordReset(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_IsvCreateUser_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateUserRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -127,11 +250,32 @@ func request_AccountManager_IsvCreateUser_0(ctx context.Context, marshaler runti } +func local_request_AccountManager_IsvCreateUser_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateUserRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.IsvCreateUser(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_CreateUser_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateUserRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -140,6 +284,23 @@ func request_AccountManager_CreateUser_0(ctx context.Context, marshaler runtime. } +func local_request_AccountManager_CreateUser_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateUserRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateUser(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AccountManager_GetPasswordReset_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -148,7 +309,10 @@ func request_AccountManager_GetPasswordReset_0(ctx context.Context, marshaler ru var protoReq GetPasswordResetRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccountManager_GetPasswordReset_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AccountManager_GetPasswordReset_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -157,11 +321,28 @@ func request_AccountManager_GetPasswordReset_0(ctx context.Context, marshaler ru } +func local_request_AccountManager_GetPasswordReset_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetPasswordResetRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccountManager_GetPasswordReset_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.GetPasswordReset(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_ValidateUserPassword_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ValidateUserPasswordRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -170,11 +351,32 @@ func request_AccountManager_ValidateUserPassword_0(ctx context.Context, marshale } +func local_request_AccountManager_ValidateUserPassword_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ValidateUserPasswordRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ValidateUserPassword(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_CreateGroup_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateGroupRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -183,6 +385,23 @@ func request_AccountManager_CreateGroup_0(ctx context.Context, marshaler runtime } +func local_request_AccountManager_CreateGroup_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateGroupRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateGroup(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AccountManager_DescribeGroups_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -191,7 +410,10 @@ func request_AccountManager_DescribeGroups_0(ctx context.Context, marshaler runt var protoReq DescribeGroupsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccountManager_DescribeGroups_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AccountManager_DescribeGroups_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -200,6 +422,19 @@ func request_AccountManager_DescribeGroups_0(ctx context.Context, marshaler runt } +func local_request_AccountManager_DescribeGroups_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeGroupsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccountManager_DescribeGroups_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeGroups(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AccountManager_DescribeGroupsDetail_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -208,7 +443,10 @@ func request_AccountManager_DescribeGroupsDetail_0(ctx context.Context, marshale var protoReq DescribeGroupsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccountManager_DescribeGroupsDetail_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AccountManager_DescribeGroupsDetail_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -217,11 +455,28 @@ func request_AccountManager_DescribeGroupsDetail_0(ctx context.Context, marshale } +func local_request_AccountManager_DescribeGroupsDetail_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeGroupsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccountManager_DescribeGroupsDetail_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeGroupsDetail(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_ModifyGroup_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyGroupRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -230,11 +485,32 @@ func request_AccountManager_ModifyGroup_0(ctx context.Context, marshaler runtime } +func local_request_AccountManager_ModifyGroup_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyGroupRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyGroup(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_DeleteGroups_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DeleteGroupsRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -243,11 +519,32 @@ func request_AccountManager_DeleteGroups_0(ctx context.Context, marshaler runtim } +func local_request_AccountManager_DeleteGroups_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteGroupsRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteGroups(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_JoinGroup_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq JoinGroupRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -256,11 +553,32 @@ func request_AccountManager_JoinGroup_0(ctx context.Context, marshaler runtime.M } +func local_request_AccountManager_JoinGroup_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq JoinGroupRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.JoinGroup(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccountManager_LeaveGroup_0(ctx context.Context, marshaler runtime.Marshaler, client AccountManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq LeaveGroupRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -269,11 +587,32 @@ func request_AccountManager_LeaveGroup_0(ctx context.Context, marshaler runtime. } +func local_request_AccountManager_LeaveGroup_0(ctx context.Context, marshaler runtime.Marshaler, server AccountManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq LeaveGroupRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.LeaveGroup(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccessManager_CanDo_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CanDoRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -282,6 +621,23 @@ func request_AccessManager_CanDo_0(ctx context.Context, marshaler runtime.Marsha } +func local_request_AccessManager_CanDo_0(ctx context.Context, marshaler runtime.Marshaler, server AccessManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CanDoRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CanDo(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AccessManager_GetRoleModule_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -290,7 +646,10 @@ func request_AccessManager_GetRoleModule_0(ctx context.Context, marshaler runtim var protoReq GetRoleModuleRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccessManager_GetRoleModule_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AccessManager_GetRoleModule_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -299,11 +658,28 @@ func request_AccessManager_GetRoleModule_0(ctx context.Context, marshaler runtim } +func local_request_AccessManager_GetRoleModule_0(ctx context.Context, marshaler runtime.Marshaler, server AccessManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetRoleModuleRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccessManager_GetRoleModule_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.GetRoleModule(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccessManager_ModifyRoleModule_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyRoleModuleRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -312,129 +688,929 @@ func request_AccessManager_ModifyRoleModule_0(ctx context.Context, marshaler run } +func local_request_AccessManager_ModifyRoleModule_0(ctx context.Context, marshaler runtime.Marshaler, server AccessManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyRoleModuleRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyRoleModule(ctx, &protoReq) + return msg, metadata, err + +} + func request_AccessManager_CreateRole_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateRoleRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.CreateRole(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err -} +} + +func local_request_AccessManager_CreateRole_0(ctx context.Context, marshaler runtime.Marshaler, server AccessManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateRoleRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateRole(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AccessManager_DeleteRoles_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteRolesRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.DeleteRoles(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AccessManager_DeleteRoles_0(ctx context.Context, marshaler runtime.Marshaler, server AccessManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteRolesRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteRoles(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AccessManager_ModifyRole_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyRoleRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.ModifyRole(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AccessManager_ModifyRole_0(ctx context.Context, marshaler runtime.Marshaler, server AccessManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyRoleRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyRole(ctx, &protoReq) + return msg, metadata, err + +} + +var ( + filter_AccessManager_GetRole_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} +) + +func request_AccessManager_GetRole_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetRoleRequest + var metadata runtime.ServerMetadata + + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AccessManager_GetRole_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.GetRole(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AccessManager_GetRole_0(ctx context.Context, marshaler runtime.Marshaler, server AccessManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetRoleRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccessManager_GetRole_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.GetRole(ctx, &protoReq) + return msg, metadata, err + +} + +var ( + filter_AccessManager_DescribeRoles_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} +) + +func request_AccessManager_DescribeRoles_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeRolesRequest + var metadata runtime.ServerMetadata + + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AccessManager_DescribeRoles_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.DescribeRoles(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AccessManager_DescribeRoles_0(ctx context.Context, marshaler runtime.Marshaler, server AccessManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeRolesRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccessManager_DescribeRoles_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeRoles(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AccessManager_BindUserRole_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq BindUserRoleRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.BindUserRole(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AccessManager_BindUserRole_0(ctx context.Context, marshaler runtime.Marshaler, server AccessManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq BindUserRoleRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.BindUserRole(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AccessManager_UnbindUserRole_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UnbindUserRoleRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.UnbindUserRole(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AccessManager_UnbindUserRole_0(ctx context.Context, marshaler runtime.Marshaler, server AccessManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UnbindUserRoleRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.UnbindUserRole(ctx, &protoReq) + return msg, metadata, err + +} + +func request_TokenManager_CreateClient_0(ctx context.Context, marshaler runtime.Marshaler, client TokenManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateClientRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.CreateClient(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_TokenManager_CreateClient_0(ctx context.Context, marshaler runtime.Marshaler, server TokenManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateClientRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateClient(ctx, &protoReq) + return msg, metadata, err + +} + +func request_TokenManager_Token_0(ctx context.Context, marshaler runtime.Marshaler, client TokenManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq TokenRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.Token(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_TokenManager_Token_0(ctx context.Context, marshaler runtime.Marshaler, server TokenManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq TokenRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.Token(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterAccountManagerHandlerServer registers the http handlers for service AccountManager to "mux". +// UnaryRPC :call AccountManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterAccountManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server AccountManagerServer) error { + + mux.Handle("GET", pattern_AccountManager_DescribeUsers_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_DescribeUsers_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_DescribeUsers_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AccountManager_DescribeUsersDetail_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_DescribeUsersDetail_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_DescribeUsersDetail_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_AccountManager_ModifyUser_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_ModifyUser_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_ModifyUser_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_AccountManager_DeleteUsers_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_DeleteUsers_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_DeleteUsers_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AccountManager_ChangePassword_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_ChangePassword_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_ChangePassword_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AccountManager_CreatePasswordReset_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_CreatePasswordReset_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_CreatePasswordReset_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AccountManager_IsvCreateUser_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_IsvCreateUser_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_IsvCreateUser_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AccountManager_CreateUser_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_CreateUser_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_CreateUser_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AccountManager_GetPasswordReset_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_GetPasswordReset_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_GetPasswordReset_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AccountManager_ValidateUserPassword_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_ValidateUserPassword_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_ValidateUserPassword_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AccountManager_CreateGroup_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_CreateGroup_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_CreateGroup_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AccountManager_DescribeGroups_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_DescribeGroups_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_DescribeGroups_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AccountManager_DescribeGroupsDetail_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_DescribeGroupsDetail_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_DescribeGroupsDetail_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_AccountManager_ModifyGroup_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_ModifyGroup_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_ModifyGroup_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_AccountManager_DeleteGroups_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_DeleteGroups_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_DeleteGroups_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AccountManager_JoinGroup_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_JoinGroup_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_JoinGroup_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AccountManager_LeaveGroup_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccountManager_LeaveGroup_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccountManager_LeaveGroup_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + +// RegisterAccessManagerHandlerServer registers the http handlers for service AccessManager to "mux". +// UnaryRPC :call AccessManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterAccessManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server AccessManagerServer) error { + + mux.Handle("POST", pattern_AccessManager_CanDo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccessManager_CanDo_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccessManager_CanDo_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AccessManager_GetRoleModule_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccessManager_GetRoleModule_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AccessManager_GetRoleModule_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -func request_AccessManager_DeleteRoles_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq DeleteRolesRequest - var metadata runtime.ServerMetadata + }) - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + mux.Handle("POST", pattern_AccessManager_ModifyRoleModule_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccessManager_ModifyRoleModule_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - msg, err := client.DeleteRoles(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + forward_AccessManager_ModifyRoleModule_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -} + }) -func request_AccessManager_ModifyRole_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq ModifyRoleRequest - var metadata runtime.ServerMetadata + mux.Handle("POST", pattern_AccessManager_CreateRole_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccessManager_CreateRole_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + forward_AccessManager_CreateRole_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - msg, err := client.ModifyRole(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + }) -} + mux.Handle("DELETE", pattern_AccessManager_DeleteRoles_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccessManager_DeleteRoles_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -var ( - filter_AccessManager_GetRole_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} -) + forward_AccessManager_DeleteRoles_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -func request_AccessManager_GetRole_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq GetRoleRequest - var metadata runtime.ServerMetadata + }) - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccessManager_GetRole_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + mux.Handle("PATCH", pattern_AccessManager_ModifyRole_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccessManager_ModifyRole_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - msg, err := client.GetRole(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + forward_AccessManager_ModifyRole_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -} + }) -var ( - filter_AccessManager_DescribeRoles_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} -) + mux.Handle("GET", pattern_AccessManager_GetRole_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccessManager_GetRole_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -func request_AccessManager_DescribeRoles_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq DescribeRolesRequest - var metadata runtime.ServerMetadata + forward_AccessManager_GetRole_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AccessManager_DescribeRoles_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + }) - msg, err := client.DescribeRoles(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + mux.Handle("GET", pattern_AccessManager_DescribeRoles_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccessManager_DescribeRoles_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -} + forward_AccessManager_DescribeRoles_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -func request_AccessManager_BindUserRole_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq BindUserRoleRequest - var metadata runtime.ServerMetadata + }) - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + mux.Handle("POST", pattern_AccessManager_BindUserRole_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccessManager_BindUserRole_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - msg, err := client.BindUserRole(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + forward_AccessManager_BindUserRole_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -} + }) -func request_AccessManager_UnbindUserRole_0(ctx context.Context, marshaler runtime.Marshaler, client AccessManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq UnbindUserRoleRequest - var metadata runtime.ServerMetadata + mux.Handle("DELETE", pattern_AccessManager_UnbindUserRole_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AccessManager_UnbindUserRole_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + forward_AccessManager_UnbindUserRole_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - msg, err := client.UnbindUserRole(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + }) + return nil } -func request_TokenManager_CreateClient_0(ctx context.Context, marshaler runtime.Marshaler, client TokenManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CreateClientRequest - var metadata runtime.ServerMetadata +// RegisterTokenManagerHandlerServer registers the http handlers for service TokenManager to "mux". +// UnaryRPC :call TokenManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterTokenManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server TokenManagerServer) error { - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + mux.Handle("POST", pattern_TokenManager_CreateClient_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_TokenManager_CreateClient_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - msg, err := client.CreateClient(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + forward_TokenManager_CreateClient_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -} + }) -func request_TokenManager_Token_0(ctx context.Context, marshaler runtime.Marshaler, client TokenManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq TokenRequest - var metadata runtime.ServerMetadata + mux.Handle("POST", pattern_TokenManager_Token_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_TokenManager_Token_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + forward_TokenManager_Token_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - msg, err := client.Token(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + }) + return nil } // RegisterAccountManagerHandlerFromEndpoint is same as RegisterAccountManagerHandler but @@ -478,15 +1654,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_AccountManager_DescribeUsers_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -507,15 +1674,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_AccountManager_DescribeUsersDetail_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -536,15 +1694,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("PATCH", pattern_AccountManager_ModifyUser_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -565,15 +1714,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("DELETE", pattern_AccountManager_DeleteUsers_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -594,15 +1734,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_AccountManager_ChangePassword_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -623,15 +1754,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_AccountManager_CreatePasswordReset_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -652,15 +1774,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_AccountManager_IsvCreateUser_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -681,15 +1794,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_AccountManager_CreateUser_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -710,15 +1814,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_AccountManager_GetPasswordReset_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -739,15 +1834,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_AccountManager_ValidateUserPassword_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -768,15 +1854,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_AccountManager_CreateGroup_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -797,15 +1874,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_AccountManager_DescribeGroups_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -826,15 +1894,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_AccountManager_DescribeGroupsDetail_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -855,15 +1914,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("PATCH", pattern_AccountManager_ModifyGroup_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -884,15 +1934,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("DELETE", pattern_AccountManager_DeleteGroups_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -913,15 +1954,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_AccountManager_JoinGroup_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -942,15 +1974,6 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_AccountManager_LeaveGroup_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -972,39 +1995,39 @@ func RegisterAccountManagerHandlerClient(ctx context.Context, mux *runtime.Serve } var ( - pattern_AccountManager_DescribeUsers_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "users"}, "")) + pattern_AccountManager_DescribeUsers_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "users"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_DescribeUsersDetail_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "users_detail"}, "")) + pattern_AccountManager_DescribeUsersDetail_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "users_detail"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_ModifyUser_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "users"}, "")) + pattern_AccountManager_ModifyUser_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "users"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_DeleteUsers_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "users"}, "")) + pattern_AccountManager_DeleteUsers_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "users"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_ChangePassword_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "users", "password"}, "change")) + pattern_AccountManager_ChangePassword_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "users", "password"}, "change", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_CreatePasswordReset_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "users", "password"}, "reset")) + pattern_AccountManager_CreatePasswordReset_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "users", "password"}, "reset", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_IsvCreateUser_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "isv_users"}, "")) + pattern_AccountManager_IsvCreateUser_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "isv_users"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_CreateUser_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "users"}, "")) + pattern_AccountManager_CreateUser_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "users"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_GetPasswordReset_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "users", "password"}, "reset")) + pattern_AccountManager_GetPasswordReset_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "users", "password"}, "reset", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_ValidateUserPassword_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "users", "password"}, "validate")) + pattern_AccountManager_ValidateUserPassword_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "users", "password"}, "validate", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_CreateGroup_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "")) + pattern_AccountManager_CreateGroup_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_DescribeGroups_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "")) + pattern_AccountManager_DescribeGroups_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_DescribeGroupsDetail_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups_detail"}, "")) + pattern_AccountManager_DescribeGroupsDetail_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups_detail"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_ModifyGroup_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "")) + pattern_AccountManager_ModifyGroup_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_DeleteGroups_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "")) + pattern_AccountManager_DeleteGroups_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_JoinGroup_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "join")) + pattern_AccountManager_JoinGroup_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "join", runtime.AssumeColonVerbOpt(true))) - pattern_AccountManager_LeaveGroup_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "leave")) + pattern_AccountManager_LeaveGroup_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "groups"}, "leave", runtime.AssumeColonVerbOpt(true))) ) var ( @@ -1084,15 +2107,6 @@ func RegisterAccessManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("POST", pattern_AccessManager_CanDo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1113,15 +2127,6 @@ func RegisterAccessManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("GET", pattern_AccessManager_GetRoleModule_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1142,15 +2147,6 @@ func RegisterAccessManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("POST", pattern_AccessManager_ModifyRoleModule_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1171,15 +2167,6 @@ func RegisterAccessManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("POST", pattern_AccessManager_CreateRole_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1200,15 +2187,6 @@ func RegisterAccessManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("DELETE", pattern_AccessManager_DeleteRoles_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1229,15 +2207,6 @@ func RegisterAccessManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("PATCH", pattern_AccessManager_ModifyRole_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1258,15 +2227,6 @@ func RegisterAccessManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("GET", pattern_AccessManager_GetRole_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1287,15 +2247,6 @@ func RegisterAccessManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("GET", pattern_AccessManager_DescribeRoles_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1316,15 +2267,6 @@ func RegisterAccessManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("POST", pattern_AccessManager_BindUserRole_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1345,15 +2287,6 @@ func RegisterAccessManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("DELETE", pattern_AccessManager_UnbindUserRole_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1375,25 +2308,25 @@ func RegisterAccessManagerHandlerClient(ctx context.Context, mux *runtime.ServeM } var ( - pattern_AccessManager_CanDo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "cando"}, "")) + pattern_AccessManager_CanDo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "cando"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccessManager_GetRoleModule_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "module")) + pattern_AccessManager_GetRoleModule_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "module", runtime.AssumeColonVerbOpt(true))) - pattern_AccessManager_ModifyRoleModule_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "module")) + pattern_AccessManager_ModifyRoleModule_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "module", runtime.AssumeColonVerbOpt(true))) - pattern_AccessManager_CreateRole_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "")) + pattern_AccessManager_CreateRole_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccessManager_DeleteRoles_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "")) + pattern_AccessManager_DeleteRoles_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccessManager_ModifyRole_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "")) + pattern_AccessManager_ModifyRole_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccessManager_GetRole_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "role"}, "")) + pattern_AccessManager_GetRole_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "role"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccessManager_DescribeRoles_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "")) + pattern_AccessManager_DescribeRoles_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "roles"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AccessManager_BindUserRole_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "user"}, "role")) + pattern_AccessManager_BindUserRole_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "user"}, "role", runtime.AssumeColonVerbOpt(true))) - pattern_AccessManager_UnbindUserRole_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "user"}, "role")) + pattern_AccessManager_UnbindUserRole_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "user"}, "role", runtime.AssumeColonVerbOpt(true))) ) var ( @@ -1459,15 +2392,6 @@ func RegisterTokenManagerHandlerClient(ctx context.Context, mux *runtime.ServeMu mux.Handle("POST", pattern_TokenManager_CreateClient_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1488,15 +2412,6 @@ func RegisterTokenManagerHandlerClient(ctx context.Context, mux *runtime.ServeMu mux.Handle("POST", pattern_TokenManager_Token_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1518,9 +2433,9 @@ func RegisterTokenManagerHandlerClient(ctx context.Context, mux *runtime.ServeMu } var ( - pattern_TokenManager_CreateClient_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "oauth2", "client"}, "")) + pattern_TokenManager_CreateClient_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "oauth2", "client"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_TokenManager_Token_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "oauth2", "token"}, "")) + pattern_TokenManager_Token_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "oauth2", "token"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/app.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/app.pb.go index 86a4d398def52bc964d5516dd13230a5951831ed..49945633a4472800c98139a518910700cd22896b 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/app.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/app.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -11,9 +12,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +27,7 @@ var _ = math.Inf // 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 UploadAppAttachmentRequest_Type int32 @@ -64,10 +66,12 @@ type CreateAppRequest struct { // app icon Icon *wrappers.BytesValue `protobuf:"bytes,6,opt,name=icon,proto3" json:"icon,omitempty"` // isv - Isv *wrappers.StringValue `protobuf:"bytes,7,opt,name=isv,proto3" json:"isv,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + Isv *wrappers.StringValue `protobuf:"bytes,7,opt,name=isv,proto3" json:"isv,omitempty"` + // categories + Categories []string `protobuf:"bytes,8,rep,name=categories,proto3" json:"categories,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *CreateAppRequest) Reset() { *m = CreateAppRequest{} } @@ -137,6 +141,13 @@ func (m *CreateAppRequest) GetIsv() *wrappers.StringValue { return nil } +func (m *CreateAppRequest) GetCategories() []string { + if m != nil { + return m.Categories + } + return nil +} + type CreateAppResponse struct { // app id AppId *wrappers.StringValue `protobuf:"bytes,1,opt,name=app_id,json=appId,proto3" json:"app_id,omitempty"` @@ -1982,7 +1993,7 @@ func (m *AppVersionReview) GetVersionType() *wrappers.StringValue { } type DescribeAppVersionReviewsRequest struct { - // query key, support these fields(review_id, version_id, app_id, status, reviewer) + // query key, support these fields(review_id, version_id, app_id, status, reviewer, app_name, owner) SearchWord *wrappers.StringValue `protobuf:"bytes,1,opt,name=search_word,json=searchWord,proto3" json:"search_word,omitempty"` // sort key, order by sort_key, default create_time SortKey *wrappers.StringValue `protobuf:"bytes,2,opt,name=sort_key,json=sortKey,proto3" json:"sort_key,omitempty"` @@ -3723,255 +3734,256 @@ func init() { func init() { proto.RegisterFile("app.proto", fileDescriptor_e0f9056a14b86d47) } var fileDescriptor_e0f9056a14b86d47 = []byte{ - // 3971 bytes of a gzipped FileDescriptorProto + // 3987 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x5b, 0x4d, 0x6c, 0x24, 0x49, 0x56, 0xde, 0xac, 0xb2, 0xdd, 0xf6, 0x2b, 0xbb, 0xed, 0x0a, 0xb7, 0xed, 0x72, 0xf5, 0x5f, 0x76, 0x76, 0xef, 0xf4, 0x5f, 0xb5, 0x3d, 0xeb, 0x99, 0xd9, 0x69, 0x66, 0x98, 0x6e, 0x55, 0x77, 0xcf, 0xec, 0xf4, 0xc2, 0x36, 0x4d, 0xb5, 0xa7, 0x1b, 0x1a, 0x89, 0x22, 0x5c, 0x15, 0xb6, 0x73, 0xbb, - 0x9c, 0x99, 0x9b, 0x11, 0x65, 0xe3, 0x0b, 0x87, 0x95, 0xf6, 0x8a, 0x44, 0xad, 0x04, 0x08, 0x2d, - 0x1a, 0xfe, 0xa5, 0x1d, 0x89, 0x15, 0x02, 0x56, 0x5a, 0x60, 0xa4, 0x15, 0xb0, 0xe2, 0xc2, 0x8f, - 0x90, 0xb8, 0x71, 0xe0, 0xc4, 0x09, 0x89, 0x0b, 0x67, 0x0e, 0x28, 0x7e, 0x32, 0x33, 0x32, 0xab, - 0xb2, 0x2a, 0xb3, 0x5c, 0xd6, 0xb0, 0xda, 0x39, 0xd9, 0x95, 0xf1, 0x5e, 0xc4, 0x8b, 0xf7, 0xbe, - 0x78, 0x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b, 0xce, 0xf8, 0xc4, 0x73, 0xb9, - 0x6c, 0x53, 0xd9, 0x8e, 0xbd, 0xe7, 0x3e, 0x6e, 0x27, 0xdd, 0xe2, 0x74, 0x5e, 0xb7, 0xf8, 0x26, - 0xcc, 0x50, 0x86, 0x59, 0x97, 0x66, 0x0a, 0x27, 0x8a, 0x36, 0x74, 0xa6, 0x67, 0x32, 0x3b, 0xd3, - 0xd7, 0x55, 0x66, 0x95, 0xc5, 0x13, 0xca, 0xd4, 0xea, 0x1e, 0x94, 0x22, 0xc0, 0xd1, 0x4c, 0xbe, - 0x50, 0x67, 0x48, 0xba, 0x6f, 0xc8, 0xeb, 0xbe, 0x75, 0x0f, 0x55, 0xca, 0xe3, 0xa1, 0x74, 0xc7, - 0x3f, 0x3f, 0x9e, 0xe3, 0x5f, 0xc8, 0xe1, 0xf8, 0xdf, 0x05, 0x68, 0xed, 0x63, 0x9f, 0xc9, 0x24, - 0xe4, 0x6c, 0x96, 0x3c, 0x50, 0xd0, 0x3f, 0xc1, 0xfd, 0x51, 0x63, 0x71, 0xcc, 0xa8, 0xb1, 0x94, - 0x35, 0x6a, 0x6c, 0xc1, 0xb4, 0x7b, 0xe4, 0x10, 0xbf, 0x52, 0xce, 0x72, 0xfe, 0x04, 0x29, 0x7a, - 0x17, 0x4a, 0x2d, 0x91, 0x32, 0x37, 0x79, 0x59, 0x54, 0x41, 0x29, 0x87, 0x70, 0x3b, 0xa8, 0x99, - 0x1a, 0x20, 0xc9, 0xf9, 0x03, 0xce, 0x2c, 0x31, 0x2b, 0x99, 0x97, 0x47, 0x33, 0x4b, 0xf2, 0x80, - 0xb9, 0xeb, 0xb5, 0xc3, 0x95, 0xcf, 0x8d, 0x66, 0x96, 0xe4, 0x82, 0xf9, 0x3e, 0xcc, 0x87, 0x01, - 0x92, 0x12, 0x56, 0x59, 0x11, 0xf9, 0xed, 0x05, 0x3d, 0x22, 0x34, 0x88, 0x34, 0xfd, 0x43, 0x45, - 0xd7, 0x08, 0x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0xd8, 0x74, - 0x3d, 0x93, 0xb9, 0x6e, 0xe7, 0xa6, 0x90, 0xf0, 0x92, 0xb5, 0x1e, 0x48, 0xb8, 0x79, 0xa8, 0x78, - 0x83, 0x6f, 0x61, 0xb8, 0xc8, 0xbf, 0x63, 0xc0, 0x52, 0x32, 0x0f, 0x43, 0x57, 0x87, 0x67, 0x69, - 0x52, 0xe8, 0x6b, 0x59, 0x52, 0x39, 0xeb, 0xdd, 0x5e, 0xfd, 0x22, 0xe2, 0x05, 0x92, 0x49, 0xc3, - 0x41, 0xd3, 0x76, 0x76, 0x5d, 0x2e, 0x39, 0x97, 0x4a, 0x48, 0xb9, 0x82, 0x96, 0x43, 0x29, 0x23, - 0x3a, 0xf4, 0x7b, 0x05, 0x98, 0xd7, 0xdf, 0x31, 0x42, 0x97, 0xf5, 0x35, 0x07, 0xbc, 0x5d, 0x56, - 0x35, 0xd3, 0x09, 0x94, 0x40, 0xff, 0x64, 0xf4, 0xea, 0x3f, 0x30, 0xd0, 0xf7, 0x0d, 0x2e, 0x13, - 0x5f, 0xb0, 0x26, 0x0c, 0xbd, 0x6b, 0x77, 0x18, 0xf1, 0xcd, 0x23, 0x9b, 0xed, 0x73, 0x33, 0x53, - 0x62, 0xee, 0xda, 0xa4, 0xd3, 0xa6, 0x37, 0x64, 0x11, 0x55, 0x33, 0x79, 0x4d, 0x5b, 0x33, 0xd5, - 0x71, 0xa9, 0x99, 0x5a, 0xe5, 0x5b, 0x33, 0x65, 0x19, 0x5b, 0x33, 0xf7, 0x5d, 0x4e, 0x63, 0xb7, - 0xc4, 0xb3, 0xe8, 0x2e, 0xbd, 0x66, 0x6a, 0x17, 0xe3, 0x35, 0x53, 0xdd, 0x57, 0xf3, 0xc9, 0x70, - 0x9b, 0x33, 0x88, 0x0a, 0xbb, 0x66, 0x46, 0x2f, 0x72, 0xdd, 0xe4, 0xf3, 0xef, 0xe2, 0x6e, 0x87, - 0x99, 0x3e, 0x61, 0x5d, 0xdf, 0x31, 0x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d, 0x87, 0x61, 0xdb, + 0x21, 0x3e, 0xcd, 0xe4, 0x03, 0x74, 0x06, 0xf4, 0x65, 0x38, 0x43, 0xdd, 0xae, 0xdf, 0x12, 0x8e, + 0x60, 0x34, 0x6f, 0x40, 0x8c, 0xde, 0x84, 0x19, 0x9f, 0xe0, 0xf6, 0x01, 0xa9, 0xcc, 0x65, 0x60, + 0x53, 0xb4, 0x5c, 0x5a, 0xbc, 0x43, 0x99, 0x8f, 0x5b, 0x42, 0x3f, 0x90, 0x45, 0x5a, 0x8d, 0x81, + 0x83, 0x91, 0xb9, 0xb4, 0x52, 0xca, 0x02, 0x46, 0xe6, 0x52, 0xf4, 0x1e, 0x94, 0x94, 0x5f, 0x3b, + 0xe6, 0xb6, 0x9f, 0xcf, 0xc0, 0x17, 0x38, 0xc2, 0xe3, 0xc7, 0x6d, 0x74, 0x17, 0x66, 0x5f, 0x91, + 0xe3, 0x23, 0xd7, 0x6f, 0xd3, 0xca, 0x42, 0x06, 0xde, 0x90, 0xda, 0xfa, 0x10, 0xca, 0x1a, 0x06, + 0x4f, 0xe0, 0x41, 0xad, 0xbf, 0x29, 0x40, 0xf5, 0x23, 0xaf, 0xe3, 0xe2, 0x76, 0xdd, 0xf3, 0xea, + 0x8c, 0xe1, 0xd6, 0xfe, 0x01, 0x71, 0xd8, 0x89, 0x80, 0x7d, 0x1f, 0xa6, 0x42, 0xb7, 0x79, 0x76, + 0xeb, 0xb6, 0xee, 0xcd, 0xd2, 0x97, 0xda, 0xe0, 0x6e, 0xb5, 0x21, 0x18, 0xd1, 0x57, 0x01, 0xe1, + 0x70, 0xbc, 0xd9, 0x72, 0x1d, 0x46, 0x1c, 0x96, 0x25, 0x58, 0x96, 0x23, 0xb6, 0x87, 0x92, 0x8b, + 0x2b, 0x99, 0xf2, 0x15, 0x9c, 0x56, 0x3a, 0xee, 0x3f, 0x7a, 0xec, 0xb0, 0x37, 0xb6, 0x94, 0x92, + 0x03, 0x6a, 0xcb, 0x84, 0x29,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 0xaa, + 0xde, 0x87, 0x72, 0x1f, 0xc9, 0xa8, 0x4e, 0xc7, 0xbc, 0xde, 0xe9, 0x78, 0x01, 0x95, 0xfe, 0xb5, + 0x27, 0x61, 0xf7, 0xef, 0x01, 0x80, 0x16, 0x9d, 0x4f, 0x64, 0xea, 0x71, 0x0a, 0x93, 0xe8, 0x80, + 0x17, 0xf3, 0x54, 0x40, 0xca, 0x4b, 0x4e, 0x65, 0xcf, 0xda, 0x02, 0x1c, 0x4e, 0x8f, 0x8b, 0xc3, + 0x99, 0x71, 0x3b, 0x3c, 0x9f, 0x17, 0x25, 0x9f, 0x7d, 0x51, 0x72, 0x1f, 0x82, 0x03, 0x99, 0xbd, + 0x2c, 0x29, 0x29, 0x0e, 0x11, 0x63, 0xa3, 0xba, 0x74, 0x31, 0x47, 0x5d, 0xfa, 0x53, 0x30, 0xe7, + 0x93, 0x43, 0x9b, 0x1c, 0x71, 0x80, 0x67, 0x29, 0x4a, 0x66, 0x25, 0xb9, 0x68, 0xa7, 0xc7, 0xaa, + 0x8c, 0xf2, 0x49, 0xaa, 0x0c, 0x74, 0x92, 0x2a, 0x63, 0x39, 0x57, 0x95, 0xa1, 0xb7, 0x78, 0xce, + 0xe5, 0x69, 0xf1, 0x70, 0x40, 0x1c, 0x10, 0x4a, 0xb9, 0xdb, 0x5e, 0xc9, 0x02, 0x08, 0x45, 0x1c, + 0xc6, 0xde, 0xd5, 0xcc, 0xb1, 0x37, 0x9e, 0x21, 0xaf, 0xe5, 0xca, 0x90, 0xad, 0x3f, 0x98, 0x86, + 0xc5, 0xc8, 0x61, 0xd6, 0xbb, 0x6d, 0xfb, 0x84, 0x01, 0x32, 0xf2, 0x80, 0x85, 0xec, 0x1e, 0x30, + 0x82, 0x63, 0x31, 0x07, 0x1c, 0x4f, 0x7c, 0x43, 0xf0, 0x36, 0xcc, 0x72, 0x59, 0x33, 0x3b, 0x52, + 0x9e, 0x02, 0x0a, 0xc6, 0xbb, 0x30, 0xeb, 0x7a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0x11, 0x13, + 0xe9, 0x25, 0xc7, 0xf7, 0x8a, 0x60, 0x6a, 0xa5, 0x7f, 0x8c, 0xf8, 0x27, 0xac, 0xcf, 0x03, 0x7a, + 0x9f, 0xe7, 0x62, 0xec, 0x34, 0xca, 0x16, 0x90, 0x76, 0xde, 0xce, 0xeb, 0xe7, 0x5c, 0xf6, 0x82, + 0xa2, 0x93, 0x1c, 0xb5, 0x7d, 0x16, 0x62, 0x6d, 0x9f, 0x01, 0x0d, 0x9a, 0xb3, 0x03, 0x1b, 0x34, + 0x55, 0x0d, 0x6c, 0x8b, 0xfa, 0xe4, 0xc4, 0xb7, 0x7e, 0xdb, 0x80, 0x2b, 0x43, 0x0c, 0x96, 0xb5, + 0x71, 0xf3, 0xf3, 0xb0, 0xaa, 0x37, 0x68, 0xd5, 0x66, 0xa2, 0x3e, 0xce, 0x85, 0x61, 0x28, 0x6a, + 0x2c, 0xe3, 0xc4, 0x93, 0x67, 0x84, 0x59, 0xdf, 0x2f, 0xc2, 0xe5, 0x7e, 0xc9, 0x44, 0xee, 0xf4, + 0x39, 0x92, 0x52, 0x91, 0x14, 0x81, 0x65, 0x3e, 0x06, 0x96, 0xaa, 0x16, 0x8d, 0x25, 0x8c, 0xa2, + 0x78, 0x7b, 0x35, 0x19, 0x6f, 0x25, 0x8c, 0xe2, 0x11, 0x75, 0x00, 0xda, 0x16, 0x07, 0xa1, 0xcd, + 0xfa, 0xb6, 0x31, 0xc8, 0x05, 0x04, 0x76, 0xcb, 0x0a, 0xa8, 0x27, 0xb0, 0xa2, 0x03, 0x0a, 0x73, + 0x76, 0x0d, 0x4f, 0xe7, 0x07, 0xe3, 0x49, 0xac, 0xd2, 0x40, 0x38, 0xfe, 0x80, 0xa3, 0xe9, 0x7f, + 0x8a, 0x50, 0xed, 0x97, 0xea, 0x27, 0x02, 0x48, 0x71, 0xc4, 0x40, 0x12, 0x31, 0x39, 0x3a, 0xd3, + 0x61, 0xa3, 0x79, 0x41, 0x6f, 0x34, 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x89, 0x3f, 0x32, 0xa0, 0xdc, 0x77, 0x6d, 0x84, 0x12, 0xc9, 0xef, 0xe0, 0xeb, 0xaa, 0x78, + 0x42, 0x97, 0x7a, 0xf7, 0x64, 0xd5, 0x7b, 0xf5, 0x15, 0xb4, 0xac, 0xc6, 0xf5, 0x42, 0x77, 0x44, + 0x26, 0x47, 0x25, 0x07, 0x97, 0xf2, 0x4f, 0x45, 0xda, 0x99, 0xb8, 0x29, 0x4a, 0xa6, 0x9d, 0x83, + 0x6f, 0xa8, 0x92, 0x69, 0x67, 0xca, 0x75, 0x93, 0xf5, 0xa8, 0x57, 0xaf, 0xa0, 0x55, 0x35, 0xae, + 0xeb, 0x35, 0x4b, 0xca, 0x29, 0x98, 0xde, 0x31, 0x6e, 0x3d, 0x98, 0x7a, 0x59, 0xf0, 0x76, 0x76, + 0x66, 0xc4, 0xf5, 0xd4, 0x1b, 0xff, 0x17, 0x00, 0x00, 0xff, 0xff, 0xd4, 0x78, 0x6d, 0xac, 0x98, 0x4e, 0x00, 0x00, } @@ -4441,6 +4453,113 @@ type AppManagerServer interface { RecoverAppVersion(context.Context, *RecoverAppVersionRequest) (*RecoverAppVersionResponse, error) } +// UnimplementedAppManagerServer can be embedded to have forward compatible implementations. +type UnimplementedAppManagerServer struct { +} + +func (*UnimplementedAppManagerServer) SyncRepo(ctx context.Context, req *SyncRepoRequest) (*SyncRepoResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SyncRepo not implemented") +} +func (*UnimplementedAppManagerServer) CreateApp(ctx context.Context, req *CreateAppRequest) (*CreateAppResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateApp not implemented") +} +func (*UnimplementedAppManagerServer) ValidatePackage(ctx context.Context, req *ValidatePackageRequest) (*ValidatePackageResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ValidatePackage not implemented") +} +func (*UnimplementedAppManagerServer) GetAppStatistics(ctx context.Context, req *GetAppStatisticsRequest) (*GetAppStatisticsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetAppStatistics not implemented") +} +func (*UnimplementedAppManagerServer) DescribeApps(ctx context.Context, req *DescribeAppsRequest) (*DescribeAppsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeApps not implemented") +} +func (*UnimplementedAppManagerServer) DescribeActiveApps(ctx context.Context, req *DescribeAppsRequest) (*DescribeAppsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeActiveApps not implemented") +} +func (*UnimplementedAppManagerServer) ModifyApp(ctx context.Context, req *ModifyAppRequest) (*ModifyAppResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyApp not implemented") +} +func (*UnimplementedAppManagerServer) UploadAppAttachment(ctx context.Context, req *UploadAppAttachmentRequest) (*UploadAppAttachmentResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UploadAppAttachment not implemented") +} +func (*UnimplementedAppManagerServer) DeleteApps(ctx context.Context, req *DeleteAppsRequest) (*DeleteAppsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteApps not implemented") +} +func (*UnimplementedAppManagerServer) CreateAppVersion(ctx context.Context, req *CreateAppVersionRequest) (*CreateAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) DescribeAppVersions(ctx context.Context, req *DescribeAppVersionsRequest) (*DescribeAppVersionsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeAppVersions not implemented") +} +func (*UnimplementedAppManagerServer) DescribeActiveAppVersions(ctx context.Context, req *DescribeAppVersionsRequest) (*DescribeAppVersionsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeActiveAppVersions not implemented") +} +func (*UnimplementedAppManagerServer) DescribeAppVersionAudits(ctx context.Context, req *DescribeAppVersionAuditsRequest) (*DescribeAppVersionAuditsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeAppVersionAudits not implemented") +} +func (*UnimplementedAppManagerServer) DescribeAppVersionReviews(ctx context.Context, req *DescribeAppVersionReviewsRequest) (*DescribeAppVersionReviewsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeAppVersionReviews not implemented") +} +func (*UnimplementedAppManagerServer) ModifyAppVersion(ctx context.Context, req *ModifyAppVersionRequest) (*ModifyAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) GetAppVersionPackage(ctx context.Context, req *GetAppVersionPackageRequest) (*GetAppVersionPackageResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetAppVersionPackage not implemented") +} +func (*UnimplementedAppManagerServer) GetAppVersionPackageFiles(ctx context.Context, req *GetAppVersionPackageFilesRequest) (*GetAppVersionPackageFilesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetAppVersionPackageFiles not implemented") +} +func (*UnimplementedAppManagerServer) SubmitAppVersion(ctx context.Context, req *SubmitAppVersionRequest) (*SubmitAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SubmitAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) CancelAppVersion(ctx context.Context, req *CancelAppVersionRequest) (*CancelAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CancelAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) ReleaseAppVersion(ctx context.Context, req *ReleaseAppVersionRequest) (*ReleaseAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ReleaseAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) DeleteAppVersion(ctx context.Context, req *DeleteAppVersionRequest) (*DeleteAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) IsvReviewAppVersion(ctx context.Context, req *ReviewAppVersionRequest) (*ReviewAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method IsvReviewAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) IsvPassAppVersion(ctx context.Context, req *PassAppVersionRequest) (*PassAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method IsvPassAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) IsvRejectAppVersion(ctx context.Context, req *RejectAppVersionRequest) (*RejectAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method IsvRejectAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) BusinessReviewAppVersion(ctx context.Context, req *ReviewAppVersionRequest) (*ReviewAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method BusinessReviewAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) BusinessPassAppVersion(ctx context.Context, req *PassAppVersionRequest) (*PassAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method BusinessPassAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) BusinessRejectAppVersion(ctx context.Context, req *RejectAppVersionRequest) (*RejectAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method BusinessRejectAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) TechnicalReviewAppVersion(ctx context.Context, req *ReviewAppVersionRequest) (*ReviewAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method TechnicalReviewAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) TechnicalPassAppVersion(ctx context.Context, req *PassAppVersionRequest) (*PassAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method TechnicalPassAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) TechnicalRejectAppVersion(ctx context.Context, req *RejectAppVersionRequest) (*RejectAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method TechnicalRejectAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) AdminPassAppVersion(ctx context.Context, req *PassAppVersionRequest) (*PassAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method AdminPassAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) AdminRejectAppVersion(ctx context.Context, req *RejectAppVersionRequest) (*RejectAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method AdminRejectAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) SuspendAppVersion(ctx context.Context, req *SuspendAppVersionRequest) (*SuspendAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SuspendAppVersion not implemented") +} +func (*UnimplementedAppManagerServer) RecoverAppVersion(ctx context.Context, req *RecoverAppVersionRequest) (*RecoverAppVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RecoverAppVersion not implemented") +} + func RegisterAppManagerServer(s *grpc.Server, srv AppManagerServer) { s.RegisterService(&_AppManager_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/app.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/app.pb.gw.go index cf15748aedbd649a8ec70b267845ca3a8531123d..36fe702d3b113c16b41bd5b7297ad6472b859f96 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/app.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/app.pb.gw.go @@ -9,30 +9,37 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage func request_AppManager_CreateApp_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateAppRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -41,11 +48,32 @@ func request_AppManager_CreateApp_0(ctx context.Context, marshaler runtime.Marsh } +func local_request_AppManager_CreateApp_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateAppRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateApp(ctx, &protoReq) + return msg, metadata, err + +} + func request_AppManager_ValidatePackage_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ValidatePackageRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -54,6 +82,23 @@ func request_AppManager_ValidatePackage_0(ctx context.Context, marshaler runtime } +func local_request_AppManager_ValidatePackage_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ValidatePackageRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ValidatePackage(ctx, &protoReq) + return msg, metadata, err + +} + func request_AppManager_GetAppStatistics_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq GetAppStatisticsRequest var metadata runtime.ServerMetadata @@ -63,6 +108,15 @@ func request_AppManager_GetAppStatistics_0(ctx context.Context, marshaler runtim } +func local_request_AppManager_GetAppStatistics_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetAppStatisticsRequest + var metadata runtime.ServerMetadata + + msg, err := server.GetAppStatistics(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AppManager_DescribeApps_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -71,7 +125,10 @@ func request_AppManager_DescribeApps_0(ctx context.Context, marshaler runtime.Ma var protoReq DescribeAppsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeApps_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AppManager_DescribeApps_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -80,6 +137,19 @@ func request_AppManager_DescribeApps_0(ctx context.Context, marshaler runtime.Ma } +func local_request_AppManager_DescribeApps_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeAppsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeApps_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeApps(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AppManager_DescribeActiveApps_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -88,7 +158,10 @@ func request_AppManager_DescribeActiveApps_0(ctx context.Context, marshaler runt var protoReq DescribeAppsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeActiveApps_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AppManager_DescribeActiveApps_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -97,11 +170,28 @@ func request_AppManager_DescribeActiveApps_0(ctx context.Context, marshaler runt } +func local_request_AppManager_DescribeActiveApps_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeAppsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeActiveApps_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeActiveApps(ctx, &protoReq) + return msg, metadata, err + +} + func request_AppManager_ModifyApp_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyAppRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -110,11 +200,32 @@ func request_AppManager_ModifyApp_0(ctx context.Context, marshaler runtime.Marsh } +func local_request_AppManager_ModifyApp_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyAppRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyApp(ctx, &protoReq) + return msg, metadata, err + +} + func request_AppManager_UploadAppAttachment_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq UploadAppAttachmentRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -123,11 +234,32 @@ func request_AppManager_UploadAppAttachment_0(ctx context.Context, marshaler run } +func local_request_AppManager_UploadAppAttachment_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UploadAppAttachmentRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.UploadAppAttachment(ctx, &protoReq) + return msg, metadata, err + +} + func request_AppManager_DeleteApps_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DeleteAppsRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -136,11 +268,32 @@ func request_AppManager_DeleteApps_0(ctx context.Context, marshaler runtime.Mars } +func local_request_AppManager_DeleteApps_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteAppsRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteApps(ctx, &protoReq) + return msg, metadata, err + +} + func request_AppManager_CreateAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateAppVersionRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -149,6 +302,23 @@ func request_AppManager_CreateAppVersion_0(ctx context.Context, marshaler runtim } +func local_request_AppManager_CreateAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AppManager_DescribeAppVersions_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -157,7 +327,10 @@ func request_AppManager_DescribeAppVersions_0(ctx context.Context, marshaler run var protoReq DescribeAppVersionsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeAppVersions_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AppManager_DescribeAppVersions_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -166,6 +339,19 @@ func request_AppManager_DescribeAppVersions_0(ctx context.Context, marshaler run } +func local_request_AppManager_DescribeAppVersions_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeAppVersionsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeAppVersions_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeAppVersions(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AppManager_DescribeActiveAppVersions_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -174,7 +360,10 @@ func request_AppManager_DescribeActiveAppVersions_0(ctx context.Context, marshal var protoReq DescribeAppVersionsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeActiveAppVersions_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AppManager_DescribeActiveAppVersions_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -183,6 +372,19 @@ func request_AppManager_DescribeActiveAppVersions_0(ctx context.Context, marshal } +func local_request_AppManager_DescribeActiveAppVersions_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeAppVersionsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeActiveAppVersions_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeActiveAppVersions(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AppManager_DescribeAppVersionAudits_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -191,7 +393,10 @@ func request_AppManager_DescribeAppVersionAudits_0(ctx context.Context, marshale var protoReq DescribeAppVersionAuditsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeAppVersionAudits_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AppManager_DescribeAppVersionAudits_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -200,6 +405,19 @@ func request_AppManager_DescribeAppVersionAudits_0(ctx context.Context, marshale } +func local_request_AppManager_DescribeAppVersionAudits_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeAppVersionAuditsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeAppVersionAudits_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeAppVersionAudits(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AppManager_DescribeAppVersionReviews_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -208,7 +426,10 @@ func request_AppManager_DescribeAppVersionReviews_0(ctx context.Context, marshal var protoReq DescribeAppVersionReviewsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeAppVersionReviews_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AppManager_DescribeAppVersionReviews_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -217,11 +438,28 @@ func request_AppManager_DescribeAppVersionReviews_0(ctx context.Context, marshal } +func local_request_AppManager_DescribeAppVersionReviews_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeAppVersionReviewsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_DescribeAppVersionReviews_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeAppVersionReviews(ctx, &protoReq) + return msg, metadata, err + +} + func request_AppManager_ModifyAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyAppVersionRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -230,6 +468,23 @@ func request_AppManager_ModifyAppVersion_0(ctx context.Context, marshaler runtim } +func local_request_AppManager_ModifyAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AppManager_GetAppVersionPackage_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -238,7 +493,10 @@ func request_AppManager_GetAppVersionPackage_0(ctx context.Context, marshaler ru var protoReq GetAppVersionPackageRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_GetAppVersionPackage_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AppManager_GetAppVersionPackage_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -247,6 +505,19 @@ func request_AppManager_GetAppVersionPackage_0(ctx context.Context, marshaler ru } +func local_request_AppManager_GetAppVersionPackage_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetAppVersionPackageRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_GetAppVersionPackage_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.GetAppVersionPackage(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_AppManager_GetAppVersionPackageFiles_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -255,7 +526,10 @@ func request_AppManager_GetAppVersionPackageFiles_0(ctx context.Context, marshal var protoReq GetAppVersionPackageFilesRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_GetAppVersionPackageFiles_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AppManager_GetAppVersionPackageFiles_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -264,11 +538,28 @@ func request_AppManager_GetAppVersionPackageFiles_0(ctx context.Context, marshal } +func local_request_AppManager_GetAppVersionPackageFiles_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetAppVersionPackageFilesRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AppManager_GetAppVersionPackageFiles_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.GetAppVersionPackageFiles(ctx, &protoReq) + return msg, metadata, err + +} + func request_AppManager_SubmitAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq SubmitAppVersionRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -277,11 +568,32 @@ func request_AppManager_SubmitAppVersion_0(ctx context.Context, marshaler runtim } +func local_request_AppManager_SubmitAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq SubmitAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.SubmitAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + func request_AppManager_CancelAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CancelAppVersionRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -290,199 +602,1199 @@ func request_AppManager_CancelAppVersion_0(ctx context.Context, marshaler runtim } -func request_AppManager_ReleaseAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq ReleaseAppVersionRequest +func local_request_AppManager_CancelAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CancelAppVersionRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } - msg, err := client.ReleaseAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := server.CancelAppVersion(ctx, &protoReq) return msg, metadata, err } -func request_AppManager_DeleteAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq DeleteAppVersionRequest +func request_AppManager_ReleaseAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ReleaseAppVersionRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } - msg, err := client.DeleteAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.ReleaseAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func request_AppManager_IsvReviewAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq ReviewAppVersionRequest +func local_request_AppManager_ReleaseAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ReleaseAppVersionRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } - msg, err := client.IsvReviewAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := server.ReleaseAppVersion(ctx, &protoReq) return msg, metadata, err } -func request_AppManager_IsvPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq PassAppVersionRequest +func request_AppManager_DeleteAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteAppVersionRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } - msg, err := client.IsvPassAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.DeleteAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func request_AppManager_IsvRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq RejectAppVersionRequest +func local_request_AppManager_DeleteAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteAppVersionRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } - msg, err := client.IsvRejectAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := server.DeleteAppVersion(ctx, &protoReq) return msg, metadata, err } -func request_AppManager_BusinessReviewAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { +func request_AppManager_IsvReviewAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ReviewAppVersionRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } - msg, err := client.BusinessReviewAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := client.IsvReviewAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } -func request_AppManager_BusinessPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq PassAppVersionRequest +func local_request_AppManager_IsvReviewAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ReviewAppVersionRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } - msg, err := client.BusinessPassAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + msg, err := server.IsvReviewAppVersion(ctx, &protoReq) return msg, metadata, err -} +} + +func request_AppManager_IsvPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq PassAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.IsvPassAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_IsvPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq PassAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.IsvPassAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AppManager_IsvRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RejectAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.IsvRejectAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_IsvRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RejectAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.IsvRejectAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AppManager_BusinessReviewAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ReviewAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.BusinessReviewAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_BusinessReviewAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ReviewAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.BusinessReviewAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AppManager_BusinessPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq PassAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.BusinessPassAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_BusinessPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq PassAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.BusinessPassAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AppManager_BusinessRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RejectAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.BusinessRejectAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_BusinessRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RejectAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.BusinessRejectAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AppManager_TechnicalReviewAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ReviewAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.TechnicalReviewAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_TechnicalReviewAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ReviewAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.TechnicalReviewAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AppManager_TechnicalPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq PassAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.TechnicalPassAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_TechnicalPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq PassAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.TechnicalPassAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AppManager_TechnicalRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RejectAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.TechnicalRejectAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_TechnicalRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RejectAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.TechnicalRejectAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AppManager_AdminPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq PassAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.AdminPassAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_AdminPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq PassAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.AdminPassAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AppManager_AdminRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RejectAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.AdminRejectAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_AdminRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RejectAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.AdminRejectAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AppManager_SuspendAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq SuspendAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.SuspendAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_SuspendAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq SuspendAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.SuspendAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +func request_AppManager_RecoverAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RecoverAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.RecoverAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_AppManager_RecoverAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, server AppManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RecoverAppVersionRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.RecoverAppVersion(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterAppManagerHandlerServer registers the http handlers for service AppManager to "mux". +// UnaryRPC :call AppManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterAppManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server AppManagerServer) error { + + mux.Handle("POST", pattern_AppManager_CreateApp_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_CreateApp_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_CreateApp_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AppManager_ValidatePackage_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_ValidatePackage_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_ValidatePackage_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AppManager_GetAppStatistics_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_GetAppStatistics_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_GetAppStatistics_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AppManager_DescribeApps_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_DescribeApps_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_DescribeApps_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AppManager_DescribeActiveApps_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_DescribeActiveApps_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_DescribeActiveApps_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_AppManager_ModifyApp_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_ModifyApp_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_ModifyApp_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_AppManager_UploadAppAttachment_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_UploadAppAttachment_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_UploadAppAttachment_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_AppManager_DeleteApps_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_DeleteApps_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_DeleteApps_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AppManager_CreateAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_CreateAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_CreateAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AppManager_DescribeAppVersions_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_DescribeAppVersions_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_DescribeAppVersions_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AppManager_DescribeActiveAppVersions_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_DescribeActiveAppVersions_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_DescribeActiveAppVersions_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AppManager_DescribeAppVersionAudits_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_DescribeAppVersionAudits_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_DescribeAppVersionAudits_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AppManager_DescribeAppVersionReviews_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_DescribeAppVersionReviews_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_DescribeAppVersionReviews_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_AppManager_ModifyAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_ModifyAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_ModifyAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AppManager_GetAppVersionPackage_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_GetAppVersionPackage_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_GetAppVersionPackage_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_AppManager_GetAppVersionPackageFiles_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_GetAppVersionPackageFiles_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_GetAppVersionPackageFiles_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AppManager_SubmitAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_SubmitAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_SubmitAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AppManager_CancelAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_CancelAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_CancelAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AppManager_ReleaseAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_ReleaseAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_ReleaseAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AppManager_DeleteAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_DeleteAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_DeleteAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AppManager_IsvReviewAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_IsvReviewAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_IsvReviewAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AppManager_IsvPassAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_IsvPassAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_IsvPassAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_AppManager_IsvRejectAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_IsvRejectAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AppManager_IsvRejectAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -func request_AppManager_BusinessRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq RejectAppVersionRequest - var metadata runtime.ServerMetadata + }) - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + mux.Handle("POST", pattern_AppManager_BusinessReviewAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_BusinessReviewAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - msg, err := client.BusinessRejectAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + forward_AppManager_BusinessReviewAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -} + }) -func request_AppManager_TechnicalReviewAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq ReviewAppVersionRequest - var metadata runtime.ServerMetadata + mux.Handle("POST", pattern_AppManager_BusinessPassAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_BusinessPassAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + forward_AppManager_BusinessPassAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - msg, err := client.TechnicalReviewAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + }) -} + mux.Handle("POST", pattern_AppManager_BusinessRejectAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_BusinessRejectAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -func request_AppManager_TechnicalPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq PassAppVersionRequest - var metadata runtime.ServerMetadata + forward_AppManager_BusinessRejectAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + }) - msg, err := client.TechnicalPassAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + mux.Handle("POST", pattern_AppManager_TechnicalReviewAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_TechnicalReviewAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -} + forward_AppManager_TechnicalReviewAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -func request_AppManager_TechnicalRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq RejectAppVersionRequest - var metadata runtime.ServerMetadata + }) - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + mux.Handle("POST", pattern_AppManager_TechnicalPassAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_TechnicalPassAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - msg, err := client.TechnicalRejectAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + forward_AppManager_TechnicalPassAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -} + }) -func request_AppManager_AdminPassAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq PassAppVersionRequest - var metadata runtime.ServerMetadata + mux.Handle("POST", pattern_AppManager_TechnicalRejectAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_TechnicalRejectAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + forward_AppManager_TechnicalRejectAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - msg, err := client.AdminPassAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + }) -} + mux.Handle("POST", pattern_AppManager_AdminPassAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_AdminPassAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -func request_AppManager_AdminRejectAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq RejectAppVersionRequest - var metadata runtime.ServerMetadata + forward_AppManager_AdminPassAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + }) - msg, err := client.AdminRejectAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + mux.Handle("POST", pattern_AppManager_AdminRejectAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_AdminRejectAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -} + forward_AppManager_AdminRejectAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -func request_AppManager_SuspendAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq SuspendAppVersionRequest - var metadata runtime.ServerMetadata + }) - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + mux.Handle("POST", pattern_AppManager_SuspendAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_SuspendAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - msg, err := client.SuspendAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + forward_AppManager_SuspendAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -} + }) -func request_AppManager_RecoverAppVersion_0(ctx context.Context, marshaler runtime.Marshaler, client AppManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq RecoverAppVersionRequest - var metadata runtime.ServerMetadata + mux.Handle("POST", pattern_AppManager_RecoverAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AppManager_RecoverAppVersion_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + forward_AppManager_RecoverAppVersion_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - msg, err := client.RecoverAppVersion(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + }) + return nil } // RegisterAppManagerHandlerFromEndpoint is same as RegisterAppManagerHandler but @@ -526,15 +1838,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_CreateApp_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -555,15 +1858,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_ValidatePackage_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -584,15 +1878,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_AppManager_GetAppStatistics_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -613,15 +1898,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_AppManager_DescribeApps_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -642,15 +1918,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_AppManager_DescribeActiveApps_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -671,15 +1938,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("PATCH", pattern_AppManager_ModifyApp_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -700,15 +1958,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("PATCH", pattern_AppManager_UploadAppAttachment_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -729,15 +1978,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("DELETE", pattern_AppManager_DeleteApps_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -758,15 +1998,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_CreateAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -787,15 +2018,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_AppManager_DescribeAppVersions_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -816,15 +2038,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_AppManager_DescribeActiveAppVersions_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -845,15 +2058,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_AppManager_DescribeAppVersionAudits_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -874,15 +2078,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_AppManager_DescribeAppVersionReviews_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -903,15 +2098,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("PATCH", pattern_AppManager_ModifyAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -932,15 +2118,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_AppManager_GetAppVersionPackage_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -961,15 +2138,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_AppManager_GetAppVersionPackageFiles_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -990,15 +2158,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_SubmitAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1019,15 +2178,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_CancelAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1048,15 +2198,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_ReleaseAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1077,15 +2218,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_DeleteAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1106,15 +2238,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_IsvReviewAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1135,15 +2258,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_IsvPassAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1164,15 +2278,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_IsvRejectAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1193,15 +2298,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_BusinessReviewAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1222,15 +2318,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_BusinessPassAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1251,15 +2338,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_BusinessRejectAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1280,15 +2358,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_TechnicalReviewAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1309,15 +2378,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_TechnicalPassAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1338,15 +2398,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_TechnicalRejectAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1367,15 +2418,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_AdminPassAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1396,15 +2438,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_AdminRejectAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1425,15 +2458,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_SuspendAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1454,15 +2478,6 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_AppManager_RecoverAppVersion_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1484,71 +2499,71 @@ func RegisterAppManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, } var ( - pattern_AppManager_CreateApp_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "apps"}, "")) + pattern_AppManager_CreateApp_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "apps"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_ValidatePackage_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "apps", "validate_package"}, "")) + pattern_AppManager_ValidatePackage_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "apps", "validate_package"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_GetAppStatistics_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "apps", "statistics"}, "")) + pattern_AppManager_GetAppStatistics_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "apps", "statistics"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_DescribeApps_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "apps"}, "")) + pattern_AppManager_DescribeApps_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "apps"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_DescribeActiveApps_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "active_apps"}, "")) + pattern_AppManager_DescribeActiveApps_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "active_apps"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_ModifyApp_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "apps"}, "")) + pattern_AppManager_ModifyApp_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "apps"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_UploadAppAttachment_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app", "attachment"}, "")) + pattern_AppManager_UploadAppAttachment_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app", "attachment"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_DeleteApps_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "apps"}, "")) + pattern_AppManager_DeleteApps_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "apps"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_CreateAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_versions"}, "")) + pattern_AppManager_CreateAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_versions"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_DescribeAppVersions_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_versions"}, "")) + pattern_AppManager_DescribeAppVersions_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_versions"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_DescribeActiveAppVersions_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "active_app_versions"}, "")) + pattern_AppManager_DescribeActiveAppVersions_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "active_app_versions"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_DescribeAppVersionAudits_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_version_audits"}, "")) + pattern_AppManager_DescribeAppVersionAudits_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_version_audits"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_DescribeAppVersionReviews_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_version_reviews"}, "")) + pattern_AppManager_DescribeAppVersionReviews_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_version_reviews"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_ModifyAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_versions"}, "")) + pattern_AppManager_ModifyAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_versions"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_GetAppVersionPackage_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app_version", "package"}, "")) + pattern_AppManager_GetAppVersionPackage_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app_version", "package"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_GetAppVersionPackageFiles_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "package", "files"}, "")) + pattern_AppManager_GetAppVersionPackageFiles_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "package", "files"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_SubmitAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "submit"}, "")) + pattern_AppManager_SubmitAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "submit"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_CancelAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "cancel"}, "")) + pattern_AppManager_CancelAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "cancel"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_ReleaseAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "release"}, "")) + pattern_AppManager_ReleaseAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "release"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_DeleteAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "delete"}, "")) + pattern_AppManager_DeleteAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "delete"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_IsvReviewAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "review", "isv"}, "")) + pattern_AppManager_IsvReviewAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "review", "isv"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_IsvPassAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "pass", "isv"}, "")) + pattern_AppManager_IsvPassAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "pass", "isv"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_IsvRejectAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "reject", "isv"}, "")) + pattern_AppManager_IsvRejectAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "reject", "isv"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_BusinessReviewAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "review", "business"}, "")) + pattern_AppManager_BusinessReviewAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "review", "business"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_BusinessPassAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "pass", "business"}, "")) + pattern_AppManager_BusinessPassAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "pass", "business"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_BusinessRejectAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "reject", "business"}, "")) + pattern_AppManager_BusinessRejectAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "reject", "business"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_TechnicalReviewAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "review", "technical"}, "")) + pattern_AppManager_TechnicalReviewAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "review", "technical"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_TechnicalPassAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "pass", "technical"}, "")) + pattern_AppManager_TechnicalPassAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "pass", "technical"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_TechnicalRejectAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "reject", "technical"}, "")) + pattern_AppManager_TechnicalRejectAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "reject", "technical"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_AdminPassAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "pass", "admin"}, "")) + pattern_AppManager_AdminPassAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "pass", "admin"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_AdminRejectAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "reject", "admin"}, "")) + pattern_AppManager_AdminRejectAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"v1", "app_version", "action", "reject", "admin"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_SuspendAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "suspend"}, "")) + pattern_AppManager_SuspendAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "suspend"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_AppManager_RecoverAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "recover"}, "")) + pattern_AppManager_RecoverAppVersion_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "app_version", "action", "recover"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/attachment.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/attachment.pb.go index 689300920aa15892964b2be194522ae1d2039788..d159dffd3f678e5bfad6021b25bac8650a87bb7a 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/attachment.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/attachment.pb.go @@ -4,15 +4,17 @@ package pb import ( + context "context" fmt "fmt" math "math" proto "github.com/golang/protobuf/proto" timestamp "github.com/golang/protobuf/ptypes/timestamp" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -24,7 +26,7 @@ var _ = math.Inf // 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 GetAttachmentsRequest struct { // required, attachment ids @@ -816,6 +818,26 @@ type AttachmentManagerServer interface { DeleteAttachments(context.Context, *DeleteAttachmentsRequest) (*DeleteAttachmentsResponse, error) } +// UnimplementedAttachmentManagerServer can be embedded to have forward compatible implementations. +type UnimplementedAttachmentManagerServer struct { +} + +func (*UnimplementedAttachmentManagerServer) CreateAttachment(ctx context.Context, req *CreateAttachmentRequest) (*CreateAttachmentResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateAttachment not implemented") +} +func (*UnimplementedAttachmentManagerServer) AppendAttachment(ctx context.Context, req *AppendAttachmentRequest) (*AppendAttachmentResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method AppendAttachment not implemented") +} +func (*UnimplementedAttachmentManagerServer) ReplaceAttachment(ctx context.Context, req *ReplaceAttachmentRequest) (*ReplaceAttachmentResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ReplaceAttachment not implemented") +} +func (*UnimplementedAttachmentManagerServer) GetAttachments(ctx context.Context, req *GetAttachmentsRequest) (*GetAttachmentsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetAttachments not implemented") +} +func (*UnimplementedAttachmentManagerServer) DeleteAttachments(ctx context.Context, req *DeleteAttachmentsRequest) (*DeleteAttachmentsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteAttachments not implemented") +} + func RegisterAttachmentManagerServer(s *grpc.Server, srv AttachmentManagerServer) { s.RegisterService(&_AttachmentManager_serviceDesc, srv) } @@ -970,6 +992,14 @@ type AttachmentServiceServer interface { GetAttachment(context.Context, *GetAttachmentRequest) (*GetAttachmentResponse, error) } +// UnimplementedAttachmentServiceServer can be embedded to have forward compatible implementations. +type UnimplementedAttachmentServiceServer struct { +} + +func (*UnimplementedAttachmentServiceServer) GetAttachment(ctx context.Context, req *GetAttachmentRequest) (*GetAttachmentResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetAttachment not implemented") +} + func RegisterAttachmentServiceServer(s *grpc.Server, srv AttachmentServiceServer) { s.RegisterService(&_AttachmentService_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/attachment.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/attachment.pb.gw.go index 02c9dcd431095e740b0a4564426c338b99b545bb..cde4ef442de373946d96cce8b5b85234705fd461 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/attachment.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/attachment.pb.gw.go @@ -9,24 +9,27 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage var ( filter_AttachmentService_GetAttachment_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} @@ -36,7 +39,10 @@ func request_AttachmentService_GetAttachment_0(ctx context.Context, marshaler ru var protoReq GetAttachmentRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AttachmentService_GetAttachment_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_AttachmentService_GetAttachment_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -45,6 +51,47 @@ func request_AttachmentService_GetAttachment_0(ctx context.Context, marshaler ru } +func local_request_AttachmentService_GetAttachment_0(ctx context.Context, marshaler runtime.Marshaler, server AttachmentServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetAttachmentRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_AttachmentService_GetAttachment_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.GetAttachment(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterAttachmentServiceHandlerServer registers the http handlers for service AttachmentService to "mux". +// UnaryRPC :call AttachmentServiceServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterAttachmentServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server AttachmentServiceServer) error { + + mux.Handle("GET", pattern_AttachmentService_GetAttachment_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_AttachmentService_GetAttachment_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_AttachmentService_GetAttachment_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + // RegisterAttachmentServiceHandlerFromEndpoint is same as RegisterAttachmentServiceHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterAttachmentServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { @@ -86,15 +133,6 @@ func RegisterAttachmentServiceHandlerClient(ctx context.Context, mux *runtime.Se mux.Handle("GET", pattern_AttachmentService_GetAttachment_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -116,7 +154,7 @@ func RegisterAttachmentServiceHandlerClient(ctx context.Context, mux *runtime.Se } var ( - pattern_AttachmentService_GetAttachment_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "attachments"}, "")) + pattern_AttachmentService_GetAttachment_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "attachments"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/category.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/category.pb.go index 99bf5a6886163bd2c9f2f6948ffa97690ce0fd0c..27aa838a44df6174b088bb75f7761b306db8ffad 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/category.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/category.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -11,9 +12,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +27,7 @@ var _ = math.Inf // 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 Category struct { // category id @@ -763,6 +765,23 @@ type CategoryManagerServer interface { DeleteCategories(context.Context, *DeleteCategoriesRequest) (*DeleteCategoriesResponse, error) } +// UnimplementedCategoryManagerServer can be embedded to have forward compatible implementations. +type UnimplementedCategoryManagerServer struct { +} + +func (*UnimplementedCategoryManagerServer) DescribeCategories(ctx context.Context, req *DescribeCategoriesRequest) (*DescribeCategoriesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeCategories not implemented") +} +func (*UnimplementedCategoryManagerServer) CreateCategory(ctx context.Context, req *CreateCategoryRequest) (*CreateCategoryResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateCategory not implemented") +} +func (*UnimplementedCategoryManagerServer) ModifyCategory(ctx context.Context, req *ModifyCategoryRequest) (*ModifyCategoryResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyCategory not implemented") +} +func (*UnimplementedCategoryManagerServer) DeleteCategories(ctx context.Context, req *DeleteCategoriesRequest) (*DeleteCategoriesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteCategories not implemented") +} + func RegisterCategoryManagerServer(s *grpc.Server, srv CategoryManagerServer) { s.RegisterService(&_CategoryManager_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/category.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/category.pb.gw.go index 6af0f9a1203c3442befac55728622a44b97f616d..4b6856b686637b453820def16cdb39f7aa9654e1 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/category.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/category.pb.gw.go @@ -9,24 +9,27 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage var ( filter_CategoryManager_DescribeCategories_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} @@ -36,7 +39,10 @@ func request_CategoryManager_DescribeCategories_0(ctx context.Context, marshaler var protoReq DescribeCategoriesRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_CategoryManager_DescribeCategories_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_CategoryManager_DescribeCategories_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -45,11 +51,28 @@ func request_CategoryManager_DescribeCategories_0(ctx context.Context, marshaler } +func local_request_CategoryManager_DescribeCategories_0(ctx context.Context, marshaler runtime.Marshaler, server CategoryManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeCategoriesRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_CategoryManager_DescribeCategories_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeCategories(ctx, &protoReq) + return msg, metadata, err + +} + func request_CategoryManager_CreateCategory_0(ctx context.Context, marshaler runtime.Marshaler, client CategoryManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateCategoryRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -58,11 +81,32 @@ func request_CategoryManager_CreateCategory_0(ctx context.Context, marshaler run } +func local_request_CategoryManager_CreateCategory_0(ctx context.Context, marshaler runtime.Marshaler, server CategoryManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateCategoryRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateCategory(ctx, &protoReq) + return msg, metadata, err + +} + func request_CategoryManager_ModifyCategory_0(ctx context.Context, marshaler runtime.Marshaler, client CategoryManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyCategoryRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -71,11 +115,32 @@ func request_CategoryManager_ModifyCategory_0(ctx context.Context, marshaler run } +func local_request_CategoryManager_ModifyCategory_0(ctx context.Context, marshaler runtime.Marshaler, server CategoryManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyCategoryRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyCategory(ctx, &protoReq) + return msg, metadata, err + +} + func request_CategoryManager_DeleteCategories_0(ctx context.Context, marshaler runtime.Marshaler, client CategoryManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DeleteCategoriesRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -84,6 +149,111 @@ func request_CategoryManager_DeleteCategories_0(ctx context.Context, marshaler r } +func local_request_CategoryManager_DeleteCategories_0(ctx context.Context, marshaler runtime.Marshaler, server CategoryManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteCategoriesRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteCategories(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterCategoryManagerHandlerServer registers the http handlers for service CategoryManager to "mux". +// UnaryRPC :call CategoryManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterCategoryManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server CategoryManagerServer) error { + + mux.Handle("GET", pattern_CategoryManager_DescribeCategories_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_CategoryManager_DescribeCategories_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_CategoryManager_DescribeCategories_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_CategoryManager_CreateCategory_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_CategoryManager_CreateCategory_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_CategoryManager_CreateCategory_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_CategoryManager_ModifyCategory_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_CategoryManager_ModifyCategory_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_CategoryManager_ModifyCategory_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_CategoryManager_DeleteCategories_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_CategoryManager_DeleteCategories_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_CategoryManager_DeleteCategories_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + // RegisterCategoryManagerHandlerFromEndpoint is same as RegisterCategoryManagerHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterCategoryManagerHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { @@ -125,15 +295,6 @@ func RegisterCategoryManagerHandlerClient(ctx context.Context, mux *runtime.Serv mux.Handle("GET", pattern_CategoryManager_DescribeCategories_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -154,15 +315,6 @@ func RegisterCategoryManagerHandlerClient(ctx context.Context, mux *runtime.Serv mux.Handle("POST", pattern_CategoryManager_CreateCategory_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -183,15 +335,6 @@ func RegisterCategoryManagerHandlerClient(ctx context.Context, mux *runtime.Serv mux.Handle("PATCH", pattern_CategoryManager_ModifyCategory_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -212,15 +355,6 @@ func RegisterCategoryManagerHandlerClient(ctx context.Context, mux *runtime.Serv mux.Handle("DELETE", pattern_CategoryManager_DeleteCategories_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -242,13 +376,13 @@ func RegisterCategoryManagerHandlerClient(ctx context.Context, mux *runtime.Serv } var ( - pattern_CategoryManager_DescribeCategories_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "categories"}, "")) + pattern_CategoryManager_DescribeCategories_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "categories"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_CategoryManager_CreateCategory_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "categories"}, "")) + pattern_CategoryManager_CreateCategory_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "categories"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_CategoryManager_ModifyCategory_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "categories"}, "")) + pattern_CategoryManager_ModifyCategory_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "categories"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_CategoryManager_DeleteCategories_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "categories"}, "")) + pattern_CategoryManager_DeleteCategories_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "categories"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/cluster.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/cluster.pb.go index 82e7a64daf5e1fad920b17c8ad0ee5a20a0937bb..e3a18b6c48899d1aa65c61a4386cee568746400b 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/cluster.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/cluster.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -12,9 +13,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -26,7 +28,7 @@ var _ = math.Inf // 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 DescribeSubnetsRequest struct { // required, id of runtime that contain subnet @@ -274,6 +276,178 @@ func (m *DescribeSubnetsResponse) GetSubnetSet() []*Subnet { return nil } +type DeleteClusterInRuntimeRequest struct { + RuntimeId []string `protobuf:"bytes,1,rep,name=runtime_id,json=runtimeId,proto3" json:"runtime_id,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *DeleteClusterInRuntimeRequest) Reset() { *m = DeleteClusterInRuntimeRequest{} } +func (m *DeleteClusterInRuntimeRequest) String() string { return proto.CompactTextString(m) } +func (*DeleteClusterInRuntimeRequest) ProtoMessage() {} +func (*DeleteClusterInRuntimeRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_3cfb3b8ec240c376, []int{3} +} + +func (m *DeleteClusterInRuntimeRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_DeleteClusterInRuntimeRequest.Unmarshal(m, b) +} +func (m *DeleteClusterInRuntimeRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_DeleteClusterInRuntimeRequest.Marshal(b, m, deterministic) +} +func (m *DeleteClusterInRuntimeRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_DeleteClusterInRuntimeRequest.Merge(m, src) +} +func (m *DeleteClusterInRuntimeRequest) XXX_Size() int { + return xxx_messageInfo_DeleteClusterInRuntimeRequest.Size(m) +} +func (m *DeleteClusterInRuntimeRequest) XXX_DiscardUnknown() { + xxx_messageInfo_DeleteClusterInRuntimeRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_DeleteClusterInRuntimeRequest proto.InternalMessageInfo + +func (m *DeleteClusterInRuntimeRequest) GetRuntimeId() []string { + if m != nil { + return m.RuntimeId + } + return nil +} + +type DeleteClusterInRuntimeResponse struct { + RuntimeId []string `protobuf:"bytes,1,rep,name=runtime_id,json=runtimeId,proto3" json:"runtime_id,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *DeleteClusterInRuntimeResponse) Reset() { *m = DeleteClusterInRuntimeResponse{} } +func (m *DeleteClusterInRuntimeResponse) String() string { return proto.CompactTextString(m) } +func (*DeleteClusterInRuntimeResponse) ProtoMessage() {} +func (*DeleteClusterInRuntimeResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_3cfb3b8ec240c376, []int{4} +} + +func (m *DeleteClusterInRuntimeResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_DeleteClusterInRuntimeResponse.Unmarshal(m, b) +} +func (m *DeleteClusterInRuntimeResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_DeleteClusterInRuntimeResponse.Marshal(b, m, deterministic) +} +func (m *DeleteClusterInRuntimeResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_DeleteClusterInRuntimeResponse.Merge(m, src) +} +func (m *DeleteClusterInRuntimeResponse) XXX_Size() int { + return xxx_messageInfo_DeleteClusterInRuntimeResponse.Size(m) +} +func (m *DeleteClusterInRuntimeResponse) XXX_DiscardUnknown() { + xxx_messageInfo_DeleteClusterInRuntimeResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_DeleteClusterInRuntimeResponse proto.InternalMessageInfo + +func (m *DeleteClusterInRuntimeResponse) GetRuntimeId() []string { + if m != nil { + return m.RuntimeId + } + return nil +} + +type MigrateClusterInRuntimeRequest struct { + FromRuntimeId string `protobuf:"bytes,1,opt,name=from_runtime_id,json=fromRuntimeId,proto3" json:"from_runtime_id,omitempty"` + ToRuntimeId string `protobuf:"bytes,2,opt,name=to_runtime_id,json=toRuntimeId,proto3" json:"to_runtime_id,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *MigrateClusterInRuntimeRequest) Reset() { *m = MigrateClusterInRuntimeRequest{} } +func (m *MigrateClusterInRuntimeRequest) String() string { return proto.CompactTextString(m) } +func (*MigrateClusterInRuntimeRequest) ProtoMessage() {} +func (*MigrateClusterInRuntimeRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_3cfb3b8ec240c376, []int{5} +} + +func (m *MigrateClusterInRuntimeRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_MigrateClusterInRuntimeRequest.Unmarshal(m, b) +} +func (m *MigrateClusterInRuntimeRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_MigrateClusterInRuntimeRequest.Marshal(b, m, deterministic) +} +func (m *MigrateClusterInRuntimeRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_MigrateClusterInRuntimeRequest.Merge(m, src) +} +func (m *MigrateClusterInRuntimeRequest) XXX_Size() int { + return xxx_messageInfo_MigrateClusterInRuntimeRequest.Size(m) +} +func (m *MigrateClusterInRuntimeRequest) XXX_DiscardUnknown() { + xxx_messageInfo_MigrateClusterInRuntimeRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_MigrateClusterInRuntimeRequest proto.InternalMessageInfo + +func (m *MigrateClusterInRuntimeRequest) GetFromRuntimeId() string { + if m != nil { + return m.FromRuntimeId + } + return "" +} + +func (m *MigrateClusterInRuntimeRequest) GetToRuntimeId() string { + if m != nil { + return m.ToRuntimeId + } + return "" +} + +type MigrateClusterInRuntimeResponse struct { + FromRuntimeId string `protobuf:"bytes,1,opt,name=from_runtime_id,json=fromRuntimeId,proto3" json:"from_runtime_id,omitempty"` + ToRuntimeId string `protobuf:"bytes,2,opt,name=to_runtime_id,json=toRuntimeId,proto3" json:"to_runtime_id,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *MigrateClusterInRuntimeResponse) Reset() { *m = MigrateClusterInRuntimeResponse{} } +func (m *MigrateClusterInRuntimeResponse) String() string { return proto.CompactTextString(m) } +func (*MigrateClusterInRuntimeResponse) ProtoMessage() {} +func (*MigrateClusterInRuntimeResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_3cfb3b8ec240c376, []int{6} +} + +func (m *MigrateClusterInRuntimeResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_MigrateClusterInRuntimeResponse.Unmarshal(m, b) +} +func (m *MigrateClusterInRuntimeResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_MigrateClusterInRuntimeResponse.Marshal(b, m, deterministic) +} +func (m *MigrateClusterInRuntimeResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_MigrateClusterInRuntimeResponse.Merge(m, src) +} +func (m *MigrateClusterInRuntimeResponse) XXX_Size() int { + return xxx_messageInfo_MigrateClusterInRuntimeResponse.Size(m) +} +func (m *MigrateClusterInRuntimeResponse) XXX_DiscardUnknown() { + xxx_messageInfo_MigrateClusterInRuntimeResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_MigrateClusterInRuntimeResponse proto.InternalMessageInfo + +func (m *MigrateClusterInRuntimeResponse) GetFromRuntimeId() string { + if m != nil { + return m.FromRuntimeId + } + return "" +} + +func (m *MigrateClusterInRuntimeResponse) GetToRuntimeId() string { + if m != nil { + return m.ToRuntimeId + } + return "" +} + type CreateClusterRequest struct { // required, id of app to run in cluster AppId *wrappers.StringValue `protobuf:"bytes,1,opt,name=app_id,json=appId,proto3" json:"app_id,omitempty"` @@ -284,17 +458,19 @@ type CreateClusterRequest struct { // required, conf a json string, include cpu, memory info of cluster Conf *wrappers.StringValue `protobuf:"bytes,4,opt,name=conf,proto3" json:"conf,omitempty"` // advanced param - AdvancedParam []string `protobuf:"bytes,5,rep,name=advanced_param,json=advancedParam,proto3" json:"advanced_param,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + AdvancedParam []string `protobuf:"bytes,5,rep,name=advanced_param,json=advancedParam,proto3" json:"advanced_param,omitempty"` + // kubernetes namespace + Zone *wrappers.StringValue `protobuf:"bytes,6,opt,name=zone,proto3" json:"zone,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *CreateClusterRequest) Reset() { *m = CreateClusterRequest{} } func (m *CreateClusterRequest) String() string { return proto.CompactTextString(m) } func (*CreateClusterRequest) ProtoMessage() {} func (*CreateClusterRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{3} + return fileDescriptor_3cfb3b8ec240c376, []int{7} } func (m *CreateClusterRequest) XXX_Unmarshal(b []byte) error { @@ -350,6 +526,13 @@ func (m *CreateClusterRequest) GetAdvancedParam() []string { return nil } +func (m *CreateClusterRequest) GetZone() *wrappers.StringValue { + if m != nil { + return m.Zone + } + return nil +} + type CreateClusterResponse struct { // id of cluster created ClusterId *wrappers.StringValue `protobuf:"bytes,1,opt,name=cluster_id,json=clusterId,proto3" json:"cluster_id,omitempty"` @@ -364,7 +547,7 @@ func (m *CreateClusterResponse) Reset() { *m = CreateClusterResponse{} } func (m *CreateClusterResponse) String() string { return proto.CompactTextString(m) } func (*CreateClusterResponse) ProtoMessage() {} func (*CreateClusterResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{4} + return fileDescriptor_3cfb3b8ec240c376, []int{8} } func (m *CreateClusterResponse) XXX_Unmarshal(b []byte) error { @@ -421,7 +604,7 @@ func (m *ModifyClusterRequest) Reset() { *m = ModifyClusterRequest{} } func (m *ModifyClusterRequest) String() string { return proto.CompactTextString(m) } func (*ModifyClusterRequest) ProtoMessage() {} func (*ModifyClusterRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{5} + return fileDescriptor_3cfb3b8ec240c376, []int{9} } func (m *ModifyClusterRequest) XXX_Unmarshal(b []byte) error { @@ -496,7 +679,7 @@ func (m *ModifyClusterResponse) Reset() { *m = ModifyClusterResponse{} } func (m *ModifyClusterResponse) String() string { return proto.CompactTextString(m) } func (*ModifyClusterResponse) ProtoMessage() {} func (*ModifyClusterResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{6} + return fileDescriptor_3cfb3b8ec240c376, []int{10} } func (m *ModifyClusterResponse) XXX_Unmarshal(b []byte) error { @@ -536,7 +719,7 @@ func (m *ModifyClusterNodeRequest) Reset() { *m = ModifyClusterNodeReque func (m *ModifyClusterNodeRequest) String() string { return proto.CompactTextString(m) } func (*ModifyClusterNodeRequest) ProtoMessage() {} func (*ModifyClusterNodeRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{7} + return fileDescriptor_3cfb3b8ec240c376, []int{11} } func (m *ModifyClusterNodeRequest) XXX_Unmarshal(b []byte) error { @@ -576,7 +759,7 @@ func (m *ModifyClusterNodeResponse) Reset() { *m = ModifyClusterNodeResp func (m *ModifyClusterNodeResponse) String() string { return proto.CompactTextString(m) } func (*ModifyClusterNodeResponse) ProtoMessage() {} func (*ModifyClusterNodeResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{8} + return fileDescriptor_3cfb3b8ec240c376, []int{12} } func (m *ModifyClusterNodeResponse) XXX_Unmarshal(b []byte) error { @@ -620,7 +803,7 @@ func (m *ModifyClusterAttributesRequest) Reset() { *m = ModifyClusterAtt func (m *ModifyClusterAttributesRequest) String() string { return proto.CompactTextString(m) } func (*ModifyClusterAttributesRequest) ProtoMessage() {} func (*ModifyClusterAttributesRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{9} + return fileDescriptor_3cfb3b8ec240c376, []int{13} } func (m *ModifyClusterAttributesRequest) XXX_Unmarshal(b []byte) error { @@ -674,7 +857,7 @@ func (m *ModifyClusterAttributesResponse) Reset() { *m = ModifyClusterAt func (m *ModifyClusterAttributesResponse) String() string { return proto.CompactTextString(m) } func (*ModifyClusterAttributesResponse) ProtoMessage() {} func (*ModifyClusterAttributesResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{10} + return fileDescriptor_3cfb3b8ec240c376, []int{14} } func (m *ModifyClusterAttributesResponse) XXX_Unmarshal(b []byte) error { @@ -716,7 +899,7 @@ func (m *ModifyClusterNodeAttributesRequest) Reset() { *m = ModifyCluste func (m *ModifyClusterNodeAttributesRequest) String() string { return proto.CompactTextString(m) } func (*ModifyClusterNodeAttributesRequest) ProtoMessage() {} func (*ModifyClusterNodeAttributesRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{11} + return fileDescriptor_3cfb3b8ec240c376, []int{15} } func (m *ModifyClusterNodeAttributesRequest) XXX_Unmarshal(b []byte) error { @@ -763,7 +946,7 @@ func (m *ModifyClusterNodeAttributesResponse) Reset() { *m = ModifyClust func (m *ModifyClusterNodeAttributesResponse) String() string { return proto.CompactTextString(m) } func (*ModifyClusterNodeAttributesResponse) ProtoMessage() {} func (*ModifyClusterNodeAttributesResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{12} + return fileDescriptor_3cfb3b8ec240c376, []int{16} } func (m *ModifyClusterNodeAttributesResponse) XXX_Unmarshal(b []byte) error { @@ -803,7 +986,7 @@ func (m *AddTableClusterNodesRequest) Reset() { *m = AddTableClusterNode func (m *AddTableClusterNodesRequest) String() string { return proto.CompactTextString(m) } func (*AddTableClusterNodesRequest) ProtoMessage() {} func (*AddTableClusterNodesRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{13} + return fileDescriptor_3cfb3b8ec240c376, []int{17} } func (m *AddTableClusterNodesRequest) XXX_Unmarshal(b []byte) error { @@ -843,7 +1026,7 @@ func (m *DeleteTableClusterNodesRequest) Reset() { *m = DeleteTableClust func (m *DeleteTableClusterNodesRequest) String() string { return proto.CompactTextString(m) } func (*DeleteTableClusterNodesRequest) ProtoMessage() {} func (*DeleteTableClusterNodesRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{14} + return fileDescriptor_3cfb3b8ec240c376, []int{18} } func (m *DeleteTableClusterNodesRequest) XXX_Unmarshal(b []byte) error { @@ -889,7 +1072,7 @@ func (m *DeleteClustersRequest) Reset() { *m = DeleteClustersRequest{} } func (m *DeleteClustersRequest) String() string { return proto.CompactTextString(m) } func (*DeleteClustersRequest) ProtoMessage() {} func (*DeleteClustersRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{15} + return fileDescriptor_3cfb3b8ec240c376, []int{19} } func (m *DeleteClustersRequest) XXX_Unmarshal(b []byte) error { @@ -952,7 +1135,7 @@ func (m *DeleteClustersResponse) Reset() { *m = DeleteClustersResponse{} func (m *DeleteClustersResponse) String() string { return proto.CompactTextString(m) } func (*DeleteClustersResponse) ProtoMessage() {} func (*DeleteClustersResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{16} + return fileDescriptor_3cfb3b8ec240c376, []int{20} } func (m *DeleteClustersResponse) XXX_Unmarshal(b []byte) error { @@ -1003,7 +1186,7 @@ func (m *UpgradeClusterRequest) Reset() { *m = UpgradeClusterRequest{} } func (m *UpgradeClusterRequest) String() string { return proto.CompactTextString(m) } func (*UpgradeClusterRequest) ProtoMessage() {} func (*UpgradeClusterRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{17} + return fileDescriptor_3cfb3b8ec240c376, []int{21} } func (m *UpgradeClusterRequest) XXX_Unmarshal(b []byte) error { @@ -1059,7 +1242,7 @@ func (m *UpgradeClusterResponse) Reset() { *m = UpgradeClusterResponse{} func (m *UpgradeClusterResponse) String() string { return proto.CompactTextString(m) } func (*UpgradeClusterResponse) ProtoMessage() {} func (*UpgradeClusterResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{18} + return fileDescriptor_3cfb3b8ec240c376, []int{22} } func (m *UpgradeClusterResponse) XXX_Unmarshal(b []byte) error { @@ -1108,7 +1291,7 @@ func (m *RollbackClusterRequest) Reset() { *m = RollbackClusterRequest{} func (m *RollbackClusterRequest) String() string { return proto.CompactTextString(m) } func (*RollbackClusterRequest) ProtoMessage() {} func (*RollbackClusterRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{19} + return fileDescriptor_3cfb3b8ec240c376, []int{23} } func (m *RollbackClusterRequest) XXX_Unmarshal(b []byte) error { @@ -1157,7 +1340,7 @@ func (m *RollbackClusterResponse) Reset() { *m = RollbackClusterResponse func (m *RollbackClusterResponse) String() string { return proto.CompactTextString(m) } func (*RollbackClusterResponse) ProtoMessage() {} func (*RollbackClusterResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{20} + return fileDescriptor_3cfb3b8ec240c376, []int{24} } func (m *RollbackClusterResponse) XXX_Unmarshal(b []byte) error { @@ -1214,7 +1397,7 @@ func (m *RoleResource) Reset() { *m = RoleResource{} } func (m *RoleResource) String() string { return proto.CompactTextString(m) } func (*RoleResource) ProtoMessage() {} func (*RoleResource) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{21} + return fileDescriptor_3cfb3b8ec240c376, []int{25} } func (m *RoleResource) XXX_Unmarshal(b []byte) error { @@ -1293,7 +1476,7 @@ func (m *ResizeClusterRequest) Reset() { *m = ResizeClusterRequest{} } func (m *ResizeClusterRequest) String() string { return proto.CompactTextString(m) } func (*ResizeClusterRequest) ProtoMessage() {} func (*ResizeClusterRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{22} + return fileDescriptor_3cfb3b8ec240c376, []int{26} } func (m *ResizeClusterRequest) XXX_Unmarshal(b []byte) error { @@ -1349,7 +1532,7 @@ func (m *ResizeClusterResponse) Reset() { *m = ResizeClusterResponse{} } func (m *ResizeClusterResponse) String() string { return proto.CompactTextString(m) } func (*ResizeClusterResponse) ProtoMessage() {} func (*ResizeClusterResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{23} + return fileDescriptor_3cfb3b8ec240c376, []int{27} } func (m *ResizeClusterResponse) XXX_Unmarshal(b []byte) error { @@ -1402,7 +1585,7 @@ func (m *AddClusterNodesRequest) Reset() { *m = AddClusterNodesRequest{} func (m *AddClusterNodesRequest) String() string { return proto.CompactTextString(m) } func (*AddClusterNodesRequest) ProtoMessage() {} func (*AddClusterNodesRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{24} + return fileDescriptor_3cfb3b8ec240c376, []int{28} } func (m *AddClusterNodesRequest) XXX_Unmarshal(b []byte) error { @@ -1465,7 +1648,7 @@ func (m *AddClusterNodesResponse) Reset() { *m = AddClusterNodesResponse func (m *AddClusterNodesResponse) String() string { return proto.CompactTextString(m) } func (*AddClusterNodesResponse) ProtoMessage() {} func (*AddClusterNodesResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{25} + return fileDescriptor_3cfb3b8ec240c376, []int{29} } func (m *AddClusterNodesResponse) XXX_Unmarshal(b []byte) error { @@ -1516,7 +1699,7 @@ func (m *DeleteClusterNodesRequest) Reset() { *m = DeleteClusterNodesReq func (m *DeleteClusterNodesRequest) String() string { return proto.CompactTextString(m) } func (*DeleteClusterNodesRequest) ProtoMessage() {} func (*DeleteClusterNodesRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{26} + return fileDescriptor_3cfb3b8ec240c376, []int{30} } func (m *DeleteClusterNodesRequest) XXX_Unmarshal(b []byte) error { @@ -1572,7 +1755,7 @@ func (m *DeleteClusterNodesResponse) Reset() { *m = DeleteClusterNodesRe func (m *DeleteClusterNodesResponse) String() string { return proto.CompactTextString(m) } func (*DeleteClusterNodesResponse) ProtoMessage() {} func (*DeleteClusterNodesResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{27} + return fileDescriptor_3cfb3b8ec240c376, []int{31} } func (m *DeleteClusterNodesResponse) XXX_Unmarshal(b []byte) error { @@ -1623,7 +1806,7 @@ func (m *UpdateClusterEnvRequest) Reset() { *m = UpdateClusterEnvRequest func (m *UpdateClusterEnvRequest) String() string { return proto.CompactTextString(m) } func (*UpdateClusterEnvRequest) ProtoMessage() {} func (*UpdateClusterEnvRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{28} + return fileDescriptor_3cfb3b8ec240c376, []int{32} } func (m *UpdateClusterEnvRequest) XXX_Unmarshal(b []byte) error { @@ -1679,7 +1862,7 @@ func (m *UpdateClusterEnvResponse) Reset() { *m = UpdateClusterEnvRespon func (m *UpdateClusterEnvResponse) String() string { return proto.CompactTextString(m) } func (*UpdateClusterEnvResponse) ProtoMessage() {} func (*UpdateClusterEnvResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{29} + return fileDescriptor_3cfb3b8ec240c376, []int{33} } func (m *UpdateClusterEnvResponse) XXX_Unmarshal(b []byte) error { @@ -1775,7 +1958,7 @@ func (m *ClusterCommon) Reset() { *m = ClusterCommon{} } func (m *ClusterCommon) String() string { return proto.CompactTextString(m) } func (*ClusterCommon) ProtoMessage() {} func (*ClusterCommon) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{30} + return fileDescriptor_3cfb3b8ec240c376, []int{34} } func (m *ClusterCommon) XXX_Unmarshal(b []byte) error { @@ -2046,7 +2229,7 @@ func (m *ClusterNode) Reset() { *m = ClusterNode{} } func (m *ClusterNode) String() string { return proto.CompactTextString(m) } func (*ClusterNode) ProtoMessage() {} func (*ClusterNode) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{31} + return fileDescriptor_3cfb3b8ec240c376, []int{35} } func (m *ClusterNode) XXX_Unmarshal(b []byte) error { @@ -2308,7 +2491,7 @@ func (m *ClusterRole) Reset() { *m = ClusterRole{} } func (m *ClusterRole) String() string { return proto.CompactTextString(m) } func (*ClusterRole) ProtoMessage() {} func (*ClusterRole) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{32} + return fileDescriptor_3cfb3b8ec240c376, []int{36} } func (m *ClusterRole) XXX_Unmarshal(b []byte) error { @@ -2447,7 +2630,7 @@ func (m *ClusterLoadbalancer) Reset() { *m = ClusterLoadbalancer{} } func (m *ClusterLoadbalancer) String() string { return proto.CompactTextString(m) } func (*ClusterLoadbalancer) ProtoMessage() {} func (*ClusterLoadbalancer) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{33} + return fileDescriptor_3cfb3b8ec240c376, []int{37} } func (m *ClusterLoadbalancer) XXX_Unmarshal(b []byte) error { @@ -2523,7 +2706,7 @@ func (m *ClusterLink) Reset() { *m = ClusterLink{} } func (m *ClusterLink) String() string { return proto.CompactTextString(m) } func (*ClusterLink) ProtoMessage() {} func (*ClusterLink) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{34} + return fileDescriptor_3cfb3b8ec240c376, []int{38} } func (m *ClusterLink) XXX_Unmarshal(b []byte) error { @@ -2648,7 +2831,7 @@ func (m *Cluster) Reset() { *m = Cluster{} } func (m *Cluster) String() string { return proto.CompactTextString(m) } func (*Cluster) ProtoMessage() {} func (*Cluster) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{35} + return fileDescriptor_3cfb3b8ec240c376, []int{39} } func (m *Cluster) XXX_Unmarshal(b []byte) error { @@ -2913,7 +3096,9 @@ type DescribeClustersRequest struct { // cluster created duration eg.[1 day] CreatedDate *wrappers.UInt32Value `protobuf:"bytes,16,opt,name=created_date,json=createdDate,proto3" json:"created_date,omitempty"` // select column to display - DisplayColumns []string `protobuf:"bytes,17,rep,name=display_columns,json=displayColumns,proto3" json:"display_columns,omitempty"` + DisplayColumns []string `protobuf:"bytes,17,rep,name=display_columns,json=displayColumns,proto3" json:"display_columns,omitempty"` + // namespace + Zone []string `protobuf:"bytes,18,rep,name=zone,proto3" json:"zone,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` @@ -2923,7 +3108,7 @@ func (m *DescribeClustersRequest) Reset() { *m = DescribeClustersRequest func (m *DescribeClustersRequest) String() string { return proto.CompactTextString(m) } func (*DescribeClustersRequest) ProtoMessage() {} func (*DescribeClustersRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{36} + return fileDescriptor_3cfb3b8ec240c376, []int{40} } func (m *DescribeClustersRequest) XXX_Unmarshal(b []byte) error { @@ -3063,6 +3248,13 @@ func (m *DescribeClustersRequest) GetDisplayColumns() []string { return nil } +func (m *DescribeClustersRequest) GetZone() []string { + if m != nil { + return m.Zone + } + return nil +} + type DescribeClustersResponse struct { // total count of qualified cluster TotalCount uint32 `protobuf:"varint,1,opt,name=total_count,json=totalCount,proto3" json:"total_count,omitempty"` @@ -3077,7 +3269,7 @@ func (m *DescribeClustersResponse) Reset() { *m = DescribeClustersRespon func (m *DescribeClustersResponse) String() string { return proto.CompactTextString(m) } func (*DescribeClustersResponse) ProtoMessage() {} func (*DescribeClustersResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{37} + return fileDescriptor_3cfb3b8ec240c376, []int{41} } func (m *DescribeClustersResponse) XXX_Unmarshal(b []byte) error { @@ -3144,7 +3336,7 @@ func (m *DescribeAppClustersRequest) Reset() { *m = DescribeAppClustersR func (m *DescribeAppClustersRequest) String() string { return proto.CompactTextString(m) } func (*DescribeAppClustersRequest) ProtoMessage() {} func (*DescribeAppClustersRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{38} + return fileDescriptor_3cfb3b8ec240c376, []int{42} } func (m *DescribeAppClustersRequest) XXX_Unmarshal(b []byte) error { @@ -3256,7 +3448,7 @@ func (m *DescribeAppClustersResponse) Reset() { *m = DescribeAppClusters func (m *DescribeAppClustersResponse) String() string { return proto.CompactTextString(m) } func (*DescribeAppClustersResponse) ProtoMessage() {} func (*DescribeAppClustersResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{39} + return fileDescriptor_3cfb3b8ec240c376, []int{43} } func (m *DescribeAppClustersResponse) XXX_Unmarshal(b []byte) error { @@ -3321,7 +3513,7 @@ func (m *DescribeClusterNodesRequest) Reset() { *m = DescribeClusterNode func (m *DescribeClusterNodesRequest) String() string { return proto.CompactTextString(m) } func (*DescribeClusterNodesRequest) ProtoMessage() {} func (*DescribeClusterNodesRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{40} + return fileDescriptor_3cfb3b8ec240c376, []int{44} } func (m *DescribeClusterNodesRequest) XXX_Unmarshal(b []byte) error { @@ -3426,7 +3618,7 @@ func (m *DescribeClusterNodesResponse) Reset() { *m = DescribeClusterNod func (m *DescribeClusterNodesResponse) String() string { return proto.CompactTextString(m) } func (*DescribeClusterNodesResponse) ProtoMessage() {} func (*DescribeClusterNodesResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{41} + return fileDescriptor_3cfb3b8ec240c376, []int{45} } func (m *DescribeClusterNodesResponse) XXX_Unmarshal(b []byte) error { @@ -3475,7 +3667,7 @@ func (m *StopClustersRequest) Reset() { *m = StopClustersRequest{} } func (m *StopClustersRequest) String() string { return proto.CompactTextString(m) } func (*StopClustersRequest) ProtoMessage() {} func (*StopClustersRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{42} + return fileDescriptor_3cfb3b8ec240c376, []int{46} } func (m *StopClustersRequest) XXX_Unmarshal(b []byte) error { @@ -3524,7 +3716,7 @@ func (m *StopClustersResponse) Reset() { *m = StopClustersResponse{} } func (m *StopClustersResponse) String() string { return proto.CompactTextString(m) } func (*StopClustersResponse) ProtoMessage() {} func (*StopClustersResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{43} + return fileDescriptor_3cfb3b8ec240c376, []int{47} } func (m *StopClustersResponse) XXX_Unmarshal(b []byte) error { @@ -3573,7 +3765,7 @@ func (m *StartClustersRequest) Reset() { *m = StartClustersRequest{} } func (m *StartClustersRequest) String() string { return proto.CompactTextString(m) } func (*StartClustersRequest) ProtoMessage() {} func (*StartClustersRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{44} + return fileDescriptor_3cfb3b8ec240c376, []int{48} } func (m *StartClustersRequest) XXX_Unmarshal(b []byte) error { @@ -3622,7 +3814,7 @@ func (m *StartClustersResponse) Reset() { *m = StartClustersResponse{} } func (m *StartClustersResponse) String() string { return proto.CompactTextString(m) } func (*StartClustersResponse) ProtoMessage() {} func (*StartClustersResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{45} + return fileDescriptor_3cfb3b8ec240c376, []int{49} } func (m *StartClustersResponse) XXX_Unmarshal(b []byte) error { @@ -3671,7 +3863,7 @@ func (m *RecoverClustersRequest) Reset() { *m = RecoverClustersRequest{} func (m *RecoverClustersRequest) String() string { return proto.CompactTextString(m) } func (*RecoverClustersRequest) ProtoMessage() {} func (*RecoverClustersRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{46} + return fileDescriptor_3cfb3b8ec240c376, []int{50} } func (m *RecoverClustersRequest) XXX_Unmarshal(b []byte) error { @@ -3720,7 +3912,7 @@ func (m *RecoverClustersResponse) Reset() { *m = RecoverClustersResponse func (m *RecoverClustersResponse) String() string { return proto.CompactTextString(m) } func (*RecoverClustersResponse) ProtoMessage() {} func (*RecoverClustersResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{47} + return fileDescriptor_3cfb3b8ec240c376, []int{51} } func (m *RecoverClustersResponse) XXX_Unmarshal(b []byte) error { @@ -3773,7 +3965,7 @@ func (m *CeaseClustersRequest) Reset() { *m = CeaseClustersRequest{} } func (m *CeaseClustersRequest) String() string { return proto.CompactTextString(m) } func (*CeaseClustersRequest) ProtoMessage() {} func (*CeaseClustersRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{48} + return fileDescriptor_3cfb3b8ec240c376, []int{52} } func (m *CeaseClustersRequest) XXX_Unmarshal(b []byte) error { @@ -3836,7 +4028,7 @@ func (m *CeaseClustersResponse) Reset() { *m = CeaseClustersResponse{} } func (m *CeaseClustersResponse) String() string { return proto.CompactTextString(m) } func (*CeaseClustersResponse) ProtoMessage() {} func (*CeaseClustersResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{49} + return fileDescriptor_3cfb3b8ec240c376, []int{53} } func (m *CeaseClustersResponse) XXX_Unmarshal(b []byte) error { @@ -3881,7 +4073,7 @@ func (m *GetClusterStatisticsRequest) Reset() { *m = GetClusterStatistic func (m *GetClusterStatisticsRequest) String() string { return proto.CompactTextString(m) } func (*GetClusterStatisticsRequest) ProtoMessage() {} func (*GetClusterStatisticsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{50} + return fileDescriptor_3cfb3b8ec240c376, []int{54} } func (m *GetClusterStatisticsRequest) XXX_Unmarshal(b []byte) error { @@ -3922,7 +4114,7 @@ func (m *GetClusterStatisticsResponse) Reset() { *m = GetClusterStatisti func (m *GetClusterStatisticsResponse) String() string { return proto.CompactTextString(m) } func (*GetClusterStatisticsResponse) ProtoMessage() {} func (*GetClusterStatisticsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{51} + return fileDescriptor_3cfb3b8ec240c376, []int{55} } func (m *GetClusterStatisticsResponse) XXX_Unmarshal(b []byte) error { @@ -4006,7 +4198,7 @@ func (m *KeyPair) Reset() { *m = KeyPair{} } func (m *KeyPair) String() string { return proto.CompactTextString(m) } func (*KeyPair) ProtoMessage() {} func (*KeyPair) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{52} + return fileDescriptor_3cfb3b8ec240c376, []int{56} } func (m *KeyPair) XXX_Unmarshal(b []byte) error { @@ -4106,7 +4298,7 @@ func (m *CreateKeyPairRequest) Reset() { *m = CreateKeyPairRequest{} } func (m *CreateKeyPairRequest) String() string { return proto.CompactTextString(m) } func (*CreateKeyPairRequest) ProtoMessage() {} func (*CreateKeyPairRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{53} + return fileDescriptor_3cfb3b8ec240c376, []int{57} } func (m *CreateKeyPairRequest) XXX_Unmarshal(b []byte) error { @@ -4160,7 +4352,7 @@ func (m *CreateKeyPairResponse) Reset() { *m = CreateKeyPairResponse{} } func (m *CreateKeyPairResponse) String() string { return proto.CompactTextString(m) } func (*CreateKeyPairResponse) ProtoMessage() {} func (*CreateKeyPairResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{54} + return fileDescriptor_3cfb3b8ec240c376, []int{58} } func (m *CreateKeyPairResponse) XXX_Unmarshal(b []byte) error { @@ -4216,7 +4408,7 @@ func (m *DescribeKeyPairsRequest) Reset() { *m = DescribeKeyPairsRequest func (m *DescribeKeyPairsRequest) String() string { return proto.CompactTextString(m) } func (*DescribeKeyPairsRequest) ProtoMessage() {} func (*DescribeKeyPairsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{55} + return fileDescriptor_3cfb3b8ec240c376, []int{59} } func (m *DescribeKeyPairsRequest) XXX_Unmarshal(b []byte) error { @@ -4314,7 +4506,7 @@ func (m *DescribeKeyPairsResponse) Reset() { *m = DescribeKeyPairsRespon func (m *DescribeKeyPairsResponse) String() string { return proto.CompactTextString(m) } func (*DescribeKeyPairsResponse) ProtoMessage() {} func (*DescribeKeyPairsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{56} + return fileDescriptor_3cfb3b8ec240c376, []int{60} } func (m *DescribeKeyPairsResponse) XXX_Unmarshal(b []byte) error { @@ -4361,7 +4553,7 @@ func (m *DeleteKeyPairsRequest) Reset() { *m = DeleteKeyPairsRequest{} } func (m *DeleteKeyPairsRequest) String() string { return proto.CompactTextString(m) } func (*DeleteKeyPairsRequest) ProtoMessage() {} func (*DeleteKeyPairsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{57} + return fileDescriptor_3cfb3b8ec240c376, []int{61} } func (m *DeleteKeyPairsRequest) XXX_Unmarshal(b []byte) error { @@ -4401,7 +4593,7 @@ func (m *DeleteKeyPairsResponse) Reset() { *m = DeleteKeyPairsResponse{} func (m *DeleteKeyPairsResponse) String() string { return proto.CompactTextString(m) } func (*DeleteKeyPairsResponse) ProtoMessage() {} func (*DeleteKeyPairsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{58} + return fileDescriptor_3cfb3b8ec240c376, []int{62} } func (m *DeleteKeyPairsResponse) XXX_Unmarshal(b []byte) error { @@ -4443,7 +4635,7 @@ func (m *AttachKeyPairsRequest) Reset() { *m = AttachKeyPairsRequest{} } func (m *AttachKeyPairsRequest) String() string { return proto.CompactTextString(m) } func (*AttachKeyPairsRequest) ProtoMessage() {} func (*AttachKeyPairsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{59} + return fileDescriptor_3cfb3b8ec240c376, []int{63} } func (m *AttachKeyPairsRequest) XXX_Unmarshal(b []byte) error { @@ -4490,7 +4682,7 @@ func (m *AttachKeyPairsResponse) Reset() { *m = AttachKeyPairsResponse{} func (m *AttachKeyPairsResponse) String() string { return proto.CompactTextString(m) } func (*AttachKeyPairsResponse) ProtoMessage() {} func (*AttachKeyPairsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{60} + return fileDescriptor_3cfb3b8ec240c376, []int{64} } func (m *AttachKeyPairsResponse) XXX_Unmarshal(b []byte) error { @@ -4532,7 +4724,7 @@ func (m *DetachKeyPairsRequest) Reset() { *m = DetachKeyPairsRequest{} } func (m *DetachKeyPairsRequest) String() string { return proto.CompactTextString(m) } func (*DetachKeyPairsRequest) ProtoMessage() {} func (*DetachKeyPairsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{61} + return fileDescriptor_3cfb3b8ec240c376, []int{65} } func (m *DetachKeyPairsRequest) XXX_Unmarshal(b []byte) error { @@ -4579,7 +4771,7 @@ func (m *DetachKeyPairsResponse) Reset() { *m = DetachKeyPairsResponse{} func (m *DetachKeyPairsResponse) String() string { return proto.CompactTextString(m) } func (*DetachKeyPairsResponse) ProtoMessage() {} func (*DetachKeyPairsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{62} + return fileDescriptor_3cfb3b8ec240c376, []int{66} } func (m *DetachKeyPairsResponse) XXX_Unmarshal(b []byte) error { @@ -4621,7 +4813,7 @@ func (m *NodeKeyPair) Reset() { *m = NodeKeyPair{} } func (m *NodeKeyPair) String() string { return proto.CompactTextString(m) } func (*NodeKeyPair) ProtoMessage() {} func (*NodeKeyPair) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{63} + return fileDescriptor_3cfb3b8ec240c376, []int{67} } func (m *NodeKeyPair) XXX_Unmarshal(b []byte) error { @@ -4668,7 +4860,7 @@ func (m *AddNodeKeyPairsRequest) Reset() { *m = AddNodeKeyPairsRequest{} func (m *AddNodeKeyPairsRequest) String() string { return proto.CompactTextString(m) } func (*AddNodeKeyPairsRequest) ProtoMessage() {} func (*AddNodeKeyPairsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{64} + return fileDescriptor_3cfb3b8ec240c376, []int{68} } func (m *AddNodeKeyPairsRequest) XXX_Unmarshal(b []byte) error { @@ -4706,7 +4898,7 @@ func (m *AddNodeKeyPairsResponse) Reset() { *m = AddNodeKeyPairsResponse func (m *AddNodeKeyPairsResponse) String() string { return proto.CompactTextString(m) } func (*AddNodeKeyPairsResponse) ProtoMessage() {} func (*AddNodeKeyPairsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{65} + return fileDescriptor_3cfb3b8ec240c376, []int{69} } func (m *AddNodeKeyPairsResponse) XXX_Unmarshal(b []byte) error { @@ -4739,7 +4931,7 @@ func (m *DeleteNodeKeyPairsRequest) Reset() { *m = DeleteNodeKeyPairsReq func (m *DeleteNodeKeyPairsRequest) String() string { return proto.CompactTextString(m) } func (*DeleteNodeKeyPairsRequest) ProtoMessage() {} func (*DeleteNodeKeyPairsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{66} + return fileDescriptor_3cfb3b8ec240c376, []int{70} } func (m *DeleteNodeKeyPairsRequest) XXX_Unmarshal(b []byte) error { @@ -4777,7 +4969,7 @@ func (m *DeleteNodeKeyPairsResponse) Reset() { *m = DeleteNodeKeyPairsRe func (m *DeleteNodeKeyPairsResponse) String() string { return proto.CompactTextString(m) } func (*DeleteNodeKeyPairsResponse) ProtoMessage() {} func (*DeleteNodeKeyPairsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3cfb3b8ec240c376, []int{67} + return fileDescriptor_3cfb3b8ec240c376, []int{71} } func (m *DeleteNodeKeyPairsResponse) XXX_Unmarshal(b []byte) error { @@ -4802,6 +4994,10 @@ func init() { proto.RegisterType((*DescribeSubnetsRequest)(nil), "openpitrix.DescribeSubnetsRequest") proto.RegisterType((*Subnet)(nil), "openpitrix.Subnet") proto.RegisterType((*DescribeSubnetsResponse)(nil), "openpitrix.DescribeSubnetsResponse") + proto.RegisterType((*DeleteClusterInRuntimeRequest)(nil), "openpitrix.DeleteClusterInRuntimeRequest") + proto.RegisterType((*DeleteClusterInRuntimeResponse)(nil), "openpitrix.DeleteClusterInRuntimeResponse") + proto.RegisterType((*MigrateClusterInRuntimeRequest)(nil), "openpitrix.MigrateClusterInRuntimeRequest") + proto.RegisterType((*MigrateClusterInRuntimeResponse)(nil), "openpitrix.MigrateClusterInRuntimeResponse") proto.RegisterType((*CreateClusterRequest)(nil), "openpitrix.CreateClusterRequest") proto.RegisterType((*CreateClusterResponse)(nil), "openpitrix.CreateClusterResponse") proto.RegisterType((*ModifyClusterRequest)(nil), "openpitrix.ModifyClusterRequest") @@ -4875,308 +5071,317 @@ func init() { func init() { proto.RegisterFile("cluster.proto", fileDescriptor_3cfb3b8ec240c376) } var fileDescriptor_3cfb3b8ec240c376 = []byte{ - // 4814 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x5c, 0x4f, 0x6c, 0x1c, 0xd7, - 0x79, 0xc7, 0xec, 0x92, 0x4b, 0xf2, 0x5b, 0xee, 0x92, 0x7a, 0x24, 0x97, 0xab, 0x25, 0x25, 0xaf, - 0x46, 0xfe, 0xa3, 0x3a, 0x34, 0x69, 0xcb, 0x72, 0x2c, 0x4b, 0x56, 0xe3, 0x15, 0xa5, 0x3a, 0xac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27, 0xea, 0x99, - 0xfb, 0x12, 0xcc, 0xee, 0x06, 0x9e, 0x4b, 0xda, 0x6c, 0xb1, 0x62, 0x29, 0x25, 0x82, 0x62, 0xcc, - 0xc1, 0x05, 0x44, 0x33, 0xca, 0xba, 0xee, 0x66, 0x54, 0x32, 0x91, 0xe0, 0x60, 0xad, 0x98, 0xd7, - 0x60, 0x06, 0xbb, 0x16, 0x4b, 0x43, 0xa1, 0x52, 0x16, 0xe8, 0x91, 0x27, 0x96, 0x23, 0xc5, 0x71, - 0x97, 0x23, 0xb3, 0x27, 0x5a, 0x8e, 0xdc, 0x81, 0xc5, 0x78, 0xbf, 0x23, 0xf0, 0x3c, 0x62, 0x98, - 0xad, 0x16, 0x0e, 0xa3, 0x0c, 0x31, 0xac, 0xbe, 0x45, 0x11, 0x5f, 0xd3, 0xf3, 0x48, 0x83, 0x71, - 0xa5, 0x5c, 0xb3, 0x3c, 0x9a, 0x6b, 0xde, 0x80, 0xa2, 0x58, 0xa3, 0x74, 0xbb, 0xb6, 0xa5, 0xb4, - 0xc2, 0x01, 0xce, 0xf0, 0xa0, 0x6b, 0x5b, 0x34, 0xcb, 0xc5, 0x1b, 0x91, 0x5c, 0x23, 0x2a, 0xfb, - 0x6c, 0xa5, 0x68, 0x1f, 0x92, 0xab, 0xe3, 0x06, 0xcc, 0x46, 0x42, 0x58, 0xb1, 0x7d, 0xe6, 0xd8, - 0x62, 0xbb, 0x28, 0xe8, 0x45, 0xa9, 0x9e, 0xec, 0x43, 0x44, 0xa3, 0xf5, 0x21, 0xa6, 0x16, 0x09, - 0x0b, 0xe3, 0x2c, 0x12, 0x16, 0x47, 0x5a, 0x24, 0xdc, 0x86, 0x39, 0xd3, 0xb2, 0x98, 0x59, 0x98, - 0x8e, 0x61, 0xbb, 0xbb, 0x9e, 0x58, 0xdf, 0x1c, 0xb3, 0xaa, 0xeb, 0x31, 0x6d, 0xb9, 0xbb, 0x5e, - 0x54, 0xd1, 0x54, 0x54, 0x2b, 0x9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, 0x5f, 0x41, 0x0f, 0xa9, 0x0e, 0x79, 0x52, 0xb0, 0xdd, 0x08, 0xe6, 0x08, 0x1a, 0x14, - 0xbb, 0x7b, 0x3d, 0xb5, 0xf1, 0x6d, 0x88, 0xa4, 0x77, 0xc5, 0x4f, 0xc8, 0x86, 0xa1, 0x35, 0xc2, - 0x6c, 0xb2, 0x15, 0x00, 0x49, 0x5d, 0x8d, 0x19, 0x1d, 0x08, 0xb5, 0xfa, 0x60, 0x02, 0xf1, 0x28, - 0x57, 0x8e, 0x1a, 0x4b, 0x68, 0x81, 0x27, 0xba, 0x90, 0x78, 0x29, 0x7d, 0x57, 0x74, 0xd9, 0x64, - 0x29, 0x85, 0x28, 0xe8, 0x4a, 0xd2, 0x41, 0x3f, 0x4a, 0x8d, 0xd4, 0xdf, 0x61, 0x20, 0x57, 0x2b, - 0x99, 0x5d, 0x02, 0xfa, 0x17, 0xd9, 0x72, 0x2f, 0x02, 0x63, 0x06, 0x44, 0x46, 0xb3, 0xac, 0xa3, - 0x14, 0x1a, 0x33, 0x20, 0x14, 0xce, 0x1f, 0xd3, 0x82, 0x4e, 0x3e, 0xc8, 0x4f, 0x15, 0x74, 0x99, - 0x5d, 0x04, 0xa9, 0x82, 0x2e, 0xbb, 0x13, 0x40, 0xbf, 0x96, 0xd8, 0x80, 0x09, 0x38, 0x4d, 0xca, - 0x28, 0x53, 0x95, 0xa6, 0x20, 0x8a, 0xf4, 0x24, 0x1d, 0xae, 0xa7, 0x96, 0xc5, 0x19, 0xad, 0x02, - 0xa9, 0x65, 0x71, 0xd6, 0xc9, 0xbc, 0xa4, 0xa7, 0x16, 0xa5, 0x18, 0xae, 0x27, 0x46, 0x42, 0xe1, - 0xfc, 0x50, 0x83, 0xc5, 0xac, 0x53, 0x61, 0xd9, 0x47, 0x86, 0x1c, 0xdf, 0xcb, 0x3e, 0x32, 0xec, - 0x80, 0x99, 0x2e, 0xdd, 0x57, 0xd0, 0x59, 0xb6, 0x9d, 0x11, 0xdf, 0x4c, 0xd7, 0x26, 0xc2, 0x9d, - 0x93, 0x13, 0x2a, 0x28, 0x6f, 0x4e, 0x7c, 0x90, 0xf3, 0x77, 0x76, 0x0a, 0x6c, 0x71, 0xf3, 0xea, - 0xff, 0x07, 0x00, 0x00, 0xff, 0xff, 0xd1, 0xb6, 0x11, 0xf4, 0xa5, 0x5b, 0x00, 0x00, + // 4950 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x5c, 0x4d, 0x6c, 0x24, 0xc7, + 0x75, 0x76, 0xcf, 0x90, 0x43, 0xf2, 0x0d, 0x67, 0xc8, 0x2d, 0xfe, 0xcd, 0x0e, 0xb9, 0xbb, 0xb3, + 0xbd, 0x96, 0xb4, 0x56, 0xa8, 0x5d, 0x69, 0x25, 0x59, 0x3f, 0xab, 0xb5, 0x34, 0xe2, 0x6e, 0xe4, + 0x89, 0x76, 0xa5, 0xc5, 0x70, 0x57, 0x72, 0x14, 0xc5, 0xed, 0xe6, 0x74, 0x71, 0xd8, 0x66, 0x4f, + 0x77, 0xab, 0xbb, 0x86, 0x6b, 0x0a, 0x39, 0x09, 0x41, 0x7e, 0x6c, 0x27, 0x80, 0x19, 0x24, 0x70, + 0x7e, 0x10, 0x20, 0x08, 0x62, 0x38, 0x41, 0x84, 0xd8, 0x02, 0x02, 0x44, 0xc8, 0x21, 0xa7, 0xf8, + 0x12, 0x20, 0x09, 0x90, 0x4b, 0xe0, 0x53, 0x0e, 0x3e, 0x39, 0xd7, 0xdc, 0x72, 0x09, 0xea, 0xa7, + 0x7f, 0xaa, 0xa7, 0x67, 0x58, 0xc3, 0xa1, 0x76, 0x65, 0xe4, 0x44, 0x4e, 0xf7, 0x7b, 0xaf, 0xbe, + 0x7e, 0xf5, 0xea, 0xbd, 0x57, 0x55, 0xaf, 0x0a, 0x2a, 0x1d, 0xa7, 0x1f, 0x12, 0x1c, 0x5c, 0xf1, + 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xb7, 0x61, 0x25, 0xc4, 0xc1, 0x01, 0x6b, 0xcd, 0xe8, + 0xfb, 0x3e, 0x0e, 0x8c, 0x1d, 0xaf, 0xef, 0x5a, 0x4a, 0x03, 0x1d, 0x71, 0xd6, 0x96, 0x75, 0x9f, + 0x32, 0xbe, 0x4e, 0xf9, 0xd0, 0x1b, 0xb0, 0x18, 0xf7, 0x83, 0xd9, 0x61, 0x2b, 0xd9, 0x4a, 0xab, + 0x29, 0x0b, 0x11, 0x57, 0x93, 0x33, 0xd1, 0x50, 0x64, 0xbb, 0x36, 0x31, 0x68, 0x1b, 0x76, 0x07, + 0xab, 0xad, 0x7a, 0x52, 0x8e, 0x6d, 0xce, 0x40, 0xc3, 0x61, 0x48, 0xcc, 0x20, 0x91, 0xa0, 0xb2, + 0xf6, 0x32, 0xcf, 0x58, 0x22, 0x11, 0x3c, 0x1c, 0xfa, 0xb1, 0x04, 0x95, 0xd5, 0x51, 0x1a, 0x0e, + 0xfd, 0x48, 0xc0, 0x57, 0xe1, 0x4c, 0xd8, 0x31, 0x1d, 0x6c, 0x78, 0xfd, 0x04, 0xc7, 0xac, 0x8a, + 0x3a, 0x18, 0xdb, 0xdb, 0xfd, 0x18, 0xca, 0x2f, 0xc3, 0x22, 0x97, 0x64, 0xbb, 0xb1, 0xa0, 0x39, + 0x05, 0x41, 0x55, 0xc6, 0xd5, 0x72, 0x23, 0x39, 0xb7, 0x60, 0x21, 0xc0, 0xb2, 0x5e, 0x40, 0x45, + 0x8c, 0x60, 0x4a, 0x89, 0xb1, 0x70, 0x48, 0x02, 0xef, 0x30, 0x16, 0x53, 0x56, 0x11, 0x23, 0x98, + 0x52, 0x62, 0xfa, 0x3c, 0x47, 0x8e, 0xc5, 0xcc, 0xab, 0x88, 0x11, 0x4c, 0x91, 0x98, 0x2d, 0xa8, + 0x76, 0xfa, 0x21, 0xf1, 0x7a, 0xb1, 0x94, 0x8a, 0x82, 0x94, 0x0a, 0xe7, 0x49, 0x09, 0xa1, 0x09, + 0x6a, 0x3f, 0xe9, 0xee, 0xaa, 0x8a, 0x10, 0xce, 0x93, 0x51, 0xaf, 0x17, 0x24, 0x1f, 0xb4, 0xa0, + 0xaa, 0x5e, 0x2f, 0x88, 0x3f, 0xe8, 0x1e, 0xac, 0x59, 0xcc, 0xcd, 0x1b, 0xa1, 0x6b, 0xfa, 0xe1, + 0x9e, 0x97, 0xf4, 0xd6, 0xa2, 0x82, 0xb8, 0x15, 0xce, 0xbc, 0x2d, 0x78, 0x53, 0xe6, 0xbc, 0x87, + 0x4d, 0x87, 0xec, 0x19, 0x9d, 0x3d, 0xdc, 0xd9, 0xaf, 0x9d, 0x51, 0x31, 0x67, 0xce, 0xb1, 0x45, + 0x19, 0xd0, 0x97, 0x61, 0xa6, 0xe7, 0xb9, 0x36, 0xf1, 0x82, 0x1a, 0x52, 0xe0, 0x8d, 0x88, 0xd1, + 0x4d, 0xa8, 0xfa, 0x66, 0x18, 0xfa, 0x7b, 0x81, 0x19, 0x62, 0x07, 0x87, 0x61, 0x6d, 0x49, 0x45, + 0x29, 0x32, 0x0f, 0x55, 0xca, 0x01, 0x0e, 0x88, 0xdd, 0x31, 0x1d, 0x83, 0x5a, 0xb5, 0xed, 0x76, + 0x0d, 0xdf, 0x73, 0xec, 0xce, 0x61, 0x6d, 0x59, 0x45, 0x29, 0x11, 0xf3, 0x36, 0xe7, 0xbd, 0xcb, + 0x58, 0xd1, 0x16, 0x2c, 0x98, 0x5d, 0xec, 0x12, 0x83, 0x25, 0xc2, 0x8e, 0x83, 0xad, 0xda, 0xca, + 0xb1, 0x33, 0xe2, 0x2a, 0x63, 0x69, 0x45, 0x1c, 0xa8, 0x0d, 0xab, 0xc2, 0x00, 0x7b, 0x98, 0x98, + 0x96, 0x49, 0x4c, 0x83, 0x2f, 0xda, 0xd4, 0x56, 0x15, 0x90, 0x2d, 0x73, 0xde, 0x3b, 0x82, 0x75, + 0x9b, 0x71, 0xa2, 0x17, 0x60, 0xd6, 0xee, 0xd1, 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 0x98, 0xa4, 0x1f, + 0x2a, 0x45, 0x29, 0x41, 0x8b, 0x5a, 0x70, 0x86, 0x04, 0xa6, 0x1b, 0xda, 0x34, 0xb1, 0x31, 0x84, + 0x00, 0x95, 0x00, 0xb5, 0x98, 0xb0, 0x6d, 0x73, 0x51, 0x2f, 0xc0, 0x6c, 0x37, 0xf0, 0xfa, 0x6c, + 0x43, 0xad, 0xaa, 0xf0, 0xb1, 0x33, 0x8c, 0x9a, 0xf7, 0x89, 0xf7, 0xc0, 0xc5, 0x81, 0xe1, 0x9b, + 0x64, 0x4f, 0x29, 0x24, 0xcd, 0x31, 0xfa, 0xbb, 0x26, 0xd9, 0xa3, 0xb9, 0x47, 0xd7, 0xf1, 0x76, + 0xa8, 0xdb, 0x8d, 0x55, 0xbd, 0xa8, 0xd0, 0x7a, 0x95, 0x73, 0x6d, 0x47, 0x0a, 0xbf, 0x05, 0x0b, + 0x19, 0x2f, 0xa9, 0x14, 0x82, 0xaa, 0xb2, 0x7b, 0xa4, 0x03, 0xde, 0xef, 0xef, 0x18, 0xfb, 0xf8, + 0x50, 0x29, 0x0a, 0x95, 0xfc, 0xfe, 0xce, 0x9b, 0x98, 0x2d, 0x8f, 0x88, 0xe8, 0x27, 0xba, 0x40, + 0x25, 0x06, 0x89, 0x80, 0x19, 0xab, 0x7f, 0xce, 0x0e, 0x85, 0x37, 0x14, 0x31, 0x67, 0x94, 0x0f, + 0x9c, 0xb5, 0x43, 0xee, 0xfa, 0xd0, 0x75, 0x28, 0x9b, 0x7d, 0xe2, 0x45, 0xac, 0xc7, 0x07, 0x18, + 0xa0, 0xe4, 0x09, 0x73, 0xba, 0x76, 0x60, 0x75, 0xac, 0xda, 0x81, 0xeb, 0x50, 0xe6, 0x9f, 0xcb, + 0x99, 0xd7, 0x8e, 0x67, 0xe6, 0xe4, 0x8c, 0xf9, 0x79, 0x98, 0xd9, 0xf3, 0x42, 0xe6, 0x02, 0x54, + 0x62, 0x48, 0x89, 0x12, 0xb7, 0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0x4b, 0x29, 0x10, 0x94, 0x63, 0x0e, 0x2e, 0x20, 0xea, 0x51, 0x56, 0x05, 0x39, + 0xa7, 0x12, 0x89, 0x04, 0x07, 0x2b, 0x8d, 0x7d, 0x19, 0xe6, 0xb0, 0x6b, 0xb1, 0x30, 0x14, 0x2a, + 0x45, 0x81, 0x84, 0x3c, 0x35, 0x1d, 0x29, 0x4f, 0x3a, 0x1d, 0x99, 0x3f, 0xd1, 0x74, 0xe4, 0x36, + 0x2c, 0xc7, 0xeb, 0x1d, 0x81, 0xe7, 0x11, 0xc3, 0xec, 0x74, 0x70, 0x18, 0x45, 0x88, 0x51, 0xf9, + 0x2d, 0x8a, 0xf8, 0xda, 0x9e, 0x47, 0x9a, 0x8c, 0x2b, 0x33, 0x34, 0xab, 0xe3, 0x0d, 0xcd, 0x1b, + 0x50, 0x16, 0x73, 0x94, 0x7e, 0xdf, 0xb6, 0x94, 0x66, 0x38, 0xc0, 0x19, 0xee, 0xf7, 0x6d, 0x8b, + 0x46, 0xb9, 0x78, 0x21, 0x92, 0x6b, 0x44, 0x65, 0x9d, 0xad, 0x12, 0xad, 0x43, 0x72, 0x75, 0xdc, + 0x80, 0xf9, 0x48, 0x08, 0x4b, 0xb6, 0xcf, 0x1c, 0x9b, 0x6c, 0x97, 0x05, 0xbd, 0x48, 0xd5, 0xd3, + 0x95, 0x8b, 0x68, 0xbc, 0xca, 0xc5, 0xcc, 0x24, 0x61, 0x69, 0x92, 0x49, 0xc2, 0xf2, 0x58, 0x93, + 0x84, 0x5b, 0xb0, 0x60, 0x5a, 0x16, 0x33, 0x0b, 0xd3, 0x31, 0x6c, 0x77, 0xd7, 0x13, 0xf3, 0x9b, + 0x63, 0x66, 0x75, 0x09, 0x53, 0xcb, 0xdd, 0xf5, 0xa2, 0x8c, 0x66, 0x55, 0x35, 0xa3, 0x79, 0x1a, + 0xa6, 0x2d, 0xbc, 0xd3, 0xef, 0x0e, 0x9d, 0xd2, 0xa4, 0xea, 0x57, 0x18,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a, 0x85, 0xbd, 0x61, 0xbb, 0x34, 0x08, + 0xe4, 0xd9, 0x4e, 0xe6, 0x53, 0xd8, 0x12, 0x30, 0xf3, 0x9c, 0xef, 0xc2, 0x72, 0xde, 0xd5, 0x1c, + 0xe8, 0x89, 0x4c, 0xb8, 0x1f, 0x76, 0xaf, 0x46, 0x7d, 0x75, 0x20, 0xe9, 0xba, 0xd5, 0xf3, 0xc9, + 0x21, 0xfa, 0x75, 0x3a, 0x07, 0xcb, 0xbd, 0x91, 0x43, 0xee, 0xdb, 0xd1, 0xd7, 0x76, 0x0c, 0x15, + 0xff, 0xbd, 0x38, 0x12, 0x45, 0x0b, 0x7a, 0x79, 0x91, 0x28, 0xb3, 0x3e, 0x99, 0x17, 0x89, 0xb2, + 0xeb, 0x81, 0xfa, 0x8b, 0x47, 0xcd, 0x35, 0xb4, 0x22, 0x45, 0xa2, 0x48, 0x7b, 0xb9, 0xc6, 0xc1, + 0x69, 0xa8, 0x2e, 0xbf, 0xab, 0x41, 0x55, 0xbe, 0x89, 0x42, 0xc6, 0x94, 0x7b, 0xc1, 0x86, 0x8c, + 0x29, 0xff, 0x22, 0x0b, 0xfd, 0x59, 0x96, 0x9b, 0x88, 0x97, 0x52, 0xff, 0x9e, 0xd5, 0x65, 0xc7, + 0x29, 0xea, 0x5c, 0x28, 0x9c, 0xef, 0x69, 0xb0, 0x90, 0xb9, 0x0d, 0x42, 0x76, 0xe3, 0xf9, 0x37, + 0x55, 0xc8, 0x6e, 0x7c, 0xc8, 0x75, 0x12, 0x34, 0x5b, 0x42, 0x68, 0x31, 0x7a, 0x2b, 0x41, 0xaa, + 0xeb, 0x2b, 0x12, 0xa4, 0x40, 0x10, 0x51, 0x4c, 0xd4, 0x9f, 0x4b, 0x47, 0xff, 0x65, 0x5f, 0x95, + 0x77, 0xa3, 0x81, 0xec, 0xab, 0x72, 0xef, 0x0d, 0x10, 0xfe, 0x9c, 0xbf, 0x1b, 0xe9, 0xcf, 0x03, + 0x46, 0x42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0x7c, 0x7b, 0x30, 0xfa, 0xd2, 0xd0, 0x14, 0x2e, 0x7b, 0x9f, 0x71, + 0xfd, 0x49, 0x15, 0x52, 0x81, 0xf7, 0x0b, 0x88, 0xc0, 0xda, 0x90, 0x1b, 0x8b, 0x33, 0x93, 0xee, + 0x91, 0x97, 0x28, 0x67, 0x26, 0xdd, 0xa3, 0xaf, 0x40, 0xd6, 0xbf, 0xf0, 0xfa, 0xd4, 0x7b, 0x05, + 0x7f, 0x67, 0xa7, 0xc4, 0x66, 0x71, 0xcf, 0xfe, 0x5f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x55, 0xa6, + 0x56, 0x00, 0x32, 0x5e, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -5201,7 +5406,7 @@ type ClusterManagerClient interface { DeleteKeyPairs(ctx context.Context, in *DeleteKeyPairsRequest, opts ...grpc.CallOption) (*DeleteKeyPairsResponse, error) // Batch attach key pairs to node AttachKeyPairs(ctx context.Context, in *AttachKeyPairsRequest, opts ...grpc.CallOption) (*AttachKeyPairsResponse, error) - // Batch detach key pairs from node + //Batch detach key pairs from node DetachKeyPairs(ctx context.Context, in *DetachKeyPairsRequest, opts ...grpc.CallOption) (*DetachKeyPairsResponse, error) // Get subnets DescribeSubnets(ctx context.Context, in *DescribeSubnetsRequest, opts ...grpc.CallOption) (*DescribeSubnetsResponse, error) @@ -5251,6 +5456,9 @@ type ClusterManagerClient interface { CeaseClusters(ctx context.Context, in *CeaseClustersRequest, opts ...grpc.CallOption) (*CeaseClustersResponse, error) // Get statistics of cluster GetClusterStatistics(ctx context.Context, in *GetClusterStatisticsRequest, opts ...grpc.CallOption) (*GetClusterStatisticsResponse, error) + // for kubesphere + DeleteClusterInRuntime(ctx context.Context, in *DeleteClusterInRuntimeRequest, opts ...grpc.CallOption) (*DeleteClusterInRuntimeResponse, error) + MigrateClusterInRuntime(ctx context.Context, in *MigrateClusterInRuntimeRequest, opts ...grpc.CallOption) (*MigrateClusterInRuntimeResponse, error) } type clusterManagerClient struct { @@ -5558,6 +5766,24 @@ func (c *clusterManagerClient) GetClusterStatistics(ctx context.Context, in *Get return out, nil } +func (c *clusterManagerClient) DeleteClusterInRuntime(ctx context.Context, in *DeleteClusterInRuntimeRequest, opts ...grpc.CallOption) (*DeleteClusterInRuntimeResponse, error) { + out := new(DeleteClusterInRuntimeResponse) + err := c.cc.Invoke(ctx, "/openpitrix.ClusterManager/DeleteClusterInRuntime", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *clusterManagerClient) MigrateClusterInRuntime(ctx context.Context, in *MigrateClusterInRuntimeRequest, opts ...grpc.CallOption) (*MigrateClusterInRuntimeResponse, error) { + out := new(MigrateClusterInRuntimeResponse) + err := c.cc.Invoke(ctx, "/openpitrix.ClusterManager/MigrateClusterInRuntime", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // ClusterManagerServer is the server API for ClusterManager service. type ClusterManagerServer interface { AddNodeKeyPairs(context.Context, *AddNodeKeyPairsRequest) (*AddNodeKeyPairsResponse, error) @@ -5570,7 +5796,7 @@ type ClusterManagerServer interface { DeleteKeyPairs(context.Context, *DeleteKeyPairsRequest) (*DeleteKeyPairsResponse, error) // Batch attach key pairs to node AttachKeyPairs(context.Context, *AttachKeyPairsRequest) (*AttachKeyPairsResponse, error) - // Batch detach key pairs from node + //Batch detach key pairs from node DetachKeyPairs(context.Context, *DetachKeyPairsRequest) (*DetachKeyPairsResponse, error) // Get subnets DescribeSubnets(context.Context, *DescribeSubnetsRequest) (*DescribeSubnetsResponse, error) @@ -5620,6 +5846,119 @@ type ClusterManagerServer interface { CeaseClusters(context.Context, *CeaseClustersRequest) (*CeaseClustersResponse, error) // Get statistics of cluster GetClusterStatistics(context.Context, *GetClusterStatisticsRequest) (*GetClusterStatisticsResponse, error) + // for kubesphere + DeleteClusterInRuntime(context.Context, *DeleteClusterInRuntimeRequest) (*DeleteClusterInRuntimeResponse, error) + MigrateClusterInRuntime(context.Context, *MigrateClusterInRuntimeRequest) (*MigrateClusterInRuntimeResponse, error) +} + +// UnimplementedClusterManagerServer can be embedded to have forward compatible implementations. +type UnimplementedClusterManagerServer struct { +} + +func (*UnimplementedClusterManagerServer) AddNodeKeyPairs(ctx context.Context, req *AddNodeKeyPairsRequest) (*AddNodeKeyPairsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method AddNodeKeyPairs not implemented") +} +func (*UnimplementedClusterManagerServer) DeleteNodeKeyPairs(ctx context.Context, req *DeleteNodeKeyPairsRequest) (*DeleteNodeKeyPairsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteNodeKeyPairs not implemented") +} +func (*UnimplementedClusterManagerServer) CreateKeyPair(ctx context.Context, req *CreateKeyPairRequest) (*CreateKeyPairResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateKeyPair not implemented") +} +func (*UnimplementedClusterManagerServer) DescribeKeyPairs(ctx context.Context, req *DescribeKeyPairsRequest) (*DescribeKeyPairsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeKeyPairs not implemented") +} +func (*UnimplementedClusterManagerServer) DeleteKeyPairs(ctx context.Context, req *DeleteKeyPairsRequest) (*DeleteKeyPairsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteKeyPairs not implemented") +} +func (*UnimplementedClusterManagerServer) AttachKeyPairs(ctx context.Context, req *AttachKeyPairsRequest) (*AttachKeyPairsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method AttachKeyPairs not implemented") +} +func (*UnimplementedClusterManagerServer) DetachKeyPairs(ctx context.Context, req *DetachKeyPairsRequest) (*DetachKeyPairsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DetachKeyPairs not implemented") +} +func (*UnimplementedClusterManagerServer) DescribeSubnets(ctx context.Context, req *DescribeSubnetsRequest) (*DescribeSubnetsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeSubnets not implemented") +} +func (*UnimplementedClusterManagerServer) CreateCluster(ctx context.Context, req *CreateClusterRequest) (*CreateClusterResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateCluster not implemented") +} +func (*UnimplementedClusterManagerServer) CreateDebugCluster(ctx context.Context, req *CreateClusterRequest) (*CreateClusterResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateDebugCluster not implemented") +} +func (*UnimplementedClusterManagerServer) ModifyCluster(ctx context.Context, req *ModifyClusterRequest) (*ModifyClusterResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyCluster not implemented") +} +func (*UnimplementedClusterManagerServer) ModifyClusterNode(ctx context.Context, req *ModifyClusterNodeRequest) (*ModifyClusterNodeResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyClusterNode not implemented") +} +func (*UnimplementedClusterManagerServer) ModifyClusterAttributes(ctx context.Context, req *ModifyClusterAttributesRequest) (*ModifyClusterAttributesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyClusterAttributes not implemented") +} +func (*UnimplementedClusterManagerServer) ModifyClusterNodeAttributes(ctx context.Context, req *ModifyClusterNodeAttributesRequest) (*ModifyClusterNodeAttributesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyClusterNodeAttributes not implemented") +} +func (*UnimplementedClusterManagerServer) AddTableClusterNodes(ctx context.Context, req *AddTableClusterNodesRequest) (*empty.Empty, error) { + return nil, status.Errorf(codes.Unimplemented, "method AddTableClusterNodes not implemented") +} +func (*UnimplementedClusterManagerServer) DeleteTableClusterNodes(ctx context.Context, req *DeleteTableClusterNodesRequest) (*empty.Empty, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteTableClusterNodes not implemented") +} +func (*UnimplementedClusterManagerServer) DeleteClusters(ctx context.Context, req *DeleteClustersRequest) (*DeleteClustersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteClusters not implemented") +} +func (*UnimplementedClusterManagerServer) UpgradeCluster(ctx context.Context, req *UpgradeClusterRequest) (*UpgradeClusterResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpgradeCluster not implemented") +} +func (*UnimplementedClusterManagerServer) RollbackCluster(ctx context.Context, req *RollbackClusterRequest) (*RollbackClusterResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RollbackCluster not implemented") +} +func (*UnimplementedClusterManagerServer) ResizeCluster(ctx context.Context, req *ResizeClusterRequest) (*ResizeClusterResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ResizeCluster not implemented") +} +func (*UnimplementedClusterManagerServer) AddClusterNodes(ctx context.Context, req *AddClusterNodesRequest) (*AddClusterNodesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method AddClusterNodes not implemented") +} +func (*UnimplementedClusterManagerServer) DeleteClusterNodes(ctx context.Context, req *DeleteClusterNodesRequest) (*DeleteClusterNodesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteClusterNodes not implemented") +} +func (*UnimplementedClusterManagerServer) UpdateClusterEnv(ctx context.Context, req *UpdateClusterEnvRequest) (*UpdateClusterEnvResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateClusterEnv not implemented") +} +func (*UnimplementedClusterManagerServer) DescribeClusters(ctx context.Context, req *DescribeClustersRequest) (*DescribeClustersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeClusters not implemented") +} +func (*UnimplementedClusterManagerServer) DescribeDebugClusters(ctx context.Context, req *DescribeClustersRequest) (*DescribeClustersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeDebugClusters not implemented") +} +func (*UnimplementedClusterManagerServer) DescribeAppClusters(ctx context.Context, req *DescribeAppClustersRequest) (*DescribeAppClustersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeAppClusters not implemented") +} +func (*UnimplementedClusterManagerServer) DescribeDebugAppClusters(ctx context.Context, req *DescribeAppClustersRequest) (*DescribeAppClustersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeDebugAppClusters not implemented") +} +func (*UnimplementedClusterManagerServer) DescribeClusterNodes(ctx context.Context, req *DescribeClusterNodesRequest) (*DescribeClusterNodesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeClusterNodes not implemented") +} +func (*UnimplementedClusterManagerServer) StopClusters(ctx context.Context, req *StopClustersRequest) (*StopClustersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method StopClusters not implemented") +} +func (*UnimplementedClusterManagerServer) StartClusters(ctx context.Context, req *StartClustersRequest) (*StartClustersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method StartClusters not implemented") +} +func (*UnimplementedClusterManagerServer) RecoverClusters(ctx context.Context, req *RecoverClustersRequest) (*RecoverClustersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RecoverClusters not implemented") +} +func (*UnimplementedClusterManagerServer) CeaseClusters(ctx context.Context, req *CeaseClustersRequest) (*CeaseClustersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CeaseClusters not implemented") +} +func (*UnimplementedClusterManagerServer) GetClusterStatistics(ctx context.Context, req *GetClusterStatisticsRequest) (*GetClusterStatisticsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetClusterStatistics not implemented") +} +func (*UnimplementedClusterManagerServer) DeleteClusterInRuntime(ctx context.Context, req *DeleteClusterInRuntimeRequest) (*DeleteClusterInRuntimeResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteClusterInRuntime not implemented") +} +func (*UnimplementedClusterManagerServer) MigrateClusterInRuntime(ctx context.Context, req *MigrateClusterInRuntimeRequest) (*MigrateClusterInRuntimeResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method MigrateClusterInRuntime not implemented") } func RegisterClusterManagerServer(s *grpc.Server, srv ClusterManagerServer) { @@ -6220,6 +6559,42 @@ func _ClusterManager_GetClusterStatistics_Handler(srv interface{}, ctx context.C return interceptor(ctx, in, info, handler) } +func _ClusterManager_DeleteClusterInRuntime_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(DeleteClusterInRuntimeRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ClusterManagerServer).DeleteClusterInRuntime(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/openpitrix.ClusterManager/DeleteClusterInRuntime", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ClusterManagerServer).DeleteClusterInRuntime(ctx, req.(*DeleteClusterInRuntimeRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _ClusterManager_MigrateClusterInRuntime_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MigrateClusterInRuntimeRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ClusterManagerServer).MigrateClusterInRuntime(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/openpitrix.ClusterManager/MigrateClusterInRuntime", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ClusterManagerServer).MigrateClusterInRuntime(ctx, req.(*MigrateClusterInRuntimeRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _ClusterManager_serviceDesc = grpc.ServiceDesc{ ServiceName: "openpitrix.ClusterManager", HandlerType: (*ClusterManagerServer)(nil), @@ -6356,6 +6731,14 @@ var _ClusterManager_serviceDesc = grpc.ServiceDesc{ MethodName: "GetClusterStatistics", Handler: _ClusterManager_GetClusterStatistics_Handler, }, + { + MethodName: "DeleteClusterInRuntime", + Handler: _ClusterManager_DeleteClusterInRuntime_Handler, + }, + { + MethodName: "MigrateClusterInRuntime", + Handler: _ClusterManager_MigrateClusterInRuntime_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "cluster.proto", diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/cluster.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/cluster.pb.gw.go index 5d99bebd3651dead678a5e284f9d30d75ae7ee6b..38bf77e41c9614f57a1b01f212e1634aa78c0471 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/cluster.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/cluster.pb.gw.go @@ -9,30 +9,37 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage func request_ClusterManager_CreateKeyPair_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateKeyPairRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -41,6 +48,23 @@ func request_ClusterManager_CreateKeyPair_0(ctx context.Context, marshaler runti } +func local_request_ClusterManager_CreateKeyPair_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateKeyPairRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateKeyPair(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_ClusterManager_DescribeKeyPairs_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -49,7 +73,10 @@ func request_ClusterManager_DescribeKeyPairs_0(ctx context.Context, marshaler ru var protoReq DescribeKeyPairsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeKeyPairs_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ClusterManager_DescribeKeyPairs_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -58,11 +85,28 @@ func request_ClusterManager_DescribeKeyPairs_0(ctx context.Context, marshaler ru } +func local_request_ClusterManager_DescribeKeyPairs_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeKeyPairsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeKeyPairs_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeKeyPairs(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_DeleteKeyPairs_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DeleteKeyPairsRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -71,11 +115,32 @@ func request_ClusterManager_DeleteKeyPairs_0(ctx context.Context, marshaler runt } +func local_request_ClusterManager_DeleteKeyPairs_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteKeyPairsRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteKeyPairs(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_AttachKeyPairs_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq AttachKeyPairsRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -84,11 +149,32 @@ func request_ClusterManager_AttachKeyPairs_0(ctx context.Context, marshaler runt } +func local_request_ClusterManager_AttachKeyPairs_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq AttachKeyPairsRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.AttachKeyPairs(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_DetachKeyPairs_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DetachKeyPairsRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -97,6 +183,23 @@ func request_ClusterManager_DetachKeyPairs_0(ctx context.Context, marshaler runt } +func local_request_ClusterManager_DetachKeyPairs_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DetachKeyPairsRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DetachKeyPairs(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_ClusterManager_DescribeSubnets_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -105,7 +208,10 @@ func request_ClusterManager_DescribeSubnets_0(ctx context.Context, marshaler run var protoReq DescribeSubnetsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeSubnets_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ClusterManager_DescribeSubnets_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -114,11 +220,28 @@ func request_ClusterManager_DescribeSubnets_0(ctx context.Context, marshaler run } +func local_request_ClusterManager_DescribeSubnets_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeSubnetsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeSubnets_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeSubnets(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_CreateCluster_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateClusterRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -127,11 +250,32 @@ func request_ClusterManager_CreateCluster_0(ctx context.Context, marshaler runti } +func local_request_ClusterManager_CreateCluster_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateClusterRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateCluster(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_CreateDebugCluster_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateClusterRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -140,11 +284,32 @@ func request_ClusterManager_CreateDebugCluster_0(ctx context.Context, marshaler } +func local_request_ClusterManager_CreateDebugCluster_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateClusterRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateDebugCluster(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_ModifyClusterAttributes_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyClusterAttributesRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -153,11 +318,32 @@ func request_ClusterManager_ModifyClusterAttributes_0(ctx context.Context, marsh } +func local_request_ClusterManager_ModifyClusterAttributes_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyClusterAttributesRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyClusterAttributes(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_ModifyClusterNodeAttributes_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyClusterNodeAttributesRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -166,11 +352,32 @@ func request_ClusterManager_ModifyClusterNodeAttributes_0(ctx context.Context, m } +func local_request_ClusterManager_ModifyClusterNodeAttributes_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyClusterNodeAttributesRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyClusterNodeAttributes(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_DeleteClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DeleteClustersRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -179,11 +386,32 @@ func request_ClusterManager_DeleteClusters_0(ctx context.Context, marshaler runt } +func local_request_ClusterManager_DeleteClusters_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteClustersRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteClusters(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_UpgradeCluster_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq UpgradeClusterRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -192,11 +420,32 @@ func request_ClusterManager_UpgradeCluster_0(ctx context.Context, marshaler runt } +func local_request_ClusterManager_UpgradeCluster_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UpgradeClusterRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.UpgradeCluster(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_RollbackCluster_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq RollbackClusterRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -205,11 +454,32 @@ func request_ClusterManager_RollbackCluster_0(ctx context.Context, marshaler run } +func local_request_ClusterManager_RollbackCluster_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RollbackClusterRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.RollbackCluster(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_ResizeCluster_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ResizeClusterRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -218,11 +488,32 @@ func request_ClusterManager_ResizeCluster_0(ctx context.Context, marshaler runti } +func local_request_ClusterManager_ResizeCluster_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ResizeClusterRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ResizeCluster(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_AddClusterNodes_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq AddClusterNodesRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -231,11 +522,32 @@ func request_ClusterManager_AddClusterNodes_0(ctx context.Context, marshaler run } +func local_request_ClusterManager_AddClusterNodes_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq AddClusterNodesRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.AddClusterNodes(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_DeleteClusterNodes_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DeleteClusterNodesRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -244,11 +556,32 @@ func request_ClusterManager_DeleteClusterNodes_0(ctx context.Context, marshaler } +func local_request_ClusterManager_DeleteClusterNodes_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteClusterNodesRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteClusterNodes(ctx, &protoReq) + return msg, metadata, err + +} + func request_ClusterManager_UpdateClusterEnv_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq UpdateClusterEnvRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -257,6 +590,23 @@ func request_ClusterManager_UpdateClusterEnv_0(ctx context.Context, marshaler ru } +func local_request_ClusterManager_UpdateClusterEnv_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UpdateClusterEnvRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.UpdateClusterEnv(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_ClusterManager_DescribeClusters_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -265,7 +615,10 @@ func request_ClusterManager_DescribeClusters_0(ctx context.Context, marshaler ru var protoReq DescribeClustersRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeClusters_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ClusterManager_DescribeClusters_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -274,6 +627,19 @@ func request_ClusterManager_DescribeClusters_0(ctx context.Context, marshaler ru } +func local_request_ClusterManager_DescribeClusters_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeClustersRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeClusters_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeClusters(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_ClusterManager_DescribeDebugClusters_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -282,7 +648,10 @@ func request_ClusterManager_DescribeDebugClusters_0(ctx context.Context, marshal var protoReq DescribeClustersRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeDebugClusters_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ClusterManager_DescribeDebugClusters_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -291,116 +660,818 @@ func request_ClusterManager_DescribeDebugClusters_0(ctx context.Context, marshal } +func local_request_ClusterManager_DescribeDebugClusters_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeClustersRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeDebugClusters_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeDebugClusters(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_ClusterManager_DescribeAppClusters_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) -func request_ClusterManager_DescribeAppClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq DescribeAppClustersRequest - var metadata runtime.ServerMetadata +func request_ClusterManager_DescribeAppClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeAppClustersRequest + var metadata runtime.ServerMetadata + + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ClusterManager_DescribeAppClusters_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.DescribeAppClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ClusterManager_DescribeAppClusters_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeAppClustersRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeAppClusters_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeAppClusters(ctx, &protoReq) + return msg, metadata, err + +} + +var ( + filter_ClusterManager_DescribeDebugAppClusters_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} +) + +func request_ClusterManager_DescribeDebugAppClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeAppClustersRequest + var metadata runtime.ServerMetadata + + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ClusterManager_DescribeDebugAppClusters_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.DescribeDebugAppClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ClusterManager_DescribeDebugAppClusters_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeAppClustersRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeDebugAppClusters_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeDebugAppClusters(ctx, &protoReq) + return msg, metadata, err + +} + +var ( + filter_ClusterManager_DescribeClusterNodes_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} +) + +func request_ClusterManager_DescribeClusterNodes_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeClusterNodesRequest + var metadata runtime.ServerMetadata + + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ClusterManager_DescribeClusterNodes_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.DescribeClusterNodes(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ClusterManager_DescribeClusterNodes_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeClusterNodesRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeClusterNodes_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeClusterNodes(ctx, &protoReq) + return msg, metadata, err + +} + +func request_ClusterManager_StopClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq StopClustersRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.StopClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ClusterManager_StopClusters_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq StopClustersRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.StopClusters(ctx, &protoReq) + return msg, metadata, err + +} + +func request_ClusterManager_StartClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq StartClustersRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.StartClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ClusterManager_StartClusters_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq StartClustersRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.StartClusters(ctx, &protoReq) + return msg, metadata, err + +} + +func request_ClusterManager_RecoverClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RecoverClustersRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.RecoverClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ClusterManager_RecoverClusters_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RecoverClustersRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.RecoverClusters(ctx, &protoReq) + return msg, metadata, err + +} + +func request_ClusterManager_CeaseClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CeaseClustersRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.CeaseClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ClusterManager_CeaseClusters_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CeaseClustersRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CeaseClusters(ctx, &protoReq) + return msg, metadata, err + +} + +func request_ClusterManager_GetClusterStatistics_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetClusterStatisticsRequest + var metadata runtime.ServerMetadata + + msg, err := client.GetClusterStatistics(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ClusterManager_GetClusterStatistics_0(ctx context.Context, marshaler runtime.Marshaler, server ClusterManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetClusterStatisticsRequest + var metadata runtime.ServerMetadata + + msg, err := server.GetClusterStatistics(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterClusterManagerHandlerServer registers the http handlers for service ClusterManager to "mux". +// UnaryRPC :call ClusterManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterClusterManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ClusterManagerServer) error { + + mux.Handle("POST", pattern_ClusterManager_CreateKeyPair_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_CreateKeyPair_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_CreateKeyPair_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_ClusterManager_DescribeKeyPairs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_DescribeKeyPairs_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_DescribeKeyPairs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_ClusterManager_DeleteKeyPairs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_DeleteKeyPairs_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_DeleteKeyPairs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_AttachKeyPairs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_AttachKeyPairs_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_AttachKeyPairs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_DetachKeyPairs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_DetachKeyPairs_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_DetachKeyPairs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_ClusterManager_DescribeSubnets_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_DescribeSubnets_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_DescribeSubnets_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_CreateCluster_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_CreateCluster_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_CreateCluster_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_CreateDebugCluster_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_CreateDebugCluster_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_CreateDebugCluster_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_ModifyClusterAttributes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_ModifyClusterAttributes_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_ModifyClusterAttributes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_ModifyClusterNodeAttributes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_ModifyClusterNodeAttributes_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_ModifyClusterNodeAttributes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_DeleteClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_DeleteClusters_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_DeleteClusters_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_UpgradeCluster_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_UpgradeCluster_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_UpgradeCluster_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_RollbackCluster_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_RollbackCluster_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_RollbackCluster_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_ResizeCluster_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_ResizeCluster_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_ResizeCluster_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_AddClusterNodes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_AddClusterNodes_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_AddClusterNodes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ClusterManager_DeleteClusterNodes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_DeleteClusterNodes_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_DeleteClusterNodes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_ClusterManager_UpdateClusterEnv_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_UpdateClusterEnv_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ClusterManager_UpdateClusterEnv_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeAppClusters_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + }) - msg, err := client.DescribeAppClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + mux.Handle("GET", pattern_ClusterManager_DescribeClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_DescribeClusters_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -} + forward_ClusterManager_DescribeClusters_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -var ( - filter_ClusterManager_DescribeDebugAppClusters_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} -) + }) -func request_ClusterManager_DescribeDebugAppClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq DescribeAppClustersRequest - var metadata runtime.ServerMetadata + mux.Handle("GET", pattern_ClusterManager_DescribeDebugClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_DescribeDebugClusters_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeDebugAppClusters_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + forward_ClusterManager_DescribeDebugClusters_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - msg, err := client.DescribeDebugAppClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + }) -} + mux.Handle("GET", pattern_ClusterManager_DescribeAppClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_DescribeAppClusters_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -var ( - filter_ClusterManager_DescribeClusterNodes_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} -) + forward_ClusterManager_DescribeAppClusters_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -func request_ClusterManager_DescribeClusterNodes_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq DescribeClusterNodesRequest - var metadata runtime.ServerMetadata + }) - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ClusterManager_DescribeClusterNodes_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + mux.Handle("GET", pattern_ClusterManager_DescribeDebugAppClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_DescribeDebugAppClusters_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - msg, err := client.DescribeClusterNodes(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + forward_ClusterManager_DescribeDebugAppClusters_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -} + }) -func request_ClusterManager_StopClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq StopClustersRequest - var metadata runtime.ServerMetadata + mux.Handle("GET", pattern_ClusterManager_DescribeClusterNodes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_DescribeClusterNodes_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + forward_ClusterManager_DescribeClusterNodes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - msg, err := client.StopClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + }) -} + mux.Handle("POST", pattern_ClusterManager_StopClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_StopClusters_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -func request_ClusterManager_StartClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq StartClustersRequest - var metadata runtime.ServerMetadata + forward_ClusterManager_StopClusters_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + }) - msg, err := client.StartClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + mux.Handle("POST", pattern_ClusterManager_StartClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_StartClusters_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -} + forward_ClusterManager_StartClusters_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -func request_ClusterManager_RecoverClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq RecoverClustersRequest - var metadata runtime.ServerMetadata + }) - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + mux.Handle("POST", pattern_ClusterManager_RecoverClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_RecoverClusters_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - msg, err := client.RecoverClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + forward_ClusterManager_RecoverClusters_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) -} + }) -func request_ClusterManager_CeaseClusters_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq CeaseClustersRequest - var metadata runtime.ServerMetadata + mux.Handle("POST", pattern_ClusterManager_CeaseClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_CeaseClusters_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } + forward_ClusterManager_CeaseClusters_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - msg, err := client.CeaseClusters(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + }) -} + mux.Handle("GET", pattern_ClusterManager_GetClusterStatistics_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ClusterManager_GetClusterStatistics_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } -func request_ClusterManager_GetClusterStatistics_0(ctx context.Context, marshaler runtime.Marshaler, client ClusterManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var protoReq GetClusterStatisticsRequest - var metadata runtime.ServerMetadata + forward_ClusterManager_GetClusterStatistics_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - msg, err := client.GetClusterStatistics(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err + }) + return nil } // RegisterClusterManagerHandlerFromEndpoint is same as RegisterClusterManagerHandler but @@ -444,15 +1515,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_CreateKeyPair_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -473,15 +1535,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_ClusterManager_DescribeKeyPairs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -502,15 +1555,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("DELETE", pattern_ClusterManager_DeleteKeyPairs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -531,15 +1575,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_AttachKeyPairs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -560,15 +1595,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_DetachKeyPairs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -589,15 +1615,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_ClusterManager_DescribeSubnets_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -618,15 +1635,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_CreateCluster_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -647,15 +1655,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_CreateDebugCluster_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -676,15 +1675,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_ModifyClusterAttributes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -705,15 +1695,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_ModifyClusterNodeAttributes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -734,15 +1715,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_DeleteClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -763,15 +1735,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_UpgradeCluster_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -792,15 +1755,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_RollbackCluster_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -821,15 +1775,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_ResizeCluster_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -850,15 +1795,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_AddClusterNodes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -879,15 +1815,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_DeleteClusterNodes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -908,15 +1835,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("PATCH", pattern_ClusterManager_UpdateClusterEnv_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -937,15 +1855,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_ClusterManager_DescribeClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -966,15 +1875,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_ClusterManager_DescribeDebugClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -995,15 +1895,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_ClusterManager_DescribeAppClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1024,15 +1915,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_ClusterManager_DescribeDebugAppClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1053,15 +1935,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_ClusterManager_DescribeClusterNodes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1082,15 +1955,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_StopClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1111,15 +1975,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_StartClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1140,15 +1995,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_RecoverClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1169,15 +2015,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_ClusterManager_CeaseClusters_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1198,15 +2035,6 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_ClusterManager_GetClusterStatistics_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -1228,59 +2056,59 @@ func RegisterClusterManagerHandlerClient(ctx context.Context, mux *runtime.Serve } var ( - pattern_ClusterManager_CreateKeyPair_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "key_pairs"}, "")) + pattern_ClusterManager_CreateKeyPair_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "key_pairs"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_DescribeKeyPairs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "key_pairs"}, "")) + pattern_ClusterManager_DescribeKeyPairs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "key_pairs"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_DeleteKeyPairs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "key_pairs"}, "")) + pattern_ClusterManager_DeleteKeyPairs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "key_pairs"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_AttachKeyPairs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "clusters", "key_pair", "attach"}, "")) + pattern_ClusterManager_AttachKeyPairs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "clusters", "key_pair", "attach"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_DetachKeyPairs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "clusters", "key_pair", "detach"}, "")) + pattern_ClusterManager_DetachKeyPairs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"v1", "clusters", "key_pair", "detach"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_DescribeSubnets_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "subnets"}, "")) + pattern_ClusterManager_DescribeSubnets_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "subnets"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_CreateCluster_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "create"}, "")) + pattern_ClusterManager_CreateCluster_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "create"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_CreateDebugCluster_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "debug_clusters", "create"}, "")) + pattern_ClusterManager_CreateDebugCluster_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "debug_clusters", "create"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_ModifyClusterAttributes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "modify"}, "")) + pattern_ClusterManager_ModifyClusterAttributes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "modify"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_ModifyClusterNodeAttributes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "modify_nodes"}, "")) + pattern_ClusterManager_ModifyClusterNodeAttributes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "modify_nodes"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_DeleteClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "delete"}, "")) + pattern_ClusterManager_DeleteClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "delete"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_UpgradeCluster_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "upgrade"}, "")) + pattern_ClusterManager_UpgradeCluster_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "upgrade"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_RollbackCluster_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "rollback"}, "")) + pattern_ClusterManager_RollbackCluster_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "rollback"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_ResizeCluster_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "resize"}, "")) + pattern_ClusterManager_ResizeCluster_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "resize"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_AddClusterNodes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "add_nodes"}, "")) + pattern_ClusterManager_AddClusterNodes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "add_nodes"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_DeleteClusterNodes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "delete_nodes"}, "")) + pattern_ClusterManager_DeleteClusterNodes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "delete_nodes"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_UpdateClusterEnv_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "update_env"}, "")) + pattern_ClusterManager_UpdateClusterEnv_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "update_env"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_DescribeClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "clusters"}, "")) + pattern_ClusterManager_DescribeClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "clusters"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_DescribeDebugClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "debug_clusters"}, "")) + pattern_ClusterManager_DescribeDebugClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "debug_clusters"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_DescribeAppClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "apps"}, "")) + pattern_ClusterManager_DescribeAppClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "apps"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_DescribeDebugAppClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "debug_clusters", "apps"}, "")) + pattern_ClusterManager_DescribeDebugAppClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "debug_clusters", "apps"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_DescribeClusterNodes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "nodes"}, "")) + pattern_ClusterManager_DescribeClusterNodes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "nodes"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_StopClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "stop"}, "")) + pattern_ClusterManager_StopClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "stop"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_StartClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "start"}, "")) + pattern_ClusterManager_StartClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "start"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_RecoverClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "recover"}, "")) + pattern_ClusterManager_RecoverClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "recover"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_CeaseClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "cease"}, "")) + pattern_ClusterManager_CeaseClusters_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "cease"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ClusterManager_GetClusterStatistics_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "statistics"}, "")) + pattern_ClusterManager_GetClusterStatistics_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "clusters", "statistics"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/helm.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/helm.pb.go new file mode 100644 index 0000000000000000000000000000000000000000..a81ee7a2ddd214cc23332133f64942ad3966be1e --- /dev/null +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/helm.pb.go @@ -0,0 +1,926 @@ +// Code generated by protoc-gen-go. DO NOT EDIT. +// source: helm.proto + +package pb + +import ( + context "context" + fmt "fmt" + math "math" + + proto "github.com/golang/protobuf/proto" + _ "github.com/golang/protobuf/ptypes/empty" + timestamp "github.com/golang/protobuf/ptypes/timestamp" + wrappers "github.com/golang/protobuf/ptypes/wrappers" + _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" + _ "google.golang.org/genproto/googleapis/api/annotations" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// 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.ProtoPackageIsVersion3 // please upgrade the proto package + +type Release struct { + ReleaseName *wrappers.StringValue `protobuf:"bytes,1,opt,name=release_name,json=releaseName,proto3" json:"release_name,omitempty"` + Version *wrappers.Int32Value `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"` + Namespace *wrappers.StringValue `protobuf:"bytes,3,opt,name=namespace,proto3" json:"namespace,omitempty"` + Status *wrappers.StringValue `protobuf:"bytes,4,opt,name=status,proto3" json:"status,omitempty"` + Description *wrappers.StringValue `protobuf:"bytes,5,opt,name=description,proto3" json:"description,omitempty"` + FirstDeployedTime *timestamp.Timestamp `protobuf:"bytes,6,opt,name=first_deployed_time,json=firstDeployedTime,proto3" json:"first_deployed_time,omitempty"` + LastDeployedTime *timestamp.Timestamp `protobuf:"bytes,7,opt,name=last_deployed_time,json=lastDeployedTime,proto3" json:"last_deployed_time,omitempty"` + DeletedTime *timestamp.Timestamp `protobuf:"bytes,8,opt,name=deleted_time,json=deletedTime,proto3" json:"deleted_time,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *Release) Reset() { *m = Release{} } +func (m *Release) String() string { return proto.CompactTextString(m) } +func (*Release) ProtoMessage() {} +func (*Release) Descriptor() ([]byte, []int) { + return fileDescriptor_141ba45979af1a8e, []int{0} +} + +func (m *Release) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_Release.Unmarshal(m, b) +} +func (m *Release) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_Release.Marshal(b, m, deterministic) +} +func (m *Release) XXX_Merge(src proto.Message) { + xxx_messageInfo_Release.Merge(m, src) +} +func (m *Release) XXX_Size() int { + return xxx_messageInfo_Release.Size(m) +} +func (m *Release) XXX_DiscardUnknown() { + xxx_messageInfo_Release.DiscardUnknown(m) +} + +var xxx_messageInfo_Release proto.InternalMessageInfo + +func (m *Release) GetReleaseName() *wrappers.StringValue { + if m != nil { + return m.ReleaseName + } + return nil +} + +func (m *Release) GetVersion() *wrappers.Int32Value { + if m != nil { + return m.Version + } + return nil +} + +func (m *Release) GetNamespace() *wrappers.StringValue { + if m != nil { + return m.Namespace + } + return nil +} + +func (m *Release) GetStatus() *wrappers.StringValue { + if m != nil { + return m.Status + } + return nil +} + +func (m *Release) GetDescription() *wrappers.StringValue { + if m != nil { + return m.Description + } + return nil +} + +func (m *Release) GetFirstDeployedTime() *timestamp.Timestamp { + if m != nil { + return m.FirstDeployedTime + } + return nil +} + +func (m *Release) GetLastDeployedTime() *timestamp.Timestamp { + if m != nil { + return m.LastDeployedTime + } + return nil +} + +func (m *Release) GetDeletedTime() *timestamp.Timestamp { + if m != nil { + return m.DeletedTime + } + return nil +} + +type ListReleasesRequest struct { + RuntimeId *wrappers.StringValue `protobuf:"bytes,1,opt,name=runtime_id,json=runtimeId,proto3" json:"runtime_id,omitempty"` + ReleaseName *wrappers.StringValue `protobuf:"bytes,2,opt,name=release_name,json=releaseName,proto3" json:"release_name,omitempty"` + Namespace *wrappers.StringValue `protobuf:"bytes,3,opt,name=namespace,proto3" json:"namespace,omitempty"` + Status *wrappers.StringValue `protobuf:"bytes,4,opt,name=status,proto3" json:"status,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *ListReleasesRequest) Reset() { *m = ListReleasesRequest{} } +func (m *ListReleasesRequest) String() string { return proto.CompactTextString(m) } +func (*ListReleasesRequest) ProtoMessage() {} +func (*ListReleasesRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_141ba45979af1a8e, []int{1} +} + +func (m *ListReleasesRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_ListReleasesRequest.Unmarshal(m, b) +} +func (m *ListReleasesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_ListReleasesRequest.Marshal(b, m, deterministic) +} +func (m *ListReleasesRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_ListReleasesRequest.Merge(m, src) +} +func (m *ListReleasesRequest) XXX_Size() int { + return xxx_messageInfo_ListReleasesRequest.Size(m) +} +func (m *ListReleasesRequest) XXX_DiscardUnknown() { + xxx_messageInfo_ListReleasesRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_ListReleasesRequest proto.InternalMessageInfo + +func (m *ListReleasesRequest) GetRuntimeId() *wrappers.StringValue { + if m != nil { + return m.RuntimeId + } + return nil +} + +func (m *ListReleasesRequest) GetReleaseName() *wrappers.StringValue { + if m != nil { + return m.ReleaseName + } + return nil +} + +func (m *ListReleasesRequest) GetNamespace() *wrappers.StringValue { + if m != nil { + return m.Namespace + } + return nil +} + +func (m *ListReleasesRequest) GetStatus() *wrappers.StringValue { + if m != nil { + return m.Status + } + return nil +} + +type ListReleaseResponse struct { + ReleaseSet []*Release `protobuf:"bytes,1,rep,name=release_set,json=releaseSet,proto3" json:"release_set,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *ListReleaseResponse) Reset() { *m = ListReleaseResponse{} } +func (m *ListReleaseResponse) String() string { return proto.CompactTextString(m) } +func (*ListReleaseResponse) ProtoMessage() {} +func (*ListReleaseResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_141ba45979af1a8e, []int{2} +} + +func (m *ListReleaseResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_ListReleaseResponse.Unmarshal(m, b) +} +func (m *ListReleaseResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_ListReleaseResponse.Marshal(b, m, deterministic) +} +func (m *ListReleaseResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_ListReleaseResponse.Merge(m, src) +} +func (m *ListReleaseResponse) XXX_Size() int { + return xxx_messageInfo_ListReleaseResponse.Size(m) +} +func (m *ListReleaseResponse) XXX_DiscardUnknown() { + xxx_messageInfo_ListReleaseResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_ListReleaseResponse proto.InternalMessageInfo + +func (m *ListReleaseResponse) GetReleaseSet() []*Release { + if m != nil { + return m.ReleaseSet + } + return nil +} + +type CreateReleaseRequest struct { + // required, id of app to run in cluster + AppId *wrappers.StringValue `protobuf:"bytes,1,opt,name=app_id,json=appId,proto3" json:"app_id,omitempty"` + // required, id of app version + VersionId *wrappers.StringValue `protobuf:"bytes,2,opt,name=version_id,json=versionId,proto3" json:"version_id,omitempty"` + // required, id of runtime + RuntimeId *wrappers.StringValue `protobuf:"bytes,3,opt,name=runtime_id,json=runtimeId,proto3" json:"runtime_id,omitempty"` + // release name + ReleaseName *wrappers.StringValue `protobuf:"bytes,4,opt,name=release_name,json=releaseName,proto3" json:"release_name,omitempty"` + // namespace + Namespace *wrappers.StringValue `protobuf:"bytes,5,opt,name=namespace,proto3" json:"namespace,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *CreateReleaseRequest) Reset() { *m = CreateReleaseRequest{} } +func (m *CreateReleaseRequest) String() string { return proto.CompactTextString(m) } +func (*CreateReleaseRequest) ProtoMessage() {} +func (*CreateReleaseRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_141ba45979af1a8e, []int{3} +} + +func (m *CreateReleaseRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_CreateReleaseRequest.Unmarshal(m, b) +} +func (m *CreateReleaseRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_CreateReleaseRequest.Marshal(b, m, deterministic) +} +func (m *CreateReleaseRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_CreateReleaseRequest.Merge(m, src) +} +func (m *CreateReleaseRequest) XXX_Size() int { + return xxx_messageInfo_CreateReleaseRequest.Size(m) +} +func (m *CreateReleaseRequest) XXX_DiscardUnknown() { + xxx_messageInfo_CreateReleaseRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_CreateReleaseRequest proto.InternalMessageInfo + +func (m *CreateReleaseRequest) GetAppId() *wrappers.StringValue { + if m != nil { + return m.AppId + } + return nil +} + +func (m *CreateReleaseRequest) GetVersionId() *wrappers.StringValue { + if m != nil { + return m.VersionId + } + return nil +} + +func (m *CreateReleaseRequest) GetRuntimeId() *wrappers.StringValue { + if m != nil { + return m.RuntimeId + } + return nil +} + +func (m *CreateReleaseRequest) GetReleaseName() *wrappers.StringValue { + if m != nil { + return m.ReleaseName + } + return nil +} + +func (m *CreateReleaseRequest) GetNamespace() *wrappers.StringValue { + if m != nil { + return m.Namespace + } + return nil +} + +type CreateReleaseResponse struct { + ReleaseName *wrappers.StringValue `protobuf:"bytes,1,opt,name=release_name,json=releaseName,proto3" json:"release_name,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *CreateReleaseResponse) Reset() { *m = CreateReleaseResponse{} } +func (m *CreateReleaseResponse) String() string { return proto.CompactTextString(m) } +func (*CreateReleaseResponse) ProtoMessage() {} +func (*CreateReleaseResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_141ba45979af1a8e, []int{4} +} + +func (m *CreateReleaseResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_CreateReleaseResponse.Unmarshal(m, b) +} +func (m *CreateReleaseResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_CreateReleaseResponse.Marshal(b, m, deterministic) +} +func (m *CreateReleaseResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_CreateReleaseResponse.Merge(m, src) +} +func (m *CreateReleaseResponse) XXX_Size() int { + return xxx_messageInfo_CreateReleaseResponse.Size(m) +} +func (m *CreateReleaseResponse) XXX_DiscardUnknown() { + xxx_messageInfo_CreateReleaseResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_CreateReleaseResponse proto.InternalMessageInfo + +func (m *CreateReleaseResponse) GetReleaseName() *wrappers.StringValue { + if m != nil { + return m.ReleaseName + } + return nil +} + +type UpgradeReleaseRequest struct { + RuntimeId *wrappers.StringValue `protobuf:"bytes,1,opt,name=runtime_id,json=runtimeId,proto3" json:"runtime_id,omitempty"` + ReleaseName *wrappers.StringValue `protobuf:"bytes,2,opt,name=release_name,json=releaseName,proto3" json:"release_name,omitempty"` + VersionId *wrappers.StringValue `protobuf:"bytes,3,opt,name=version_id,json=versionId,proto3" json:"version_id,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *UpgradeReleaseRequest) Reset() { *m = UpgradeReleaseRequest{} } +func (m *UpgradeReleaseRequest) String() string { return proto.CompactTextString(m) } +func (*UpgradeReleaseRequest) ProtoMessage() {} +func (*UpgradeReleaseRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_141ba45979af1a8e, []int{5} +} + +func (m *UpgradeReleaseRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_UpgradeReleaseRequest.Unmarshal(m, b) +} +func (m *UpgradeReleaseRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_UpgradeReleaseRequest.Marshal(b, m, deterministic) +} +func (m *UpgradeReleaseRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_UpgradeReleaseRequest.Merge(m, src) +} +func (m *UpgradeReleaseRequest) XXX_Size() int { + return xxx_messageInfo_UpgradeReleaseRequest.Size(m) +} +func (m *UpgradeReleaseRequest) XXX_DiscardUnknown() { + xxx_messageInfo_UpgradeReleaseRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_UpgradeReleaseRequest proto.InternalMessageInfo + +func (m *UpgradeReleaseRequest) GetRuntimeId() *wrappers.StringValue { + if m != nil { + return m.RuntimeId + } + return nil +} + +func (m *UpgradeReleaseRequest) GetReleaseName() *wrappers.StringValue { + if m != nil { + return m.ReleaseName + } + return nil +} + +func (m *UpgradeReleaseRequest) GetVersionId() *wrappers.StringValue { + if m != nil { + return m.VersionId + } + return nil +} + +type UpgradeReleaseResponse struct { + ReleaseName *wrappers.StringValue `protobuf:"bytes,1,opt,name=release_name,json=releaseName,proto3" json:"release_name,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *UpgradeReleaseResponse) Reset() { *m = UpgradeReleaseResponse{} } +func (m *UpgradeReleaseResponse) String() string { return proto.CompactTextString(m) } +func (*UpgradeReleaseResponse) ProtoMessage() {} +func (*UpgradeReleaseResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_141ba45979af1a8e, []int{6} +} + +func (m *UpgradeReleaseResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_UpgradeReleaseResponse.Unmarshal(m, b) +} +func (m *UpgradeReleaseResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_UpgradeReleaseResponse.Marshal(b, m, deterministic) +} +func (m *UpgradeReleaseResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_UpgradeReleaseResponse.Merge(m, src) +} +func (m *UpgradeReleaseResponse) XXX_Size() int { + return xxx_messageInfo_UpgradeReleaseResponse.Size(m) +} +func (m *UpgradeReleaseResponse) XXX_DiscardUnknown() { + xxx_messageInfo_UpgradeReleaseResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_UpgradeReleaseResponse proto.InternalMessageInfo + +func (m *UpgradeReleaseResponse) GetReleaseName() *wrappers.StringValue { + if m != nil { + return m.ReleaseName + } + return nil +} + +type RollbackReleaseRequest struct { + RuntimeId *wrappers.StringValue `protobuf:"bytes,1,opt,name=runtime_id,json=runtimeId,proto3" json:"runtime_id,omitempty"` + ReleaseName *wrappers.StringValue `protobuf:"bytes,2,opt,name=release_name,json=releaseName,proto3" json:"release_name,omitempty"` + Version *wrappers.Int32Value `protobuf:"bytes,3,opt,name=version,proto3" json:"version,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *RollbackReleaseRequest) Reset() { *m = RollbackReleaseRequest{} } +func (m *RollbackReleaseRequest) String() string { return proto.CompactTextString(m) } +func (*RollbackReleaseRequest) ProtoMessage() {} +func (*RollbackReleaseRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_141ba45979af1a8e, []int{7} +} + +func (m *RollbackReleaseRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_RollbackReleaseRequest.Unmarshal(m, b) +} +func (m *RollbackReleaseRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_RollbackReleaseRequest.Marshal(b, m, deterministic) +} +func (m *RollbackReleaseRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_RollbackReleaseRequest.Merge(m, src) +} +func (m *RollbackReleaseRequest) XXX_Size() int { + return xxx_messageInfo_RollbackReleaseRequest.Size(m) +} +func (m *RollbackReleaseRequest) XXX_DiscardUnknown() { + xxx_messageInfo_RollbackReleaseRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_RollbackReleaseRequest proto.InternalMessageInfo + +func (m *RollbackReleaseRequest) GetRuntimeId() *wrappers.StringValue { + if m != nil { + return m.RuntimeId + } + return nil +} + +func (m *RollbackReleaseRequest) GetReleaseName() *wrappers.StringValue { + if m != nil { + return m.ReleaseName + } + return nil +} + +func (m *RollbackReleaseRequest) GetVersion() *wrappers.Int32Value { + if m != nil { + return m.Version + } + return nil +} + +type RollbackReleaseResponse struct { + ReleaseName *wrappers.StringValue `protobuf:"bytes,1,opt,name=release_name,json=releaseName,proto3" json:"release_name,omitempty"` + Version *wrappers.Int32Value `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *RollbackReleaseResponse) Reset() { *m = RollbackReleaseResponse{} } +func (m *RollbackReleaseResponse) String() string { return proto.CompactTextString(m) } +func (*RollbackReleaseResponse) ProtoMessage() {} +func (*RollbackReleaseResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_141ba45979af1a8e, []int{8} +} + +func (m *RollbackReleaseResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_RollbackReleaseResponse.Unmarshal(m, b) +} +func (m *RollbackReleaseResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_RollbackReleaseResponse.Marshal(b, m, deterministic) +} +func (m *RollbackReleaseResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_RollbackReleaseResponse.Merge(m, src) +} +func (m *RollbackReleaseResponse) XXX_Size() int { + return xxx_messageInfo_RollbackReleaseResponse.Size(m) +} +func (m *RollbackReleaseResponse) XXX_DiscardUnknown() { + xxx_messageInfo_RollbackReleaseResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_RollbackReleaseResponse proto.InternalMessageInfo + +func (m *RollbackReleaseResponse) GetReleaseName() *wrappers.StringValue { + if m != nil { + return m.ReleaseName + } + return nil +} + +func (m *RollbackReleaseResponse) GetVersion() *wrappers.Int32Value { + if m != nil { + return m.Version + } + return nil +} + +type DeleteReleaseRequest struct { + RuntimeId *wrappers.StringValue `protobuf:"bytes,1,opt,name=runtime_id,json=runtimeId,proto3" json:"runtime_id,omitempty"` + ReleaseName *wrappers.StringValue `protobuf:"bytes,2,opt,name=release_name,json=releaseName,proto3" json:"release_name,omitempty"` + Purge *wrappers.BoolValue `protobuf:"bytes,3,opt,name=purge,proto3" json:"purge,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *DeleteReleaseRequest) Reset() { *m = DeleteReleaseRequest{} } +func (m *DeleteReleaseRequest) String() string { return proto.CompactTextString(m) } +func (*DeleteReleaseRequest) ProtoMessage() {} +func (*DeleteReleaseRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_141ba45979af1a8e, []int{9} +} + +func (m *DeleteReleaseRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_DeleteReleaseRequest.Unmarshal(m, b) +} +func (m *DeleteReleaseRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_DeleteReleaseRequest.Marshal(b, m, deterministic) +} +func (m *DeleteReleaseRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_DeleteReleaseRequest.Merge(m, src) +} +func (m *DeleteReleaseRequest) XXX_Size() int { + return xxx_messageInfo_DeleteReleaseRequest.Size(m) +} +func (m *DeleteReleaseRequest) XXX_DiscardUnknown() { + xxx_messageInfo_DeleteReleaseRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_DeleteReleaseRequest proto.InternalMessageInfo + +func (m *DeleteReleaseRequest) GetRuntimeId() *wrappers.StringValue { + if m != nil { + return m.RuntimeId + } + return nil +} + +func (m *DeleteReleaseRequest) GetReleaseName() *wrappers.StringValue { + if m != nil { + return m.ReleaseName + } + return nil +} + +func (m *DeleteReleaseRequest) GetPurge() *wrappers.BoolValue { + if m != nil { + return m.Purge + } + return nil +} + +type DeleteReleaseResponse struct { + ReleaseName *wrappers.StringValue `protobuf:"bytes,1,opt,name=release_name,json=releaseName,proto3" json:"release_name,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *DeleteReleaseResponse) Reset() { *m = DeleteReleaseResponse{} } +func (m *DeleteReleaseResponse) String() string { return proto.CompactTextString(m) } +func (*DeleteReleaseResponse) ProtoMessage() {} +func (*DeleteReleaseResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_141ba45979af1a8e, []int{10} +} + +func (m *DeleteReleaseResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_DeleteReleaseResponse.Unmarshal(m, b) +} +func (m *DeleteReleaseResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_DeleteReleaseResponse.Marshal(b, m, deterministic) +} +func (m *DeleteReleaseResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_DeleteReleaseResponse.Merge(m, src) +} +func (m *DeleteReleaseResponse) XXX_Size() int { + return xxx_messageInfo_DeleteReleaseResponse.Size(m) +} +func (m *DeleteReleaseResponse) XXX_DiscardUnknown() { + xxx_messageInfo_DeleteReleaseResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_DeleteReleaseResponse proto.InternalMessageInfo + +func (m *DeleteReleaseResponse) GetReleaseName() *wrappers.StringValue { + if m != nil { + return m.ReleaseName + } + return nil +} + +func init() { + proto.RegisterType((*Release)(nil), "openpitrix.Release") + proto.RegisterType((*ListReleasesRequest)(nil), "openpitrix.ListReleasesRequest") + proto.RegisterType((*ListReleaseResponse)(nil), "openpitrix.ListReleaseResponse") + proto.RegisterType((*CreateReleaseRequest)(nil), "openpitrix.CreateReleaseRequest") + proto.RegisterType((*CreateReleaseResponse)(nil), "openpitrix.CreateReleaseResponse") + proto.RegisterType((*UpgradeReleaseRequest)(nil), "openpitrix.UpgradeReleaseRequest") + proto.RegisterType((*UpgradeReleaseResponse)(nil), "openpitrix.UpgradeReleaseResponse") + proto.RegisterType((*RollbackReleaseRequest)(nil), "openpitrix.RollbackReleaseRequest") + proto.RegisterType((*RollbackReleaseResponse)(nil), "openpitrix.RollbackReleaseResponse") + proto.RegisterType((*DeleteReleaseRequest)(nil), "openpitrix.DeleteReleaseRequest") + proto.RegisterType((*DeleteReleaseResponse)(nil), "openpitrix.DeleteReleaseResponse") +} + +func init() { proto.RegisterFile("helm.proto", fileDescriptor_141ba45979af1a8e) } + +var fileDescriptor_141ba45979af1a8e = []byte{ + // 773 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x55, 0xcd, 0x6e, 0xd3, 0x40, + 0x10, 0x96, 0xf3, 0x57, 0x3a, 0x09, 0x69, 0xbb, 0xfd, 0x21, 0x72, 0x2b, 0x1a, 0x8c, 0x90, 0xaa, + 0xd2, 0x26, 0x90, 0xc2, 0xa5, 0x08, 0x50, 0x4a, 0x0f, 0x94, 0xbf, 0x43, 0x0a, 0x08, 0xb8, 0x44, + 0x9b, 0x78, 0x6b, 0x2c, 0x1c, 0x7b, 0xd9, 0xdd, 0xb4, 0xf4, 0x86, 0x10, 0x48, 0xbd, 0x12, 0x9e, + 0x80, 0x57, 0xe1, 0xc0, 0x8d, 0x0b, 0xbc, 0x02, 0x0f, 0x82, 0x6c, 0xaf, 0x69, 0xd6, 0x0e, 0x6d, + 0x4a, 0x2b, 0xe8, 0x29, 0x91, 0xe7, 0xfb, 0xbe, 0x99, 0x9d, 0x6f, 0x76, 0x16, 0xe0, 0x25, 0x71, + 0x3a, 0x15, 0xca, 0x3c, 0xe1, 0x21, 0xf0, 0x28, 0x71, 0xa9, 0x2d, 0x98, 0xfd, 0x46, 0x9f, 0xb5, + 0x3c, 0xcf, 0x72, 0x48, 0x35, 0x88, 0xb4, 0xba, 0x5b, 0x55, 0xd2, 0xa1, 0x62, 0x37, 0x04, 0xea, + 0xe7, 0xe3, 0xc1, 0x1d, 0x86, 0x29, 0x25, 0x8c, 0xcb, 0xf8, 0x7c, 0x3c, 0x2e, 0xec, 0x0e, 0xe1, + 0x02, 0x77, 0xa8, 0x04, 0xcc, 0x49, 0x00, 0xa6, 0x76, 0x15, 0xbb, 0xae, 0x27, 0xb0, 0xb0, 0x3d, + 0x37, 0xa2, 0x2f, 0x05, 0x3f, 0xed, 0x65, 0x8b, 0xb8, 0xcb, 0x7c, 0x07, 0x5b, 0x16, 0x61, 0x55, + 0x8f, 0x06, 0x88, 0x24, 0xda, 0xd8, 0xcb, 0xc0, 0x48, 0x83, 0x38, 0x04, 0x73, 0x82, 0x6e, 0x43, + 0x81, 0x85, 0x7f, 0x9b, 0x2e, 0xee, 0x90, 0x92, 0x56, 0xd6, 0x16, 0xf2, 0xb5, 0xb9, 0x4a, 0x98, + 0xae, 0x12, 0xd5, 0x53, 0xd9, 0x14, 0xcc, 0x76, 0xad, 0xa7, 0xd8, 0xe9, 0x92, 0x46, 0x5e, 0x32, + 0x1e, 0xe1, 0x0e, 0x41, 0xd7, 0x61, 0x64, 0x9b, 0x30, 0x6e, 0x7b, 0x6e, 0x29, 0x15, 0x70, 0x67, + 0x13, 0xdc, 0x0d, 0x57, 0xac, 0xd4, 0x42, 0x6a, 0x84, 0x45, 0xab, 0x30, 0xea, 0xe7, 0xe3, 0x14, + 0xb7, 0x49, 0x29, 0x3d, 0x44, 0xd2, 0x7d, 0x38, 0xba, 0x06, 0x39, 0x2e, 0xb0, 0xe8, 0xf2, 0x52, + 0x66, 0x08, 0xa2, 0xc4, 0xa2, 0x5b, 0x90, 0x37, 0x09, 0x6f, 0x33, 0x3b, 0xe8, 0x4b, 0x29, 0x3b, + 0xcc, 0x41, 0xfb, 0x08, 0xe8, 0x1e, 0x4c, 0x6e, 0xd9, 0x8c, 0x8b, 0xa6, 0x49, 0xa8, 0xe3, 0xed, + 0x12, 0x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x7b, 0x0d, + 0x8a, 0xea, 0x8d, 0x47, 0x4a, 0x86, 0x81, 0x1b, 0x4e, 0x37, 0x0e, 0x82, 0xc8, 0x2a, 0x2e, 0xf7, + 0xea, 0x13, 0x68, 0x4c, 0x06, 0xd5, 0x32, 0x6a, 0x89, 0x32, 0xf6, 0x34, 0x18, 0x8b, 0x5d, 0x26, + 0xa4, 0x24, 0x19, 0xbc, 0x39, 0xf4, 0x8b, 0x07, 0x62, 0x64, 0x25, 0x4b, 0xbd, 0x3a, 0x42, 0xe3, + 0x51, 0x54, 0x2d, 0xc5, 0x48, 0x94, 0xe2, 0x9b, 0xa2, 0xcc, 0x9e, 0x6a, 0xca, 0xa0, 0xeb, 0xa5, + 0x9a, 0x32, 0x70, 0x70, 0xa5, 0x29, 0x61, 0x4c, 0x2d, 0x61, 0x31, 0x5e, 0xc2, 0x5a, 0xe6, 0x45, + 0x8a, 0xb6, 0x5a, 0xb9, 0x60, 0x98, 0x57, 0x7e, 0x05, 0x00, 0x00, 0xff, 0xff, 0x0a, 0xf9, 0x10, + 0xa6, 0x2a, 0x0c, 0x00, 0x00, +} + +// Reference imports to suppress errors if they are not otherwise used. +var _ context.Context +var _ grpc.ClientConn + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +const _ = grpc.SupportPackageIsVersion4 + +// ReleaseManagerClient is the client API for ReleaseManager service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. +type ReleaseManagerClient interface { + ListReleases(ctx context.Context, in *ListReleasesRequest, opts ...grpc.CallOption) (*ListReleaseResponse, error) + CreateRelease(ctx context.Context, in *CreateReleaseRequest, opts ...grpc.CallOption) (*CreateReleaseResponse, error) + UpgradeRelease(ctx context.Context, in *UpgradeReleaseRequest, opts ...grpc.CallOption) (*UpgradeReleaseResponse, error) + RollbackRelease(ctx context.Context, in *RollbackReleaseRequest, opts ...grpc.CallOption) (*RollbackReleaseResponse, error) + DeleteRelease(ctx context.Context, in *DeleteReleaseRequest, opts ...grpc.CallOption) (*DeleteReleaseResponse, error) +} + +type releaseManagerClient struct { + cc *grpc.ClientConn +} + +func NewReleaseManagerClient(cc *grpc.ClientConn) ReleaseManagerClient { + return &releaseManagerClient{cc} +} + +func (c *releaseManagerClient) ListReleases(ctx context.Context, in *ListReleasesRequest, opts ...grpc.CallOption) (*ListReleaseResponse, error) { + out := new(ListReleaseResponse) + err := c.cc.Invoke(ctx, "/openpitrix.ReleaseManager/ListReleases", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *releaseManagerClient) CreateRelease(ctx context.Context, in *CreateReleaseRequest, opts ...grpc.CallOption) (*CreateReleaseResponse, error) { + out := new(CreateReleaseResponse) + err := c.cc.Invoke(ctx, "/openpitrix.ReleaseManager/CreateRelease", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *releaseManagerClient) UpgradeRelease(ctx context.Context, in *UpgradeReleaseRequest, opts ...grpc.CallOption) (*UpgradeReleaseResponse, error) { + out := new(UpgradeReleaseResponse) + err := c.cc.Invoke(ctx, "/openpitrix.ReleaseManager/UpgradeRelease", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *releaseManagerClient) RollbackRelease(ctx context.Context, in *RollbackReleaseRequest, opts ...grpc.CallOption) (*RollbackReleaseResponse, error) { + out := new(RollbackReleaseResponse) + err := c.cc.Invoke(ctx, "/openpitrix.ReleaseManager/RollbackRelease", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *releaseManagerClient) DeleteRelease(ctx context.Context, in *DeleteReleaseRequest, opts ...grpc.CallOption) (*DeleteReleaseResponse, error) { + out := new(DeleteReleaseResponse) + err := c.cc.Invoke(ctx, "/openpitrix.ReleaseManager/DeleteRelease", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// ReleaseManagerServer is the server API for ReleaseManager service. +type ReleaseManagerServer interface { + ListReleases(context.Context, *ListReleasesRequest) (*ListReleaseResponse, error) + CreateRelease(context.Context, *CreateReleaseRequest) (*CreateReleaseResponse, error) + UpgradeRelease(context.Context, *UpgradeReleaseRequest) (*UpgradeReleaseResponse, error) + RollbackRelease(context.Context, *RollbackReleaseRequest) (*RollbackReleaseResponse, error) + DeleteRelease(context.Context, *DeleteReleaseRequest) (*DeleteReleaseResponse, error) +} + +// UnimplementedReleaseManagerServer can be embedded to have forward compatible implementations. +type UnimplementedReleaseManagerServer struct { +} + +func (*UnimplementedReleaseManagerServer) ListReleases(ctx context.Context, req *ListReleasesRequest) (*ListReleaseResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ListReleases not implemented") +} +func (*UnimplementedReleaseManagerServer) CreateRelease(ctx context.Context, req *CreateReleaseRequest) (*CreateReleaseResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateRelease not implemented") +} +func (*UnimplementedReleaseManagerServer) UpgradeRelease(ctx context.Context, req *UpgradeReleaseRequest) (*UpgradeReleaseResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpgradeRelease not implemented") +} +func (*UnimplementedReleaseManagerServer) RollbackRelease(ctx context.Context, req *RollbackReleaseRequest) (*RollbackReleaseResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RollbackRelease not implemented") +} +func (*UnimplementedReleaseManagerServer) DeleteRelease(ctx context.Context, req *DeleteReleaseRequest) (*DeleteReleaseResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteRelease not implemented") +} + +func RegisterReleaseManagerServer(s *grpc.Server, srv ReleaseManagerServer) { + s.RegisterService(&_ReleaseManager_serviceDesc, srv) +} + +func _ReleaseManager_ListReleases_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(ListReleasesRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ReleaseManagerServer).ListReleases(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/openpitrix.ReleaseManager/ListReleases", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ReleaseManagerServer).ListReleases(ctx, req.(*ListReleasesRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _ReleaseManager_CreateRelease_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CreateReleaseRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ReleaseManagerServer).CreateRelease(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/openpitrix.ReleaseManager/CreateRelease", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ReleaseManagerServer).CreateRelease(ctx, req.(*CreateReleaseRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _ReleaseManager_UpgradeRelease_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(UpgradeReleaseRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ReleaseManagerServer).UpgradeRelease(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/openpitrix.ReleaseManager/UpgradeRelease", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ReleaseManagerServer).UpgradeRelease(ctx, req.(*UpgradeReleaseRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _ReleaseManager_RollbackRelease_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(RollbackReleaseRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ReleaseManagerServer).RollbackRelease(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/openpitrix.ReleaseManager/RollbackRelease", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ReleaseManagerServer).RollbackRelease(ctx, req.(*RollbackReleaseRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _ReleaseManager_DeleteRelease_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(DeleteReleaseRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ReleaseManagerServer).DeleteRelease(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/openpitrix.ReleaseManager/DeleteRelease", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ReleaseManagerServer).DeleteRelease(ctx, req.(*DeleteReleaseRequest)) + } + return interceptor(ctx, in, info, handler) +} + +var _ReleaseManager_serviceDesc = grpc.ServiceDesc{ + ServiceName: "openpitrix.ReleaseManager", + HandlerType: (*ReleaseManagerServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "ListReleases", + Handler: _ReleaseManager_ListReleases_Handler, + }, + { + MethodName: "CreateRelease", + Handler: _ReleaseManager_CreateRelease_Handler, + }, + { + MethodName: "UpgradeRelease", + Handler: _ReleaseManager_UpgradeRelease_Handler, + }, + { + MethodName: "RollbackRelease", + Handler: _ReleaseManager_RollbackRelease_Handler, + }, + { + MethodName: "DeleteRelease", + Handler: _ReleaseManager_DeleteRelease_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "helm.proto", +} diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/helm.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/helm.pb.gw.go new file mode 100644 index 0000000000000000000000000000000000000000..0b1360a9bbea8091c5a93052058c3c88119edf0f --- /dev/null +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/helm.pb.gw.go @@ -0,0 +1,474 @@ +// Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. +// source: helm.proto + +/* +Package pb is a reverse proxy. + +It translates gRPC into RESTful JSON APIs. +*/ +package pb + +import ( + "context" + "io" + "net/http" + + "github.com/golang/protobuf/descriptor" + "github.com/golang/protobuf/proto" + "github.com/grpc-ecosystem/grpc-gateway/runtime" + "github.com/grpc-ecosystem/grpc-gateway/utilities" + "google.golang.org/grpc" + "google.golang.org/grpc/codes" + "google.golang.org/grpc/grpclog" + "google.golang.org/grpc/status" +) + +// Suppress "imported and not used" errors +var _ codes.Code +var _ io.Reader +var _ status.Status +var _ = runtime.String +var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage + +var ( + filter_ReleaseManager_ListReleases_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} +) + +func request_ReleaseManager_ListReleases_0(ctx context.Context, marshaler runtime.Marshaler, client ReleaseManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ListReleasesRequest + var metadata runtime.ServerMetadata + + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ReleaseManager_ListReleases_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.ListReleases(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ReleaseManager_ListReleases_0(ctx context.Context, marshaler runtime.Marshaler, server ReleaseManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ListReleasesRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ReleaseManager_ListReleases_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ListReleases(ctx, &protoReq) + return msg, metadata, err + +} + +func request_ReleaseManager_CreateRelease_0(ctx context.Context, marshaler runtime.Marshaler, client ReleaseManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateReleaseRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.CreateRelease(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ReleaseManager_CreateRelease_0(ctx context.Context, marshaler runtime.Marshaler, server ReleaseManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateReleaseRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateRelease(ctx, &protoReq) + return msg, metadata, err + +} + +func request_ReleaseManager_UpgradeRelease_0(ctx context.Context, marshaler runtime.Marshaler, client ReleaseManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UpgradeReleaseRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.UpgradeRelease(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ReleaseManager_UpgradeRelease_0(ctx context.Context, marshaler runtime.Marshaler, server ReleaseManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UpgradeReleaseRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.UpgradeRelease(ctx, &protoReq) + return msg, metadata, err + +} + +func request_ReleaseManager_RollbackRelease_0(ctx context.Context, marshaler runtime.Marshaler, client ReleaseManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RollbackReleaseRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.RollbackRelease(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ReleaseManager_RollbackRelease_0(ctx context.Context, marshaler runtime.Marshaler, server ReleaseManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RollbackReleaseRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.RollbackRelease(ctx, &protoReq) + return msg, metadata, err + +} + +func request_ReleaseManager_DeleteRelease_0(ctx context.Context, marshaler runtime.Marshaler, client ReleaseManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteReleaseRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := client.DeleteRelease(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_ReleaseManager_DeleteRelease_0(ctx context.Context, marshaler runtime.Marshaler, server ReleaseManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteReleaseRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteRelease(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterReleaseManagerHandlerServer registers the http handlers for service ReleaseManager to "mux". +// UnaryRPC :call ReleaseManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterReleaseManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ReleaseManagerServer) error { + + mux.Handle("GET", pattern_ReleaseManager_ListReleases_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ReleaseManager_ListReleases_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ReleaseManager_ListReleases_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PUT", pattern_ReleaseManager_CreateRelease_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ReleaseManager_CreateRelease_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ReleaseManager_CreateRelease_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_ReleaseManager_UpgradeRelease_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ReleaseManager_UpgradeRelease_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ReleaseManager_UpgradeRelease_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ReleaseManager_RollbackRelease_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ReleaseManager_RollbackRelease_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ReleaseManager_RollbackRelease_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_ReleaseManager_DeleteRelease_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ReleaseManager_DeleteRelease_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ReleaseManager_DeleteRelease_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + +// RegisterReleaseManagerHandlerFromEndpoint is same as RegisterReleaseManagerHandler but +// automatically dials to "endpoint" and closes the connection when "ctx" gets done. +func RegisterReleaseManagerHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { + conn, err := grpc.Dial(endpoint, opts...) + if err != nil { + return err + } + defer func() { + if err != nil { + if cerr := conn.Close(); cerr != nil { + grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) + } + return + } + go func() { + <-ctx.Done() + if cerr := conn.Close(); cerr != nil { + grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) + } + }() + }() + + return RegisterReleaseManagerHandler(ctx, mux, conn) +} + +// RegisterReleaseManagerHandler registers the http handlers for service ReleaseManager to "mux". +// The handlers forward requests to the grpc endpoint over "conn". +func RegisterReleaseManagerHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { + return RegisterReleaseManagerHandlerClient(ctx, mux, NewReleaseManagerClient(conn)) +} + +// RegisterReleaseManagerHandlerClient registers the http handlers for service ReleaseManager +// to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "ReleaseManagerClient". +// Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "ReleaseManagerClient" +// doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in +// "ReleaseManagerClient" to call the correct interceptors. +func RegisterReleaseManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ReleaseManagerClient) error { + + mux.Handle("GET", pattern_ReleaseManager_ListReleases_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_ReleaseManager_ListReleases_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ReleaseManager_ListReleases_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PUT", pattern_ReleaseManager_CreateRelease_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_ReleaseManager_CreateRelease_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ReleaseManager_CreateRelease_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_ReleaseManager_UpgradeRelease_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_ReleaseManager_UpgradeRelease_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ReleaseManager_UpgradeRelease_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ReleaseManager_RollbackRelease_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_ReleaseManager_RollbackRelease_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ReleaseManager_RollbackRelease_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_ReleaseManager_DeleteRelease_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_ReleaseManager_DeleteRelease_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ReleaseManager_DeleteRelease_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + +var ( + pattern_ReleaseManager_ListReleases_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "releases"}, "", runtime.AssumeColonVerbOpt(true))) + + pattern_ReleaseManager_CreateRelease_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "releases"}, "", runtime.AssumeColonVerbOpt(true))) + + pattern_ReleaseManager_UpgradeRelease_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "releases"}, "", runtime.AssumeColonVerbOpt(true))) + + pattern_ReleaseManager_RollbackRelease_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "releases"}, "", runtime.AssumeColonVerbOpt(true))) + + pattern_ReleaseManager_DeleteRelease_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "releases"}, "", runtime.AssumeColonVerbOpt(true))) +) + +var ( + forward_ReleaseManager_ListReleases_0 = runtime.ForwardResponseMessage + + forward_ReleaseManager_CreateRelease_0 = runtime.ForwardResponseMessage + + forward_ReleaseManager_UpgradeRelease_0 = runtime.ForwardResponseMessage + + forward_ReleaseManager_RollbackRelease_0 = runtime.ForwardResponseMessage + + forward_ReleaseManager_DeleteRelease_0 = runtime.ForwardResponseMessage +) diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/isv.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/isv.pb.go index 7d5b0e5cc8eb9773457ab3e8071b30818b81896e..4d123e62bced2d96a31f5060e1935fc64974ba37 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/isv.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/isv.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -11,9 +12,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +27,7 @@ var _ = math.Inf // 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 DescribeVendorVerifyInfosRequest struct { // query key, support these fields(user_id, status) @@ -1112,6 +1114,29 @@ type IsvManagerServer interface { GetVendorVerifyInfo(context.Context, *GetVendorVerifyInfoRequest) (*GetVendorVerifyInfoResponse, error) } +// UnimplementedIsvManagerServer can be embedded to have forward compatible implementations. +type UnimplementedIsvManagerServer struct { +} + +func (*UnimplementedIsvManagerServer) SubmitVendorVerifyInfo(ctx context.Context, req *SubmitVendorVerifyInfoRequest) (*SubmitVendorVerifyInfoResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SubmitVendorVerifyInfo not implemented") +} +func (*UnimplementedIsvManagerServer) DescribeVendorVerifyInfos(ctx context.Context, req *DescribeVendorVerifyInfosRequest) (*DescribeVendorVerifyInfosResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeVendorVerifyInfos not implemented") +} +func (*UnimplementedIsvManagerServer) DescribeAppVendorStatistics(ctx context.Context, req *DescribeVendorVerifyInfosRequest) (*DescribeVendorStatisticsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeAppVendorStatistics not implemented") +} +func (*UnimplementedIsvManagerServer) PassVendorVerifyInfo(ctx context.Context, req *PassVendorVerifyInfoRequest) (*PassVendorVerifyInfoResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PassVendorVerifyInfo not implemented") +} +func (*UnimplementedIsvManagerServer) RejectVendorVerifyInfo(ctx context.Context, req *RejectVendorVerifyInfoRequest) (*RejectVendorVerifyInfoResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RejectVendorVerifyInfo not implemented") +} +func (*UnimplementedIsvManagerServer) GetVendorVerifyInfo(ctx context.Context, req *GetVendorVerifyInfoRequest) (*GetVendorVerifyInfoResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetVendorVerifyInfo not implemented") +} + func RegisterIsvManagerServer(s *grpc.Server, srv IsvManagerServer) { s.RegisterService(&_IsvManager_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/isv.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/isv.pb.gw.go index 6236032eec0534353350b902c61dad131c0ee85e..f8e211a07d56f5f54bb0bd7400140eeda1e43993 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/isv.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/isv.pb.gw.go @@ -9,30 +9,37 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage func request_IsvManager_SubmitVendorVerifyInfo_0(ctx context.Context, marshaler runtime.Marshaler, client IsvManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq SubmitVendorVerifyInfoRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -41,6 +48,23 @@ func request_IsvManager_SubmitVendorVerifyInfo_0(ctx context.Context, marshaler } +func local_request_IsvManager_SubmitVendorVerifyInfo_0(ctx context.Context, marshaler runtime.Marshaler, server IsvManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq SubmitVendorVerifyInfoRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.SubmitVendorVerifyInfo(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_IsvManager_DescribeVendorVerifyInfos_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -49,7 +73,10 @@ func request_IsvManager_DescribeVendorVerifyInfos_0(ctx context.Context, marshal var protoReq DescribeVendorVerifyInfosRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_IsvManager_DescribeVendorVerifyInfos_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_IsvManager_DescribeVendorVerifyInfos_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -58,6 +85,19 @@ func request_IsvManager_DescribeVendorVerifyInfos_0(ctx context.Context, marshal } +func local_request_IsvManager_DescribeVendorVerifyInfos_0(ctx context.Context, marshaler runtime.Marshaler, server IsvManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeVendorVerifyInfosRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_IsvManager_DescribeVendorVerifyInfos_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeVendorVerifyInfos(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_IsvManager_DescribeAppVendorStatistics_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -66,7 +106,10 @@ func request_IsvManager_DescribeAppVendorStatistics_0(ctx context.Context, marsh var protoReq DescribeVendorVerifyInfosRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_IsvManager_DescribeAppVendorStatistics_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_IsvManager_DescribeAppVendorStatistics_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -75,11 +118,28 @@ func request_IsvManager_DescribeAppVendorStatistics_0(ctx context.Context, marsh } +func local_request_IsvManager_DescribeAppVendorStatistics_0(ctx context.Context, marshaler runtime.Marshaler, server IsvManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeVendorVerifyInfosRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_IsvManager_DescribeAppVendorStatistics_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeAppVendorStatistics(ctx, &protoReq) + return msg, metadata, err + +} + func request_IsvManager_PassVendorVerifyInfo_0(ctx context.Context, marshaler runtime.Marshaler, client IsvManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq PassVendorVerifyInfoRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -88,11 +148,32 @@ func request_IsvManager_PassVendorVerifyInfo_0(ctx context.Context, marshaler ru } +func local_request_IsvManager_PassVendorVerifyInfo_0(ctx context.Context, marshaler runtime.Marshaler, server IsvManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq PassVendorVerifyInfoRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.PassVendorVerifyInfo(ctx, &protoReq) + return msg, metadata, err + +} + func request_IsvManager_RejectVendorVerifyInfo_0(ctx context.Context, marshaler runtime.Marshaler, client IsvManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq RejectVendorVerifyInfoRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -101,6 +182,23 @@ func request_IsvManager_RejectVendorVerifyInfo_0(ctx context.Context, marshaler } +func local_request_IsvManager_RejectVendorVerifyInfo_0(ctx context.Context, marshaler runtime.Marshaler, server IsvManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RejectVendorVerifyInfoRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.RejectVendorVerifyInfo(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_IsvManager_GetVendorVerifyInfo_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -109,7 +207,10 @@ func request_IsvManager_GetVendorVerifyInfo_0(ctx context.Context, marshaler run var protoReq GetVendorVerifyInfoRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_IsvManager_GetVendorVerifyInfo_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_IsvManager_GetVendorVerifyInfo_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -118,6 +219,147 @@ func request_IsvManager_GetVendorVerifyInfo_0(ctx context.Context, marshaler run } +func local_request_IsvManager_GetVendorVerifyInfo_0(ctx context.Context, marshaler runtime.Marshaler, server IsvManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetVendorVerifyInfoRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_IsvManager_GetVendorVerifyInfo_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.GetVendorVerifyInfo(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterIsvManagerHandlerServer registers the http handlers for service IsvManager to "mux". +// UnaryRPC :call IsvManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterIsvManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server IsvManagerServer) error { + + mux.Handle("POST", pattern_IsvManager_SubmitVendorVerifyInfo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_IsvManager_SubmitVendorVerifyInfo_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_IsvManager_SubmitVendorVerifyInfo_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_IsvManager_DescribeVendorVerifyInfos_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_IsvManager_DescribeVendorVerifyInfos_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_IsvManager_DescribeVendorVerifyInfos_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_IsvManager_DescribeAppVendorStatistics_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_IsvManager_DescribeAppVendorStatistics_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_IsvManager_DescribeAppVendorStatistics_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_IsvManager_PassVendorVerifyInfo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_IsvManager_PassVendorVerifyInfo_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_IsvManager_PassVendorVerifyInfo_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_IsvManager_RejectVendorVerifyInfo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_IsvManager_RejectVendorVerifyInfo_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_IsvManager_RejectVendorVerifyInfo_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_IsvManager_GetVendorVerifyInfo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_IsvManager_GetVendorVerifyInfo_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_IsvManager_GetVendorVerifyInfo_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + // RegisterIsvManagerHandlerFromEndpoint is same as RegisterIsvManagerHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterIsvManagerHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { @@ -159,15 +401,6 @@ func RegisterIsvManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_IsvManager_SubmitVendorVerifyInfo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -188,15 +421,6 @@ func RegisterIsvManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_IsvManager_DescribeVendorVerifyInfos_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -217,15 +441,6 @@ func RegisterIsvManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_IsvManager_DescribeAppVendorStatistics_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -246,15 +461,6 @@ func RegisterIsvManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_IsvManager_PassVendorVerifyInfo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -275,15 +481,6 @@ func RegisterIsvManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("POST", pattern_IsvManager_RejectVendorVerifyInfo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -304,15 +501,6 @@ func RegisterIsvManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_IsvManager_GetVendorVerifyInfo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -334,17 +522,17 @@ func RegisterIsvManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, } var ( - pattern_IsvManager_SubmitVendorVerifyInfo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_vendors"}, "")) + pattern_IsvManager_SubmitVendorVerifyInfo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_vendors"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_IsvManager_DescribeVendorVerifyInfos_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_vendors"}, "")) + pattern_IsvManager_DescribeVendorVerifyInfos_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "app_vendors"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_IsvManager_DescribeAppVendorStatistics_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app_vendors", "app_vendor_statistics"}, "")) + pattern_IsvManager_DescribeAppVendorStatistics_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app_vendors", "app_vendor_statistics"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_IsvManager_PassVendorVerifyInfo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app_vendors", "pass"}, "")) + pattern_IsvManager_PassVendorVerifyInfo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app_vendors", "pass"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_IsvManager_RejectVendorVerifyInfo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app_vendors", "reject"}, "")) + pattern_IsvManager_RejectVendorVerifyInfo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app_vendors", "reject"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_IsvManager_GetVendorVerifyInfo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app_vendors", "app_vendor"}, "")) + pattern_IsvManager_GetVendorVerifyInfo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "app_vendors", "app_vendor"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/job.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/job.pb.go index 96aea86b8be6801e534dde4416e677a2e86b60fd..22ae081084952812fedcc7c3d3d7013a613f973f 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/job.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/job.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -11,9 +12,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +27,7 @@ var _ = math.Inf // 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 CreateJobRequest struct { // required, cluster id @@ -708,6 +710,17 @@ type JobManagerServer interface { DescribeJobs(context.Context, *DescribeJobsRequest) (*DescribeJobsResponse, error) } +// UnimplementedJobManagerServer can be embedded to have forward compatible implementations. +type UnimplementedJobManagerServer struct { +} + +func (*UnimplementedJobManagerServer) CreateJob(ctx context.Context, req *CreateJobRequest) (*CreateJobResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateJob not implemented") +} +func (*UnimplementedJobManagerServer) DescribeJobs(ctx context.Context, req *DescribeJobsRequest) (*DescribeJobsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeJobs not implemented") +} + func RegisterJobManagerServer(s *grpc.Server, srv JobManagerServer) { s.RegisterService(&_JobManager_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/job.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/job.pb.gw.go index 19489b0e97386f8a52424eb5bb908ac7538d6d18..a737761ef3e9a03f2f4626627d625f3b46863802 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/job.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/job.pb.gw.go @@ -9,24 +9,27 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage var ( filter_JobManager_DescribeJobs_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} @@ -36,7 +39,10 @@ func request_JobManager_DescribeJobs_0(ctx context.Context, marshaler runtime.Ma var protoReq DescribeJobsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_JobManager_DescribeJobs_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_JobManager_DescribeJobs_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -45,6 +51,47 @@ func request_JobManager_DescribeJobs_0(ctx context.Context, marshaler runtime.Ma } +func local_request_JobManager_DescribeJobs_0(ctx context.Context, marshaler runtime.Marshaler, server JobManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeJobsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_JobManager_DescribeJobs_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeJobs(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterJobManagerHandlerServer registers the http handlers for service JobManager to "mux". +// UnaryRPC :call JobManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterJobManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server JobManagerServer) error { + + mux.Handle("GET", pattern_JobManager_DescribeJobs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_JobManager_DescribeJobs_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_JobManager_DescribeJobs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + // RegisterJobManagerHandlerFromEndpoint is same as RegisterJobManagerHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterJobManagerHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { @@ -86,15 +133,6 @@ func RegisterJobManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, mux.Handle("GET", pattern_JobManager_DescribeJobs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -116,7 +154,7 @@ func RegisterJobManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux, } var ( - pattern_JobManager_DescribeJobs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "jobs"}, "")) + pattern_JobManager_DescribeJobs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "jobs"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/market.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/market.pb.go index 9d56f03e6f3fa5792508d0c783fbb18091d3856b..090707e7b3c2b1b0d36dddc4fc864aeb12d0586b 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/market.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/market.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -11,9 +12,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +27,7 @@ var _ = math.Inf // 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 Market struct { MarketId *wrappers.StringValue `protobuf:"bytes,1,opt,name=market_id,json=marketId,proto3" json:"market_id,omitempty"` @@ -1181,6 +1183,32 @@ type MarketManagerServer interface { DescribeMarketUsers(context.Context, *DescribeMarketUsersRequest) (*DescribeMarketUsersResponse, error) } +// UnimplementedMarketManagerServer can be embedded to have forward compatible implementations. +type UnimplementedMarketManagerServer struct { +} + +func (*UnimplementedMarketManagerServer) CreateMarket(ctx context.Context, req *CreateMarketRequest) (*CreateMarketResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateMarket not implemented") +} +func (*UnimplementedMarketManagerServer) DescribeMarkets(ctx context.Context, req *DescribeMarketsRequest) (*DescribeMarketsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeMarkets not implemented") +} +func (*UnimplementedMarketManagerServer) ModifyMarket(ctx context.Context, req *ModifyMarketRequest) (*ModifyMarketResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyMarket not implemented") +} +func (*UnimplementedMarketManagerServer) DeleteMarkets(ctx context.Context, req *DeleteMarketsRequest) (*DeleteMarketsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteMarkets not implemented") +} +func (*UnimplementedMarketManagerServer) UserJoinMarket(ctx context.Context, req *UserJoinMarketRequest) (*UserJoinMarketResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UserJoinMarket not implemented") +} +func (*UnimplementedMarketManagerServer) UserLeaveMarket(ctx context.Context, req *UserLeaveMarketRequest) (*UserLeaveMarketResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UserLeaveMarket not implemented") +} +func (*UnimplementedMarketManagerServer) DescribeMarketUsers(ctx context.Context, req *DescribeMarketUsersRequest) (*DescribeMarketUsersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeMarketUsers not implemented") +} + func RegisterMarketManagerServer(s *grpc.Server, srv MarketManagerServer) { s.RegisterService(&_MarketManager_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/market.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/market.pb.gw.go index dc7998c6f9e30bf44e56dc0396a82ecfa4dc1271..0cbea0f68dc572f67206723a0174a2134a4eedb4 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/market.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/market.pb.gw.go @@ -9,30 +9,37 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage func request_MarketManager_CreateMarket_0(ctx context.Context, marshaler runtime.Marshaler, client MarketManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateMarketRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -41,6 +48,23 @@ func request_MarketManager_CreateMarket_0(ctx context.Context, marshaler runtime } +func local_request_MarketManager_CreateMarket_0(ctx context.Context, marshaler runtime.Marshaler, server MarketManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateMarketRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateMarket(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_MarketManager_DescribeMarkets_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -49,7 +73,10 @@ func request_MarketManager_DescribeMarkets_0(ctx context.Context, marshaler runt var protoReq DescribeMarketsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_MarketManager_DescribeMarkets_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_MarketManager_DescribeMarkets_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -58,11 +85,28 @@ func request_MarketManager_DescribeMarkets_0(ctx context.Context, marshaler runt } +func local_request_MarketManager_DescribeMarkets_0(ctx context.Context, marshaler runtime.Marshaler, server MarketManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeMarketsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_MarketManager_DescribeMarkets_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeMarkets(ctx, &protoReq) + return msg, metadata, err + +} + func request_MarketManager_ModifyMarket_0(ctx context.Context, marshaler runtime.Marshaler, client MarketManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyMarketRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -71,11 +115,32 @@ func request_MarketManager_ModifyMarket_0(ctx context.Context, marshaler runtime } +func local_request_MarketManager_ModifyMarket_0(ctx context.Context, marshaler runtime.Marshaler, server MarketManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyMarketRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyMarket(ctx, &protoReq) + return msg, metadata, err + +} + func request_MarketManager_DeleteMarkets_0(ctx context.Context, marshaler runtime.Marshaler, client MarketManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DeleteMarketsRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -84,11 +149,32 @@ func request_MarketManager_DeleteMarkets_0(ctx context.Context, marshaler runtim } +func local_request_MarketManager_DeleteMarkets_0(ctx context.Context, marshaler runtime.Marshaler, server MarketManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteMarketsRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteMarkets(ctx, &protoReq) + return msg, metadata, err + +} + func request_MarketManager_UserJoinMarket_0(ctx context.Context, marshaler runtime.Marshaler, client MarketManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq UserJoinMarketRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -97,11 +183,32 @@ func request_MarketManager_UserJoinMarket_0(ctx context.Context, marshaler runti } +func local_request_MarketManager_UserJoinMarket_0(ctx context.Context, marshaler runtime.Marshaler, server MarketManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UserJoinMarketRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.UserJoinMarket(ctx, &protoReq) + return msg, metadata, err + +} + func request_MarketManager_UserLeaveMarket_0(ctx context.Context, marshaler runtime.Marshaler, client MarketManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq UserLeaveMarketRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -110,6 +217,23 @@ func request_MarketManager_UserLeaveMarket_0(ctx context.Context, marshaler runt } +func local_request_MarketManager_UserLeaveMarket_0(ctx context.Context, marshaler runtime.Marshaler, server MarketManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq UserLeaveMarketRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.UserLeaveMarket(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_MarketManager_DescribeMarketUsers_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -118,7 +242,10 @@ func request_MarketManager_DescribeMarketUsers_0(ctx context.Context, marshaler var protoReq DescribeMarketUsersRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_MarketManager_DescribeMarketUsers_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_MarketManager_DescribeMarketUsers_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -127,6 +254,167 @@ func request_MarketManager_DescribeMarketUsers_0(ctx context.Context, marshaler } +func local_request_MarketManager_DescribeMarketUsers_0(ctx context.Context, marshaler runtime.Marshaler, server MarketManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeMarketUsersRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_MarketManager_DescribeMarketUsers_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeMarketUsers(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterMarketManagerHandlerServer registers the http handlers for service MarketManager to "mux". +// UnaryRPC :call MarketManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterMarketManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server MarketManagerServer) error { + + mux.Handle("POST", pattern_MarketManager_CreateMarket_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_MarketManager_CreateMarket_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_MarketManager_CreateMarket_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_MarketManager_DescribeMarkets_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_MarketManager_DescribeMarkets_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_MarketManager_DescribeMarkets_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_MarketManager_ModifyMarket_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_MarketManager_ModifyMarket_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_MarketManager_ModifyMarket_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_MarketManager_DeleteMarkets_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_MarketManager_DeleteMarkets_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_MarketManager_DeleteMarkets_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_MarketManager_UserJoinMarket_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_MarketManager_UserJoinMarket_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_MarketManager_UserJoinMarket_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_MarketManager_UserLeaveMarket_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_MarketManager_UserLeaveMarket_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_MarketManager_UserLeaveMarket_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_MarketManager_DescribeMarketUsers_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_MarketManager_DescribeMarketUsers_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_MarketManager_DescribeMarketUsers_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + // RegisterMarketManagerHandlerFromEndpoint is same as RegisterMarketManagerHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterMarketManagerHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { @@ -168,15 +456,6 @@ func RegisterMarketManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("POST", pattern_MarketManager_CreateMarket_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -197,15 +476,6 @@ func RegisterMarketManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("GET", pattern_MarketManager_DescribeMarkets_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -226,15 +496,6 @@ func RegisterMarketManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("PATCH", pattern_MarketManager_ModifyMarket_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -255,15 +516,6 @@ func RegisterMarketManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("DELETE", pattern_MarketManager_DeleteMarkets_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -284,15 +536,6 @@ func RegisterMarketManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("POST", pattern_MarketManager_UserJoinMarket_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -313,15 +556,6 @@ func RegisterMarketManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("POST", pattern_MarketManager_UserLeaveMarket_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -342,15 +576,6 @@ func RegisterMarketManagerHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("GET", pattern_MarketManager_DescribeMarketUsers_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -372,19 +597,19 @@ func RegisterMarketManagerHandlerClient(ctx context.Context, mux *runtime.ServeM } var ( - pattern_MarketManager_CreateMarket_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "")) + pattern_MarketManager_CreateMarket_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_MarketManager_DescribeMarkets_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "")) + pattern_MarketManager_DescribeMarkets_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_MarketManager_ModifyMarket_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "")) + pattern_MarketManager_ModifyMarket_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_MarketManager_DeleteMarkets_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "")) + pattern_MarketManager_DeleteMarkets_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_MarketManager_UserJoinMarket_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "join")) + pattern_MarketManager_UserJoinMarket_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "join", runtime.AssumeColonVerbOpt(true))) - pattern_MarketManager_UserLeaveMarket_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "leave")) + pattern_MarketManager_UserLeaveMarket_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "markets"}, "leave", runtime.AssumeColonVerbOpt(true))) - pattern_MarketManager_DescribeMarketUsers_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "market_users"}, "")) + pattern_MarketManager_DescribeMarketUsers_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "market_users"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/repo.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/repo.pb.go index 646312eee4d051859f19c55a3e16a194f2d4740f..a345790a241b4a055c39afa01d159aa7408028ca 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/repo.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/repo.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -11,9 +12,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +27,7 @@ var _ = math.Inf // 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 CreateRepoRequest struct { // required, repository name @@ -1314,6 +1316,26 @@ type RepoManagerServer interface { ValidateRepo(context.Context, *ValidateRepoRequest) (*ValidateRepoResponse, error) } +// UnimplementedRepoManagerServer can be embedded to have forward compatible implementations. +type UnimplementedRepoManagerServer struct { +} + +func (*UnimplementedRepoManagerServer) CreateRepo(ctx context.Context, req *CreateRepoRequest) (*CreateRepoResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateRepo not implemented") +} +func (*UnimplementedRepoManagerServer) DescribeRepos(ctx context.Context, req *DescribeReposRequest) (*DescribeReposResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeRepos not implemented") +} +func (*UnimplementedRepoManagerServer) ModifyRepo(ctx context.Context, req *ModifyRepoRequest) (*ModifyRepoResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyRepo not implemented") +} +func (*UnimplementedRepoManagerServer) DeleteRepos(ctx context.Context, req *DeleteReposRequest) (*DeleteReposResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteRepos not implemented") +} +func (*UnimplementedRepoManagerServer) ValidateRepo(ctx context.Context, req *ValidateRepoRequest) (*ValidateRepoResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ValidateRepo not implemented") +} + func RegisterRepoManagerServer(s *grpc.Server, srv RepoManagerServer) { s.RegisterService(&_RepoManager_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/repo.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/repo.pb.gw.go index 4021437ad4ae57b7d86adff3e0be6c55cd78e722..94c4af1de238869fe3ed25b0dc47f9ce9ff2aa3e 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/repo.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/repo.pb.gw.go @@ -9,30 +9,37 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage func request_RepoManager_CreateRepo_0(ctx context.Context, marshaler runtime.Marshaler, client RepoManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateRepoRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -41,6 +48,23 @@ func request_RepoManager_CreateRepo_0(ctx context.Context, marshaler runtime.Mar } +func local_request_RepoManager_CreateRepo_0(ctx context.Context, marshaler runtime.Marshaler, server RepoManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateRepoRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateRepo(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_RepoManager_DescribeRepos_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -49,7 +73,10 @@ func request_RepoManager_DescribeRepos_0(ctx context.Context, marshaler runtime. var protoReq DescribeReposRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RepoManager_DescribeRepos_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RepoManager_DescribeRepos_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -58,11 +85,28 @@ func request_RepoManager_DescribeRepos_0(ctx context.Context, marshaler runtime. } +func local_request_RepoManager_DescribeRepos_0(ctx context.Context, marshaler runtime.Marshaler, server RepoManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeReposRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RepoManager_DescribeRepos_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeRepos(ctx, &protoReq) + return msg, metadata, err + +} + func request_RepoManager_ModifyRepo_0(ctx context.Context, marshaler runtime.Marshaler, client RepoManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyRepoRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -71,11 +115,32 @@ func request_RepoManager_ModifyRepo_0(ctx context.Context, marshaler runtime.Mar } +func local_request_RepoManager_ModifyRepo_0(ctx context.Context, marshaler runtime.Marshaler, server RepoManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyRepoRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyRepo(ctx, &protoReq) + return msg, metadata, err + +} + func request_RepoManager_DeleteRepos_0(ctx context.Context, marshaler runtime.Marshaler, client RepoManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DeleteReposRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -84,6 +149,23 @@ func request_RepoManager_DeleteRepos_0(ctx context.Context, marshaler runtime.Ma } +func local_request_RepoManager_DeleteRepos_0(ctx context.Context, marshaler runtime.Marshaler, server RepoManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteReposRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteRepos(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_RepoManager_ValidateRepo_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -92,7 +174,10 @@ func request_RepoManager_ValidateRepo_0(ctx context.Context, marshaler runtime.M var protoReq ValidateRepoRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RepoManager_ValidateRepo_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RepoManager_ValidateRepo_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -101,6 +186,127 @@ func request_RepoManager_ValidateRepo_0(ctx context.Context, marshaler runtime.M } +func local_request_RepoManager_ValidateRepo_0(ctx context.Context, marshaler runtime.Marshaler, server RepoManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ValidateRepoRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RepoManager_ValidateRepo_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ValidateRepo(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterRepoManagerHandlerServer registers the http handlers for service RepoManager to "mux". +// UnaryRPC :call RepoManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterRepoManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server RepoManagerServer) error { + + mux.Handle("POST", pattern_RepoManager_CreateRepo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RepoManager_CreateRepo_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RepoManager_CreateRepo_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_RepoManager_DescribeRepos_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RepoManager_DescribeRepos_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RepoManager_DescribeRepos_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_RepoManager_ModifyRepo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RepoManager_ModifyRepo_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RepoManager_ModifyRepo_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_RepoManager_DeleteRepos_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RepoManager_DeleteRepos_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RepoManager_DeleteRepos_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_RepoManager_ValidateRepo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RepoManager_ValidateRepo_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RepoManager_ValidateRepo_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + // RegisterRepoManagerHandlerFromEndpoint is same as RegisterRepoManagerHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterRepoManagerHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { @@ -142,15 +348,6 @@ func RegisterRepoManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux mux.Handle("POST", pattern_RepoManager_CreateRepo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -171,15 +368,6 @@ func RegisterRepoManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux mux.Handle("GET", pattern_RepoManager_DescribeRepos_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -200,15 +388,6 @@ func RegisterRepoManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux mux.Handle("PATCH", pattern_RepoManager_ModifyRepo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -229,15 +408,6 @@ func RegisterRepoManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux mux.Handle("DELETE", pattern_RepoManager_DeleteRepos_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -258,15 +428,6 @@ func RegisterRepoManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux mux.Handle("GET", pattern_RepoManager_ValidateRepo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -288,15 +449,15 @@ func RegisterRepoManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux } var ( - pattern_RepoManager_CreateRepo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "repos"}, "")) + pattern_RepoManager_CreateRepo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "repos"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RepoManager_DescribeRepos_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "repos"}, "")) + pattern_RepoManager_DescribeRepos_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "repos"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RepoManager_ModifyRepo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "repos"}, "")) + pattern_RepoManager_ModifyRepo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "repos"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RepoManager_DeleteRepos_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "repos"}, "")) + pattern_RepoManager_DeleteRepos_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "repos"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RepoManager_ValidateRepo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "repos", "validate"}, "")) + pattern_RepoManager_ValidateRepo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "repos", "validate"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/repo_indexer.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/repo_indexer.pb.go index 0809c40c35597f59c89dcba76d92609fcba16c0c..63216f30fd64d98974b92a784cecaf26e12f03d1 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/repo_indexer.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/repo_indexer.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -11,9 +12,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +27,7 @@ var _ = math.Inf // 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 IndexRepoRequest struct { // id of repository to index @@ -457,6 +459,17 @@ type RepoIndexerServer interface { DescribeRepoEvents(context.Context, *DescribeRepoEventsRequest) (*DescribeRepoEventsResponse, error) } +// UnimplementedRepoIndexerServer can be embedded to have forward compatible implementations. +type UnimplementedRepoIndexerServer struct { +} + +func (*UnimplementedRepoIndexerServer) IndexRepo(ctx context.Context, req *IndexRepoRequest) (*IndexRepoResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method IndexRepo not implemented") +} +func (*UnimplementedRepoIndexerServer) DescribeRepoEvents(ctx context.Context, req *DescribeRepoEventsRequest) (*DescribeRepoEventsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeRepoEvents not implemented") +} + func RegisterRepoIndexerServer(s *grpc.Server, srv RepoIndexerServer) { s.RegisterService(&_RepoIndexer_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/repo_indexer.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/repo_indexer.pb.gw.go index d35cd9ba01221c1f574ae5f140f6516136070a27..f151082c300cbe27d0f623b2daeb7d37ac4525d3 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/repo_indexer.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/repo_indexer.pb.gw.go @@ -9,30 +9,37 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage func request_RepoIndexer_IndexRepo_0(ctx context.Context, marshaler runtime.Marshaler, client RepoIndexerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq IndexRepoRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -41,6 +48,23 @@ func request_RepoIndexer_IndexRepo_0(ctx context.Context, marshaler runtime.Mars } +func local_request_RepoIndexer_IndexRepo_0(ctx context.Context, marshaler runtime.Marshaler, server RepoIndexerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq IndexRepoRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.IndexRepo(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_RepoIndexer_DescribeRepoEvents_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -49,7 +73,10 @@ func request_RepoIndexer_DescribeRepoEvents_0(ctx context.Context, marshaler run var protoReq DescribeRepoEventsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RepoIndexer_DescribeRepoEvents_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RepoIndexer_DescribeRepoEvents_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -58,6 +85,67 @@ func request_RepoIndexer_DescribeRepoEvents_0(ctx context.Context, marshaler run } +func local_request_RepoIndexer_DescribeRepoEvents_0(ctx context.Context, marshaler runtime.Marshaler, server RepoIndexerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeRepoEventsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RepoIndexer_DescribeRepoEvents_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeRepoEvents(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterRepoIndexerHandlerServer registers the http handlers for service RepoIndexer to "mux". +// UnaryRPC :call RepoIndexerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterRepoIndexerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server RepoIndexerServer) error { + + mux.Handle("POST", pattern_RepoIndexer_IndexRepo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RepoIndexer_IndexRepo_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RepoIndexer_IndexRepo_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_RepoIndexer_DescribeRepoEvents_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RepoIndexer_DescribeRepoEvents_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RepoIndexer_DescribeRepoEvents_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + // RegisterRepoIndexerHandlerFromEndpoint is same as RegisterRepoIndexerHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterRepoIndexerHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { @@ -99,15 +187,6 @@ func RegisterRepoIndexerHandlerClient(ctx context.Context, mux *runtime.ServeMux mux.Handle("POST", pattern_RepoIndexer_IndexRepo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -128,15 +207,6 @@ func RegisterRepoIndexerHandlerClient(ctx context.Context, mux *runtime.ServeMux mux.Handle("GET", pattern_RepoIndexer_DescribeRepoEvents_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -158,9 +228,9 @@ func RegisterRepoIndexerHandlerClient(ctx context.Context, mux *runtime.ServeMux } var ( - pattern_RepoIndexer_IndexRepo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "repos", "index"}, "")) + pattern_RepoIndexer_IndexRepo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "repos", "index"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RepoIndexer_DescribeRepoEvents_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "repo_events"}, "")) + pattern_RepoIndexer_DescribeRepoEvents_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "repo_events"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/runtime.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/runtime.pb.go index 16a482da8b0f60345ca4cd16f7323a7fc9220f88..43fb3de06711ae5ed5de74e8c625149c3814167e 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/runtime.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/runtime.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -11,9 +12,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +27,7 @@ var _ = math.Inf // 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 RuntimeCredential struct { // runtime credential id @@ -364,7 +366,9 @@ type CreateRuntimeRequest struct { // required, runtime credential id RuntimeCredentialId *wrappers.StringValue `protobuf:"bytes,4,opt,name=runtime_credential_id,json=runtimeCredentialId,proto3" json:"runtime_credential_id,omitempty"` // required, runtime zone eg.[pek3a|pek3b|...] - Zone *wrappers.StringValue `protobuf:"bytes,5,opt,name=zone,proto3" json:"zone,omitempty"` + Zone *wrappers.StringValue `protobuf:"bytes,5,opt,name=zone,proto3" json:"zone,omitempty"` + // for kubesphere only, if provider this value means upsert this record + RuntimeId *wrappers.StringValue `protobuf:"bytes,10,opt,name=runtime_id,json=runtimeId,proto3" json:"runtime_id,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` @@ -430,6 +434,13 @@ func (m *CreateRuntimeRequest) GetZone() *wrappers.StringValue { return nil } +func (m *CreateRuntimeRequest) GetRuntimeId() *wrappers.StringValue { + if m != nil { + return m.RuntimeId + } + return nil +} + type CreateRuntimeResponse struct { // id of runtime created RuntimeId *wrappers.StringValue `protobuf:"bytes,1,opt,name=runtime_id,json=runtimeId,proto3" json:"runtime_id,omitempty"` @@ -490,7 +501,9 @@ type DescribeRuntimesRequest struct { // runtime provider eg.[qingcloud|aliyun|aws|kubernetes] Provider []string `protobuf:"bytes,13,rep,name=provider,proto3" json:"provider,omitempty"` // owner - Owner []string `protobuf:"bytes,14,rep,name=owner,proto3" json:"owner,omitempty"` + Owner []string `protobuf:"bytes,14,rep,name=owner,proto3" json:"owner,omitempty"` + // runtime credential id + RuntimeCredentialId []string `protobuf:"bytes,15,rep,name=runtime_credential_id,json=runtimeCredentialId,proto3" json:"runtime_credential_id,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` @@ -591,6 +604,13 @@ func (m *DescribeRuntimesRequest) GetOwner() []string { return nil } +func (m *DescribeRuntimesRequest) GetRuntimeCredentialId() []string { + if m != nil { + return m.RuntimeCredentialId + } + return nil +} + type DescribeRuntimesResponse struct { // total count of runtime TotalCount uint32 `protobuf:"varint,1,opt,name=total_count,json=totalCount,proto3" json:"total_count,omitempty"` @@ -904,7 +924,9 @@ type CreateRuntimeCredentialRequest struct { // runtime credential name Name *wrappers.StringValue `protobuf:"bytes,4,opt,name=name,proto3" json:"name,omitempty"` // runtime credential description - Description *wrappers.StringValue `protobuf:"bytes,5,opt,name=description,proto3" json:"description,omitempty"` + Description *wrappers.StringValue `protobuf:"bytes,5,opt,name=description,proto3" json:"description,omitempty"` + // for kubesphere only, if provider this value means upsert this record + RuntimeCredentialId *wrappers.StringValue `protobuf:"bytes,10,opt,name=runtime_credential_id,json=runtimeCredentialId,proto3" json:"runtime_credential_id,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` @@ -970,6 +992,13 @@ func (m *CreateRuntimeCredentialRequest) GetDescription() *wrappers.StringValue return nil } +func (m *CreateRuntimeCredentialRequest) GetRuntimeCredentialId() *wrappers.StringValue { + if m != nil { + return m.RuntimeCredentialId + } + return nil +} + type CreateRuntimeCredentialResponse struct { // id of runtime credential created RuntimeCredentialId *wrappers.StringValue `protobuf:"bytes,1,opt,name=runtime_credential_id,json=runtimeCredentialId,proto3" json:"runtime_credential_id,omitempty"` @@ -1686,127 +1715,128 @@ func init() { func init() { proto.RegisterFile("runtime.proto", fileDescriptor_86e2dd377c869464) } var fileDescriptor_86e2dd377c869464 = []byte{ - // 1915 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x58, 0xcd, 0x6f, 0x1c, 0x49, - 0x15, 0x57, 0xb7, 0x3d, 0x76, 0xfc, 0xc6, 0xe3, 0xc4, 0xb5, 0x8e, 0xdd, 0xe9, 0xf8, 0xa3, 0xdd, - 0x59, 0xd8, 0xe0, 0x8c, 0xed, 0x30, 0x44, 0xec, 0xb2, 0xab, 0x20, 0x26, 0xce, 0x2a, 0x20, 0x12, - 0x11, 0x4d, 0xbc, 0x59, 0x29, 0x97, 0x51, 0x7b, 0xa6, 0x66, 0xdc, 0x72, 0xbb, 0x6b, 0xb6, 0xba, - 0xc6, 0x83, 0x39, 0xa0, 0x15, 0x20, 0x21, 0xd8, 0x5c, 0x18, 0x84, 0x40, 0x1c, 0x38, 0x22, 0x4e, - 0x88, 0x0b, 0xe2, 0x82, 0x04, 0x42, 0x62, 0x25, 0xce, 0x88, 0xff, 0x00, 0x89, 0x03, 0x7f, 0x00, - 0x47, 0x50, 0x57, 0x55, 0x7b, 0xfa, 0x7b, 0xda, 0xf1, 0x24, 0x08, 0x76, 0x4f, 0xf6, 0x54, 0xbd, - 0x57, 0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xda, 0x74, 0x01, 0x7d, 0x90, 0x0a, 0xef, 0x51, 0x07, - 0x3d, 0x03, 0x3d, 0x25, 0x04, 0x2d, 0xe2, 0x32, 0xec, 0x32, 0xad, 0x54, 0xe0, 0x34, 0x2d, 0x11, - 0x87, 0x3d, 0xa1, 0x8d, 0xde, 0x01, 0x20, 0x03, 0x17, 0xd3, 0x66, 0xcf, 0x62, 0x87, 0xda, 0x4c, - 0x81, 0xb3, 0xe6, 0xb8, 0xfc, 0x63, 0x8b, 0x1d, 0xa2, 0xb7, 0xe0, 0x52, 0x8f, 0x92, 0x13, 0xbb, - 0x8d, 0xa9, 0x36, 0x5b, 0x40, 0xf5, 0x4c, 0x1a, 0xdd, 0x81, 0x19, 0x8f, 0x59, 0xac, 0xef, 0x69, - 0x97, 0x0a, 0xe8, 0x49, 0x59, 0xf4, 0x0e, 0x94, 0x5b, 0x14, 0x5b, 0x0c, 0x37, 0x7d, 0x67, 0xb4, - 0x39, 0xae, 0xaa, 0x27, 0x54, 0xf7, 0x83, 0x22, 0x6d, 0x80, 0x10, 0xf7, 0x17, 0x7c, 0x65, 0x71, - 0x8c, 0x50, 0x86, 0xf1, 0xca, 0x42, 0x9c, 0x2b, 0xdf, 0x86, 0x52, 0x1b, 0x1f, 0xf4, 0xbb, 0x5a, - 0x39, 0x43, 0xed, 0x1e, 0x21, 0x8e, 0x30, 0x56, 0x08, 0xa2, 0x1a, 0x94, 0x78, 0xa0, 0xb4, 0xf9, - 0x02, 0x0e, 0x0a, 0x51, 0xf3, 0x2f, 0x25, 0x98, 0x95, 0x08, 0xf0, 0x13, 0x13, 0x24, 0xbd, 0x60, - 0xb1, 0xcf, 0x49, 0xf9, 0xff, 0x4a, 0x89, 0x87, 0x4b, 0x61, 0xfa, 0x5c, 0xa5, 0x90, 0x09, 0xf0, - 0xd2, 0x05, 0x00, 0xfe, 0x2d, 0xe2, 0xe2, 0x42, 0xd5, 0xcc, 0x25, 0x63, 0x28, 0x98, 0x3d, 0x1f, - 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, 0xc2, 0xd2, 0xf4, 0xaf, 0x0e, 0xeb, 0x26, - 0x32, 0xee, 0x59, 0xac, 0x75, 0x68, 0xb4, 0x23, 0xe4, 0x9a, 0x08, 0xfe, 0xda, 0xd6, 0x38, 0xee, - 0xba, 0x96, 0xf9, 0x11, 0x08, 0x45, 0xac, 0x1a, 0xf7, 0x91, 0x4c, 0xdf, 0x2e, 0x28, 0x2d, 0x9d, - 0x78, 0x38, 0xac, 0xaf, 0xa1, 0xeb, 0x81, 0x5c, 0x56, 0x06, 0x3e, 0x6b, 0x6e, 0x66, 0xda, 0x7f, - 0x22, 0x75, 0x7d, 0x47, 0x7e, 0xaf, 0xc0, 0x6a, 0xde, 0x54, 0x85, 0x76, 0x73, 0x80, 0x95, 0x36, - 0xf9, 0xe9, 0xb7, 0x8b, 0x2b, 0x48, 0x8f, 0xbe, 0x34, 0xac, 0xaf, 0x22, 0x3d, 0x4c, 0x5f, 0x01, - 0x7a, 0x78, 0xdf, 0x10, 0xe9, 0x02, 0xce, 0x1c, 0xe2, 0x3b, 0xe8, 0x57, 0x0a, 0x2c, 0xa5, 0x0d, - 0x2b, 0xe8, 0x8d, 0xf1, 0xe3, 0x8c, 0x30, 0xf7, 0x66, 0xd1, 0xb9, 0xc7, 0xbc, 0xcb, 0x0b, 0xbf, - 0x8b, 0x19, 0x07, 0xb9, 0xd8, 0x34, 0x48, 0x27, 0xd2, 0x25, 0x5c, 0x43, 0x2b, 0x11, 0x2b, 0x47, - 0x92, 0xf7, 0xa6, 0x9f, 0xa9, 0xbd, 0x83, 0x83, 0x19, 0x3e, 0x75, 0x7e, 0xe1, 0x3f, 0x01, 0x00, - 0x00, 0xff, 0xff, 0x9c, 0xa1, 0x54, 0x90, 0x83, 0x24, 0x00, 0x00, + // 1934 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x59, 0xcd, 0x6f, 0x1c, 0x49, + 0x15, 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x19, + 0xc0, 0x4a, 0x9a, 0xfc, 0xb4, 0xbb, 0xf9, 0x15, 0xa4, 0x47, 0x5f, 0x1a, 0xd6, 0x57, 0x90, 0x16, + 0xa4, 0x2f, 0x1f, 0x3d, 0xbc, 0x6f, 0x08, 0x75, 0x01, 0x67, 0x0e, 0xf1, 0x15, 0xf4, 0x0b, 0x05, + 0x16, 0x93, 0x86, 0x15, 0xf4, 0xc6, 0xf8, 0x71, 0x46, 0x98, 0x7b, 0x3b, 0xef, 0xdc, 0x63, 0xdc, + 0xe7, 0x85, 0xdf, 0xc5, 0x8c, 0x83, 0x5c, 0x2c, 0xea, 0xa4, 0x13, 0xea, 0x12, 0x6e, 0xa0, 0xe5, + 0x90, 0x95, 0x23, 0xc9, 0x07, 0x53, 0xcf, 0x0b, 0xbd, 0x83, 0x83, 0x69, 0x3e, 0x75, 0x7e, 0xe1, + 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x13, 0x03, 0x48, 0xff, 0x46, 0x25, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -2041,6 +2071,59 @@ type RuntimeManagerServer interface { GetRuntimeStatistics(context.Context, *GetRuntimeStatisticsRequest) (*GetRuntimeStatisticsResponse, error) } +// UnimplementedRuntimeManagerServer can be embedded to have forward compatible implementations. +type UnimplementedRuntimeManagerServer struct { +} + +func (*UnimplementedRuntimeManagerServer) CreateRuntime(ctx context.Context, req *CreateRuntimeRequest) (*CreateRuntimeResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateRuntime not implemented") +} +func (*UnimplementedRuntimeManagerServer) CreateDebugRuntime(ctx context.Context, req *CreateRuntimeRequest) (*CreateRuntimeResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateDebugRuntime not implemented") +} +func (*UnimplementedRuntimeManagerServer) DescribeRuntimeDetails(ctx context.Context, req *DescribeRuntimesRequest) (*DescribeRuntimeDetailsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeRuntimeDetails not implemented") +} +func (*UnimplementedRuntimeManagerServer) DescribeRuntimes(ctx context.Context, req *DescribeRuntimesRequest) (*DescribeRuntimesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeRuntimes not implemented") +} +func (*UnimplementedRuntimeManagerServer) DescribeDebugRuntimes(ctx context.Context, req *DescribeRuntimesRequest) (*DescribeRuntimesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeDebugRuntimes not implemented") +} +func (*UnimplementedRuntimeManagerServer) ModifyRuntime(ctx context.Context, req *ModifyRuntimeRequest) (*ModifyRuntimeResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyRuntime not implemented") +} +func (*UnimplementedRuntimeManagerServer) DeleteRuntimes(ctx context.Context, req *DeleteRuntimesRequest) (*DeleteRuntimesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteRuntimes not implemented") +} +func (*UnimplementedRuntimeManagerServer) CreateRuntimeCredential(ctx context.Context, req *CreateRuntimeCredentialRequest) (*CreateRuntimeCredentialResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateRuntimeCredential not implemented") +} +func (*UnimplementedRuntimeManagerServer) CreateDebugRuntimeCredential(ctx context.Context, req *CreateRuntimeCredentialRequest) (*CreateRuntimeCredentialResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateDebugRuntimeCredential not implemented") +} +func (*UnimplementedRuntimeManagerServer) DescribeRuntimeCredentials(ctx context.Context, req *DescribeRuntimeCredentialsRequest) (*DescribeRuntimeCredentialsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeRuntimeCredentials not implemented") +} +func (*UnimplementedRuntimeManagerServer) DescribeDebugRuntimeCredentials(ctx context.Context, req *DescribeRuntimeCredentialsRequest) (*DescribeRuntimeCredentialsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeDebugRuntimeCredentials not implemented") +} +func (*UnimplementedRuntimeManagerServer) ModifyRuntimeCredential(ctx context.Context, req *ModifyRuntimeCredentialRequest) (*ModifyRuntimeCredentialResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ModifyRuntimeCredential not implemented") +} +func (*UnimplementedRuntimeManagerServer) DeleteRuntimeCredentials(ctx context.Context, req *DeleteRuntimeCredentialsRequest) (*DeleteRuntimeCredentialsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteRuntimeCredentials not implemented") +} +func (*UnimplementedRuntimeManagerServer) ValidateRuntimeCredential(ctx context.Context, req *ValidateRuntimeCredentialRequest) (*ValidateRuntimeCredentialResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ValidateRuntimeCredential not implemented") +} +func (*UnimplementedRuntimeManagerServer) DescribeRuntimeProviderZones(ctx context.Context, req *DescribeRuntimeProviderZonesRequest) (*DescribeRuntimeProviderZonesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeRuntimeProviderZones not implemented") +} +func (*UnimplementedRuntimeManagerServer) GetRuntimeStatistics(ctx context.Context, req *GetRuntimeStatisticsRequest) (*GetRuntimeStatisticsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetRuntimeStatistics not implemented") +} + func RegisterRuntimeManagerServer(s *grpc.Server, srv RuntimeManagerServer) { s.RegisterService(&_RuntimeManager_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/runtime.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/runtime.pb.gw.go index b1c1a4d283116a863dd3fbbf9323a7865e58eb85..36267e46943a8f26f17bfc27c98acdd58f943205 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/runtime.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/runtime.pb.gw.go @@ -9,30 +9,37 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage func request_RuntimeManager_CreateRuntime_0(ctx context.Context, marshaler runtime.Marshaler, client RuntimeManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateRuntimeRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -41,11 +48,32 @@ func request_RuntimeManager_CreateRuntime_0(ctx context.Context, marshaler runti } +func local_request_RuntimeManager_CreateRuntime_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateRuntimeRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateRuntime(ctx, &protoReq) + return msg, metadata, err + +} + func request_RuntimeManager_CreateDebugRuntime_0(ctx context.Context, marshaler runtime.Marshaler, client RuntimeManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateRuntimeRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -54,6 +82,23 @@ func request_RuntimeManager_CreateDebugRuntime_0(ctx context.Context, marshaler } +func local_request_RuntimeManager_CreateDebugRuntime_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateRuntimeRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateDebugRuntime(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_RuntimeManager_DescribeRuntimes_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -62,7 +107,10 @@ func request_RuntimeManager_DescribeRuntimes_0(ctx context.Context, marshaler ru var protoReq DescribeRuntimesRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RuntimeManager_DescribeRuntimes_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RuntimeManager_DescribeRuntimes_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -71,6 +119,19 @@ func request_RuntimeManager_DescribeRuntimes_0(ctx context.Context, marshaler ru } +func local_request_RuntimeManager_DescribeRuntimes_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeRuntimesRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RuntimeManager_DescribeRuntimes_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeRuntimes(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_RuntimeManager_DescribeDebugRuntimes_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -79,7 +140,10 @@ func request_RuntimeManager_DescribeDebugRuntimes_0(ctx context.Context, marshal var protoReq DescribeRuntimesRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RuntimeManager_DescribeDebugRuntimes_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RuntimeManager_DescribeDebugRuntimes_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -88,11 +152,28 @@ func request_RuntimeManager_DescribeDebugRuntimes_0(ctx context.Context, marshal } +func local_request_RuntimeManager_DescribeDebugRuntimes_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeRuntimesRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RuntimeManager_DescribeDebugRuntimes_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeDebugRuntimes(ctx, &protoReq) + return msg, metadata, err + +} + func request_RuntimeManager_ModifyRuntime_0(ctx context.Context, marshaler runtime.Marshaler, client RuntimeManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyRuntimeRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -101,11 +182,32 @@ func request_RuntimeManager_ModifyRuntime_0(ctx context.Context, marshaler runti } +func local_request_RuntimeManager_ModifyRuntime_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyRuntimeRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyRuntime(ctx, &protoReq) + return msg, metadata, err + +} + func request_RuntimeManager_DeleteRuntimes_0(ctx context.Context, marshaler runtime.Marshaler, client RuntimeManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DeleteRuntimesRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -114,11 +216,32 @@ func request_RuntimeManager_DeleteRuntimes_0(ctx context.Context, marshaler runt } +func local_request_RuntimeManager_DeleteRuntimes_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteRuntimesRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteRuntimes(ctx, &protoReq) + return msg, metadata, err + +} + func request_RuntimeManager_CreateRuntimeCredential_0(ctx context.Context, marshaler runtime.Marshaler, client RuntimeManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateRuntimeCredentialRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -127,11 +250,32 @@ func request_RuntimeManager_CreateRuntimeCredential_0(ctx context.Context, marsh } +func local_request_RuntimeManager_CreateRuntimeCredential_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateRuntimeCredentialRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateRuntimeCredential(ctx, &protoReq) + return msg, metadata, err + +} + func request_RuntimeManager_CreateDebugRuntimeCredential_0(ctx context.Context, marshaler runtime.Marshaler, client RuntimeManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq CreateRuntimeCredentialRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -140,6 +284,23 @@ func request_RuntimeManager_CreateDebugRuntimeCredential_0(ctx context.Context, } +func local_request_RuntimeManager_CreateDebugRuntimeCredential_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq CreateRuntimeCredentialRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.CreateDebugRuntimeCredential(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_RuntimeManager_DescribeRuntimeCredentials_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -148,7 +309,10 @@ func request_RuntimeManager_DescribeRuntimeCredentials_0(ctx context.Context, ma var protoReq DescribeRuntimeCredentialsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RuntimeManager_DescribeRuntimeCredentials_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RuntimeManager_DescribeRuntimeCredentials_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -157,6 +321,19 @@ func request_RuntimeManager_DescribeRuntimeCredentials_0(ctx context.Context, ma } +func local_request_RuntimeManager_DescribeRuntimeCredentials_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeRuntimeCredentialsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RuntimeManager_DescribeRuntimeCredentials_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeRuntimeCredentials(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_RuntimeManager_DescribeDebugRuntimeCredentials_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -165,7 +342,10 @@ func request_RuntimeManager_DescribeDebugRuntimeCredentials_0(ctx context.Contex var protoReq DescribeRuntimeCredentialsRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RuntimeManager_DescribeDebugRuntimeCredentials_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RuntimeManager_DescribeDebugRuntimeCredentials_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -174,11 +354,28 @@ func request_RuntimeManager_DescribeDebugRuntimeCredentials_0(ctx context.Contex } +func local_request_RuntimeManager_DescribeDebugRuntimeCredentials_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeRuntimeCredentialsRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RuntimeManager_DescribeDebugRuntimeCredentials_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeDebugRuntimeCredentials(ctx, &protoReq) + return msg, metadata, err + +} + func request_RuntimeManager_ModifyRuntimeCredential_0(ctx context.Context, marshaler runtime.Marshaler, client RuntimeManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ModifyRuntimeCredentialRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -187,11 +384,32 @@ func request_RuntimeManager_ModifyRuntimeCredential_0(ctx context.Context, marsh } +func local_request_RuntimeManager_ModifyRuntimeCredential_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ModifyRuntimeCredentialRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ModifyRuntimeCredential(ctx, &protoReq) + return msg, metadata, err + +} + func request_RuntimeManager_DeleteRuntimeCredentials_0(ctx context.Context, marshaler runtime.Marshaler, client RuntimeManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq DeleteRuntimeCredentialsRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -200,11 +418,32 @@ func request_RuntimeManager_DeleteRuntimeCredentials_0(ctx context.Context, mars } +func local_request_RuntimeManager_DeleteRuntimeCredentials_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DeleteRuntimeCredentialsRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DeleteRuntimeCredentials(ctx, &protoReq) + return msg, metadata, err + +} + func request_RuntimeManager_ValidateRuntimeCredential_0(ctx context.Context, marshaler runtime.Marshaler, client RuntimeManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ValidateRuntimeCredentialRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -213,6 +452,23 @@ func request_RuntimeManager_ValidateRuntimeCredential_0(ctx context.Context, mar } +func local_request_RuntimeManager_ValidateRuntimeCredential_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ValidateRuntimeCredentialRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ValidateRuntimeCredential(ctx, &protoReq) + return msg, metadata, err + +} + var ( filter_RuntimeManager_DescribeRuntimeProviderZones_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) @@ -221,7 +477,10 @@ func request_RuntimeManager_DescribeRuntimeProviderZones_0(ctx context.Context, var protoReq DescribeRuntimeProviderZonesRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RuntimeManager_DescribeRuntimeProviderZones_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RuntimeManager_DescribeRuntimeProviderZones_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -230,6 +489,19 @@ func request_RuntimeManager_DescribeRuntimeProviderZones_0(ctx context.Context, } +func local_request_RuntimeManager_DescribeRuntimeProviderZones_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeRuntimeProviderZonesRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RuntimeManager_DescribeRuntimeProviderZones_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeRuntimeProviderZones(ctx, &protoReq) + return msg, metadata, err + +} + func request_RuntimeManager_GetRuntimeStatistics_0(ctx context.Context, marshaler runtime.Marshaler, client RuntimeManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq GetRuntimeStatisticsRequest var metadata runtime.ServerMetadata @@ -239,6 +511,323 @@ func request_RuntimeManager_GetRuntimeStatistics_0(ctx context.Context, marshale } +func local_request_RuntimeManager_GetRuntimeStatistics_0(ctx context.Context, marshaler runtime.Marshaler, server RuntimeManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetRuntimeStatisticsRequest + var metadata runtime.ServerMetadata + + msg, err := server.GetRuntimeStatistics(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterRuntimeManagerHandlerServer registers the http handlers for service RuntimeManager to "mux". +// UnaryRPC :call RuntimeManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterRuntimeManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server RuntimeManagerServer) error { + + mux.Handle("POST", pattern_RuntimeManager_CreateRuntime_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_CreateRuntime_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_CreateRuntime_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_RuntimeManager_CreateDebugRuntime_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_CreateDebugRuntime_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_CreateDebugRuntime_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_RuntimeManager_DescribeRuntimes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_DescribeRuntimes_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_DescribeRuntimes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_RuntimeManager_DescribeDebugRuntimes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_DescribeDebugRuntimes_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_DescribeDebugRuntimes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_RuntimeManager_ModifyRuntime_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_ModifyRuntime_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_ModifyRuntime_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_RuntimeManager_DeleteRuntimes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_DeleteRuntimes_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_DeleteRuntimes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_RuntimeManager_CreateRuntimeCredential_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_CreateRuntimeCredential_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_CreateRuntimeCredential_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_RuntimeManager_CreateDebugRuntimeCredential_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_CreateDebugRuntimeCredential_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_CreateDebugRuntimeCredential_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_RuntimeManager_DescribeRuntimeCredentials_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_DescribeRuntimeCredentials_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_DescribeRuntimeCredentials_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_RuntimeManager_DescribeDebugRuntimeCredentials_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_DescribeDebugRuntimeCredentials_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_DescribeDebugRuntimeCredentials_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("PATCH", pattern_RuntimeManager_ModifyRuntimeCredential_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_ModifyRuntimeCredential_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_ModifyRuntimeCredential_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("DELETE", pattern_RuntimeManager_DeleteRuntimeCredentials_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_DeleteRuntimeCredentials_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_DeleteRuntimeCredentials_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_RuntimeManager_ValidateRuntimeCredential_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_ValidateRuntimeCredential_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_ValidateRuntimeCredential_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_RuntimeManager_DescribeRuntimeProviderZones_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_DescribeRuntimeProviderZones_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_DescribeRuntimeProviderZones_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("GET", pattern_RuntimeManager_GetRuntimeStatistics_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_RuntimeManager_GetRuntimeStatistics_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_RuntimeManager_GetRuntimeStatistics_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + // RegisterRuntimeManagerHandlerFromEndpoint is same as RegisterRuntimeManagerHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterRuntimeManagerHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { @@ -280,15 +869,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_RuntimeManager_CreateRuntime_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -309,15 +889,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_RuntimeManager_CreateDebugRuntime_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -338,15 +909,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_RuntimeManager_DescribeRuntimes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -367,15 +929,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_RuntimeManager_DescribeDebugRuntimes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -396,15 +949,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("PATCH", pattern_RuntimeManager_ModifyRuntime_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -425,15 +969,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("DELETE", pattern_RuntimeManager_DeleteRuntimes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -454,15 +989,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_RuntimeManager_CreateRuntimeCredential_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -483,15 +1009,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_RuntimeManager_CreateDebugRuntimeCredential_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -512,15 +1029,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_RuntimeManager_DescribeRuntimeCredentials_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -541,15 +1049,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_RuntimeManager_DescribeDebugRuntimeCredentials_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -570,15 +1069,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("PATCH", pattern_RuntimeManager_ModifyRuntimeCredential_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -599,15 +1089,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("DELETE", pattern_RuntimeManager_DeleteRuntimeCredentials_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -628,15 +1109,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("POST", pattern_RuntimeManager_ValidateRuntimeCredential_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -657,15 +1129,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_RuntimeManager_DescribeRuntimeProviderZones_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -686,15 +1149,6 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve mux.Handle("GET", pattern_RuntimeManager_GetRuntimeStatistics_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -716,35 +1170,35 @@ func RegisterRuntimeManagerHandlerClient(ctx context.Context, mux *runtime.Serve } var ( - pattern_RuntimeManager_CreateRuntime_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "runtimes"}, "")) + pattern_RuntimeManager_CreateRuntime_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "runtimes"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_CreateDebugRuntime_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "debug_runtimes"}, "")) + pattern_RuntimeManager_CreateDebugRuntime_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "debug_runtimes"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_DescribeRuntimes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "runtimes"}, "")) + pattern_RuntimeManager_DescribeRuntimes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "runtimes"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_DescribeDebugRuntimes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "debug_runtimes"}, "")) + pattern_RuntimeManager_DescribeDebugRuntimes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "debug_runtimes"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_ModifyRuntime_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "runtimes"}, "")) + pattern_RuntimeManager_ModifyRuntime_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "runtimes"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_DeleteRuntimes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "runtimes"}, "")) + pattern_RuntimeManager_DeleteRuntimes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "runtimes"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_CreateRuntimeCredential_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "credentials"}, "")) + pattern_RuntimeManager_CreateRuntimeCredential_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "credentials"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_CreateDebugRuntimeCredential_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "debug_runtimes", "credentials"}, "")) + pattern_RuntimeManager_CreateDebugRuntimeCredential_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "debug_runtimes", "credentials"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_DescribeRuntimeCredentials_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "credentials"}, "")) + pattern_RuntimeManager_DescribeRuntimeCredentials_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "credentials"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_DescribeDebugRuntimeCredentials_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "debug_runtimes", "credentials"}, "")) + pattern_RuntimeManager_DescribeDebugRuntimeCredentials_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "debug_runtimes", "credentials"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_ModifyRuntimeCredential_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "credentials"}, "")) + pattern_RuntimeManager_ModifyRuntimeCredential_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "credentials"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_DeleteRuntimeCredentials_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "credentials"}, "")) + pattern_RuntimeManager_DeleteRuntimeCredentials_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "credentials"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_ValidateRuntimeCredential_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "credentials"}, "validate")) + pattern_RuntimeManager_ValidateRuntimeCredential_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "credentials"}, "validate", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_DescribeRuntimeProviderZones_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "zones"}, "")) + pattern_RuntimeManager_DescribeRuntimeProviderZones_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "zones"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_RuntimeManager_GetRuntimeStatistics_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "statistics"}, "")) + pattern_RuntimeManager_GetRuntimeStatistics_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "runtimes", "statistics"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/runtime_provider.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/runtime_provider.pb.go index 4de82b98c609ec678009ef50a041b5e99914943c..c3e0a7879d864a11ffeade2c147d151d2a5277d2 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/runtime_provider.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/runtime_provider.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -11,9 +12,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +27,7 @@ var _ = math.Inf // 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 RegisterRuntimeProviderRequest struct { // required, runtime provider.eg:[qingcloud|aliyun|aws|kubernetes] @@ -1363,6 +1365,44 @@ type RuntimeProviderManagerServer interface { DescribeZones(context.Context, *DescribeZonesRequest) (*DescribeZonesResponse, error) } +// UnimplementedRuntimeProviderManagerServer can be embedded to have forward compatible implementations. +type UnimplementedRuntimeProviderManagerServer struct { +} + +func (*UnimplementedRuntimeProviderManagerServer) RegisterRuntimeProvider(ctx context.Context, req *RegisterRuntimeProviderRequest) (*RegisterRuntimeProviderResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RegisterRuntimeProvider not implemented") +} +func (*UnimplementedRuntimeProviderManagerServer) ParseClusterConf(ctx context.Context, req *ParseClusterConfRequest) (*ParseClusterConfResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ParseClusterConf not implemented") +} +func (*UnimplementedRuntimeProviderManagerServer) SplitJobIntoTasks(ctx context.Context, req *SplitJobIntoTasksRequest) (*SplitJobIntoTasksResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SplitJobIntoTasks not implemented") +} +func (*UnimplementedRuntimeProviderManagerServer) HandleSubtask(ctx context.Context, req *HandleSubtaskRequest) (*HandleSubtaskResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method HandleSubtask not implemented") +} +func (*UnimplementedRuntimeProviderManagerServer) WaitSubtask(ctx context.Context, req *WaitSubtaskRequest) (*WaitSubtaskResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method WaitSubtask not implemented") +} +func (*UnimplementedRuntimeProviderManagerServer) DescribeSubnets(ctx context.Context, req *DescribeSubnetsRequest) (*DescribeSubnetsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeSubnets not implemented") +} +func (*UnimplementedRuntimeProviderManagerServer) CheckResource(ctx context.Context, req *CheckResourceRequest) (*CheckResourceResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CheckResource not implemented") +} +func (*UnimplementedRuntimeProviderManagerServer) DescribeVpc(ctx context.Context, req *DescribeVpcRequest) (*DescribeVpcResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeVpc not implemented") +} +func (*UnimplementedRuntimeProviderManagerServer) DescribeClusterDetails(ctx context.Context, req *DescribeClusterDetailsRequest) (*DescribeClusterDetailsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeClusterDetails not implemented") +} +func (*UnimplementedRuntimeProviderManagerServer) ValidateRuntime(ctx context.Context, req *ValidateRuntimeRequest) (*ValidateRuntimeResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ValidateRuntime not implemented") +} +func (*UnimplementedRuntimeProviderManagerServer) DescribeZones(ctx context.Context, req *DescribeZonesRequest) (*DescribeZonesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeZones not implemented") +} + func RegisterRuntimeProviderManagerServer(s *grpc.Server, srv RuntimeProviderManagerServer) { s.RegisterService(&_RuntimeProviderManager_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/service_config.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/service_config.pb.go index c456297103326af73682671b15bbfef1b6066255..f6ab35b73cde9a91b882cfdb3cb77de7123359f5 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/service_config.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/service_config.pb.go @@ -4,16 +4,17 @@ package pb import ( + context "context" fmt "fmt" math "math" proto "github.com/golang/protobuf/proto" - _ "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +26,7 @@ var _ = math.Inf // 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 EmailServiceConfig struct { // protocol @@ -592,55 +593,54 @@ func init() { func init() { proto.RegisterFile("service_config.proto", fileDescriptor_452b382cbc0cfd24) } var fileDescriptor_452b382cbc0cfd24 = []byte{ - // 767 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x55, 0xdd, 0x4e, 0xdb, 0x48, - 0x14, 0x96, 0x43, 0x80, 0xe5, 0x84, 0xa0, 0xdd, 0x59, 0xb4, 0xf1, 0x66, 0xb3, 0x6c, 0xd6, 0xbb, - 0x52, 0x11, 0x2a, 0x31, 0x0d, 0x37, 0x2d, 0x45, 0xa2, 0x80, 0x50, 0xca, 0x45, 0x01, 0x25, 0x85, - 0x8b, 0xde, 0x58, 0x13, 0x67, 0xe2, 0x8e, 0xe4, 0x78, 0xdc, 0x99, 0x09, 0x34, 0xb7, 0x7d, 0x81, - 0xaa, 0xf4, 0xbe, 0x2f, 0xd0, 0x47, 0xe8, 0x63, 0xf4, 0x15, 0x7a, 0xd1, 0xbe, 0x45, 0x95, 0x99, - 0x31, 0x24, 0xe4, 0x07, 0xab, 0xed, 0x55, 0xaf, 0xa2, 0xb1, 0xbf, 0xef, 0x9c, 0xef, 0x7c, 0xe7, - 0x9b, 0x18, 0x96, 0x05, 0xe1, 0xe7, 0xd4, 0x27, 0x9e, 0xcf, 0xa2, 0x36, 0x0d, 0x2a, 0x31, 0x67, - 0x92, 0x21, 0x60, 0x31, 0x89, 0x62, 0x2a, 0x39, 0x7d, 0x59, 0x2c, 0x05, 0x8c, 0x05, 0x21, 0x71, - 0x71, 0x4c, 0x5d, 0x1c, 0x45, 0x4c, 0x62, 0x49, 0x59, 0x24, 0x34, 0xb2, 0xb8, 0x62, 0xde, 0xaa, - 0x53, 0xb3, 0xdb, 0x76, 0x2f, 0x38, 0x8e, 0x63, 0xc2, 0x93, 0xf7, 0x77, 0xd5, 0x8f, 0xbf, 0x1e, - 0x90, 0x68, 0x5d, 0x5c, 0xe0, 0x20, 0x20, 0xdc, 0x65, 0xb1, 0xaa, 0x30, 0xa6, 0xda, 0x3f, 0x37, - 0xab, 0x49, 0xda, 0x21, 0x42, 0xe2, 0x4e, 0xac, 0x01, 0xce, 0xfb, 0x19, 0x40, 0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0x85, 0x74, 0xcb, 0x5a, 0xdb, 0xcb, 0x3e, 0xcb, 0xc4, 0xcd, 0xe6, 0x9c, 0xca, 0xcc, - 0xe6, 0xd7, 0x00, 0x00, 0x00, 0xff, 0xff, 0x7b, 0xae, 0xf0, 0x4d, 0x6f, 0x09, 0x00, 0x00, + // 750 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x55, 0xd1, 0x4e, 0x13, 0x41, + 0x14, 0xcd, 0x96, 0x02, 0x72, 0x4b, 0x89, 0x8e, 0xc4, 0xae, 0xb5, 0x92, 0xba, 0x9a, 0x48, 0x88, + 0x74, 0xb1, 0xbc, 0x28, 0x92, 0x20, 0x10, 0x52, 0x79, 0x10, 0x48, 0x2b, 0x3c, 0xf8, 0xb2, 0xd9, + 0x6e, 0xa7, 0xeb, 0x24, 0xdb, 0x9d, 0x75, 0x66, 0x0a, 0xf6, 0xd5, 0x1f, 0x30, 0xe2, 0xbb, 0x3f, + 0xe0, 0x27, 0xf8, 0x19, 0xfe, 0x82, 0x0f, 0xfa, 0x17, 0xa6, 0x33, 0xb3, 0xd0, 0xba, 0x6d, 0xd9, + 0xa8, 0x4f, 0x3e, 0x35, 0xb3, 0x7b, 0xce, 0xbd, 0xe7, 0x9e, 0x7b, 0xa6, 0x0b, 0x8b, 0x1c, 0xb3, + 0x53, 0xe2, 0x61, 0xc7, 0xa3, 0x61, 0x9b, 0xf8, 0x95, 0x88, 0x51, 0x41, 0x11, 0xd0, 0x08, 0x87, + 0x11, 0x11, 0x8c, 0xbc, 0x2b, 0x96, 0x7c, 0x4a, 0xfd, 0x00, 0xdb, 0x6e, 0x44, 0x6c, 0x37, 0x0c, + 0xa9, 0x70, 0x05, 0xa1, 0x21, 0x57, 0xc8, 0xe2, 0x92, 0x7e, 0x2b, 0x4f, 0xcd, 0x6e, 0xdb, 0x3e, + 0x63, 0x6e, 0x14, 0x61, 0x16, 0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 0x1a, 0xa8, 0xc5, 0x1e, 0x9d, 0x6f, 0x9b, 0xe8, + 0x56, 0x0c, 0x29, 0xcb, 0xd8, 0xc4, 0xba, 0xa5, 0x54, 0xdb, 0x5a, 0x19, 0x25, 0xf5, 0x54, 0x33, + 0x9c, 0xa1, 0x90, 0x6e, 0x18, 0x2b, 0x3b, 0xd9, 0xd7, 0x99, 0xa8, 0xd9, 0x9c, 0x91, 0x99, 0x59, + 0xff, 0x15, 0x00, 0x00, 0xff, 0xff, 0x92, 0x91, 0xe8, 0x28, 0x4e, 0x09, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -708,6 +708,20 @@ type ServiceConfigServer interface { ValidateEmailService(context.Context, *ValidateEmailServiceRequest) (*ValidateEmailServiceResponse, error) } +// UnimplementedServiceConfigServer can be embedded to have forward compatible implementations. +type UnimplementedServiceConfigServer struct { +} + +func (*UnimplementedServiceConfigServer) SetServiceConfig(ctx context.Context, req *SetServiceConfigRequest) (*SetServiceConfigResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SetServiceConfig not implemented") +} +func (*UnimplementedServiceConfigServer) GetServiceConfig(ctx context.Context, req *GetServiceConfigRequest) (*GetServiceConfigResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetServiceConfig not implemented") +} +func (*UnimplementedServiceConfigServer) ValidateEmailService(ctx context.Context, req *ValidateEmailServiceRequest) (*ValidateEmailServiceResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ValidateEmailService not implemented") +} + func RegisterServiceConfigServer(s *grpc.Server, srv ServiceConfigServer) { s.RegisterService(&_ServiceConfig_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/service_config.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/service_config.pb.gw.go index 13c9b5f3fa4a11e118bbeedc832024a417635f65..0c72cbfa0ac77649655822dc87016f5846dea2b9 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/service_config.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/service_config.pb.gw.go @@ -9,30 +9,37 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage func request_ServiceConfig_SetServiceConfig_0(ctx context.Context, marshaler runtime.Marshaler, client ServiceConfigClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq SetServiceConfigRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -41,11 +48,32 @@ func request_ServiceConfig_SetServiceConfig_0(ctx context.Context, marshaler run } +func local_request_ServiceConfig_SetServiceConfig_0(ctx context.Context, marshaler runtime.Marshaler, server ServiceConfigServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq SetServiceConfigRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.SetServiceConfig(ctx, &protoReq) + return msg, metadata, err + +} + func request_ServiceConfig_GetServiceConfig_0(ctx context.Context, marshaler runtime.Marshaler, client ServiceConfigClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq GetServiceConfigRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -54,11 +82,32 @@ func request_ServiceConfig_GetServiceConfig_0(ctx context.Context, marshaler run } +func local_request_ServiceConfig_GetServiceConfig_0(ctx context.Context, marshaler runtime.Marshaler, server ServiceConfigServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq GetServiceConfigRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.GetServiceConfig(ctx, &protoReq) + return msg, metadata, err + +} + func request_ServiceConfig_ValidateEmailService_0(ctx context.Context, marshaler runtime.Marshaler, client ServiceConfigClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq ValidateEmailServiceRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -67,6 +116,91 @@ func request_ServiceConfig_ValidateEmailService_0(ctx context.Context, marshaler } +func local_request_ServiceConfig_ValidateEmailService_0(ctx context.Context, marshaler runtime.Marshaler, server ServiceConfigServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq ValidateEmailServiceRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.ValidateEmailService(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterServiceConfigHandlerServer registers the http handlers for service ServiceConfig to "mux". +// UnaryRPC :call ServiceConfigServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterServiceConfigHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ServiceConfigServer) error { + + mux.Handle("POST", pattern_ServiceConfig_SetServiceConfig_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ServiceConfig_SetServiceConfig_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ServiceConfig_SetServiceConfig_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ServiceConfig_GetServiceConfig_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ServiceConfig_GetServiceConfig_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ServiceConfig_GetServiceConfig_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_ServiceConfig_ValidateEmailService_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_ServiceConfig_ValidateEmailService_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_ServiceConfig_ValidateEmailService_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + // RegisterServiceConfigHandlerFromEndpoint is same as RegisterServiceConfigHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterServiceConfigHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { @@ -108,15 +242,6 @@ func RegisterServiceConfigHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("POST", pattern_ServiceConfig_SetServiceConfig_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -137,15 +262,6 @@ func RegisterServiceConfigHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("POST", pattern_ServiceConfig_GetServiceConfig_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -166,15 +282,6 @@ func RegisterServiceConfigHandlerClient(ctx context.Context, mux *runtime.ServeM mux.Handle("POST", pattern_ServiceConfig_ValidateEmailService_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -196,11 +303,11 @@ func RegisterServiceConfigHandlerClient(ctx context.Context, mux *runtime.ServeM } var ( - pattern_ServiceConfig_SetServiceConfig_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "service_configs", "set"}, "")) + pattern_ServiceConfig_SetServiceConfig_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "service_configs", "set"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ServiceConfig_GetServiceConfig_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "service_configs", "get"}, "")) + pattern_ServiceConfig_GetServiceConfig_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "service_configs", "get"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_ServiceConfig_ValidateEmailService_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "service_configs", "validate_email_service"}, "")) + pattern_ServiceConfig_ValidateEmailService_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "service_configs", "validate_email_service"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/task.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/task.pb.go index 9c88eae9ae31feeba971945fb5593e58911621d6..dd4b9b6e870b1c17a37fc33bd3439373383ac7ac 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/task.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/task.pb.go @@ -4,6 +4,7 @@ package pb import ( + context "context" fmt "fmt" math "math" @@ -11,9 +12,10 @@ import ( timestamp "github.com/golang/protobuf/ptypes/timestamp" wrappers "github.com/golang/protobuf/ptypes/wrappers" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" - context "golang.org/x/net/context" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. @@ -25,7 +27,7 @@ var _ = math.Inf // 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 CreateTaskRequest struct { // id of job(jod will split to one more task) to split @@ -784,6 +786,20 @@ type TaskManagerServer interface { RetryTasks(context.Context, *RetryTasksRequest) (*RetryTasksResponse, error) } +// UnimplementedTaskManagerServer can be embedded to have forward compatible implementations. +type UnimplementedTaskManagerServer struct { +} + +func (*UnimplementedTaskManagerServer) CreateTask(ctx context.Context, req *CreateTaskRequest) (*CreateTaskResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateTask not implemented") +} +func (*UnimplementedTaskManagerServer) DescribeTasks(ctx context.Context, req *DescribeTasksRequest) (*DescribeTasksResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DescribeTasks not implemented") +} +func (*UnimplementedTaskManagerServer) RetryTasks(ctx context.Context, req *RetryTasksRequest) (*RetryTasksResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RetryTasks not implemented") +} + func RegisterTaskManagerServer(s *grpc.Server, srv TaskManagerServer) { s.RegisterService(&_TaskManager_serviceDesc, srv) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/task.pb.gw.go b/vendor/openpitrix.io/openpitrix/pkg/pb/task.pb.gw.go index 306a96560a17583dad70059eeef045a1cf18aaba..bd4816d46c92d59602c6cfda862744d2e659a21a 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/task.pb.gw.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/task.pb.gw.go @@ -9,24 +9,27 @@ It translates gRPC into RESTful JSON APIs. package pb import ( + "context" "io" "net/http" + "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" - "golang.org/x/net/context" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/status" ) +// Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray +var _ = descriptor.ForMessage var ( filter_TaskManager_DescribeTasks_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} @@ -36,7 +39,10 @@ func request_TaskManager_DescribeTasks_0(ctx context.Context, marshaler runtime. var protoReq DescribeTasksRequest var metadata runtime.ServerMetadata - if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_TaskManager_DescribeTasks_0); err != nil { + if err := req.ParseForm(); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_TaskManager_DescribeTasks_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -45,11 +51,28 @@ func request_TaskManager_DescribeTasks_0(ctx context.Context, marshaler runtime. } +func local_request_TaskManager_DescribeTasks_0(ctx context.Context, marshaler runtime.Marshaler, server TaskManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq DescribeTasksRequest + var metadata runtime.ServerMetadata + + if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_TaskManager_DescribeTasks_0); err != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.DescribeTasks(ctx, &protoReq) + return msg, metadata, err + +} + func request_TaskManager_RetryTasks_0(ctx context.Context, marshaler runtime.Marshaler, client TaskManagerClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq RetryTasksRequest var metadata runtime.ServerMetadata - if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && err != io.EOF { + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } @@ -58,6 +81,71 @@ func request_TaskManager_RetryTasks_0(ctx context.Context, marshaler runtime.Mar } +func local_request_TaskManager_RetryTasks_0(ctx context.Context, marshaler runtime.Marshaler, server TaskManagerServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq RetryTasksRequest + var metadata runtime.ServerMetadata + + newReader, berr := utilities.IOReaderFactory(req.Body) + if berr != nil { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr) + } + if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + + msg, err := server.RetryTasks(ctx, &protoReq) + return msg, metadata, err + +} + +// RegisterTaskManagerHandlerServer registers the http handlers for service TaskManager to "mux". +// UnaryRPC :call TaskManagerServer directly. +// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. +func RegisterTaskManagerHandlerServer(ctx context.Context, mux *runtime.ServeMux, server TaskManagerServer) error { + + mux.Handle("GET", pattern_TaskManager_DescribeTasks_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_TaskManager_DescribeTasks_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_TaskManager_DescribeTasks_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + mux.Handle("POST", pattern_TaskManager_RetryTasks_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_TaskManager_RetryTasks_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_TaskManager_RetryTasks_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + + return nil +} + // RegisterTaskManagerHandlerFromEndpoint is same as RegisterTaskManagerHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterTaskManagerHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { @@ -99,15 +187,6 @@ func RegisterTaskManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux mux.Handle("GET", pattern_TaskManager_DescribeTasks_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -128,15 +207,6 @@ func RegisterTaskManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux mux.Handle("POST", pattern_TaskManager_RetryTasks_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - if cn, ok := w.(http.CloseNotifier); ok { - go func(done <-chan struct{}, closed <-chan bool) { - select { - case <-done: - case <-closed: - cancel() - } - }(ctx.Done(), cn.CloseNotify()) - } inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { @@ -158,9 +228,9 @@ func RegisterTaskManagerHandlerClient(ctx context.Context, mux *runtime.ServeMux } var ( - pattern_TaskManager_DescribeTasks_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "tasks"}, "")) + pattern_TaskManager_DescribeTasks_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"v1", "tasks"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_TaskManager_RetryTasks_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "tasks", "retry"}, "")) + pattern_TaskManager_RetryTasks_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"v1", "tasks", "retry"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/vendor/openpitrix.io/openpitrix/pkg/pb/types.pb.go b/vendor/openpitrix.io/openpitrix/pkg/pb/types.pb.go index ee7b241d0e854f4f3a65a1ec4b2799764a3d85f1..57dc1ab48afdf656090f06b7a9d66131ecab21d4 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/pb/types.pb.go +++ b/vendor/openpitrix.io/openpitrix/pkg/pb/types.pb.go @@ -21,7 +21,7 @@ var _ = math.Inf // 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 ErrorDetail struct { ErrorName string `protobuf:"bytes,1,opt,name=error_name,json=errorName,proto3" json:"error_name,omitempty"` diff --git a/vendor/openpitrix.io/openpitrix/pkg/util/ctxutil/ctx.go b/vendor/openpitrix.io/openpitrix/pkg/util/ctxutil/ctx.go index 764f67b682e7ae4950a43b487ab442abeeb98247..2de9c1f1b6de707c386d5ca21c7393480917e2ea 100644 --- a/vendor/openpitrix.io/openpitrix/pkg/util/ctxutil/ctx.go +++ b/vendor/openpitrix.io/openpitrix/pkg/util/ctxutil/ctx.go @@ -13,6 +13,7 @@ import ( const ( messageIdKey = "x-message-id" requestIdKey = "x-request-id" + localeKey = "locale" ) type getMetadataFromContext func(ctx context.Context) (md metadata.MD, ok bool) @@ -48,5 +49,8 @@ func GetValueFromContext(ctx context.Context, key string) []string { } func Copy(src, dst context.Context) context.Context { - return SetMessageId(dst, GetMessageId(src)) + ContextWithSender(dst, GetSender(src)) + SetMessageId(dst, GetMessageId(src)) + SetRequestId(dst, GetRequestId(src)) + return SetLocale(dst, GetLocale(src)) } diff --git a/vendor/openpitrix.io/openpitrix/pkg/util/ctxutil/locale.go b/vendor/openpitrix.io/openpitrix/pkg/util/ctxutil/locale.go new file mode 100644 index 0000000000000000000000000000000000000000..19c2be6219b03269becb8b438744d7dcb5ca1b2d --- /dev/null +++ b/vendor/openpitrix.io/openpitrix/pkg/util/ctxutil/locale.go @@ -0,0 +1,25 @@ +package ctxutil + +import ( + "context" + + "google.golang.org/grpc/metadata" +) + +func GetLocale(ctx context.Context) string { + locale := GetValueFromContext(ctx, localeKey) + if len(locale) == 0 { + return "" + } + return locale[0] +} + +func SetLocale(ctx context.Context, locale string) context.Context { + ctx = context.WithValue(ctx, localeKey, []string{locale}) + md, ok := metadata.FromOutgoingContext(ctx) + if !ok { + md = metadata.MD{} + } + md[localeKey] = []string{locale} + return metadata.NewOutgoingContext(ctx, md) +} diff --git a/vendor/openpitrix.io/openpitrix/pkg/version/gen_helper.go b/vendor/openpitrix.io/openpitrix/pkg/version/gen_helper.go deleted file mode 100644 index 01af5342fda7659fe08f75bce00d4442883b5b83..0000000000000000000000000000000000000000 --- a/vendor/openpitrix.io/openpitrix/pkg/version/gen_helper.go +++ /dev/null @@ -1,74 +0,0 @@ -// Copyright 2018 The OpenPitrix Authors. All rights reserved. -// Use of this source code is governed by a Apache license -// that can be found in the LICENSE file. - -// +build ignore - -package main - -import ( - "fmt" - "io/ioutil" - "log" - "os/exec" - "strings" - "time" -) - -func main() { - version, gitSha1Version := getAppVersion() - buildTime := time.Now().Format("2006-01-02 15:04:05") - - data := make_update_version_go_file(version, gitSha1Version, buildTime) - - err := ioutil.WriteFile("./z_update_version.go", []byte(data), 0666) - if err != nil { - log.Fatalf("ioutil.WriteFile: err = %v", err) - } - - fmt.Printf("%s (%s)\n", version, gitSha1Version) - fmt.Println(buildTime) -} - -func make_update_version_go_file(version, gitSha1Version, buildTime string) string { - return fmt.Sprintf(`// Copyright 2018 The OpenPitrix Authors. All rights reserved. -// Use of this source code is governed by a Apache license -// that can be found in the LICENSE file. - -// Auto generated by 'go run gen_helper.go', DO NOT EDIT. - -package version - -func init() { - ShortVersion = "%s" - GitSha1Version = "%s" - BuildDate = "%s" -} -`, - version, - gitSha1Version, - buildTime, - ) -} - -func getAppVersion() (version, gitSha1Version string) { - // VERSION=`git describe --tags --always --dirty="-dev"` - versionData, err := exec.Command( - `git`, `describe`, `--tags`, `--always`, `--dirty=-dev`, - ).CombinedOutput() - if err != nil { - log.Fatal(err) - } - - // GIT_SHA1=`git show --quiet --pretty=format:%H` - gitSha1VersionData, err := exec.Command( - `git`, `show`, `--quiet`, `--pretty=format:%H`, - ).CombinedOutput() - if err != nil { - log.Fatal(err) - } - - version = strings.TrimSpace(string(versionData)) - gitSha1Version = strings.TrimSpace(string(gitSha1VersionData)) - return -}