com.pulumi.kubernetes.apiextensions.v1beta1.outputs.CustomResourceSubresourceScalePatch Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of kubernetes Show documentation
Show all versions of kubernetes Show documentation
A Pulumi package for creating and managing Kubernetes resources.
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package com.pulumi.kubernetes.apiextensions.v1beta1.outputs;
import com.pulumi.core.annotations.CustomType;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
@CustomType
public final class CustomResourceSubresourceScalePatch {
/**
* @return labelSelectorPath defines the JSON path inside of a custom resource that corresponds to Scale `status.selector`. Only JSON paths without the array notation are allowed. Must be a JSON Path under `.status` or `.spec`. Must be set to work with HorizontalPodAutoscaler. The field pointed by this JSON path must be a string field (not a complex selector struct) which contains a serialized label selector in string form. More info: https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions#scale-subresource If there is no value under the given path in the custom resource, the `status.selector` value in the `/scale` subresource will default to the empty string.
*
*/
private @Nullable String labelSelectorPath;
/**
* @return specReplicasPath defines the JSON path inside of a custom resource that corresponds to Scale `spec.replicas`. Only JSON paths without the array notation are allowed. Must be a JSON Path under `.spec`. If there is no value under the given path in the custom resource, the `/scale` subresource will return an error on GET.
*
*/
private @Nullable String specReplicasPath;
/**
* @return statusReplicasPath defines the JSON path inside of a custom resource that corresponds to Scale `status.replicas`. Only JSON paths without the array notation are allowed. Must be a JSON Path under `.status`. If there is no value under the given path in the custom resource, the `status.replicas` value in the `/scale` subresource will default to 0.
*
*/
private @Nullable String statusReplicasPath;
private CustomResourceSubresourceScalePatch() {}
/**
* @return labelSelectorPath defines the JSON path inside of a custom resource that corresponds to Scale `status.selector`. Only JSON paths without the array notation are allowed. Must be a JSON Path under `.status` or `.spec`. Must be set to work with HorizontalPodAutoscaler. The field pointed by this JSON path must be a string field (not a complex selector struct) which contains a serialized label selector in string form. More info: https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions#scale-subresource If there is no value under the given path in the custom resource, the `status.selector` value in the `/scale` subresource will default to the empty string.
*
*/
public Optional labelSelectorPath() {
return Optional.ofNullable(this.labelSelectorPath);
}
/**
* @return specReplicasPath defines the JSON path inside of a custom resource that corresponds to Scale `spec.replicas`. Only JSON paths without the array notation are allowed. Must be a JSON Path under `.spec`. If there is no value under the given path in the custom resource, the `/scale` subresource will return an error on GET.
*
*/
public Optional specReplicasPath() {
return Optional.ofNullable(this.specReplicasPath);
}
/**
* @return statusReplicasPath defines the JSON path inside of a custom resource that corresponds to Scale `status.replicas`. Only JSON paths without the array notation are allowed. Must be a JSON Path under `.status`. If there is no value under the given path in the custom resource, the `status.replicas` value in the `/scale` subresource will default to 0.
*
*/
public Optional statusReplicasPath() {
return Optional.ofNullable(this.statusReplicasPath);
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(CustomResourceSubresourceScalePatch defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private @Nullable String labelSelectorPath;
private @Nullable String specReplicasPath;
private @Nullable String statusReplicasPath;
public Builder() {}
public Builder(CustomResourceSubresourceScalePatch defaults) {
Objects.requireNonNull(defaults);
this.labelSelectorPath = defaults.labelSelectorPath;
this.specReplicasPath = defaults.specReplicasPath;
this.statusReplicasPath = defaults.statusReplicasPath;
}
@CustomType.Setter
public Builder labelSelectorPath(@Nullable String labelSelectorPath) {
this.labelSelectorPath = labelSelectorPath;
return this;
}
@CustomType.Setter
public Builder specReplicasPath(@Nullable String specReplicasPath) {
this.specReplicasPath = specReplicasPath;
return this;
}
@CustomType.Setter
public Builder statusReplicasPath(@Nullable String statusReplicasPath) {
this.statusReplicasPath = statusReplicasPath;
return this;
}
public CustomResourceSubresourceScalePatch build() {
final var _resultValue = new CustomResourceSubresourceScalePatch();
_resultValue.labelSelectorPath = labelSelectorPath;
_resultValue.specReplicasPath = specReplicasPath;
_resultValue.statusReplicasPath = statusReplicasPath;
return _resultValue;
}
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy