Class KubernetesResource

  • All Implemented Interfaces:
    KubernetesResourceOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable

    public final class KubernetesResource
    extends com.google.protobuf.GeneratedMessageV3
    implements KubernetesResourceOrBuilder
     KubernetesResource contains the YAML manifests and configuration for
     Membership Kubernetes resources in the cluster. After CreateMembership or
     UpdateMembership, these resources should be re-applied in the cluster.
     
    Protobuf type google.cloud.gkehub.v1.KubernetesResource
    See Also:
    Serialized Form
    • Field Detail

      • MEMBERSHIP_CR_MANIFEST_FIELD_NUMBER

        public static final int MEMBERSHIP_CR_MANIFEST_FIELD_NUMBER
        See Also:
        Constant Field Values
      • MEMBERSHIP_RESOURCES_FIELD_NUMBER

        public static final int MEMBERSHIP_RESOURCES_FIELD_NUMBER
        See Also:
        Constant Field Values
      • CONNECT_RESOURCES_FIELD_NUMBER

        public static final int CONNECT_RESOURCES_FIELD_NUMBER
        See Also:
        Constant Field Values
      • RESOURCE_OPTIONS_FIELD_NUMBER

        public static final int RESOURCE_OPTIONS_FIELD_NUMBER
        See Also:
        Constant Field Values
    • Method Detail

      • newInstance

        protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
      • getMembershipCrManifest

        public String getMembershipCrManifest()
         Input only. The YAML representation of the Membership CR. This field is
         ignored for GKE clusters where Hub can read the CR directly.
        
         Callers should provide the CR that is currently present in the cluster
         during CreateMembership or UpdateMembership, or leave this field empty if
         none exists. The CR manifest is used to validate the cluster has not been
         registered with another Membership.
         
        string membership_cr_manifest = 1 [(.google.api.field_behavior) = INPUT_ONLY];
        Specified by:
        getMembershipCrManifest in interface KubernetesResourceOrBuilder
        Returns:
        The membershipCrManifest.
      • getMembershipCrManifestBytes

        public com.google.protobuf.ByteString getMembershipCrManifestBytes()
         Input only. The YAML representation of the Membership CR. This field is
         ignored for GKE clusters where Hub can read the CR directly.
        
         Callers should provide the CR that is currently present in the cluster
         during CreateMembership or UpdateMembership, or leave this field empty if
         none exists. The CR manifest is used to validate the cluster has not been
         registered with another Membership.
         
        string membership_cr_manifest = 1 [(.google.api.field_behavior) = INPUT_ONLY];
        Specified by:
        getMembershipCrManifestBytes in interface KubernetesResourceOrBuilder
        Returns:
        The bytes for membershipCrManifest.
      • getMembershipResourcesList

        public List<ResourceManifest> getMembershipResourcesList()
         Output only. Additional Kubernetes resources that need to be applied to the
         cluster after Membership creation, and after every update.
        
         This field is only populated in the Membership returned from a successful
         long-running operation from CreateMembership or UpdateMembership. It is not
         populated during normal GetMembership or ListMemberships requests. To get
         the resource manifest after the initial registration, the caller should
         make a UpdateMembership call with an empty field mask.
         
        repeated .google.cloud.gkehub.v1.ResourceManifest membership_resources = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getMembershipResourcesList in interface KubernetesResourceOrBuilder
      • getMembershipResourcesOrBuilderList

        public List<? extends ResourceManifestOrBuilder> getMembershipResourcesOrBuilderList()
         Output only. Additional Kubernetes resources that need to be applied to the
         cluster after Membership creation, and after every update.
        
         This field is only populated in the Membership returned from a successful
         long-running operation from CreateMembership or UpdateMembership. It is not
         populated during normal GetMembership or ListMemberships requests. To get
         the resource manifest after the initial registration, the caller should
         make a UpdateMembership call with an empty field mask.
         
        repeated .google.cloud.gkehub.v1.ResourceManifest membership_resources = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getMembershipResourcesOrBuilderList in interface KubernetesResourceOrBuilder
      • getMembershipResourcesCount

        public int getMembershipResourcesCount()
         Output only. Additional Kubernetes resources that need to be applied to the
         cluster after Membership creation, and after every update.
        
         This field is only populated in the Membership returned from a successful
         long-running operation from CreateMembership or UpdateMembership. It is not
         populated during normal GetMembership or ListMemberships requests. To get
         the resource manifest after the initial registration, the caller should
         make a UpdateMembership call with an empty field mask.
         
        repeated .google.cloud.gkehub.v1.ResourceManifest membership_resources = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getMembershipResourcesCount in interface KubernetesResourceOrBuilder
      • getMembershipResources

        public ResourceManifest getMembershipResources​(int index)
         Output only. Additional Kubernetes resources that need to be applied to the
         cluster after Membership creation, and after every update.
        
         This field is only populated in the Membership returned from a successful
         long-running operation from CreateMembership or UpdateMembership. It is not
         populated during normal GetMembership or ListMemberships requests. To get
         the resource manifest after the initial registration, the caller should
         make a UpdateMembership call with an empty field mask.
         
        repeated .google.cloud.gkehub.v1.ResourceManifest membership_resources = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getMembershipResources in interface KubernetesResourceOrBuilder
      • getMembershipResourcesOrBuilder

        public ResourceManifestOrBuilder getMembershipResourcesOrBuilder​(int index)
         Output only. Additional Kubernetes resources that need to be applied to the
         cluster after Membership creation, and after every update.
        
         This field is only populated in the Membership returned from a successful
         long-running operation from CreateMembership or UpdateMembership. It is not
         populated during normal GetMembership or ListMemberships requests. To get
         the resource manifest after the initial registration, the caller should
         make a UpdateMembership call with an empty field mask.
         
        repeated .google.cloud.gkehub.v1.ResourceManifest membership_resources = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getMembershipResourcesOrBuilder in interface KubernetesResourceOrBuilder
      • getConnectResourcesList

        public List<ResourceManifest> getConnectResourcesList()
         Output only. The Kubernetes resources for installing the GKE Connect agent
        
         This field is only populated in the Membership returned from a successful
         long-running operation from CreateMembership or UpdateMembership. It is not
         populated during normal GetMembership or ListMemberships requests. To get
         the resource manifest after the initial registration, the caller should
         make a UpdateMembership call with an empty field mask.
         
        repeated .google.cloud.gkehub.v1.ResourceManifest connect_resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getConnectResourcesList in interface KubernetesResourceOrBuilder
      • getConnectResourcesOrBuilderList

        public List<? extends ResourceManifestOrBuilder> getConnectResourcesOrBuilderList()
         Output only. The Kubernetes resources for installing the GKE Connect agent
        
         This field is only populated in the Membership returned from a successful
         long-running operation from CreateMembership or UpdateMembership. It is not
         populated during normal GetMembership or ListMemberships requests. To get
         the resource manifest after the initial registration, the caller should
         make a UpdateMembership call with an empty field mask.
         
        repeated .google.cloud.gkehub.v1.ResourceManifest connect_resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getConnectResourcesOrBuilderList in interface KubernetesResourceOrBuilder
      • getConnectResourcesCount

        public int getConnectResourcesCount()
         Output only. The Kubernetes resources for installing the GKE Connect agent
        
         This field is only populated in the Membership returned from a successful
         long-running operation from CreateMembership or UpdateMembership. It is not
         populated during normal GetMembership or ListMemberships requests. To get
         the resource manifest after the initial registration, the caller should
         make a UpdateMembership call with an empty field mask.
         
        repeated .google.cloud.gkehub.v1.ResourceManifest connect_resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getConnectResourcesCount in interface KubernetesResourceOrBuilder
      • getConnectResources

        public ResourceManifest getConnectResources​(int index)
         Output only. The Kubernetes resources for installing the GKE Connect agent
        
         This field is only populated in the Membership returned from a successful
         long-running operation from CreateMembership or UpdateMembership. It is not
         populated during normal GetMembership or ListMemberships requests. To get
         the resource manifest after the initial registration, the caller should
         make a UpdateMembership call with an empty field mask.
         
        repeated .google.cloud.gkehub.v1.ResourceManifest connect_resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getConnectResources in interface KubernetesResourceOrBuilder
      • getConnectResourcesOrBuilder

        public ResourceManifestOrBuilder getConnectResourcesOrBuilder​(int index)
         Output only. The Kubernetes resources for installing the GKE Connect agent
        
         This field is only populated in the Membership returned from a successful
         long-running operation from CreateMembership or UpdateMembership. It is not
         populated during normal GetMembership or ListMemberships requests. To get
         the resource manifest after the initial registration, the caller should
         make a UpdateMembership call with an empty field mask.
         
        repeated .google.cloud.gkehub.v1.ResourceManifest connect_resources = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getConnectResourcesOrBuilder in interface KubernetesResourceOrBuilder
      • hasResourceOptions

        public boolean hasResourceOptions()
         Optional. Options for Kubernetes resource generation.
         
        .google.cloud.gkehub.v1.ResourceOptions resource_options = 4 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        hasResourceOptions in interface KubernetesResourceOrBuilder
        Returns:
        Whether the resourceOptions field is set.
      • getResourceOptions

        public ResourceOptions getResourceOptions()
         Optional. Options for Kubernetes resource generation.
         
        .google.cloud.gkehub.v1.ResourceOptions resource_options = 4 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getResourceOptions in interface KubernetesResourceOrBuilder
        Returns:
        The resourceOptions.
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static KubernetesResource parseFrom​(ByteBuffer data)
                                            throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static KubernetesResource parseFrom​(ByteBuffer data,
                                                   com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                            throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static KubernetesResource parseFrom​(com.google.protobuf.ByteString data)
                                            throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static KubernetesResource parseFrom​(com.google.protobuf.ByteString data,
                                                   com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                            throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static KubernetesResource parseFrom​(byte[] data)
                                            throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static KubernetesResource parseFrom​(byte[] data,
                                                   com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                            throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static KubernetesResource parseFrom​(com.google.protobuf.CodedInputStream input,
                                                   com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                            throws IOException
        Throws:
        IOException
      • newBuilderForType

        public KubernetesResource.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public KubernetesResource.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected KubernetesResource.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • getParserForType

        public com.google.protobuf.Parser<KubernetesResource> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

        public KubernetesResource getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder