UNPKG

@google-cloud/bigtable

Version:
744 lines (743 loc) 40.6 kB
import type * as gax from 'google-gax'; import type { Callback, CallOptions, Descriptors, ClientOptions } from 'google-gax'; import * as protos from '../../protos/protos'; /** * Service for reading from and writing to existing Bigtable tables. * @class * @memberof v2 */ export declare class BigtableClient { private _terminated; private _opts; private _providedCustomServicePath; private _gaxModule; private _gaxGrpc; private _protos; private _defaults; private _universeDomain; private _servicePath; private _log; auth: gax.GoogleAuth; descriptors: Descriptors; warn: (code: string, message: string, warnType?: string) => void; innerApiCalls: { [name: string]: Function; }; pathTemplates: { [name: string]: gax.PathTemplate; }; bigtableStub?: Promise<{ [name: string]: Function; }>; /** * Construct an instance of BigtableClient. * * @param {object} [options] - The configuration object. * The options accepted by the constructor are described in detail * in [this document](https://github.com/googleapis/gax-nodejs/blob/main/client-libraries.md#creating-the-client-instance). * The common options are: * @param {object} [options.credentials] - Credentials object. * @param {string} [options.credentials.client_email] * @param {string} [options.credentials.private_key] * @param {string} [options.email] - Account email address. Required when * using a .pem or .p12 keyFilename. * @param {string} [options.keyFilename] - Full path to the a .json, .pem, or * .p12 key downloaded from the Google Developers Console. If you provide * a path to a JSON file, the projectId option below is not necessary. * NOTE: .pem and .p12 require you to specify options.email as well. * @param {number} [options.port] - The port on which to connect to * the remote host. * @param {string} [options.projectId] - The project ID from the Google * Developer's Console, e.g. 'grape-spaceship-123'. We will also check * the environment variable GCLOUD_PROJECT for your project ID. If your * app is running in an environment which supports * {@link https://cloud.google.com/docs/authentication/application-default-credentials Application Default Credentials}, * your project ID will be detected automatically. * @param {string} [options.apiEndpoint] - The domain name of the * API remote host. * @param {gax.ClientConfig} [options.clientConfig] - Client configuration override. * Follows the structure of {@link gapicConfig}. * @param {boolean} [options.fallback] - Use HTTP/1.1 REST mode. * For more information, please check the * {@link https://github.com/googleapis/gax-nodejs/blob/main/client-libraries.md#http11-rest-api-mode documentation}. * @param {gax} [gaxInstance]: loaded instance of `google-gax`. Useful if you * need to avoid loading the default gRPC version and want to use the fallback * HTTP implementation. Load only fallback version and pass it to the constructor: * ``` * const gax = require('google-gax/build/src/fallback'); // avoids loading google-gax with gRPC * const client = new BigtableClient({fallback: true}, gax); * ``` */ constructor(opts?: ClientOptions, gaxInstance?: typeof gax | typeof gax.fallback); /** * Initialize the client. * Performs asynchronous operations (such as authentication) and prepares the client. * This function will be called automatically when any class method is called for the * first time, but if you need to initialize it before calling an actual method, * feel free to call initialize() directly. * * You can await on this method if you want to make sure the client is initialized. * * @returns {Promise} A promise that resolves to an authenticated service stub. */ initialize(): Promise<{ [name: string]: Function; }>; /** * The DNS address for this API service. * @deprecated Use the apiEndpoint method of the client instance. * @returns {string} The DNS address for this service. */ static get servicePath(): string; /** * The DNS address for this API service - same as servicePath. * @deprecated Use the apiEndpoint method of the client instance. * @returns {string} The DNS address for this service. */ static get apiEndpoint(): string; /** * The DNS address for this API service. * @returns {string} The DNS address for this service. */ get apiEndpoint(): string; get universeDomain(): string; /** * The port for this API service. * @returns {number} The default port for this service. */ static get port(): number; /** * The scopes needed to make gRPC calls for every method defined * in this service. * @returns {string[]} List of default scopes. */ static get scopes(): string[]; getProjectId(): Promise<string>; getProjectId(callback: Callback<string, undefined, undefined>): void; /** * Mutates a row atomically. Cells already present in the row are left * unchanged unless explicitly changed by `mutation`. * * @param {Object} request * The request object that will be sent. * @param {string} [request.tableName] * Optional. The unique name of the table to which the mutation should be * applied. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>`. * @param {string} [request.authorizedViewName] * Optional. The unique name of the AuthorizedView to which the mutation * should be applied. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>/authorizedViews/<authorized_view>`. * @param {string} request.appProfileId * This value specifies routing for replication. If not specified, the * "default" application profile will be used. * @param {Buffer} request.rowKey * Required. The key of the row to which the mutation should be applied. * @param {number[]} request.mutations * Required. Changes to be atomically applied to the specified row. Entries * are applied in order, meaning that earlier mutations can be masked by later * ones. Must contain at least one entry and at most 100000. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Promise} - The promise which resolves to an array. * The first element of the array is an object representing {@link protos.google.bigtable.v2.MutateRowResponse|MutateRowResponse}. * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods | documentation } * for more details and examples. */ mutateRow(request?: protos.google.bigtable.v2.IMutateRowRequest, options?: CallOptions): Promise<[ protos.google.bigtable.v2.IMutateRowResponse, protos.google.bigtable.v2.IMutateRowRequest | undefined, {} | undefined ]>; mutateRow(request: protos.google.bigtable.v2.IMutateRowRequest, options: CallOptions, callback: Callback<protos.google.bigtable.v2.IMutateRowResponse, protos.google.bigtable.v2.IMutateRowRequest | null | undefined, {} | null | undefined>): void; mutateRow(request: protos.google.bigtable.v2.IMutateRowRequest, callback: Callback<protos.google.bigtable.v2.IMutateRowResponse, protos.google.bigtable.v2.IMutateRowRequest | null | undefined, {} | null | undefined>): void; /** * Mutates a row atomically based on the output of a predicate Reader filter. * * @param {Object} request * The request object that will be sent. * @param {string} [request.tableName] * Optional. The unique name of the table to which the conditional mutation * should be applied. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>`. * @param {string} [request.authorizedViewName] * Optional. The unique name of the AuthorizedView to which the conditional * mutation should be applied. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>/authorizedViews/<authorized_view>`. * @param {string} request.appProfileId * This value specifies routing for replication. If not specified, the * "default" application profile will be used. * @param {Buffer} request.rowKey * Required. The key of the row to which the conditional mutation should be * applied. * @param {google.bigtable.v2.RowFilter} request.predicateFilter * The filter to be applied to the contents of the specified row. Depending * on whether or not any results are yielded, either `true_mutations` or * `false_mutations` will be executed. If unset, checks that the row contains * any values at all. * @param {number[]} request.trueMutations * Changes to be atomically applied to the specified row if `predicate_filter` * yields at least one cell when applied to `row_key`. Entries are applied in * order, meaning that earlier mutations can be masked by later ones. * Must contain at least one entry if `false_mutations` is empty, and at most * 100000. * @param {number[]} request.falseMutations * Changes to be atomically applied to the specified row if `predicate_filter` * does not yield any cells when applied to `row_key`. Entries are applied in * order, meaning that earlier mutations can be masked by later ones. * Must contain at least one entry if `true_mutations` is empty, and at most * 100000. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Promise} - The promise which resolves to an array. * The first element of the array is an object representing {@link protos.google.bigtable.v2.CheckAndMutateRowResponse|CheckAndMutateRowResponse}. * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods | documentation } * for more details and examples. */ checkAndMutateRow(request?: protos.google.bigtable.v2.ICheckAndMutateRowRequest, options?: CallOptions): Promise<[ protos.google.bigtable.v2.ICheckAndMutateRowResponse, protos.google.bigtable.v2.ICheckAndMutateRowRequest | undefined, {} | undefined ]>; checkAndMutateRow(request: protos.google.bigtable.v2.ICheckAndMutateRowRequest, options: CallOptions, callback: Callback<protos.google.bigtable.v2.ICheckAndMutateRowResponse, protos.google.bigtable.v2.ICheckAndMutateRowRequest | null | undefined, {} | null | undefined>): void; checkAndMutateRow(request: protos.google.bigtable.v2.ICheckAndMutateRowRequest, callback: Callback<protos.google.bigtable.v2.ICheckAndMutateRowResponse, protos.google.bigtable.v2.ICheckAndMutateRowRequest | null | undefined, {} | null | undefined>): void; /** * Warm up associated instance metadata for this connection. * This call is not required but may be useful for connection keep-alive. * * @param {Object} request * The request object that will be sent. * @param {string} request.name * Required. The unique name of the instance to check permissions for as well * as respond. Values are of the form * `projects/<project>/instances/<instance>`. * @param {string} request.appProfileId * This value specifies routing for replication. If not specified, the * "default" application profile will be used. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Promise} - The promise which resolves to an array. * The first element of the array is an object representing {@link protos.google.bigtable.v2.PingAndWarmResponse|PingAndWarmResponse}. * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods | documentation } * for more details and examples. */ pingAndWarm(request?: protos.google.bigtable.v2.IPingAndWarmRequest, options?: CallOptions): Promise<[ protos.google.bigtable.v2.IPingAndWarmResponse, protos.google.bigtable.v2.IPingAndWarmRequest | undefined, {} | undefined ]>; pingAndWarm(request: protos.google.bigtable.v2.IPingAndWarmRequest, options: CallOptions, callback: Callback<protos.google.bigtable.v2.IPingAndWarmResponse, protos.google.bigtable.v2.IPingAndWarmRequest | null | undefined, {} | null | undefined>): void; pingAndWarm(request: protos.google.bigtable.v2.IPingAndWarmRequest, callback: Callback<protos.google.bigtable.v2.IPingAndWarmResponse, protos.google.bigtable.v2.IPingAndWarmRequest | null | undefined, {} | null | undefined>): void; /** * Modifies a row atomically on the server. The method reads the latest * existing timestamp and value from the specified columns and writes a new * entry based on pre-defined read/modify/write rules. The new value for the * timestamp is the greater of the existing timestamp or the current server * time. The method returns the new contents of all modified cells. * * @param {Object} request * The request object that will be sent. * @param {string} [request.tableName] * Optional. The unique name of the table to which the read/modify/write rules * should be applied. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>`. * @param {string} [request.authorizedViewName] * Optional. The unique name of the AuthorizedView to which the * read/modify/write rules should be applied. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>/authorizedViews/<authorized_view>`. * @param {string} request.appProfileId * This value specifies routing for replication. If not specified, the * "default" application profile will be used. * @param {Buffer} request.rowKey * Required. The key of the row to which the read/modify/write rules should be * applied. * @param {number[]} request.rules * Required. Rules specifying how the specified row's contents are to be * transformed into writes. Entries are applied in order, meaning that earlier * rules will affect the results of later ones. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Promise} - The promise which resolves to an array. * The first element of the array is an object representing {@link protos.google.bigtable.v2.ReadModifyWriteRowResponse|ReadModifyWriteRowResponse}. * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods | documentation } * for more details and examples. */ readModifyWriteRow(request?: protos.google.bigtable.v2.IReadModifyWriteRowRequest, options?: CallOptions): Promise<[ protos.google.bigtable.v2.IReadModifyWriteRowResponse, protos.google.bigtable.v2.IReadModifyWriteRowRequest | undefined, {} | undefined ]>; readModifyWriteRow(request: protos.google.bigtable.v2.IReadModifyWriteRowRequest, options: CallOptions, callback: Callback<protos.google.bigtable.v2.IReadModifyWriteRowResponse, protos.google.bigtable.v2.IReadModifyWriteRowRequest | null | undefined, {} | null | undefined>): void; readModifyWriteRow(request: protos.google.bigtable.v2.IReadModifyWriteRowRequest, callback: Callback<protos.google.bigtable.v2.IReadModifyWriteRowResponse, protos.google.bigtable.v2.IReadModifyWriteRowRequest | null | undefined, {} | null | undefined>): void; /** * Prepares a GoogleSQL query for execution on a particular Bigtable instance. * * @param {Object} request * The request object that will be sent. * @param {string} request.instanceName * Required. The unique name of the instance against which the query should be * executed. * Values are of the form `projects/<project>/instances/<instance>` * @param {string} [request.appProfileId] * Optional. This value specifies routing for preparing the query. Note that * this `app_profile_id` is only used for preparing the query. The actual * query execution will use the app profile specified in the * `ExecuteQueryRequest`. If not specified, the `default` application profile * will be used. * @param {string} request.query * Required. The query string. * @param {google.bigtable.v2.ProtoFormat} request.protoFormat * Protocol buffer format as described by ProtoSchema and ProtoRows * messages. * @param {number[]} request.paramTypes * Required. `param_types` is a map of parameter identifier strings to their * `Type`s. * * In query string, a parameter placeholder consists of the * `@` character followed by the parameter name (for example, `@firstName`) in * the query string. * * For example, if param_types["firstName"] = Bytes then @firstName will be a * query parameter of type Bytes. The specific `Value` to be used for the * query execution must be sent in `ExecuteQueryRequest` in the `params` map. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Promise} - The promise which resolves to an array. * The first element of the array is an object representing {@link protos.google.bigtable.v2.PrepareQueryResponse|PrepareQueryResponse}. * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods | documentation } * for more details and examples. */ prepareQuery(request?: protos.google.bigtable.v2.IPrepareQueryRequest, options?: CallOptions): Promise<[ protos.google.bigtable.v2.IPrepareQueryResponse, protos.google.bigtable.v2.IPrepareQueryRequest | undefined, {} | undefined ]>; prepareQuery(request: protos.google.bigtable.v2.IPrepareQueryRequest, options: CallOptions, callback: Callback<protos.google.bigtable.v2.IPrepareQueryResponse, protos.google.bigtable.v2.IPrepareQueryRequest | null | undefined, {} | null | undefined>): void; prepareQuery(request: protos.google.bigtable.v2.IPrepareQueryRequest, callback: Callback<protos.google.bigtable.v2.IPrepareQueryResponse, protos.google.bigtable.v2.IPrepareQueryRequest | null | undefined, {} | null | undefined>): void; /** * Streams back the contents of all requested rows in key order, optionally * applying the same Reader filter to each. Depending on their size, * rows and cells may be broken up across multiple responses, but * atomicity of each row will still be preserved. See the * ReadRowsResponse documentation for details. * * @param {Object} request * The request object that will be sent. * @param {string} [request.tableName] * Optional. The unique name of the table from which to read. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>`. * @param {string} [request.authorizedViewName] * Optional. The unique name of the AuthorizedView from which to read. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>/authorizedViews/<authorized_view>`. * @param {string} [request.materializedViewName] * Optional. The unique name of the MaterializedView from which to read. * * Values are of the form * `projects/<project>/instances/<instance>/materializedViews/<materialized_view>`. * @param {string} request.appProfileId * This value specifies routing for replication. If not specified, the * "default" application profile will be used. * @param {google.bigtable.v2.RowSet} request.rows * The row keys and/or ranges to read sequentially. If not specified, reads * from all rows. * @param {google.bigtable.v2.RowFilter} request.filter * The filter to apply to the contents of the specified row(s). If unset, * reads the entirety of each row. * @param {number} request.rowsLimit * The read will stop after committing to N rows' worth of results. The * default (zero) is to return all results. * @param {google.bigtable.v2.ReadRowsRequest.RequestStatsView} request.requestStatsView * The view into RequestStats, as described above. * @param {boolean} request.reversed * Experimental API - Please note that this API is currently experimental * and can change in the future. * * Return rows in lexiographical descending order of the row keys. The row * contents will not be affected by this flag. * * Example result set: * * [ * {key: "k2", "f:col1": "v1", "f:col2": "v1"}, * {key: "k1", "f:col1": "v2", "f:col2": "v2"} * ] * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Stream} * An object stream which emits {@link protos.google.bigtable.v2.ReadRowsResponse|ReadRowsResponse} on 'data' event. * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#server-streaming | documentation } * for more details and examples. */ readRows(request?: protos.google.bigtable.v2.IReadRowsRequest, options?: CallOptions): gax.CancellableStream; /** * Returns a sample of row keys in the table. The returned row keys will * delimit contiguous sections of the table of approximately equal size, * which can be used to break up the data for distributed tasks like * mapreduces. * * @param {Object} request * The request object that will be sent. * @param {string} [request.tableName] * Optional. The unique name of the table from which to sample row keys. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>`. * @param {string} [request.authorizedViewName] * Optional. The unique name of the AuthorizedView from which to sample row * keys. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>/authorizedViews/<authorized_view>`. * @param {string} [request.materializedViewName] * Optional. The unique name of the MaterializedView from which to read. * * Values are of the form * `projects/<project>/instances/<instance>/materializedViews/<materialized_view>`. * @param {string} request.appProfileId * This value specifies routing for replication. If not specified, the * "default" application profile will be used. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Stream} * An object stream which emits {@link protos.google.bigtable.v2.SampleRowKeysResponse|SampleRowKeysResponse} on 'data' event. * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#server-streaming | documentation } * for more details and examples. */ sampleRowKeys(request?: protos.google.bigtable.v2.ISampleRowKeysRequest, options?: CallOptions): gax.CancellableStream; /** * Mutates multiple rows in a batch. Each individual row is mutated * atomically as in MutateRow, but the entire batch is not executed * atomically. * * @param {Object} request * The request object that will be sent. * @param {string} [request.tableName] * Optional. The unique name of the table to which the mutations should be * applied. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>`. * @param {string} [request.authorizedViewName] * Optional. The unique name of the AuthorizedView to which the mutations * should be applied. * * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>/authorizedViews/<authorized_view>`. * @param {string} request.appProfileId * This value specifies routing for replication. If not specified, the * "default" application profile will be used. * @param {number[]} request.entries * Required. The row keys and corresponding mutations to be applied in bulk. * Each entry is applied as an atomic mutation, but the entries may be * applied in arbitrary order (even between entries for the same row). * At least one entry must be specified, and in total the entries can * contain at most 100000 mutations. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Stream} * An object stream which emits {@link protos.google.bigtable.v2.MutateRowsResponse|MutateRowsResponse} on 'data' event. * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#server-streaming | documentation } * for more details and examples. */ mutateRows(request?: protos.google.bigtable.v2.IMutateRowsRequest, options?: CallOptions): gax.CancellableStream; /** * NOTE: This API is intended to be used by Apache Beam BigtableIO. * Returns the current list of partitions that make up the table's * change stream. The union of partitions will cover the entire keyspace. * Partitions can be read with `ReadChangeStream`. * * @param {Object} request * The request object that will be sent. * @param {string} request.tableName * Required. The unique name of the table from which to get change stream * partitions. Values are of the form * `projects/<project>/instances/<instance>/tables/<table>`. * Change streaming must be enabled on the table. * @param {string} request.appProfileId * This value specifies routing for replication. If not specified, the * "default" application profile will be used. * Single cluster routing must be configured on the profile. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Stream} * An object stream which emits {@link protos.google.bigtable.v2.GenerateInitialChangeStreamPartitionsResponse|GenerateInitialChangeStreamPartitionsResponse} on 'data' event. * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#server-streaming | documentation } * for more details and examples. */ generateInitialChangeStreamPartitions(request?: protos.google.bigtable.v2.IGenerateInitialChangeStreamPartitionsRequest, options?: CallOptions): gax.CancellableStream; /** * NOTE: This API is intended to be used by Apache Beam BigtableIO. * Reads changes from a table's change stream. Changes will * reflect both user-initiated mutations and mutations that are caused by * garbage collection. * * @param {Object} request * The request object that will be sent. * @param {string} request.tableName * Required. The unique name of the table from which to read a change stream. * Values are of the form * `projects/<project>/instances/<instance>/tables/<table>`. * Change streaming must be enabled on the table. * @param {string} request.appProfileId * This value specifies routing for replication. If not specified, the * "default" application profile will be used. * Single cluster routing must be configured on the profile. * @param {google.bigtable.v2.StreamPartition} request.partition * The partition to read changes from. * @param {google.protobuf.Timestamp} request.startTime * Start reading the stream at the specified timestamp. This timestamp must * be within the change stream retention period, less than or equal to the * current time, and after change stream creation, whichever is greater. * This value is inclusive and will be truncated to microsecond granularity. * @param {google.bigtable.v2.StreamContinuationTokens} request.continuationTokens * Tokens that describe how to resume reading a stream where reading * previously left off. If specified, changes will be read starting at the * the position. Tokens are delivered on the stream as part of `Heartbeat` * and `CloseStream` messages. * * If a single token is provided, the token’s partition must exactly match * the request’s partition. If multiple tokens are provided, as in the case * of a partition merge, the union of the token partitions must exactly * cover the request’s partition. Otherwise, INVALID_ARGUMENT will be * returned. * @param {google.protobuf.Timestamp} request.endTime * If specified, OK will be returned when the stream advances beyond * this time. Otherwise, changes will be continuously delivered on the stream. * This value is inclusive and will be truncated to microsecond granularity. * @param {google.protobuf.Duration} request.heartbeatDuration * If specified, the duration between `Heartbeat` messages on the stream. * Otherwise, defaults to 5 seconds. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Stream} * An object stream which emits {@link protos.google.bigtable.v2.ReadChangeStreamResponse|ReadChangeStreamResponse} on 'data' event. * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#server-streaming | documentation } * for more details and examples. */ readChangeStream(request?: protos.google.bigtable.v2.IReadChangeStreamRequest, options?: CallOptions): gax.CancellableStream; /** * Executes a SQL query against a particular Bigtable instance. * * @param {Object} request * The request object that will be sent. * @param {string} request.instanceName * Required. The unique name of the instance against which the query should be * executed. * Values are of the form `projects/<project>/instances/<instance>` * @param {string} [request.appProfileId] * Optional. This value specifies routing for replication. If not specified, * the `default` application profile will be used. * @param {string} request.query * Required. The query string. * * Exactly one of `query` and `prepared_query` is required. Setting both * or neither is an `INVALID_ARGUMENT`. * @param {Buffer} request.preparedQuery * A prepared query that was returned from `PrepareQueryResponse`. * * Exactly one of `query` and `prepared_query` is required. Setting both * or neither is an `INVALID_ARGUMENT`. * * Setting this field also places restrictions on several other fields: * - `data_format` must be empty. * - `validate_only` must be false. * - `params` must match the `param_types` set in the `PrepareQueryRequest`. * @param {google.bigtable.v2.ProtoFormat} request.protoFormat * Protocol buffer format as described by ProtoSchema and ProtoRows * messages. * @param {Buffer} [request.resumeToken] * Optional. If this request is resuming a previously interrupted query * execution, `resume_token` should be copied from the last * PartialResultSet yielded before the interruption. Doing this * enables the query execution to resume where the last one left * off. * The rest of the request parameters must exactly match the * request that yielded this token. Otherwise the request will fail. * @param {number[]} request.params * Required. params contains string type keys and Bigtable type values that * bind to placeholders in the query string. In query string, a parameter * placeholder consists of the * `@` character followed by the parameter name (for example, `@firstName`) in * the query string. * * For example, if * `params["firstName"] = bytes_value: "foo" type {bytes_type {}}` * then `@firstName` will be replaced with googlesql bytes value "foo" in the * query string during query evaluation. * * If `Value.kind` is not set, the value is treated as a NULL value of the * given type. For example, if * `params["firstName"] = type {string_type {}}` * then `@firstName` will be replaced with googlesql null string. * * If `query` is set, any empty `Value.type` in the map will be rejected with * `INVALID_ARGUMENT`. * * If `prepared_query` is set, any empty `Value.type` in the map will be * inferred from the `param_types` in the `PrepareQueryRequest`. Any non-empty * `Value.type` must match the corresponding `param_types` entry, or be * rejected with `INVALID_ARGUMENT`. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Stream} * An object stream which emits {@link protos.google.bigtable.v2.ExecuteQueryResponse|ExecuteQueryResponse} on 'data' event. * Please see the {@link https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#server-streaming | documentation } * for more details and examples. */ executeQuery(request?: protos.google.bigtable.v2.IExecuteQueryRequest, options?: CallOptions): gax.CancellableStream; /** * Return a fully-qualified authorizedView resource name string. * * @param {string} project * @param {string} instance * @param {string} table * @param {string} authorized_view * @returns {string} Resource name string. */ authorizedViewPath(project: string, instance: string, table: string, authorizedView: string): string; /** * Parse the project from AuthorizedView resource. * * @param {string} authorizedViewName * A fully-qualified path representing AuthorizedView resource. * @returns {string} A string representing the project. */ matchProjectFromAuthorizedViewName(authorizedViewName: string): string | number; /** * Parse the instance from AuthorizedView resource. * * @param {string} authorizedViewName * A fully-qualified path representing AuthorizedView resource. * @returns {string} A string representing the instance. */ matchInstanceFromAuthorizedViewName(authorizedViewName: string): string | number; /** * Parse the table from AuthorizedView resource. * * @param {string} authorizedViewName * A fully-qualified path representing AuthorizedView resource. * @returns {string} A string representing the table. */ matchTableFromAuthorizedViewName(authorizedViewName: string): string | number; /** * Parse the authorized_view from AuthorizedView resource. * * @param {string} authorizedViewName * A fully-qualified path representing AuthorizedView resource. * @returns {string} A string representing the authorized_view. */ matchAuthorizedViewFromAuthorizedViewName(authorizedViewName: string): string | number; /** * Return a fully-qualified instance resource name string. * * @param {string} project * @param {string} instance * @returns {string} Resource name string. */ instancePath(project: string, instance: string): string; /** * Parse the project from Instance resource. * * @param {string} instanceName * A fully-qualified path representing Instance resource. * @returns {string} A string representing the project. */ matchProjectFromInstanceName(instanceName: string): string | number; /** * Parse the instance from Instance resource. * * @param {string} instanceName * A fully-qualified path representing Instance resource. * @returns {string} A string representing the instance. */ matchInstanceFromInstanceName(instanceName: string): string | number; /** * Return a fully-qualified materializedView resource name string. * * @param {string} project * @param {string} instance * @param {string} materialized_view * @returns {string} Resource name string. */ materializedViewPath(project: string, instance: string, materializedView: string): string; /** * Parse the project from MaterializedView resource. * * @param {string} materializedViewName * A fully-qualified path representing MaterializedView resource. * @returns {string} A string representing the project. */ matchProjectFromMaterializedViewName(materializedViewName: string): string | number; /** * Parse the instance from MaterializedView resource. * * @param {string} materializedViewName * A fully-qualified path representing MaterializedView resource. * @returns {string} A string representing the instance. */ matchInstanceFromMaterializedViewName(materializedViewName: string): string | number; /** * Parse the materialized_view from MaterializedView resource. * * @param {string} materializedViewName * A fully-qualified path representing MaterializedView resource. * @returns {string} A string representing the materialized_view. */ matchMaterializedViewFromMaterializedViewName(materializedViewName: string): string | number; /** * Return a fully-qualified table resource name string. * * @param {string} project * @param {string} instance * @param {string} table * @returns {string} Resource name string. */ tablePath(project: string, instance: string, table: string): string; /** * Parse the project from Table resource. * * @param {string} tableName * A fully-qualified path representing Table resource. * @returns {string} A string representing the project. */ matchProjectFromTableName(tableName: string): string | number; /** * Parse the instance from Table resource. * * @param {string} tableName * A fully-qualified path representing Table resource. * @returns {string} A string representing the instance. */ matchInstanceFromTableName(tableName: string): string | number; /** * Parse the table from Table resource. * * @param {string} tableName * A fully-qualified path representing Table resource. * @returns {string} A string representing the table. */ matchTableFromTableName(tableName: string): string | number; /** * Terminate the gRPC channel and close the client. * * The client will no longer be usable and all future behavior is undefined. * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise<void>; }