Class TrinoJob.Builder

  • All Implemented Interfaces:
    TrinoJobOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
    Enclosing class:
    TrinoJob

    public static final class TrinoJob.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
    implements TrinoJobOrBuilder
     A Dataproc job for running [Trino](https://trino.io/) queries.
     **IMPORTANT**: The [Dataproc Trino Optional
     Component](https://cloud.google.com/dataproc/docs/concepts/components/trino)
     must be enabled when the cluster is created to submit a Trino job to the
     cluster.
     
    Protobuf type google.cloud.dataproc.v1.TrinoJob
    • Method Detail

      • getDescriptor

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

        protected com.google.protobuf.MapField internalGetMapField​(int number)
        Overrides:
        internalGetMapField in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • internalGetMutableMapField

        protected com.google.protobuf.MapField internalGetMutableMapField​(int number)
        Overrides:
        internalGetMutableMapField in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • clear

        public TrinoJob.Builder clear()
        Specified by:
        clear in interface com.google.protobuf.Message.Builder
        Specified by:
        clear in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clear in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • getDefaultInstanceForType

        public TrinoJob getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public TrinoJob build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public TrinoJob buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • clone

        public TrinoJob.Builder clone()
        Specified by:
        clone in interface com.google.protobuf.Message.Builder
        Specified by:
        clone in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clone in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • setField

        public TrinoJob.Builder setField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                         Object value)
        Specified by:
        setField in interface com.google.protobuf.Message.Builder
        Overrides:
        setField in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • clearField

        public TrinoJob.Builder clearField​(com.google.protobuf.Descriptors.FieldDescriptor field)
        Specified by:
        clearField in interface com.google.protobuf.Message.Builder
        Overrides:
        clearField in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • clearOneof

        public TrinoJob.Builder clearOneof​(com.google.protobuf.Descriptors.OneofDescriptor oneof)
        Specified by:
        clearOneof in interface com.google.protobuf.Message.Builder
        Overrides:
        clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • setRepeatedField

        public TrinoJob.Builder setRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                 int index,
                                                 Object value)
        Specified by:
        setRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • addRepeatedField

        public TrinoJob.Builder addRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                 Object value)
        Specified by:
        addRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • mergeFrom

        public TrinoJob.Builder mergeFrom​(com.google.protobuf.Message other)
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<TrinoJob.Builder>
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • mergeFrom

        public TrinoJob.Builder mergeFrom​(com.google.protobuf.CodedInputStream input,
                                          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                   throws IOException
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Specified by:
        mergeFrom in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<TrinoJob.Builder>
        Throws:
        IOException
      • hasQueryFileUri

        public boolean hasQueryFileUri()
         The HCFS URI of the script that contains SQL queries.
         
        string query_file_uri = 1;
        Specified by:
        hasQueryFileUri in interface TrinoJobOrBuilder
        Returns:
        Whether the queryFileUri field is set.
      • getQueryFileUri

        public String getQueryFileUri()
         The HCFS URI of the script that contains SQL queries.
         
        string query_file_uri = 1;
        Specified by:
        getQueryFileUri in interface TrinoJobOrBuilder
        Returns:
        The queryFileUri.
      • getQueryFileUriBytes

        public com.google.protobuf.ByteString getQueryFileUriBytes()
         The HCFS URI of the script that contains SQL queries.
         
        string query_file_uri = 1;
        Specified by:
        getQueryFileUriBytes in interface TrinoJobOrBuilder
        Returns:
        The bytes for queryFileUri.
      • setQueryFileUri

        public TrinoJob.Builder setQueryFileUri​(String value)
         The HCFS URI of the script that contains SQL queries.
         
        string query_file_uri = 1;
        Parameters:
        value - The queryFileUri to set.
        Returns:
        This builder for chaining.
      • clearQueryFileUri

        public TrinoJob.Builder clearQueryFileUri()
         The HCFS URI of the script that contains SQL queries.
         
        string query_file_uri = 1;
        Returns:
        This builder for chaining.
      • setQueryFileUriBytes

        public TrinoJob.Builder setQueryFileUriBytes​(com.google.protobuf.ByteString value)
         The HCFS URI of the script that contains SQL queries.
         
        string query_file_uri = 1;
        Parameters:
        value - The bytes for queryFileUri to set.
        Returns:
        This builder for chaining.
      • hasQueryList

        public boolean hasQueryList()
         A list of queries.
         
        .google.cloud.dataproc.v1.QueryList query_list = 2;
        Specified by:
        hasQueryList in interface TrinoJobOrBuilder
        Returns:
        Whether the queryList field is set.
      • getQueryList

        public QueryList getQueryList()
         A list of queries.
         
        .google.cloud.dataproc.v1.QueryList query_list = 2;
        Specified by:
        getQueryList in interface TrinoJobOrBuilder
        Returns:
        The queryList.
      • setQueryList

        public TrinoJob.Builder setQueryList​(QueryList value)
         A list of queries.
         
        .google.cloud.dataproc.v1.QueryList query_list = 2;
      • mergeQueryList

        public TrinoJob.Builder mergeQueryList​(QueryList value)
         A list of queries.
         
        .google.cloud.dataproc.v1.QueryList query_list = 2;
      • clearQueryList

        public TrinoJob.Builder clearQueryList()
         A list of queries.
         
        .google.cloud.dataproc.v1.QueryList query_list = 2;
      • getQueryListBuilder

        public QueryList.Builder getQueryListBuilder()
         A list of queries.
         
        .google.cloud.dataproc.v1.QueryList query_list = 2;
      • getContinueOnFailure

        public boolean getContinueOnFailure()
         Optional. Whether to continue executing queries if a query fails.
         The default value is `false`. Setting to `true` can be useful when
         executing independent parallel queries.
         
        bool continue_on_failure = 3 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getContinueOnFailure in interface TrinoJobOrBuilder
        Returns:
        The continueOnFailure.
      • setContinueOnFailure

        public TrinoJob.Builder setContinueOnFailure​(boolean value)
         Optional. Whether to continue executing queries if a query fails.
         The default value is `false`. Setting to `true` can be useful when
         executing independent parallel queries.
         
        bool continue_on_failure = 3 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        value - The continueOnFailure to set.
        Returns:
        This builder for chaining.
      • clearContinueOnFailure

        public TrinoJob.Builder clearContinueOnFailure()
         Optional. Whether to continue executing queries if a query fails.
         The default value is `false`. Setting to `true` can be useful when
         executing independent parallel queries.
         
        bool continue_on_failure = 3 [(.google.api.field_behavior) = OPTIONAL];
        Returns:
        This builder for chaining.
      • getOutputFormat

        public String getOutputFormat()
         Optional. The format in which query output will be displayed. See the
         Trino documentation for supported output formats
         
        string output_format = 4 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getOutputFormat in interface TrinoJobOrBuilder
        Returns:
        The outputFormat.
      • getOutputFormatBytes

        public com.google.protobuf.ByteString getOutputFormatBytes()
         Optional. The format in which query output will be displayed. See the
         Trino documentation for supported output formats
         
        string output_format = 4 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getOutputFormatBytes in interface TrinoJobOrBuilder
        Returns:
        The bytes for outputFormat.
      • setOutputFormat

        public TrinoJob.Builder setOutputFormat​(String value)
         Optional. The format in which query output will be displayed. See the
         Trino documentation for supported output formats
         
        string output_format = 4 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        value - The outputFormat to set.
        Returns:
        This builder for chaining.
      • clearOutputFormat

        public TrinoJob.Builder clearOutputFormat()
         Optional. The format in which query output will be displayed. See the
         Trino documentation for supported output formats
         
        string output_format = 4 [(.google.api.field_behavior) = OPTIONAL];
        Returns:
        This builder for chaining.
      • setOutputFormatBytes

        public TrinoJob.Builder setOutputFormatBytes​(com.google.protobuf.ByteString value)
         Optional. The format in which query output will be displayed. See the
         Trino documentation for supported output formats
         
        string output_format = 4 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        value - The bytes for outputFormat to set.
        Returns:
        This builder for chaining.
      • getClientTagsList

        public com.google.protobuf.ProtocolStringList getClientTagsList()
         Optional. Trino client tags to attach to this query
         
        repeated string client_tags = 5 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getClientTagsList in interface TrinoJobOrBuilder
        Returns:
        A list containing the clientTags.
      • getClientTagsCount

        public int getClientTagsCount()
         Optional. Trino client tags to attach to this query
         
        repeated string client_tags = 5 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getClientTagsCount in interface TrinoJobOrBuilder
        Returns:
        The count of clientTags.
      • getClientTags

        public String getClientTags​(int index)
         Optional. Trino client tags to attach to this query
         
        repeated string client_tags = 5 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getClientTags in interface TrinoJobOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The clientTags at the given index.
      • getClientTagsBytes

        public com.google.protobuf.ByteString getClientTagsBytes​(int index)
         Optional. Trino client tags to attach to this query
         
        repeated string client_tags = 5 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getClientTagsBytes in interface TrinoJobOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the clientTags at the given index.
      • setClientTags

        public TrinoJob.Builder setClientTags​(int index,
                                              String value)
         Optional. Trino client tags to attach to this query
         
        repeated string client_tags = 5 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        index - The index to set the value at.
        value - The clientTags to set.
        Returns:
        This builder for chaining.
      • addClientTags

        public TrinoJob.Builder addClientTags​(String value)
         Optional. Trino client tags to attach to this query
         
        repeated string client_tags = 5 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        value - The clientTags to add.
        Returns:
        This builder for chaining.
      • addAllClientTags

        public TrinoJob.Builder addAllClientTags​(Iterable<String> values)
         Optional. Trino client tags to attach to this query
         
        repeated string client_tags = 5 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        values - The clientTags to add.
        Returns:
        This builder for chaining.
      • clearClientTags

        public TrinoJob.Builder clearClientTags()
         Optional. Trino client tags to attach to this query
         
        repeated string client_tags = 5 [(.google.api.field_behavior) = OPTIONAL];
        Returns:
        This builder for chaining.
      • addClientTagsBytes

        public TrinoJob.Builder addClientTagsBytes​(com.google.protobuf.ByteString value)
         Optional. Trino client tags to attach to this query
         
        repeated string client_tags = 5 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        value - The bytes of the clientTags to add.
        Returns:
        This builder for chaining.
      • getPropertiesCount

        public int getPropertiesCount()
        Description copied from interface: TrinoJobOrBuilder
         Optional. A mapping of property names to values. Used to set Trino
         [session properties](https://trino.io/docs/current/sql/set-session.html)
         Equivalent to using the --session flag in the Trino CLI
         
        map<string, string> properties = 6 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getPropertiesCount in interface TrinoJobOrBuilder
      • containsProperties

        public boolean containsProperties​(String key)
         Optional. A mapping of property names to values. Used to set Trino
         [session properties](https://trino.io/docs/current/sql/set-session.html)
         Equivalent to using the --session flag in the Trino CLI
         
        map<string, string> properties = 6 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        containsProperties in interface TrinoJobOrBuilder
      • getPropertiesMap

        public Map<String,​String> getPropertiesMap()
         Optional. A mapping of property names to values. Used to set Trino
         [session properties](https://trino.io/docs/current/sql/set-session.html)
         Equivalent to using the --session flag in the Trino CLI
         
        map<string, string> properties = 6 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getPropertiesMap in interface TrinoJobOrBuilder
      • getPropertiesOrDefault

        public String getPropertiesOrDefault​(String key,
                                             String defaultValue)
         Optional. A mapping of property names to values. Used to set Trino
         [session properties](https://trino.io/docs/current/sql/set-session.html)
         Equivalent to using the --session flag in the Trino CLI
         
        map<string, string> properties = 6 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getPropertiesOrDefault in interface TrinoJobOrBuilder
      • getPropertiesOrThrow

        public String getPropertiesOrThrow​(String key)
         Optional. A mapping of property names to values. Used to set Trino
         [session properties](https://trino.io/docs/current/sql/set-session.html)
         Equivalent to using the --session flag in the Trino CLI
         
        map<string, string> properties = 6 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getPropertiesOrThrow in interface TrinoJobOrBuilder
      • removeProperties

        public TrinoJob.Builder removeProperties​(String key)
         Optional. A mapping of property names to values. Used to set Trino
         [session properties](https://trino.io/docs/current/sql/set-session.html)
         Equivalent to using the --session flag in the Trino CLI
         
        map<string, string> properties = 6 [(.google.api.field_behavior) = OPTIONAL];
      • getMutableProperties

        @Deprecated
        public Map<String,​String> getMutableProperties()
        Deprecated.
        Use alternate mutation accessors instead.
      • putProperties

        public TrinoJob.Builder putProperties​(String key,
                                              String value)
         Optional. A mapping of property names to values. Used to set Trino
         [session properties](https://trino.io/docs/current/sql/set-session.html)
         Equivalent to using the --session flag in the Trino CLI
         
        map<string, string> properties = 6 [(.google.api.field_behavior) = OPTIONAL];
      • putAllProperties

        public TrinoJob.Builder putAllProperties​(Map<String,​String> values)
         Optional. A mapping of property names to values. Used to set Trino
         [session properties](https://trino.io/docs/current/sql/set-session.html)
         Equivalent to using the --session flag in the Trino CLI
         
        map<string, string> properties = 6 [(.google.api.field_behavior) = OPTIONAL];
      • hasLoggingConfig

        public boolean hasLoggingConfig()
         Optional. The runtime log config for job execution.
         
        .google.cloud.dataproc.v1.LoggingConfig logging_config = 7 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        hasLoggingConfig in interface TrinoJobOrBuilder
        Returns:
        Whether the loggingConfig field is set.
      • getLoggingConfig

        public LoggingConfig getLoggingConfig()
         Optional. The runtime log config for job execution.
         
        .google.cloud.dataproc.v1.LoggingConfig logging_config = 7 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getLoggingConfig in interface TrinoJobOrBuilder
        Returns:
        The loggingConfig.
      • setLoggingConfig

        public TrinoJob.Builder setLoggingConfig​(LoggingConfig value)
         Optional. The runtime log config for job execution.
         
        .google.cloud.dataproc.v1.LoggingConfig logging_config = 7 [(.google.api.field_behavior) = OPTIONAL];
      • setLoggingConfig

        public TrinoJob.Builder setLoggingConfig​(LoggingConfig.Builder builderForValue)
         Optional. The runtime log config for job execution.
         
        .google.cloud.dataproc.v1.LoggingConfig logging_config = 7 [(.google.api.field_behavior) = OPTIONAL];
      • mergeLoggingConfig

        public TrinoJob.Builder mergeLoggingConfig​(LoggingConfig value)
         Optional. The runtime log config for job execution.
         
        .google.cloud.dataproc.v1.LoggingConfig logging_config = 7 [(.google.api.field_behavior) = OPTIONAL];
      • clearLoggingConfig

        public TrinoJob.Builder clearLoggingConfig()
         Optional. The runtime log config for job execution.
         
        .google.cloud.dataproc.v1.LoggingConfig logging_config = 7 [(.google.api.field_behavior) = OPTIONAL];
      • getLoggingConfigBuilder

        public LoggingConfig.Builder getLoggingConfigBuilder()
         Optional. The runtime log config for job execution.
         
        .google.cloud.dataproc.v1.LoggingConfig logging_config = 7 [(.google.api.field_behavior) = OPTIONAL];
      • setUnknownFields

        public final TrinoJob.Builder setUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        setUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>
      • mergeUnknownFields

        public final TrinoJob.Builder mergeUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        mergeUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<TrinoJob.Builder>