# Generated with protoc-gen-openapi # https://github.com/google/gnostic/tree/master/cmd/protoc-gen-openapi openapi: 3.0.3 info: title: "" version: 0.0.1 paths: /v1/auth/auth: post: tags: - UserCenter description: Auth operationId: UserCenter_Auth requestBody: content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.AuthRequest' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.AuthResponse' /v1/auth/authenticate: post: tags: - UserCenter description: Authenticate operationId: UserCenter_Authenticate requestBody: content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.AuthenticateRequest' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.AuthenticateResponse' /v1/auth/authorize: post: tags: - UserCenter description: Authorize operationId: UserCenter_Authorize requestBody: content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.AuthorizeRequest' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.AuthorizeResponse' /v1/auth/login: post: tags: - UserCenter description: Login operationId: UserCenter_Login requestBody: content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.LoginRequest' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.LoginReply' /v1/auth/logout: post: tags: - UserCenter description: Logout operationId: UserCenter_Logout requestBody: content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.LogoutRequest' required: true responses: "200": description: OK content: {} /v1/auth/refresh-token: post: tags: - UserCenter description: RefreshToken operationId: UserCenter_RefreshToken requestBody: content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.RefreshTokenRequest' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.LoginReply' /v1/idempotents: get: tags: - Gateway description: GetIdempotentToken operationId: Gateway_GetIdempotentToken responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/gateway.v1.IdempotentResponse' /v1/miners: get: tags: - Gateway description: ListMiner operationId: Gateway_ListMiner parameters: - name: limit in: query schema: type: string - name: offset in: query schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/gateway.v1.ListMinerResponse' put: tags: - Gateway description: UpdateMiner operationId: Gateway_UpdateMiner requestBody: content: application/json: schema: $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.Miner' required: true responses: "200": description: OK content: {} post: tags: - Gateway description: CreateMiner operationId: Gateway_CreateMiner requestBody: content: application/json: schema: $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.Miner' required: true responses: "200": description: OK content: {} /v1/miners/{name}: get: tags: - Gateway description: GetMiner operationId: Gateway_GetMiner parameters: - name: name in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.Miner' delete: tags: - Gateway description: DeleteMiner operationId: Gateway_DeleteMiner parameters: - name: name in: path required: true schema: type: string responses: "200": description: OK content: {} /v1/minersets: get: tags: - Gateway description: ListMinerSet operationId: Gateway_ListMinerSet parameters: - name: limit in: query schema: type: string - name: offset in: query schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/gateway.v1.ListMinerSetResponse' put: tags: - Gateway description: UpdateMinerSet operationId: Gateway_UpdateMinerSet requestBody: content: application/json: schema: $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerSet' required: true responses: "200": description: OK content: {} post: tags: - Gateway description: CreateMinerSet operationId: Gateway_CreateMinerSet requestBody: content: application/json: schema: $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerSet' required: true responses: "200": description: OK content: {} /v1/minersets/{name}: get: tags: - Gateway description: GetMinerSet operationId: Gateway_GetMinerSet parameters: - name: name in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerSet' delete: tags: - Gateway description: DeleteMinerSet operationId: Gateway_DeleteMinerSet parameters: - name: name in: path required: true schema: type: string responses: "200": description: OK content: {} /v1/minersets/{name}/scale: put: tags: - Gateway description: ScaleMinerSet operationId: Gateway_ScaleMinerSet parameters: - name: name in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/gateway.v1.ScaleMinerSetRequest' required: true responses: "200": description: OK content: {} /v1/orders: get: tags: - FakeServer operationId: FakeServer_ListOrder parameters: - name: limit in: query schema: type: string - name: offset in: query schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/fakeserver.v1.ListOrderResponse' post: tags: - FakeServer operationId: FakeServer_CreateOrder requestBody: content: application/json: schema: $ref: '#/components/schemas/fakeserver.v1.CreateOrderRequest' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/fakeserver.v1.CreateOrderResponse' /v1/orders/{orderID}: get: tags: - FakeServer operationId: FakeServer_GetOrder parameters: - name: orderID in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/fakeserver.v1.OrderReply' put: tags: - FakeServer operationId: FakeServer_UpdateOrder parameters: - name: orderID in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/fakeserver.v1.UpdateOrderRequest' required: true responses: "200": description: OK content: {} delete: tags: - FakeServer operationId: FakeServer_DeleteOrder parameters: - name: orderID in: path required: true schema: type: string responses: "200": description: OK content: {} /v1/secrets: get: tags: - UserCenter description: ListSecret operationId: UserCenter_ListSecret parameters: - name: limit in: query schema: type: string - name: offset in: query schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.ListSecretResponse' post: tags: - UserCenter description: CreateSecret operationId: UserCenter_CreateSecret requestBody: content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.CreateSecretRequest' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.SecretReply' /v1/secrets/{name}: get: tags: - UserCenter description: GetSecret operationId: UserCenter_GetSecret parameters: - name: name in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.SecretReply' put: tags: - UserCenter description: UpdateSecret operationId: UserCenter_UpdateSecret parameters: - name: name in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.UpdateSecretRequest' required: true responses: "200": description: OK content: {} delete: tags: - UserCenter description: DeleteSecret operationId: UserCenter_DeleteSecret parameters: - name: name in: path required: true schema: type: string responses: "200": description: OK content: {} /v1/users: get: tags: - UserCenter description: ListUser operationId: UserCenter_ListUser parameters: - name: limit in: query schema: type: string - name: offset in: query schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.ListUserResponse' post: tags: - UserCenter description: CreateUser operationId: UserCenter_CreateUser requestBody: content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.CreateUserRequest' required: true responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.UserReply' /v1/users/{username}: get: tags: - UserCenter description: GetUser operationId: UserCenter_GetUser parameters: - name: username in: path required: true schema: type: string responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.UserReply' put: tags: - UserCenter description: UpdateUser operationId: UserCenter_UpdateUser parameters: - name: username in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.UpdateUserRequest' required: true responses: "200": description: OK content: {} delete: tags: - UserCenter description: DeleteUser operationId: UserCenter_DeleteUser parameters: - name: username in: path required: true schema: type: string responses: "200": description: OK content: {} /v1/users/{username}/update-password: put: tags: - UserCenter description: UpdatePassword operationId: UserCenter_UpdatePassword parameters: - name: username in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/usercenter.v1.UpdatePasswordRequest' required: true responses: "200": description: OK content: {} /version: get: tags: - Gateway description: GetVersion operationId: Gateway_GetVersion responses: "200": description: OK content: application/json: schema: $ref: '#/components/schemas/gateway.v1.GetVersionResponse' components: schemas: fakeserver.v1.CreateOrderRequest: type: object properties: customer: type: string product: type: string quantity: type: string fakeserver.v1.CreateOrderResponse: type: object properties: orderID: type: string fakeserver.v1.ListOrderResponse: type: object properties: totalCount: type: string Orders: type: array items: $ref: '#/components/schemas/fakeserver.v1.OrderReply' fakeserver.v1.OrderReply: type: object properties: orderID: type: string customer: type: string product: type: string quantity: type: string createdAt: type: string format: date-time updatedAt: type: string format: date-time fakeserver.v1.UpdateOrderRequest: type: object properties: orderID: type: string customer: type: string product: type: string quantity: type: string gateway.v1.GetVersionResponse: type: object properties: GitVersion: type: string GitCommit: type: string GitTreeState: type: string BuildDate: type: string GoVersion: type: string Compiler: type: string Platform: type: string gateway.v1.IdempotentResponse: type: object properties: token: type: string gateway.v1.ListMinerResponse: type: object properties: totalCount: type: string Miners: type: array items: $ref: '#/components/schemas/gateway.v1.Miner' gateway.v1.ListMinerSetResponse: type: object properties: totalCount: type: string MinerSets: type: array items: $ref: '#/components/schemas/gateway.v1.MinerSet' gateway.v1.Miner: type: object properties: name: type: string displayName: type: string minerType: type: string chainName: type: string dataDir: type: string status: type: string createdAt: type: string format: date-time updatedAt: type: string format: date-time gateway.v1.MinerSet: type: object properties: name: type: string replicas: type: integer format: int32 displayName: type: string deletePolicy: type: string MinerTemplate: $ref: '#/components/schemas/gateway.v1.MinerTemplate' createdAt: type: string format: date-time updatedAt: type: string format: date-time gateway.v1.MinerTemplate: type: object properties: minerType: type: string chainName: type: string dataDir: type: string gateway.v1.ScaleMinerSetRequest: type: object properties: name: type: string replicas: type: integer format: int32 github.com.superproj.onex.pkg.apis.apps.v1beta1.Condition: type: object properties: type: type: string description: |- Type of condition in CamelCase or in foo.example.com/CamelCase. Many .condition.type values are consistent across resources like Available, but because arbitrary conditions can be useful (see .node.status.conditions), the ability to deconflict is important. status: type: string description: Status of the condition, one of True, False, Unknown. severity: type: string description: |- Severity provides an explicit classification of Reason code, so the users or machines can immediately understand the current situation and act accordingly. The Severity field MUST be set only when Status=False. +optional lastTransitionTime: allOf: - $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.Time' description: |- Last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable. reason: type: string description: |- The reason for the condition's last transition in CamelCase. The specific API may choose whether or not this field is considered a guaranteed API. This field may not be empty. +optional message: type: string description: |- A human readable message indicating details about the transition. This field may be empty. +optional description: Condition defines an observation of a cloud miner resource operational state. github.com.superproj.onex.pkg.apis.apps.v1beta1.Miner: type: object properties: metadata: allOf: - $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta' description: |- Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata +optional spec: allOf: - $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerSpec' description: |- Specification of the desired behavior of the miner. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status +optional status: allOf: - $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerStatus' description: |- Most recently observed status of the miner. This data may not be up to date. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status +optional description: Miner is the Schema for the miners API. github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerAddress: type: object properties: type: type: string description: Miner address type, one of Hostname, ExternalIP or InternalIP. address: type: string description: The machine address. description: MinerAddress contains information for the miner's address. github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerSet: type: object properties: metadata: allOf: - $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta' description: |- If the Labels of a MinerSet are empty, they are defaulted to be the same as the Miner(s) that the MinerSet manages. Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata +optional spec: allOf: - $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerSetSpec' description: |- Spec defines the specification of the desired behavior of the MinerSet. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status +optional status: allOf: - $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerSetStatus' description: |- Status is the most recently observed status of the MinerSet. This data may be out of date by some window of time. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status +optional description: MinerSet ensures that a specified number of miners replicas are running at any given time. github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerSetSpec: type: object properties: replicas: type: integer description: |- Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller +optional format: int32 selector: allOf: - $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector' description: |- Selector is a label query over miners that should match the replica count. Label keys and values that must match in order to be controlled by this MinerSet. It must match the miner template's labels. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors template: allOf: - $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerTemplateSpec' description: |- Template is the object that describes the miner that will be created if insufficient replicas are detected. +optional displayName: type: string description: The display name of the minerset. deletePolicy: type: string description: |- DeletePolicy defines the policy used to identify miners to delete when downscaling. Defaults to "Random". Valid values are "Random, "Newest", "Oldest" +kubebuilder:validation:Enum=Random;Newest;Oldest +optional minReadySeconds: type: integer description: |- Minimum number of seconds for which a newly created miner should be ready without any of its component crashing, for it to be considered available. Defaults to 0 (miner will be considered available as soon as it is ready) +optional format: int32 progressDeadlineSeconds: type: integer description: |- The maximum time in seconds for a minerset to make progress before it is considered to be failed. The deployment controller will continue to process failed deployments and a condition with a ProgressDeadlineExceeded reason will be surfaced in the deployment status. Note that progress will not be estimated during the time a deployment is paused. Defaults to 600s. format: int32 description: MinerSetSpec defines the desired state of MinerSet. github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerSetStatus: type: object properties: replicas: type: integer description: Replicas is the most recently observed number of replicas. format: int32 fullyLabeledReplicas: type: integer description: |- The number of miners that have labels matching the labels of the miner template of the minerset. +optional format: int32 readyReplicas: type: integer description: |- readyReplicas is the number of miners targeted by this MinerSet with a Ready Condition. +optional format: int32 availableReplicas: type: integer description: |- The number of available replicas (ready for at least minReadySeconds) for this minerset. +optional format: int32 observedGeneration: type: string description: |- ObservedGeneration reflects the generation of the most recently observed MinerSet. +optional failureReason: type: string description: |- In the event that there is a terminal problem reconciling the replicas, both FailureReason and FailureMessage will be set. FailureReason will be populated with a succinct value suitable for miner interpretation, while FailureMessage will contain a more verbose string suitable for logging and human consumption. These fields should not be set for transitive errors that a controller faces that are expected to be fixed automatically over time (like service outages), but instead indicate that something is fundamentally wrong with the MinerTemplate's spec or the configuration of the miner controller, and that manual intervention is required. Examples of terminal errors would be invalid combinations of settings in the spec, values that are unsupported by the miner controller, or the responsible miner controller itself being critically misconfigured. Any transient errors that occur during the reconciliation of Miners can be added as events to the MinerSet object and/or logged in the controller's output. +optional failureMessage: type: string description: |- FailureMessage will be set in the event that there is a terminal problem reconciling the MinerSet and will contain a more verbose string suitable for logging and human consumption. This field should not be set for transitive errors that a controller faces that are expected to be fixed automatically over time (like service outages), but instead indicate that something is fundamentally wrong with the MinerSet's spec or the configuration of the controller, and that manual intervention is required. Examples of terminal errors would be invalid combinations of settings in the spec, values that are unsupported by the controller, or the responsible controller itself being critically misconfigured. Any transient errors that occur during the reconciliation of MinerSets can be added as events to the MinerSet object and/or logged in the controller's output. +optional conditions: type: array items: $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.Condition' description: |- Represents the latest available observations of a miner set's current state. +optional +patchMergeKey=type +patchStrategy=merge description: MinerSetStatus represents the current status of a MinerSet. github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerSpec: type: object properties: metadata: allOf: - $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.ObjectMeta' description: |- ObjectMeta will autopopulate the Pod created. Use this to indicate what labels, annotations, name prefix, etc., should be used when creating the Pod. +optional displayName: type: string description: |- The display name of the miner. +optional minerType: type: string description: |- Miner machine configuration. +optional chainName: type: string description: +optional restartPolicy: type: string description: |- Restart policy for the miner. One of Always, OnFailure, Never. Default to Always. +optional podDeletionTimeout: allOf: - $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.Duration' description: |- PodDeletionTimeout defines how long the controller will attempt to delete the Pod that the Machine hosts after the Machine is marked for deletion. A duration of 0 will retry deletion indefinitely. Defaults to 10 seconds. +optional description: MinerSpec defines the desired state of Miner. github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerStatus: type: object properties: podRef: allOf: - $ref: '#/components/schemas/k8s.io.api.core.v1.ObjectReference' description: |- PodRef will point to the corresponding Pod if it exists. +optional lastUpdated: allOf: - $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.Time' description: |- LastUpdated identifies when this status was last observed. +optional failureReason: type: string description: |- FailureReason will be set in the event that there is a terminal problem reconciling the Miner and will contain a succinct value suitable for miner interpretation. This field should not be set for transitive errors that a controller faces that are expected to be fixed automatically over time (like service outages), but instead indicate that something is fundamentally wrong with the Miner's spec or the configuration of the controller, and that manual intervention is required. Examples of terminal errors would be invalid combinations of settings in the spec, values that are unsupported by the controller, or the responsible controller itself being critically misconfigured. Any transient errors that occur during the reconciliation of Miners can be added as events to the Miner object and/or logged in the controller's output. +optional failureMessage: type: string description: |- FailureMessage will be set in the event that there is a terminal problem reconciling the Miner and will contain a more verbose string suitable for logging and human consumption. This field should not be set for transitive errors that a controller faces that are expected to be fixed automatically over time (like service outages), but instead indicate that something is fundamentally wrong with the Miner's spec or the configuration of the controller, and that manual intervention is required. Examples of terminal errors would be invalid combinations of settings in the spec, values that are unsupported by the controller, or the responsible controller itself being critically misconfigured. Any transient errors that occur during the reconciliation of Miners can be added as events to the Miner object and/or logged in the controller's output. +optional addresses: type: array items: $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerAddress' description: |- Addresses is a list of addresses assigned to the miner. Queried from kind cluster, if available. +optional +patchMergeKey=type +patchStrategy=merge phase: type: string description: |- Phase represents the current phase of miner actuation. One of: Failed, Provisioning, Provisioned, Running, Deleting This field is maintained by miner controller. +optional observedGeneration: type: string description: |- ObservedGeneration is the latest generation observed by the controller. +optional conditions: type: array items: $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.Condition' description: |- Conditions defines the current state of the Miner +optional description: MinerStatus defines the observed state of Miner. github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerTemplateSpec: type: object properties: metadata: allOf: - $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.ObjectMeta' description: |- Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata +optional spec: allOf: - $ref: '#/components/schemas/github.com.superproj.onex.pkg.apis.apps.v1beta1.MinerSpec' description: |- Specification of the desired behavior of the miner. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status +optional description: MinerTemplateSpec describes the data needed to create a Miner from a template. github.com.superproj.onex.pkg.apis.apps.v1beta1.ObjectMeta: type: object properties: labels: type: object additionalProperties: type: string description: |- Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels +optional annotations: type: object additionalProperties: type: string description: |- Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations +optional description: |- ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create. This is a copy of customizable fields from metav1.ObjectMeta. ObjectMeta is embedded in `Miner.Spec` and `MinerSet.Template`, which are not top-level Kubernetes objects. Given that metav1.ObjectMeta has lots of special cases and read-only fields which end up in the generated CRD validation, having it as a subset simplifies the API and some issues that can impact user experience. During the [upgrade to controller-tools@v2](https://github.com/kubernetes-sigs/cluster-api/pull/1054) for v1alpha2, we noticed a failure would occur running Cluster API test suite against the new CRDs, specifically `spec.metadata.creationTimestamp in body must be of type string: "null"`. The investigation showed that `controller-tools@v2` behaves differently than its previous version when handling types from [metav1](k8s.io/apimachinery/pkg/apis/meta/v1) package. In more details, we found that embedded (non-top level) types that embedded `metav1.ObjectMeta` had validation properties, including for `creationTimestamp` (metav1.Time). The `metav1.Time` type specifies a custom json marshaller that, when IsZero() is true, returns `null` which breaks validation because the field isn't marked as nullable. In future versions, controller-tools@v2 might allow overriding the type and validation for embedded types. When that happens, this hack should be revisited. k8s.io.api.core.v1.ObjectReference: type: object properties: kind: type: string description: |- Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds +optional namespace: type: string description: |- Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ +optional name: type: string description: |- Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names +optional uid: type: string description: |- UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids +optional apiVersion: type: string description: |- API version of the referent. +optional resourceVersion: type: string 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 +optional fieldPath: type: string 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. +optional 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 . +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +structType=atomic k8s.io.apimachinery.pkg.apis.meta.v1.Duration: type: object properties: duration: type: string description: |- Duration is a wrapper around time.Duration which supports correct marshaling to YAML and JSON. In particular, it marshals into strings, which can be used as map keys in json. k8s.io.apimachinery.pkg.apis.meta.v1.FieldsV1: type: object properties: Raw: type: string description: Raw is the underlying serialization of this object. format: bytes description: |- FieldsV1 stores a set of fields in a data structure like a Trie, in JSON format. Each key is either a '.' representing the field itself, and will always map to an empty set, or a string representing a sub-field or item. The string will follow one of these four formats: 'f:', where is the name of a field in a struct, or key in a map 'v:', where is the exact json formatted value of a list item 'i:', where is position of a item in a list 'k:', where is a map of a list item's key fields to their unique values If a key maps to an empty Fields value, the field that key represents is part of the set. The exact format is defined in sigs.k8s.io/structured-merge-diff +protobuf.options.(gogoproto.goproto_stringer)=false k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector: type: object properties: matchLabels: type: object additionalProperties: type: string description: |- matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed. +optional matchExpressions: type: array items: $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelectorRequirement' description: |- matchExpressions is a list of label selector requirements. The requirements are ANDed. +optional +listType=atomic description: |- A label selector is a label query over a set of resources. The result of matchLabels and matchExpressions are ANDed. An empty label selector matches all objects. A null label selector matches no objects. +structType=atomic k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelectorRequirement: type: object properties: key: type: string description: key is the label key that the selector applies to. operator: type: string description: |- operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist. values: type: array items: type: string description: |- values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch. +optional +listType=atomic description: |- A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values. k8s.io.apimachinery.pkg.apis.meta.v1.ManagedFieldsEntry: type: object properties: manager: type: string description: Manager is an identifier of the workflow managing these fields. operation: type: string description: |- Operation is the type of operation which lead to this ManagedFieldsEntry being created. The only valid values for this field are 'Apply' and 'Update'. apiVersion: type: string description: |- APIVersion defines the version of this resource that this field set applies to. The format is "group/version" just like the top-level APIVersion field. It is necessary to track the version of a field set because it cannot be automatically converted. time: allOf: - $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.Time' description: |- Time is the timestamp of when the ManagedFields entry was added. The timestamp will also be updated if a field is added, the manager changes any of the owned fields value or removes a field. The timestamp does not update when a field is removed from the entry because another manager took it over. +optional fieldsType: type: string description: |- FieldsType is the discriminator for the different fields format and version. There is currently only one possible value: "FieldsV1" fieldsV1: allOf: - $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.FieldsV1' description: |- FieldsV1 holds the first JSON version format as described in the "FieldsV1" type. +optional subresource: type: string description: |- Subresource is the name of the subresource used to update that object, or empty string if the object was updated through the main resource. The value of this field is used to distinguish between managers, even if they share the same name. For example, a status update will be distinct from a regular update using the same manager name. Note that the APIVersion field is not related to the Subresource field and it always corresponds to the version of the main resource. description: |- ManagedFieldsEntry is a workflow-id, a FieldSet and the group version of the resource that the fieldset applies to. k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta: type: object properties: name: type: string description: |- Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#names +optional generateName: type: string description: |- GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server. If this field is specified and the generated name exists, the server will return a 409. Applied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#idempotency +optional namespace: type: string description: |- Namespace defines the space within which each name must be unique. An empty namespace is equivalent to the "default" namespace, but "default" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty. Must be a DNS_LABEL. Cannot be updated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces +optional selfLink: type: string description: |- Deprecated: selfLink is a legacy read-only field that is no longer populated by the system. +optional uid: type: string description: |- UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations. Populated by the system. Read-only. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#uids +optional resourceVersion: type: string description: |- An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources. Populated by the system. Read-only. Value must be treated as opaque by clients and . More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency +optional generation: type: string description: |- A sequence number representing a specific generation of the desired state. Populated by the system. Read-only. +optional creationTimestamp: allOf: - $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.Time' description: |- CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC. Populated by the system. Read-only. Null for lists. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata +optional deletionTimestamp: allOf: - $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.Time' description: |- DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field, once the finalizers list is empty. As long as the finalizers list contains items, deletion is blocked. Once the deletionTimestamp is set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested. Populated by the system when a graceful deletion is requested. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata +optional deletionGracePeriodSeconds: type: string description: |- Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only. +optional labels: type: object additionalProperties: type: string description: |- Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels +optional annotations: type: object additionalProperties: type: string description: |- Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations +optional ownerReferences: type: array items: $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.OwnerReference' description: |- List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller. +optional +patchMergeKey=uid +patchStrategy=merge +listType=map +listMapKey=uid finalizers: type: array items: type: string description: |- Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. Finalizers may be processed and removed in any order. Order is NOT enforced because it introduces significant risk of stuck finalizers. finalizers is a shared field, any actor with permission can reorder it. If the finalizer list is processed in order, then this can lead to a situation in which the component responsible for the first finalizer in the list is waiting for a signal (field value, external system, or other) produced by a component responsible for a finalizer later in the list, resulting in a deadlock. Without enforced ordering finalizers are free to order amongst themselves and are not vulnerable to ordering changes in the list. +optional +patchStrategy=merge +listType=set managedFields: type: array items: $ref: '#/components/schemas/k8s.io.apimachinery.pkg.apis.meta.v1.ManagedFieldsEntry' description: |- ManagedFields maps workflow-id and version to the set of fields that are managed by that workflow. This is mostly for internal housekeeping, and users typically shouldn't need to set or understand this field. A workflow can be the user's name, a controller's name, or the name of a specific apply path like "ci-cd". The set of fields is always in the version that the workflow used when modifying the object. +optional +listType=atomic description: |- ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create. k8s.io.apimachinery.pkg.apis.meta.v1.OwnerReference: type: object properties: apiVersion: type: string description: API version of the referent. kind: type: string description: |- Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds name: type: string description: |- Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#names uid: type: string description: |- UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#uids controller: type: boolean description: |- If true, this reference points to the managing controller. +optional blockOwnerDeletion: type: boolean description: |- If true, AND if the owner has the "foregroundDeletion" finalizer, then the owner cannot be deleted from the key-value store until this reference is removed. See https://kubernetes.io/docs/concepts/architecture/garbage-collection/#foreground-deletion for how the garbage collector interacts with this field and enforces the foreground deletion. Defaults to false. To set this field, a user needs "delete" permission of the owner, otherwise 422 (Unprocessable Entity) will be returned. +optional description: |- OwnerReference contains enough information to let you identify an owning object. An owning object must be in the same namespace as the dependent, or be cluster-scoped, so there is no namespace field. +structType=atomic k8s.io.apimachinery.pkg.apis.meta.v1.Time: type: object properties: seconds: type: string description: |- Represents seconds of UTC time since Unix epoch 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z inclusive. nanos: type: integer description: |- Non-negative fractions of a second at nanosecond resolution. Negative second values with fractions must still have non-negative nanos values that count forward in time. Must be from 0 to 999,999,999 inclusive. This field may be limited in precision depending on context. format: int32 description: |- Time is a wrapper around time.Time which supports correct marshaling to YAML and JSON. Wrappers are provided for many of the factory methods that the time package offers. +protobuf.options.marshal=false +protobuf.as=Timestamp +protobuf.options.(gogoproto.goproto_stringer)=false usercenter.v1.AuthRequest: type: object properties: token: type: string obj: type: string act: type: string usercenter.v1.AuthResponse: type: object properties: userID: type: string allowed: type: boolean usercenter.v1.AuthenticateRequest: type: object properties: token: type: string usercenter.v1.AuthenticateResponse: type: object properties: userID: type: string usercenter.v1.AuthorizeRequest: type: object properties: sub: type: string obj: type: string act: type: string usercenter.v1.AuthorizeResponse: type: object properties: allowed: type: boolean usercenter.v1.CreateSecretRequest: type: object properties: name: type: string expires: type: string description: type: string usercenter.v1.CreateUserRequest: type: object properties: username: type: string nickname: type: string password: type: string email: type: string phone: type: string usercenter.v1.ListSecretResponse: type: object properties: totalCount: type: string Secrets: type: array items: $ref: '#/components/schemas/usercenter.v1.SecretReply' usercenter.v1.ListUserResponse: type: object properties: totalCount: type: string Users: type: array items: $ref: '#/components/schemas/usercenter.v1.UserReply' usercenter.v1.LoginReply: type: object properties: refreshToken: type: string accessToken: type: string type: type: string expiresAt: type: string usercenter.v1.LoginRequest: type: object properties: username: type: string password: type: string usercenter.v1.LogoutRequest: type: object properties: {} usercenter.v1.RefreshTokenRequest: type: object properties: {} usercenter.v1.SecretReply: type: object properties: userID: type: string name: type: string secretID: type: string secretKey: type: string expires: type: string status: type: integer format: int32 description: type: string createdAt: type: string format: date-time updatedAt: type: string format: date-time usercenter.v1.UpdatePasswordRequest: type: object properties: username: type: string oldPassword: type: string newPassword: type: string usercenter.v1.UpdateSecretRequest: type: object properties: name: type: string expires: type: string status: type: integer format: int32 description: type: string usercenter.v1.UpdateUserRequest: type: object properties: username: type: string nickname: type: string email: type: string phone: type: string usercenter.v1.UserReply: type: object properties: userID: type: string username: type: string nickname: type: string password: type: string email: type: string phone: type: string secrets: type: string createdAt: type: string format: date-time updatedAt: type: string format: date-time tags: - name: FakeServer - name: Gateway description: Peer lists hubble peers and notifies of changes. - name: UserCenter description: Peer lists hubble peers and notifies of changes.