Package flyteidl.core

Class Security.OAuth2TokenRequest

  • All Implemented Interfaces:
    com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Security.OAuth2TokenRequestOrBuilder, Serializable
    Enclosing class:
    Security

    public static final class Security.OAuth2TokenRequest
    extends com.google.protobuf.GeneratedMessageV3
    implements Security.OAuth2TokenRequestOrBuilder
     OAuth2TokenRequest encapsulates information needed to request an OAuth2 token.
     FLYTE_TOKENS_ENV_PREFIX will be passed to indicate the prefix of the environment variables that will be present if
     tokens are passed through environment variables.
     FLYTE_TOKENS_PATH_PREFIX will be passed to indicate the prefix of the path where secrets will be mounted if tokens
     are passed through file mounts.
     
    Protobuf type flyteidl.core.OAuth2TokenRequest
    See Also:
    Serialized Form
    • Constructor Detail

      • OAuth2TokenRequest

        private OAuth2TokenRequest​(com.google.protobuf.GeneratedMessageV3.Builder<?> builder)
      • OAuth2TokenRequest

        private OAuth2TokenRequest()
    • Method Detail

      • newInstance

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

        public final com.google.protobuf.UnknownFieldSet getUnknownFields()
        Specified by:
        getUnknownFields in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getUnknownFields 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
      • getName

        public String getName()
         name indicates a unique id for the token request within this task token requests. It'll be used as a suffix for
         environment variables and as a filename for mounting tokens as files.
         +required
         
        string name = 1;
        Specified by:
        getName in interface Security.OAuth2TokenRequestOrBuilder
        Returns:
        The name.
      • getNameBytes

        public com.google.protobuf.ByteString getNameBytes()
         name indicates a unique id for the token request within this task token requests. It'll be used as a suffix for
         environment variables and as a filename for mounting tokens as files.
         +required
         
        string name = 1;
        Specified by:
        getNameBytes in interface Security.OAuth2TokenRequestOrBuilder
        Returns:
        The bytes for name.
      • getTypeValue

        public int getTypeValue()
         type indicates the type of the request to make. Defaults to CLIENT_CREDENTIALS.
         +required
         
        .flyteidl.core.OAuth2TokenRequest.Type type = 2;
        Specified by:
        getTypeValue in interface Security.OAuth2TokenRequestOrBuilder
        Returns:
        The enum numeric value on the wire for type.
      • hasClient

        public boolean hasClient()
         client references the client_id/secret to use to request the OAuth2 token.
         +required
         
        .flyteidl.core.OAuth2Client client = 3;
        Specified by:
        hasClient in interface Security.OAuth2TokenRequestOrBuilder
        Returns:
        Whether the client field is set.
      • getIdpDiscoveryEndpoint

        public String getIdpDiscoveryEndpoint()
         idp_discovery_endpoint references the discovery endpoint used to retrieve token endpoint and other related
         information.
         +optional
         
        string idp_discovery_endpoint = 4;
        Specified by:
        getIdpDiscoveryEndpoint in interface Security.OAuth2TokenRequestOrBuilder
        Returns:
        The idpDiscoveryEndpoint.
      • getIdpDiscoveryEndpointBytes

        public com.google.protobuf.ByteString getIdpDiscoveryEndpointBytes()
         idp_discovery_endpoint references the discovery endpoint used to retrieve token endpoint and other related
         information.
         +optional
         
        string idp_discovery_endpoint = 4;
        Specified by:
        getIdpDiscoveryEndpointBytes in interface Security.OAuth2TokenRequestOrBuilder
        Returns:
        The bytes for idpDiscoveryEndpoint.
      • getTokenEndpoint

        public String getTokenEndpoint()
         token_endpoint references the token issuance endpoint. If idp_discovery_endpoint is not provided, this parameter is
         mandatory.
         +optional
         
        string token_endpoint = 5;
        Specified by:
        getTokenEndpoint in interface Security.OAuth2TokenRequestOrBuilder
        Returns:
        The tokenEndpoint.
      • getTokenEndpointBytes

        public com.google.protobuf.ByteString getTokenEndpointBytes()
         token_endpoint references the token issuance endpoint. If idp_discovery_endpoint is not provided, this parameter is
         mandatory.
         +optional
         
        string token_endpoint = 5;
        Specified by:
        getTokenEndpointBytes in interface Security.OAuth2TokenRequestOrBuilder
        Returns:
        The bytes for tokenEndpoint.
      • 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 Security.OAuth2TokenRequest parseFrom​(ByteBuffer data)
                                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

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

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

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

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

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

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

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

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

        public com.google.protobuf.Parser<Security.OAuth2TokenRequest> 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 Security.OAuth2TokenRequest getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder