Class HiveServer2Endpoint
- java.lang.Object
-
- org.apache.flink.table.endpoint.hive.HiveServer2Endpoint
-
- All Implemented Interfaces:
Runnable
,SqlGatewayEndpoint
,org.apache.hive.service.rpc.thrift.TCLIService.Iface
public class HiveServer2Endpoint extends Object implements org.apache.hive.service.rpc.thrift.TCLIService.Iface, SqlGatewayEndpoint, Runnable
HiveServer2 Endpoint that allows to accept the request from the hive client, e.g. Hive JDBC, Hive Beeline.
-
-
Constructor Summary
Constructors Constructor Description HiveServer2Endpoint(SqlGatewayService service, InetSocketAddress socketAddress, long maxMessageSize, int requestTimeoutMs, int backOffSlotLengthMs, int minWorkerThreads, int maxWorkerThreads, Duration workerKeepAliveTime, String catalogName, HiveConf hiveConf, String defaultDatabase, String moduleName)
HiveServer2Endpoint(SqlGatewayService service, InetSocketAddress socketAddress, long maxMessageSize, int requestTimeoutMs, int backOffSlotLengthMs, int minWorkerThreads, int maxWorkerThreads, Duration workerKeepAliveTime, String catalogName, HiveConf hiveConf, String defaultDatabase, String moduleName, boolean allowEmbedded, boolean isVerbose)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.hive.service.rpc.thrift.TCancelDelegationTokenResp
CancelDelegationToken(org.apache.hive.service.rpc.thrift.TCancelDelegationTokenReq tCancelDelegationTokenReq)
org.apache.hive.service.rpc.thrift.TCancelOperationResp
CancelOperation(org.apache.hive.service.rpc.thrift.TCancelOperationReq tCancelOperationReq)
org.apache.hive.service.rpc.thrift.TCloseOperationResp
CloseOperation(org.apache.hive.service.rpc.thrift.TCloseOperationReq tCloseOperationReq)
org.apache.hive.service.rpc.thrift.TCloseSessionResp
CloseSession(org.apache.hive.service.rpc.thrift.TCloseSessionReq tCloseSessionReq)
boolean
equals(Object o)
org.apache.hive.service.rpc.thrift.TExecuteStatementResp
ExecuteStatement(org.apache.hive.service.rpc.thrift.TExecuteStatementReq tExecuteStatementReq)
org.apache.hive.service.rpc.thrift.TFetchResultsResp
FetchResults(org.apache.hive.service.rpc.thrift.TFetchResultsReq tFetchResultsReq)
org.apache.hive.service.rpc.thrift.TGetCatalogsResp
GetCatalogs(org.apache.hive.service.rpc.thrift.TGetCatalogsReq tGetCatalogsReq)
org.apache.hive.service.rpc.thrift.TGetColumnsResp
GetColumns(org.apache.hive.service.rpc.thrift.TGetColumnsReq tGetColumnsReq)
org.apache.hive.service.rpc.thrift.TGetCrossReferenceResp
GetCrossReference(org.apache.hive.service.rpc.thrift.TGetCrossReferenceReq tGetCrossReferenceReq)
org.apache.hive.service.rpc.thrift.TGetDelegationTokenResp
GetDelegationToken(org.apache.hive.service.rpc.thrift.TGetDelegationTokenReq tGetDelegationTokenReq)
org.apache.hive.service.rpc.thrift.TGetFunctionsResp
GetFunctions(org.apache.hive.service.rpc.thrift.TGetFunctionsReq tGetFunctionsReq)
org.apache.hive.service.rpc.thrift.TGetInfoResp
GetInfo(org.apache.hive.service.rpc.thrift.TGetInfoReq tGetInfoReq)
org.apache.hive.service.rpc.thrift.TGetOperationStatusResp
GetOperationStatus(org.apache.hive.service.rpc.thrift.TGetOperationStatusReq tGetOperationStatusReq)
org.apache.hive.service.rpc.thrift.TGetPrimaryKeysResp
GetPrimaryKeys(org.apache.hive.service.rpc.thrift.TGetPrimaryKeysReq tGetPrimaryKeysReq)
TGetQueryIdResp
GetQueryId(TGetQueryIdReq tGetQueryIdReq)
To be compatible with Hive3, add a default implementation.org.apache.hive.service.rpc.thrift.TGetResultSetMetadataResp
GetResultSetMetadata(org.apache.hive.service.rpc.thrift.TGetResultSetMetadataReq tGetResultSetMetadataReq)
org.apache.hive.service.rpc.thrift.TGetSchemasResp
GetSchemas(org.apache.hive.service.rpc.thrift.TGetSchemasReq tGetSchemasReq)
org.apache.hive.service.rpc.thrift.TGetTablesResp
GetTables(org.apache.hive.service.rpc.thrift.TGetTablesReq tGetTablesReq)
org.apache.hive.service.rpc.thrift.TGetTableTypesResp
GetTableTypes(org.apache.hive.service.rpc.thrift.TGetTableTypesReq tGetTableTypesReq)
org.apache.hive.service.rpc.thrift.TGetTypeInfoResp
GetTypeInfo(org.apache.hive.service.rpc.thrift.TGetTypeInfoReq tGetTypeInfoReq)
int
hashCode()
org.apache.hive.service.rpc.thrift.TOpenSessionResp
OpenSession(org.apache.hive.service.rpc.thrift.TOpenSessionReq tOpenSessionReq)
org.apache.hive.service.rpc.thrift.TRenewDelegationTokenResp
RenewDelegationToken(org.apache.hive.service.rpc.thrift.TRenewDelegationTokenReq tRenewDelegationTokenReq)
void
run()
TSetClientInfoResp
SetClientInfo(TSetClientInfoReq tSetClientInfoReq)
To be compatible with Hive3, add a default implementation.void
start()
Start the endpoint.void
stop()
Terminate the endpoint.
-
-
-
Constructor Detail
-
HiveServer2Endpoint
public HiveServer2Endpoint(SqlGatewayService service, InetSocketAddress socketAddress, long maxMessageSize, int requestTimeoutMs, int backOffSlotLengthMs, int minWorkerThreads, int maxWorkerThreads, Duration workerKeepAliveTime, String catalogName, HiveConf hiveConf, @Nullable String defaultDatabase, String moduleName)
-
HiveServer2Endpoint
@VisibleForTesting public HiveServer2Endpoint(SqlGatewayService service, InetSocketAddress socketAddress, long maxMessageSize, int requestTimeoutMs, int backOffSlotLengthMs, int minWorkerThreads, int maxWorkerThreads, Duration workerKeepAliveTime, String catalogName, HiveConf hiveConf, @Nullable String defaultDatabase, String moduleName, boolean allowEmbedded, boolean isVerbose)
-
-
Method Detail
-
start
public void start() throws Exception
Description copied from interface:SqlGatewayEndpoint
Start the endpoint.- Specified by:
start
in interfaceSqlGatewayEndpoint
- Throws:
Exception
-
stop
public void stop() throws Exception
Description copied from interface:SqlGatewayEndpoint
Terminate the endpoint.- Specified by:
stop
in interfaceSqlGatewayEndpoint
- Throws:
Exception
-
OpenSession
public org.apache.hive.service.rpc.thrift.TOpenSessionResp OpenSession(org.apache.hive.service.rpc.thrift.TOpenSessionReq tOpenSessionReq) throws org.apache.thrift.TException
- Specified by:
OpenSession
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
CloseSession
public org.apache.hive.service.rpc.thrift.TCloseSessionResp CloseSession(org.apache.hive.service.rpc.thrift.TCloseSessionReq tCloseSessionReq) throws org.apache.thrift.TException
- Specified by:
CloseSession
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetInfo
public org.apache.hive.service.rpc.thrift.TGetInfoResp GetInfo(org.apache.hive.service.rpc.thrift.TGetInfoReq tGetInfoReq) throws org.apache.thrift.TException
- Specified by:
GetInfo
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
ExecuteStatement
public org.apache.hive.service.rpc.thrift.TExecuteStatementResp ExecuteStatement(org.apache.hive.service.rpc.thrift.TExecuteStatementReq tExecuteStatementReq) throws org.apache.thrift.TException
- Specified by:
ExecuteStatement
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetTypeInfo
public org.apache.hive.service.rpc.thrift.TGetTypeInfoResp GetTypeInfo(org.apache.hive.service.rpc.thrift.TGetTypeInfoReq tGetTypeInfoReq) throws org.apache.thrift.TException
- Specified by:
GetTypeInfo
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetCatalogs
public org.apache.hive.service.rpc.thrift.TGetCatalogsResp GetCatalogs(org.apache.hive.service.rpc.thrift.TGetCatalogsReq tGetCatalogsReq) throws org.apache.thrift.TException
- Specified by:
GetCatalogs
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetSchemas
public org.apache.hive.service.rpc.thrift.TGetSchemasResp GetSchemas(org.apache.hive.service.rpc.thrift.TGetSchemasReq tGetSchemasReq) throws org.apache.thrift.TException
- Specified by:
GetSchemas
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetTables
public org.apache.hive.service.rpc.thrift.TGetTablesResp GetTables(org.apache.hive.service.rpc.thrift.TGetTablesReq tGetTablesReq) throws org.apache.thrift.TException
- Specified by:
GetTables
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetTableTypes
public org.apache.hive.service.rpc.thrift.TGetTableTypesResp GetTableTypes(org.apache.hive.service.rpc.thrift.TGetTableTypesReq tGetTableTypesReq) throws org.apache.thrift.TException
- Specified by:
GetTableTypes
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetColumns
public org.apache.hive.service.rpc.thrift.TGetColumnsResp GetColumns(org.apache.hive.service.rpc.thrift.TGetColumnsReq tGetColumnsReq) throws org.apache.thrift.TException
- Specified by:
GetColumns
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetFunctions
public org.apache.hive.service.rpc.thrift.TGetFunctionsResp GetFunctions(org.apache.hive.service.rpc.thrift.TGetFunctionsReq tGetFunctionsReq) throws org.apache.thrift.TException
- Specified by:
GetFunctions
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetPrimaryKeys
public org.apache.hive.service.rpc.thrift.TGetPrimaryKeysResp GetPrimaryKeys(org.apache.hive.service.rpc.thrift.TGetPrimaryKeysReq tGetPrimaryKeysReq) throws org.apache.thrift.TException
- Specified by:
GetPrimaryKeys
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetCrossReference
public org.apache.hive.service.rpc.thrift.TGetCrossReferenceResp GetCrossReference(org.apache.hive.service.rpc.thrift.TGetCrossReferenceReq tGetCrossReferenceReq) throws org.apache.thrift.TException
- Specified by:
GetCrossReference
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetOperationStatus
public org.apache.hive.service.rpc.thrift.TGetOperationStatusResp GetOperationStatus(org.apache.hive.service.rpc.thrift.TGetOperationStatusReq tGetOperationStatusReq) throws org.apache.thrift.TException
- Specified by:
GetOperationStatus
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
CancelOperation
public org.apache.hive.service.rpc.thrift.TCancelOperationResp CancelOperation(org.apache.hive.service.rpc.thrift.TCancelOperationReq tCancelOperationReq) throws org.apache.thrift.TException
- Specified by:
CancelOperation
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
CloseOperation
public org.apache.hive.service.rpc.thrift.TCloseOperationResp CloseOperation(org.apache.hive.service.rpc.thrift.TCloseOperationReq tCloseOperationReq) throws org.apache.thrift.TException
- Specified by:
CloseOperation
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetResultSetMetadata
public org.apache.hive.service.rpc.thrift.TGetResultSetMetadataResp GetResultSetMetadata(org.apache.hive.service.rpc.thrift.TGetResultSetMetadataReq tGetResultSetMetadataReq) throws org.apache.thrift.TException
- Specified by:
GetResultSetMetadata
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
FetchResults
public org.apache.hive.service.rpc.thrift.TFetchResultsResp FetchResults(org.apache.hive.service.rpc.thrift.TFetchResultsReq tFetchResultsReq) throws org.apache.thrift.TException
- Specified by:
FetchResults
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetDelegationToken
public org.apache.hive.service.rpc.thrift.TGetDelegationTokenResp GetDelegationToken(org.apache.hive.service.rpc.thrift.TGetDelegationTokenReq tGetDelegationTokenReq) throws org.apache.thrift.TException
- Specified by:
GetDelegationToken
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
CancelDelegationToken
public org.apache.hive.service.rpc.thrift.TCancelDelegationTokenResp CancelDelegationToken(org.apache.hive.service.rpc.thrift.TCancelDelegationTokenReq tCancelDelegationTokenReq) throws org.apache.thrift.TException
- Specified by:
CancelDelegationToken
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
RenewDelegationToken
public org.apache.hive.service.rpc.thrift.TRenewDelegationTokenResp RenewDelegationToken(org.apache.hive.service.rpc.thrift.TRenewDelegationTokenReq tRenewDelegationTokenReq) throws org.apache.thrift.TException
- Specified by:
RenewDelegationToken
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
GetQueryId
public TGetQueryIdResp GetQueryId(TGetQueryIdReq tGetQueryIdReq) throws org.apache.thrift.TException
To be compatible with Hive3, add a default implementation.- Specified by:
GetQueryId
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
SetClientInfo
public TSetClientInfoResp SetClientInfo(TSetClientInfoReq tSetClientInfoReq) throws org.apache.thrift.TException
To be compatible with Hive3, add a default implementation.- Specified by:
SetClientInfo
in interfaceorg.apache.hive.service.rpc.thrift.TCLIService.Iface
- Throws:
org.apache.thrift.TException
-
-