HttpStreamSession
Defined in: src/client/stream.ts:28
StreamSession implementation for the HTTP transport. Stream state is carried statelessly across requests via an HMAC state token: each HttpStreamSession.exchange or producer-continuation POST sends the current token and receives the next one in the response metadata.
Implements
Section titled “Implements”Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new HttpStreamSession(opts): HttpStreamSession;Defined in: src/client/stream.ts:46
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
opts | { authorization?: string; baseUrl: string; compressFn?: CompressFn; compressionLevel?: number; decompressFn?: DecompressFn; externalConfig?: ExternalLocationConfig; finished: boolean; header: Record<string, any> | null; inputSchema?: Schema<any>; method: string; onLog?: (msg) => void; outputSchema: Schema; pendingBatches: RecordBatch<any>[]; postFn?: PostFn; prefix: string; stateToken: string | null; } |
opts.authorization? | string |
opts.baseUrl | string |
opts.compressFn? | CompressFn |
opts.compressionLevel? | number |
opts.decompressFn? | DecompressFn |
opts.externalConfig? | ExternalLocationConfig |
opts.finished | boolean |
opts.header | Record<string, any> | null |
opts.inputSchema? | Schema<any> |
opts.method | string |
opts.onLog? | (msg) => void |
opts.outputSchema | Schema |
opts.pendingBatches | RecordBatch<any>[] |
opts.postFn? | PostFn |
opts.prefix | string |
opts.stateToken | string | null |
Returns
Section titled “Returns”HttpStreamSession
Accessors
Section titled “Accessors”header
Section titled “header”Get Signature
Section titled “Get Signature”get header(): Record<string, any> | null;Defined in: src/client/stream.ts:92
The stream’s one-time header row, or null if the method declares no header.
Returns
Section titled “Returns”Record<string, any> | null
The method’s header row (returned once at stream start), or null if the method declares no header.
Implementation of
Section titled “Implementation of”Methods
Section titled “Methods”[asyncIterator]()
Section titled “[asyncIterator]()”asyncIterator: AsyncIterableIterator<Record<string, any>[]>;Defined in: src/client/stream.ts:240
Iterate over producer stream batches.
Returns
Section titled “Returns”AsyncIterableIterator<Record<string, any>[]>
Implementation of
Section titled “Implementation of”close()
Section titled “close()”close(): void;Defined in: src/client/stream.ts:316
No-op: the HTTP transport is stateless, so there is nothing to tear down.
Returns
Section titled “Returns”void
Implementation of
Section titled “Implementation of”exchange()
Section titled “exchange()”exchange(input): Promise<Record<string, any>[]>;Defined in: src/client/stream.ts:130
Send an exchange request and return the data rows.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
input | Record<string, any>[] |
Returns
Section titled “Returns”Promise<Record<string, any>[]>