Class SqlGatewayServiceImpl
java.lang.Object
org.apache.flink.table.gateway.service.SqlGatewayServiceImpl
- All Implemented Interfaces:
org.apache.flink.table.gateway.api.SqlGatewayService
public class SqlGatewayServiceImpl
extends Object
implements org.apache.flink.table.gateway.api.SqlGatewayService
The implementation of the
SqlGatewayService interface.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcancelOperation(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle) voidcloseOperation(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle) voidcloseSession(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) completeStatement(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String statement, int position) voidconfigureSession(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String statement, long executionTimeoutMs) <ClusterID>
ClusterIDdeployScript(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, URI scriptUri, String script, org.apache.flink.configuration.Configuration executionConfig) org.apache.flink.table.gateway.api.operation.OperationHandleexecuteStatement(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String statement, long executionTimeoutMs, org.apache.flink.configuration.Configuration executionConfig) org.apache.flink.table.gateway.api.results.ResultSetfetchResults(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle, long token, int maxRows) org.apache.flink.table.gateway.api.results.ResultSetfetchResults(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle, org.apache.flink.table.gateway.api.results.FetchOrientation orientation, int maxRows) getCurrentCatalog(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) org.apache.flink.table.functions.FunctionDefinitiongetFunctionDefinition(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.catalog.UnresolvedIdentifier functionIdentifier) org.apache.flink.table.gateway.api.results.GatewayInfoorg.apache.flink.table.gateway.api.results.OperationInfogetOperationInfo(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle) org.apache.flink.table.catalog.ResolvedSchemagetOperationResultSchema(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle) getSession(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) getSessionConfig(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) org.apache.flink.table.gateway.api.endpoint.EndpointVersiongetSessionEndpointVersion(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) org.apache.flink.table.catalog.ResolvedCatalogBaseTable<?>getTable(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.catalog.ObjectIdentifier tableIdentifier) listCatalogs(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) listDatabases(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String catalogName) Set<org.apache.flink.table.gateway.api.results.FunctionInfo>listSystemFunctions(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) Set<org.apache.flink.table.gateway.api.results.TableInfo>listTables(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String catalogName, String databaseName, Set<org.apache.flink.table.catalog.CatalogBaseTable.TableKind> tableKinds) Set<org.apache.flink.table.gateway.api.results.FunctionInfo>listUserDefinedFunctions(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String catalogName, String databaseName) org.apache.flink.table.gateway.api.session.SessionHandleopenSession(org.apache.flink.table.gateway.api.session.SessionEnvironment environment) org.apache.flink.table.gateway.api.operation.OperationHandlerefreshMaterializedTable(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String materializedTableIdentifier, boolean isPeriodic, String scheduleTime, Map<String, String> dynamicOptions, Map<String, String> staticPartitions, Map<String, String> executionConfig) org.apache.flink.table.gateway.api.operation.OperationHandlesubmitOperation(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, Callable<org.apache.flink.table.gateway.api.results.ResultSet> executor)
-
Constructor Details
-
SqlGatewayServiceImpl
-
-
Method Details
-
openSession
public org.apache.flink.table.gateway.api.session.SessionHandle openSession(org.apache.flink.table.gateway.api.session.SessionEnvironment environment) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
openSessionin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
closeSession
public void closeSession(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
closeSessionin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
configureSession
public void configureSession(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String statement, long executionTimeoutMs) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
configureSessionin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
getSessionConfig
public Map<String,String> getSessionConfig(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
getSessionConfigin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
getSessionEndpointVersion
public org.apache.flink.table.gateway.api.endpoint.EndpointVersion getSessionEndpointVersion(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
getSessionEndpointVersionin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
submitOperation
public org.apache.flink.table.gateway.api.operation.OperationHandle submitOperation(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, Callable<org.apache.flink.table.gateway.api.results.ResultSet> executor) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
submitOperationin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
cancelOperation
public void cancelOperation(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle) - Specified by:
cancelOperationin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService
-
closeOperation
public void closeOperation(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle) - Specified by:
closeOperationin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService
-
getOperationInfo
public org.apache.flink.table.gateway.api.results.OperationInfo getOperationInfo(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle) - Specified by:
getOperationInfoin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService
-
getOperationResultSchema
public org.apache.flink.table.catalog.ResolvedSchema getOperationResultSchema(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
getOperationResultSchemain interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
executeStatement
public org.apache.flink.table.gateway.api.operation.OperationHandle executeStatement(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String statement, long executionTimeoutMs, org.apache.flink.configuration.Configuration executionConfig) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
executeStatementin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
fetchResults
public org.apache.flink.table.gateway.api.results.ResultSet fetchResults(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle, long token, int maxRows) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
fetchResultsin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
fetchResults
public org.apache.flink.table.gateway.api.results.ResultSet fetchResults(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.gateway.api.operation.OperationHandle operationHandle, org.apache.flink.table.gateway.api.results.FetchOrientation orientation, int maxRows) - Specified by:
fetchResultsin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService
-
getCurrentCatalog
public String getCurrentCatalog(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) - Specified by:
getCurrentCatalogin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService
-
listCatalogs
public Set<String> listCatalogs(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
listCatalogsin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
listDatabases
public Set<String> listDatabases(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String catalogName) - Specified by:
listDatabasesin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService
-
listTables
public Set<org.apache.flink.table.gateway.api.results.TableInfo> listTables(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String catalogName, String databaseName, Set<org.apache.flink.table.catalog.CatalogBaseTable.TableKind> tableKinds) - Specified by:
listTablesin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService
-
getTable
public org.apache.flink.table.catalog.ResolvedCatalogBaseTable<?> getTable(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.catalog.ObjectIdentifier tableIdentifier) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
getTablein interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
refreshMaterializedTable
public org.apache.flink.table.gateway.api.operation.OperationHandle refreshMaterializedTable(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String materializedTableIdentifier, boolean isPeriodic, @Nullable String scheduleTime, Map<String, String> dynamicOptions, Map<String, String> staticPartitions, Map<String, String> executionConfig) - Specified by:
refreshMaterializedTablein interfaceorg.apache.flink.table.gateway.api.SqlGatewayService
-
deployScript
public <ClusterID> ClusterID deployScript(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, @Nullable URI scriptUri, @Nullable String script, org.apache.flink.configuration.Configuration executionConfig) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
deployScriptin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
listUserDefinedFunctions
public Set<org.apache.flink.table.gateway.api.results.FunctionInfo> listUserDefinedFunctions(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String catalogName, String databaseName) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
listUserDefinedFunctionsin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
listSystemFunctions
public Set<org.apache.flink.table.gateway.api.results.FunctionInfo> listSystemFunctions(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) - Specified by:
listSystemFunctionsin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService
-
getFunctionDefinition
public org.apache.flink.table.functions.FunctionDefinition getFunctionDefinition(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, org.apache.flink.table.catalog.UnresolvedIdentifier functionIdentifier) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
getFunctionDefinitionin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
getGatewayInfo
public org.apache.flink.table.gateway.api.results.GatewayInfo getGatewayInfo()- Specified by:
getGatewayInfoin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService
-
completeStatement
public List<String> completeStatement(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle, String statement, int position) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException - Specified by:
completeStatementin interfaceorg.apache.flink.table.gateway.api.SqlGatewayService- Throws:
org.apache.flink.table.gateway.api.utils.SqlGatewayException
-
getSession
@VisibleForTesting public Session getSession(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle)
-