diff --git a/apis/objectstorage.k8s.io/v1alpha1/openapi_generated.go b/apis/objectstorage.k8s.io/v1alpha1/openapi_generated.go index 063860b3..424fbde3 100644 --- a/apis/objectstorage.k8s.io/v1alpha1/openapi_generated.go +++ b/apis/objectstorage.k8s.io/v1alpha1/openapi_generated.go @@ -102,20 +102,17 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketSpec"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketStatus"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketStatus"), }, }, }, @@ -148,20 +145,17 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessSpec"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessStatus"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessStatus"), }, }, }, @@ -194,8 +188,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "policyActionsConfigMap": { @@ -210,9 +203,8 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", + Type: []string{"string"}, + Format: "", }, }, }, @@ -248,8 +240,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -258,8 +249,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessClass"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessClass"), }, }, }, @@ -296,8 +286,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -306,8 +295,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccess"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccess"), }, }, }, @@ -344,20 +332,17 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessRequestSpec"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessRequestSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessRequestStatus"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessRequestStatus"), }, }, }, @@ -390,8 +375,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -400,8 +384,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessRequest"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketAccessRequest"), }, }, }, @@ -442,9 +425,8 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "bucketAccessClassName": { SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", + Type: []string{"string"}, + Format: "", }, }, }, @@ -468,9 +450,8 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "accessGranted": { SchemaProps: spec.SchemaProps{ - Default: false, - Type: []string{"boolean"}, - Format: "", + Type: []string{"boolean"}, + Format: "", }, }, "bucketAccessName": { @@ -507,24 +488,12 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Ref: ref("k8s.io/api/core/v1.ObjectReference"), }, }, - "mintedSecretName": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, "policyActionsConfigMapData": { SchemaProps: spec.SchemaProps{ Type: []string{"string"}, Format: "", }, }, - "accountID": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, "parameters": { SchemaProps: spec.SchemaProps{ Type: []string{"object"}, @@ -532,9 +501,8 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", + Type: []string{"string"}, + Format: "", }, }, }, @@ -560,6 +528,18 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Format: "", }, }, + "mintedSecretName": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "accountID": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, "accessGranted": { SchemaProps: spec.SchemaProps{ Type: []string{"boolean"}, @@ -594,8 +574,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "provisioner": { @@ -621,9 +600,8 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", + Type: []string{"string"}, + Format: "", }, }, }, @@ -631,8 +609,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "protocol": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.Protocol"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.Protocol"), }, }, "deletionPolicy": { @@ -648,9 +625,8 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", + Type: []string{"string"}, + Format: "", }, }, }, @@ -687,8 +663,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -697,8 +672,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketClass"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketClass"), }, }, }, @@ -735,8 +709,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -745,8 +718,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.Bucket"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.Bucket"), }, }, }, @@ -783,20 +755,17 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketRequestSpec"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketRequestSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketRequestStatus"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketRequestStatus"), }, }, }, @@ -829,8 +798,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "metadata": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -839,8 +807,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketRequest"), + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.BucketRequest"), }, }, }, @@ -893,9 +860,8 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "bucketAvailable": { SchemaProps: spec.SchemaProps{ - Default: false, - Type: []string{"boolean"}, - Format: "", + Type: []string{"boolean"}, + Format: "", }, }, "bucketName": { @@ -944,9 +910,8 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", + Type: []string{"string"}, + Format: "", }, }, }, @@ -954,14 +919,7 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "protocol": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.Protocol"), - }, - }, - "bucketID": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", + Ref: ref("sigs.k8s.io/container-object-storage-interface-api/apis/objectstorage.k8s.io/v1alpha1.Protocol"), }, }, "parameters": { @@ -971,9 +929,8 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", + Type: []string{"string"}, + Format: "", }, }, }, @@ -981,9 +938,8 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp }, "deletionPolicy": { SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", + Type: []string{"string"}, + Format: "", }, }, }, @@ -1013,6 +969,12 @@ func schema_container_object_storage_interface_api_apis_objectstoragek8sio_v1alp Format: "", }, }, + "bucketID": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, }, }, }, diff --git a/apis/objectstorage.k8s.io/v1alpha1/types.go b/apis/objectstorage.k8s.io/v1alpha1/types.go index 5f19281c..ce9bf614 100644 --- a/apis/objectstorage.k8s.io/v1alpha1/types.go +++ b/apis/objectstorage.k8s.io/v1alpha1/types.go @@ -72,9 +72,6 @@ type BucketSpec struct { Protocol Protocol `json:"protocol"` - // +optional - BucketID string `json:"bucketID,omitempty"` - // +optional Parameters map[string]string `json:"parameters,omitempty"` @@ -88,6 +85,9 @@ type BucketStatus struct { // +optional BucketAvailable bool `json:"bucketAvailable,omitempty"` + + // +optional + BucketID string `json:"bucketID,omitempty"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object @@ -239,14 +239,8 @@ type BucketAccessSpec struct { // +optional ServiceAccount *corev1.ObjectReference `json:"serviceAccount,omitempty"` - // +optional - MintedSecretName string `json:"mintedSecretName,omitempty"` - PolicyActionsConfigMapData string `json:"policyActionsConfigMapData,omitempty"` - // +optional - AccountID string `json:"accountID,omitempty"` - // +optional Parameters map[string]string `json:"parameters,omitempty"` } @@ -255,6 +249,12 @@ type BucketAccessStatus struct { // +optional Message string `json:"message,omitempty"` + // +optional + MintedSecretName string `json:"mintedSecretName,omitempty"` + + // +optional + AccountID string `json:"accountID,omitempty"` + // +optional AccessGranted bool `json:"accessGranted,omitempty"` } diff --git a/clientset/fake/register.go b/clientset/fake/register.go index a7727906..b6266233 100644 --- a/clientset/fake/register.go +++ b/clientset/fake/register.go @@ -29,7 +29,7 @@ import ( var scheme = runtime.NewScheme() var codecs = serializer.NewCodecFactory(scheme) - +var parameterCodec = runtime.NewParameterCodec(scheme) var localSchemeBuilder = runtime.SchemeBuilder{ objectstoragev1alpha1.AddToScheme, } diff --git a/controller/controller.go b/controller/controller.go index c97a3b94..0a1e34e2 100644 --- a/controller/controller.go +++ b/controller/controller.go @@ -284,6 +284,7 @@ func (c *ObjectStorageController) processNextItem(ctx context.Context) bool { err = delete(ctx, o.Object) if err == nil { o.Indexer.Delete(o.Object) + c.opMap.Delete(uuid) } default: panic("unknown item in queue") @@ -320,7 +321,6 @@ func (c *ObjectStorageController) GetOpLock(op types.UID) *sync.Mutex { // handleErr checks if an error happened and makes sure we will retry later. func (c *ObjectStorageController) handleErr(err error, uuid types.UID) { if err == nil { - c.opMap.Delete(uuid) return } c.queue.AddRateLimited(uuid) diff --git a/crds/objectstorage.k8s.io_bucketaccessclasses.yaml b/crds/objectstorage.k8s.io_bucketaccessclasses.yaml index 18de5b5d..4fd63c15 100644 --- a/crds/objectstorage.k8s.io_bucketaccessclasses.yaml +++ b/crds/objectstorage.k8s.io_bucketaccessclasses.yaml @@ -4,7 +4,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.4.1 + controller-gen.kubebuilder.io/version: v0.5.0 creationTimestamp: null name: bucketaccessclasses.objectstorage.k8s.io spec: @@ -21,14 +21,10 @@ spec: openAPIV3Schema: properties: apiVersion: - description: 'APIVersion defines the versioned schema of this representation - of an object. Servers should convert recognized schemas to the latest - internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' type: string kind: - description: 'Kind is a string value representing the REST resource this - object represents. Servers may infer this from the endpoint the client - submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' type: string metadata: type: object @@ -37,43 +33,13 @@ spec: type: string type: object policyActionsConfigMap: - description: 'ObjectReference contains enough information to let you inspect - or modify the referred object. --- New uses of this type are discouraged - because of difficulty describing its usage when embedded in APIs. 1. - Ignored fields. It includes many fields which are not generally honored. For - instance, ResourceVersion and FieldPath are both very rarely valid in - actual usage. 2. Invalid usage help. It is impossible to add specific - help for individual usage. In most embedded usages, there are particular restrictions - like, "must refer only to types A and B" or "UID not honored" or "name - must be restricted". Those cannot be well described when embedded. 3. - Inconsistent validation. Because the usages are different, the validation - rules are different by usage, which makes it hard for users to predict - what will happen. 4. The fields are both imprecise and overly precise. Kind - is not a precise mapping to a URL. This can produce ambiguity during - interpretation and require a REST mapping. In most cases, the dependency - is on the group,resource tuple and the version of the actual struct - is irrelevant. 5. We cannot easily change it. Because this type is - embedded in many locations, updates to this type will affect numerous - schemas. Don''t make new APIs embed an underspecified API type they - do not control. Instead of using this type, create a locally provided - and used type that is well-focused on your reference. For example, ServiceReferences - for admission registration: https://github.com/kubernetes/api/blob/release-1.17/admissionregistration/v1/types.go#L533 - .' + description: 'ObjectReference contains enough information to let you inspect or modify the referred object. --- New uses of this type are discouraged because of difficulty describing its usage when embedded in APIs. 1. Ignored fields. It includes many fields which are not generally honored. For instance, ResourceVersion and FieldPath are both very rarely valid in actual usage. 2. Invalid usage help. It is impossible to add specific help for individual usage. In most embedded usages, there are particular restrictions like, "must refer only to types A and B" or "UID not honored" or "name must be restricted". Those cannot be well described when embedded. 3. Inconsistent validation. Because the usages are different, the validation rules are different by usage, which makes it hard for users to predict what will happen. 4. The fields are both imprecise and overly precise. Kind is not a precise mapping to a URL. This can produce ambiguity during interpretation and require a REST mapping. In most cases, the dependency is on the group,resource tuple and the version of the actual struct is irrelevant. 5. We cannot easily change it. Because this type is embedded in many locations, updates to this type will affect numerous schemas. Don''t make new APIs embed an underspecified API type they do not control. Instead of using this type, create a locally provided and used type that is well-focused on your reference. For example, ServiceReferences for admission registration: https://github.com/kubernetes/api/blob/release-1.17/admissionregistration/v1/types.go#L533 .' properties: apiVersion: description: API version of the referent. type: string fieldPath: - description: 'If referring to a piece of an object instead of an entire - object, this string should contain a valid JSON/Go field access - statement, such as desiredState.manifest.containers[2]. For example, - if the object reference is to a container within a pod, this would - take on a value like: "spec.containers{name}" (where "name" refers - to the name of the container that triggered the event) or if no - container name is specified "spec.containers[2]" (container with - index 2 in this pod). This syntax is chosen only to have some well-defined - way of referencing a part of an object. TODO: this design is not - final and this field is subject to change in the future.' + description: 'If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. TODO: this design is not final and this field is subject to change in the future.' type: string kind: description: 'Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' @@ -85,8 +51,7 @@ spec: description: 'Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/' type: string resourceVersion: - description: 'Specific resourceVersion to which this reference is - made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency' + description: 'Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency' type: string uid: description: 'UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids' diff --git a/crds/objectstorage.k8s.io_bucketaccesses.yaml b/crds/objectstorage.k8s.io_bucketaccesses.yaml index 734c4546..dd84ec95 100644 --- a/crds/objectstorage.k8s.io_bucketaccesses.yaml +++ b/crds/objectstorage.k8s.io_bucketaccesses.yaml @@ -4,7 +4,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.4.1 + controller-gen.kubebuilder.io/version: v0.5.0 creationTimestamp: null name: bucketaccesses.objectstorage.k8s.io spec: @@ -21,62 +21,23 @@ spec: openAPIV3Schema: properties: apiVersion: - description: 'APIVersion defines the versioned schema of this representation - of an object. Servers should convert recognized schemas to the latest - internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' type: string kind: - description: 'Kind is a string value representing the REST resource this - object represents. Servers may infer this from the endpoint the client - submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' type: string metadata: type: object spec: properties: - accountID: - type: string bucketAccessRequest: - description: 'ObjectReference contains enough information to let you - inspect or modify the referred object. --- New uses of this type - are discouraged because of difficulty describing its usage when - embedded in APIs. 1. Ignored fields. It includes many fields which - are not generally honored. For instance, ResourceVersion and FieldPath - are both very rarely valid in actual usage. 2. Invalid usage help. It - is impossible to add specific help for individual usage. In most - embedded usages, there are particular restrictions like, "must - refer only to types A and B" or "UID not honored" or "name must - be restricted". Those cannot be well described when embedded. 3. - Inconsistent validation. Because the usages are different, the - validation rules are different by usage, which makes it hard for - users to predict what will happen. 4. The fields are both imprecise - and overly precise. Kind is not a precise mapping to a URL. This - can produce ambiguity during interpretation and require a REST - mapping. In most cases, the dependency is on the group,resource - tuple and the version of the actual struct is irrelevant. 5. - We cannot easily change it. Because this type is embedded in many - locations, updates to this type will affect numerous schemas. Don''t - make new APIs embed an underspecified API type they do not control. - Instead of using this type, create a locally provided and used type - that is well-focused on your reference. For example, ServiceReferences - for admission registration: https://github.com/kubernetes/api/blob/release-1.17/admissionregistration/v1/types.go#L533 - .' + description: 'ObjectReference contains enough information to let you inspect or modify the referred object. --- New uses of this type are discouraged because of difficulty describing its usage when embedded in APIs. 1. Ignored fields. It includes many fields which are not generally honored. For instance, ResourceVersion and FieldPath are both very rarely valid in actual usage. 2. Invalid usage help. It is impossible to add specific help for individual usage. In most embedded usages, there are particular restrictions like, "must refer only to types A and B" or "UID not honored" or "name must be restricted". Those cannot be well described when embedded. 3. Inconsistent validation. Because the usages are different, the validation rules are different by usage, which makes it hard for users to predict what will happen. 4. The fields are both imprecise and overly precise. Kind is not a precise mapping to a URL. This can produce ambiguity during interpretation and require a REST mapping. In most cases, the dependency is on the group,resource tuple and the version of the actual struct is irrelevant. 5. We cannot easily change it. Because this type is embedded in many locations, updates to this type will affect numerous schemas. Don''t make new APIs embed an underspecified API type they do not control. Instead of using this type, create a locally provided and used type that is well-focused on your reference. For example, ServiceReferences for admission registration: https://github.com/kubernetes/api/blob/release-1.17/admissionregistration/v1/types.go#L533 .' properties: apiVersion: description: API version of the referent. type: string fieldPath: - description: 'If referring to a piece of an object instead of - an entire object, this string should contain a valid JSON/Go - field access statement, such as desiredState.manifest.containers[2]. - For example, if the object reference is to a container within - a pod, this would take on a value like: "spec.containers{name}" - (where "name" refers to the name of the container that triggered - the event) or if no container name is specified "spec.containers[2]" - (container with index 2 in this pod). This syntax is chosen - only to have some well-defined way of referencing a part of - an object. TODO: this design is not final and this field is - subject to change in the future.' + description: 'If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. TODO: this design is not final and this field is subject to change in the future.' type: string kind: description: 'Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' @@ -88,8 +49,7 @@ spec: description: 'Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/' type: string resourceVersion: - description: 'Specific resourceVersion to which this reference - is made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency' + description: 'Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency' type: string uid: description: 'UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids' @@ -97,8 +57,6 @@ spec: type: object bucketName: type: string - mintedSecretName: - type: string parameters: additionalProperties: type: string @@ -106,46 +64,13 @@ spec: policyActionsConfigMapData: type: string serviceAccount: - description: 'ObjectReference contains enough information to let you - inspect or modify the referred object. --- New uses of this type - are discouraged because of difficulty describing its usage when - embedded in APIs. 1. Ignored fields. It includes many fields which - are not generally honored. For instance, ResourceVersion and FieldPath - are both very rarely valid in actual usage. 2. Invalid usage help. It - is impossible to add specific help for individual usage. In most - embedded usages, there are particular restrictions like, "must - refer only to types A and B" or "UID not honored" or "name must - be restricted". Those cannot be well described when embedded. 3. - Inconsistent validation. Because the usages are different, the - validation rules are different by usage, which makes it hard for - users to predict what will happen. 4. The fields are both imprecise - and overly precise. Kind is not a precise mapping to a URL. This - can produce ambiguity during interpretation and require a REST - mapping. In most cases, the dependency is on the group,resource - tuple and the version of the actual struct is irrelevant. 5. - We cannot easily change it. Because this type is embedded in many - locations, updates to this type will affect numerous schemas. Don''t - make new APIs embed an underspecified API type they do not control. - Instead of using this type, create a locally provided and used type - that is well-focused on your reference. For example, ServiceReferences - for admission registration: https://github.com/kubernetes/api/blob/release-1.17/admissionregistration/v1/types.go#L533 - .' + description: 'ObjectReference contains enough information to let you inspect or modify the referred object. --- New uses of this type are discouraged because of difficulty describing its usage when embedded in APIs. 1. Ignored fields. It includes many fields which are not generally honored. For instance, ResourceVersion and FieldPath are both very rarely valid in actual usage. 2. Invalid usage help. It is impossible to add specific help for individual usage. In most embedded usages, there are particular restrictions like, "must refer only to types A and B" or "UID not honored" or "name must be restricted". Those cannot be well described when embedded. 3. Inconsistent validation. Because the usages are different, the validation rules are different by usage, which makes it hard for users to predict what will happen. 4. The fields are both imprecise and overly precise. Kind is not a precise mapping to a URL. This can produce ambiguity during interpretation and require a REST mapping. In most cases, the dependency is on the group,resource tuple and the version of the actual struct is irrelevant. 5. We cannot easily change it. Because this type is embedded in many locations, updates to this type will affect numerous schemas. Don''t make new APIs embed an underspecified API type they do not control. Instead of using this type, create a locally provided and used type that is well-focused on your reference. For example, ServiceReferences for admission registration: https://github.com/kubernetes/api/blob/release-1.17/admissionregistration/v1/types.go#L533 .' properties: apiVersion: description: API version of the referent. type: string fieldPath: - description: 'If referring to a piece of an object instead of - an entire object, this string should contain a valid JSON/Go - field access statement, such as desiredState.manifest.containers[2]. - For example, if the object reference is to a container within - a pod, this would take on a value like: "spec.containers{name}" - (where "name" refers to the name of the container that triggered - the event) or if no container name is specified "spec.containers[2]" - (container with index 2 in this pod). This syntax is chosen - only to have some well-defined way of referencing a part of - an object. TODO: this design is not final and this field is - subject to change in the future.' + description: 'If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. TODO: this design is not final and this field is subject to change in the future.' type: string kind: description: 'Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' @@ -157,8 +82,7 @@ spec: description: 'Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/' type: string resourceVersion: - description: 'Specific resourceVersion to which this reference - is made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency' + description: 'Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency' type: string uid: description: 'UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids' @@ -169,8 +93,12 @@ spec: properties: accessGranted: type: boolean + accountID: + type: string message: type: string + mintedSecretName: + type: string type: object type: object served: true diff --git a/crds/objectstorage.k8s.io_bucketaccessrequests.yaml b/crds/objectstorage.k8s.io_bucketaccessrequests.yaml index f3f62a9e..4528c482 100644 --- a/crds/objectstorage.k8s.io_bucketaccessrequests.yaml +++ b/crds/objectstorage.k8s.io_bucketaccessrequests.yaml @@ -4,7 +4,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.4.1 + controller-gen.kubebuilder.io/version: v0.5.0 creationTimestamp: null name: bucketaccessrequests.objectstorage.k8s.io spec: @@ -21,14 +21,10 @@ spec: openAPIV3Schema: properties: apiVersion: - description: 'APIVersion defines the versioned schema of this representation - of an object. Servers should convert recognized schemas to the latest - internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' type: string kind: - description: 'Kind is a string value representing the REST resource this - object represents. Servers may infer this from the endpoint the client - submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' type: string metadata: type: object diff --git a/crds/objectstorage.k8s.io_bucketclasses.yaml b/crds/objectstorage.k8s.io_bucketclasses.yaml index 6c106336..b9e1c15a 100644 --- a/crds/objectstorage.k8s.io_bucketclasses.yaml +++ b/crds/objectstorage.k8s.io_bucketclasses.yaml @@ -4,7 +4,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.4.1 + controller-gen.kubebuilder.io/version: v0.5.0 creationTimestamp: null name: bucketclasses.objectstorage.k8s.io spec: @@ -26,9 +26,7 @@ spec: type: array x-kubernetes-list-type: atomic apiVersion: - description: 'APIVersion defines the versioned schema of this representation - of an object. Servers should convert recognized schemas to the latest - internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' type: string deletionPolicy: default: retain @@ -37,9 +35,7 @@ spec: default: false type: boolean kind: - description: 'Kind is a string value representing the REST resource this - object represents. Servers may infer this from the endpoint the client - submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' type: string metadata: type: object diff --git a/crds/objectstorage.k8s.io_bucketrequests.yaml b/crds/objectstorage.k8s.io_bucketrequests.yaml index 1bd27a2d..d0d0b915 100644 --- a/crds/objectstorage.k8s.io_bucketrequests.yaml +++ b/crds/objectstorage.k8s.io_bucketrequests.yaml @@ -4,7 +4,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.4.1 + controller-gen.kubebuilder.io/version: v0.5.0 creationTimestamp: null name: bucketrequests.objectstorage.k8s.io spec: @@ -21,14 +21,10 @@ spec: openAPIV3Schema: properties: apiVersion: - description: 'APIVersion defines the versioned schema of this representation - of an object. Servers should convert recognized schemas to the latest - internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' type: string kind: - description: 'Kind is a string value representing the REST resource this - object represents. Servers may infer this from the endpoint the client - submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' type: string metadata: type: object diff --git a/crds/objectstorage.k8s.io_buckets.yaml b/crds/objectstorage.k8s.io_buckets.yaml index e2aae14a..7fd5cc43 100644 --- a/crds/objectstorage.k8s.io_buckets.yaml +++ b/crds/objectstorage.k8s.io_buckets.yaml @@ -4,7 +4,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.4.1 + controller-gen.kubebuilder.io/version: v0.5.0 creationTimestamp: null name: buckets.objectstorage.k8s.io spec: @@ -21,14 +21,10 @@ spec: openAPIV3Schema: properties: apiVersion: - description: 'APIVersion defines the versioned schema of this representation - of an object. Servers should convert recognized schemas to the latest - internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' type: string kind: - description: 'Kind is a string value representing the REST resource this - object represents. Servers may infer this from the endpoint the client - submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' type: string metadata: type: object @@ -41,49 +37,14 @@ spec: x-kubernetes-list-type: atomic bucketClassName: type: string - bucketID: - type: string bucketRequest: - description: 'ObjectReference contains enough information to let you - inspect or modify the referred object. --- New uses of this type - are discouraged because of difficulty describing its usage when - embedded in APIs. 1. Ignored fields. It includes many fields which - are not generally honored. For instance, ResourceVersion and FieldPath - are both very rarely valid in actual usage. 2. Invalid usage help. It - is impossible to add specific help for individual usage. In most - embedded usages, there are particular restrictions like, "must - refer only to types A and B" or "UID not honored" or "name must - be restricted". Those cannot be well described when embedded. 3. - Inconsistent validation. Because the usages are different, the - validation rules are different by usage, which makes it hard for - users to predict what will happen. 4. The fields are both imprecise - and overly precise. Kind is not a precise mapping to a URL. This - can produce ambiguity during interpretation and require a REST - mapping. In most cases, the dependency is on the group,resource - tuple and the version of the actual struct is irrelevant. 5. - We cannot easily change it. Because this type is embedded in many - locations, updates to this type will affect numerous schemas. Don''t - make new APIs embed an underspecified API type they do not control. - Instead of using this type, create a locally provided and used type - that is well-focused on your reference. For example, ServiceReferences - for admission registration: https://github.com/kubernetes/api/blob/release-1.17/admissionregistration/v1/types.go#L533 - .' + description: 'ObjectReference contains enough information to let you inspect or modify the referred object. --- New uses of this type are discouraged because of difficulty describing its usage when embedded in APIs. 1. Ignored fields. It includes many fields which are not generally honored. For instance, ResourceVersion and FieldPath are both very rarely valid in actual usage. 2. Invalid usage help. It is impossible to add specific help for individual usage. In most embedded usages, there are particular restrictions like, "must refer only to types A and B" or "UID not honored" or "name must be restricted". Those cannot be well described when embedded. 3. Inconsistent validation. Because the usages are different, the validation rules are different by usage, which makes it hard for users to predict what will happen. 4. The fields are both imprecise and overly precise. Kind is not a precise mapping to a URL. This can produce ambiguity during interpretation and require a REST mapping. In most cases, the dependency is on the group,resource tuple and the version of the actual struct is irrelevant. 5. We cannot easily change it. Because this type is embedded in many locations, updates to this type will affect numerous schemas. Don''t make new APIs embed an underspecified API type they do not control. Instead of using this type, create a locally provided and used type that is well-focused on your reference. For example, ServiceReferences for admission registration: https://github.com/kubernetes/api/blob/release-1.17/admissionregistration/v1/types.go#L533 .' properties: apiVersion: description: API version of the referent. type: string fieldPath: - description: 'If referring to a piece of an object instead of - an entire object, this string should contain a valid JSON/Go - field access statement, such as desiredState.manifest.containers[2]. - For example, if the object reference is to a container within - a pod, this would take on a value like: "spec.containers{name}" - (where "name" refers to the name of the container that triggered - the event) or if no container name is specified "spec.containers[2]" - (container with index 2 in this pod). This syntax is chosen - only to have some well-defined way of referencing a part of - an object. TODO: this design is not final and this field is - subject to change in the future.' + description: 'If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: "spec.containers{name}" (where "name" refers to the name of the container that triggered the event) or if no container name is specified "spec.containers[2]" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object. TODO: this design is not final and this field is subject to change in the future.' type: string kind: description: 'Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' @@ -95,8 +56,7 @@ spec: description: 'Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/' type: string resourceVersion: - description: 'Specific resourceVersion to which this reference - is made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency' + description: 'Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency' type: string uid: description: 'UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids' @@ -154,6 +114,8 @@ spec: properties: bucketAvailable: type: boolean + bucketID: + type: string message: type: string type: object diff --git a/go.mod b/go.mod index 3dfe9ef6..aceb6e1c 100644 --- a/go.mod +++ b/go.mod @@ -4,14 +4,12 @@ go 1.15 require ( github.com/go-openapi/spec v0.19.12 - github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b github.com/onsi/ginkgo v1.14.2 // indirect - github.com/spf13/cobra v0.0.5 github.com/spf13/viper v1.3.2 - golang.org/x/time v0.0.0-20191024005414-555d28b269f0 k8s.io/api v0.19.4 k8s.io/apimachinery v0.19.4 k8s.io/client-go v0.19.4 + k8s.io/klog/v2 v2.2.0 k8s.io/kube-openapi v0.0.0-20200923155610-8b5066479488 sigs.k8s.io/container-object-storage-interface-spec v0.0.0-20210329232956-3bbacbbc9c19 sigs.k8s.io/controller-runtime v0.6.3 diff --git a/go.sum b/go.sum index 164afeab..d5e80bca 100644 --- a/go.sum +++ b/go.sum @@ -202,6 +202,7 @@ github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm4 github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.1 h1:Gkbcsh/GbpXz7lPftLA3P6TYMwjCLYm83jiFQZF/3gY= github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.1.2 h1:EVhdT+1Kseyi1/pUmXKaFxYsDNy9RQYkMWRH68J/W7Y= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= 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= @@ -344,6 +345,7 @@ github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXf github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.4.0 h1:2E4SXV/wtOkTonXsotYi4li6zVWxYlZuYNCXe9XRJyk= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= +github.com/stretchr/testify v1.5.1 h1:nOGnQDM7FYENwehXlg/kFVnos3rEvtKTjRvOWSzb6H4= github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/tidwall/pretty v1.0.0/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk= github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= @@ -615,8 +617,6 @@ k8s.io/utils v0.0.0-20200729134348-d5654de09c73 h1:uJmqzgNWG7XyClnU/mLPBWwfKKF1K k8s.io/utils v0.0.0-20200729134348-d5654de09c73/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.7/go.mod h1:PHgbrJT7lCHcxMU+mDHEm+nx46H4zuuHZkDP6icnhu0= -sigs.k8s.io/container-object-storage-interface-spec v0.0.0-20210224211525-dfa3af562c18 h1:TIx7kV6/3ZSQ5BETBx1QG1Va28zv1LZAvqRjs28n8ss= -sigs.k8s.io/container-object-storage-interface-spec v0.0.0-20210224211525-dfa3af562c18/go.mod h1:kafkL5l/lTUrZXhVi/9p1GzpEE/ts29BkWkL3Ao33WU= sigs.k8s.io/container-object-storage-interface-spec v0.0.0-20210329232956-3bbacbbc9c19 h1:LrLrBCBqO7O/VjJtTrDSj3/f7hLSQaCIouLZFnHGxFg= sigs.k8s.io/container-object-storage-interface-spec v0.0.0-20210329232956-3bbacbbc9c19/go.mod h1:kafkL5l/lTUrZXhVi/9p1GzpEE/ts29BkWkL3Ao33WU= sigs.k8s.io/controller-runtime v0.6.3 h1:SBbr+inLPEKhvlJtrvDcwIpm+uhDvp63Bl72xYJtoOE= diff --git a/listers/objectstorage.k8s.io/v1alpha1/bucket.go b/listers/objectstorage.k8s.io/v1alpha1/bucket.go index 35b06d5f..16d40085 100644 --- a/listers/objectstorage.k8s.io/v1alpha1/bucket.go +++ b/listers/objectstorage.k8s.io/v1alpha1/bucket.go @@ -26,13 +26,10 @@ import ( ) // BucketLister helps list Buckets. -// All objects returned here must be treated as read-only. type BucketLister interface { // List lists all Buckets in the indexer. - // Objects returned here must be treated as read-only. List(selector labels.Selector) (ret []*v1alpha1.Bucket, err error) // Get retrieves the Bucket from the index for a given name. - // Objects returned here must be treated as read-only. Get(name string) (*v1alpha1.Bucket, error) BucketListerExpansion } diff --git a/listers/objectstorage.k8s.io/v1alpha1/bucketaccess.go b/listers/objectstorage.k8s.io/v1alpha1/bucketaccess.go index 51eb357f..69308e27 100644 --- a/listers/objectstorage.k8s.io/v1alpha1/bucketaccess.go +++ b/listers/objectstorage.k8s.io/v1alpha1/bucketaccess.go @@ -26,13 +26,10 @@ import ( ) // BucketAccessLister helps list BucketAccesses. -// All objects returned here must be treated as read-only. type BucketAccessLister interface { // List lists all BucketAccesses in the indexer. - // Objects returned here must be treated as read-only. List(selector labels.Selector) (ret []*v1alpha1.BucketAccess, err error) // Get retrieves the BucketAccess from the index for a given name. - // Objects returned here must be treated as read-only. Get(name string) (*v1alpha1.BucketAccess, error) BucketAccessListerExpansion } diff --git a/listers/objectstorage.k8s.io/v1alpha1/bucketaccessclass.go b/listers/objectstorage.k8s.io/v1alpha1/bucketaccessclass.go index 146ac41d..c4bbc9aa 100644 --- a/listers/objectstorage.k8s.io/v1alpha1/bucketaccessclass.go +++ b/listers/objectstorage.k8s.io/v1alpha1/bucketaccessclass.go @@ -26,13 +26,10 @@ import ( ) // BucketAccessClassLister helps list BucketAccessClasses. -// All objects returned here must be treated as read-only. type BucketAccessClassLister interface { // List lists all BucketAccessClasses in the indexer. - // Objects returned here must be treated as read-only. List(selector labels.Selector) (ret []*v1alpha1.BucketAccessClass, err error) // Get retrieves the BucketAccessClass from the index for a given name. - // Objects returned here must be treated as read-only. Get(name string) (*v1alpha1.BucketAccessClass, error) BucketAccessClassListerExpansion } diff --git a/listers/objectstorage.k8s.io/v1alpha1/bucketaccessrequest.go b/listers/objectstorage.k8s.io/v1alpha1/bucketaccessrequest.go index 7340f910..a1b11add 100644 --- a/listers/objectstorage.k8s.io/v1alpha1/bucketaccessrequest.go +++ b/listers/objectstorage.k8s.io/v1alpha1/bucketaccessrequest.go @@ -26,10 +26,8 @@ import ( ) // BucketAccessRequestLister helps list BucketAccessRequests. -// All objects returned here must be treated as read-only. type BucketAccessRequestLister interface { // List lists all BucketAccessRequests in the indexer. - // Objects returned here must be treated as read-only. List(selector labels.Selector) (ret []*v1alpha1.BucketAccessRequest, err error) // BucketAccessRequests returns an object that can list and get BucketAccessRequests. BucketAccessRequests(namespace string) BucketAccessRequestNamespaceLister @@ -60,13 +58,10 @@ func (s *bucketAccessRequestLister) BucketAccessRequests(namespace string) Bucke } // BucketAccessRequestNamespaceLister helps list and get BucketAccessRequests. -// All objects returned here must be treated as read-only. type BucketAccessRequestNamespaceLister interface { // List lists all BucketAccessRequests in the indexer for a given namespace. - // Objects returned here must be treated as read-only. List(selector labels.Selector) (ret []*v1alpha1.BucketAccessRequest, err error) // Get retrieves the BucketAccessRequest from the indexer for a given namespace and name. - // Objects returned here must be treated as read-only. Get(name string) (*v1alpha1.BucketAccessRequest, error) BucketAccessRequestNamespaceListerExpansion } diff --git a/listers/objectstorage.k8s.io/v1alpha1/bucketclass.go b/listers/objectstorage.k8s.io/v1alpha1/bucketclass.go index f7c5c514..31248953 100644 --- a/listers/objectstorage.k8s.io/v1alpha1/bucketclass.go +++ b/listers/objectstorage.k8s.io/v1alpha1/bucketclass.go @@ -26,13 +26,10 @@ import ( ) // BucketClassLister helps list BucketClasses. -// All objects returned here must be treated as read-only. type BucketClassLister interface { // List lists all BucketClasses in the indexer. - // Objects returned here must be treated as read-only. List(selector labels.Selector) (ret []*v1alpha1.BucketClass, err error) // Get retrieves the BucketClass from the index for a given name. - // Objects returned here must be treated as read-only. Get(name string) (*v1alpha1.BucketClass, error) BucketClassListerExpansion } diff --git a/listers/objectstorage.k8s.io/v1alpha1/bucketrequest.go b/listers/objectstorage.k8s.io/v1alpha1/bucketrequest.go index 005d8622..b14298db 100644 --- a/listers/objectstorage.k8s.io/v1alpha1/bucketrequest.go +++ b/listers/objectstorage.k8s.io/v1alpha1/bucketrequest.go @@ -26,10 +26,8 @@ import ( ) // BucketRequestLister helps list BucketRequests. -// All objects returned here must be treated as read-only. type BucketRequestLister interface { // List lists all BucketRequests in the indexer. - // Objects returned here must be treated as read-only. List(selector labels.Selector) (ret []*v1alpha1.BucketRequest, err error) // BucketRequests returns an object that can list and get BucketRequests. BucketRequests(namespace string) BucketRequestNamespaceLister @@ -60,13 +58,10 @@ func (s *bucketRequestLister) BucketRequests(namespace string) BucketRequestName } // BucketRequestNamespaceLister helps list and get BucketRequests. -// All objects returned here must be treated as read-only. type BucketRequestNamespaceLister interface { // List lists all BucketRequests in the indexer for a given namespace. - // Objects returned here must be treated as read-only. List(selector labels.Selector) (ret []*v1alpha1.BucketRequest, err error) // Get retrieves the BucketRequest from the indexer for a given namespace and name. - // Objects returned here must be treated as read-only. Get(name string) (*v1alpha1.BucketRequest, error) BucketRequestNamespaceListerExpansion }