Skip to content

Commit

Permalink
Updated thrift files (#161)
Browse files Browse the repository at this point in the history
* Updated thrift files

* Reran command with diff params

---------

Co-authored-by: Levko Kravets <[email protected]>
  • Loading branch information
nithinkdb and kravets-levko authored Aug 17, 2023
1 parent c9e27f4 commit a8e14d7
Show file tree
Hide file tree
Showing 3 changed files with 662 additions and 290 deletions.
43 changes: 43 additions & 0 deletions thrift/TCLIService.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ import TExecuteStatementReq = ttypes.TExecuteStatementReq
import TDBSqlStatement = ttypes.TDBSqlStatement
import TSparkParameterValue = ttypes.TSparkParameterValue
import TSparkParameter = ttypes.TSparkParameter
import TStatementConf = ttypes.TStatementConf
import TExecuteStatementResp = ttypes.TExecuteStatementResp
import TGetTypeInfoReq = ttypes.TGetTypeInfoReq
import TGetTypeInfoResp = ttypes.TGetTypeInfoResp
Expand Down Expand Up @@ -141,46 +142,88 @@ declare class Client {

constructor(output: thrift.TTransport, pClass: { new(trans: thrift.TTransport): thrift.TProtocol });

OpenSession(req: TOpenSessionReq): TOpenSessionResp;

OpenSession(req: TOpenSessionReq, callback?: (error: void, response: TOpenSessionResp)=>void): void;

CloseSession(req: TCloseSessionReq): TCloseSessionResp;

CloseSession(req: TCloseSessionReq, callback?: (error: void, response: TCloseSessionResp)=>void): void;

GetInfo(req: TGetInfoReq): TGetInfoResp;

GetInfo(req: TGetInfoReq, callback?: (error: void, response: TGetInfoResp)=>void): void;

ExecuteStatement(req: TExecuteStatementReq): TExecuteStatementResp;

ExecuteStatement(req: TExecuteStatementReq, callback?: (error: void, response: TExecuteStatementResp)=>void): void;

GetTypeInfo(req: TGetTypeInfoReq): TGetTypeInfoResp;

GetTypeInfo(req: TGetTypeInfoReq, callback?: (error: void, response: TGetTypeInfoResp)=>void): void;

GetCatalogs(req: TGetCatalogsReq): TGetCatalogsResp;

GetCatalogs(req: TGetCatalogsReq, callback?: (error: void, response: TGetCatalogsResp)=>void): void;

GetSchemas(req: TGetSchemasReq): TGetSchemasResp;

GetSchemas(req: TGetSchemasReq, callback?: (error: void, response: TGetSchemasResp)=>void): void;

GetTables(req: TGetTablesReq): TGetTablesResp;

GetTables(req: TGetTablesReq, callback?: (error: void, response: TGetTablesResp)=>void): void;

GetTableTypes(req: TGetTableTypesReq): TGetTableTypesResp;

GetTableTypes(req: TGetTableTypesReq, callback?: (error: void, response: TGetTableTypesResp)=>void): void;

GetColumns(req: TGetColumnsReq): TGetColumnsResp;

GetColumns(req: TGetColumnsReq, callback?: (error: void, response: TGetColumnsResp)=>void): void;

GetFunctions(req: TGetFunctionsReq): TGetFunctionsResp;

GetFunctions(req: TGetFunctionsReq, callback?: (error: void, response: TGetFunctionsResp)=>void): void;

GetPrimaryKeys(req: TGetPrimaryKeysReq): TGetPrimaryKeysResp;

GetPrimaryKeys(req: TGetPrimaryKeysReq, callback?: (error: void, response: TGetPrimaryKeysResp)=>void): void;

GetCrossReference(req: TGetCrossReferenceReq): TGetCrossReferenceResp;

GetCrossReference(req: TGetCrossReferenceReq, callback?: (error: void, response: TGetCrossReferenceResp)=>void): void;

GetOperationStatus(req: TGetOperationStatusReq): TGetOperationStatusResp;

GetOperationStatus(req: TGetOperationStatusReq, callback?: (error: void, response: TGetOperationStatusResp)=>void): void;

CancelOperation(req: TCancelOperationReq): TCancelOperationResp;

CancelOperation(req: TCancelOperationReq, callback?: (error: void, response: TCancelOperationResp)=>void): void;

CloseOperation(req: TCloseOperationReq): TCloseOperationResp;

CloseOperation(req: TCloseOperationReq, callback?: (error: void, response: TCloseOperationResp)=>void): void;

GetResultSetMetadata(req: TGetResultSetMetadataReq): TGetResultSetMetadataResp;

GetResultSetMetadata(req: TGetResultSetMetadataReq, callback?: (error: void, response: TGetResultSetMetadataResp)=>void): void;

FetchResults(req: TFetchResultsReq): TFetchResultsResp;

FetchResults(req: TFetchResultsReq, callback?: (error: void, response: TFetchResultsResp)=>void): void;

GetDelegationToken(req: TGetDelegationTokenReq): TGetDelegationTokenResp;

GetDelegationToken(req: TGetDelegationTokenReq, callback?: (error: void, response: TGetDelegationTokenResp)=>void): void;

CancelDelegationToken(req: TCancelDelegationTokenReq): TCancelDelegationTokenResp;

CancelDelegationToken(req: TCancelDelegationTokenReq, callback?: (error: void, response: TCancelDelegationTokenResp)=>void): void;

RenewDelegationToken(req: TRenewDelegationTokenReq): TRenewDelegationTokenResp;

RenewDelegationToken(req: TRenewDelegationTokenReq, callback?: (error: void, response: TRenewDelegationTokenResp)=>void): void;
}

Expand Down
32 changes: 26 additions & 6 deletions thrift/TCLIService_types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -469,8 +469,9 @@ declare class TSparkArrowResultLink {
public startRowOffset: Int64;
public rowCount: Int64;
public bytesNum: Int64;
public httpHeaders?: { [k: string]: string; };

constructor(args?: { fileLink: string; expiryTime: Int64; startRowOffset: Int64; rowCount: Int64; bytesNum: Int64; });
constructor(args?: { fileLink: string; expiryTime: Int64; startRowOffset: Int64; rowCount: Int64; bytesNum: Int64; httpHeaders?: { [k: string]: string; }; });
}

declare class TDBSqlCloudResultFile {
Expand All @@ -481,8 +482,9 @@ declare class TDBSqlCloudResultFile {
public compressedBytes?: Int64;
public fileLink?: string;
public linkExpiryTime?: Int64;
public httpHeaders?: { [k: string]: string; };

constructor(args?: { filePath?: string; startRowOffset?: Int64; rowCount?: Int64; uncompressedBytes?: Int64; compressedBytes?: Int64; fileLink?: string; linkExpiryTime?: Int64; });
constructor(args?: { filePath?: string; startRowOffset?: Int64; rowCount?: Int64; uncompressedBytes?: Int64; compressedBytes?: Int64; fileLink?: string; linkExpiryTime?: Int64; httpHeaders?: { [k: string]: string; }; });
}

declare class TRowSet {
Expand Down Expand Up @@ -555,9 +557,10 @@ declare class TStatus {
public errorCode?: number;
public errorMessage?: string;
public displayMessage?: string;
public errorDetailsJson?: string;
public responseValidation?: Buffer;

constructor(args?: { statusCode: TStatusCode; infoMessages?: string[]; sqlState?: string; errorCode?: number; errorMessage?: string; displayMessage?: string; responseValidation?: Buffer; });
constructor(args?: { statusCode: TStatusCode; infoMessages?: string[]; sqlState?: string; errorCode?: number; errorMessage?: string; displayMessage?: string; errorDetailsJson?: string; responseValidation?: Buffer; });
}

declare class TNamespace {
Expand Down Expand Up @@ -696,6 +699,8 @@ declare class TExecuteStatementReq {
public useArrowNativeTypes?: TSparkArrowTypes;
public resultRowLimit?: Int64;
public parameters?: TSparkParameter[];
public maxBytesPerBatch?: Int64;
public statementConf?: TStatementConf;
public operationId?: THandleIdentifier;
public sessionConf?: TDBSqlSessionConf;
public rejectHighCostQueries?: boolean;
Expand All @@ -712,8 +717,12 @@ declare class TExecuteStatementReq {
public resultByteLimit?: Int64;
public resultDataFormat?: TDBSqlResultFormat;
public originatingClientIdentity?: string;
public preferSingleFileResult?: boolean;
public preferDriverOnlyUpload?: boolean;
public enforceEmbeddedSchemaCorrectness?: boolean;
public idempotencyToken?: string;

constructor(args?: { sessionHandle: TSessionHandle; statement: string; confOverlay?: { [k: string]: string; }; runAsync?: boolean; getDirectResults?: TSparkGetDirectResults; queryTimeout?: Int64; canReadArrowResult?: boolean; canDownloadResult?: boolean; canDecompressLZ4Result?: boolean; maxBytesPerFile?: Int64; useArrowNativeTypes?: TSparkArrowTypes; resultRowLimit?: Int64; parameters?: TSparkParameter[]; operationId?: THandleIdentifier; sessionConf?: TDBSqlSessionConf; rejectHighCostQueries?: boolean; estimatedCost?: number; executionVersion?: number; requestValidation?: Buffer; resultPersistenceMode?: TResultPersistenceMode; trimArrowBatchesToLimit?: boolean; fetchDisposition?: TDBSqlFetchDisposition; enforceResultPersistenceMode?: boolean; statementList?: TDBSqlStatement[]; persistResultManifest?: boolean; resultRetentionSeconds?: Int64; resultByteLimit?: Int64; resultDataFormat?: TDBSqlResultFormat; originatingClientIdentity?: string; });
constructor(args?: { sessionHandle: TSessionHandle; statement: string; confOverlay?: { [k: string]: string; }; runAsync?: boolean; getDirectResults?: TSparkGetDirectResults; queryTimeout?: Int64; canReadArrowResult?: boolean; canDownloadResult?: boolean; canDecompressLZ4Result?: boolean; maxBytesPerFile?: Int64; useArrowNativeTypes?: TSparkArrowTypes; resultRowLimit?: Int64; parameters?: TSparkParameter[]; maxBytesPerBatch?: Int64; statementConf?: TStatementConf; operationId?: THandleIdentifier; sessionConf?: TDBSqlSessionConf; rejectHighCostQueries?: boolean; estimatedCost?: number; executionVersion?: number; requestValidation?: Buffer; resultPersistenceMode?: TResultPersistenceMode; trimArrowBatchesToLimit?: boolean; fetchDisposition?: TDBSqlFetchDisposition; enforceResultPersistenceMode?: boolean; statementList?: TDBSqlStatement[]; persistResultManifest?: boolean; resultRetentionSeconds?: Int64; resultByteLimit?: Int64; resultDataFormat?: TDBSqlResultFormat; originatingClientIdentity?: string; preferSingleFileResult?: boolean; preferDriverOnlyUpload?: boolean; enforceEmbeddedSchemaCorrectness?: boolean; idempotencyToken?: string; });
}

declare class TDBSqlStatement {
Expand All @@ -739,6 +748,15 @@ declare class TSparkParameter {
constructor(args?: { ordinal?: number; name?: string; type?: string; value?: TSparkParameterValue; });
}

declare class TStatementConf {
public sessionless?: boolean;
public initialNamespace?: TNamespace;
public client_protocol?: TProtocolVersion;
public client_protocol_i64?: Int64;

constructor(args?: { sessionless?: boolean; initialNamespace?: TNamespace; client_protocol?: TProtocolVersion; client_protocol_i64?: Int64; });
}

declare class TExecuteStatementResp {
public status: TStatus;
public operationHandle?: TOperationHandle;
Expand Down Expand Up @@ -961,12 +979,13 @@ declare class TGetOperationStatusResp {
public numModifiedRows?: Int64;
public displayMessage?: string;
public diagnosticInfo?: string;
public errorDetailsJson?: string;
public responseValidation?: Buffer;
public idempotencyType?: TOperationIdempotencyType;
public statementTimeout?: Int64;
public statementTimeoutLevel?: TOperationTimeoutLevel;

constructor(args?: { status: TStatus; operationState?: TOperationState; sqlState?: string; errorCode?: number; errorMessage?: string; taskStatus?: string; operationStarted?: Int64; operationCompleted?: Int64; hasResultSet?: boolean; progressUpdateResponse?: TProgressUpdateResp; numModifiedRows?: Int64; displayMessage?: string; diagnosticInfo?: string; responseValidation?: Buffer; idempotencyType?: TOperationIdempotencyType; statementTimeout?: Int64; statementTimeoutLevel?: TOperationTimeoutLevel; });
constructor(args?: { status: TStatus; operationState?: TOperationState; sqlState?: string; errorCode?: number; errorMessage?: string; taskStatus?: string; operationStarted?: Int64; operationCompleted?: Int64; hasResultSet?: boolean; progressUpdateResponse?: TProgressUpdateResp; numModifiedRows?: Int64; displayMessage?: string; diagnosticInfo?: string; errorDetailsJson?: string; responseValidation?: Buffer; idempotencyType?: TOperationIdempotencyType; statementTimeout?: Int64; statementTimeoutLevel?: TOperationTimeoutLevel; });
}

declare class TCancelOperationReq {
Expand Down Expand Up @@ -1023,8 +1042,9 @@ declare class TGetResultSetMetadataResp {
public isServerless?: boolean;
public resultDataFormat?: TDBSqlResultFormat;
public truncatedByThriftLimit?: boolean;
public resultByteLimit?: Int64;

constructor(args?: { status: TStatus; schema?: TTableSchema; resultFormat?: TSparkRowSetType; lz4Compressed?: boolean; arrowSchema?: Buffer; cacheLookupResult?: TCacheLookupResult; uncompressedBytes?: Int64; compressedBytes?: Int64; isStagingOperation?: boolean; reasonForNoCloudFetch?: TCloudFetchDisabledReason; resultFiles?: TDBSqlCloudResultFile[]; manifestFile?: string; manifestFileFormat?: TDBSqlManifestFileFormat; cacheLookupLatency?: Int64; remoteCacheMissReason?: string; fetchDisposition?: TDBSqlFetchDisposition; remoteResultCacheEnabled?: boolean; isServerless?: boolean; resultDataFormat?: TDBSqlResultFormat; truncatedByThriftLimit?: boolean; });
constructor(args?: { status: TStatus; schema?: TTableSchema; resultFormat?: TSparkRowSetType; lz4Compressed?: boolean; arrowSchema?: Buffer; cacheLookupResult?: TCacheLookupResult; uncompressedBytes?: Int64; compressedBytes?: Int64; isStagingOperation?: boolean; reasonForNoCloudFetch?: TCloudFetchDisabledReason; resultFiles?: TDBSqlCloudResultFile[]; manifestFile?: string; manifestFileFormat?: TDBSqlManifestFileFormat; cacheLookupLatency?: Int64; remoteCacheMissReason?: string; fetchDisposition?: TDBSqlFetchDisposition; remoteResultCacheEnabled?: boolean; isServerless?: boolean; resultDataFormat?: TDBSqlResultFormat; truncatedByThriftLimit?: boolean; resultByteLimit?: Int64; });
}

declare class TFetchResultsReq {
Expand Down
Loading

0 comments on commit a8e14d7

Please sign in to comment.