public static ColumnDescriptor newPrimitiveColumnDescriptor(String name, String comment, Type type, int position) { // Current usage looks like it's only for metadata columns, but if that changes then // this method may need to require a type qualifiers aruments. return new ColumnDescriptor(name, comment, new TypeDescriptor(type), position); }
public RowBasedSet(TableSchema schema) { descriptors = schema.toTypeDescriptors(); rows = new RemovableList<TRow>(); }
public TOperationHandle toTOperationHandle() { TOperationHandle tOperationHandle = new TOperationHandle(); tOperationHandle.setOperationId(getHandleIdentifier().toTHandleIdentifier()); tOperationHandle.setOperationType(opType.toTOperationType()); tOperationHandle.setHasResultSet(hasResultSet); return tOperationHandle; }
public UUID getSessionId() { return getHandleIdentifier().getPublicId(); }
@Override public SessionHandle openSessionWithImpersonation(String username, String password, Map<String, String> configuration, String delegationToken) throws HiveSQLException { throw new HiveSQLException("Impersonated session is not supported in the embedded mode"); }
@Override public RowSet fetchResults(OperationHandle opHandle) throws HiveSQLException { return fetchResults(opHandle, Operation.DEFAULT_FETCH_ORIENTATION, defaultFetchRows, FetchType.QUERY_OUTPUT); }
@Override public RowSet fetchResults(OperationHandle opHandle) throws HiveSQLException { return fetchResults(opHandle, FetchOrientation.FETCH_NEXT, defaultFetchRows, FetchType.QUERY_OUTPUT); }
@Override public OperationHandle executeStatement(SessionHandle sessionHandle, String statement, Map<String, String> confOverlay, long queryTimeout) throws HiveSQLException { return cliService.executeStatement(sessionHandle, statement, confOverlay, queryTimeout); }
@Override public RowSet fetchResults(OperationHandle opHandle, FetchOrientation orientation, long maxRows, FetchType fetchType) throws HiveSQLException { return cliService.fetchResults(opHandle, orientation, maxRows, fetchType); }
@Override public SessionHandle openSession(String username, String password, Map<String, String> configuration) throws HiveSQLException { return cliService.openSession(username, password, configuration); }
@Override public OperationHandle getColumns(SessionHandle sessionHandle, String catalogName, String schemaName, String tableName, String columnName) throws HiveSQLException { return cliService.getColumns(sessionHandle, catalogName, schemaName, tableName, columnName); }
@Override public OperationHandle getSchemas(SessionHandle sessionHandle, String catalogName, String schemaName) throws HiveSQLException { return cliService.getSchemas(sessionHandle, catalogName, schemaName); }
@Override public void renewDelegationToken(SessionHandle sessionHandle, HiveAuthFactory authFactory, String tokenStr) throws HiveSQLException { cliService.renewDelegationToken(sessionHandle, authFactory, tokenStr); }
@Override public GetInfoValue getInfo(SessionHandle sessionHandle, GetInfoType getInfoType) throws HiveSQLException { return cliService.getInfo(sessionHandle, getInfoType); }
@Override public SessionHandle openSessionWithImpersonation(String username, String password, Map<String, String> configuration, String delegationToken) throws HiveSQLException { return cliService.openSessionWithImpersonation(username, password, configuration, delegationToken); }
@Override public void setApplicationName(SessionHandle sh, String value) throws HiveSQLException { cliService.setApplicationName(sh, value); } }
@Override public OperationHandle getCrossReference(SessionHandle sessionHandle, String primaryCatalog, String primarySchema, String primaryTable, String foreignCatalog, String foreignSchema, String foreignTable) throws HiveSQLException { return cliService.getCrossReference(sessionHandle, primaryCatalog, primarySchema, primaryTable, foreignCatalog, foreignSchema, foreignTable); }
@Override public OperationHandle executeStatement(SessionHandle sessionHandle, String statement, Map<String, String> confOverlay) throws HiveSQLException { return cliService.executeStatement(sessionHandle, statement, confOverlay); }
@Override public RowSet fetchResults(OperationHandle opHandle, FetchOrientation orientation, long maxRows, FetchType fetchType) throws HiveSQLException { return cliService.fetchResults(opHandle, orientation, maxRows, fetchType); }