diff --git a/pkg/imported-controller/.github/ISSUE_TEMPLATE/bug_report.md b/pkg/imported-controller/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index 3bbfb6c0..00000000 --- a/pkg/imported-controller/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,31 +0,0 @@ ---- -name: Bug Report -about: Use this template for reporting bugs or issues. -title: "[DATE] - Title" ---- -# Bug Report - - - -**What happened**: - -**What you expected to happen**: - -**How to reproduce this bug (as minimally and precisely as possible)**: - -**Anything else relevant for this bug report?**: - -**Environment**: - -- Kubernetes version (use `kubectl version`), please list client and server: -- Controller version (provide the release tag or commit hash): -- Provisoner name and version (provide the release tag or commit hash): -- Cloud provider or hardware configuration: -- OS (e.g: `cat /etc/os-release`): -- Kernel (e.g. `uname -a`): -- Install tools: -- Network plugin and version (if this is a network-related bug): -- Others: diff --git a/pkg/imported-controller/.github/ISSUE_TEMPLATE/enhancement.md b/pkg/imported-controller/.github/ISSUE_TEMPLATE/enhancement.md deleted file mode 100644 index 7ed31b19..00000000 --- a/pkg/imported-controller/.github/ISSUE_TEMPLATE/enhancement.md +++ /dev/null @@ -1,19 +0,0 @@ ---- -name: Enhancement/Feature Request -about: Use this template to request a new feature or enhancement for the COSI controller -title: "[DATE] - Title" -labels: bug ---- -# Enhancement - -**Is your feature request related to a problem?/Why is this needed** - - -**Describe the solution you'd like in detail** - - -**Describe alternatives you've considered** - - -**Additional context** - diff --git a/pkg/imported-controller/.github/SECURITY.md b/pkg/imported-controller/.github/SECURITY.md deleted file mode 100644 index 3bafc83a..00000000 --- a/pkg/imported-controller/.github/SECURITY.md +++ /dev/null @@ -1,14 +0,0 @@ -# Security Policy - -## Supported Versions - -Information about supported Kubernetes versions can be found on the -[Kubernetes version and version skew support policy] page on the Kubernetes website. - -## Reporting a Vulnerability - -Instructions for reporting a vulnerability can be found on the -[Kubernetes Security and Disclosure Information] page. - -[Kubernetes version and version skew support policy]: https://kubernetes.io/docs/setup/release/version-skew-policy/#supported-versions -[Kubernetes Security and Disclosure Information]: https://kubernetes.io/docs/reference/issues-security/security/#report-a-vulnerability diff --git a/pkg/imported-controller/.github/dependabot.yml b/pkg/imported-controller/.github/dependabot.yml deleted file mode 100644 index eb774b36..00000000 --- a/pkg/imported-controller/.github/dependabot.yml +++ /dev/null @@ -1,27 +0,0 @@ -version: 2 -enable-beta-ecosystems: true -updates: - - - package-ecosystem: "gomod" - directory: "/" - schedule: - interval: "weekly" - groups: # batch updates together for fewer dependabot PRs - golang-dependencies: - patterns: - - "github.com/golang*" - k8s-dependencies: - patterns: - - "k8s.io*" - - "sigs.k8s.io*" - exclude-patterns: - # controller-runtime has history of breaking API changes more often than other k8s projects - - "sigs.k8s.io/controller-runtime" - github-dependencies: - patterns: - - "github.com*" - - - package-ecosystem: "docker" - directory: "/" - schedule: - interval: "weekly" diff --git a/pkg/imported-controller/.gitignore b/pkg/imported-controller/.gitignore deleted file mode 100644 index faa1c3ef..00000000 --- a/pkg/imported-controller/.gitignore +++ /dev/null @@ -1,9 +0,0 @@ -*.tmp -.DS_Store -.build -*.swp -travis.yml -release-tools -bin -vendor/ -.idea/ \ No newline at end of file diff --git a/pkg/imported-controller/CHANGELOG/CHANGELOG-0.1.md b/pkg/imported-controller/CHANGELOG/CHANGELOG-0.1.md deleted file mode 100644 index 60d975be..00000000 --- a/pkg/imported-controller/CHANGELOG/CHANGELOG-0.1.md +++ /dev/null @@ -1,7 +0,0 @@ -# First Release v0.1.0 - - ### New Features - - - Listen on Bucket* events - - Create Buckets in response to BucketClaim creation - - Enable lifecycle of Buckets and BucketAccesses diff --git a/pkg/imported-controller/CONTRIBUTING.md b/pkg/imported-controller/CONTRIBUTING.md deleted file mode 100644 index 22b0ac08..00000000 --- a/pkg/imported-controller/CONTRIBUTING.md +++ /dev/null @@ -1,26 +0,0 @@ -# Contributing Guidelines - -Welcome to Kubernetes. We are excited about the prospect of you joining our [community](https://git.k8s.io/community)! The Kubernetes community abides by the CNCF [code of conduct](code-of-conduct.md). Here is an excerpt: - -_As contributors and maintainers of this project, and in the interest of fostering an open and welcoming community, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities._ - -## Getting Started - -We have full documentation on how to get started contributing here: - - - -- [Contributor License Agreement](https://git.k8s.io/community/CLA.md) Kubernetes projects require that you sign a Contributor License Agreement (CLA) before we can accept your pull requests -- [Kubernetes Contributor Guide](https://git.k8s.io/community/contributors/guide) - Main contributor documentation, or you can just jump directly to the [contributing section](https://git.k8s.io/community/contributors/guide#contributing) -- [Contributor Cheat Sheet](https://git.k8s.io/community/contributors/guide/contributor-cheatsheet) - Common resources for existing developers - -## Mentorship - -- [Mentoring Initiatives](https://git.k8s.io/community/mentoring) - We have a diverse set of mentorship programs available that are always looking for volunteers! - -## Contact Information - -- [Slack](https://kubernetes.slack.com/messages/sig-storage-cosi) -- [Mailing List](https://groups.google.com/forum/#!forum/kubernetes-sig-storage) diff --git a/pkg/imported-controller/Dockerfile b/pkg/imported-controller/Dockerfile deleted file mode 100644 index fc164382..00000000 --- a/pkg/imported-controller/Dockerfile +++ /dev/null @@ -1,36 +0,0 @@ -# -# BUILDER -# -FROM docker.io/library/golang:1.22.2 AS builder - -WORKDIR /buildroot - -# Cache deps before building and copying source, so that we don't need to re-download -# as much and so that source changes don't invalidate our downloaded layer. -COPY go.mod go.mod -COPY go.sum go.sum -RUN go mod download - -COPY cmd/ cmd/ -COPY pkg/ pkg/ - -ENV CGO_ENABLED=0 - -RUN go build -o artifacts/controller-manager cmd/controller-manager/*.go - - -# -# FINAL IMAGE -# -FROM gcr.io/distroless/static:latest - -LABEL maintainers="Kubernetes Authors" -LABEL description="COSI Controller" - -LABEL org.opencontainers.image.title="COSI Controller" -LABEL org.opencontainers.image.description="Container Object Storage Interface (COSI) Controller" -LABEL org.opencontainers.image.source="https://github.com/kubernetes-sigs/container-object-storage-interface-controller" -LABEL org.opencontainers.image.licenses="APACHE-2.0" - -COPY --from=builder /buildroot/artifacts/controller-manager . -ENTRYPOINT ["/controller-manager"] diff --git a/pkg/imported-controller/LICENSE b/pkg/imported-controller/LICENSE deleted file mode 100644 index 8dada3ed..00000000 --- a/pkg/imported-controller/LICENSE +++ /dev/null @@ -1,201 +0,0 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "{}" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright {yyyy} {name of copyright owner} - - 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. diff --git a/pkg/imported-controller/Makefile b/pkg/imported-controller/Makefile deleted file mode 100644 index 91df56a1..00000000 --- a/pkg/imported-controller/Makefile +++ /dev/null @@ -1,37 +0,0 @@ -.DEFAULT_GOAL := help -SHELL = /usr/bin/env bash - -# 'go env' vars aren't always available in make environments, so get defaults for needed ones -GOARCH ?= $(shell go env GOARCH) - -## -## ==== ARGS ===== # - -## Container build tool compatible with `docker` API -DOCKER ?= docker - -## Platform for 'build' -PLATFORM ?= linux/$(GOARCH) - -## Image tag for all builds -IMAGE_TAG ?= cosi-controller:latest - -## -## === TARGETS === # - -.PHONY: build -## Build local image for development, defaulting linux/ -build: - $(DOCKER) build --platform $(PLATFORM) --tag $(IMAGE_TAG) . - -.PHONY: test -## Test packages -test: - go vet ./... - go test ./... - -# print out lines beginning with double-comments, plus next line as basic help text -.PHONY: help -## Show this help text -help: - @sed -n -e "/^##/{N;s/^/\n/p;}" $(MAKEFILE_LIST) diff --git a/pkg/imported-controller/OWNERS b/pkg/imported-controller/OWNERS deleted file mode 100644 index e1434ba0..00000000 --- a/pkg/imported-controller/OWNERS +++ /dev/null @@ -1,11 +0,0 @@ -# See the OWNERS docs at https://go.k8s.io/owners - -approvers: - - jsafrane - - msau42 - - saad-ali - - xing-yang - - wlan0 - - mukhoakash - - BlaineEXE - - shanduur diff --git a/pkg/imported-controller/README.md b/pkg/imported-controller/README.md deleted file mode 100644 index 436ae7a7..00000000 --- a/pkg/imported-controller/README.md +++ /dev/null @@ -1,51 +0,0 @@ -# Container Object Storage Controller - -Container Object Storage Interface (COSI) controller is responsible to manage lifecycle of COSI objects. -Specifically, this controller monitors the lifecycle of the user-facing CRDs: - -- BucketRequest - Represents a request to provision a Bucket -- BucketAccessRequest - Represents a request to access a Bucket - -and generates the associated CRDs: - -- Bucket - Represents a Bucket or its equivalent in the storage backend -- BucketAccess - Represents a access token or service account in the storage backend - -## Developer Guide - -Before diving into the code of this repo, we suggest that you familiarize yourself with: - -- The Spec of CRDs in [objectstorage.k8s.io/v1alpha1/types.go](https://github.com/kubernetes-sigs/container-object-storage-interface-api/blob/master/apis/objectstorage/v1alpha1/types.go) -- The Spec of the COSI objects [sigs.k8s.io/container-object-storage-interface-spec](https://github.com/kubernetes-sigs/container-object-storage-interface-spec) - -A good starting point towards understanding the functionality of this repo would be to study the tests: - -- [BucketClaim Test](./pkg/bucketclaim/bucketclaim_test.go) - -### Build and Test - -In order to build and generate a Docker image execute: -```bash -make container -``` - -In order to run the tests execute: -```bash -make test -``` - -## References - - - [Documentation](https://container-object-storage-interface.github.io/) - - [Deployment Guide](https://container-object-storage-interface.github.io/docs/deployment-guide) - - [Weekly Meetings](https://container-object-storage-interface.github.io/docs/community/weekly-meetings) - - [Roadmap](https://github.com/orgs/kubernetes-sigs/projects/8) -## Community, discussion, contribution, and support - -You can reach the maintainers of this project at: - - - [#sig-storage-cosi](https://kubernetes.slack.com/messages/sig-storage-cosi) slack channel - - [container-object-storage-interface](https://groups.google.com/g/container-object-storage-interface-wg?pli=1) mailing list -### Code of conduct - -Participation in the Kubernetes community is governed by the [Kubernetes Code of Conduct](code-of-conduct.md). diff --git a/pkg/imported-controller/RELEASE.md b/pkg/imported-controller/RELEASE.md deleted file mode 100644 index 7274b344..00000000 --- a/pkg/imported-controller/RELEASE.md +++ /dev/null @@ -1,9 +0,0 @@ -# Release Process - -The Kubernetes Template Project is released on an as-needed basis. The process is as follows: - -1. An issue is proposing a new release with a changelog since the last release -1. All [OWNERS](OWNERS) must LGTM this release -1. An OWNER runs `git tag -s $VERSION` and inserts the changelog and pushes the tag with `git push $VERSION` -1. The release issue is closed -1. An announcement email is sent to `kubernetes-dev@googlegroups.com` with the subject `[ANNOUNCE] kubernetes-template-project $VERSION is released` diff --git a/pkg/imported-controller/SECURITY_CONTACTS b/pkg/imported-controller/SECURITY_CONTACTS deleted file mode 100644 index 8a7b91d5..00000000 --- a/pkg/imported-controller/SECURITY_CONTACTS +++ /dev/null @@ -1,16 +0,0 @@ -# Defined below are the security contacts for this repo. -# -# They are the contact point for the Product Security Committee to reach out -# to for triaging and handling of incoming issues. -# -# The below names agree to abide by the -# [Embargo Policy](https://git.k8s.io/security/private-distributors-list.md#embargo-policy) -# and will be removed and replaced if they violate that agreement. -# -# DO NOT REPORT SECURITY VULNERABILITIES DIRECTLY TO THESE NAMES, FOLLOW THE -# INSTRUCTIONS AT https://kubernetes.io/security/ - -jsafrane -msau42 -saad-ali -xing-yang diff --git a/pkg/imported-controller/cloudbuild.yaml b/pkg/imported-controller/cloudbuild.yaml deleted file mode 100644 index bd1d6886..00000000 --- a/pkg/imported-controller/cloudbuild.yaml +++ /dev/null @@ -1,39 +0,0 @@ -# K8s infra build example: https://github.com/kubernetes/test-infra/blob/master/config/jobs/image-pushing/README.md -# GCloud build docs: https://cloud.google.com/cloud-build/docs/build-config -# Builds go to https://console.cloud.google.com/gcr/images/k8s-staging-sig-storage/GLOBAL -# Build logs in https://testgrid.k8s.io/sig-storage-image-build -timeout: 3000s -options: - substitution_option: 'ALLOW_LOOSE' - machineType: 'E2_HIGHCPU_8' -substitutions: - # K8s provides custom substitutions _GIT_TAG and _PULL_BASE_REF: - # https://github.com/kubernetes/test-infra/blob/master/config/jobs/image-pushing/README.md#custom-substitutions - _GIT_TAG: '12345' # e.g., vYYYYMMDD-hash, vYYYYMMDD-tag, or vYYYYMMDD-tag-n-ghash - _PULL_BASE_REF: 'master' # e.g., master or release-0.2 for a PR merge, or v0.2 for a tag - # COSI substitutions: - _IMAGE: objectstorage-controller - _PLATFORMS: linux/amd64,linux/arm64 # add more platforms here if desired -steps: - # based on k8s infra build example and modified to use docker buildx - # buildx refs: https://github.com/docker/buildx/blob/master/docs/reference/buildx.md - - id: set-up-multi-arch-builder-as-default - name: gcr.io/cloud-builders/docker - args: ["buildx", "create", "--use", "--name", "multi-arch", "--platform=${_PLATFORMS}"] - - id: bootstrap-multi-arch-builder - name: gcr.io/cloud-builders/docker - args: ["buildx", "inspect", "--bootstrap"] - - id: do-multi-arch-build - name: gcr.io/cloud-builders/docker - args: - - buildx - - build - - --push # --load doesn't work with multi-platform builds, so just push from docker build - - --platform=${_PLATFORMS} - - --tag=gcr.io/k8s-staging-sig-storage/${_IMAGE}:${_GIT_TAG} - # using _PULL_BASE_REF as a tag will often just build and overwrite the same 'master' tag, - # BUT! if the commit has a git tag, it will build that tag instead. this mechanism allows - # creating the semver-tagged images that will be auto-promoted to release - - --tag=gcr.io/k8s-staging-sig-storage/${_IMAGE}:${_PULL_BASE_REF} - - --tag=gcr.io/k8s-staging-sig-storage/${_IMAGE}:latest - - . diff --git a/pkg/imported-controller/cmd/controller-manager/controller-manager.go b/pkg/imported-controller/cmd/controller-manager/controller-manager.go deleted file mode 100644 index a963ba1a..00000000 --- a/pkg/imported-controller/cmd/controller-manager/controller-manager.go +++ /dev/null @@ -1,71 +0,0 @@ -package main - -import ( - "context" - "flag" - "os" - "os/signal" - "syscall" - - "github.com/spf13/cobra" - "github.com/spf13/viper" - - bucketcontroller "sigs.k8s.io/container-object-storage-interface-api/controller" - "sigs.k8s.io/container-object-storage-interface-controller/pkg/bucketclaim" - - "k8s.io/klog/v2" -) - -var cmd = &cobra.Command{ - Use: "controller-manager", - Short: "central controller for managing bucket* and bucketAccess* API objects", - SilenceErrors: true, - SilenceUsage: true, - RunE: func(c *cobra.Command, args []string) error { - return run(c.Context(), args) - }, - DisableFlagsInUseLine: true, -} - -var kubeConfig string -var verbosity int - -func init() { - viper.AutomaticEnv() - - flag.Set("alsologtostderr", "true") - kflags := flag.NewFlagSet("klog", flag.ExitOnError) - klog.InitFlags(kflags) - - cmd.PersistentFlags().AddGoFlagSet(kflags) - cmd.PersistentFlags().StringVarP(&kubeConfig, "kubeconfig", "", kubeConfig, "path to kubeconfig file") - - //flag.CommandLine.Parse([]string{}) - viper.BindPFlags(cmd.PersistentFlags()) -} - -func main() { - ctx, cancel := context.WithCancel(context.Background()) - defer cancel() // Just in case - - sigs := make(chan os.Signal, 1) - signal.Notify(sigs, syscall.SIGINT, syscall.SIGTERM) - - go func() { - <-sigs - cancel() - }() - - if err := cmd.ExecuteContext(ctx); err != nil { - klog.Error(err) - } -} - -func run(ctx context.Context, args []string) error { - ctrl, err := bucketcontroller.NewDefaultObjectStorageController("cosi-controller-manager", "leader-lock", 40) - if err != nil { - return err - } - ctrl.AddBucketClaimListener(bucketclaim.NewBucketClaimListener()) - return ctrl.Run(ctx) -} diff --git a/pkg/imported-controller/code-of-conduct.md b/pkg/imported-controller/code-of-conduct.md deleted file mode 100644 index 0d15c00c..00000000 --- a/pkg/imported-controller/code-of-conduct.md +++ /dev/null @@ -1,3 +0,0 @@ -# Kubernetes Community Code of Conduct - -Please refer to our [Kubernetes Community Code of Conduct](https://git.k8s.io/community/code-of-conduct.md) diff --git a/pkg/imported-controller/docs/deployment-guide.md b/pkg/imported-controller/docs/deployment-guide.md deleted file mode 100644 index 32c3e575..00000000 --- a/pkg/imported-controller/docs/deployment-guide.md +++ /dev/null @@ -1,21 +0,0 @@ -# Deployment guide - -This document describes steps for Kubernetes administrators to setup Container Object Storage Interface Controller (COSI) Controller onto a Kubernetes cluster. - -COSI controller can be setup using the [kustomization file](https://github.com/kubernetes-sigs/container-object-storage-interface-controller/blob/master/kustomization.yaml) from the [container-object-storage-interface-controller](https://github.com/kubernetes-sigs/container-object-storage-interface-controller) repository with following command: - -```sh -kubectl create -k github.com/kubernetes-sigs/container-object-storage-interface-controller -``` -The output should look like the following: -```sh -serviceaccount/objectstorage-controller-sa created -role.rbac.authorization.k8s.io/objectstorage-controller created -clusterrole.rbac.authorization.k8s.io/objectstorage-controller-role created -rolebinding.rbac.authorization.k8s.io/objectstorage-controller created -clusterrolebinding.rbac.authorization.k8s.io/objectstorage-controller created -deployment.apps/objectstorage-controller created -``` - -The controller will be deployed in the `default` namespace. - diff --git a/pkg/imported-controller/go.mod b/pkg/imported-controller/go.mod deleted file mode 100644 index eb09bf16..00000000 --- a/pkg/imported-controller/go.mod +++ /dev/null @@ -1,72 +0,0 @@ -module sigs.k8s.io/container-object-storage-interface-controller - -go 1.18 - -require ( - github.com/spf13/cobra v1.8.0 - github.com/spf13/viper v1.18.2 - k8s.io/api v0.24.2 - k8s.io/apimachinery v0.24.2 - k8s.io/client-go v0.24.2 - k8s.io/klog/v2 v2.70.1 - sigs.k8s.io/container-object-storage-interface-api v0.1.1-0.20240208184109-05444273ee49 - sigs.k8s.io/controller-runtime v0.12.3 -) - -require ( - github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect - github.com/emicklei/go-restful/v3 v3.8.0 // indirect - github.com/evanphx/json-patch v4.12.0+incompatible // indirect - github.com/fsnotify/fsnotify v1.7.0 // indirect - github.com/go-logr/logr v1.2.0 // indirect - github.com/go-openapi/jsonpointer v0.19.5 // indirect - github.com/go-openapi/jsonreference v0.20.0 // indirect - github.com/go-openapi/swag v0.19.15 // indirect - github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect - github.com/golang/protobuf v1.5.3 // indirect - github.com/google/gnostic v0.5.7-v3refs // indirect - github.com/google/go-cmp v0.5.9 // indirect - github.com/google/gofuzz v1.1.0 // indirect - github.com/hashicorp/hcl v1.0.0 // indirect - github.com/imdario/mergo v0.3.12 // indirect - github.com/inconshreveable/mousetrap v1.1.0 // indirect - github.com/josharian/intern v1.0.0 // indirect - github.com/json-iterator/go v1.1.12 // indirect - github.com/magiconair/properties v1.8.7 // indirect - github.com/mailru/easyjson v0.7.6 // indirect - github.com/mitchellh/mapstructure v1.5.0 // indirect - github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect - github.com/modern-go/reflect2 v1.0.2 // indirect - github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect - github.com/pelletier/go-toml/v2 v2.1.0 // indirect - github.com/pkg/errors v0.9.1 // indirect - github.com/sagikazarmark/locafero v0.4.0 // indirect - github.com/sagikazarmark/slog-shim v0.1.0 // indirect - github.com/sourcegraph/conc v0.3.0 // indirect - github.com/spf13/afero v1.11.0 // indirect - github.com/spf13/cast v1.6.0 // indirect - github.com/spf13/pflag v1.0.5 // indirect - github.com/subosito/gotenv v1.6.0 // indirect - go.uber.org/atomic v1.9.0 // indirect - go.uber.org/multierr v1.9.0 // indirect - golang.org/x/exp v0.0.0-20230905200255-921286631fa9 // indirect - golang.org/x/net v0.19.0 // indirect - golang.org/x/oauth2 v0.15.0 // indirect - golang.org/x/sys v0.15.0 // indirect - golang.org/x/term v0.15.0 // indirect - golang.org/x/text v0.14.0 // indirect - golang.org/x/time v0.5.0 // indirect - google.golang.org/appengine v1.6.7 // indirect - google.golang.org/protobuf v1.31.0 // indirect - gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b // indirect - gopkg.in/inf.v0 v0.9.1 // indirect - gopkg.in/ini.v1 v1.67.0 // indirect - gopkg.in/yaml.v2 v2.4.0 // indirect - gopkg.in/yaml.v3 v3.0.1 // indirect - k8s.io/kube-openapi v0.0.0-20220627174259-011e075b9cb8 // indirect - k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9 // indirect - sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2 // indirect - sigs.k8s.io/structured-merge-diff/v4 v4.2.1 // indirect - sigs.k8s.io/yaml v1.3.0 // indirect -) diff --git a/pkg/imported-controller/go.sum b/pkg/imported-controller/go.sum deleted file mode 100644 index 7e734c02..00000000 --- a/pkg/imported-controller/go.sum +++ /dev/null @@ -1,717 +0,0 @@ -cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= -cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU= -cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= -cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc= -cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0= -cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To= -cloud.google.com/go v0.52.0/go.mod h1:pXajvRH/6o3+F9jDHZWQ5PbGhn+o8w9qiu/CffaVdO4= -cloud.google.com/go v0.53.0/go.mod h1:fp/UouUEsRkN6ryDKNW/Upv/JBKnv6WDthjR6+vze6M= -cloud.google.com/go v0.54.0/go.mod h1:1rq2OEkV3YMf6n/9ZvGWI3GWw0VoqH/1x2nd8Is/bPc= -cloud.google.com/go v0.56.0/go.mod h1:jr7tqZxxKOVYizybht9+26Z/gUq7tiRzu+ACVAMbKVk= -cloud.google.com/go v0.57.0/go.mod h1:oXiQ6Rzq3RAkkY7N6t3TcE6jE+CIBBbA36lwQ1JyzZs= -cloud.google.com/go v0.62.0/go.mod h1:jmCYTdRCQuc1PHIIJ/maLInMho30T/Y0M4hTdTShOYc= -cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHObY= -cloud.google.com/go v0.72.0/go.mod h1:M+5Vjvlc2wnp6tjzE102Dw08nGShTscUx2nZMufOKPI= -cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmWk= -cloud.google.com/go v0.78.0/go.mod h1:QjdrLG0uq+YwhjoVOLsS1t7TW8fs36kLs4XO5R5ECHg= -cloud.google.com/go v0.79.0/go.mod h1:3bzgcEeQlzbuEAYu4mrWhKqWjmpprinYgKJLgKHnbb8= -cloud.google.com/go v0.81.0/go.mod h1:mk/AM35KwGk/Nm2YSeZbxXdrNK3KZOYHmLkOqC2V6E0= -cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= -cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE= -cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc= -cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg= -cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= -cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= -cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= -cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk= -cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= -cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw= -cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA= -cloud.google.com/go/pubsub v1.3.1/go.mod h1:i+ucay31+CNRpDW4Lu78I4xXG+O1r/MAHgjpRVR+TSU= -cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw= -cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0ZeosJ0Rtdos= -cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk= -cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= -cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= -dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= -github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24= -github.com/Azure/go-autorest/autorest v0.11.18/go.mod h1:dSiJPy22c3u0OtOKDNttNgqpNFY/GeWa7GH/Pz56QRA= -github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M= -github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74= -github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k= -github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8= -github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU= -github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= -github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= -github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46/go.mod h1:3wb06e3pkSAbeQ52E9H9iFoQsEEwGN64994WTCIhntQ= -github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= -github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= -github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= -github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= -github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= -github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= -github.com/cespare/xxhash/v2 v2.1.2 h1:YRXhKfTDauu4ajMg1TPgFO5jnlC2HCbmLXMcTG5cbYE= -github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= -github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= -github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= -github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= -github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= -github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= -github.com/cpuguy83/go-md2man/v2 v2.0.3/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= -github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE= -github.com/elazarl/goproxy v0.0.0-20180725130230-947c36da3153/go.mod h1:/Zj4wYkgs4iZTTu3o/KG3Itv/qCCa8VVMlb3i9OVuzc= -github.com/emicklei/go-restful v0.0.0-20170410110728-ff4f55a20633/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs= -github.com/emicklei/go-restful v2.9.5+incompatible/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs= -github.com/emicklei/go-restful/v3 v3.8.0 h1:eCZ8ulSerjdAiaNpF7GxXIE7ZCMo1moN1qX+S609eVw= -github.com/emicklei/go-restful/v3 v3.8.0/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= -github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= -github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= -github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= -github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5ynNVH9qI8YYLbd1fK2po= -github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= -github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/evanphx/json-patch v4.12.0+incompatible h1:4onqiflcdA9EOZ4RxV643DvftH5pOlLGNtQ5lPWQu84= -github.com/evanphx/json-patch v4.12.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= -github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= -github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= -github.com/frankban/quicktest v1.14.6 h1:7Xjx+VpznH+oBnejlPUj8oUpdxnVs4f8XU8WnHkI4W8= -github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= -github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= -github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nosvA= -github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= -github.com/getkin/kin-openapi v0.76.0/go.mod h1:660oXbgy5JFMKreazJaQTw7o+X00qeSyhcnluiMv+Xg= -github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= -github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= -github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= -github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= -github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas= -github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU= -github.com/go-logr/logr v1.2.0 h1:QK40JKJyMdUDz+h+xvCsru/bJhvG0UxvePV0ufL/AcE= -github.com/go-logr/logr v1.2.0/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/zapr v1.2.0 h1:n4JnPI1T3Qq1SFEi/F8rwLrZERp2bso19PJZDB9dayk= -github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= -github.com/go-openapi/jsonpointer v0.19.5 h1:gZr+CIYByUqjcgeLXnQu2gHYQC9o73G2XUeOFYEICuY= -github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= -github.com/go-openapi/jsonreference v0.19.3/go.mod h1:rjx6GuL8TTa9VaixXglHmQmIL98+wF9xc8zWvFonSJ8= -github.com/go-openapi/jsonreference v0.19.5/go.mod h1:RdybgQwPxbL4UEjuAruzK1x3nE69AqPYEJeo/TWfEeg= -github.com/go-openapi/jsonreference v0.20.0 h1:MYlu0sBgChmCfJxxUKZ8g1cPWFOB37YSZqewK7OKeyA= -github.com/go-openapi/jsonreference v0.20.0/go.mod h1:Ag74Ico3lPc+zR+qjn4XBUmXymS4zJbYVCZmcgkasdo= -github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= -github.com/go-openapi/swag v0.19.14/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ= -github.com/go-openapi/swag v0.19.15 h1:D2NRCBzS9/pEY3gP9Nl8aDqGUcPFrwG2p+CNFrLyrCM= -github.com/go-openapi/swag v0.19.15/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ= -github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= -github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= -github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= -github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= -github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= -github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y= -github.com/golang/mock v1.4.0/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= -github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= -github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= -github.com/golang/mock v1.4.4/go.mod h1:l3mdAwkq5BuhzHwde/uurv3sEJeZMXNpwsxVWU71h+4= -github.com/golang/mock v1.5.0/go.mod h1:CWnOUgYIOo4TcNZ0wHX3YZCqsaM1I1Jvs6v3mP3KVu8= -github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.3.3/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw= -github.com/golang/protobuf v1.3.4/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw= -github.com/golang/protobuf v1.3.5/go.mod h1:6O5/vntMXwX2lRkT1hjjk0nAC1IDOTvTlVgjlRvqsdk= -github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= -github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= -github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= -github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= -github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8= -github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= -github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= -github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= -github.com/golang/protobuf v1.5.1/go.mod h1:DopwsBzvsk0Fs44TXzsVbJyPhcCPeIwnvohx4u74HPM= -github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= -github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= -github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= -github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= -github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= -github.com/google/btree v1.0.1/go.mod h1:xXMiIv4Fb/0kKde4SpL7qlzvu5cMJDRkFDxJfI9uaxA= -github.com/google/gnostic v0.5.7-v3refs h1:FhTMOKj2VhjpouxvWJAV1TL304uMlb9zcDqkl6cEI54= -github.com/google/gnostic v0.5.7-v3refs/go.mod h1:73MKFl6jIHelAJNaBGFzt3SPtZULs9dYrGFt8OiIsHQ= -github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= -github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= -github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= -github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.4.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= -github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= -github.com/google/gofuzz v1.1.0 h1:Hsa8mG0dQ46ij8Sl2AYJDUv1oA9/d6Vk+3LG99Oe02g= -github.com/google/gofuzz v1.1.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= -github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= -github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= -github.com/google/martian/v3 v3.1.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= -github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= -github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= -github.com/google/pprof v0.0.0-20191218002539-d4f498aebedc/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= -github.com/google/pprof v0.0.0-20200212024743-f11f1df84d12/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= -github.com/google/pprof v0.0.0-20200229191704-1ebb73c60ed3/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= -github.com/google/pprof v0.0.0-20200430221834-fc25d7d30c6d/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= -github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= -github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= -github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= -github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= -github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= -github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= -github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= -github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= -github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= -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/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= -github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= -github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= -github.com/imdario/mergo v0.3.5/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA= -github.com/imdario/mergo v0.3.12 h1:b6R2BslTbIEToALKP7LxUvijTsNI9TAe80pLWN2g/HU= -github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= -github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= -github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= -github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= -github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= -github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= -github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= -github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= -github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= -github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= -github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= -github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= -github.com/kr/pretty v0.2.0/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= -github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= -github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= -github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= -github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= -github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= -github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0VQdvPDY= -github.com/magiconair/properties v1.8.7/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= -github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= -github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= -github.com/mailru/easyjson v0.7.6 h1:8yTIVnZgCoiM1TgqoeTl+LfU5Jg6/xL3QhGQnimLYnA= -github.com/mailru/easyjson v0.7.6/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= -github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 h1:I0XW9+e1XWDxdcEniV4rQAIOPUGDq67JSCiRCgGCZLI= -github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= -github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= -github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= -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= -github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= -github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= -github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= -github.com/munnerz/goautoneg v0.0.0-20120707110453-a547fc61f48d/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= -github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= -github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= -github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw= -github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e h1:fD57ERR4JtEqsWbfPhv4DMiApHyliiK5xCTNVSPiaAs= -github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= -github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= -github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= -github.com/onsi/ginkgo v0.0.0-20170829012221-11459a886d9c/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= -github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= -github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE= -github.com/onsi/ginkgo/v2 v2.1.4 h1:GNapqRSid3zijZ9H77KrgVG4/8KqiyRsxcSxe+7ApXY= -github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= -github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= -github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= -github.com/onsi/gomega v1.19.0 h1:4ieX6qQjPP/BfC3mpsAtIGGlxTWPeA3Inl/7DtXw1tw= -github.com/pelletier/go-toml/v2 v2.1.0 h1:FnwAJ4oYMvbT/34k9zzHuZNrhlz48GB3/s6at6/MHO4= -github.com/pelletier/go-toml/v2 v2.1.0/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdUvyaeZurnPPDc= -github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= -github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= -github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U= -github.com/prometheus/client_golang v1.12.1 h1:ZiaPsmm9uiBeaSMRznKsCDNtPCS0T3JVDGF+06gjBzk= -github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.2.0 h1:uq5h0d+GuxiXLJLNABMgp2qUWDPiLvgCzz2dUR+/W/M= -github.com/prometheus/common v0.32.1 h1:hWIdL3N2HoUx3B8j3YN9mWor0qhY/NlEKZEaXxuIRh4= -github.com/prometheus/procfs v0.7.3 h1:4jVXhlkAyzOScmCkXBTOLRLTz8EeU+eyjrwB/EPq0VU= -github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= -github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8= -github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/sagikazarmark/locafero v0.4.0 h1:HApY1R9zGo4DBgr7dqsTH/JJxLTTsOt7u6keLGt6kNQ= -github.com/sagikazarmark/locafero v0.4.0/go.mod h1:Pe1W6UlPYUk/+wc/6KFhbORCfqzgYEpgQ3O5fPuL3H4= -github.com/sagikazarmark/slog-shim v0.1.0 h1:diDBnUNK9N/354PgrxMywXnAwEr1QZcOr6gto+ugjYE= -github.com/sagikazarmark/slog-shim v0.1.0/go.mod h1:SrcSrq8aKtyuqEI1uvTDTK1arOWRIczQRv+GVI1AkeQ= -github.com/sourcegraph/conc v0.3.0 h1:OQTbbt6P72L20UqAkXXuLOj79LfEanQ+YQFNpLA9ySo= -github.com/sourcegraph/conc v0.3.0/go.mod h1:Sdozi7LEKbFPqYX2/J+iBAM6HpqSLTASQIKqDmF7Mt0= -github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk= -github.com/spf13/afero v1.11.0 h1:WJQKhtpdm3v2IzqG8VMqrr6Rf3UYpEF239Jy9wNepM8= -github.com/spf13/afero v1.11.0/go.mod h1:GH9Y3pIexgf1MTIWtNGyogA5MwRIDXGUr+hbWNoBjkY= -github.com/spf13/cast v1.6.0 h1:GEiTHELF+vaR5dhz3VqZfFSzZjYbgeKDpBxQVS4GYJ0= -github.com/spf13/cast v1.6.0/go.mod h1:ancEpBxwJDODSW/UG4rDrAqiKolqNNh2DX3mk86cAdo= -github.com/spf13/cobra v1.8.0 h1:7aJaZx1B85qltLMc546zn58BxxfZdR/W22ej9CFoEf0= -github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyhcho= -github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= -github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/spf13/viper v1.18.2 h1:LUXCnvUvSM6FXAsj6nnfc8Q2tp1dIgUfY9Kc8GsSOiQ= -github.com/spf13/viper v1.18.2/go.mod h1:EKmWIqdnk5lOcmR72yw6hS+8OPYcwD0jteitLMVB+yk= -github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8= -github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= -github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= -github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= -github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= -github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= -github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= -github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= -github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= -github.com/subosito/gotenv v1.6.0 h1:9NlTDc1FTs4qu0DDq7AEtTPNw6SVm7uBMsUCUjABIf8= -github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= -github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= -go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= -go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= -go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= -go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= -go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= -go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= -go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= -go.uber.org/atomic v1.9.0 h1:ECmE8Bn/WFTYwEW/bpKD3M8VtR/zQVbavAoalC1PYyE= -go.uber.org/atomic v1.9.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= -go.uber.org/multierr v1.9.0 h1:7fIwc/ZtS0q++VgcfqFDxSBZVv/Xo49/SYnDFupUwlI= -go.uber.org/multierr v1.9.0/go.mod h1:X2jQV1h+kxSjClGpnseKVIxpmcjrj7MNnI0bnlfKTVQ= -go.uber.org/zap v1.21.0 h1:WefMeulhovoZ2sYXz7st6K0sLj7bBhpiFaud4r4zST8= -golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= -golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20220214200702-86341886e292/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= -golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= -golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= -golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek= -golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY= -golang.org/x/exp v0.0.0-20191129062945-2f5052295587/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= -golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= -golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= -golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= -golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= -golang.org/x/exp v0.0.0-20230905200255-921286631fa9 h1:GoHiUyI/Tp2nVkLI2mCxVkOjsbSXD66ic0XW0js0R9g= -golang.org/x/exp v0.0.0-20230905200255-921286631fa9/go.mod h1:S2oDrQGGwySpoQPVqRShND87VCbxmc6bL1Yd2oYrm6k= -golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= -golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= -golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= -golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= -golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= -golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/lint v0.0.0-20190409202823-959b441ac422/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/lint v0.0.0-20190909230951-414d861bb4ac/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/lint v0.0.0-20191125180803-fdd1cda4f05f/go.mod h1:5qLYkcX4OjUUV8bRuDixDT3tpyyb+LUpUlRWLxfhWrs= -golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= -golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= -golang.org/x/lint v0.0.0-20201208152925-83fdc39ff7b5/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= -golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE= -golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o= -golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= -golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY= -golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= -golang.org/x/mod v0.1.1-0.20191107180719-034126e5016b/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= -golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= -golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20200222125558-5a598a2470a0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20200301022130-244492dfa37a/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20200324143707-d3edc9973b7e/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= -golang.org/x/net v0.0.0-20200501053045-e0ff5e5a1de5/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= -golang.org/x/net v0.0.0-20200506145744-7e3656a0809f/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= -golang.org/x/net v0.0.0-20200513185701-a91f0712d120/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= -golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= -golang.org/x/net v0.0.0-20200520182314-0ba52f642ac2/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= -golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= -golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= -golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= -golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.0.0-20201031054903-ff519b6c9102/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= -golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= -golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= -golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= -golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= -golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -golang.org/x/net v0.19.0 h1:zTwKpTd2XuCqf8huc7Fo2iSy+4RHPd10s4KzeTnVr1c= -golang.org/x/net v0.19.0/go.mod h1:CfAk/cbD4CthTvqiEl8NpboMuiuOYsAr/7NOjZJtv1U= -golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= -golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= -golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= -golang.org/x/oauth2 v0.0.0-20191202225959-858c2ad4c8b6/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= -golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= -golang.org/x/oauth2 v0.0.0-20200902213428-5d25da1a8d43/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.0.0-20201109201403-9fd604954f58/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.0.0-20201208152858-08078c50e5b5/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.0.0-20210313182246-cd4f82c27b84/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.15.0 h1:s8pnnxNVzjWyrvYdFUQq5llS1PX2zhPXmccZv99h7uQ= -golang.org/x/oauth2 v0.15.0/go.mod h1:q48ptWNTY5XWf+JNten23lcvHpLJ0ZSxF5ttTHKVCAM= -golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200212091648-12a6c2dcc1e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200302150141-5c8b2ff67527/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= -golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= -golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= -golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= -golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= -golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20220210224613-90d013bbcef8/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.5.0 h1:o7cqy6amK/52YcAKIPlM3a+Fpj35zvRj2TP+e1xFSfk= -golang.org/x/time v0.5.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= -golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= -golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= -golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= -golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= -golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191115202509-3a792d9c32b2/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191125144606-a911d9008d1f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191130070609-6e064ea0cf2d/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191216173652-a0e659d51361/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20191227053925-7b8e75db28f4/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200122220014-bf1340f18c4a/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200204074204-1cc6d1ef6c74/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200207183749-b753a1ba74fa/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200212150539-ea181f53ac56/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200224181240-023911ca70b2/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200227222343-706bc42d1f0d/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200304193943-95d2e580d8eb/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw= -golang.org/x/tools v0.0.0-20200312045724-11d5b4c81c7d/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw= -golang.org/x/tools v0.0.0-20200331025713-a30bf2db82d4/go.mod h1:Sl4aGygMT6LrqrWclx+PTx3U+LnKx/seiNR+3G19Ar8= -golang.org/x/tools v0.0.0-20200501065659-ab2804fb9c9d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20200505023115-26f46d2f7ef8/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20200512131952-2bc93b1c0c88/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20200515010526-7d3b6ebf133d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20200618134242-20370b0cb4b2/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20200729194436-6467de6f59a7/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= -golang.org/x/tools v0.0.0-20200804011535-6c149bb5ef0d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= -golang.org/x/tools v0.0.0-20200825202427-b303f430e36d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= -golang.org/x/tools v0.0.0-20200904185747-39188db58858/go.mod h1:Cj7w3i3Rnn0Xh82ur9kSqwfTHTeVxaDqrfMjpcNT6bE= -golang.org/x/tools v0.0.0-20201110124207-079ba7bd75cd/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= -golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -gomodules.xyz/jsonpatch/v2 v2.2.0 h1:4pT439QV83L+G9FkcCriY6EkpcK6r6bK+A5FBUMI7qY= -google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= -google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= -google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= -google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= -google.golang.org/api v0.13.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= -google.golang.org/api v0.14.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= -google.golang.org/api v0.15.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= -google.golang.org/api v0.17.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= -google.golang.org/api v0.18.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= -google.golang.org/api v0.19.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= -google.golang.org/api v0.20.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= -google.golang.org/api v0.22.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= -google.golang.org/api v0.24.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE= -google.golang.org/api v0.28.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE= -google.golang.org/api v0.29.0/go.mod h1:Lcubydp8VUV7KeIHD9z2Bys/sm/vGKnG1UHuDBSrHWM= -google.golang.org/api v0.30.0/go.mod h1:QGmEvQ87FHZNiUVJkT14jQNYJ4ZJjdRF23ZXz5138Fc= -google.golang.org/api v0.35.0/go.mod h1:/XrVsuzM0rZmrsbjJutiuftIzeuTQcEeaYcSk/mQ1dg= -google.golang.org/api v0.36.0/go.mod h1:+z5ficQTmoYpPn8LCUNVpK5I7hwkpjbcgqA7I34qYtE= -google.golang.org/api v0.40.0/go.mod h1:fYKFpnQN0DsDSKRVRcQSDQNtqWPfM9i+zNPxepjRCQ8= -google.golang.org/api v0.41.0/go.mod h1:RkxM5lITDfTzmyKFPt+wGrCJbVfniCr2ool8kTBzRTU= -google.golang.org/api v0.43.0/go.mod h1:nQsDGjRXMo4lvh5hP0TKqF244gqhGcr/YSIykhUk/94= -google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= -google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= -google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= -google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0= -google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= -google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= -google.golang.org/appengine v1.6.7 h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c= -google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= -google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= -google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= -google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= -google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= -google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= -google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= -google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= -google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8= -google.golang.org/genproto v0.0.0-20191108220845-16a3f7862a1a/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= -google.golang.org/genproto v0.0.0-20191115194625-c23dd37a84c9/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= -google.golang.org/genproto v0.0.0-20191216164720-4f79533eabd1/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= -google.golang.org/genproto v0.0.0-20191230161307-f3c370f40bfb/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= -google.golang.org/genproto v0.0.0-20200115191322-ca5a22157cba/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= -google.golang.org/genproto v0.0.0-20200122232147-0452cf42e150/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= -google.golang.org/genproto v0.0.0-20200204135345-fa8e72b47b90/go.mod h1:GmwEX6Z4W5gMy59cAlVYjN9JhxgbQH6Gn+gFDQe2lzA= -google.golang.org/genproto v0.0.0-20200212174721-66ed5ce911ce/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200224152610-e50cd9704f63/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200228133532-8c2c7df3a383/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200305110556-506484158171/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200312145019-da6875a35672/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200331122359-1ee6d9798940/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200430143042-b979b6f78d84/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200511104702-f5ebc3bea380/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200515170657-fc4c6c6a6587/go.mod h1:YsZOwe1myG/8QRHRsmBRE1LrgQY60beZKjly0O1fX9U= -google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= -google.golang.org/genproto v0.0.0-20200618031413-b414f8b61790/go.mod h1:jDfRM7FcilCzHH/e9qn6dsT145K34l5v+OpcnNgKAAA= -google.golang.org/genproto v0.0.0-20200729003335-053ba62fc06f/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20200804131852-c06518451d9c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20200825200019-8632dd797987/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20200904004341-0bd0a958aa1d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20201019141844-1ed22bb0c154/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20201109203340-2640f1f9cdfb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20201201144952-b05cb90ed32e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20210222152913-aa3ee6e6a81c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20210303154014-9728d6b83eeb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20210310155132-4ce2db91004e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20210319143718-93e7006c17a6/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20210402141018-6c239bbf2bb1/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= -google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= -google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= -google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= -google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= -google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= -google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= -google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= -google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= -google.golang.org/grpc v1.28.0/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60= -google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3IjizoKk= -google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= -google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= -google.golang.org/grpc v1.31.1/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= -google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc= -google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA51WJ8= -google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= -google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= -google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= -google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= -google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= -google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= -google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= -google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= -google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGjtUeSXeh4= -google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= -google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= -google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= -google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= -gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b h1:QRR6H1YWRnHb4Y/HeNFCTJLFVxaq6wH4YuVdsUOr75U= -gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= -gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= -gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= -gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= -gopkg.in/ini.v1 v1.67.0 h1:Dgnx+6+nfE+IfzjUEISNeydPJh9AXNNsWbGP9KzCsOA= -gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= -gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= -gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= -gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= -gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= -gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= -honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= -honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= -k8s.io/api v0.24.2 h1:g518dPU/L7VRLxWfcadQn2OnsiGWVOadTLpdnqgY2OI= -k8s.io/api v0.24.2/go.mod h1:AHqbSkTm6YrQ0ObxjO3Pmp/ubFF/KuM7jU+3khoBsOg= -k8s.io/apiextensions-apiserver v0.24.2 h1:/4NEQHKlEz1MlaK/wHT5KMKC9UKYz6NZz6JE6ov4G6k= -k8s.io/apimachinery v0.24.2 h1:5QlH9SL2C8KMcrNJPor+LbXVTaZRReml7svPEh4OKDM= -k8s.io/apimachinery v0.24.2/go.mod h1:82Bi4sCzVBdpYjyI4jY6aHX+YCUchUIrZrXKedjd2UM= -k8s.io/client-go v0.24.2 h1:CoXFSf8if+bLEbinDqN9ePIDGzcLtqhfd6jpfnwGOFA= -k8s.io/client-go v0.24.2/go.mod h1:zg4Xaoo+umDsfCWr4fCnmLEtQXyCNXCvJuSsglNcV30= -k8s.io/gengo v0.0.0-20210813121822-485abfe95c7c/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E= -k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE= -k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y= -k8s.io/klog/v2 v2.60.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= -k8s.io/klog/v2 v2.70.1 h1:7aaoSdahviPmR+XkS7FyxlkkXs6tHISSG03RxleQAVQ= -k8s.io/klog/v2 v2.70.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= -k8s.io/kube-openapi v0.0.0-20220328201542-3ee0da9b0b42/go.mod h1:Z/45zLw8lUo4wdiUkI+v/ImEGAvu3WatcZl3lPMR4Rk= -k8s.io/kube-openapi v0.0.0-20220627174259-011e075b9cb8 h1:yEQKdMCjzAOvGeiTwG4hO/hNVNtDOuUFvMUZ0OlaIzs= -k8s.io/kube-openapi v0.0.0-20220627174259-011e075b9cb8/go.mod h1:mbJ+NSUoAhuR14N0S63bPkh8MGVSo3VYSGZtH/mfMe0= -k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= -k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9 h1:HNSDgDCrr/6Ly3WEGKZftiE7IY19Vz2GdbOCyI4qqhc= -k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= -rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= -rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= -rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= -sigs.k8s.io/container-object-storage-interface-api v0.1.1-0.20240208184109-05444273ee49 h1:Ax4j3ThWolmk6yH6jvL3Yf0Fzxe0ZfVuDlSLNILU3GA= -sigs.k8s.io/container-object-storage-interface-api v0.1.1-0.20240208184109-05444273ee49/go.mod h1:YiB+i/UGkzqgODDhRG3u7jkbWkQcoUeLEJ7hwOT/2Qk= -sigs.k8s.io/controller-runtime v0.12.3 h1:FCM8xeY/FI8hoAfh/V4XbbYMY20gElh9yh+A98usMio= -sigs.k8s.io/controller-runtime v0.12.3/go.mod h1:qKsk4WE6zW2Hfj0G4v10EnNB2jMG1C+NTb8h+DwCoU0= -sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2 h1:kDi4JBNAsJWfz1aEXhO8Jg87JJaPNLh5tIzYHgStQ9Y= -sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2/go.mod h1:B+TnT182UBxE84DiCz4CVE26eOSDAeYCpfDnC2kdKMY= -sigs.k8s.io/structured-merge-diff/v4 v4.0.2/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw= -sigs.k8s.io/structured-merge-diff/v4 v4.2.1 h1:bKCqE9GvQ5tiVHn5rfn1r+yao3aLQEaLzkkmAkf+A6Y= -sigs.k8s.io/structured-merge-diff/v4 v4.2.1/go.mod h1:j/nl6xW8vLS49O8YvXW1ocPhZawJtm+Yrr7PPRQ0Vg4= -sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc= -sigs.k8s.io/yaml v1.3.0 h1:a2VclLzOGrwOHDiV8EfBGhvjHvP46CtW5j6POvhYGGo= -sigs.k8s.io/yaml v1.3.0/go.mod h1:GeOyir5tyXNByN85N/dRIT9es5UQNerPYEKK56eTBm8= diff --git a/pkg/imported-controller/kustomization.yaml b/pkg/imported-controller/kustomization.yaml deleted file mode 100644 index 1cb50a7a..00000000 --- a/pkg/imported-controller/kustomization.yaml +++ /dev/null @@ -1,14 +0,0 @@ ---- -apiVersion: kustomize.config.k8s.io/v1beta1 -kind: Kustomization - -commonLabels: - app.kubernetes.io/part-of: container-object-storage-interface - app.kubernetes.io/component: controller - app.kubernetes.io/version: main - app.kubernetes.io/name: container-object-storage-interface-controller - -resources: -- resources/sa.yaml -- resources/rbac.yaml -- resources/deployment.yaml diff --git a/pkg/imported-controller/pkg/bucketclaim/bucketclaim.go b/pkg/imported-controller/pkg/bucketclaim/bucketclaim.go deleted file mode 100644 index 6ab94569..00000000 --- a/pkg/imported-controller/pkg/bucketclaim/bucketclaim.go +++ /dev/null @@ -1,275 +0,0 @@ -package bucketclaim - -import ( - "context" - "fmt" - - v1 "k8s.io/api/core/v1" - kubeerrors "k8s.io/apimachinery/pkg/api/errors" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" - kubeclientset "k8s.io/client-go/kubernetes" - "k8s.io/client-go/tools/record" - "k8s.io/klog/v2" - "sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage/v1alpha1" - bucketclientset "sigs.k8s.io/container-object-storage-interface-api/client/clientset/versioned" - objectstoragev1alpha1 "sigs.k8s.io/container-object-storage-interface-api/client/clientset/versioned/typed/objectstorage/v1alpha1" - "sigs.k8s.io/container-object-storage-interface-api/controller/events" - "sigs.k8s.io/container-object-storage-interface-controller/pkg/util" - "sigs.k8s.io/controller-runtime/pkg/controller/controllerutil" -) - -// BucketClaimListener is a resource handler for bucket requests objects -type BucketClaimListener struct { - eventRecorder record.EventRecorder - - kubeClient kubeclientset.Interface - bucketClient bucketclientset.Interface -} - -func NewBucketClaimListener() *BucketClaimListener { - return &BucketClaimListener{} -} - -// Add creates a bucket in response to a bucketClaim -func (b *BucketClaimListener) Add(ctx context.Context, bucketClaim *v1alpha1.BucketClaim) error { - klog.V(3).InfoS("Add BucketClaim", - "name", bucketClaim.ObjectMeta.Name, - "ns", bucketClaim.ObjectMeta.Namespace, - "bucketClass", bucketClaim.Spec.BucketClassName, - ) - - err := b.provisionBucketClaimOperation(ctx, bucketClaim) - if err != nil { - switch err { - case util.ErrInvalidBucketClass: - klog.V(3).ErrorS(err, - "bucketClaim", bucketClaim.ObjectMeta.Name, - "ns", bucketClaim.ObjectMeta.Namespace, - "bucketClassName", bucketClaim.Spec.BucketClassName) - case util.ErrBucketAlreadyExists: - klog.V(3).InfoS("Bucket already exists", - "bucketClaim", bucketClaim.ObjectMeta.Name, - "ns", bucketClaim.ObjectMeta.Namespace, - ) - return nil - default: - klog.V(3).ErrorS(err, - "name", bucketClaim.ObjectMeta.Name, - "ns", bucketClaim.ObjectMeta.Namespace, - "err", err) - } - return err - } - - klog.V(3).InfoS("Add BucketClaim success", - "name", bucketClaim.ObjectMeta.Name, - "ns", bucketClaim.ObjectMeta.Namespace) - return nil -} - -// update processes any updates made to the bucket request -func (b *BucketClaimListener) Update(ctx context.Context, old, new *v1alpha1.BucketClaim) error { - klog.V(3).InfoS("Update BucketClaim", - "name", old.Name, - "ns", old.Namespace) - - bucketClaim := new.DeepCopy() - - if !new.GetDeletionTimestamp().IsZero() { - if controllerutil.ContainsFinalizer(bucketClaim, util.BucketClaimFinalizer) { - bucketName := bucketClaim.Status.BucketName - err := b.buckets().Delete(ctx, bucketName, metav1.DeleteOptions{}) - if err != nil { - klog.V(3).ErrorS(err, "Error deleting bucket", - "bucket", bucketName, - "bucketClaim", bucketClaim.ObjectMeta.Name) - return b.recordError(bucketClaim, v1.EventTypeWarning, events.FailedDeleteBucket, err) - } - - klog.V(5).Infof("Successfully deleted bucket: %s from bucketClaim: %s", bucketName, bucketClaim.ObjectMeta.Name) - } - } - - klog.V(3).InfoS("Update BucketClaim success", - "name", bucketClaim.ObjectMeta.Name, - "ns", bucketClaim.ObjectMeta.Namespace) - return nil -} - -// Delete processes a bucket for which bucket request is deleted -func (b *BucketClaimListener) Delete(ctx context.Context, bucketClaim *v1alpha1.BucketClaim) error { - klog.V(3).InfoS("Delete BucketClaim", - "name", bucketClaim.ObjectMeta.Name, - "ns", bucketClaim.ObjectMeta.Namespace) - - return nil -} - -// provisionBucketClaimOperation attempts to provision a bucket for a given bucketClaim. -// -// Return values -// - nil - BucketClaim successfully processed -// - ErrInvalidBucketClass - BucketClass does not exist [requeue'd with exponential backoff] -// - ErrBucketAlreadyExists - BucketClaim already processed -// - non-nil err - Internal error [requeue'd with exponential backoff] -func (b *BucketClaimListener) provisionBucketClaimOperation(ctx context.Context, inputBucketClaim *v1alpha1.BucketClaim) error { - bucketClaim := inputBucketClaim.DeepCopy() - if bucketClaim.Status.BucketReady { - return util.ErrBucketAlreadyExists - } - - var bucketName string - var err error - - if bucketClaim.Spec.ExistingBucketName != "" { - bucketName = bucketClaim.Spec.ExistingBucketName - bucket, err := b.buckets().Get(ctx, bucketName, metav1.GetOptions{}) - if kubeerrors.IsNotFound(err) { - return b.recordError(inputBucketClaim, v1.EventTypeWarning, events.FailedCreateBucket, err) - } else if err != nil { - klog.V(3).ErrorS(err, "Get Bucket with ExistingBucketName error", "name", bucketClaim.Spec.ExistingBucketName) - return b.recordError(inputBucketClaim, v1.EventTypeWarning, events.FailedCreateBucket, err) - } - - bucket.Spec.BucketClaim = &v1.ObjectReference{ - Name: bucketClaim.ObjectMeta.Name, - Namespace: bucketClaim.ObjectMeta.Namespace, - UID: bucketClaim.ObjectMeta.UID, - } - - protocolCopy := make([]v1alpha1.Protocol, len(bucketClaim.Spec.Protocols)) - copy(protocolCopy, bucketClaim.Spec.Protocols) - - bucket.Spec.Protocols = protocolCopy - _, err = b.buckets().Update(ctx, bucket, metav1.UpdateOptions{}) - if err != nil { - klog.V(3).ErrorS(err, "Error updating existing bucket", - "bucket", bucket.ObjectMeta.Name, - "bucketClaim", bucketClaim.ObjectMeta.Name) - return b.recordError(inputBucketClaim, v1.EventTypeWarning, events.FailedCreateBucket, err) - } - - bucketClaim.Status.BucketName = bucketName - bucketClaim.Status.BucketReady = true - } else { - bucketClassName := bucketClaim.Spec.BucketClassName - if bucketClassName == "" { - return b.recordError(inputBucketClaim, v1.EventTypeWarning, events.FailedCreateBucket, util.ErrInvalidBucketClass) - } - - bucketClass, err := b.bucketClasses().Get(ctx, bucketClassName, metav1.GetOptions{}) - if kubeerrors.IsNotFound(err) { - return b.recordError(inputBucketClaim, v1.EventTypeWarning, events.FailedCreateBucket, err) - } else if err != nil { - klog.V(3).ErrorS(err, "Get Bucketclass Error", "name", bucketClassName) - return b.recordError(inputBucketClaim, v1.EventTypeWarning, events.FailedCreateBucket, err) - } - - bucketName = bucketClassName + string(bucketClaim.ObjectMeta.UID) - - // create bucket - bucket := &v1alpha1.Bucket{} - bucket.Name = bucketName - bucket.Spec.DriverName = bucketClass.DriverName - bucket.Status.BucketReady = false - bucket.Spec.BucketClassName = bucketClassName - bucket.Spec.DeletionPolicy = bucketClass.DeletionPolicy - bucket.Spec.Parameters = util.CopySS(bucketClass.Parameters) - - bucket.Spec.BucketClaim = &v1.ObjectReference{ - Name: bucketClaim.ObjectMeta.Name, - Namespace: bucketClaim.ObjectMeta.Namespace, - UID: bucketClaim.ObjectMeta.UID, - } - - protocolCopy := make([]v1alpha1.Protocol, len(bucketClaim.Spec.Protocols)) - copy(protocolCopy, bucketClaim.Spec.Protocols) - - bucket.Spec.Protocols = protocolCopy - bucket, err = b.buckets().Create(ctx, bucket, metav1.CreateOptions{}) - if err != nil && !kubeerrors.IsAlreadyExists(err) { - klog.V(3).ErrorS(err, "Error creationg bucket", - "bucket", bucketName, - "bucketClaim", bucketClaim.ObjectMeta.Name) - return b.recordError(inputBucketClaim, v1.EventTypeWarning, events.FailedCreateBucket, err) - } - - bucketClaim.Status.BucketName = bucketName - bucketClaim.Status.BucketReady = false - } - - // Fetching the updated bucketClaim again, so that the update - // operation doesn't happen on an outdated version of the bucketClaim. - bucketClaim, err = b.bucketClaims(bucketClaim.ObjectMeta.Namespace).UpdateStatus(ctx, bucketClaim, metav1.UpdateOptions{}) - if err != nil { - klog.V(3).ErrorS(err, "Failed to update status of BucketClaim", "name", bucketClaim.ObjectMeta.Name) - return b.recordError(inputBucketClaim, v1.EventTypeWarning, events.FailedCreateBucket, err) - } - - // Add the finalizers so that bucketClaim is deleted - // only after the associated bucket is deleted. - controllerutil.AddFinalizer(bucketClaim, util.BucketClaimFinalizer) - _, err = b.bucketClaims(bucketClaim.ObjectMeta.Namespace).Update(ctx, bucketClaim, metav1.UpdateOptions{}) - if err != nil { - klog.V(3).ErrorS(err, "Failed to add finalizer BucketClaim", "name", bucketClaim.ObjectMeta.Name) - return b.recordError(inputBucketClaim, v1.EventTypeWarning, events.FailedCreateBucket, err) - } - - klog.V(3).Infof("Finished creating Bucket %v", bucketName) - return nil -} - -// InitializeKubeClient initializes the kubernetes client -func (b *BucketClaimListener) InitializeKubeClient(k kubeclientset.Interface) { - b.kubeClient = k -} - -// InitializeBucketClient initializes the object storage bucket client -func (b *BucketClaimListener) InitializeBucketClient(bc bucketclientset.Interface) { - b.bucketClient = bc -} - -// InitializeEventRecorder initializes the event recorder -func (b *BucketClaimListener) InitializeEventRecorder(er record.EventRecorder) { - b.eventRecorder = er -} - -func (b *BucketClaimListener) buckets() objectstoragev1alpha1.BucketInterface { - if b.bucketClient != nil { - return b.bucketClient.ObjectstorageV1alpha1().Buckets() - } - panic("uninitialized listener") -} - -func (b *BucketClaimListener) bucketClasses() objectstoragev1alpha1.BucketClassInterface { - if b.bucketClient != nil { - return b.bucketClient.ObjectstorageV1alpha1().BucketClasses() - } - panic("uninitialized listener") -} - -func (b *BucketClaimListener) bucketClaims(namespace string) objectstoragev1alpha1.BucketClaimInterface { - if b.bucketClient != nil { - return b.bucketClient.ObjectstorageV1alpha1().BucketClaims(namespace) - } - panic("uninitialized listener") -} - -// recordError during the processing of the objects -func (b *BucketClaimListener) recordError(subject runtime.Object, eventtype, reason string, err error) error { - if b.eventRecorder == nil { - return err - } - b.eventRecorder.Event(subject, eventtype, reason, err.Error()) - - return err -} - -// recordEvent during the processing of the objects -func (b *BucketClaimListener) recordEvent(subject runtime.Object, eventtype, reason, message string, args ...any) { - if b.eventRecorder == nil { - return - } - b.eventRecorder.Event(subject, eventtype, reason, fmt.Sprintf(message, args...)) -} diff --git a/pkg/imported-controller/pkg/bucketclaim/bucketclaim_test.go b/pkg/imported-controller/pkg/bucketclaim/bucketclaim_test.go deleted file mode 100644 index 22a173d0..00000000 --- a/pkg/imported-controller/pkg/bucketclaim/bucketclaim_test.go +++ /dev/null @@ -1,327 +0,0 @@ -package bucketclaim - -import ( - "context" - "fmt" - "testing" - - v1 "k8s.io/api/core/v1" - kubeerrors "k8s.io/apimachinery/pkg/api/errors" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - fakekubeclientset "k8s.io/client-go/kubernetes/fake" - "k8s.io/client-go/tools/record" - "sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage/v1alpha1" - types "sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage/v1alpha1" - fakebucketclientset "sigs.k8s.io/container-object-storage-interface-api/client/clientset/versioned/fake" - "sigs.k8s.io/container-object-storage-interface-api/controller/events" - "sigs.k8s.io/container-object-storage-interface-controller/pkg/util" -) - -var classGoldParameters = map[string]string{ - "param1": "value1", - "param2": "value2", -} - -var goldClass = types.BucketClass{ - TypeMeta: metav1.TypeMeta{ - APIVersion: "objectstorage.k8s.io/v1alpha1", - Kind: "BucketClass", - }, - ObjectMeta: metav1.ObjectMeta{ - Name: "classgold", - }, - DriverName: "sample.cosi.driver", - Parameters: classGoldParameters, - DeletionPolicy: types.DeletionPolicyDelete, -} - -var bucketClaim1 = types.BucketClaim{ - TypeMeta: metav1.TypeMeta{ - APIVersion: "objectstorage.k8s.io/v1alpha1", - Kind: "BucketClaim", - }, - ObjectMeta: metav1.ObjectMeta{ - Name: "bucketclaim1", - Namespace: "default", - UID: "12345-67890", - }, - Spec: types.BucketClaimSpec{ - BucketClassName: "classgold", - Protocols: []types.Protocol{types.ProtocolAzure, types.ProtocolS3}, - }, -} - -var bucketClaim2 = types.BucketClaim{ - TypeMeta: metav1.TypeMeta{ - APIVersion: "objectstorage.k8s.io/v1alpha1", - Kind: "BucketClaim", - }, - ObjectMeta: metav1.ObjectMeta{ - Name: "bucketclaim2", - Namespace: "default", - UID: "abcde-fghijk", - }, - Spec: types.BucketClaimSpec{ - BucketClassName: "classgold", - Protocols: []types.Protocol{types.ProtocolAzure, types.ProtocolGCP}, - }, -} - -// Test basic add functionality -func TestAddBR(t *testing.T) { - runCreateBucket(t) -} - -// Test add with multipleBRs -func TestAddWithMultipleBR(t *testing.T) { - runCreateBucketWithMultipleBR(t) -} - -// Test add idempotency -func TestAddBRIdempotency(t *testing.T) { - runCreateBucketIdempotency(t) -} - -func runCreateBucket(t *testing.T) { - ctx, cancel := context.WithCancel(context.Background()) - defer cancel() - - client := fakebucketclientset.NewSimpleClientset() - kubeClient := fakekubeclientset.NewSimpleClientset() - eventRecorder := record.NewFakeRecorder(3) - - listener := NewBucketClaimListener() - listener.InitializeKubeClient(kubeClient) - listener.InitializeBucketClient(client) - listener.InitializeEventRecorder(eventRecorder) - - bucketclass, err := util.CreateBucketClass(ctx, client, &goldClass) - if err != nil { - t.Fatalf("Error occurred when creating BucketClass: %v", err) - } - - bucketClaim, err := util.CreateBucketClaim(ctx, client, &bucketClaim1) - if err != nil { - t.Fatalf("Error occurred when creating BucketClaim: %v", err) - } - - listener.Add(ctx, bucketClaim) - - bucketList := util.GetBuckets(ctx, client, 1) - defer util.DeleteObjects(ctx, client, *bucketClaim, *bucketclass, bucketList.Items) - - if len(bucketList.Items) != 1 { - t.Fatalf("Expecting a single Bucket created but found %v", len(bucketList.Items)) - } - bucket := bucketList.Items[0] - - bucketClaim, err = client.ObjectstorageV1alpha1().BucketClaims(bucketClaim.Namespace).Get(ctx, bucketClaim.Name, metav1.GetOptions{}) - if err != nil { - t.Fatalf("Error occurred when reading BucketClaim: %v", err) - } - - if util.ValidateBucket(bucket, *bucketClaim, *bucketclass) { - return - } else { - t.Fatalf("Failed to compare the resulting Bucket with the BucketClaim %v and BucketClass %v", bucketClaim, bucketclass) - } -} - -func runCreateBucketWithMultipleBR(t *testing.T) { - ctx, cancel := context.WithCancel(context.Background()) - defer cancel() - - client := fakebucketclientset.NewSimpleClientset() - kubeClient := fakekubeclientset.NewSimpleClientset() - eventRecorder := record.NewFakeRecorder(3) - - listener := NewBucketClaimListener() - listener.InitializeKubeClient(kubeClient) - listener.InitializeBucketClient(client) - listener.InitializeEventRecorder(eventRecorder) - - bucketclass, err := util.CreateBucketClass(ctx, client, &goldClass) - if err != nil { - t.Fatalf("Error occurred when creating BucketClass: %v", err) - } - - bucketClaim, err := util.CreateBucketClaim(ctx, client, &bucketClaim1) - if err != nil { - t.Fatalf("Error occurred when creating BucketClaim: %v", err) - } - - bucketClaim2, err := util.CreateBucketClaim(ctx, client, &bucketClaim2) - if err != nil { - t.Fatalf("Error occurred when creating BucketClaim: %v", err) - } - - listener.Add(ctx, bucketClaim) - listener.Add(ctx, bucketClaim2) - - bucketList := util.GetBuckets(ctx, client, 2) - defer util.DeleteObjects(ctx, client, *bucketClaim, *bucketClaim2, *bucketclass, bucketList.Items) - if len(bucketList.Items) != 2 { - t.Fatalf("Expecting two Buckets created but found %v", len(bucketList.Items)) - } - bucket := bucketList.Items[0] - bucket2 := bucketList.Items[1] - - bucketClaim, err = client.ObjectstorageV1alpha1().BucketClaims(bucketClaim.Namespace).Get(ctx, bucketClaim.Name, metav1.GetOptions{}) - if err != nil { - t.Fatalf("Error occurred when reading BucketClaim: %v", err) - } - bucketClaim2, err = client.ObjectstorageV1alpha1().BucketClaims(bucketClaim2.Namespace).Get(ctx, bucketClaim2.Name, metav1.GetOptions{}) - if err != nil { - t.Fatalf("Error occurred when reading BucketClaim: %v", err) - } - - if (util.ValidateBucket(bucket, *bucketClaim, *bucketclass) && util.ValidateBucket(bucket2, *bucketClaim2, *bucketclass)) || - (util.ValidateBucket(bucket2, *bucketClaim, *bucketclass) && util.ValidateBucket(bucket, *bucketClaim2, *bucketclass)) { - return - } else { - t.Fatalf("Failed to compare the resulting Bucket with the BucketClaim %v and BucketClass %v", bucketClaim, bucketclass) - } -} - -func runCreateBucketIdempotency(t *testing.T) { - ctx, cancel := context.WithCancel(context.Background()) - defer cancel() - - client := fakebucketclientset.NewSimpleClientset() - kubeClient := fakekubeclientset.NewSimpleClientset() - eventRecorder := record.NewFakeRecorder(3) - - listener := NewBucketClaimListener() - listener.InitializeKubeClient(kubeClient) - listener.InitializeBucketClient(client) - listener.InitializeEventRecorder(eventRecorder) - - bucketclass, err := util.CreateBucketClass(ctx, client, &goldClass) - if err != nil { - t.Fatalf("Error occurred when creating BucketClass: %v", err) - } - - bucketClaim, err := util.CreateBucketClaim(ctx, client, &bucketClaim1) - if err != nil { - t.Fatalf("Error occurred when creating BucketClaim: %v", err) - } - - listener.Add(ctx, bucketClaim) - - bucketList := util.GetBuckets(ctx, client, 1) - defer util.DeleteObjects(ctx, client, *bucketClaim, *bucketclass, bucketList.Items) - - if len(bucketList.Items) != 1 { - t.Errorf("Expecting a single Bucket created but found %v", len(bucketList.Items)) - } - bucket := bucketList.Items[0] - - bucketClaim, err = client.ObjectstorageV1alpha1().BucketClaims(bucketClaim.Namespace).Get(ctx, bucketClaim.Name, metav1.GetOptions{}) - if err != nil { - t.Fatalf("Error occurred when reading BucketClaim: %v", err) - } - - if util.ValidateBucket(bucket, *bucketClaim, *bucketclass) { - return - } else { - t.Fatalf("Failed to compare the resulting Bucket with the BucketClaim %v and BucketClass %v", bucketClaim, bucketclass) - // call the add directly the second time - } - - listener.Add(ctx, bucketClaim) - - bucketList = util.GetBuckets(ctx, client, 1) - if len(bucketList.Items) != 1 { - t.Fatalf("Expecting a single Bucket created but found %v", len(bucketList.Items)) - } -} - -// Test recording events -func TestRecordEvents(t *testing.T) { - t.Parallel() - - defaultBucketClaim := &v1alpha1.BucketClaim{ - ObjectMeta: metav1.ObjectMeta{ - Name: "test-bucketClaim", - Namespace: "test-ns", - }, - Spec: v1alpha1.BucketClaimSpec{ - BucketClassName: "test-bucketClass", - }, - } - - for _, tc := range []struct { - name string - expectedEvent string - eventTrigger func(*testing.T, *BucketClaimListener) - }{ - { - name: "ExistingBucketNotFound", - expectedEvent: newEvent( - v1.EventTypeWarning, - events.FailedCreateBucket, - "buckets.objectstorage.k8s.io \"existing-bucket\" not found"), - eventTrigger: func(t *testing.T, bcl *BucketClaimListener) { - ctx := context.TODO() - - bucketClaim := defaultBucketClaim.DeepCopy() - bucketClaim.Spec.ExistingBucketName = "existing-bucket" - - err := bcl.Add(ctx, bucketClaim) - if !kubeerrors.IsNotFound(err) { - t.Errorf("expected Not Found error got %v", err) - } - }, - }, - { - name: "BucketClassNotFound", - expectedEvent: newEvent( - v1.EventTypeWarning, - events.FailedCreateBucket, - "bucketclasses.objectstorage.k8s.io \"test-bucketClass\" not found"), - eventTrigger: func(t *testing.T, listener *BucketClaimListener) { - ctx := context.TODO() - bucketClaim := defaultBucketClaim.DeepCopy() - - err := listener.Add(ctx, bucketClaim) - if !kubeerrors.IsNotFound(err) { - t.Errorf("expected Not Found error got %v", err) - } - }, - }, - } { - tc := tc - - t.Run(tc.name, func(t *testing.T) { - t.Parallel() - - client := fakebucketclientset.NewSimpleClientset() - kubeClient := fakekubeclientset.NewSimpleClientset() - eventRecorder := record.NewFakeRecorder(1) - - listener := NewBucketClaimListener() - listener.InitializeKubeClient(kubeClient) - listener.InitializeBucketClient(client) - listener.InitializeEventRecorder(eventRecorder) - - tc.eventTrigger(t, listener) - - select { - case event, ok := <-eventRecorder.Events: - if ok { - if event != tc.expectedEvent { - t.Errorf("expected %s got %s", tc.expectedEvent, event) - } - } else { - t.Error("channel closed, no event") - } - default: - t.Errorf("no event after trigger") - } - }) - } -} - -func newEvent(eventType, reason, message string) string { - return fmt.Sprintf("%s %s %s", eventType, reason, message) -} diff --git a/pkg/imported-controller/pkg/util/const.go b/pkg/imported-controller/pkg/util/const.go deleted file mode 100644 index 082d779e..00000000 --- a/pkg/imported-controller/pkg/util/const.go +++ /dev/null @@ -1,16 +0,0 @@ -package util - -import ( - "errors" -) - -const ( - BucketClaimFinalizer = "cosi.objectstorage.k8s.io/bucketclaim-protection" -) - -var ( - // Error codes that the central controller will return - ErrBucketAlreadyExists = errors.New("a bucket already exists that matches the bucket claim") - ErrInvalidBucketClass = errors.New("cannot find bucket class with the name specified in the bucket claim") - ErrNotImplemented = errors.New("operation not implemented") -) diff --git a/pkg/imported-controller/pkg/util/util.go b/pkg/imported-controller/pkg/util/util.go deleted file mode 100644 index cdbfe18b..00000000 --- a/pkg/imported-controller/pkg/util/util.go +++ /dev/null @@ -1,102 +0,0 @@ -package util - -import ( - "context" - "reflect" - "time" - - apierrors "k8s.io/apimachinery/pkg/api/errors" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - - types "sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage/v1alpha1" - bucketclientset "sigs.k8s.io/container-object-storage-interface-api/client/clientset/versioned" - - "k8s.io/klog/v2" -) - -func CopySS(m map[string]string) map[string]string { - if m == nil { - return nil - } - copy := make(map[string]string, len(m)) - for k, v := range m { - copy[k] = v - } - return copy -} - -// GetBuckets will wait and fetch expected number of buckets created by the test -// This is used by bucket request unit tests -func GetBuckets(ctx context.Context, client bucketclientset.Interface, numExpected int) *types.BucketList { - bucketList, err := client.ObjectstorageV1alpha1().Buckets().List(ctx, metav1.ListOptions{}) - if len(bucketList.Items) > 0 { - return bucketList - } - numtimes := 0 - for numtimes < 10 { - bucketList, err = client.ObjectstorageV1alpha1().Buckets().List(ctx, metav1.ListOptions{}) - if len(bucketList.Items) >= numExpected { - return bucketList - } else { - klog.Errorf("Failed to fetch the bucket created %v", err) - } - numtimes++ - <-time.After(time.Duration(numtimes) * time.Second) - } - return &types.BucketList{} -} - -// Validates the content of the bucket against bucket request and backet class -// This is used by bucket request unit tests -func ValidateBucket(bucket types.Bucket, bucketClaim types.BucketClaim, bucketClass types.BucketClass) bool { - return (bucketClaim.Status.BucketName == bucket.ObjectMeta.Name && - bucket.Spec.BucketClassName == bucketClaim.Spec.BucketClassName && - bucket.Spec.BucketClaim.Name == bucketClaim.ObjectMeta.Name && - bucket.Spec.BucketClaim.Namespace == bucketClaim.ObjectMeta.Namespace && - bucket.Spec.BucketClaim.UID == bucketClaim.ObjectMeta.UID && - bucket.Spec.BucketClassName == bucketClass.ObjectMeta.Name && - reflect.DeepEqual(bucket.Spec.Parameters, bucketClass.Parameters) && - bucket.Spec.DriverName == bucketClass.DriverName && - bucket.Spec.DeletionPolicy == bucketClass.DeletionPolicy) -} - -// Deletes any bucket api object or an array of bucket or bucket access objects. -// This is used by bucket request and bucket access request unit tests -func DeleteObjects(ctx context.Context, client bucketclientset.Interface, objs ...interface{}) { - for _, obj := range objs { - switch t := obj.(type) { - case types.Bucket: - client.ObjectstorageV1alpha1().Buckets().Delete(ctx, obj.(types.Bucket).Name, metav1.DeleteOptions{}) - case types.BucketClaim: - client.ObjectstorageV1alpha1().BucketClaims(obj.(types.BucketClaim).Namespace).Delete(ctx, obj.(types.BucketClaim).Name, metav1.DeleteOptions{}) - case types.BucketClass: - client.ObjectstorageV1alpha1().BucketClasses().Delete(ctx, obj.(types.BucketClass).Name, metav1.DeleteOptions{}) - case []types.Bucket: - for _, a := range obj.([]types.Bucket) { - DeleteObjects(ctx, client, a) - } - default: - klog.Errorf("Unknown Obj of type %v", t) - } - } -} - -// CreateBucketClaim creates a bucket claim object or return an existing bucket request object -// This is used by bucket claim unit tests -func CreateBucketClaim(ctx context.Context, client bucketclientset.Interface, bc *types.BucketClaim) (*types.BucketClaim, error) { - bc, err := client.ObjectstorageV1alpha1().BucketClaims(bc.Namespace).Create(ctx, bc, metav1.CreateOptions{}) - if (err != nil) && apierrors.IsAlreadyExists(err) { - bc, err = client.ObjectstorageV1alpha1().BucketClaims(bc.Namespace).Get(ctx, bc.Name, metav1.GetOptions{}) - } - return bc, err -} - -// CreateBucketClass creates a bucket class object or return an existing bucket class object -// This is used by bucket claim unit tests -func CreateBucketClass(ctx context.Context, client bucketclientset.Interface, bc *types.BucketClass) (*types.BucketClass, error) { - bc, err := client.ObjectstorageV1alpha1().BucketClasses().Create(ctx, bc, metav1.CreateOptions{}) - if (err != nil) && apierrors.IsAlreadyExists(err) { - bc, err = client.ObjectstorageV1alpha1().BucketClasses().Get(ctx, bc.Name, metav1.GetOptions{}) - } - return bc, err -} diff --git a/pkg/imported-controller/resources/deployment.yaml b/pkg/imported-controller/resources/deployment.yaml deleted file mode 100644 index e222fa60..00000000 --- a/pkg/imported-controller/resources/deployment.yaml +++ /dev/null @@ -1,37 +0,0 @@ ---- -kind: Deployment -apiVersion: apps/v1 -metadata: - name: objectstorage-controller - labels: - app.kubernetes.io/part-of: container-object-storage-interface - app.kubernetes.io/component: controller - app.kubernetes.io/version: main - app.kubernetes.io/name: container-object-storage-interface-controller -spec: - replicas: 1 - strategy: - rollingUpdate: - maxUnavailable: 0 - maxSurge: 1 - selector: - matchLabels: - app.kubernetes.io/part-of: container-object-storage-interface - app.kubernetes.io/component: controller - app.kubernetes.io/version: main - app.kubernetes.io/name: container-object-storage-interface-controller - template: - metadata: - labels: - app.kubernetes.io/part-of: container-object-storage-interface - app.kubernetes.io/component: controller - app.kubernetes.io/version: main - app.kubernetes.io/name: container-object-storage-interface-controller - spec: - serviceAccountName: objectstorage-controller-sa - containers: - - name: objectstorage-controller - image: gcr.io/k8s-staging-sig-storage/objectstorage-controller:v20221027-v0.1.1-8-g300019f - imagePullPolicy: Always - args: - - "--v=5" diff --git a/pkg/imported-controller/resources/rbac.yaml b/pkg/imported-controller/resources/rbac.yaml deleted file mode 100644 index 8123e1aa..00000000 --- a/pkg/imported-controller/resources/rbac.yaml +++ /dev/null @@ -1,81 +0,0 @@ ---- -kind: ClusterRole -apiVersion: rbac.authorization.k8s.io/v1 -metadata: - name: objectstorage-controller-role - namespace: default - labels: - app.kubernetes.io/part-of: container-object-storage-interface - app.kubernetes.io/component: controller - app.kubernetes.io/version: main - app.kubernetes.io/name: container-object-storage-interface-controller -rules: -- apiGroups: ["objectstorage.k8s.io"] - resources: ["bucketclaims", "bucketaccesses", "bucketclaims/status", "bucketaccesses/status"] - verbs: ["get", "list", "watch", "update"] -- apiGroups: ["objectstorage.k8s.io"] - resources: ["buckets"] - verbs: ["get", "list", "watch", "update", "create", "delete"] -- apiGroups: ["objectstorage.k8s.io"] - resources: ["bucketclasses","bucketaccessclasses"] - verbs: ["get", "list"] -- apiGroups: [""] - resources: ["events"] - verbs: ["list", "watch", "create", "update", "patch"] -- apiGroups: [""] - resources: ["configmaps", "serviceaccounts"] - verbs: ["list", "get"] - ---- -kind: ClusterRoleBinding -apiVersion: rbac.authorization.k8s.io/v1 -metadata: - name: objectstorage-controller - namespace: default - labels: - app.kubernetes.io/part-of: container-object-storage-interface - app.kubernetes.io/component: controller - app.kubernetes.io/version: main - app.kubernetes.io/name: container-object-storage-interface-controller -subjects: - - kind: ServiceAccount - name: objectstorage-controller-sa - namespace: default -roleRef: - kind: ClusterRole - name: objectstorage-controller-role - apiGroup: rbac.authorization.k8s.io ---- -kind: Role -apiVersion: rbac.authorization.k8s.io/v1 -metadata: - name: objectstorage-controller - namespace: default - labels: - app.kubernetes.io/part-of: container-object-storage-interface - app.kubernetes.io/component: controller - app.kubernetes.io/version: main - app.kubernetes.io/name: container-object-storage-interface-controller -rules: -- apiGroups: ["coordination.k8s.io"] - resources: ["leases"] - verbs: ["get", "watch", "list", "delete", "update", "create"] ---- -kind: RoleBinding -apiVersion: rbac.authorization.k8s.io/v1 -metadata: - name: objectstorage-controller - namespace: default - labels: - app.kubernetes.io/part-of: container-object-storage-interface - app.kubernetes.io/component: controller - app.kubernetes.io/version: main - app.kubernetes.io/name: container-object-storage-interface-controller -subjects: - - kind: ServiceAccount - name: objectstorage-controller-sa - namespace: default -roleRef: - kind: Role - name: objectstorage-controller - apiGroup: rbac.authorization.k8s.io diff --git a/pkg/imported-controller/resources/sa.yaml b/pkg/imported-controller/resources/sa.yaml deleted file mode 100644 index f6cf10db..00000000 --- a/pkg/imported-controller/resources/sa.yaml +++ /dev/null @@ -1,10 +0,0 @@ ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: objectstorage-controller-sa - labels: - app.kubernetes.io/part-of: container-object-storage-interface - app.kubernetes.io/component: controller - app.kubernetes.io/version: main - app.kubernetes.io/name: container-object-storage-interface-controller diff --git a/pkg/imported-grpc/.github/ISSUE_TEMPLATE/bug_report.md b/pkg/imported-grpc/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index 8c304dd3..00000000 --- a/pkg/imported-grpc/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,31 +0,0 @@ ---- -name: Bug Report -about: Use this template for reporting bugs or issues. -title: "[DATE] - Title" -labels: bug ---- -# Bug Report - - - -**What happened**: - -**What you expected to happen**: - -**How to reproduce this bug (as minimally and precisely as possible)**: - -**Anything else relevant for this bug report?**: - -**Environment**: - -- Kubernetes version (use `kubectl version`), please list client and server: -- Provisoner name and version (provide the release tag or commit hash): -- Cloud provider or hardware configuration: -- OS (e.g: `cat /etc/os-release`): -- Kernel (e.g. `uname -a`): -- Install tools: -- Network plugin and version (if this is a network-related bug): -- Others: diff --git a/pkg/imported-grpc/.github/ISSUE_TEMPLATE/enhancement.md b/pkg/imported-grpc/.github/ISSUE_TEMPLATE/enhancement.md deleted file mode 100644 index 2cc57ace..00000000 --- a/pkg/imported-grpc/.github/ISSUE_TEMPLATE/enhancement.md +++ /dev/null @@ -1,18 +0,0 @@ ---- -name: Enhancement/Feature Request -about: Use this template to request a new feature or enhancement for the COSI spec -title: "[DATE] - Title" ---- -# Enhancement - -**Is your feature request related to a problem?/Why is this needed** - - -**Describe the solution you'd like in detail** - - -**Describe alternatives you've considered** - - -**Additional context** - diff --git a/pkg/imported-grpc/.github/SECURITY.md b/pkg/imported-grpc/.github/SECURITY.md deleted file mode 100644 index 3bafc83a..00000000 --- a/pkg/imported-grpc/.github/SECURITY.md +++ /dev/null @@ -1,14 +0,0 @@ -# Security Policy - -## Supported Versions - -Information about supported Kubernetes versions can be found on the -[Kubernetes version and version skew support policy] page on the Kubernetes website. - -## Reporting a Vulnerability - -Instructions for reporting a vulnerability can be found on the -[Kubernetes Security and Disclosure Information] page. - -[Kubernetes version and version skew support policy]: https://kubernetes.io/docs/setup/release/version-skew-policy/#supported-versions -[Kubernetes Security and Disclosure Information]: https://kubernetes.io/docs/reference/issues-security/security/#report-a-vulnerability diff --git a/pkg/imported-grpc/.gitignore b/pkg/imported-grpc/.gitignore deleted file mode 100644 index c105ac95..00000000 --- a/pkg/imported-grpc/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -*.tmp -.DS_Store -.build -*.swp -cosi.proto.tmp -protoc* -cosi.a -.protoc -.idea -.project diff --git a/pkg/imported-grpc/CHANGELOG/CHANGELOG-0.1.md b/pkg/imported-grpc/CHANGELOG/CHANGELOG-0.1.md deleted file mode 100644 index 14ed6145..00000000 --- a/pkg/imported-grpc/CHANGELOG/CHANGELOG-0.1.md +++ /dev/null @@ -1,5 +0,0 @@ -# First Release v0.1.0 - -### New Features - -- Support GRPC calls between COSI driver and sidecar diff --git a/pkg/imported-grpc/CONTRIBUTING.md b/pkg/imported-grpc/CONTRIBUTING.md deleted file mode 100644 index 38ec4ebc..00000000 --- a/pkg/imported-grpc/CONTRIBUTING.md +++ /dev/null @@ -1,26 +0,0 @@ -# Contributing Guidelines - -Welcome to Kubernetes. We are excited about the prospect of you joining our [community](https://git.k8s.io/community)! The Kubernetes community abides by the CNCF [code of conduct](code-of-conduct.md). Here is an excerpt: - -_As contributors and maintainers of this project, and in the interest of fostering an open and welcoming community, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities._ - -## Getting Started - -We have full documentation on how to get started contributing here: - - - -- [Contributor License Agreement](https://git.k8s.io/community/CLA.md) Kubernetes projects require that you sign a Contributor License Agreement (CLA) before we can accept your pull requests -- [Kubernetes Contributor Guide](https://git.k8s.io/community/contributors/guide) - Main contributor documentation, or you can just jump directly to the [contributing section](https://git.k8s.io/community/contributors/guide#contributing) -- [Contributor Cheat Sheet](https://git.k8s.io/community/contributors/guide/contributor-cheatsheet) - Common resources for existing developers - -## Mentorship - -- [Mentoring Initiatives](https://git.k8s.io/community/mentoring) - We have a diverse set of mentorship programs available that are always looking for volunteers! - -## Contact Information - -- [Slack](https://kubernetes.slack.com/messages/sig-storage) -- [Mailing List](https://groups.google.com/forum/#!forum/kubernetes-sig-storage) diff --git a/pkg/imported-grpc/LICENSE b/pkg/imported-grpc/LICENSE deleted file mode 100644 index 8dada3ed..00000000 --- a/pkg/imported-grpc/LICENSE +++ /dev/null @@ -1,201 +0,0 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "{}" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright {yyyy} {name of copyright owner} - - 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. diff --git a/pkg/imported-grpc/Makefile b/pkg/imported-grpc/Makefile deleted file mode 100644 index d34cf5df..00000000 --- a/pkg/imported-grpc/Makefile +++ /dev/null @@ -1,243 +0,0 @@ -all: build - -######################################################################## -## GOLANG ## -######################################################################## - -# If GOPATH isn't defined then set its default location. -ifeq (,$(strip $(GOPATH))) -GOPATH := $(HOME)/go -else -# If GOPATH is already set then update GOPATH to be its own -# first element. -GOPATH := $(word 1,$(subst :, ,$(GOPATH))) -endif -export GOPATH - - -######################################################################## -## PROTOC ## -######################################################################## - -# Only set PROTOC_VER if it has an empty value. -ifeq (,$(strip $(PROTOC_VER))) -PROTOC_VER := 3.14.0 -endif - -PROTOC_OS := $(shell uname -s) -ifeq (Darwin,$(PROTOC_OS)) -PROTOC_OS := osx -endif - -PROTOC_ARCH := $(shell uname -m) -ifeq (i386,$(PROTOC_ARCH)) -PROTOC_ARCH := x86_32 -endif - -PROTOC := ./protoc -PROTOC_ZIP := protoc-$(PROTOC_VER)-$(PROTOC_OS)-$(PROTOC_ARCH).zip -PROTOC_URL := https://github.com/protocolbuffers/protobuf/releases/download/v$(PROTOC_VER)/$(PROTOC_ZIP) -PROTOC_TMP_DIR := .protoc -PROTOC_TMP_BIN := $(PROTOC_TMP_DIR)/bin/protoc -PROTOC_TMP_INC := $(PROTOC_TMP_DIR)/include - -$(PROTOC): - -mkdir -p "$(PROTOC_TMP_DIR)" && \ - curl -L $(PROTOC_URL) -o "$(PROTOC_TMP_DIR)/$(PROTOC_ZIP)" && \ - unzip -o "$(PROTOC_TMP_DIR)/$(PROTOC_ZIP)" -d "$(PROTOC_TMP_DIR)" && \ - unzip -o "$(PROTOC_TMP_DIR)/$(PROTOC_ZIP)" -d "$(PROTOC_TMP_INC)/*" && \ - chmod 0755 "$(PROTOC_TMP_BIN)" && \ - cp -f "$(PROTOC_TMP_BIN)" "$@" - stat "$@" > /dev/null 2>&1 - - -######################################################################## -## PROTOC-GEN-GO ## -######################################################################## - -# This is the recipe for getting and installing the go plug-in -# for protoc -PROTOC_GEN_GO_PKG := github.com/golang/protobuf/protoc-gen-go -PROTOC_GEN_GO := protoc-gen-go -$(PROTOC_GEN_GO): PROTOBUF_PKG := $(dir $(PROTOC_GEN_GO_PKG)) -$(PROTOC_GEN_GO): PROTOBUF_VERSION := v1.3.2 -$(PROTOC_GEN_GO): - mkdir -p $(dir $(GOPATH)/src/$(PROTOBUF_PKG)) - test -d $(GOPATH)/src/$(PROTOBUF_PKG)/.git || git clone https://$(PROTOBUF_PKG) $(GOPATH)/src/$(PROTOBUF_PKG) - (cd $(GOPATH)/src/$(PROTOBUF_PKG) && \ - (test "$$(git describe --tags | head -1)" = "$(PROTOBUF_VERSION)" || \ - (git fetch && git checkout tags/$(PROTOBUF_VERSION)))) - (cd $(GOPATH)/src/$(PROTOBUF_PKG) && go get -v -d $$(go list -f '{{ .ImportPath }}' ./...)) && \ - go build -o "$@" $(PROTOC_GEN_GO_PKG) - - -######################################################################## -## PROTOC-GEN-GO-JSON ## -######################################################################## - -# This is the recipe for getting and installing the json plug-in -# for protoc-gen-go -PROTOC_GEN_GO_JSON_PKG := github.com/mitchellh/protoc-gen-go-json -PROTOC_GEN_GO_JSON := protoc-gen-go-json -$(PROTOC_GEN_GO_JSON): PROTOC_GEN_GO_JSON_VERSION := v1.1.0 -$(PROTOC_GEN_GO_JSON): - mkdir -p $(dir $(GOPATH)/src/$(PROTOC_GEN_GO_JSON_PKG)) - test -d $(GOPATH)/src/$(PROTOC_GEN_GO_JSON_PKG)/.git || git clone https://$(PROTOC_GEN_GO_JSON_PKG) $(GOPATH)/src/$(PROTOC_GEN_GO_JSON_PKG) - (cd $(GOPATH)/src/$(PROTOC_GEN_GO_JSON_PKG) && \ - (test "$$(git describe --tags | head -1)" = "$(PROTOC_GEN_GO_JSON_VERSION)" || \ - (git fetch && git checkout tags/$(PROTOC_GEN_GO_JSON_VERSION)))) - (cd $(GOPATH)/src/$(PROTOC_GEN_GO_JSON_PKG) && go get -v -d $$(go list -f '{{ .ImportPath }}' ./...)) && \ - go build -o "$@" $(PROTOC_GEN_GO_JSON_PKG) - - -######################################################################## -## GEN-PROTO-GO ## -######################################################################## - -# This is the recipe for getting and installing the gen-proto pkg -# This is a dependency of grpc-go and must be installed before -# installing grpc-go. -GENPROTO_GO_SRC := github.com/googleapis/go-genproto -GENPROTO_GO_PKG := google.golang.org/genproto -GENPROTO_BUILD_GO := genproto-build-go -$(GENPROTO_BUILD_GO): GENPROTO_VERSION := 24fa4b261c55da65468f2abfdae2b024eef27dfb -$(GENPROTO_BUILD_GO): - mkdir -p $(dir $(GOPATH)/src/$(GENPROTO_GO_PKG)) - test -d $(GOPATH)/src/$(GENPROTO_GO_PKG)/.git || git clone https://$(GENPROTO_GO_SRC) $(GOPATH)/src/$(GENPROTO_GO_PKG) - (cd $(GOPATH)/src/$(GENPROTO_GO_PKG) && \ - (git fetch && git checkout $(GENPROTO_VERSION))) - (cd $(GOPATH)/src/$(GENPROTO_GO_PKG) && go get -v -d $$(go list -f '{{ .ImportPath }}' ./...)) - - -######################################################################## -## GRPC-GO ## -######################################################################## - -# This is the recipe for getting and installing the grpc go -GRPC_GO_SRC := github.com/grpc/grpc-go -GRPC_GO_PKG := google.golang.org/grpc -GRPC_BUILD_GO := grpc-build-go -$(GRPC_BUILD_GO): GRPC_VERSION := v1.26.0 -$(GRPC_BUILD_GO): - mkdir -p $(dir $(GOPATH)/src/$(GRPC_GO_PKG)) - test -d $(GOPATH)/src/$(GRPC_GO_PKG)/.git || git clone https://$(GRPC_GO_SRC) $(GOPATH)/src/$(GRPC_GO_PKG) - (cd $(GOPATH)/src/$(GRPC_GO_PKG) && \ - (test "$$(git describe --tags | head -1)" = "$(GRPC_VERSION)" || \ - (git fetch && git checkout tags/$(GRPC_VERSION)))) - (cd $(GOPATH)/src/$(GRPC_GO_PKG) && go get -v -d $$(go list -f '{{ .ImportPath }}' ./...) && \ - go build -o "$@" $(GRPC_GO_PKG)) - - -######################################################################## -## PROTOC-GEN-GO-FAKE ## -######################################################################## - -# This is the recipe for getting and installing the grpc go -PROTOC_GEN_GO_FAKE_SRC := ./hack/fake-gen -PROTOC_GEN_GO_FAKE := protoc-gen-gofake -$(PROTOC_GEN_GO_FAKE): - go build -o $(PROTOC_GEN_GO_FAKE) $(PROTOC_GEN_GO_FAKE_SRC) - - -######################################################################## -## PATH ## -######################################################################## - -# Update PATH with the current directory. This enables the protoc -# binary to discover the protoc-gen-go binary, built inside this -# directory. -export PATH := $(shell pwd):$(PATH) - - -######################################################################## -## BUILD ## -######################################################################## -COSI_PROTO := ./cosi.proto -COSI_SPEC := spec.md -COSI_PKG_ROOT := sigs.k8s.io/container-object-storage-interface-spec -COSI_PKG_SUB := . -COSI_BUILD := $(COSI_PKG_SUB)/.build -COSI_GO := $(COSI_PKG_SUB)/cosi.pb.go -COSI_GO_JSON := $(COSI_PKG_SUB)/cosi.pb.json.go -COSI_GO_FAKE := $(COSI_PKG_SUB)/fake/cosi.pb.fake.go -COSI_A := cosi.a -COSI_GO_TMP := $(COSI_BUILD)/$(COSI_PKG_ROOT)/cosi.pb.go -COSI_GO_JSON_TMP := $(COSI_BUILD)/$(COSI_PKG_ROOT)/cosi.pb.json.go -COSI_GO_FAKE_TMP := $(COSI_BUILD)/fake/$(COSI_PKG_ROOT)/cosi.pb.fake.go - -# This recipe generates the go language bindings to a temp area. -$(COSI_GO_TMP): HERE := $(shell pwd) -$(COSI_GO_TMP): PTYPES_PKG := github.com/golang/protobuf/ptypes -$(COSI_GO_TMP): GO_OUT := plugins=grpc -$(COSI_GO_TMP): GO_OUT := $(GO_OUT),Mgoogle/protobuf/descriptor.proto=github.com/golang/protobuf/protoc-gen-go/descriptor -$(COSI_GO_TMP): GO_OUT := $(GO_OUT),Mgoogle/protobuf/wrappers.proto=$(PTYPES_PKG)/wrappers -$(COSI_GO_TMP): GO_OUT := $(GO_OUT):"$(HERE)/$(COSI_BUILD)" -$(COSI_GO_TMP): GO_JSON_OUT := emit_defaults=true -$(COSI_GO_TMP): GO_JSON_OUT := $(GO_JSON_OUT):"$(HERE)/$(COSI_BUILD)" -$(COSI_GO_TMP): GO_FAKE_OUT := emit_defaults -$(COSI_GO_TMP): GO_FAKE_OUT := $(GO_FAKE_OUT),packagePath=sigs.k8s.io/container-object-storage-interface-spec -$(COSI_GO_TMP): GO_FAKE_OUT := $(GO_FAKE_OUT):"$(HERE)/$(COSI_BUILD)"/fake -$(COSI_GO_TMP): INCLUDE := -I$(GOPATH)/src -I$(HERE)/$(PROTOC_TMP_DIR)/include -$(COSI_GO_TMP): $(COSI_PROTO) | $(PROTOC) $(PROTOC_GEN_GO) $(PROTOC_GEN_GO_JSON) $(PROTOC_GEN_GO_FAKE) - @mkdir -p "$(@D)" - @mkdir -p "$(COSI_BUILD)/fake" - (cd "$(GOPATH)/src" && \ - $(HERE)/$(PROTOC) $(INCLUDE) --go_out=$(GO_OUT) --go-json_out=$(GO_JSON_OUT) --gofake_out=$(GO_FAKE_OUT) "$(COSI_PKG_ROOT)/$( /dev/null 2>&1 || cp -f "$?" "$@" -endif - -# The temp language bindings are compared to the ones that are -# versioned. If they are different then it means the language -# bindings were not updated prior to being committed. -$(COSI_GO_JSON): $(COSI_GO_JSON_TMP) -ifeq (true,$(TRAVIS)) - diff "$@" "$?" -else - @mkdir -p "$(@D)" - diff "$@" "$?" > /dev/null 2>&1 || cp -f "$?" "$@" -endif - -# The temp language bindings are compared to the ones that are -# versioned. If they are different then it means the language -# bindings were not updated prior to being committed. -$(COSI_GO_FAKE): $(COSI_GO_FAKE_TMP) -ifeq (true,$(TRAVIS)) - diff "$@" "$?" -else - @mkdir -p "$(@D)" - diff "$@" "$?" > /dev/null 2>&1 || cp -f "$?" "$@" -endif - -# This recipe builds the Go archive from the sources in three steps: -# -# 1. Go get any missing dependencies. -# 2. Cache the packages. -# 3. Build the archive file. -$(COSI_A): $(COSI_GO) $(COSI_GO_JSON) $(COSI_GO_FAKE) $(GENPROTO_BUILD_GO) $(GRPC_BUILD_GO) - go get -v -d ./... - go install ./$(COSI_PKG_SUB) - go build -o "$@" ./$(COSI_PKG_SUB) - -generate: - echo "// Code generated by make; DO NOT EDIT." > "$(COSI_PROTO)" - cat $(COSI_SPEC) | sed -n -e '/```protobuf$$/,/^```$$/ p' | sed '/^```/d' >> "$(COSI_PROTO)" - -build: generate $(COSI_A) - -clean: - go clean -i ./... - rm -rf "$(COSI_PROTO)" "$(COSI_A)" "$(COSI_GO)" "$(COSI_GO_JSON)" "$(COSI_BUILD)" - -clobber: clean - rm -fr "$(PROTOC)" "$(PROTOC_TMP_DIR)" "$(PROTOC_GEN_GO)" "$(PROTOC_GEN_GO_JSON)" "$(PROTOC_GEN_GO_FAKE)" - -.PHONY: clean clobber $(GRPC_BUILD_GO) $(GENPROTO_BUILD_GO) diff --git a/pkg/imported-grpc/OWNERS b/pkg/imported-grpc/OWNERS deleted file mode 100644 index 0f0e9b26..00000000 --- a/pkg/imported-grpc/OWNERS +++ /dev/null @@ -1,9 +0,0 @@ -# See the OWNERS docs at https://go.k8s.io/owners - -approvers: - - jsafrane - - msau42 - - saad-ali - - xing-yang - - BlaineEXE - - shanduur diff --git a/pkg/imported-grpc/README.md b/pkg/imported-grpc/README.md deleted file mode 100644 index 705057af..00000000 --- a/pkg/imported-grpc/README.md +++ /dev/null @@ -1,70 +0,0 @@ -![version](https://img.shields.io/badge/status-pre--alpha-lightgrey) - -# Container Object Storage Interface Spec - -This repository hosts the gRPC API for the Container Object Storage Interface (COSI) standard. The interfaces defined in the [gRPC specification](cosi.proto) are meant to be the common interface for object storage provisioning and management across various object storage vendors. - -For more information about the COSI effort, visit our [documentation](https://container-object-storage-interface.github.io/docs). - -## Why another standard? - -Kubernetes abstracts file/block storage via the CSI standard. The primitives for file/block storage do not extend well to object storage. Here is the **_extremely_** concise and incomplete list of reasons why: - - - Unit of provisioned storage - Bucket instead of filesystem mount or block device. - - Access is over the network instead of local POSIX calls. - - No common protocol for consumption across various implementations of object storage. - - Management policies and primitives - for instance, mounting and unmounting do not apply to object storage. - -The existing primitives in CSI do not apply to objectstorage. Thus the need for a new standard to automate the management of objectstorage. - -## Developer Guide - -All API definitions **_MUST_** satisfy the following requirements: - - - - Must be in-sync with the API definitions in [sigs.k8s.io/container-object-storage-interface-api](https://github.com/kubernetes-sigs/container-object-storage-interface-api) - -### Build and Test - -1. `cosi.proto` is generated from the specification defined in `spec.md` - -2. In order to update the API, make changes to `spec.md`. Then, generate `cosi.proto` using: - -```sh -# generates cosi.proto -make generate -``` - -3. Clean and Build - -```sh -# cleans up old build files -make clobber -# builds the go bindings -make -``` - -4. Do it all in 1 step: - -``` -# generates cosi.proto and builds the go bindings -make all -``` - -## References - -- [Documentation](https://container-object-storage-interface.github.io/) -- [Deployment Guide](https://container-object-storage-interface.github.io/docs/deployment-guide) -- [Weekly Meetings](https://container-object-storage-interface.github.io/docs/community/weekly-meetings) -- [Roadmap](https://github.com/orgs/kubernetes-sigs/projects/8) - -## Community, discussion, contribution, and support - -You can reach the maintainers of this project at: - -- [#sig-storage-cosi](https://kubernetes.slack.com/messages/sig-storage-cosi) slack channel -- [container-object-storage-interface](https://groups.google.com/g/container-object-storage-interface-wg?pli=1) mailing list - -### Code of conduct - -Participation in the Kubernetes community is governed by the [Kubernetes Code of Conduct](code-of-conduct.md). diff --git a/pkg/imported-grpc/RELEASE.md b/pkg/imported-grpc/RELEASE.md deleted file mode 100644 index 7274b344..00000000 --- a/pkg/imported-grpc/RELEASE.md +++ /dev/null @@ -1,9 +0,0 @@ -# Release Process - -The Kubernetes Template Project is released on an as-needed basis. The process is as follows: - -1. An issue is proposing a new release with a changelog since the last release -1. All [OWNERS](OWNERS) must LGTM this release -1. An OWNER runs `git tag -s $VERSION` and inserts the changelog and pushes the tag with `git push $VERSION` -1. The release issue is closed -1. An announcement email is sent to `kubernetes-dev@googlegroups.com` with the subject `[ANNOUNCE] kubernetes-template-project $VERSION is released` diff --git a/pkg/imported-grpc/SECURITY_CONTACTS b/pkg/imported-grpc/SECURITY_CONTACTS deleted file mode 100644 index 8a7b91d5..00000000 --- a/pkg/imported-grpc/SECURITY_CONTACTS +++ /dev/null @@ -1,16 +0,0 @@ -# Defined below are the security contacts for this repo. -# -# They are the contact point for the Product Security Committee to reach out -# to for triaging and handling of incoming issues. -# -# The below names agree to abide by the -# [Embargo Policy](https://git.k8s.io/security/private-distributors-list.md#embargo-policy) -# and will be removed and replaced if they violate that agreement. -# -# DO NOT REPORT SECURITY VULNERABILITIES DIRECTLY TO THESE NAMES, FOLLOW THE -# INSTRUCTIONS AT https://kubernetes.io/security/ - -jsafrane -msau42 -saad-ali -xing-yang diff --git a/pkg/imported-grpc/code-of-conduct.md b/pkg/imported-grpc/code-of-conduct.md deleted file mode 100644 index 0d15c00c..00000000 --- a/pkg/imported-grpc/code-of-conduct.md +++ /dev/null @@ -1,3 +0,0 @@ -# Kubernetes Community Code of Conduct - -Please refer to our [Kubernetes Community Code of Conduct](https://git.k8s.io/community/code-of-conduct.md) diff --git a/pkg/imported-grpc/cosi.pb.go b/pkg/imported-grpc/cosi.pb.go deleted file mode 100644 index 6e1aaa7e..00000000 --- a/pkg/imported-grpc/cosi.pb.go +++ /dev/null @@ -1,2009 +0,0 @@ -// Code generated by make; DO NOT EDIT. - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.25.0 -// protoc v3.14.0 -// source: sigs.k8s.io/container-object-storage-interface-spec/cosi.proto - -package cosi - -import ( - context "context" - proto "github.com/golang/protobuf/proto" - descriptor "github.com/golang/protobuf/protoc-gen-go/descriptor" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// This is a compile-time assertion that a sufficiently up-to-date version -// of the legacy proto package is being used. -const _ = proto.ProtoPackageIsVersion4 - -// S3SignatureVersion is the version of the signing algorithm for all s3 requests -type S3SignatureVersion int32 - -const ( - S3SignatureVersion_UnknownSignature S3SignatureVersion = 0 - // S3V2, Signature version v2 - S3SignatureVersion_S3V2 S3SignatureVersion = 1 - // S3V4, Signature version v4 - S3SignatureVersion_S3V4 S3SignatureVersion = 2 -) - -// Enum value maps for S3SignatureVersion. -var ( - S3SignatureVersion_name = map[int32]string{ - 0: "UnknownSignature", - 1: "S3V2", - 2: "S3V4", - } - S3SignatureVersion_value = map[string]int32{ - "UnknownSignature": 0, - "S3V2": 1, - "S3V4": 2, - } -) - -func (x S3SignatureVersion) Enum() *S3SignatureVersion { - p := new(S3SignatureVersion) - *p = x - return p -} - -func (x S3SignatureVersion) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (S3SignatureVersion) Descriptor() protoreflect.EnumDescriptor { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_enumTypes[0].Descriptor() -} - -func (S3SignatureVersion) Type() protoreflect.EnumType { - return &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_enumTypes[0] -} - -func (x S3SignatureVersion) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use S3SignatureVersion.Descriptor instead. -func (S3SignatureVersion) EnumDescriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{0} -} - -type AnonymousBucketAccessMode int32 - -const ( - AnonymousBucketAccessMode_UnknownBucketAccessMode AnonymousBucketAccessMode = 0 - // Default, disallow uncredentialed access to the backend storage. - AnonymousBucketAccessMode_Private AnonymousBucketAccessMode = 1 - // Read only, uncredentialed users can call ListBucket and GetObject. - AnonymousBucketAccessMode_ReadOnly AnonymousBucketAccessMode = 2 - // Write only, uncredentialed users can only call PutObject. - AnonymousBucketAccessMode_WriteOnly AnonymousBucketAccessMode = 3 - // Read/Write, uncredentialed users can read objects as well as PutObject. - AnonymousBucketAccessMode_ReadWrite AnonymousBucketAccessMode = 4 -) - -// Enum value maps for AnonymousBucketAccessMode. -var ( - AnonymousBucketAccessMode_name = map[int32]string{ - 0: "UnknownBucketAccessMode", - 1: "Private", - 2: "ReadOnly", - 3: "WriteOnly", - 4: "ReadWrite", - } - AnonymousBucketAccessMode_value = map[string]int32{ - "UnknownBucketAccessMode": 0, - "Private": 1, - "ReadOnly": 2, - "WriteOnly": 3, - "ReadWrite": 4, - } -) - -func (x AnonymousBucketAccessMode) Enum() *AnonymousBucketAccessMode { - p := new(AnonymousBucketAccessMode) - *p = x - return p -} - -func (x AnonymousBucketAccessMode) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (AnonymousBucketAccessMode) Descriptor() protoreflect.EnumDescriptor { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_enumTypes[1].Descriptor() -} - -func (AnonymousBucketAccessMode) Type() protoreflect.EnumType { - return &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_enumTypes[1] -} - -func (x AnonymousBucketAccessMode) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use AnonymousBucketAccessMode.Descriptor instead. -func (AnonymousBucketAccessMode) EnumDescriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{1} -} - -type AuthenticationType int32 - -const ( - AuthenticationType_UnknownAuthenticationType AuthenticationType = 0 - // Default, KEY based authentication. - AuthenticationType_Key AuthenticationType = 1 - // Storageaccount based authentication. - AuthenticationType_IAM AuthenticationType = 2 -) - -// Enum value maps for AuthenticationType. -var ( - AuthenticationType_name = map[int32]string{ - 0: "UnknownAuthenticationType", - 1: "Key", - 2: "IAM", - } - AuthenticationType_value = map[string]int32{ - "UnknownAuthenticationType": 0, - "Key": 1, - "IAM": 2, - } -) - -func (x AuthenticationType) Enum() *AuthenticationType { - p := new(AuthenticationType) - *p = x - return p -} - -func (x AuthenticationType) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (AuthenticationType) Descriptor() protoreflect.EnumDescriptor { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_enumTypes[2].Descriptor() -} - -func (AuthenticationType) Type() protoreflect.EnumType { - return &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_enumTypes[2] -} - -func (x AuthenticationType) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use AuthenticationType.Descriptor instead. -func (AuthenticationType) EnumDescriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{2} -} - -type S3 struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // region denotes the geographical region where the S3 server is running - Region string `protobuf:"bytes,1,opt,name=region,proto3" json:"region,omitempty"` - // signature_version denotes the signature version for signing all s3 requests - SignatureVersion S3SignatureVersion `protobuf:"varint,2,opt,name=signature_version,json=signatureVersion,proto3,enum=cosi.v1alpha1.S3SignatureVersion" json:"signature_version,omitempty"` -} - -func (x *S3) Reset() { - *x = S3{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *S3) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*S3) ProtoMessage() {} - -func (x *S3) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use S3.ProtoReflect.Descriptor instead. -func (*S3) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{0} -} - -func (x *S3) GetRegion() string { - if x != nil { - return x.Region - } - return "" -} - -func (x *S3) GetSignatureVersion() S3SignatureVersion { - if x != nil { - return x.SignatureVersion - } - return S3SignatureVersion_UnknownSignature -} - -type AzureBlob struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // storage_account is the id of the azure storage account - StorageAccount string `protobuf:"bytes,1,opt,name=storage_account,json=storageAccount,proto3" json:"storage_account,omitempty"` -} - -func (x *AzureBlob) Reset() { - *x = AzureBlob{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *AzureBlob) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AzureBlob) ProtoMessage() {} - -func (x *AzureBlob) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AzureBlob.ProtoReflect.Descriptor instead. -func (*AzureBlob) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{1} -} - -func (x *AzureBlob) GetStorageAccount() string { - if x != nil { - return x.StorageAccount - } - return "" -} - -type GCS struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // private_key_name denotes the name of the private key in the storage backend - PrivateKeyName string `protobuf:"bytes,1,opt,name=private_key_name,json=privateKeyName,proto3" json:"private_key_name,omitempty"` - // project_id denotes the name of the project id in the storage backend - ProjectId string `protobuf:"bytes,2,opt,name=project_id,json=projectId,proto3" json:"project_id,omitempty"` - // service_account denotes the name of the service account in the storage backend - ServiceAccount string `protobuf:"bytes,3,opt,name=service_account,json=serviceAccount,proto3" json:"service_account,omitempty"` -} - -func (x *GCS) Reset() { - *x = GCS{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *GCS) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GCS) ProtoMessage() {} - -func (x *GCS) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GCS.ProtoReflect.Descriptor instead. -func (*GCS) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{2} -} - -func (x *GCS) GetPrivateKeyName() string { - if x != nil { - return x.PrivateKeyName - } - return "" -} - -func (x *GCS) GetProjectId() string { - if x != nil { - return x.ProjectId - } - return "" -} - -func (x *GCS) GetServiceAccount() string { - if x != nil { - return x.ServiceAccount - } - return "" -} - -type Protocol struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // Types that are assignable to Type: - // - // *Protocol_S3 - // *Protocol_AzureBlob - // *Protocol_Gcs - Type isProtocol_Type `protobuf_oneof:"type"` -} - -func (x *Protocol) Reset() { - *x = Protocol{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *Protocol) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Protocol) ProtoMessage() {} - -func (x *Protocol) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Protocol.ProtoReflect.Descriptor instead. -func (*Protocol) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{3} -} - -func (m *Protocol) GetType() isProtocol_Type { - if m != nil { - return m.Type - } - return nil -} - -func (x *Protocol) GetS3() *S3 { - if x, ok := x.GetType().(*Protocol_S3); ok { - return x.S3 - } - return nil -} - -func (x *Protocol) GetAzureBlob() *AzureBlob { - if x, ok := x.GetType().(*Protocol_AzureBlob); ok { - return x.AzureBlob - } - return nil -} - -func (x *Protocol) GetGcs() *GCS { - if x, ok := x.GetType().(*Protocol_Gcs); ok { - return x.Gcs - } - return nil -} - -type isProtocol_Type interface { - isProtocol_Type() -} - -type Protocol_S3 struct { - S3 *S3 `protobuf:"bytes,1,opt,name=s3,proto3,oneof"` -} - -type Protocol_AzureBlob struct { - AzureBlob *AzureBlob `protobuf:"bytes,2,opt,name=azureBlob,proto3,oneof"` -} - -type Protocol_Gcs struct { - Gcs *GCS `protobuf:"bytes,3,opt,name=gcs,proto3,oneof"` -} - -func (*Protocol_S3) isProtocol_Type() {} - -func (*Protocol_AzureBlob) isProtocol_Type() {} - -func (*Protocol_Gcs) isProtocol_Type() {} - -type CredentialDetails struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // map of the details in the secrets for the protocol string - Secrets map[string]string `protobuf:"bytes,1,rep,name=secrets,proto3" json:"secrets,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` -} - -func (x *CredentialDetails) Reset() { - *x = CredentialDetails{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *CredentialDetails) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*CredentialDetails) ProtoMessage() {} - -func (x *CredentialDetails) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use CredentialDetails.ProtoReflect.Descriptor instead. -func (*CredentialDetails) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{4} -} - -func (x *CredentialDetails) GetSecrets() map[string]string { - if x != nil { - return x.Secrets - } - return nil -} - -type DriverGetInfoRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *DriverGetInfoRequest) Reset() { - *x = DriverGetInfoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *DriverGetInfoRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DriverGetInfoRequest) ProtoMessage() {} - -func (x *DriverGetInfoRequest) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DriverGetInfoRequest.ProtoReflect.Descriptor instead. -func (*DriverGetInfoRequest) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{5} -} - -type DriverGetInfoResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // This field is REQUIRED - // The name MUST follow domain name notation format - // (https://tools.ietf.org/html/rfc1035#section-2.3.1). It SHOULD - // include the plugin's host company name and the plugin name, - // to minimize the possibility of collisions. It MUST be 63 - // characters or less, beginning and ending with an alphanumeric - // character ([a-z0-9A-Z]) with dashes (-), dots (.), and - // alphanumerics between. - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` -} - -func (x *DriverGetInfoResponse) Reset() { - *x = DriverGetInfoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *DriverGetInfoResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DriverGetInfoResponse) ProtoMessage() {} - -func (x *DriverGetInfoResponse) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DriverGetInfoResponse.ProtoReflect.Descriptor instead. -func (*DriverGetInfoResponse) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{6} -} - -func (x *DriverGetInfoResponse) GetName() string { - if x != nil { - return x.Name - } - return "" -} - -type DriverCreateBucketRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // This field is REQUIRED - // name specifies the name of the bucket that should be created. - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - // This field is OPTIONAL - // The caller should treat the values in parameters as opaque. - // The receiver is responsible for parsing and validating the values. - Parameters map[string]string `protobuf:"bytes,2,rep,name=parameters,proto3" json:"parameters,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` -} - -func (x *DriverCreateBucketRequest) Reset() { - *x = DriverCreateBucketRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *DriverCreateBucketRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DriverCreateBucketRequest) ProtoMessage() {} - -func (x *DriverCreateBucketRequest) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DriverCreateBucketRequest.ProtoReflect.Descriptor instead. -func (*DriverCreateBucketRequest) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{7} -} - -func (x *DriverCreateBucketRequest) GetName() string { - if x != nil { - return x.Name - } - return "" -} - -func (x *DriverCreateBucketRequest) GetParameters() map[string]string { - if x != nil { - return x.Parameters - } - return nil -} - -type DriverCreateBucketResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // bucket_id returned here is expected to be the globally unique - // identifier for the bucket in the object storage provider. - BucketId string `protobuf:"bytes,1,opt,name=bucket_id,json=bucketId,proto3" json:"bucket_id,omitempty"` - // bucket_info returned here stores the data specific to the - // bucket required by the object storage provider to connect to the bucket. - BucketInfo *Protocol `protobuf:"bytes,2,opt,name=bucket_info,json=bucketInfo,proto3" json:"bucket_info,omitempty"` -} - -func (x *DriverCreateBucketResponse) Reset() { - *x = DriverCreateBucketResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *DriverCreateBucketResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DriverCreateBucketResponse) ProtoMessage() {} - -func (x *DriverCreateBucketResponse) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DriverCreateBucketResponse.ProtoReflect.Descriptor instead. -func (*DriverCreateBucketResponse) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{8} -} - -func (x *DriverCreateBucketResponse) GetBucketId() string { - if x != nil { - return x.BucketId - } - return "" -} - -func (x *DriverCreateBucketResponse) GetBucketInfo() *Protocol { - if x != nil { - return x.BucketInfo - } - return nil -} - -type DriverDeleteBucketRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // This field is REQUIRED - // bucket_id is a globally unique identifier for the bucket - // in the object storage provider - BucketId string `protobuf:"bytes,1,opt,name=bucket_id,json=bucketId,proto3" json:"bucket_id,omitempty"` - // This field is OPTIONAL - // The caller should treat the values in delete_context as opaque. - // The receiver is responsible for parsing and validating the values. - DeleteContext map[string]string `protobuf:"bytes,2,rep,name=delete_context,json=deleteContext,proto3" json:"delete_context,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` -} - -func (x *DriverDeleteBucketRequest) Reset() { - *x = DriverDeleteBucketRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *DriverDeleteBucketRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DriverDeleteBucketRequest) ProtoMessage() {} - -func (x *DriverDeleteBucketRequest) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DriverDeleteBucketRequest.ProtoReflect.Descriptor instead. -func (*DriverDeleteBucketRequest) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{9} -} - -func (x *DriverDeleteBucketRequest) GetBucketId() string { - if x != nil { - return x.BucketId - } - return "" -} - -func (x *DriverDeleteBucketRequest) GetDeleteContext() map[string]string { - if x != nil { - return x.DeleteContext - } - return nil -} - -type DriverDeleteBucketResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *DriverDeleteBucketResponse) Reset() { - *x = DriverDeleteBucketResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *DriverDeleteBucketResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DriverDeleteBucketResponse) ProtoMessage() {} - -func (x *DriverDeleteBucketResponse) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DriverDeleteBucketResponse.ProtoReflect.Descriptor instead. -func (*DriverDeleteBucketResponse) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{10} -} - -type DriverGrantBucketAccessRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // This field is REQUIRED - // bucket_id is a globally unique identifier for the bucket - // in the object storage provider - BucketId string `protobuf:"bytes,1,opt,name=bucket_id,json=bucketId,proto3" json:"bucket_id,omitempty"` - // This field is REQUIRED - // name field is used to define the name of the bucket access object. - Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` - // This field is REQUIRED - // Requested authentication type for the bucket access. - // Supported authentication types are KEY or IAM. - AuthenticationType AuthenticationType `protobuf:"varint,3,opt,name=authentication_type,json=authenticationType,proto3,enum=cosi.v1alpha1.AuthenticationType" json:"authentication_type,omitempty"` - // This field is OPTIONAL - // The caller should treat the values in parameters as opaque. - // The receiver is responsible for parsing and validating the values. - Parameters map[string]string `protobuf:"bytes,4,rep,name=parameters,proto3" json:"parameters,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` -} - -func (x *DriverGrantBucketAccessRequest) Reset() { - *x = DriverGrantBucketAccessRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *DriverGrantBucketAccessRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DriverGrantBucketAccessRequest) ProtoMessage() {} - -func (x *DriverGrantBucketAccessRequest) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DriverGrantBucketAccessRequest.ProtoReflect.Descriptor instead. -func (*DriverGrantBucketAccessRequest) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{11} -} - -func (x *DriverGrantBucketAccessRequest) GetBucketId() string { - if x != nil { - return x.BucketId - } - return "" -} - -func (x *DriverGrantBucketAccessRequest) GetName() string { - if x != nil { - return x.Name - } - return "" -} - -func (x *DriverGrantBucketAccessRequest) GetAuthenticationType() AuthenticationType { - if x != nil { - return x.AuthenticationType - } - return AuthenticationType_UnknownAuthenticationType -} - -func (x *DriverGrantBucketAccessRequest) GetParameters() map[string]string { - if x != nil { - return x.Parameters - } - return nil -} - -type DriverGrantBucketAccessResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // This field is REQUIRED - // This is the account_id that is being provided access. This will - // be required later to revoke access. - AccountId string `protobuf:"bytes,1,opt,name=account_id,json=accountId,proto3" json:"account_id,omitempty"` - // This field is REQUIRED - // Credentials supplied for accessing the bucket ex: aws access key id and secret, etc. - Credentials map[string]*CredentialDetails `protobuf:"bytes,2,rep,name=credentials,proto3" json:"credentials,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` -} - -func (x *DriverGrantBucketAccessResponse) Reset() { - *x = DriverGrantBucketAccessResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *DriverGrantBucketAccessResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DriverGrantBucketAccessResponse) ProtoMessage() {} - -func (x *DriverGrantBucketAccessResponse) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DriverGrantBucketAccessResponse.ProtoReflect.Descriptor instead. -func (*DriverGrantBucketAccessResponse) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{12} -} - -func (x *DriverGrantBucketAccessResponse) GetAccountId() string { - if x != nil { - return x.AccountId - } - return "" -} - -func (x *DriverGrantBucketAccessResponse) GetCredentials() map[string]*CredentialDetails { - if x != nil { - return x.Credentials - } - return nil -} - -type DriverRevokeBucketAccessRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // This field is REQUIRED - // bucket_id is a globally unique identifier for the bucket - // in the object storage provider. - BucketId string `protobuf:"bytes,1,opt,name=bucket_id,json=bucketId,proto3" json:"bucket_id,omitempty"` - // This field is REQUIRED - // This is the account_id that is having its access revoked. - AccountId string `protobuf:"bytes,2,opt,name=account_id,json=accountId,proto3" json:"account_id,omitempty"` - // This field is OPTIONAL - // The caller should treat the values in revoke_access_context as opaque. - // The receiver is responsible for parsing and validating the values. - RevokeAccessContext map[string]string `protobuf:"bytes,3,rep,name=revoke_access_context,json=revokeAccessContext,proto3" json:"revoke_access_context,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` -} - -func (x *DriverRevokeBucketAccessRequest) Reset() { - *x = DriverRevokeBucketAccessRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *DriverRevokeBucketAccessRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DriverRevokeBucketAccessRequest) ProtoMessage() {} - -func (x *DriverRevokeBucketAccessRequest) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DriverRevokeBucketAccessRequest.ProtoReflect.Descriptor instead. -func (*DriverRevokeBucketAccessRequest) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{13} -} - -func (x *DriverRevokeBucketAccessRequest) GetBucketId() string { - if x != nil { - return x.BucketId - } - return "" -} - -func (x *DriverRevokeBucketAccessRequest) GetAccountId() string { - if x != nil { - return x.AccountId - } - return "" -} - -func (x *DriverRevokeBucketAccessRequest) GetRevokeAccessContext() map[string]string { - if x != nil { - return x.RevokeAccessContext - } - return nil -} - -type DriverRevokeBucketAccessResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *DriverRevokeBucketAccessResponse) Reset() { - *x = DriverRevokeBucketAccessResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *DriverRevokeBucketAccessResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DriverRevokeBucketAccessResponse) ProtoMessage() {} - -func (x *DriverRevokeBucketAccessResponse) ProtoReflect() protoreflect.Message { - mi := &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DriverRevokeBucketAccessResponse.ProtoReflect.Descriptor instead. -func (*DriverRevokeBucketAccessResponse) Descriptor() ([]byte, []int) { - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP(), []int{14} -} - -var file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_extTypes = []protoimpl.ExtensionInfo{ - { - ExtendedType: (*descriptor.EnumOptions)(nil), - ExtensionType: (*bool)(nil), - Field: 1116, - Name: "cosi.v1alpha1.alpha_enum", - Tag: "varint,1116,opt,name=alpha_enum", - Filename: "sigs.k8s.io/container-object-storage-interface-spec/cosi.proto", - }, - { - ExtendedType: (*descriptor.EnumValueOptions)(nil), - ExtensionType: (*bool)(nil), - Field: 1116, - Name: "cosi.v1alpha1.alpha_enum_value", - Tag: "varint,1116,opt,name=alpha_enum_value", - Filename: "sigs.k8s.io/container-object-storage-interface-spec/cosi.proto", - }, - { - ExtendedType: (*descriptor.FieldOptions)(nil), - ExtensionType: (*bool)(nil), - Field: 1115, - Name: "cosi.v1alpha1.cosi_secret", - Tag: "varint,1115,opt,name=cosi_secret", - Filename: "sigs.k8s.io/container-object-storage-interface-spec/cosi.proto", - }, - { - ExtendedType: (*descriptor.FieldOptions)(nil), - ExtensionType: (*bool)(nil), - Field: 1116, - Name: "cosi.v1alpha1.alpha_field", - Tag: "varint,1116,opt,name=alpha_field", - Filename: "sigs.k8s.io/container-object-storage-interface-spec/cosi.proto", - }, - { - ExtendedType: (*descriptor.MessageOptions)(nil), - ExtensionType: (*bool)(nil), - Field: 1116, - Name: "cosi.v1alpha1.alpha_message", - Tag: "varint,1116,opt,name=alpha_message", - Filename: "sigs.k8s.io/container-object-storage-interface-spec/cosi.proto", - }, - { - ExtendedType: (*descriptor.MethodOptions)(nil), - ExtensionType: (*bool)(nil), - Field: 1116, - Name: "cosi.v1alpha1.alpha_method", - Tag: "varint,1116,opt,name=alpha_method", - Filename: "sigs.k8s.io/container-object-storage-interface-spec/cosi.proto", - }, - { - ExtendedType: (*descriptor.ServiceOptions)(nil), - ExtensionType: (*bool)(nil), - Field: 1116, - Name: "cosi.v1alpha1.alpha_service", - Tag: "varint,1116,opt,name=alpha_service", - Filename: "sigs.k8s.io/container-object-storage-interface-spec/cosi.proto", - }, -} - -// Extension fields to descriptor.EnumOptions. -var ( - // Indicates that this enum is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - // - // optional bool alpha_enum = 1116; - E_AlphaEnum = &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_extTypes[0] -) - -// Extension fields to descriptor.EnumValueOptions. -var ( - // Indicates that this enum value is OPTIONAL and part of an - // experimental API that may be deprecated and eventually removed - // between minor releases. - // - // optional bool alpha_enum_value = 1116; - E_AlphaEnumValue = &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_extTypes[1] -) - -// Extension fields to descriptor.FieldOptions. -var ( - // Indicates that a field MAY contain information that is sensitive - // and MUST be treated as such (e.g. not logged). - // - // optional bool cosi_secret = 1115; - E_CosiSecret = &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_extTypes[2] - // Indicates that this field is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - // - // optional bool alpha_field = 1116; - E_AlphaField = &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_extTypes[3] -) - -// Extension fields to descriptor.MessageOptions. -var ( - // Indicates that this message is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - // - // optional bool alpha_message = 1116; - E_AlphaMessage = &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_extTypes[4] -) - -// Extension fields to descriptor.MethodOptions. -var ( - // Indicates that this method is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - // - // optional bool alpha_method = 1116; - E_AlphaMethod = &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_extTypes[5] -) - -// Extension fields to descriptor.ServiceOptions. -var ( - // Indicates that this service is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - // - // optional bool alpha_service = 1116; - E_AlphaService = &file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_extTypes[6] -) - -var File_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto protoreflect.FileDescriptor - -var file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDesc = []byte{ - 0x0a, 0x3e, 0x73, 0x69, 0x67, 0x73, 0x2e, 0x6b, 0x38, 0x73, 0x2e, 0x69, 0x6f, 0x2f, 0x63, 0x6f, - 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2d, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2d, 0x73, - 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x2d, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, - 0x2d, 0x73, 0x70, 0x65, 0x63, 0x2f, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x12, 0x0d, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x1a, - 0x20, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, - 0x2f, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x22, 0x6c, 0x0a, 0x02, 0x53, 0x33, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x67, 0x69, 0x6f, - 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x12, - 0x4e, 0x0a, 0x11, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x76, 0x65, 0x72, - 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x21, 0x2e, 0x63, 0x6f, 0x73, - 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x53, 0x33, 0x53, 0x69, 0x67, - 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x10, 0x73, - 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, - 0x34, 0x0a, 0x09, 0x41, 0x7a, 0x75, 0x72, 0x65, 0x42, 0x6c, 0x6f, 0x62, 0x12, 0x27, 0x0a, 0x0f, - 0x73, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x5f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x73, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x41, 0x63, - 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x77, 0x0a, 0x03, 0x47, 0x43, 0x53, 0x12, 0x28, 0x0a, 0x10, - 0x70, 0x72, 0x69, 0x76, 0x61, 0x74, 0x65, 0x5f, 0x6b, 0x65, 0x79, 0x5f, 0x6e, 0x61, 0x6d, 0x65, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x70, 0x72, 0x69, 0x76, 0x61, 0x74, 0x65, 0x4b, - 0x65, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, - 0x74, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x70, 0x72, 0x6f, 0x6a, - 0x65, 0x63, 0x74, 0x49, 0x64, 0x12, 0x27, 0x0a, 0x0f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, - 0x5f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, - 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x99, - 0x01, 0x0a, 0x08, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x12, 0x23, 0x0a, 0x02, 0x73, - 0x33, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, - 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x53, 0x33, 0x48, 0x00, 0x52, 0x02, 0x73, 0x33, - 0x12, 0x38, 0x0a, 0x09, 0x61, 0x7a, 0x75, 0x72, 0x65, 0x42, 0x6c, 0x6f, 0x62, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, - 0x68, 0x61, 0x31, 0x2e, 0x41, 0x7a, 0x75, 0x72, 0x65, 0x42, 0x6c, 0x6f, 0x62, 0x48, 0x00, 0x52, - 0x09, 0x61, 0x7a, 0x75, 0x72, 0x65, 0x42, 0x6c, 0x6f, 0x62, 0x12, 0x26, 0x0a, 0x03, 0x67, 0x63, - 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, - 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x47, 0x43, 0x53, 0x48, 0x00, 0x52, 0x03, 0x67, - 0x63, 0x73, 0x42, 0x06, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x22, 0x98, 0x01, 0x0a, 0x11, 0x43, - 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, - 0x12, 0x47, 0x0a, 0x07, 0x73, 0x65, 0x63, 0x72, 0x65, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, - 0x0b, 0x32, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, - 0x31, 0x2e, 0x43, 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x44, 0x65, 0x74, 0x61, - 0x69, 0x6c, 0x73, 0x2e, 0x53, 0x65, 0x63, 0x72, 0x65, 0x74, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, - 0x52, 0x07, 0x73, 0x65, 0x63, 0x72, 0x65, 0x74, 0x73, 0x1a, 0x3a, 0x0a, 0x0c, 0x53, 0x65, 0x63, - 0x72, 0x65, 0x74, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, - 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x16, 0x0a, 0x14, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x47, - 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x2b, 0x0a, - 0x15, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0xc8, 0x01, 0x0a, 0x19, 0x44, - 0x72, 0x69, 0x76, 0x65, 0x72, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, - 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x58, 0x0a, 0x0a, - 0x70, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x38, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, - 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x42, 0x75, 0x63, - 0x6b, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, - 0x65, 0x74, 0x65, 0x72, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x0a, 0x70, 0x61, 0x72, 0x61, - 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x1a, 0x3d, 0x0a, 0x0f, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x65, - 0x74, 0x65, 0x72, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, - 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x73, 0x0a, 0x1a, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x62, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x5f, 0x69, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x64, - 0x12, 0x38, 0x0a, 0x0b, 0x62, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x5f, 0x69, 0x6e, 0x66, 0x6f, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, - 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x52, 0x0a, - 0x62, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0xde, 0x01, 0x0a, 0x19, 0x44, - 0x72, 0x69, 0x76, 0x65, 0x72, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, - 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1b, 0x0a, 0x09, 0x62, 0x75, 0x63, 0x6b, - 0x65, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x75, 0x63, - 0x6b, 0x65, 0x74, 0x49, 0x64, 0x12, 0x62, 0x0a, 0x0e, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x5f, - 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x3b, 0x2e, - 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, - 0x69, 0x76, 0x65, 0x72, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x43, 0x6f, - 0x6e, 0x74, 0x65, 0x78, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x0d, 0x64, 0x65, 0x6c, 0x65, - 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x1a, 0x40, 0x0a, 0x12, 0x44, 0x65, 0x6c, - 0x65, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, - 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, - 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x1c, 0x0a, 0x1a, 0x44, - 0x72, 0x69, 0x76, 0x65, 0x72, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, - 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xc3, 0x02, 0x0a, 0x1e, 0x44, 0x72, - 0x69, 0x76, 0x65, 0x72, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, - 0x63, 0x63, 0x65, 0x73, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1b, 0x0a, 0x09, - 0x62, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x08, 0x62, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, - 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x52, 0x0a, - 0x13, 0x61, 0x75, 0x74, 0x68, 0x65, 0x6e, 0x74, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, - 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x21, 0x2e, 0x63, 0x6f, 0x73, - 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x41, 0x75, 0x74, 0x68, 0x65, - 0x6e, 0x74, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x12, 0x61, - 0x75, 0x74, 0x68, 0x65, 0x6e, 0x74, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x79, 0x70, - 0x65, 0x12, 0x5d, 0x0a, 0x0a, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x18, - 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x3d, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, - 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x47, 0x72, 0x61, 0x6e, - 0x74, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x45, - 0x6e, 0x74, 0x72, 0x79, 0x52, 0x0a, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, - 0x1a, 0x3d, 0x0a, 0x0f, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x45, 0x6e, - 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, - 0x85, 0x02, 0x0a, 0x1f, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x42, - 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x69, - 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, - 0x49, 0x64, 0x12, 0x61, 0x0a, 0x0b, 0x63, 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, - 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x3f, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, - 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x47, 0x72, - 0x61, 0x6e, 0x74, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x43, 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, - 0x61, 0x6c, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x0b, 0x63, 0x72, 0x65, 0x64, 0x65, 0x6e, - 0x74, 0x69, 0x61, 0x6c, 0x73, 0x1a, 0x60, 0x0a, 0x10, 0x43, 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, - 0x69, 0x61, 0x6c, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x36, 0x0a, 0x05, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x63, 0x6f, 0x73, - 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x43, 0x72, 0x65, 0x64, 0x65, - 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x52, 0x05, 0x76, 0x61, - 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xa2, 0x02, 0x0a, 0x1f, 0x44, 0x72, 0x69, 0x76, - 0x65, 0x72, 0x52, 0x65, 0x76, 0x6f, 0x6b, 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, 0x63, - 0x63, 0x65, 0x73, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1b, 0x0a, 0x09, 0x62, - 0x75, 0x63, 0x6b, 0x65, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, - 0x62, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x49, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x63, 0x63, 0x6f, - 0x75, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x63, - 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x7b, 0x0a, 0x15, 0x72, 0x65, 0x76, 0x6f, 0x6b, - 0x65, 0x5f, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, - 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x47, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, - 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x76, - 0x6f, 0x6b, 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x52, 0x65, 0x76, 0x6f, 0x6b, 0x65, 0x41, 0x63, 0x63, - 0x65, 0x73, 0x73, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, - 0x13, 0x72, 0x65, 0x76, 0x6f, 0x6b, 0x65, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x43, 0x6f, 0x6e, - 0x74, 0x65, 0x78, 0x74, 0x1a, 0x46, 0x0a, 0x18, 0x52, 0x65, 0x76, 0x6f, 0x6b, 0x65, 0x41, 0x63, - 0x63, 0x65, 0x73, 0x73, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, - 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, - 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x22, 0x0a, 0x20, - 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x76, 0x6f, 0x6b, 0x65, 0x42, 0x75, 0x63, 0x6b, - 0x65, 0x74, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x2a, 0x3e, 0x0a, 0x12, 0x53, 0x33, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x56, - 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x10, 0x55, 0x6e, 0x6b, 0x6e, 0x6f, 0x77, - 0x6e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, - 0x53, 0x33, 0x56, 0x32, 0x10, 0x01, 0x12, 0x08, 0x0a, 0x04, 0x53, 0x33, 0x56, 0x34, 0x10, 0x02, - 0x2a, 0x71, 0x0a, 0x19, 0x41, 0x6e, 0x6f, 0x6e, 0x79, 0x6d, 0x6f, 0x75, 0x73, 0x42, 0x75, 0x63, - 0x6b, 0x65, 0x74, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x4d, 0x6f, 0x64, 0x65, 0x12, 0x1b, 0x0a, - 0x17, 0x55, 0x6e, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, 0x63, - 0x63, 0x65, 0x73, 0x73, 0x4d, 0x6f, 0x64, 0x65, 0x10, 0x00, 0x12, 0x0b, 0x0a, 0x07, 0x50, 0x72, - 0x69, 0x76, 0x61, 0x74, 0x65, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x52, 0x65, 0x61, 0x64, 0x4f, - 0x6e, 0x6c, 0x79, 0x10, 0x02, 0x12, 0x0d, 0x0a, 0x09, 0x57, 0x72, 0x69, 0x74, 0x65, 0x4f, 0x6e, - 0x6c, 0x79, 0x10, 0x03, 0x12, 0x0d, 0x0a, 0x09, 0x52, 0x65, 0x61, 0x64, 0x57, 0x72, 0x69, 0x74, - 0x65, 0x10, 0x04, 0x2a, 0x45, 0x0a, 0x12, 0x41, 0x75, 0x74, 0x68, 0x65, 0x6e, 0x74, 0x69, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1d, 0x0a, 0x19, 0x55, 0x6e, 0x6b, - 0x6e, 0x6f, 0x77, 0x6e, 0x41, 0x75, 0x74, 0x68, 0x65, 0x6e, 0x74, 0x69, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x4b, 0x65, 0x79, 0x10, - 0x01, 0x12, 0x07, 0x0a, 0x03, 0x49, 0x41, 0x4d, 0x10, 0x02, 0x32, 0x68, 0x0a, 0x08, 0x49, 0x64, - 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x12, 0x5c, 0x0a, 0x0d, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, - 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x23, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, - 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x47, 0x65, - 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x2e, 0x63, - 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, - 0x76, 0x65, 0x72, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x00, 0x32, 0xde, 0x03, 0x0a, 0x0b, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, - 0x6f, 0x6e, 0x65, 0x72, 0x12, 0x6b, 0x0a, 0x12, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x43, 0x72, - 0x65, 0x61, 0x74, 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x28, 0x2e, 0x63, 0x6f, 0x73, - 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, - 0x72, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, - 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x00, 0x12, 0x6b, 0x0a, 0x12, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x44, 0x65, 0x6c, 0x65, 0x74, - 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x28, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, - 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x44, 0x65, - 0x6c, 0x65, 0x74, 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x29, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, - 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x42, 0x75, - 0x63, 0x6b, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x78, - 0x0a, 0x17, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x42, 0x75, 0x63, - 0x6b, 0x65, 0x74, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x12, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x69, - 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, - 0x47, 0x72, 0x61, 0x6e, 0x74, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, 0x63, 0x63, 0x65, 0x73, - 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2e, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, - 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x47, - 0x72, 0x61, 0x6e, 0x74, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x7b, 0x0a, 0x18, 0x44, 0x72, 0x69, 0x76, - 0x65, 0x72, 0x52, 0x65, 0x76, 0x6f, 0x6b, 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, 0x63, - 0x63, 0x65, 0x73, 0x73, 0x12, 0x2e, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, - 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x76, 0x6f, 0x6b, - 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2f, 0x2e, 0x63, 0x6f, 0x73, 0x69, 0x2e, 0x76, 0x31, 0x61, 0x6c, - 0x70, 0x68, 0x61, 0x31, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x76, 0x6f, 0x6b, - 0x65, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x3a, 0x3c, 0x0a, 0x0a, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x5f, 0x65, - 0x6e, 0x75, 0x6d, 0x12, 0x1c, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6e, 0x75, 0x6d, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, - 0x73, 0x18, 0xdc, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x45, - 0x6e, 0x75, 0x6d, 0x3a, 0x4c, 0x0a, 0x10, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x5f, 0x65, 0x6e, 0x75, - 0x6d, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x21, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6e, 0x75, 0x6d, 0x56, 0x61, - 0x6c, 0x75, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0xdc, 0x08, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x0e, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x45, 0x6e, 0x75, 0x6d, 0x56, 0x61, 0x6c, 0x75, - 0x65, 0x3a, 0x3f, 0x0a, 0x0b, 0x63, 0x6f, 0x73, 0x69, 0x5f, 0x73, 0x65, 0x63, 0x72, 0x65, 0x74, - 0x12, 0x1d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, - 0xdb, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x63, 0x6f, 0x73, 0x69, 0x53, 0x65, 0x63, 0x72, - 0x65, 0x74, 0x3a, 0x3f, 0x0a, 0x0b, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x5f, 0x66, 0x69, 0x65, 0x6c, - 0x64, 0x12, 0x1d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, - 0x18, 0xdc, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x46, 0x69, - 0x65, 0x6c, 0x64, 0x3a, 0x45, 0x0a, 0x0d, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x5f, 0x6d, 0x65, 0x73, - 0x73, 0x61, 0x67, 0x65, 0x12, 0x1f, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x4f, 0x70, - 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0xdc, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0c, 0x61, 0x6c, - 0x70, 0x68, 0x61, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x3a, 0x42, 0x0a, 0x0c, 0x61, 0x6c, - 0x70, 0x68, 0x61, 0x5f, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x12, 0x1e, 0x2e, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x4d, 0x65, 0x74, - 0x68, 0x6f, 0x64, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0xdc, 0x08, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x0b, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x3a, 0x45, - 0x0a, 0x0d, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, - 0x1f, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2e, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, - 0x18, 0xdc, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0c, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x53, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x42, 0x3a, 0x5a, 0x38, 0x73, 0x69, 0x67, 0x73, 0x2e, 0x6b, 0x38, - 0x73, 0x2e, 0x69, 0x6f, 0x2f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2d, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2d, 0x73, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x2d, 0x69, 0x6e, - 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x2d, 0x73, 0x70, 0x65, 0x63, 0x3b, 0x63, 0x6f, 0x73, - 0x69, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, -} - -var ( - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescOnce sync.Once - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescData = file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDesc -) - -func file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescGZIP() []byte { - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescOnce.Do(func() { - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescData = protoimpl.X.CompressGZIP(file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescData) - }) - return file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDescData -} - -var file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_enumTypes = make([]protoimpl.EnumInfo, 3) -var file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes = make([]protoimpl.MessageInfo, 21) -var file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_goTypes = []interface{}{ - (S3SignatureVersion)(0), // 0: cosi.v1alpha1.S3SignatureVersion - (AnonymousBucketAccessMode)(0), // 1: cosi.v1alpha1.AnonymousBucketAccessMode - (AuthenticationType)(0), // 2: cosi.v1alpha1.AuthenticationType - (*S3)(nil), // 3: cosi.v1alpha1.S3 - (*AzureBlob)(nil), // 4: cosi.v1alpha1.AzureBlob - (*GCS)(nil), // 5: cosi.v1alpha1.GCS - (*Protocol)(nil), // 6: cosi.v1alpha1.Protocol - (*CredentialDetails)(nil), // 7: cosi.v1alpha1.CredentialDetails - (*DriverGetInfoRequest)(nil), // 8: cosi.v1alpha1.DriverGetInfoRequest - (*DriverGetInfoResponse)(nil), // 9: cosi.v1alpha1.DriverGetInfoResponse - (*DriverCreateBucketRequest)(nil), // 10: cosi.v1alpha1.DriverCreateBucketRequest - (*DriverCreateBucketResponse)(nil), // 11: cosi.v1alpha1.DriverCreateBucketResponse - (*DriverDeleteBucketRequest)(nil), // 12: cosi.v1alpha1.DriverDeleteBucketRequest - (*DriverDeleteBucketResponse)(nil), // 13: cosi.v1alpha1.DriverDeleteBucketResponse - (*DriverGrantBucketAccessRequest)(nil), // 14: cosi.v1alpha1.DriverGrantBucketAccessRequest - (*DriverGrantBucketAccessResponse)(nil), // 15: cosi.v1alpha1.DriverGrantBucketAccessResponse - (*DriverRevokeBucketAccessRequest)(nil), // 16: cosi.v1alpha1.DriverRevokeBucketAccessRequest - (*DriverRevokeBucketAccessResponse)(nil), // 17: cosi.v1alpha1.DriverRevokeBucketAccessResponse - nil, // 18: cosi.v1alpha1.CredentialDetails.SecretsEntry - nil, // 19: cosi.v1alpha1.DriverCreateBucketRequest.ParametersEntry - nil, // 20: cosi.v1alpha1.DriverDeleteBucketRequest.DeleteContextEntry - nil, // 21: cosi.v1alpha1.DriverGrantBucketAccessRequest.ParametersEntry - nil, // 22: cosi.v1alpha1.DriverGrantBucketAccessResponse.CredentialsEntry - nil, // 23: cosi.v1alpha1.DriverRevokeBucketAccessRequest.RevokeAccessContextEntry - (*descriptor.EnumOptions)(nil), // 24: google.protobuf.EnumOptions - (*descriptor.EnumValueOptions)(nil), // 25: google.protobuf.EnumValueOptions - (*descriptor.FieldOptions)(nil), // 26: google.protobuf.FieldOptions - (*descriptor.MessageOptions)(nil), // 27: google.protobuf.MessageOptions - (*descriptor.MethodOptions)(nil), // 28: google.protobuf.MethodOptions - (*descriptor.ServiceOptions)(nil), // 29: google.protobuf.ServiceOptions -} -var file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_depIdxs = []int32{ - 0, // 0: cosi.v1alpha1.S3.signature_version:type_name -> cosi.v1alpha1.S3SignatureVersion - 3, // 1: cosi.v1alpha1.Protocol.s3:type_name -> cosi.v1alpha1.S3 - 4, // 2: cosi.v1alpha1.Protocol.azureBlob:type_name -> cosi.v1alpha1.AzureBlob - 5, // 3: cosi.v1alpha1.Protocol.gcs:type_name -> cosi.v1alpha1.GCS - 18, // 4: cosi.v1alpha1.CredentialDetails.secrets:type_name -> cosi.v1alpha1.CredentialDetails.SecretsEntry - 19, // 5: cosi.v1alpha1.DriverCreateBucketRequest.parameters:type_name -> cosi.v1alpha1.DriverCreateBucketRequest.ParametersEntry - 6, // 6: cosi.v1alpha1.DriverCreateBucketResponse.bucket_info:type_name -> cosi.v1alpha1.Protocol - 20, // 7: cosi.v1alpha1.DriverDeleteBucketRequest.delete_context:type_name -> cosi.v1alpha1.DriverDeleteBucketRequest.DeleteContextEntry - 2, // 8: cosi.v1alpha1.DriverGrantBucketAccessRequest.authentication_type:type_name -> cosi.v1alpha1.AuthenticationType - 21, // 9: cosi.v1alpha1.DriverGrantBucketAccessRequest.parameters:type_name -> cosi.v1alpha1.DriverGrantBucketAccessRequest.ParametersEntry - 22, // 10: cosi.v1alpha1.DriverGrantBucketAccessResponse.credentials:type_name -> cosi.v1alpha1.DriverGrantBucketAccessResponse.CredentialsEntry - 23, // 11: cosi.v1alpha1.DriverRevokeBucketAccessRequest.revoke_access_context:type_name -> cosi.v1alpha1.DriverRevokeBucketAccessRequest.RevokeAccessContextEntry - 7, // 12: cosi.v1alpha1.DriverGrantBucketAccessResponse.CredentialsEntry.value:type_name -> cosi.v1alpha1.CredentialDetails - 24, // 13: cosi.v1alpha1.alpha_enum:extendee -> google.protobuf.EnumOptions - 25, // 14: cosi.v1alpha1.alpha_enum_value:extendee -> google.protobuf.EnumValueOptions - 26, // 15: cosi.v1alpha1.cosi_secret:extendee -> google.protobuf.FieldOptions - 26, // 16: cosi.v1alpha1.alpha_field:extendee -> google.protobuf.FieldOptions - 27, // 17: cosi.v1alpha1.alpha_message:extendee -> google.protobuf.MessageOptions - 28, // 18: cosi.v1alpha1.alpha_method:extendee -> google.protobuf.MethodOptions - 29, // 19: cosi.v1alpha1.alpha_service:extendee -> google.protobuf.ServiceOptions - 8, // 20: cosi.v1alpha1.Identity.DriverGetInfo:input_type -> cosi.v1alpha1.DriverGetInfoRequest - 10, // 21: cosi.v1alpha1.Provisioner.DriverCreateBucket:input_type -> cosi.v1alpha1.DriverCreateBucketRequest - 12, // 22: cosi.v1alpha1.Provisioner.DriverDeleteBucket:input_type -> cosi.v1alpha1.DriverDeleteBucketRequest - 14, // 23: cosi.v1alpha1.Provisioner.DriverGrantBucketAccess:input_type -> cosi.v1alpha1.DriverGrantBucketAccessRequest - 16, // 24: cosi.v1alpha1.Provisioner.DriverRevokeBucketAccess:input_type -> cosi.v1alpha1.DriverRevokeBucketAccessRequest - 9, // 25: cosi.v1alpha1.Identity.DriverGetInfo:output_type -> cosi.v1alpha1.DriverGetInfoResponse - 11, // 26: cosi.v1alpha1.Provisioner.DriverCreateBucket:output_type -> cosi.v1alpha1.DriverCreateBucketResponse - 13, // 27: cosi.v1alpha1.Provisioner.DriverDeleteBucket:output_type -> cosi.v1alpha1.DriverDeleteBucketResponse - 15, // 28: cosi.v1alpha1.Provisioner.DriverGrantBucketAccess:output_type -> cosi.v1alpha1.DriverGrantBucketAccessResponse - 17, // 29: cosi.v1alpha1.Provisioner.DriverRevokeBucketAccess:output_type -> cosi.v1alpha1.DriverRevokeBucketAccessResponse - 25, // [25:30] is the sub-list for method output_type - 20, // [20:25] is the sub-list for method input_type - 20, // [20:20] is the sub-list for extension type_name - 13, // [13:20] is the sub-list for extension extendee - 0, // [0:13] is the sub-list for field type_name -} - -func init() { file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_init() } -func file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_init() { - if File_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto != nil { - return - } - if !protoimpl.UnsafeEnabled { - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*S3); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*AzureBlob); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GCS); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Protocol); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CredentialDetails); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverGetInfoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverGetInfoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverCreateBucketRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverCreateBucketResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverDeleteBucketRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverDeleteBucketResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverGrantBucketAccessRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverGrantBucketAccessResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverRevokeBucketAccessRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverRevokeBucketAccessResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes[3].OneofWrappers = []interface{}{ - (*Protocol_S3)(nil), - (*Protocol_AzureBlob)(nil), - (*Protocol_Gcs)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDesc, - NumEnums: 3, - NumMessages: 21, - NumExtensions: 7, - NumServices: 2, - }, - GoTypes: file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_goTypes, - DependencyIndexes: file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_depIdxs, - EnumInfos: file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_enumTypes, - MessageInfos: file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_msgTypes, - ExtensionInfos: file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_extTypes, - }.Build() - File_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto = out.File - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_rawDesc = nil - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_goTypes = nil - file_sigs_k8s_io_container_object_storage_interface_spec_cosi_proto_depIdxs = nil -} - -// Reference imports to suppress errors if they are not otherwise used. -var _ context.Context -var _ grpc.ClientConnInterface - -// 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.SupportPackageIsVersion6 - -// IdentityClient is the client API for Identity service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. -type IdentityClient interface { - // This call is meant to retrieve the unique provisioner Identity. - // This identity will have to be set in BucketClaim.DriverName field in order to invoke this specific provisioner. - DriverGetInfo(ctx context.Context, in *DriverGetInfoRequest, opts ...grpc.CallOption) (*DriverGetInfoResponse, error) -} - -type identityClient struct { - cc grpc.ClientConnInterface -} - -func NewIdentityClient(cc grpc.ClientConnInterface) IdentityClient { - return &identityClient{cc} -} - -func (c *identityClient) DriverGetInfo(ctx context.Context, in *DriverGetInfoRequest, opts ...grpc.CallOption) (*DriverGetInfoResponse, error) { - out := new(DriverGetInfoResponse) - err := c.cc.Invoke(ctx, "/cosi.v1alpha1.Identity/DriverGetInfo", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// IdentityServer is the server API for Identity service. -type IdentityServer interface { - // This call is meant to retrieve the unique provisioner Identity. - // This identity will have to be set in BucketClaim.DriverName field in order to invoke this specific provisioner. - DriverGetInfo(context.Context, *DriverGetInfoRequest) (*DriverGetInfoResponse, error) -} - -// UnimplementedIdentityServer can be embedded to have forward compatible implementations. -type UnimplementedIdentityServer struct { -} - -func (*UnimplementedIdentityServer) DriverGetInfo(context.Context, *DriverGetInfoRequest) (*DriverGetInfoResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method DriverGetInfo not implemented") -} - -func RegisterIdentityServer(s *grpc.Server, srv IdentityServer) { - s.RegisterService(&_Identity_serviceDesc, srv) -} - -func _Identity_DriverGetInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(DriverGetInfoRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(IdentityServer).DriverGetInfo(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/cosi.v1alpha1.Identity/DriverGetInfo", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(IdentityServer).DriverGetInfo(ctx, req.(*DriverGetInfoRequest)) - } - return interceptor(ctx, in, info, handler) -} - -var _Identity_serviceDesc = grpc.ServiceDesc{ - ServiceName: "cosi.v1alpha1.Identity", - HandlerType: (*IdentityServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "DriverGetInfo", - Handler: _Identity_DriverGetInfo_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "sigs.k8s.io/container-object-storage-interface-spec/cosi.proto", -} - -// ProvisionerClient is the client API for Provisioner service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. -type ProvisionerClient interface { - // This call is made to create the bucket in the backend. - // This call is idempotent - // 1. If a bucket that matches both name and parameters already exists, then OK (success) must be returned. - // 2. If a bucket by same name, but different parameters is provided, then the appropriate error code ALREADY_EXISTS must be returned. - DriverCreateBucket(ctx context.Context, in *DriverCreateBucketRequest, opts ...grpc.CallOption) (*DriverCreateBucketResponse, error) - // This call is made to delete the bucket in the backend. - // If the bucket has already been deleted, then no error should be returned. - DriverDeleteBucket(ctx context.Context, in *DriverDeleteBucketRequest, opts ...grpc.CallOption) (*DriverDeleteBucketResponse, error) - // This call grants access to an account. The account_name in the request shall be used as a unique identifier to create credentials. - // The account_id returned in the response will be used as the unique identifier for deleting this access when calling DriverRevokeBucketAccess. - DriverGrantBucketAccess(ctx context.Context, in *DriverGrantBucketAccessRequest, opts ...grpc.CallOption) (*DriverGrantBucketAccessResponse, error) - // This call revokes all access to a particular bucket from a principal. - DriverRevokeBucketAccess(ctx context.Context, in *DriverRevokeBucketAccessRequest, opts ...grpc.CallOption) (*DriverRevokeBucketAccessResponse, error) -} - -type provisionerClient struct { - cc grpc.ClientConnInterface -} - -func NewProvisionerClient(cc grpc.ClientConnInterface) ProvisionerClient { - return &provisionerClient{cc} -} - -func (c *provisionerClient) DriverCreateBucket(ctx context.Context, in *DriverCreateBucketRequest, opts ...grpc.CallOption) (*DriverCreateBucketResponse, error) { - out := new(DriverCreateBucketResponse) - err := c.cc.Invoke(ctx, "/cosi.v1alpha1.Provisioner/DriverCreateBucket", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *provisionerClient) DriverDeleteBucket(ctx context.Context, in *DriverDeleteBucketRequest, opts ...grpc.CallOption) (*DriverDeleteBucketResponse, error) { - out := new(DriverDeleteBucketResponse) - err := c.cc.Invoke(ctx, "/cosi.v1alpha1.Provisioner/DriverDeleteBucket", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *provisionerClient) DriverGrantBucketAccess(ctx context.Context, in *DriverGrantBucketAccessRequest, opts ...grpc.CallOption) (*DriverGrantBucketAccessResponse, error) { - out := new(DriverGrantBucketAccessResponse) - err := c.cc.Invoke(ctx, "/cosi.v1alpha1.Provisioner/DriverGrantBucketAccess", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *provisionerClient) DriverRevokeBucketAccess(ctx context.Context, in *DriverRevokeBucketAccessRequest, opts ...grpc.CallOption) (*DriverRevokeBucketAccessResponse, error) { - out := new(DriverRevokeBucketAccessResponse) - err := c.cc.Invoke(ctx, "/cosi.v1alpha1.Provisioner/DriverRevokeBucketAccess", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// ProvisionerServer is the server API for Provisioner service. -type ProvisionerServer interface { - // This call is made to create the bucket in the backend. - // This call is idempotent - // 1. If a bucket that matches both name and parameters already exists, then OK (success) must be returned. - // 2. If a bucket by same name, but different parameters is provided, then the appropriate error code ALREADY_EXISTS must be returned. - DriverCreateBucket(context.Context, *DriverCreateBucketRequest) (*DriverCreateBucketResponse, error) - // This call is made to delete the bucket in the backend. - // If the bucket has already been deleted, then no error should be returned. - DriverDeleteBucket(context.Context, *DriverDeleteBucketRequest) (*DriverDeleteBucketResponse, error) - // This call grants access to an account. The account_name in the request shall be used as a unique identifier to create credentials. - // The account_id returned in the response will be used as the unique identifier for deleting this access when calling DriverRevokeBucketAccess. - DriverGrantBucketAccess(context.Context, *DriverGrantBucketAccessRequest) (*DriverGrantBucketAccessResponse, error) - // This call revokes all access to a particular bucket from a principal. - DriverRevokeBucketAccess(context.Context, *DriverRevokeBucketAccessRequest) (*DriverRevokeBucketAccessResponse, error) -} - -// UnimplementedProvisionerServer can be embedded to have forward compatible implementations. -type UnimplementedProvisionerServer struct { -} - -func (*UnimplementedProvisionerServer) DriverCreateBucket(context.Context, *DriverCreateBucketRequest) (*DriverCreateBucketResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method DriverCreateBucket not implemented") -} -func (*UnimplementedProvisionerServer) DriverDeleteBucket(context.Context, *DriverDeleteBucketRequest) (*DriverDeleteBucketResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method DriverDeleteBucket not implemented") -} -func (*UnimplementedProvisionerServer) DriverGrantBucketAccess(context.Context, *DriverGrantBucketAccessRequest) (*DriverGrantBucketAccessResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method DriverGrantBucketAccess not implemented") -} -func (*UnimplementedProvisionerServer) DriverRevokeBucketAccess(context.Context, *DriverRevokeBucketAccessRequest) (*DriverRevokeBucketAccessResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method DriverRevokeBucketAccess not implemented") -} - -func RegisterProvisionerServer(s *grpc.Server, srv ProvisionerServer) { - s.RegisterService(&_Provisioner_serviceDesc, srv) -} - -func _Provisioner_DriverCreateBucket_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(DriverCreateBucketRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ProvisionerServer).DriverCreateBucket(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/cosi.v1alpha1.Provisioner/DriverCreateBucket", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ProvisionerServer).DriverCreateBucket(ctx, req.(*DriverCreateBucketRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _Provisioner_DriverDeleteBucket_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(DriverDeleteBucketRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ProvisionerServer).DriverDeleteBucket(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/cosi.v1alpha1.Provisioner/DriverDeleteBucket", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ProvisionerServer).DriverDeleteBucket(ctx, req.(*DriverDeleteBucketRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _Provisioner_DriverGrantBucketAccess_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(DriverGrantBucketAccessRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ProvisionerServer).DriverGrantBucketAccess(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/cosi.v1alpha1.Provisioner/DriverGrantBucketAccess", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ProvisionerServer).DriverGrantBucketAccess(ctx, req.(*DriverGrantBucketAccessRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _Provisioner_DriverRevokeBucketAccess_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(DriverRevokeBucketAccessRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ProvisionerServer).DriverRevokeBucketAccess(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/cosi.v1alpha1.Provisioner/DriverRevokeBucketAccess", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ProvisionerServer).DriverRevokeBucketAccess(ctx, req.(*DriverRevokeBucketAccessRequest)) - } - return interceptor(ctx, in, info, handler) -} - -var _Provisioner_serviceDesc = grpc.ServiceDesc{ - ServiceName: "cosi.v1alpha1.Provisioner", - HandlerType: (*ProvisionerServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "DriverCreateBucket", - Handler: _Provisioner_DriverCreateBucket_Handler, - }, - { - MethodName: "DriverDeleteBucket", - Handler: _Provisioner_DriverDeleteBucket_Handler, - }, - { - MethodName: "DriverGrantBucketAccess", - Handler: _Provisioner_DriverGrantBucketAccess_Handler, - }, - { - MethodName: "DriverRevokeBucketAccess", - Handler: _Provisioner_DriverRevokeBucketAccess_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "sigs.k8s.io/container-object-storage-interface-spec/cosi.proto", -} diff --git a/pkg/imported-grpc/cosi.pb.json.go b/pkg/imported-grpc/cosi.pb.json.go deleted file mode 100644 index 8d30f4fc..00000000 --- a/pkg/imported-grpc/cosi.pb.json.go +++ /dev/null @@ -1,248 +0,0 @@ -// Code generated by protoc-gen-go-json. DO NOT EDIT. -// source: sigs.k8s.io/container-object-storage-interface-spec/cosi.proto - -package cosi - -import ( - "google.golang.org/protobuf/encoding/protojson" -) - -// MarshalJSON implements json.Marshaler -func (msg *S3) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *S3) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *AzureBlob) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *AzureBlob) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *GCS) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *GCS) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *Protocol) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *Protocol) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *CredentialDetails) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *CredentialDetails) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *DriverGetInfoRequest) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *DriverGetInfoRequest) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *DriverGetInfoResponse) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *DriverGetInfoResponse) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *DriverCreateBucketRequest) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *DriverCreateBucketRequest) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *DriverCreateBucketResponse) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *DriverCreateBucketResponse) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *DriverDeleteBucketRequest) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *DriverDeleteBucketRequest) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *DriverDeleteBucketResponse) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *DriverDeleteBucketResponse) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *DriverGrantBucketAccessRequest) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *DriverGrantBucketAccessRequest) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *DriverGrantBucketAccessResponse) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *DriverGrantBucketAccessResponse) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *DriverRevokeBucketAccessRequest) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *DriverRevokeBucketAccessRequest) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} - -// MarshalJSON implements json.Marshaler -func (msg *DriverRevokeBucketAccessResponse) MarshalJSON() ([]byte, error) { - return protojson.MarshalOptions{ - UseEnumNumbers: false, - EmitUnpopulated: true, - UseProtoNames: false, - }.Marshal(msg) -} - -// UnmarshalJSON implements json.Unmarshaler -func (msg *DriverRevokeBucketAccessResponse) UnmarshalJSON(b []byte) error { - return protojson.UnmarshalOptions{ - DiscardUnknown: false, - }.Unmarshal(b, msg) -} diff --git a/pkg/imported-grpc/cosi.proto b/pkg/imported-grpc/cosi.proto deleted file mode 100644 index ca55a5ff..00000000 --- a/pkg/imported-grpc/cosi.proto +++ /dev/null @@ -1,245 +0,0 @@ -// Code generated by make; DO NOT EDIT. -syntax = "proto3"; -package cosi.v1alpha1; - -import "google/protobuf/descriptor.proto"; - -option go_package = "sigs.k8s.io/container-object-storage-interface-spec;cosi"; - -extend google.protobuf.EnumOptions { - // Indicates that this enum is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - bool alpha_enum = 1116; -} - -extend google.protobuf.EnumValueOptions { - // Indicates that this enum value is OPTIONAL and part of an - // experimental API that may be deprecated and eventually removed - // between minor releases. - bool alpha_enum_value = 1116; -} - -extend google.protobuf.FieldOptions { - // Indicates that a field MAY contain information that is sensitive - // and MUST be treated as such (e.g. not logged). - bool cosi_secret = 1115; - - // Indicates that this field is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - bool alpha_field = 1116; -} - -extend google.protobuf.MessageOptions { - // Indicates that this message is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - bool alpha_message = 1116; -} - -extend google.protobuf.MethodOptions { - // Indicates that this method is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - bool alpha_method = 1116; -} - -extend google.protobuf.ServiceOptions { - // Indicates that this service is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - bool alpha_service = 1116; -} - -service Identity { - // This call is meant to retrieve the unique provisioner Identity. - // This identity will have to be set in BucketClaim.DriverName field in order to invoke this specific provisioner. - rpc DriverGetInfo (DriverGetInfoRequest) returns (DriverGetInfoResponse) {} -} - -service Provisioner { - // This call is made to create the bucket in the backend. - // This call is idempotent - // 1. If a bucket that matches both name and parameters already exists, then OK (success) must be returned. - // 2. If a bucket by same name, but different parameters is provided, then the appropriate error code ALREADY_EXISTS must be returned. - rpc DriverCreateBucket (DriverCreateBucketRequest) returns (DriverCreateBucketResponse) {} - // This call is made to delete the bucket in the backend. - // If the bucket has already been deleted, then no error should be returned. - rpc DriverDeleteBucket (DriverDeleteBucketRequest) returns (DriverDeleteBucketResponse) {} - - // This call grants access to an account. The account_name in the request shall be used as a unique identifier to create credentials. - // The account_id returned in the response will be used as the unique identifier for deleting this access when calling DriverRevokeBucketAccess. - rpc DriverGrantBucketAccess (DriverGrantBucketAccessRequest) returns (DriverGrantBucketAccessResponse); - // This call revokes all access to a particular bucket from a principal. - rpc DriverRevokeBucketAccess (DriverRevokeBucketAccessRequest) returns (DriverRevokeBucketAccessResponse); -} - -// S3SignatureVersion is the version of the signing algorithm for all s3 requests -enum S3SignatureVersion { - UnknownSignature = 0; - // S3V2, Signature version v2 - S3V2 = 1; - // S3V4, Signature version v4 - S3V4 = 2; -} - -enum AnonymousBucketAccessMode { - UnknownBucketAccessMode = 0; - // Default, disallow uncredentialed access to the backend storage. - Private = 1; - // Read only, uncredentialed users can call ListBucket and GetObject. - ReadOnly = 2; - // Write only, uncredentialed users can only call PutObject. - WriteOnly = 3; - // Read/Write, uncredentialed users can read objects as well as PutObject. - ReadWrite = 4; -} - -enum AuthenticationType { - UnknownAuthenticationType = 0; - // Default, KEY based authentication. - Key = 1; - // Storageaccount based authentication. - IAM = 2; -} - -message S3 { - // region denotes the geographical region where the S3 server is running - string region = 1; - // signature_version denotes the signature version for signing all s3 requests - S3SignatureVersion signature_version = 2; -} - -message AzureBlob { - // storage_account is the id of the azure storage account - string storage_account = 1; -} - -message GCS { - // private_key_name denotes the name of the private key in the storage backend - string private_key_name = 1; - // project_id denotes the name of the project id in the storage backend - string project_id = 2; - // service_account denotes the name of the service account in the storage backend - string service_account = 3; -} - -message Protocol { - oneof type { - S3 s3 = 1; - AzureBlob azureBlob = 2; - GCS gcs = 3; - } -} - -message CredentialDetails { - // map of the details in the secrets for the protocol string - map secrets = 1; -} - -message DriverGetInfoRequest { - // Intentionally left blank -} - -message DriverGetInfoResponse { - // This field is REQUIRED - // The name MUST follow domain name notation format - // (https://tools.ietf.org/html/rfc1035#section-2.3.1). It SHOULD - // include the plugin's host company name and the plugin name, - // to minimize the possibility of collisions. It MUST be 63 - // characters or less, beginning and ending with an alphanumeric - // character ([a-z0-9A-Z]) with dashes (-), dots (.), and - // alphanumerics between. - string name = 1; -} - -message DriverCreateBucketRequest { - // This field is REQUIRED - // name specifies the name of the bucket that should be created. - string name = 1; - - // This field is OPTIONAL - // The caller should treat the values in parameters as opaque. - // The receiver is responsible for parsing and validating the values. - map parameters = 2; -} - -message DriverCreateBucketResponse { - // bucket_id returned here is expected to be the globally unique - // identifier for the bucket in the object storage provider. - string bucket_id = 1; - - // bucket_info returned here stores the data specific to the - // bucket required by the object storage provider to connect to the bucket. - Protocol bucket_info = 2; -} - -message DriverDeleteBucketRequest { - // This field is REQUIRED - // bucket_id is a globally unique identifier for the bucket - // in the object storage provider - string bucket_id = 1; - - // This field is OPTIONAL - // The caller should treat the values in delete_context as opaque. - // The receiver is responsible for parsing and validating the values. - map delete_context = 2; -} - -message DriverDeleteBucketResponse { - // Intentionally left blank -} - -message DriverGrantBucketAccessRequest { - // This field is REQUIRED - // bucket_id is a globally unique identifier for the bucket - // in the object storage provider - string bucket_id = 1; - - // This field is REQUIRED - // name field is used to define the name of the bucket access object. - string name = 2; - - // This field is REQUIRED - // Requested authentication type for the bucket access. - // Supported authentication types are KEY or IAM. - AuthenticationType authentication_type = 3; - - // This field is OPTIONAL - // The caller should treat the values in parameters as opaque. - // The receiver is responsible for parsing and validating the values. - map parameters = 4; -} - -message DriverGrantBucketAccessResponse { - // This field is REQUIRED - // This is the account_id that is being provided access. This will - // be required later to revoke access. - string account_id = 1; - - // This field is REQUIRED - // Credentials supplied for accessing the bucket ex: aws access key id and secret, etc. - map credentials = 2; -} - -message DriverRevokeBucketAccessRequest { - // This field is REQUIRED - // bucket_id is a globally unique identifier for the bucket - // in the object storage provider. - string bucket_id = 1; - - // This field is REQUIRED - // This is the account_id that is having its access revoked. - string account_id = 2; - - // This field is OPTIONAL - // The caller should treat the values in revoke_access_context as opaque. - // The receiver is responsible for parsing and validating the values. - map revoke_access_context = 3; -} - -message DriverRevokeBucketAccessResponse { - // Intentionally left blank -} - diff --git a/pkg/imported-grpc/cosicomponents.png b/pkg/imported-grpc/cosicomponents.png deleted file mode 100644 index 6c852a33..00000000 Binary files a/pkg/imported-grpc/cosicomponents.png and /dev/null differ diff --git a/pkg/imported-grpc/fake/cosi.pb.fake.go b/pkg/imported-grpc/fake/cosi.pb.fake.go deleted file mode 100644 index 170bedbb..00000000 --- a/pkg/imported-grpc/fake/cosi.pb.fake.go +++ /dev/null @@ -1,35 +0,0 @@ -package fake - -import ( - "context" - grpc "google.golang.org/grpc" - containerobjectstorageinterfacespec "sigs.k8s.io/container-object-storage-interface-spec" -) - -type FakeIdentityClient struct { - FakeDriverGetInfo func(ctx context.Context, in *containerobjectstorageinterfacespec.DriverGetInfoRequest, opts ...grpc.CallOption) (*containerobjectstorageinterfacespec.DriverGetInfoResponse, error) -} - -func (f *FakeIdentityClient) DriverGetInfo(ctx context.Context, in *containerobjectstorageinterfacespec.DriverGetInfoRequest, opts ...grpc.CallOption) (*containerobjectstorageinterfacespec.DriverGetInfoResponse, error) { - return f.FakeDriverGetInfo(ctx, in, opts...) -} - -type FakeProvisionerClient struct { - FakeDriverCreateBucket func(ctx context.Context, in *containerobjectstorageinterfacespec.DriverCreateBucketRequest, opts ...grpc.CallOption) (*containerobjectstorageinterfacespec.DriverCreateBucketResponse, error) - FakeDriverDeleteBucket func(ctx context.Context, in *containerobjectstorageinterfacespec.DriverDeleteBucketRequest, opts ...grpc.CallOption) (*containerobjectstorageinterfacespec.DriverDeleteBucketResponse, error) - FakeDriverGrantBucketAccess func(ctx context.Context, in *containerobjectstorageinterfacespec.DriverGrantBucketAccessRequest, opts ...grpc.CallOption) (*containerobjectstorageinterfacespec.DriverGrantBucketAccessResponse, error) - FakeDriverRevokeBucketAccess func(ctx context.Context, in *containerobjectstorageinterfacespec.DriverRevokeBucketAccessRequest, opts ...grpc.CallOption) (*containerobjectstorageinterfacespec.DriverRevokeBucketAccessResponse, error) -} - -func (f *FakeProvisionerClient) DriverCreateBucket(ctx context.Context, in *containerobjectstorageinterfacespec.DriverCreateBucketRequest, opts ...grpc.CallOption) (*containerobjectstorageinterfacespec.DriverCreateBucketResponse, error) { - return f.FakeDriverCreateBucket(ctx, in, opts...) -} -func (f *FakeProvisionerClient) DriverDeleteBucket(ctx context.Context, in *containerobjectstorageinterfacespec.DriverDeleteBucketRequest, opts ...grpc.CallOption) (*containerobjectstorageinterfacespec.DriverDeleteBucketResponse, error) { - return f.FakeDriverDeleteBucket(ctx, in, opts...) -} -func (f *FakeProvisionerClient) DriverGrantBucketAccess(ctx context.Context, in *containerobjectstorageinterfacespec.DriverGrantBucketAccessRequest, opts ...grpc.CallOption) (*containerobjectstorageinterfacespec.DriverGrantBucketAccessResponse, error) { - return f.FakeDriverGrantBucketAccess(ctx, in, opts...) -} -func (f *FakeProvisionerClient) DriverRevokeBucketAccess(ctx context.Context, in *containerobjectstorageinterfacespec.DriverRevokeBucketAccessRequest, opts ...grpc.CallOption) (*containerobjectstorageinterfacespec.DriverRevokeBucketAccessResponse, error) { - return f.FakeDriverRevokeBucketAccess(ctx, in, opts...) -} diff --git a/pkg/imported-grpc/go.mod b/pkg/imported-grpc/go.mod deleted file mode 100644 index ad3d5439..00000000 --- a/pkg/imported-grpc/go.mod +++ /dev/null @@ -1,19 +0,0 @@ -module sigs.k8s.io/container-object-storage-interface-spec - -go 1.18 - -require ( - github.com/dave/jennifer v1.4.1 - github.com/golang/protobuf v1.4.3 - google.golang.org/grpc v1.35.0 - google.golang.org/protobuf v1.25.0 -) - -require ( - github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b // indirect - github.com/mitchellh/protoc-gen-go-json v1.1.0 // indirect - golang.org/x/net v0.0.0-20191002035440-2ec189313ef0 // indirect - golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a // indirect - golang.org/x/text v0.3.0 // indirect - google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013 // indirect -) diff --git a/pkg/imported-grpc/go.sum b/pkg/imported-grpc/go.sum deleted file mode 100644 index 7d412c5a..00000000 --- a/pkg/imported-grpc/go.sum +++ /dev/null @@ -1,92 +0,0 @@ -cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= -github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= -github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= -github.com/dave/jennifer v1.4.1 h1:XyqG6cn5RQsTj3qlWQTKlRGAyrTcsk1kUmWdZBzRjDw= -github.com/dave/jennifer v1.4.1/go.mod h1:7jEdnm+qBcxl8PC0zyp7vxcpSRnzXSt9r39tpTVGlwA= -github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= -github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= -github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= -github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58= -github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= -github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= -github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= -github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= -github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= -github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8= -github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= -github.com/golang/protobuf v1.4.3 h1:JjCZWpVbqXDqFVmTfYWEVTMIYrL/NPdPSCHPJ0T/raM= -github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= -github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= -github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= -github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= -github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.0 h1:/QaMHBdZ26BB3SSst0Iwl10Epc+xhTquomWX0oZEB6w= -github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/mitchellh/protoc-gen-go-json v1.1.0 h1:lEi1xtXyYKDwA8EB5u27+UUZOTznC4JpqVOKZwCGJUo= -github.com/mitchellh/protoc-gen-go-json v1.1.0/go.mod h1:pACAKlMtBf4SMFbVswcjwNwWwlci6Vn841H5jPRcE9I= -github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= -github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= -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/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= -golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= -golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20191002035440-2ec189313ef0 h1:2mqDk8w/o6UmeUCu5Qiq2y7iMf6anbx+YA8d1JFoFrs= -golang.org/x/net v0.0.0-20191002035440-2ec189313ef0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= -golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a h1:1BGLXjeY4akVXGgbC9HugT3Jv3hCI0z56oJR5vAMgBU= -golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/text v0.3.0 h1:g61tztE5qeGQ89tm6NTjjM9VPIm088od1l6aSorWRWg= -golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= -golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= -golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= -golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= -google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= -google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= -google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= -google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013 h1:+kGHl1aib/qcwaRi1CbqBZ1rk19r85MNUf8HaBghugY= -google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= -google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= -google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= -google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= -google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= -google.golang.org/grpc v1.35.0 h1:TwIQcH3es+MojMVojxxfQ3l3OF2KzlRxML2xZq0kRo8= -google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= -google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= -google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= -google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= -google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= -google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= -google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.25.0 h1:Ejskq+SyPohKW+1uil0JJMtmHCgJPJ/qWTxr8qp+R4c= -google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= -gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= diff --git a/pkg/imported-grpc/hack/fake-gen/main.go b/pkg/imported-grpc/hack/fake-gen/main.go deleted file mode 100644 index 942d7717..00000000 --- a/pkg/imported-grpc/hack/fake-gen/main.go +++ /dev/null @@ -1,185 +0,0 @@ -/* -If this program is on the path of your machine you can invoke it in the following way: - -protoc --plugin protoc-gen-gofake --goexample_out=package=cosi,packagePath=sigs.k8s.io/container-object-storage-interface-spec:fake cosi.proto - -Requires package, and packagePath to be specified -*/ -package main - -import ( - "fmt" - "io/ioutil" - "os" - "strings" - - . "github.com/dave/jennifer/jen" - "github.com/golang/protobuf/proto" - plugin "github.com/golang/protobuf/protoc-gen-go/plugin" -) - -type GoFake struct { - Request *plugin.CodeGeneratorRequest - Response *plugin.CodeGeneratorResponse - Parameters map[string]string -} - -type FakeService struct { - Name string - Methods []Method -} - -type Method struct { - Name string - Input string - Output string -} - -func cleanInput(val string) string { - spl := strings.Split(val, ".") - return spl[len(spl)-1] -} - -func (runner *GoFake) getLocationMessage() map[string][]*FakeService { - ret := make(map[string][]*FakeService) - for _, protoFile := range runner.Request.ProtoFile { - _, _ = fmt.Fprintf(os.Stderr, "%s\n", *protoFile.Name) - fakeServices := make([]*FakeService, 0) - _, _ = fmt.Fprintf(os.Stderr, "%+v\n", protoFile.GetService()) - svcs := protoFile.GetService() - for _, svc := range svcs { - _, _ = fmt.Fprintf(os.Stderr, "service: %+v\n", svc) - current := &FakeService{ - Name: fmt.Sprintf("%sClient", *svc.Name), - } - methods := make([]Method, 0) - for _, mtd := range svc.Method { - method := Method{Name: *mtd.Name} - if mtd.InputType != nil { - method.Input = cleanInput(*mtd.InputType) - } - if mtd.OutputType != nil { - method.Output = cleanInput(*mtd.OutputType) - } - methods = append(methods, method) - } - current.Methods = methods - - fakeServices = append(fakeServices, current) - } - ret[*protoFile.Name] = fakeServices - } - return ret -} - -func (runner *GoFake) CreateFakeFile(filename string, fakeSVC []*FakeService) error { - var outfileName string - var content string - outfileName = strings.Replace(filename, ".proto", ".pb.fake.go", -1) - var mdFile plugin.CodeGeneratorResponse_File - mdFile.Name = &outfileName - - pkgPath := runner.Parameters["packagePath"] - - f := NewFile("fake") - for _, fakeSVC := range fakeSVC { - s := f.Type().Id(fmt.Sprintf("Fake%s", fakeSVC.Name)) - fakeMethds := make([]Code, len(fakeSVC.Methods)) - for i, mtd := range fakeSVC.Methods { - fakeMethds[i] = Id(fmt.Sprintf("Fake%s", mtd.Name)).Func().Params( - Id("ctx").Qual("context", "Context"), - Id("in").Op("*").Qual(pkgPath, mtd.Input), - Id("opts").Op("...").Qual("google.golang.org/grpc", "CallOption"), - ).Op("(").List( - Op("*").Qual(pkgPath, mtd.Output), - Error(), - ).Op(")") - } - s.Struct(fakeMethds...) - for _, mtd := range fakeSVC.Methods { - f.Func().Params(Id("f").Id(fmt.Sprintf("*Fake%s", fakeSVC.Name))).Id(mtd.Name).Params( - Id("ctx").Qual("context", "Context"), - Id("in").Op("*").Qual(pkgPath, mtd.Input), - Id("opts").Op("...").Qual("google.golang.org/grpc", "CallOption"), - ).Op("(").List( - Op("*").Qual(pkgPath, mtd.Output), - Error(), - ).Op(")").Block( - Return(Id("f").Dot(fmt.Sprintf("Fake%s", mtd.Name)).Call( - Id("ctx"), - Id("in"), - Id("opts").Op("..."), - )), - ) - } - } - content = fmt.Sprintf("%#v", f) - mdFile.Content = &content - runner.Response.File = append(runner.Response.File, &mdFile) - return nil -} - -func (runner *GoFake) generateMessageMarkdown() error { - // This convenience method will return a structure of some types that I use - for filename, locationMessages := range runner.getLocationMessage() { - runner.CreateFakeFile(filename, locationMessages) - } - return nil -} - -func (runner *GoFake) generateCode() error { - // Initialize the output file slice - files := make([]*plugin.CodeGeneratorResponse_File, 0) - runner.Response.File = files - - err := runner.generateMessageMarkdown() - if err != nil { - return err - } - return nil -} - -func main() { - // os.Stdin will contain data which will unmarshal into the following object: - // https://godoc.org/github.com/golang/protobuf/protoc-gen-go/plugin#CodeGeneratorRequest - req := &plugin.CodeGeneratorRequest{} - resp := &plugin.CodeGeneratorResponse{} - - data, err := ioutil.ReadAll(os.Stdin) - if err != nil { - panic(err) - } - - // You must use the requests unmarshal method to handle this type - if err := proto.Unmarshal(data, req); err != nil { - panic(err) - } - - // You may require more data than what is in the proto files alone. There are a couple ways in which to do this. - // The first is by parameters. Another may be using leading comments in the proto files which I will cover in generateCode. - parameters := req.GetParameter() - // =grpc,import_path=mypackage:. - exampleRunner := &GoFake{ - Request: req, - Response: resp, - Parameters: make(map[string]string), - } - groupkv := strings.Split(parameters, ",") - for _, element := range groupkv { - kv := strings.Split(element, "=") - if len(kv) > 1 { - exampleRunner.Parameters[kv[0]] = kv[1] - } - } - - err = exampleRunner.generateCode() - if err != nil { - panic(err) - } - - marshalled, err := proto.Marshal(resp) - if err != nil { - panic(err) - } - os.Stdout.Write(marshalled) -} diff --git a/pkg/imported-grpc/release-tools/.prow.sh b/pkg/imported-grpc/release-tools/.prow.sh deleted file mode 100755 index b18c5358..00000000 --- a/pkg/imported-grpc/release-tools/.prow.sh +++ /dev/null @@ -1,7 +0,0 @@ -#! /bin/bash -e -# -# This is for testing csi-release-tools itself in Prow. All other -# repos use prow.sh for that, but as csi-release-tools isn't a normal -# repo with some Go code in it, it has a custom Prow test script. - -./verify-shellcheck.sh "$(pwd)" diff --git a/pkg/imported-grpc/release-tools/build.make b/pkg/imported-grpc/release-tools/build.make deleted file mode 100644 index 1880b002..00000000 --- a/pkg/imported-grpc/release-tools/build.make +++ /dev/null @@ -1,170 +0,0 @@ -# Copyright 2020 The Kubernetes 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. - -.PHONY: build-% build container-% container push-% push clean test - -# A space-separated list of all commands in the repository, must be -# set in main Makefile of a repository. -# CMDS= - -# This is the default. It can be overridden in the main Makefile after -# including build.make. -REGISTRY_NAME=quay.io/k8scosi - -# Can be set to -mod=vendor to ensure that the "vendor" directory is used. -GOFLAGS_VENDOR= - -# Revision that gets built into each binary via the main.version -# string. Uses the `git describe` output based on the most recent -# version tag with a short revision suffix or, if nothing has been -# tagged yet, just the revision. -# -# Beware that tags may also be missing in shallow clones as done by -# some CI systems (like TravisCI, which pulls only 50 commits). -REV=$(shell git describe --long --tags --match='v*' --dirty 2>/dev/null || git rev-list -n1 HEAD) - -# A space-separated list of image tags under which the current build is to be pushed. -# Determined dynamically. -IMAGE_TAGS= - -# A "canary" image gets built if the current commit is the head of the remote "master" branch. -# That branch does not exist when building some other branch in TravisCI. -IMAGE_TAGS+=$(shell if [ "$$(git rev-list -n1 HEAD)" = "$$(git rev-list -n1 origin/master 2>/dev/null)" ]; then echo "canary"; fi) - -# A "X.Y.Z-canary" image gets built if the current commit is the head of a "origin/release-X.Y.Z" branch. -# The actual suffix does not matter, only the "release-" prefix is checked. -IMAGE_TAGS+=$(shell git branch -r --points-at=HEAD | grep 'origin/release-' | grep -v -e ' -> ' | sed -e 's;.*/release-\(.*\);\1-canary;') - -# A release image "vX.Y.Z" gets built if there is a tag of that format for the current commit. -# --abbrev=0 suppresses long format, only showing the closest tag. -IMAGE_TAGS+=$(shell tagged="$$(git describe --tags --match='v*' --abbrev=0)"; if [ "$$tagged" ] && [ "$$(git rev-list -n1 HEAD)" = "$$(git rev-list -n1 $$tagged)" ]; then echo $$tagged; fi) - -# Images are named after the command contained in them. -IMAGE_NAME=$(REGISTRY_NAME)/$* - -ifdef V -# Adding "-alsologtostderr" assumes that all test binaries contain glog. This is not guaranteed. -TESTARGS = -v -args -alsologtostderr -v 5 -else -TESTARGS = -endif - -ARCH := $(if $(GOARCH),$(GOARCH),$(shell go env GOARCH)) - -# Specific packages can be excluded from each of the tests below by setting the *_FILTER_CMD variables -# to something like "| grep -v 'github.com/kubernetes-csi/project/pkg/foobar'". See usage below. - -build-%: check-go-version-go - mkdir -p bin - CGO_ENABLED=0 GOOS=linux go build $(GOFLAGS_VENDOR) -a -ldflags '-X main.version=$(REV) -extldflags "-static"' -o ./bin/$* ./cmd/$* - if [ "$(ARCH)" = "amd64" ]; then \ - CGO_ENABLED=0 GOOS=windows go build $(GOFLAGS_VENDOR) -a -ldflags '-X main.version=$(REV) -extldflags "-static"' -o ./bin/$*.exe ./cmd/$* ; \ - CGO_ENABLED=0 GOOS=linux GOARCH=ppc64le go build $(GOFLAGS_VENDOR) -a -ldflags '-X main.version=$(REV) -extldflags "-static"' -o ./bin/$*-ppc64le ./cmd/$* ; \ - CGO_ENABLED=0 GOOS=linux GOARCH=arm64 go build $(GOFLAGS_VENDOR) -a -ldflags '-X main.version=$(REV) -extldflags "-static"' -o ./bin/$*-arm64 ./cmd/$* ; \ - fi - -container-%: build-% - docker build -t $*:latest -f $(shell if [ -e ./cmd/$*/Dockerfile ]; then echo ./cmd/$*/Dockerfile; else echo Dockerfile; fi) --label revision=$(REV) . - -push-%: container-% - set -ex; \ - push_image () { \ - docker tag $*:latest $(IMAGE_NAME):$$tag; \ - docker push $(IMAGE_NAME):$$tag; \ - }; \ - for tag in $(IMAGE_TAGS); do \ - if [ "$$tag" = "canary" ] || echo "$$tag" | grep -q -e '-canary$$'; then \ - : "creating or overwriting canary image"; \ - push_image; \ - elif docker pull $(IMAGE_NAME):$$tag 2>&1 | tee /dev/stderr | grep -q "manifest for $(IMAGE_NAME):$$tag not found"; then \ - : "creating release image"; \ - push_image; \ - else \ - : "release image $(IMAGE_NAME):$$tag already exists, skipping push"; \ - fi; \ - done - -build: $(CMDS:%=build-%) -container: $(CMDS:%=container-%) -push: $(CMDS:%=push-%) - -clean: - -rm -rf bin - -test: check-go-version-go - -.PHONY: test-go -test: test-go -test-go: - @ echo; echo "### $@:" - go test $(GOFLAGS_VENDOR) `go list $(GOFLAGS_VENDOR) ./... | grep -v -e 'vendor' -e '/test/e2e$$' $(TEST_GO_FILTER_CMD)` $(TESTARGS) - -.PHONY: test-vet -test: test-vet -test-vet: - @ echo; echo "### $@:" - go vet $(GOFLAGS_VENDOR) `go list $(GOFLAGS_VENDOR) ./... | grep -v vendor $(TEST_VET_FILTER_CMD)` - -.PHONY: test-fmt -test: test-fmt -test-fmt: - @ echo; echo "### $@:" - files=$$(find . -name '*.go' | grep -v './vendor' $(TEST_FMT_FILTER_CMD)); \ - if [ $$(gofmt -d $$files | wc -l) -ne 0 ]; then \ - echo "formatting errors:"; \ - gofmt -d $$files; \ - false; \ - fi - -# This test only runs when dep >= 0.5 is installed, which is the case for the CI setup. -# When using 'go mod', we allow the test to be skipped in the Prow CI under some special -# circumstances, because it depends on accessing all remote repos and thus -# running it all the time would defeat the purpose of vendoring: -# - not handling a PR or -# - the fabricated merge commit leaves go.mod, go.sum and vendor dir unchanged -# - release-tools also didn't change (changing rules or Go version might lead to -# a different result and thus must be tested) -# - import statements not changed (because if they change, go.mod might have to be updated) -# -# "git diff" is intelligent enough to annotate changes inside the "import" block in -# the start of the diff hunk: -# -# diff --git a/rpc/common.go b/rpc/common.go -# index bb4a5c4..5fa4271 100644 -# --- a/rpc/common.go -# +++ b/rpc/common.go -# @@ -21,7 +21,6 @@ import ( -# "fmt" -# "time" -# -# - "google.golang.org/grpc" -# "google.golang.org/grpc/codes" -# "google.golang.org/grpc/status" -# -# We rely on that to find such changes. -# -# Vendoring is optional when using go.mod. -.PHONY: test-vendor -test: test-vendor -test-vendor: - @ echo; echo "### $@:" - @ ./release-tools/verify-vendor.sh - -# Targets in the makefile can depend on check-go-version- -# to trigger a warning if the x.y version of that binary does not match -# what the project uses. Make ensures that this is only checked once per -# invocation. -.PHONY: check-go-version-% -check-go-version-%: - ./release-tools/verify-go-version.sh "$*" diff --git a/pkg/imported-grpc/release-tools/filter-junit.go b/pkg/imported-grpc/release-tools/filter-junit.go deleted file mode 100644 index 8ba3f6fe..00000000 --- a/pkg/imported-grpc/release-tools/filter-junit.go +++ /dev/null @@ -1,133 +0,0 @@ -/* -Copyright 2020 The Kubernetes 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. -*/ - -/* - * This command filters a JUnit file such that only tests with a name - * matching a regular expression are passed through. By concatenating - * multiple input files it is possible to merge them into a single file. - */ -package main - -import ( - "encoding/xml" - "flag" - "io/ioutil" - "os" - "regexp" -) - -var ( - output = flag.String("o", "-", "junit file to write, - for stdout") - tests = flag.String("t", "", "regular expression matching the test names that are to be included in the output") -) - -/* - * TestSuite represents a JUnit file. Due to how encoding/xml works, we have - * represent all fields that we want to be passed through. It's therefore - * not a complete solution, but good enough for Ginkgo + Spyglass. - */ -type TestSuite struct { - XMLName string `xml:"testsuite"` - TestCases []TestCase `xml:"testcase"` -} - -type TestCase struct { - Name string `xml:"name,attr"` - Time string `xml:"time,attr"` - SystemOut string `xml:"system-out,omitempty"` - Failure string `xml:"failure,omitempty"` - Skipped SkipReason `xml:"skipped,omitempty"` -} - -// SkipReason deals with the special : -// if present, we must re-encode it, even if empty. -type SkipReason string - -func (s *SkipReason) UnmarshalText(text []byte) error { - *s = SkipReason(text) - if *s == "" { - *s = " " - } - return nil -} - -func (s SkipReason) MarshalText() ([]byte, error) { - if s == " " { - return []byte{}, nil - } - return []byte(s), nil -} - -func main() { - var junit TestSuite - var data []byte - - flag.Parse() - - re := regexp.MustCompile(*tests) - - // Read all input files. - for _, input := range flag.Args() { - if input == "-" { - if _, err := os.Stdin.Read(data); err != nil { - panic(err) - } - } else { - var err error - data, err = ioutil.ReadFile(input) - if err != nil { - panic(err) - } - } - if err := xml.Unmarshal(data, &junit); err != nil { - panic(err) - } - } - - // Keep only matching testcases. Testcases skipped in all test runs are only stored once. - filtered := map[string]TestCase{} - for _, testcase := range junit.TestCases { - if !re.MatchString(testcase.Name) { - continue - } - entry, ok := filtered[testcase.Name] - if !ok || // not present yet - entry.Skipped != "" && testcase.Skipped == "" { // replaced skipped test with real test run - filtered[testcase.Name] = testcase - } - } - junit.TestCases = nil - for _, testcase := range filtered { - junit.TestCases = append(junit.TestCases, testcase) - } - - // Re-encode. - data, err := xml.MarshalIndent(junit, "", " ") - if err != nil { - panic(err) - } - - // Write to output. - if *output == "-" { - if _, err := os.Stdout.Write(data); err != nil { - panic(err) - } - } else { - if err := ioutil.WriteFile(*output, data, 0644); err != nil { - panic(err) - } - } -} diff --git a/pkg/imported-grpc/release-tools/go-get-kubernetes.sh b/pkg/imported-grpc/release-tools/go-get-kubernetes.sh deleted file mode 100755 index 2e739830..00000000 --- a/pkg/imported-grpc/release-tools/go-get-kubernetes.sh +++ /dev/null @@ -1,104 +0,0 @@ -#!/usr/bin/env bash - -# Copyright 2020 The Kubernetes 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. -# -# This script can be used while converting a repo from "dep" to "go mod" -# by calling it after "go mod init" or to update the Kubernetes packages -# in a repo that has already been converted. Only packages that are -# part of kubernetes/kubernetes and thus part of a Kubernetes release -# are modified. Other k8.io packages (like k8s.io/klog, k8s.io/utils) -# need to be updated separately. - -set -o pipefail - -cmd=$0 - -function help () { - echo "$cmd - update all components from kubernetes/kubernetes to that version" -} - -if [ $# -ne 1 ]; then - help - exit 1 -fi -case "$1" in -h|--help|help) help; exit 0;; esac - -die () { - echo >&2 "$@" - exit 1 -} - -k8s="$1" - -# If the repo imports k8s.io/kubernetes (directly or indirectly), then -# "go mod" will try to find "v0.0.0" versions because -# k8s.io/kubernetes has those in it's go.mod file -# (https://github.com/kubernetes/kubernetes/blob/2bd9643cee5b3b3a5ecbd3af49d09018f0773c77/go.mod#L146-L157). -# (https://github.com/kubernetes/kubernetes/issues/79384). -# -# We need to replicate the replace statements to override those fake -# versions also in our go.mod file (idea and some code from -# https://github.com/kubernetes/kubernetes/issues/79384#issuecomment-521493597). -mods=$( (set -x; curl --silent --show-error --fail "https://raw.githubusercontent.com/kubernetes/kubernetes/v${k8s}/go.mod") | - sed -n 's|.*k8s.io/\(.*\) => ./staging/src/k8s.io/.*|k8s.io/\1|p' - ) || die "failed to determine Kubernetes staging modules" -for mod in $mods; do - # The presence of a potentially incomplete go.mod file affects this command, - # so move elsewhere. - modinfo=$(set -x; cd /; env GO111MODULE=on go mod download -json "$mod@kubernetes-${k8s}") || - die "failed to determine version of $mod: $modinfo" - v=$(echo "$modinfo" | sed -n 's|.*"Version": "\(.*\)".*|\1|p') - (set -x; env GO111MODULE=on go mod edit "-replace=$mod=$mod@$v") || die "'go mod edit' failed" -done - -packages= - -# Beware that we have to work with packages, not modules (i.e. no -m -# flag), because some modules trigger a "no Go code except tests" -# error. Getting their packages works. -if ! packages=$( (set -x; env GO111MODULE=on go list all) | grep ^k8s.io/ | sed -e 's; *;;'); then - cat >&2 <&2 <" go.mod; then - deps="$deps $(echo "$package" | sed -e "s;\$;@kubernetes-$k8s;" -e 's;^k8s.io/kubernetes\(/.*\)@kubernetes-;k8s.io/kubernetes\1@v;')" - fi -done - -# shellcheck disable=SC2086 -(set -x; env GO111MODULE=on go get $deps 2>&1) || die "go get failed" -echo "SUCCESS" diff --git a/pkg/imported-grpc/release-tools/prow.sh b/pkg/imported-grpc/release-tools/prow.sh deleted file mode 100755 index 5e9968c9..00000000 --- a/pkg/imported-grpc/release-tools/prow.sh +++ /dev/null @@ -1,890 +0,0 @@ -#! /bin/bash -# -# Copyright 2020 The Kubernetes 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. - - -# This script runs inside a Prow job. It can run unit tests ("make test") -# and E2E testing. This E2E testing covers different scenarios. -# -# The intended usage of this script is that individual repos import -# release-tools, then link their top-level prow.sh to this or -# include it in that file. When including it, several of the variables -# can be overridden in the top-level prow.sh to customize the script -# for the repo. -# -# The expected environment is: -# - $GOPATH/src/ for the repository that is to be tested, -# with PR branch merged (when testing a PR) -# - running on linux-amd64 -# - bazel installed (when testing against Kubernetes master), must be recent -# enough for Kubernetes master -# - kind (https://github.com/kubernetes-sigs/kind) installed -# - optional: Go already installed - -RELEASE_TOOLS_ROOT="$(realpath "$(dirname "${BASH_SOURCE[0]}")")" -REPO_DIR="$(pwd)" - -# Sets the default value for a variable if not set already and logs the value. -# Any variable set this way is usually something that a repo's .prow.sh -# or the job can set. -configvar () { - # Ignore: Word is of the form "A"B"C" (B indicated). Did you mean "ABC" or "A\"B\"C"? - # shellcheck disable=SC2140 - eval : \$\{"$1":="\$2"\} - eval echo "\$3:" "$1=\${$1}" -} - -# Takes the minor version of $COSI_PROW_KUBERNETES_VERSION and overrides it to -# $1 if they are equal minor versions. Ignores versions that begin with -# "release-". -override_k8s_version () { - local current_minor_version - local override_minor_version - - # Ignore: See if you can use ${variable//search/replace} instead. - # shellcheck disable=SC2001 - current_minor_version="$(echo "${COSI_PROW_KUBERNETES_VERSION}" | sed -e 's/\([0-9]*\)\.\([0-9]*\).*/\1\.\2/')" - - # Ignore: See if you can use ${variable//search/replace} instead. - # shellcheck disable=SC2001 - override_minor_version="$(echo "${1}" | sed -e 's/\([0-9]*\)\.\([0-9]*\).*/\1\.\2/')" - if [ "${current_minor_version}" == "${override_minor_version}" ]; then - COSI_PROW_KUBERNETES_VERSION="$1" - echo "Overriding COSI_PROW_KUBERNETES_VERSION with $1: $COSI_PROW_KUBERNETES_VERSION" - fi -} - -# Prints the value of a variable + version suffix, falling back to variable + "LATEST". -get_versioned_variable () { - local var="$1" - local version="$2" - local value - - eval value="\${${var}_${version}}" - if ! [ "$value" ]; then - eval value="\${${var}_LATEST}" - fi - echo "$value" -} - -# If we have a vendor directory, then use it. We must be careful to only -# use this for "make" invocations inside the project's repo itself because -# setting it globally can break other go usages (like "go get " -# which is disabled with GOFLAGS=-mod=vendor). -configvar GOFLAGS_VENDOR "$( [ -d vendor ] && echo '-mod=vendor' )" "Go flags for using the vendor directory" - -# Go versions can be specified seperately for different tasks -# If the pre-installed Go is missing or a different -# version, the required version here will get installed -# from https://golang.org/dl/. -go_from_travis_yml () { - grep "^ *- go:" "${RELEASE_TOOLS_ROOT}/travis.yml" | sed -e 's/.*go: *//' -} - -configvar COSI_K8S_GO_VERSION "1.15.5" "This will override the k8s version, sometime k8s version is incorrect to fetch from go downloads" -configvar COSI_PROW_GO_VERSION_BUILD "$(go_from_travis_yml)" "Go version for building the component" # depends on component's source code -configvar COSI_PROW_GO_VERSION_E2E "${COSI_K8S_GO_VERSION}" "override Go version for building the Kubernetes E2E test suite" # normally doesn't need to be set, see install_e2e -configvar COSI_PROW_GO_VERSION_KIND "${COSI_PROW_GO_VERSION_BUILD}" "Go version for building 'kind'" # depends on COSI_PROW_KIND_VERSION below -configvar COSI_PROW_GO_VERSION_GINKGO "${COSI_PROW_GO_VERSION_BUILD}" "Go version for building ginkgo" # depends on COSI_PROW_GINKGO_VERSION below - -# kind version to use. If the pre-installed version is different, -# the desired version is downloaded from https://github.com/kubernetes-sigs/kind/releases/download/ -# (if available), otherwise it is built from source. -configvar COSI_PROW_KIND_VERSION "v0.6.0" "kind" - -# ginkgo test runner version to use. If the pre-installed version is -# different, the desired version is built from source. -configvar COSI_PROW_GINKGO_VERSION v1.7.0 "Ginkgo" - -# Ginkgo runs the E2E test in parallel. The default is based on the number -# of CPUs, but typically this can be set to something higher in the job. -configvar COSI_PROW_GINKO_PARALLEL "-p" "Ginko parallelism parameter(s)" - -# Enables building the code in the repository. On by default, can be -# disabled in jobs which only use pre-built components. -configvar COSI_PROW_BUILD_JOB true "building code in repo enabled" - -# Kubernetes version to test against. This must be a version number -# (like 1.13.3) for which there is a pre-built kind image (see -# https://hub.docker.com/r/kindest/node/tags), "latest" (builds -# Kubernetes from the master branch) or "release-x.yy" (builds -# Kubernetes from a release branch). -# -# This can also be a version that was not released yet at the time -# that the settings below were chose. The script will then -# use the same settings as for "latest" Kubernetes. This works -# as long as there are no breaking changes in Kubernetes, like -# deprecating or changing the implementation of an alpha feature. -configvar COSI_PROW_KUBERNETES_VERSION 1.24.0 "Kubernetes" - -# This is a hack to workaround the issue that each version -# of kind currently only supports specific patch versions of -# Kubernetes. We need to override COSI_PROW_KUBERNETES_VERSION -# passed in by our CI/pull jobs to the versions that -# kind v0.5.0 supports. -# -# If the version is prefixed with "release-", then nothing -# is overridden. -override_k8s_version "1.24.0" - -# COSI_PROW_KUBERNETES_VERSION reduced to first two version numbers and -# with underscore (1_13 instead of 1.13.3) and in uppercase (LATEST -# instead of latest). -# -# This is used to derive the right defaults for the variables below -# when a Prow job just defines the Kubernetes version. -cosi_prow_kubernetes_version_suffix="$(echo "${COSI_PROW_KUBERNETES_VERSION}" | tr . _ | tr '[:lower:]' '[:upper:]' | sed -e 's/^RELEASE-//' -e 's/\([0-9]*\)_\([0-9]*\).*/\1_\2/')" - -# Work directory. It has to allow running executables, therefore /tmp -# is avoided. Cleaning up after the script is intentionally left to -# the caller. -configvar COSI_PROW_WORK "$(mkdir -p "$GOPATH/pkg" && mktemp -d "$GOPATH/pkg/cosiprow.XXXXXXXXXX")" "work directory" - -# The E2E testing can come from an arbitrary repo. The expectation is that -# the repo supports "go test ./test/e2e -args --storage.testdriver" (https://github.com/kubernetes/kubernetes/pull/72836) -# after setting KUBECONFIG. As a special case, if the repository is Kubernetes, -# then `make WHAT=test/e2e/e2e.test` is called first to ensure that -# all generated files are present. -# -# COSI_PROW_E2E_REPO=none disables E2E testing. -# TOOO: remove versioned variables and make e2e version match k8s version -configvar COSI_PROW_E2E_VERSION_LATEST master "E2E version for Kubernetes master" # testing against Kubernetes master is already tracking a moving target, so we might as well use a moving E2E version -configvar COSI_PROW_E2E_REPO_LATEST https://github.com/kubernetes/kubernetes "E2E repo for Kubernetes >= 1.13.x" # currently the same for all versions -configvar COSI_PROW_E2E_IMPORT_PATH_LATEST k8s.io/kubernetes "E2E package for Kubernetes >= 1.13.x" # currently the same for all versions -configvar COSI_PROW_E2E_VERSION "$(get_versioned_variable COSI_PROW_E2E_VERSION "${cosi_prow_kubernetes_version_suffix}")" "E2E version" -configvar COSI_PROW_E2E_REPO "$(get_versioned_variable COSI_PROW_E2E_REPO "${cosi_prow_kubernetes_version_suffix}")" "E2E repo" -configvar COSI_PROW_E2E_IMPORT_PATH "$(get_versioned_variable COSI_PROW_E2E_IMPORT_PATH "${cosi_prow_kubernetes_version_suffix}")" "E2E package" - -# The version of dep to use for 'make test-vendor'. Ignored if the project doesn't -# use dep. Only binary releases of dep are supported (https://github.com/golang/dep/releases). -configvar COSI_PROW_DEP_VERSION v0.5.1 "golang dep version to be used for vendor checking" - -// Version of the Spec used -configvar COSI_SPEC_VERSION master "version of the cosi spec will influence the crd object loaded for testing" - -// Version of the API used -configvar COSI_API_VERSION master "version of the cosi api will influence the api objects loaded for testing" - -// Version of the Controller used -configvar COSI_CONTROLLER_VERSION master "version of the cosi controller used for testing" - -# TODO Each job can run one or more of the following tests, identified by -# a single word: -# - unit testing -# - parallel excluding alpha features -# - serial excluding alpha features -# - parallel, only alpha feature -# - serial, only alpha features -# - sanity -# -# Unknown or unsupported entries are ignored. -# -configvar COSI_PROW_TESTS "unit parallel serial parallel-alpha serial-alpha sanity" "tests to run" -tests_enabled () { - local t1 t2 - # We want word-splitting here, so ignore: Quote to prevent word splitting, or split robustly with mapfile or read -a. - # shellcheck disable=SC2206 - local tests=(${COSI_PROW_TESTS}) - for t1 in "$@"; do - for t2 in "${tests[@]}"; do - if [ "$t1" = "$t2" ]; then - return - fi - done - done - return 1 -} - -tests_need_kind () { - tests_enabled "parallel" "serial" "serial-alpha" "parallel-alpha" || - sanity_enabled -} -tests_need_non_alpha_cluster () { - tests_enabled "parallel" "serial" || - sanity_enabled -} -tests_need_alpha_cluster () { - tests_enabled "parallel-alpha" "serial-alpha" -} - -# Serial vs. parallel is always determined by these regular expressions. -# Individual regular expressions are seperated by spaces for readability -# and expected to not contain spaces. Use dots instead. The complete -# regex for Ginkgo will be created by joining the individual terms. -configvar COSI_PROW_E2E_SERIAL '\[Serial\] \[Disruptive\]' "tags for serial E2E tests" -regex_join () { - echo "$@" | sed -e 's/ */|/g' -e 's/^|*//' -e 's/|*$//' -e 's/^$/this-matches-nothing/g' -} - -configvar COSI_PROW_E2E_SKIP 'Disruptive|different\s+node' "tests that need to be skipped" - -configvar COSI_PROW_E2E_ALPHA "$(get_versioned_variable COSI_PROW_E2E_ALPHA "${cosi_prow_kubernetes_version_suffix}")" "alpha tests" - -# This is the directory for additional result files. Usually set by Prow, but -# if not (for example, when invoking manually) it defaults to the work directory. -configvar ARTIFACTS "${COSI_PROW_WORK}/artifacts" "artifacts" -mkdir -p "${ARTIFACTS}" - -run () { - echo "$(date) $(go version | sed -e 's/.*version \(go[^ ]*\).*/\1/') $(if [ "$(pwd)" != "${REPO_DIR}" ]; then pwd; fi)\$" "$@" >&2 - "$@" -} - -info () { - echo >&2 INFO: "$@" -} - -warn () { - echo >&2 WARNING: "$@" -} - -die () { - echo >&2 ERROR: "$@" - exit 1 -} - -# For additional tools. -COSI_PROW_BIN="${COSI_PROW_WORK}/bin" -mkdir -p "${COSI_PROW_BIN}" -PATH="${COSI_PROW_BIN}:$PATH" - -# Ensure that PATH has the desired version of the Go tools, then run command given as argument. -# Empty parameter uses the already installed Go. In Prow, that version is kept up-to-date by -# bumping the container image regularly. -run_with_go () { - local version - version="$1" - shift - - if ! [ "$version" ] || go version 2>/dev/null | grep -q "go$version"; then - run "$@" - else - if ! [ -d "${COSI_PROW_WORK}/go-$version" ]; then - run curl --fail --location "https://dl.google.com/go/go$version.linux-amd64.tar.gz" | tar -C "${COSI_PROW_WORK}" -zxf - || die "installation of Go $version failed" - mv "${COSI_PROW_WORK}/go" "${COSI_PROW_WORK}/go-$version" - fi - PATH="${COSI_PROW_WORK}/go-$version/bin:$PATH" run "$@" - fi -} - -# Ensure that we have the desired version of kind. -install_kind () { - if kind --version 2>/dev/null | grep -q " ${COSI_PROW_KIND_VERSION}$"; then - return - fi - if run curl --fail --location -o "${COSI_PROW_WORK}/bin/kind" "https://github.com/kubernetes-sigs/kind/releases/download/${COSI_PROW_KIND_VERSION}/kind-linux-amd64"; then - chmod u+x "${COSI_PROW_WORK}/bin/kind" - else - git_checkout https://github.com/kubernetes-sigs/kind "${GOPATH}/src/sigs.k8s.io/kind" "${COSI_PROW_KIND_VERSION}" --depth=1 && - (cd "${GOPATH}/src/sigs.k8s.io/kind" && make install INSTALL_DIR="${COSI_PROW_WORK}/bin") - fi -} - -# Ensure that we have the desired version of the ginkgo test runner. -install_ginkgo () { - # COSI_PROW_GINKGO_VERSION contains the tag with v prefix, the command line output does not. - if [ "v$(ginkgo version 2>/dev/null | sed -e 's/.* //')" = "${COSI_PROW_GINKGO_VERSION}" ]; then - return - fi - git_checkout https://github.com/onsi/ginkgo "$GOPATH/src/github.com/onsi/ginkgo" "${COSI_PROW_GINKGO_VERSION}" --depth=1 && - # We have to get dependencies and hence can't call just "go build". - run_with_go "${COSI_PROW_GO_VERSION_GINKGO}" go get github.com/onsi/ginkgo/ginkgo || die "building ginkgo failed" && - mv "$GOPATH/bin/ginkgo" "${COSI_PROW_BIN}" -} - -# Ensure that we have the desired version of dep. -install_dep () { - if dep version 2>/dev/null | grep -q "version:.*${COSI_PROW_DEP_VERSION}$"; then - return - fi - run curl --fail --location -o "${COSI_PROW_WORK}/bin/dep" "https://github.com/golang/dep/releases/download/v0.5.4/dep-linux-amd64" && - chmod u+x "${COSI_PROW_WORK}/bin/dep" -} - -# This checks out a repo ("https://github.com/kubernetes/kubernetes") -# in a certain location ("$GOPATH/src/k8s.io/kubernetes") at -# a certain revision (a hex commit hash, v1.13.1, master). It's okay -# for that directory to exist already. -git_checkout () { - local repo path revision - repo="$1" - shift - path="$1" - shift - revision="$1" - shift - - mkdir -p "$path" - if ! [ -d "$path/.git" ]; then - run git init "$path" - fi - if (cd "$path" && run git fetch "$@" "$repo" "$revision"); then - (cd "$path" && run git checkout FETCH_HEAD) || die "checking out $repo $revision failed" - else - # Might have been because fetching by revision is not - # supported by GitHub (https://github.com/isaacs/github/issues/436). - # Fall back to fetching everything. - (cd "$path" && run git fetch "$repo" '+refs/heads/*:refs/remotes/cosiprow/heads/*' '+refs/tags/*:refs/tags/*') || die "fetching $repo failed" - (cd "$path" && run git checkout "$revision") || die "checking out $repo $revision failed" - fi - # This is useful for local testing or when switching between different revisions in the same - # repo. - (cd "$path" && run git clean -fdx) || die "failed to clean $path" -} - -# This clones a repo ("https://github.com/kubernetes/kubernetes") -# in a certain location ("$GOPATH/src/k8s.io/kubernetes") at -# a the head of a specific branch (i.e., release-1.13, master). -# The directory cannot exist. -git_clone_branch () { - local repo path branch parent - repo="$1" - shift - path="$1" - shift - branch="$1" - shift - - parent="$(dirname "$path")" - mkdir -p "$parent" - (cd "$parent" && run git clone --single-branch --branch "$branch" "$repo" "$path") || die "cloning $repo" failed - # This is useful for local testing or when switching between different revisions in the same - # repo. - (cd "$path" && run git clean -fdx) || die "failed to clean $path" -} - -go_version_for_kubernetes () ( - local path="$1" - local version="$2" - local go_version - - # We use the minimal Go version specified for each K8S release (= minimum_go_version in hack/lib/golang.sh). - # More recent versions might also work, but we don't want to count on that. - go_version="$(grep minimum_go_version= "$path/hack/lib/golang.sh" | sed -e 's/.*=go//')" - if ! [ "$go_version" ]; then - die "Unable to determine Go version for Kubernetes $version from hack/lib/golang.sh." - fi - echo "$go_version" -) - -cosi_prow_kind_have_kubernetes=false -# Brings up a Kubernetes cluster and sets KUBECONFIG. -# Accepts additional feature gates in the form gate1=true|false,gate2=... -start_cluster () { - local image gates - gates="$1" - - if kind get clusters | grep -q cosi-prow; then - run kind delete cluster --name=cosi-prow || die "kind delete failed" - fi - - echo "build k/k source" - # Build from source? - if [[ "${COSI_PROW_KUBERNETES_VERSION}" =~ ^release-|^latest$ ]]; then - if ! ${cosi_prow_kind_have_kubernetes}; then - local version="${COSI_PROW_KUBERNETES_VERSION}" - if [ "$version" = "latest" ]; then - version=master - fi - git_clone_branch https://github.com/kubernetes/kubernetes "${COSI_PROW_WORK}/src/kubernetes" "$version" || die "checking out Kubernetes $version failed" - - go_version="$(go_version_for_kubernetes "${COSI_PROW_WORK}/src/kubernetes" "$version")" || die "cannot proceed without knowing Go version for Kubernetes" - run_with_go "$go_version" kind build node-image --type bazel --image cosiprow/node:latest --kube-root "${COSI_PROW_WORK}/src/kubernetes" || die "'kind build node-image' failed" - cosi_prow_kind_have_kubernetes=true - fi - image="cosiprow/node:latest" - else - image="kindest/node:v${COSI_PROW_KUBERNETES_VERSION}" - fi - cat >"${COSI_PROW_WORK}/kind-config.yaml" <>"${COSI_PROW_WORK}/kind-config.yaml" <&2 "ERROR: cosi CRDs not ready after over 1 min" - exit 1 - fi - echo "$(date +%H:%M:%S)" "waiting for cosi CRDs, attempt #$cnt" - cnt=$((cnt + 1)) - sleep 2 - done -} - -# Install controller and associated RBAC, retrying until the pod is running. -install_controller() { - kubectl apply -f "https://raw.githubusercontent.com/kubernetes-sigs/container-object-storage-interface-controller/${COSI_CONTROLLER_VERSION}/deploy/base/sa.yaml" - kubectl apply -f "https://raw.githubusercontent.com/kubernetes-sigs/container-object-storage-interface-controller/${COSI_CONTROLLER_VERSION}/deploy/base/rbac.yaml" - cnt=0 - until kubectl get clusterrolebinding objectstorage-controller; do - if [ $cnt -gt 30 ]; then - echo "Cluster role bindings:" - kubectl describe clusterrolebinding - echo >&2 "ERROR: controller RBAC not ready after over 5 min" - exit 1 - fi - echo "$(date +%H:%M:%S)" "waiting for cosi RBAC setup complete, attempt #$cnt" - cnt=$((cnt + 1)) - sleep 10 - done - - - kubectl apply -f "https://raw.githubusercontent.com/kubernetes-sigs/container-object-storage-interface-controller/${COSI_CONTROLLER_VERSION}/deploy/base/deployment.yaml" - cnt=0 - kubectl get pods - kubectl get pods -l app=objectstorage-controller - expected_running_pods=$(curl "https://raw.githubusercontent.com/kubernetes-sigs/container-object-storage-interface-controller/${COSI_CONTROLLER_VERSION}/deploy/base/deployment.yaml" | grep replicas | cut -d ':' -f 2-) - while [ "$(kubectl get pods -l app.kubernetes.io/name=container-object-storage-interface-controller | grep 'Running' -c)" -lt "$expected_running_pods" ]; do - if [ $cnt -gt 30 ]; then - echo "objectstorage-controller pod status:" - kubectl describe pods -l app.kubernetes.io/name=container-object-storage-interface-controller - echo >&2 "ERROR: cosi controller not ready after over 5 min" - exit 1 - fi - echo "$(date +%H:%M:%S)" "waiting for cosi controller deployment to complete, attempt #$cnt" - cnt=$((cnt + 1)) - sleep 10 - done -} - -# collect logs and cluster status (like the version of all components, Kubernetes version, test version) -collect_cluster_info () { - cat <>"${ARTIFACTS}/$namespace/$pod/$container.log" & - echo "$!" - done - done -} - -# Makes the E2E test suite binary available as "${COSI_PROW_WORK}/e2e.test". -install_e2e () { - if [ -e "${COSI_PROW_WORK}/e2e.test" ]; then - return - fi - - git_checkout "${COSI_PROW_E2E_REPO}" "${GOPATH}/src/${COSI_PROW_E2E_IMPORT_PATH}" "${COSI_PROW_E2E_VERSION}" --depth=1 && - if [ "${COSI_PROW_E2E_IMPORT_PATH}" = "k8s.io/kubernetes" ]; then - go_version="${COSI_PROW_GO_VERSION_E2E:-$(go_version_for_kubernetes "${GOPATH}/src/${COSI_PROW_E2E_IMPORT_PATH}" "${COSI_PROW_E2E_VERSION}")}" && - run_with_go "$go_version" make WHAT=test/e2e/e2e.test "-C${GOPATH}/src/${COSI_PROW_E2E_IMPORT_PATH}" && - ln -s "${GOPATH}/src/${COSI_PROW_E2E_IMPORT_PATH}/_output/bin/e2e.test" "${COSI_PROW_WORK}" - else - run_with_go "${COSI_PROW_GO_VERSION_E2E}" go test -c -o "${COSI_PROW_WORK}/e2e.test" "${COSI_PROW_E2E_IMPORT_PATH}/test/e2e" - fi -} - -# Captures pod output while running some other command. -run_with_loggers () ( - loggers=$(start_loggers -f) - trap 'kill $loggers' EXIT - - run "$@" -) - -# Invokes the filter-junit.go tool. -run_filter_junit () { - run_with_go "${COSI_PROW_GO_VERSION_BUILD}" go run "${RELEASE_TOOLS_ROOT}/filter-junit.go" "$@" -} - -# Runs the E2E test suite in a sub-shell. -run_e2e () ( - name="$1" - shift - - install_e2e || die "building e2e.test failed" - install_ginkgo || die "installing ginkgo failed" - - # Rename, merge and filter JUnit files. Necessary in case that we run the E2E suite again - # and to avoid the large number of "skipped" tests that we get from using - # the full Kubernetes E2E testsuite while only running a few tests. - move_junit () { - if ls "${ARTIFACTS}"/junit_[0-9]*.xml 2>/dev/null >/dev/null; then - run_filter_junit -t="External Storage" -o "${ARTIFACTS}/junit_${name}.xml" "${ARTIFACTS}"/junit_[0-9]*.xml && rm -f "${ARTIFACTS}"/junit_[0-9]*.xml - fi - } - trap move_junit EXIT - - cd "${GOPATH}/src/${COSI_PROW_E2E_IMPORT_PATH}" && - run_with_loggers ginkgo -v "$@" "${COSI_PROW_WORK}/e2e.test" -- -report-dir "${ARTIFACTS}" -# add this flag so that we cn switch to run tests against any driver -storage.testdriver="${COSI_PROW_WORK}/test-driver.yaml" -) - -ascii_to_xml () { - # We must escape special characters and remove escape sequences - # (no good representation in the simple XML that we generate - # here). filter_junit.go would choke on them during decoding, even - # when disabling strict parsing. - sed -e 's/&/&/g' -e 's//\>/g' -e 's/\x1B...//g' -} - -# The "make test" output starts each test with "### :" -# and then ends when the next test starts or with "make: *** -# [] Error 1" when there was a failure. Here we read each -# line of that output, split it up into individual tests and generate -# a make-test.xml file in JUnit format. -make_test_to_junit () { - local ret out testname testoutput - ret=0 - # Plain make-test.xml was not delivered as text/xml by the web - # server and ignored by spyglass. It seems that the name has to - # match junit*.xml. - out="${ARTIFACTS}/junit_make_test.xml" - testname= - echo "" >>"$out" - - while IFS= read -r line; do - echo "$line" # pass through - if echo "$line" | grep -q "^### [^ ]*:$"; then - if [ "$testname" ]; then - # previous test succesful - echo " " >>"$out" - echo " " >>"$out" - fi - # Ignore: See if you can use ${variable//search/replace} instead. - # shellcheck disable=SC2001 - # - # start new test - testname="$(echo "$line" | sed -e 's/^### \([^ ]*\):$/\1/')" - testoutput= - echo " " >>"$out" - echo " " >>"$out" - elif echo "$line" | grep -q '^make: .*Error [0-9]*$'; then - if [ "$testname" ]; then - # Ignore: Consider using { cmd1; cmd2; } >> file instead of individual redirects. - # shellcheck disable=SC2129 - # - # end test with failure - echo " " >>"$out" - # Include the same text as in also in , - # because then it is easier to view in spyglass (shown directly - # instead of having to click through to stdout). - echo " " >>"$out" - echo -n "$testoutput" | ascii_to_xml >>"$out" - echo " " >>"$out" - echo " " >>"$out" - fi - # remember failure for exit code - ret=1 - # not currently inside a test - testname= - else - if [ "$testname" ]; then - # Test output. - echo "$line" | ascii_to_xml >>"$out" - testoutput="$testoutput$line -" - fi - fi - done - # if still in a test, close it now - if [ "$testname" ]; then - echo " " >>"$out" - echo " " >>"$out" - fi - echo "" >>"$out" - - # this makes the error more visible in spyglass - if [ "$ret" -ne 0 ]; then - echo "ERROR: 'make test' failed" - return 1 - fi -} - -# version_gt returns true if arg1 is greater than arg2. -# -# This function expects versions to be one of the following formats: -# X.Y.Z, release-X.Y.Z, vX.Y.Z -# -# where X,Y, and Z are any number. -# -# Partial versions (1.2, release-1.2) work as well. -# The follow substrings are stripped before version comparison: -# - "v" -# - "release-" -# - "kubernetes-" -# -# Usage: -# version_gt release-1.3 v1.2.0 (returns true) -# version_gt v1.1.1 v1.2.0 (returns false) -# version_gt 1.1.1 v1.2.0 (returns false) -# version_gt 1.3.1 v1.2.0 (returns true) -# version_gt 1.1.1 release-1.2.0 (returns false) -# version_gt 1.2.0 1.2.2 (returns false) -function version_gt() { - versions=$(for ver in "$@"; do ver=${ver#release-}; ver=${ver#kubernetes-}; echo "${ver#v}"; done) - greaterVersion=${1#"release-"}; - greaterVersion=${greaterVersion#"kubernetes-"}; - greaterVersion=${greaterVersion#"v"}; - test "$(printf '%s' "$versions" | sort -V | head -n 1)" != "$greaterVersion" -} - -main () { - local images ret - ret=0 - - images= - if ${COSI_PROW_BUILD_JOB}; then - # A successful build is required for testing. - run_with_go "${COSI_PROW_GO_VERSION_BUILD}" make all "GOFLAGS_VENDOR=${GOFLAGS_VENDOR}" || die "'make all' failed" - # We don't want test failures to prevent E2E testing below, because the failure - # might have been minor or unavoidable, for example when experimenting with - # changes in "release-tools" in a PR (that fails the "is release-tools unmodified" - # test). - if tests_enabled "unit"; then - if [ -f Gopkg.toml ] && ! install_dep; then - warn "installing 'dep' failed, cannot test vendoring" - ret=1 - fi - if ! run_with_go "${COSI_PROW_GO_VERSION_BUILD}" make -k test "GOFLAGS_VENDOR=${GOFLAGS_VENDOR}" 2>&1 | make_test_to_junit; then - warn "'make test' failed, proceeding anyway" - ret=1 - fi - fi - # Required for E2E testing. - run_with_go "${COSI_PROW_GO_VERSION_BUILD}" make container "GOFLAGS_VENDOR=${GOFLAGS_VENDOR}" || die "'make container' failed" - fi - - if tests_need_kind; then - install_kind || die "installing kind failed" - - if ${COSI_PROW_BUILD_JOB}; then - cmds="$(grep '^\s*CMDS\s*=' Makefile | sed -e 's/\s*CMDS\s*=//')" - # Get the image that was just built (if any) from the - # top-level Makefile CMDS variable and set the - # deploy.sh env variables for it. We also need to - # side-load those images into the cluster. - for i in $cmds; do - e=$(echo "$i" | tr '[:lower:]' '[:upper:]' | tr - _) - images="$images ${e}_REGISTRY=quay.io/containerobjectstorage ${e}_TAG=cosiprow" - - # We must avoid the tag "latest" because that implies - # always pulling the image - # (https://github.com/kubernetes-sigs/kind/issues/328). - docker tag "$i:latest" "$i:cosiprow" || die "tagging the locally built container image for $i failed" - done - - if [ -e deploy/kubernetes/rbac.yaml ]; then - # This is one of those components which has its own RBAC rules (like external-provisioner). - # We are testing a locally built image and also want to test with the the current, - # potentially modified RBAC rules. - if [ "$(echo "$cmds" | wc -w)" != 1 ]; then - die "ambiguous deploy/kubernetes/rbac.yaml: need exactly one command, got: $cmds" - fi - e=$(echo "$cmds" | tr '[:lower:]' '[:upper:]' | tr - _) - images="$images ${e}_RBAC=$(pwd)/deploy/kubernetes/rbac.yaml" - fi - fi - - if tests_need_non_alpha_cluster; then - start_cluster || die "starting the non-alpha cluster failed" - - # Install necessary CRDs and controllers - # For Kubernetes 1.19+, we will install the CRDs and controller. - if version_gt "${COSI_PROW_KUBERNETES_VERSION}" "1.16.255" || "${COSI_PROW_KUBERNETES_VERSION}" == "latest"; then - info "Version ${COSI_PROW_KUBERNETES_VERSION}, installing CRDs and cosi controller" - install_crds - install_controller - else - info "Version ${COSI_PROW_KUBERNETES_VERSION}, skipping CRDs and cosi controller" - fi - - collect_cluster_info - - if tests_enabled "parallel"; then - if ! run_e2e parallel ${COSI_PROW_GINKO_PARALLEL} \ - -focus="ObjectStorage" \ - -skip="$(regex_join "${COSI_PROW_E2E_SERIAL}" "${COSI_PROW_E2E_ALPHA}" "${COSI_PROW_E2E_SKIP}")"; then - warn "E2E parallel failed" - ret=1 - fi - fi - - if tests_enabled "serial"; then - if ! run_e2e serial \ - -focus="ObjectStorage.*" \ - -skip="$(regex_join "${COSI_PROW_E2E_ALPHA}" "${COSI_PROW_E2E_SKIP}")"; then - warn "E2E serial failed" - ret=1 - fi - fi - - fi - delete_cluster_inside_prow_job - fi - # Merge all junit files into one. This gets rid of duplicated "skipped" tests. - if ls "${ARTIFACTS}"/junit_*.xml 2>/dev/null >&2; then - run_filter_junit -o "${COSI_PROW_WORK}/junit_final.xml" "${ARTIFACTS}"/junit_*.xml && rm "${ARTIFACTS}"/junit_*.xml && mv "${COSI_PROW_WORK}/junit_final.xml" "${ARTIFACTS}" - fi - - return "$ret" -} diff --git a/pkg/imported-grpc/release-tools/travis.yml b/pkg/imported-grpc/release-tools/travis.yml deleted file mode 100644 index f12d7ee4..00000000 --- a/pkg/imported-grpc/release-tools/travis.yml +++ /dev/null @@ -1,21 +0,0 @@ -language: go -sudo: required -services: - - docker -git: - depth: false -matrix: - include: - - go: 1.18.4 -before_script: -- mkdir -p bin -- wget https://github.com/golang/dep/releases/download/v0.5.1/dep-linux-amd64 -O bin/dep -- chmod u+x bin/dep -- export PATH=$PWD/bin:$PATH -script: -- make -k all test GOFLAGS_VENDOR=$( [ -d vendor ] && echo '-mod=vendor' ) -after_success: - - if [ "${TRAVIS_PULL_REQUEST}" == "false" ]; then - docker login -u "${DOCKER_USERNAME}" -p "${DOCKER_PASSWORD}" quay.io; - make push GOFLAGS_VENDOR=$( [ -d vendor ] && echo '-mod=vendor' ); - fi diff --git a/pkg/imported-grpc/release-tools/update-vendor.sh b/pkg/imported-grpc/release-tools/update-vendor.sh deleted file mode 100755 index 013a289b..00000000 --- a/pkg/imported-grpc/release-tools/update-vendor.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/usr/bin/env bash - -# Copyright 2020 The Kubernetes 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. - -if [ -f Gopkg.toml ]; then - echo "Repo uses 'dep' for vendoring." - (set -x; dep ensure) -elif [ -f go.mod ]; then - release-tools/verify-go-version.sh "go" - (set -x; env GO111MODULE=on go mod tidy && env GO111MODULE=on go mod vendor) -fi diff --git a/pkg/imported-grpc/release-tools/util.sh b/pkg/imported-grpc/release-tools/util.sh deleted file mode 100755 index 8993774d..00000000 --- a/pkg/imported-grpc/release-tools/util.sh +++ /dev/null @@ -1,148 +0,0 @@ -#!/usr/bin/env bash - -# Copyright 2020 The Kubernetes 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. - -function kube::util::sourced_variable { - # Call this function to tell shellcheck that a variable is supposed to - # be used from other calling context. This helps quiet an "unused - # variable" warning from shellcheck and also document your code. - true -} - -kube::util::sortable_date() { - date "+%Y%m%d-%H%M%S" -} - -# arguments: target, item1, item2, item3, ... -# returns 0 if target is in the given items, 1 otherwise. -kube::util::array_contains() { - local search="$1" - local element - shift - for element; do - if [[ "${element}" == "${search}" ]]; then - return 0 - fi - done - return 1 -} - -# Example: kube::util::trap_add 'echo "in trap DEBUG"' DEBUG -# See: http://stackoverflow.com/questions/3338030/multiple-bash-traps-for-the-same-signal -kube::util::trap_add() { - local trap_add_cmd - trap_add_cmd=$1 - shift - - for trap_add_name in "$@"; do - local existing_cmd - local new_cmd - - # Grab the currently defined trap commands for this trap - existing_cmd=$(trap -p "${trap_add_name}" | awk -F"'" '{print $2}') - - if [[ -z "${existing_cmd}" ]]; then - new_cmd="${trap_add_cmd}" - else - new_cmd="${trap_add_cmd};${existing_cmd}" - fi - - # Assign the test. Disable the shellcheck warning telling that trap - # commands should be single quoted to avoid evaluating them at this - # point instead evaluating them at run time. The logic of adding new - # commands to a single trap requires them to be evaluated right away. - # shellcheck disable=SC2064 - trap "${new_cmd}" "${trap_add_name}" - done -} - -kube::util::download_file() { - local -r url=$1 - local -r destination_file=$2 - - rm "${destination_file}" 2&> /dev/null || true - - for i in $(seq 5) - do - if ! curl -fsSL --retry 3 --keepalive-time 2 "${url}" -o "${destination_file}"; then - echo "Downloading ${url} failed. $((5-i)) retries left." - sleep 1 - else - echo "Downloading ${url} succeed" - return 0 - fi - done - return 1 -} - -# Wait for background jobs to finish. Return with -# an error status if any of the jobs failed. -kube::util::wait-for-jobs() { - local fail=0 - local job - for job in $(jobs -p); do - wait "${job}" || fail=$((fail + 1)) - done - return ${fail} -} - -# kube::util::join -# Concatenates the list elements with the delimiter passed as first parameter -# -# Ex: kube::util::join , a b c -# -> a,b,c -function kube::util::join { - local IFS="$1" - shift - echo "$*" -} - -# kube::util::check-file-in-alphabetical-order -# Check that the file is in alphabetical order -# -function kube::util::check-file-in-alphabetical-order { - local failure_file="$1" - if ! diff -u "${failure_file}" <(LC_ALL=C sort "${failure_file}"); then - { - echo - echo "${failure_file} is not in alphabetical order. Please sort it:" - echo - echo " LC_ALL=C sort -o ${failure_file} ${failure_file}" - echo - } >&2 - false - fi -} - -# Some useful colors. -if [[ -z "${color_start-}" ]]; then - declare -r color_start="\033[" - declare -r color_red="${color_start}0;31m" - declare -r color_yellow="${color_start}0;33m" - declare -r color_green="${color_start}0;32m" - declare -r color_blue="${color_start}1;34m" - declare -r color_cyan="${color_start}1;36m" - declare -r color_norm="${color_start}0m" - - kube::util::sourced_variable "${color_start}" - kube::util::sourced_variable "${color_red}" - kube::util::sourced_variable "${color_yellow}" - kube::util::sourced_variable "${color_green}" - kube::util::sourced_variable "${color_blue}" - kube::util::sourced_variable "${color_cyan}" - kube::util::sourced_variable "${color_norm}" -fi - -# ex: ts=2 sw=2 et filetype=sh diff --git a/pkg/imported-grpc/release-tools/verify-go-version.sh b/pkg/imported-grpc/release-tools/verify-go-version.sh deleted file mode 100755 index d24ce1ee..00000000 --- a/pkg/imported-grpc/release-tools/verify-go-version.sh +++ /dev/null @@ -1,51 +0,0 @@ -#!/usr/bin/env bash - -# Copyright 2020 The Kubernetes 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. - -GO="$1" - -if [ ! "$GO" ]; then - echo >&2 "usage: $0 " - exit 1 -fi - -die () { - echo "ERROR: $*" - exit 1 -} - -version=$("$GO" version) || die "determining version of $GO failed" -# shellcheck disable=SC2001 -majorminor=$(echo "$version" | sed -e 's/.*go\([0-9]*\)\.\([0-9]*\).*/\1.\2/') -# shellcheck disable=SC2001 -expected=$(grep "^ *- go:" "release-tools/travis.yml" | sed -e 's/.*go: *\([0-9]*\)\.\([0-9]*\).*/\1.\2/') - -if [ "$majorminor" != "$expected" ]; then - cat >&2 < /dev/null || true -} - -# ensure we're linting the source tree -cd "${ROOT}" - -# find all shell scripts excluding ./_*, ./.git/*, ./vendor*, -# and anything git-ignored -all_shell_scripts=() -while IFS=$'\n' read -r script; - do git check-ignore -q "$script" || all_shell_scripts+=("$script"); -done < <(find . -name "*.sh" \ - -not \( \ - -path ./_\* -o \ - -path ./.git\* -o \ - -path ./vendor\* \ - \)) - -# detect if the host machine has the required shellcheck version installed -# if so, we will use that instead. -HAVE_SHELLCHECK=false -if which shellcheck &>/dev/null; then - detected_version="$(shellcheck --version | grep 'version: .*')" - if [[ "${detected_version}" = "version: ${SHELLCHECK_VERSION}" ]]; then - HAVE_SHELLCHECK=true - fi -fi - -# tell the user which we've selected and possibly set up the container -if ${HAVE_SHELLCHECK}; then - echo "Using host shellcheck ${SHELLCHECK_VERSION} binary." -else - echo "Using shellcheck ${SHELLCHECK_VERSION} docker image." - # remove any previous container, ensure we will attempt to cleanup on exit, - # and create the container - remove_container - kube::util::trap_add 'remove_container' EXIT - if ! output="$(create_container 2>&1)"; then - { - echo "Failed to create shellcheck container with output: " - echo "" - echo "${output}" - } >&2 - exit 1 - fi -fi - -# lint each script, tracking failures -errors=() -for f in "${all_shell_scripts[@]}"; do - set +o errexit - if ${HAVE_SHELLCHECK}; then - failedLint=$(shellcheck --exclude="${SHELLCHECK_DISABLED}" "${f}") - else - failedLint=$(docker exec -t ${SHELLCHECK_CONTAINER} \ - shellcheck --exclude="${SHELLCHECK_DISABLED}" "${f}") - fi - set -o errexit - if [[ -n "${failedLint}" ]]; then - errors+=( "${failedLint}" ) - fi -done - -# Check to be sure all the packages that should pass lint are. -if [ ${#errors[@]} -eq 0 ]; then - echo 'Congratulations! All shell files are passing lint.' -else - { - echo "Errors from shellcheck:" - for err in "${errors[@]}"; do - echo "$err" - done - echo - echo 'Please review the above warnings. You can test via "./hack/verify-shellcheck"' - echo 'If the above warnings do not make sense, you can exempt them from shellcheck' - echo 'checking by adding the "shellcheck disable" directive' - echo '(https://github.com/koalaman/shellcheck/wiki/Directive#disable).' - echo - } >&2 - false -fi diff --git a/pkg/imported-grpc/release-tools/verify-subtree.sh b/pkg/imported-grpc/release-tools/verify-subtree.sh deleted file mode 100755 index ab8bb304..00000000 --- a/pkg/imported-grpc/release-tools/verify-subtree.sh +++ /dev/null @@ -1,41 +0,0 @@ -#! /bin/sh -e -# -# Copyright 2020 The Kubernetes 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. - -# This script verifies that the content of a directory managed -# by "git subtree" has not been modified locally. It does that -# by looking for commits that modify the files with the -# subtree prefix (aka directory) while ignoring merge -# commits. Merge commits are where "git subtree" pulls the -# upstream files into the directory. -# -# Theoretically a developer can subvert this check by modifying files -# in a merge commit, but in practice that shouldn't happen. - -DIR="$1" -if [ ! "$DIR" ]; then - echo "usage: $0 " >&2 - exit 1 -fi - -REV=$(git log -n1 --remove-empty --format=format:%H --no-merges -- "$DIR") -if [ "$REV" ]; then - echo "Directory '$DIR' contains non-upstream changes:" - echo - git log --no-merges -- "$DIR" - exit 1 -else - echo "$DIR is a clean copy of upstream." -fi diff --git a/pkg/imported-grpc/release-tools/verify-vendor.sh b/pkg/imported-grpc/release-tools/verify-vendor.sh deleted file mode 100755 index 1673242c..00000000 --- a/pkg/imported-grpc/release-tools/verify-vendor.sh +++ /dev/null @@ -1,60 +0,0 @@ -#!/usr/bin/env bash - -# Copyright 2020 The Kubernetes 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. - -if [ -f Gopkg.toml ]; then - echo "Repo uses 'dep' for vendoring." - case "$(dep version 2>/dev/null | grep 'version *:')" in - *v0.[56789]*) - if dep check; then - echo "vendor up-to-date" - else - exit 1 - fi - ;; - *) echo "skipping check, dep >= 0.5 required";; - esac -elif [ -f go.mod ]; then - echo "Repo uses 'go mod'." - # shellcheck disable=SC2235 - if [ "${JOB_NAME}" ] && - ( [ "${JOB_TYPE}" != "presubmit" ] || - [ "$( (git diff "${PULL_BASE_SHA}..HEAD" -- go.mod go.sum vendor release-tools; - git diff "${PULL_BASE_SHA}..HEAD" | grep -e '^@@.*@@ import (' -e '^[+-]import') | - wc -l)" -eq 0 ] ); then - echo "Skipping vendor check because the Prow pre-submit job does not affect dependencies." - elif ! (set -x; env GO111MODULE=on go mod tidy); then - echo "ERROR: vendor check failed." - exit 1 - elif [ "$(git status --porcelain -- go.mod go.sum | wc -l)" -gt 0 ]; then - echo "ERROR: go module files *not* up-to-date, they did get modified by 'GO111MODULE=on go mod tidy':"; - git diff -- go.mod go.sum - exit 1 - elif [ -d vendor ]; then - if ! (set -x; env GO111MODULE=on go mod vendor); then - echo "ERROR: vendor check failed." - exit 1 - elif [ "$(git status --porcelain -- vendor | wc -l)" -gt 0 ]; then - echo "ERROR: vendor directory *not* up-to-date, it did get modified by 'GO111MODULE=on go mod vendor':" - git status -- vendor - git diff -- vendor - exit 1 - else - echo "Go dependencies and vendor directory up-to-date." - fi - else - echo "Go dependencies up-to-date." - fi -fi diff --git a/pkg/imported-grpc/spec.md b/pkg/imported-grpc/spec.md deleted file mode 100644 index bbb1e47a..00000000 --- a/pkg/imported-grpc/spec.md +++ /dev/null @@ -1,631 +0,0 @@ -# Container Object Storage Interface (COSI) - -Authors: - -* Sidharth Mani [@wlan0](https://github.com/wlan0) -* Jeff Vance [@jeffvance](https://github.com/jeffvance) -* Srini Brahmaroutu [@brahmaroutu](https://github.com/brahmaroutu) - - -## Notational Conventions - -The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" are to be interpreted as described in [RFC 2119](http://tools.ietf.org/html/rfc2119) (Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, March 1997). - -The key words "unspecified", "undefined", and "implementation-defined" are to be interpreted as described in the [rationale for the C99 standard](http://www.open-std.org/jtc1/sc22/wg14/www/C99RationaleV5.10.pdf#page=18). - -An implementation is not compliant if it fails to satisfy one or more of the MUST, REQUIRED, or SHALL requirements for the protocols it implements. -An implementation is compliant if it satisfies all the MUST, REQUIRED, and SHALL requirements for the protocols it implements. - -## Terminology - -| Term | Definition | -|-------------------|--------------------------------------------------| -| Bucket | A flat organization that contains immutable objects. | -| Brownfield Bucket | An existing back-end bucket. | -| Greenfield Bucket | A new back-end bucket created by COSI. | -|COSI System | Container Orchestration system/ Container Object Storage Implementation, communicates with Plugins using COSI service RPCs. | -| SP | Object Storage Provider, the vendor of a COSI plugin implementation. | -| CO | Container Orchestrator, like Kubernetes. | -| RPC/gRPC | [Remote Procedure Call](https://en.wikipedia.org/wiki/Remote_procedure_call). | -| Node | A host where the user workload will be running, uniquely identifiable from the perspective of a Plugin by a node ID. | -| COSI Driver(aka Plugin) | Aka “plugin implementation”, a gRPC endpoint that implements the COSI Services. | -| Sidecar (aka Provisioner Sidecar) | A COSI process that interfaces with the Plugin. | -|COSI Node Adapter (aka CSI Driver) | A process that accepts gRPC calls from the Kubelet notifying it when the workload has been started and when it is terminating. | -| Provisioner | A generic term meant to describe the combination of a sidecar and COSI driver. "Provisioning" a bucket can mean creating a new bucket or granting access to an existing bucket. | -| Workload | The atomic unit of "work" scheduled by a COSI System. This MAY be a container or a collection of containers. | - -## Objective - -To define a standard “Container Object Storage Interface” (COSI) that enables a storage vendor (SP) to develop an RPC-based plugin once and have it work across multiple Kubernetes clusters and on other COs. - -### Goals in MVP - -The Container Object Storage Interface (COSI) will: - -* Enable SP authors to write one COSI compliant RPC Plugin that “just works” across all COs that implement COSI. -* Define API (RPCs) that enable: - * Dynamic provisioning and de-provisioning of a bucket. - * Ability to define bucket access control mechanisms - * Consumption of both existing and new buckets created on SP. - * Define plugin protocol recommendations. - * Describe a process by which an admin configures a Plugin. - * COSI deployments and templates. - -### Non-Goals in MVP - -The Container Object Storage Interface (COSI) spec explicitly will not define, provide, or dictate: - -* Specific mechanisms by which a Provisioner Sidecar manages the lifecycle of a Plugin, including: - * How to deploy, install, upgrade, uninstall, monitor, or respawn (in case of unexpected termination) Plugins. -* A first class message structure/field to represent "grades of object storage" (aka "bucket class"). -* Protocol-level authentication and authorization. -* Packaging of a Plugin. - -## Solution Overview - -This specification defines an interface along with the minimum operational and packaging recommendations for a storage provider (SP) to implement a COSI compatible plugin. -The interface declares the RPCs that a plugin MUST expose: this is the **primary focus** of the COSI specification. -Any operational and packaging recommendations offer additional guidance to promote cross-COSI system compatibility. - -### Architecture - -The primary focus of this specification is on the RPC **protocol** between a COSI System and a Plugin. -It SHOULD be possible to ship cross-COSI system compatible Plugins for a variety of deployment architectures. -A COSI system SHOULD be equipped to handle both centralized and headless plugins. -Interaction of these components is illustrated in the figure below. - -``` - COSI System "Master" Host -+-------------------------------------------+ -| | -| +------------+ +------------+ | -| | COSI | gRPC | Controller | | -| | System +-----------> Plugin | | -| +------------+ +------------+ | -| | -+-------------------------------------------+ - -``` -Figure 1: Plugin deployment, all of the COSI system Node hosts run Plugins. - - -![Cosi Components](cosicomponents.png) - -Figure 2: Kubernetes implementation - Interaction of COSI components - -### Bucket Lifecycle - -``` - CreateBucket +-------------+ DeleteBucket - +------------->| CREATED +--------------+ - | +---+----^---+ | - | Grant | | Revoke v - +++ Bucket | | Bucket +++ - |X| Access | | Access | | - +-+ +---v----+---+ +-+ - | BOUND | - +---+----^---+ - -``` -Figure 3: The lifecycle of a dynamically provisioned bucket, from -creation to deletion. - -The above diagrams illustrate a general expectation with respect to how a COSI system MAY manage the lifecycle of a bucket via the API presented in this specification. -Plugins SHOULD expose all RPCs for an interface: Controller plugins SHOULD implement all RPCs for the service. -Unsupported RPCs SHOULD return an appropriate error code that indicates such (e.g. `UNIMPLEMENTED`). - -## Container Object Storage Interface - -This section describes the interface between COSI systems and Plugins. - -### RPC Interface - -A CO interacts with an Plugin through RPCs. -Each SP MUST provide: - -* **Plugin**: A gRPC endpoint serving COSI RPCs that MUST be run on the Node. - -```protobuf -syntax = "proto3"; -package cosi.v1alpha1; - -import "google/protobuf/descriptor.proto"; - -option go_package = "sigs.k8s.io/container-object-storage-interface-spec;cosi"; - -extend google.protobuf.EnumOptions { - // Indicates that this enum is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - bool alpha_enum = 1116; -} - -extend google.protobuf.EnumValueOptions { - // Indicates that this enum value is OPTIONAL and part of an - // experimental API that may be deprecated and eventually removed - // between minor releases. - bool alpha_enum_value = 1116; -} - -extend google.protobuf.FieldOptions { - // Indicates that a field MAY contain information that is sensitive - // and MUST be treated as such (e.g. not logged). - bool cosi_secret = 1115; - - // Indicates that this field is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - bool alpha_field = 1116; -} - -extend google.protobuf.MessageOptions { - // Indicates that this message is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - bool alpha_message = 1116; -} - -extend google.protobuf.MethodOptions { - // Indicates that this method is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - bool alpha_method = 1116; -} - -extend google.protobuf.ServiceOptions { - // Indicates that this service is OPTIONAL and part of an experimental - // API that may be deprecated and eventually removed between minor - // releases. - bool alpha_service = 1116; -} - -service Identity { - // This call is meant to retrieve the unique provisioner Identity. - // This identity will have to be set in BucketClaim.DriverName field in order to invoke this specific provisioner. - rpc DriverGetInfo (DriverGetInfoRequest) returns (DriverGetInfoResponse) {} -} - -service Provisioner { - // This call is made to create the bucket in the backend. - // This call is idempotent - // 1. If a bucket that matches both name and parameters already exists, then OK (success) must be returned. - // 2. If a bucket by same name, but different parameters is provided, then the appropriate error code ALREADY_EXISTS must be returned. - rpc DriverCreateBucket (DriverCreateBucketRequest) returns (DriverCreateBucketResponse) {} - // This call is made to delete the bucket in the backend. - // If the bucket has already been deleted, then no error should be returned. - rpc DriverDeleteBucket (DriverDeleteBucketRequest) returns (DriverDeleteBucketResponse) {} - - // This call grants access to an account. The account_name in the request shall be used as a unique identifier to create credentials. - // The account_id returned in the response will be used as the unique identifier for deleting this access when calling DriverRevokeBucketAccess. - rpc DriverGrantBucketAccess (DriverGrantBucketAccessRequest) returns (DriverGrantBucketAccessResponse); - // This call revokes all access to a particular bucket from a principal. - rpc DriverRevokeBucketAccess (DriverRevokeBucketAccessRequest) returns (DriverRevokeBucketAccessResponse); -} - -// S3SignatureVersion is the version of the signing algorithm for all s3 requests -enum S3SignatureVersion { - UnknownSignature = 0; - // S3V2, Signature version v2 - S3V2 = 1; - // S3V4, Signature version v4 - S3V4 = 2; -} - -enum AnonymousBucketAccessMode { - UnknownBucketAccessMode = 0; - // Default, disallow uncredentialed access to the backend storage. - Private = 1; - // Read only, uncredentialed users can call ListBucket and GetObject. - ReadOnly = 2; - // Write only, uncredentialed users can only call PutObject. - WriteOnly = 3; - // Read/Write, uncredentialed users can read objects as well as PutObject. - ReadWrite = 4; -} - -enum AuthenticationType { - UnknownAuthenticationType = 0; - // Default, KEY based authentication. - Key = 1; - // Storageaccount based authentication. - IAM = 2; -} - -message S3 { - // region denotes the geographical region where the S3 server is running - string region = 1; - // signature_version denotes the signature version for signing all s3 requests - S3SignatureVersion signature_version = 2; -} - -message AzureBlob { - // storage_account is the id of the azure storage account - string storage_account = 1; -} - -message GCS { - // private_key_name denotes the name of the private key in the storage backend - string private_key_name = 1; - // project_id denotes the name of the project id in the storage backend - string project_id = 2; - // service_account denotes the name of the service account in the storage backend - string service_account = 3; -} - -message Protocol { - oneof type { - S3 s3 = 1; - AzureBlob azureBlob = 2; - GCS gcs = 3; - } -} - -message CredentialDetails { - // map of the details in the secrets for the protocol string - map secrets = 1; -} - -message DriverGetInfoRequest { - // Intentionally left blank -} - -message DriverGetInfoResponse { - // This field is REQUIRED - // The name MUST follow domain name notation format - // (https://tools.ietf.org/html/rfc1035#section-2.3.1). It SHOULD - // include the plugin's host company name and the plugin name, - // to minimize the possibility of collisions. It MUST be 63 - // characters or less, beginning and ending with an alphanumeric - // character ([a-z0-9A-Z]) with dashes (-), dots (.), and - // alphanumerics between. - string name = 1; -} - -message DriverCreateBucketRequest { - // This field is REQUIRED - // name specifies the name of the bucket that should be created. - string name = 1; - - // This field is OPTIONAL - // The caller should treat the values in parameters as opaque. - // The receiver is responsible for parsing and validating the values. - map parameters = 2; -} - -message DriverCreateBucketResponse { - // bucket_id returned here is expected to be the globally unique - // identifier for the bucket in the object storage provider. - string bucket_id = 1; - - // bucket_info returned here stores the data specific to the - // bucket required by the object storage provider to connect to the bucket. - Protocol bucket_info = 2; -} - -message DriverDeleteBucketRequest { - // This field is REQUIRED - // bucket_id is a globally unique identifier for the bucket - // in the object storage provider - string bucket_id = 1; - - // This field is OPTIONAL - // The caller should treat the values in delete_context as opaque. - // The receiver is responsible for parsing and validating the values. - map delete_context = 2; -} - -message DriverDeleteBucketResponse { - // Intentionally left blank -} - -message DriverGrantBucketAccessRequest { - // This field is REQUIRED - // bucket_id is a globally unique identifier for the bucket - // in the object storage provider - string bucket_id = 1; - - // This field is REQUIRED - // name field is used to define the name of the bucket access object. - string name = 2; - - // This field is REQUIRED - // Requested authentication type for the bucket access. - // Supported authentication types are KEY or IAM. - AuthenticationType authentication_type = 3; - - // This field is OPTIONAL - // The caller should treat the values in parameters as opaque. - // The receiver is responsible for parsing and validating the values. - map parameters = 4; -} - -message DriverGrantBucketAccessResponse { - // This field is REQUIRED - // This is the account_id that is being provided access. This will - // be required later to revoke access. - string account_id = 1; - - // This field is REQUIRED - // Credentials supplied for accessing the bucket ex: aws access key id and secret, etc. - map credentials = 2; -} - -message DriverRevokeBucketAccessRequest { - // This field is REQUIRED - // bucket_id is a globally unique identifier for the bucket - // in the object storage provider. - string bucket_id = 1; - - // This field is REQUIRED - // This is the account_id that is having its access revoked. - string account_id = 2; - - // This field is OPTIONAL - // The caller should treat the values in revoke_access_context as opaque. - // The receiver is responsible for parsing and validating the values. - map revoke_access_context = 3; -} - -message DriverRevokeBucketAccessResponse { - // Intentionally left blank -} - -``` - -#### Concurrency - -In general the Cluster Orchestrator (CO) is responsible for ensuring that there is no more than one call “in-flight” per Bucket at a given time. -Multiple calls to CreateBucket may result in error 'ALREADY_EXISTS' if the call succeeded early. Similarly DeleteBucket, GrantBucketAccess, RevokeBucketAccess will behave the same. - - -#### Field Requirements - -The requirements documented herein apply equally and without exception, unless otherwise noted, for the fields of all protobuf message types defined by this specification. -Violation of these requirements MAY result in RPC message data that is not compatible with all COSI systems, Plugin, and/or COSI middleware implementations. - -##### Size Limits - -COSI defines general size limits for fields of various types (see table below). -The general size limit for a particular field MAY be overridden by specifying a different size limit in said field's description. -Unless otherwise specified, fields SHALL NOT exceed the limits documented here. -These limits apply for messages generated by both COSI systems and plugins. - -| Size | Field Type | -|------------|---------------------| -| 128 bytes | string | -| 4 KiB | map | - -##### `REQUIRED` vs. `OPTIONAL` - -* A field noted as `REQUIRED` MUST be specified, subject to any per-RPC caveats; caveats SHOULD be rare. -* A `repeated` or `map` field listed as `REQUIRED` MUST contain at least 1 element. -* A field noted as `OPTIONAL` MAY be specified and the specification SHALL clearly define expected behavior for the default, zero-value of such fields. - -Scalar fields, even REQUIRED ones, will be defaulted if not specified and any field set to the default value will not be serialized over the wire as per [proto3](https://developers.google.com/protocol-buffers/docs/proto3#default). - -#### Timeouts - -Any of the RPCs defined in this spec MAY timeout and MAY be retried. -The COSI system MAY choose the maximum time it is willing to wait for a call, how long it waits between retries, and how many time it retries (these values are not negotiated between plugin and COSI system). - -Idempotency requirements ensure that a retried call with the same fields continues where it left off when retried. -The only way to cancel a call is to issue a "negation" call if one exists. -For example, issue a `DeleteBucket` call to cancel a pending `CreateBucket` operation, etc. - -### Error Scheme - -All COSI API calls defined in this spec MUST return a [standard gRPC status](https://github.com/grpc/grpc/blob/master/src/proto/grpc/status/status.proto). -Most gRPC libraries provide helper methods to set and read the status fields. - -The status `code` MUST contain a [canonical error code](https://github.com/grpc/grpc-go/blob/master/codes/codes.go). COSI systems MUST handle all valid error codes. Each RPC defines a set of gRPC error codes that MUST be returned by the plugin when specified conditions are encountered. In addition to those, if the conditions defined below are encountered, the plugin MUST return the associated gRPC error code. - -| Condition | gRPC Code | Description | Recovery Behavior | -|-----------|-----------|-------------|-------------------| -| Missing required field | 3 MISSING_ARGUMENT | Indicates that a required field is missing from the request. More human-readable information MAY be provided in the `status.message` field. | Caller MUST fix the request by adding the missing required field before retrying. | -| Invalid or unsupported field in the request | 3 INVALID_ARGUMENT | Indicates that the one or more fields in this field is either not allowed by the Plugin or has an invalid value. More human-readable information MAY be provided in the gRPC `status.message` field. | Caller MUST fix the field before retrying. | -| Permission denied | 7 PERMISSION_DENIED | The Plugin is able to derive or otherwise infer an identity from the secrets present within an RPC, but that identity does not have permission to invoke the RPC. | System administrator SHOULD ensure that requisite permissions are granted, after which point the caller MAY retry the attempted RPC. | -| Operation pending for bucket | 10 ABORTED | Indicates that there is already an operation pending for the specified bucket. In general the Cluster Orchestrator (CO) is responsible for ensuring that there is no more than one call "in-flight" per bucket at a given time. However, in some circumstances, the COSI system MAY lose state (for example when the COSI system crashes and restarts), and MAY issue multiple calls simultaneously for the same bucket. The Plugin, SHOULD handle this as gracefully as possible, and MAY return this error code to reject secondary calls. | Caller SHOULD ensure that there are no other calls pending for the specified volume, and then retry with exponential back off. | -| Call not implemented | 12 UNIMPLEMENTED | The invoked RPC is not implemented by the Plugin or disabled in the Plugin's current mode of operation. | Caller MUST NOT retry. Caller MAY call `GetPluginInfo` to discover Plugin info. | -| Not authenticated | 16 UNAUTHENTICATED | The invoked RPC does not carry secrets that are valid for authentication. | Caller SHALL either fix the secrets provided in the RPC, or otherwise regalvanize said secrets such that they will pass authentication by the Plugin for the attempted RPC, after which point the caller MAY retry the attempted RPC. | - -The status `message` MUST contain a human readable description of error, if the status `code` is not `OK`. -This string MAY be surfaced by COSI system to end users. - -The status `details` MUST be empty. In the future, this spec MAY require `details` to return a machine-parsable protobuf message if the status `code` is not `OK` to enable COSI system's to implement smarter error handling and fault resolution. - -### Provisioner Service RPC - -Provisioner service RPCs allow a COSI system to query a plugin for information, create and delete bucket as well as grant and revoke access to the bucket to various principals running the workload. -The general flow of the success case MAY be as follows (protos illustrated in YAML for brevity): - -1. COSI system queries metadata via Identity RPC. - -``` - # COSI system --(DriverGetInfo)--> Plugin - request: - response: - name: org.foo.whizbang.super-plugin -``` -``` -message DriverGetInfoRequest { - // Intentionally left blank -} - -message DriverGetInfoResponse { - string name = 1; -} -``` - -#### `DriverCreateBucket` - -A Controller Plugin MUST implement this RPC call. -This RPC will be called by the COSI system to provision a new bucket on behalf of a COSI user. - -This operation MUST be idempotent. -If a volume corresponding to the specified bucket `name` already exists, is accessible from `accessibility_requirements, and is compatible with the specified attributes of the bucket in the `DriverCreateBucket`, the Plugin MUST reply `0 OK` with the corresponding `DriverCreateBucketResponse`. - -``` -message DriverCreateBucketRequest { - // Idempotency - This name is generated by the COSI system to achieve - // idempotency. - // This field is REQUIRED. - string bucket_name = 1; - - // This field is OPTIONAL - // Protocol specific information required by the call is passed in as key,value pairs. - map bucket_context = 2; -} - -message DriverCreateBucketResponse { - // Intentionally left blank -} - -``` -##### CreateBucket Errors - -If the plugin is unable to complete the CreateBucket call successfully, it MUST return a non-ok gRPC code in the gRPC status. -If the conditions defined below are encountered, the plugin MUST return the specified gRPC error code. -The COSI system MUST implement the specified error recovery behavior when it encounters the gRPC error code. - -| Condition | gRPC Code | Description | Recovery Behavior | -|-----------|-----------|-------------|-------------------| -| Bucket Name invalid | 3 INVALID_ARGUMENT | Besides the general cases, this code MUST also be used to indicate when plugin cannot create a bucket due to parameter check on the backend. More human-readable information SHOULD be provided in the gRPC `status.message` field for the problem. | Caller should retry call with corrected parameter values.| -| Bucket already exists but is incompatible | 6 ALREADY_EXISTS | Indicates that a bucket corresponding to the specified bucket `name` already exists but is incompatible with the specified attributes. | Caller MUST fix the arguments or use a different `name` before retrying. | -| Unsupported value | 11 OUT_OF_RANGE | Indicates that the value requested cannot be used to provision the bucket. | Caller MUST fix the attributes before retrying. | - - -### Secrets Requirements (where applicable) - -Secrets MAY be required by plugin to complete a RPC request. -A secret is a string to string map where the key identifies the name of the secret (e.g. "username" or "password"), and the value contains the secret data (e.g. "bob" or "abc123"). -Each key MUST consist of alphanumeric characters, '-', '_' or '.'. -Each value MUST contain a valid string. -An SP MAY choose to accept binary (non-string) data by using a binary-to-text encoding scheme, like base64. -An SP SHALL advertise the requirements for required secret keys and values in documentation. -COSI system SHALL permit passing through the required secrets. -A COSI system MAY pass the same secrets to all RPCs, therefore the keys for all unique secrets that an SP expects MUST be unique across all COSI operations. -This information is sensitive and MUST be treated as such (not logged, etc.) by the COSI system. - - -## Protocol - -### Connectivity - -* A COSI system SHALL communicate with a Plugin using gRPC to access the `Provisioner` service. - * proto3 SHOULD be used with gRPC, as per the [official recommendations](http://www.grpc.io/docs/guides/#protocol-buffer-versions). - * All Plugins SHALL implement the REQUIRED Identity service RPCs. -* The COSI system SHALL provide the listen-address for the Plugin by way of the `COSI_ENDPOINT` environment variable. - Plugin components SHALL create, bind, and listen for RPCs on the specified listen address. - * Only UNIX Domain Sockets MAY be used as endpoints. - This will likely change in a future version of this specification to support non-UNIX platforms. -* All supported RPC services MUST be available at the listen address of the Plugin. - -### Security - -* The COSI system operator and Provisioner Sidecar SHOULD take steps to ensure that any and all communication between the COSI system and Plugin Service are secured according to best practices. -* Communication between a COSI system and a Plugin SHALL be transported over UNIX Domain Sockets. - * gRPC is compatible with UNIX Domain Sockets; it is the responsibility of the COSI system operator and Provisioner Sidecar to properly secure access to the Domain Socket using OS filesystem ACLs and/or other OS-specific security context tooling. - * SP’s supplying stand-alone Plugin controller appliances, or other remote components that are incompatible with UNIX Domain Sockets MUST provide a software component that proxies communication between a UNIX Domain Socket and the remote component(s). - Proxy components transporting communication over IP networks SHALL be responsible for securing communications over such networks. -* Both the COSI system and Plugin SHOULD avoid accidental leakage of sensitive information (such as redacting such information from log files). - -### Debugging - -* Debugging and tracing are supported by external, COSI-independent additions and extensions to gRPC APIs, such as [OpenTracing](https://github.com/grpc-ecosystem/grpc-opentracing). - -## Configuration and Operation - -### General Configuration - -* The `COSI_ENDPOINT` environment variable SHALL be supplied to the Plugin by the Provisioner Sidecar. -* An operator SHALL configure the COSI system to connect to the Plugin via the listen address identified by `COSI_ENDPOINT` variable. -* With exception to sensitive data, Plugin configuration SHOULD be specified by environment variables, whenever possible, instead of by command line flags or bind-mounted/injected files. - - -#### Plugin Bootstrap Example - -* Sidecar -> Plugin: `COSI_ENDPOINT=unix:///path/to/unix/domain/socket.sock`. -* Operator -> COSI system: use plugin at endpoint `unix:///path/to/unix/domain/socket.sock`. -* COSI system: monitor `/path/to/unix/domain/socket.sock`. -* Plugin: read `COSI_ENDPOINT`, create UNIX socket at specified path, bind and listen. -* COSI system: observe that socket now exists, establish connection. -* COSI system: invoke `GetPluginInfo. - -#### Filesystem - -* Plugins SHALL NOT specify requirements that include or otherwise reference directories and/or files on the root filesystem of the COSI system. -* Plugins SHALL NOT create additional files or directories adjacent to the UNIX socket specified by `COSI_ENDPOINT`; violations of this requirement constitute "abuse". - * The Provisioner Sidecar is the ultimate authority of the directory in which the UNIX socket endpoint is created and MAY enforce policies to prevent and/or mitigate abuse of the directory by Plugins. - -### Supervised Lifecycle Management - -* For Plugins packaged in software form: - * Plugin Packages SHOULD use a well-documented container image format (e.g., Docker, OCI). - * The chosen package image format MAY expose configurable Plugin properties as environment variables, unless otherwise indicated in the section below. - Variables so exposed SHOULD be assigned default values in the image manifest. - * A Provisioner Sidecar MAY programmatically evaluate or otherwise scan a Plugin Package’s image manifest in order to discover configurable environment variables. - * A Plugin SHALL NOT assume that an operator or Provisioner Sidecar will scan an image manifest for environment variables. - -#### Environment Variables - -* Variables defined by this specification SHALL be identifiable by their `COSI_` name prefix. -* Configuration properties not defined by the COSI specification SHALL NOT use the same `COSI_` name prefix; this prefix is reserved for common configuration properties defined by the COSI specification. -* The Provisioner Sidecar SHOULD supply all RECOMMENDED COSI environment variables to a Plugin. -* The Provisioner Sidecar SHALL supply all REQUIRED COSI environment variables to a Plugin. - -##### `COSI_ENDPOINT` - -Network endpoint at which a Plugin SHALL host COSI RPC services. The general format is: - - {scheme}://{authority}{endpoint} - -The following address types SHALL be supported by Plugins: - - unix:///path/to/unix/socket.sock - -Note: All UNIX endpoints SHALL end with `.sock`. See [gRPC Name Resolution](https://github.com/grpc/grpc/blob/master/doc/naming.md). - -This variable is REQUIRED. - -#### Operational Recommendations - -The Provisioner Sidecar expects that a Plugin SHALL act as a long-running service vs. an on-demand, CLI-driven process. - -Supervised plugins MAY be isolated and/or resource-bounded. - -##### Logging - -* Plugins SHOULD generate log messages to ONLY standard output and/or standard error. - * In this case the Provisioner Sidecar SHALL assume responsibility for all log lifecycle management. -* Plugin implementations that deviate from the above recommendation SHALL clearly and unambiguously document the following: - * Logging configuration flags and/or variables, including working sample configurations. - * Default log destination(s) (where do the logs go if no configuration is specified?) - * Log lifecycle management ownership and related guidance (size limits, rate limits, rolling, archiving, expunging, etc.) applicable to the logging mechanism embedded within the Plugin. -* Plugins SHOULD NOT write potentially sensitive data to logs (e.g. secrets). - -##### Available Services - -* Plugin Packages MAY support all or a subset of COSI services; service combinations MAY be configurable at runtime by the Provisioner Sidecar. - * A plugin MUST know the "mode" in which it is operating (e.g. node, controller, or both). - * This specification does not dictate the mechanism by which mode of operation MUST be discovered, and instead places that burden upon the SP. -* Misconfigured plugin software SHOULD fail-fast with an OS-appropriate error code. - -##### Linux Capabilities - -* Provisioner Sidecar SHALL guarantee that plugins will have necessary permission to connect to their backend Object Storage System -* Plugins SHOULD clearly document any additionally required capabilities and/or security context. - -##### Namespaces - -* A Plugin SHOULD NOT assume that it is in the same [Linux namespaces](https://en.wikipedia.org/wiki/Linux_namespaces) as the Provisioner Sidecar. - The COSI system MUST clearly document the CSI dependency requirements on ephemeral volumes for the plugins and the Provisioner Sidecar SHALL satisfy the COSI system’s requirements. - -##### Cgroup Isolation - -* A Plugin MAY be constrained by cgroups. -* An operator or Provisioner Sidecar MAY configure the devices cgroup subsystem to ensure that a Plugin MAY access requisite devices. -* A Provisioner Sidecar MAY define resource limits for a Plugin. - -##### Resource Requirements - -* SPs SHOULD unambiguously document all of a Plugin’s resource requirements.