Class QueryInfo

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

    public final class QueryInfo
    extends com.google.protobuf.GeneratedMessageV3
    implements QueryInfoOrBuilder
     Information about a query which a client sends to a ClickHouse server.
     The first QueryInfo can set any of the following fields. Extra QueryInfos only add extra data.
     In extra QueryInfos only `input_data`, `external_tables`, `next_query_info` and `cancel` fields can be set.
     
    Protobuf type clickhouse.grpc.QueryInfo
    See Also:
    Serialized Form
    • 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()
      • internalGetMapField

        protected com.google.protobuf.MapField internalGetMapField​(int number)
        Overrides:
        internalGetMapField in class com.google.protobuf.GeneratedMessageV3
      • internalGetFieldAccessorTable

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

        public com.google.protobuf.ByteString getQueryBytes()
        string query = 1;
        Specified by:
        getQueryBytes in interface QueryInfoOrBuilder
        Returns:
        The bytes for query.
      • getQueryIdBytes

        public com.google.protobuf.ByteString getQueryIdBytes()
        string query_id = 2;
        Specified by:
        getQueryIdBytes in interface QueryInfoOrBuilder
        Returns:
        The bytes for queryId.
      • getDatabaseBytes

        public com.google.protobuf.ByteString getDatabaseBytes()
         Default database.
         
        string database = 4;
        Specified by:
        getDatabaseBytes in interface QueryInfoOrBuilder
        Returns:
        The bytes for database.
      • getInputData

        public com.google.protobuf.ByteString getInputData()
         Input data, used both as data for INSERT query and as data for the input() function.
         
        bytes input_data = 5;
        Specified by:
        getInputData in interface QueryInfoOrBuilder
        Returns:
        The inputData.
      • getInputDataDelimiter

        public com.google.protobuf.ByteString getInputDataDelimiter()
         Delimiter for input_data, inserted between input_data from adjacent QueryInfos.
         
        bytes input_data_delimiter = 6;
        Specified by:
        getInputDataDelimiter in interface QueryInfoOrBuilder
        Returns:
        The inputDataDelimiter.
      • getOutputFormat

        public String getOutputFormat()
         Default output format. If not specified, 'TabSeparated' is used.
         
        string output_format = 7;
        Specified by:
        getOutputFormat in interface QueryInfoOrBuilder
        Returns:
        The outputFormat.
      • getOutputFormatBytes

        public com.google.protobuf.ByteString getOutputFormatBytes()
         Default output format. If not specified, 'TabSeparated' is used.
         
        string output_format = 7;
        Specified by:
        getOutputFormatBytes in interface QueryInfoOrBuilder
        Returns:
        The bytes for outputFormat.
      • getUserNameBytes

        public com.google.protobuf.ByteString getUserNameBytes()
        string user_name = 9;
        Specified by:
        getUserNameBytes in interface QueryInfoOrBuilder
        Returns:
        The bytes for userName.
      • getPasswordBytes

        public com.google.protobuf.ByteString getPasswordBytes()
        string password = 10;
        Specified by:
        getPasswordBytes in interface QueryInfoOrBuilder
        Returns:
        The bytes for password.
      • getQuotaBytes

        public com.google.protobuf.ByteString getQuotaBytes()
        string quota = 11;
        Specified by:
        getQuotaBytes in interface QueryInfoOrBuilder
        Returns:
        The bytes for quota.
      • getSessionId

        public String getSessionId()
         Works exactly like sessions in the HTTP protocol.
         
        string session_id = 12;
        Specified by:
        getSessionId in interface QueryInfoOrBuilder
        Returns:
        The sessionId.
      • getSessionIdBytes

        public com.google.protobuf.ByteString getSessionIdBytes()
         Works exactly like sessions in the HTTP protocol.
         
        string session_id = 12;
        Specified by:
        getSessionIdBytes in interface QueryInfoOrBuilder
        Returns:
        The bytes for sessionId.
      • getSessionCheck

        public boolean getSessionCheck()
        bool session_check = 13;
        Specified by:
        getSessionCheck in interface QueryInfoOrBuilder
        Returns:
        The sessionCheck.
      • getSessionTimeout

        public int getSessionTimeout()
        uint32 session_timeout = 14;
        Specified by:
        getSessionTimeout in interface QueryInfoOrBuilder
        Returns:
        The sessionTimeout.
      • getCancel

        public boolean getCancel()
         Set `cancel` to true to stop executing the query.
         
        bool cancel = 15;
        Specified by:
        getCancel in interface QueryInfoOrBuilder
        Returns:
        The cancel.
      • getNextQueryInfo

        public boolean getNextQueryInfo()
         If true there will be at least one more QueryInfo in the input stream.
         `next_query_info` is allowed to be set only if a method with streaming input (i.e. ExecuteQueryWithStreamInput() or ExecuteQueryWithStreamIO()) is used.
         
        bool next_query_info = 16;
        Specified by:
        getNextQueryInfo in interface QueryInfoOrBuilder
        Returns:
        The nextQueryInfo.
      • hasResultCompression

        public boolean hasResultCompression()
        / Controls how a ClickHouse server will compress query execution results before sending back to the client.
         / If not set the compression settings from the configuration file will be used.
         
        .clickhouse.grpc.Compression result_compression = 17;
        Specified by:
        hasResultCompression in interface QueryInfoOrBuilder
        Returns:
        Whether the resultCompression field is set.
      • getResultCompression

        public Compression getResultCompression()
        / Controls how a ClickHouse server will compress query execution results before sending back to the client.
         / If not set the compression settings from the configuration file will be used.
         
        .clickhouse.grpc.Compression result_compression = 17;
        Specified by:
        getResultCompression in interface QueryInfoOrBuilder
        Returns:
        The resultCompression.
      • getResultCompressionOrBuilder

        public CompressionOrBuilder getResultCompressionOrBuilder()
        / Controls how a ClickHouse server will compress query execution results before sending back to the client.
         / If not set the compression settings from the configuration file will be used.
         
        .clickhouse.grpc.Compression result_compression = 17;
        Specified by:
        getResultCompressionOrBuilder in interface QueryInfoOrBuilder
      • 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 QueryInfo parseFrom​(ByteBuffer data)
                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

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

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

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

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

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

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

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

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

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

        public static QueryInfo getDefaultInstance()
      • parser

        public static com.google.protobuf.Parser<QueryInfo> parser()
      • getParserForType

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