Class v2.BigtableInstanceAdminClient (6.0.0)

Service for creating, configuring, and deleting Cloud Bigtable Instances and Clusters. Provides access to the Instance and Cluster schemas only, not the tables' metadata or data stored in those tables. v2

Package

@google-cloud/bigtable

Constructors

(constructor)(opts, gaxInstance)

constructor(opts?: ClientOptions, gaxInstance?: typeof gax | typeof gax.fallback);

Construct an instance of BigtableInstanceAdminClient.

Parameters
Name Description
opts ClientOptions
gaxInstance typeof gax | typeof fallback

: 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 BigtableInstanceAdminClient({fallback: true}, gax); ```

Properties

apiEndpoint

get apiEndpoint(): string;

The DNS address for this API service.

apiEndpoint

static get apiEndpoint(): string;

The DNS address for this API service - same as servicePath.

auth

auth: gax.GoogleAuth;

bigtableInstanceAdminStub

bigtableInstanceAdminStub?: Promise<{
        [name: string]: Function;
    }>;

descriptors

descriptors: Descriptors;

innerApiCalls

innerApiCalls: {
        [name: string]: Function;
    };

operationsClient

operationsClient: gax.OperationsClient;

pathTemplates

pathTemplates: {
        [name: string]: gax.PathTemplate;
    };

port

static get port(): number;

The port for this API service.

scopes

static get scopes(): string[];

The scopes needed to make gRPC calls for every method defined in this service.

servicePath

static get servicePath(): string;

The DNS address for this API service.

universeDomain

get universeDomain(): string;

warn

warn: (code: string, message: string, warnType?: string) => void;

Methods

appProfilePath(project, instance, appProfile)

appProfilePath(project: string, instance: string, appProfile: string): string;

Return a fully-qualified appProfile resource name string.

Parameters
Name Description
project string
instance string
appProfile string
Returns
Type Description
string

{string} Resource name string.

authorizedViewPath(project, instance, table, authorizedView)

authorizedViewPath(project: string, instance: string, table: string, authorizedView: string): string;

Return a fully-qualified authorizedView resource name string.

Parameters
Name Description
project string
instance string
table string
authorizedView string
Returns
Type Description
string

{string} Resource name string.

backupPath(project, instance, cluster, backup)

backupPath(project: string, instance: string, cluster: string, backup: string): string;

Return a fully-qualified backup resource name string.

Parameters
Name Description
project string
instance string
cluster string
backup string
Returns
Type Description
string

{string} Resource name string.

checkCreateClusterProgress(name)

checkCreateClusterProgress(name: string): Promise<LROperation<protos.google.bigtable.admin.v2.Cluster, protos.google.bigtable.admin.v2.CreateClusterMetadata>>;

Check the status of the long running operation returned by createCluster().

Parameter
Name Description
name string

The operation name that will be passed.

Returns
Type Description
Promise<LROperation<protos.google.bigtable.admin.v2.Cluster, protos.google.bigtable.admin.v2.CreateClusterMetadata>>

{Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the instance in which to create the new
   *  cluster. Values are of the form `projects/{project}/instances/{instance}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The ID to be used when referring to the new cluster within its
   *  instance, e.g., just `mycluster` rather than
   *  `projects/myproject/instances/myinstance/clusters/mycluster`.
   */
  // const clusterId = 'abc123'
  /**
   *  Required. The cluster to be created.
   *  Fields marked `OutputOnly` must be left blank.
   */
  // const cluster = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callCreateCluster() {
    // Construct request
    const request = {
      parent,
      clusterId,
      cluster,
    };

    // Run request
    const [operation] = await adminClient.createCluster(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callCreateCluster();

checkCreateInstanceProgress(name)

checkCreateInstanceProgress(name: string): Promise<LROperation<protos.google.bigtable.admin.v2.Instance, protos.google.bigtable.admin.v2.CreateInstanceMetadata>>;

Check the status of the long running operation returned by createInstance().

Parameter
Name Description
name string

The operation name that will be passed.

Returns
Type Description
Promise<LROperation<protos.google.bigtable.admin.v2.Instance, protos.google.bigtable.admin.v2.CreateInstanceMetadata>>

{Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the project in which to create the new
   *  instance. Values are of the form `projects/{project}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The ID to be used when referring to the new instance within its
   *  project, e.g., just `myinstance` rather than
   *  `projects/myproject/instances/myinstance`.
   */
  // const instanceId = 'abc123'
  /**
   *  Required. The instance to create.
   *  Fields marked `OutputOnly` must be left blank.
   */
  // const instance = {}
  /**
   *  Required. The clusters to be created within the instance, mapped by desired
   *  cluster ID, e.g., just `mycluster` rather than
   *  `projects/myproject/instances/myinstance/clusters/mycluster`.
   *  Fields marked `OutputOnly` must be left blank.
   */
  // const clusters = [1,2,3,4]

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callCreateInstance() {
    // Construct request
    const request = {
      parent,
      instanceId,
      instance,
      clusters,
    };

    // Run request
    const [operation] = await adminClient.createInstance(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callCreateInstance();

checkCreateLogicalViewProgress(name)

checkCreateLogicalViewProgress(name: string): Promise<LROperation<protos.google.bigtable.admin.v2.LogicalView, protos.google.bigtable.admin.v2.CreateLogicalViewMetadata>>;

Check the status of the long running operation returned by createLogicalView().

Parameter
Name Description
name string

The operation name that will be passed.

Returns
Type Description
Promise<LROperation<protos.google.bigtable.admin.v2.LogicalView, protos.google.bigtable.admin.v2.CreateLogicalViewMetadata>>

{Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The parent instance where this logical view will be created.
   *  Format: `projects/{project}/instances/{instance}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The ID to use for the logical view, which will become the final
   *  component of the logical view's resource name.
   */
  // const logicalViewId = 'abc123'
  /**
   *  Required. The logical view to create.
   */
  // const logicalView = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callCreateLogicalView() {
    // Construct request
    const request = {
      parent,
      logicalViewId,
      logicalView,
    };

    // Run request
    const [operation] = await adminClient.createLogicalView(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callCreateLogicalView();

checkCreateMaterializedViewProgress(name)

checkCreateMaterializedViewProgress(name: string): Promise<LROperation<protos.google.bigtable.admin.v2.MaterializedView, protos.google.bigtable.admin.v2.CreateMaterializedViewMetadata>>;

Check the status of the long running operation returned by createMaterializedView().

Parameter
Name Description
name string

The operation name that will be passed.

Returns
Type Description
Promise<LROperation<protos.google.bigtable.admin.v2.MaterializedView, protos.google.bigtable.admin.v2.CreateMaterializedViewMetadata>>

{Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The parent instance where this materialized view will be created.
   *  Format: `projects/{project}/instances/{instance}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The ID to use for the materialized view, which will become the
   *  final component of the materialized view's resource name.
   */
  // const materializedViewId = 'abc123'
  /**
   *  Required. The materialized view to create.
   */
  // const materializedView = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callCreateMaterializedView() {
    // Construct request
    const request = {
      parent,
      materializedViewId,
      materializedView,
    };

    // Run request
    const [operation] = await adminClient.createMaterializedView(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callCreateMaterializedView();

checkPartialUpdateClusterProgress(name)

checkPartialUpdateClusterProgress(name: string): Promise<LROperation<protos.google.bigtable.admin.v2.Cluster, protos.google.bigtable.admin.v2.PartialUpdateClusterMetadata>>;

Check the status of the long running operation returned by partialUpdateCluster().

Parameter
Name Description
name string

The operation name that will be passed.

Returns
Type Description
Promise<LROperation<protos.google.bigtable.admin.v2.Cluster, protos.google.bigtable.admin.v2.PartialUpdateClusterMetadata>>

{Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The Cluster which contains the partial updates to be applied,
   *  subject to the update_mask.
   */
  // const cluster = {}
  /**
   *  Required. The subset of Cluster fields which should be replaced.
   */
  // const updateMask = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callPartialUpdateCluster() {
    // Construct request
    const request = {
      cluster,
      updateMask,
    };

    // Run request
    const [operation] = await adminClient.partialUpdateCluster(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callPartialUpdateCluster();

checkPartialUpdateInstanceProgress(name)

checkPartialUpdateInstanceProgress(name: string): Promise<LROperation<protos.google.bigtable.admin.v2.Instance, protos.google.bigtable.admin.v2.UpdateInstanceMetadata>>;

Check the status of the long running operation returned by partialUpdateInstance().

Parameter
Name Description
name string

The operation name that will be passed.

Returns
Type Description
Promise<LROperation<protos.google.bigtable.admin.v2.Instance, protos.google.bigtable.admin.v2.UpdateInstanceMetadata>>

{Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The Instance which will (partially) replace the current value.
   */
  // const instance = {}
  /**
   *  Required. The subset of Instance fields which should be replaced.
   *  Must be explicitly set.
   */
  // const updateMask = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callPartialUpdateInstance() {
    // Construct request
    const request = {
      instance,
      updateMask,
    };

    // Run request
    const [operation] = await adminClient.partialUpdateInstance(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callPartialUpdateInstance();

checkUpdateAppProfileProgress(name)

checkUpdateAppProfileProgress(name: string): Promise<LROperation<protos.google.bigtable.admin.v2.AppProfile, protos.google.bigtable.admin.v2.UpdateAppProfileMetadata>>;

Check the status of the long running operation returned by updateAppProfile().

Parameter
Name Description
name string

The operation name that will be passed.

Returns
Type Description
Promise<LROperation<protos.google.bigtable.admin.v2.AppProfile, protos.google.bigtable.admin.v2.UpdateAppProfileMetadata>>

{Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The app profile which will (partially) replace the current value.
   */
  // const appProfile = {}
  /**
   *  Required. The subset of app profile fields which should be replaced.
   *  If unset, all fields will be replaced.
   */
  // const updateMask = {}
  /**
   *  If true, ignore safety checks when updating the app profile.
   */
  // const ignoreWarnings = true

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callUpdateAppProfile() {
    // Construct request
    const request = {
      appProfile,
      updateMask,
    };

    // Run request
    const [operation] = await adminClient.updateAppProfile(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callUpdateAppProfile();

checkUpdateClusterProgress(name)

checkUpdateClusterProgress(name: string): Promise<LROperation<protos.google.bigtable.admin.v2.Cluster, protos.google.bigtable.admin.v2.UpdateClusterMetadata>>;

Check the status of the long running operation returned by updateCluster().

Parameter
Name Description
name string

The operation name that will be passed.

Returns
Type Description
Promise<LROperation<protos.google.bigtable.admin.v2.Cluster, protos.google.bigtable.admin.v2.UpdateClusterMetadata>>

{Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  The unique name of the cluster. Values are of the form
   *  `projects/{project}/instances/{instance}/clusters/[a-z][-a-z0-9]*`.
   */
  // const name = 'abc123'
  /**
   *  Immutable. The location where this cluster's nodes and storage reside. For
   *  best performance, clients should be located as close as possible to this
   *  cluster. Currently only zones are supported, so values should be of the
   *  form `projects/{project}/locations/{zone}`.
   */
  // const location = 'abc123'
  /**
   *  Output only. The current state of the cluster.
   */
  // const state = {}
  /**
   *  The number of nodes in the cluster. If no value is set,
   *  Cloud Bigtable automatically allocates nodes based on your data footprint
   *  and optimized for 50% storage utilization.
   */
  // const serveNodes = 1234
  /**
   *  Immutable. The node scaling factor of this cluster.
   */
  // const nodeScalingFactor = {}
  /**
   *  Configuration for this cluster.
   */
  // const clusterConfig = {}
  /**
   *  Immutable. The type of storage used by this cluster to serve its
   *  parent instance's tables, unless explicitly overridden.
   */
  // const defaultStorageType = {}
  /**
   *  Immutable. The encryption configuration for CMEK-protected clusters.
   */
  // const encryptionConfig = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callUpdateCluster() {
    // Construct request
    const request = {
      location,
      state,
      nodeScalingFactor,
      defaultStorageType,
      encryptionConfig,
    };

    // Run request
    const [operation] = await adminClient.updateCluster(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callUpdateCluster();

checkUpdateLogicalViewProgress(name)

checkUpdateLogicalViewProgress(name: string): Promise<LROperation<protos.google.bigtable.admin.v2.LogicalView, protos.google.bigtable.admin.v2.UpdateLogicalViewMetadata>>;

Check the status of the long running operation returned by updateLogicalView().

Parameter
Name Description
name string

The operation name that will be passed.

Returns
Type Description
Promise<LROperation<protos.google.bigtable.admin.v2.LogicalView, protos.google.bigtable.admin.v2.UpdateLogicalViewMetadata>>

{Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The logical view to update.
   *  The logical view's `name` field is used to identify the view to update.
   *  Format:
   *  `projects/{project}/instances/{instance}/logicalViews/{logical_view}`.
   */
  // const logicalView = {}
  /**
   *  Optional. The list of fields to update.
   */
  // const updateMask = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callUpdateLogicalView() {
    // Construct request
    const request = {
      logicalView,
    };

    // Run request
    const [operation] = await adminClient.updateLogicalView(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callUpdateLogicalView();

checkUpdateMaterializedViewProgress(name)

checkUpdateMaterializedViewProgress(name: string): Promise<LROperation<protos.google.bigtable.admin.v2.MaterializedView, protos.google.bigtable.admin.v2.UpdateMaterializedViewMetadata>>;

Check the status of the long running operation returned by updateMaterializedView().

Parameter
Name Description
name string

The operation name that will be passed.

Returns
Type Description
Promise<LROperation<protos.google.bigtable.admin.v2.MaterializedView, protos.google.bigtable.admin.v2.UpdateMaterializedViewMetadata>>

{Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The materialized view to update.
   *  The materialized view's `name` field is used to identify the view to
   *  update. Format:
   *  `projects/{project}/instances/{instance}/materializedViews/{materialized_view}`.
   */
  // const materializedView = {}
  /**
   *  Optional. The list of fields to update.
   */
  // const updateMask = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callUpdateMaterializedView() {
    // Construct request
    const request = {
      materializedView,
    };

    // Run request
    const [operation] = await adminClient.updateMaterializedView(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callUpdateMaterializedView();

close()

close(): Promise<void>;

Terminate the gRPC channel and close the client.

The client will no longer be usable and all future behavior is undefined.

Returns
Type Description
Promise<void>

{Promise} A promise that resolves when the client is closed.

clusterPath(project, instance, cluster)

clusterPath(project: string, instance: string, cluster: string): string;

Return a fully-qualified cluster resource name string.

Parameters
Name Description
project string
instance string
cluster string
Returns
Type Description
string

{string} Resource name string.

createAppProfile(request, options)

createAppProfile(request?: protos.google.bigtable.admin.v2.ICreateAppProfileRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.IAppProfile,
        protos.google.bigtable.admin.v2.ICreateAppProfileRequest | undefined,
        {} | undefined
    ]>;

Creates an app profile within an instance.

Parameters
Name Description
request ICreateAppProfileRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.ICreateAppProfileRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the instance in which to create the new app
   *  profile. Values are of the form `projects/{project}/instances/{instance}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The ID to be used when referring to the new app profile within
   *  its instance, e.g., just `myprofile` rather than
   *  `projects/myproject/instances/myinstance/appProfiles/myprofile`.
   */
  // const appProfileId = 'abc123'
  /**
   *  Required. The app profile to be created.
   *  Fields marked `OutputOnly` will be ignored.
   */
  // const appProfile = {}
  /**
   *  If true, ignore safety checks when creating the app profile.
   */
  // const ignoreWarnings = true

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callCreateAppProfile() {
    // Construct request
    const request = {
      parent,
      appProfileId,
      appProfile,
    };

    // Run request
    const response = await adminClient.createAppProfile(request);
    console.log(response);
  }

  callCreateAppProfile();

createAppProfile(request, options, callback)

createAppProfile(request: protos.google.bigtable.admin.v2.ICreateAppProfileRequest, options: CallOptions, callback: Callback<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.ICreateAppProfileRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICreateAppProfileRequest
options CallOptions
callback Callback<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.ICreateAppProfileRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

createAppProfile(request, callback)

createAppProfile(request: protos.google.bigtable.admin.v2.ICreateAppProfileRequest, callback: Callback<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.ICreateAppProfileRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICreateAppProfileRequest
callback Callback<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.ICreateAppProfileRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

createCluster(request, options)

createCluster(request?: protos.google.bigtable.admin.v2.ICreateClusterRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.ICreateClusterMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Creates a cluster within an instance.

Note that exactly one of Cluster.serve_nodes and Cluster.cluster_config.cluster_autoscaling_config can be set. If serve_nodes is set to non-zero, then the cluster is manually scaled. If cluster_config.cluster_autoscaling_config is non-empty, then autoscaling is enabled.

Parameters
Name Description
request ICreateClusterRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.ICreateClusterMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the instance in which to create the new
   *  cluster. Values are of the form `projects/{project}/instances/{instance}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The ID to be used when referring to the new cluster within its
   *  instance, e.g., just `mycluster` rather than
   *  `projects/myproject/instances/myinstance/clusters/mycluster`.
   */
  // const clusterId = 'abc123'
  /**
   *  Required. The cluster to be created.
   *  Fields marked `OutputOnly` must be left blank.
   */
  // const cluster = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callCreateCluster() {
    // Construct request
    const request = {
      parent,
      clusterId,
      cluster,
    };

    // Run request
    const [operation] = await adminClient.createCluster(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callCreateCluster();

createCluster(request, options, callback)

createCluster(request: protos.google.bigtable.admin.v2.ICreateClusterRequest, options: CallOptions, callback: Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.ICreateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICreateClusterRequest
options CallOptions
callback Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.ICreateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

createCluster(request, callback)

createCluster(request: protos.google.bigtable.admin.v2.ICreateClusterRequest, callback: Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.ICreateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICreateClusterRequest
callback Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.ICreateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

createInstance(request, options)

createInstance(request?: protos.google.bigtable.admin.v2.ICreateInstanceRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.ICreateInstanceMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Create an instance within a project.

Note that exactly one of Cluster.serve_nodes and Cluster.cluster_config.cluster_autoscaling_config can be set. If serve_nodes is set to non-zero, then the cluster is manually scaled. If cluster_config.cluster_autoscaling_config is non-empty, then autoscaling is enabled.

Parameters
Name Description
request ICreateInstanceRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.ICreateInstanceMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the project in which to create the new
   *  instance. Values are of the form `projects/{project}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The ID to be used when referring to the new instance within its
   *  project, e.g., just `myinstance` rather than
   *  `projects/myproject/instances/myinstance`.
   */
  // const instanceId = 'abc123'
  /**
   *  Required. The instance to create.
   *  Fields marked `OutputOnly` must be left blank.
   */
  // const instance = {}
  /**
   *  Required. The clusters to be created within the instance, mapped by desired
   *  cluster ID, e.g., just `mycluster` rather than
   *  `projects/myproject/instances/myinstance/clusters/mycluster`.
   *  Fields marked `OutputOnly` must be left blank.
   */
  // const clusters = [1,2,3,4]

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callCreateInstance() {
    // Construct request
    const request = {
      parent,
      instanceId,
      instance,
      clusters,
    };

    // Run request
    const [operation] = await adminClient.createInstance(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callCreateInstance();

createInstance(request, options, callback)

createInstance(request: protos.google.bigtable.admin.v2.ICreateInstanceRequest, options: CallOptions, callback: Callback<LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.ICreateInstanceMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICreateInstanceRequest
options CallOptions
callback Callback<LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.ICreateInstanceMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

createInstance(request, callback)

createInstance(request: protos.google.bigtable.admin.v2.ICreateInstanceRequest, callback: Callback<LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.ICreateInstanceMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICreateInstanceRequest
callback Callback<LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.ICreateInstanceMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

createLogicalView(request, options)

createLogicalView(request?: protos.google.bigtable.admin.v2.ICreateLogicalViewRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.ICreateLogicalViewMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Creates a logical view within an instance.

Parameters
Name Description
request ICreateLogicalViewRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.ICreateLogicalViewMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The parent instance where this logical view will be created.
   *  Format: `projects/{project}/instances/{instance}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The ID to use for the logical view, which will become the final
   *  component of the logical view's resource name.
   */
  // const logicalViewId = 'abc123'
  /**
   *  Required. The logical view to create.
   */
  // const logicalView = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callCreateLogicalView() {
    // Construct request
    const request = {
      parent,
      logicalViewId,
      logicalView,
    };

    // Run request
    const [operation] = await adminClient.createLogicalView(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callCreateLogicalView();

createLogicalView(request, options, callback)

createLogicalView(request: protos.google.bigtable.admin.v2.ICreateLogicalViewRequest, options: CallOptions, callback: Callback<LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.ICreateLogicalViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICreateLogicalViewRequest
options CallOptions
callback Callback<LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.ICreateLogicalViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

createLogicalView(request, callback)

createLogicalView(request: protos.google.bigtable.admin.v2.ICreateLogicalViewRequest, callback: Callback<LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.ICreateLogicalViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICreateLogicalViewRequest
callback Callback<LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.ICreateLogicalViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

createMaterializedView(request, options)

createMaterializedView(request?: protos.google.bigtable.admin.v2.ICreateMaterializedViewRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.ICreateMaterializedViewMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Creates a materialized view within an instance.

Parameters
Name Description
request ICreateMaterializedViewRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.ICreateMaterializedViewMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The parent instance where this materialized view will be created.
   *  Format: `projects/{project}/instances/{instance}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The ID to use for the materialized view, which will become the
   *  final component of the materialized view's resource name.
   */
  // const materializedViewId = 'abc123'
  /**
   *  Required. The materialized view to create.
   */
  // const materializedView = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callCreateMaterializedView() {
    // Construct request
    const request = {
      parent,
      materializedViewId,
      materializedView,
    };

    // Run request
    const [operation] = await adminClient.createMaterializedView(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callCreateMaterializedView();

createMaterializedView(request, options, callback)

createMaterializedView(request: protos.google.bigtable.admin.v2.ICreateMaterializedViewRequest, options: CallOptions, callback: Callback<LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.ICreateMaterializedViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICreateMaterializedViewRequest
options CallOptions
callback Callback<LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.ICreateMaterializedViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

createMaterializedView(request, callback)

createMaterializedView(request: protos.google.bigtable.admin.v2.ICreateMaterializedViewRequest, callback: Callback<LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.ICreateMaterializedViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICreateMaterializedViewRequest
callback Callback<LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.ICreateMaterializedViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

deleteAppProfile(request, options)

deleteAppProfile(request?: protos.google.bigtable.admin.v2.IDeleteAppProfileRequest, options?: CallOptions): Promise<[
        protos.google.protobuf.IEmpty,
        protos.google.bigtable.admin.v2.IDeleteAppProfileRequest | undefined,
        {} | undefined
    ]>;

Deletes an app profile from an instance.

Parameters
Name Description
request IDeleteAppProfileRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteAppProfileRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing Empty. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the app profile to be deleted. Values are of
   *  the form
   *  `projects/{project}/instances/{instance}/appProfiles/{app_profile}`.
   */
  // const name = 'abc123'
  /**
   *  Required. If true, ignore safety checks when deleting the app profile.
   */
  // const ignoreWarnings = true

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callDeleteAppProfile() {
    // Construct request
    const request = {
      name,
      ignoreWarnings,
    };

    // Run request
    const response = await adminClient.deleteAppProfile(request);
    console.log(response);
  }

  callDeleteAppProfile();

deleteAppProfile(request, options, callback)

deleteAppProfile(request: protos.google.bigtable.admin.v2.IDeleteAppProfileRequest, options: CallOptions, callback: Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteAppProfileRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IDeleteAppProfileRequest
options CallOptions
callback Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteAppProfileRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

deleteAppProfile(request, callback)

deleteAppProfile(request: protos.google.bigtable.admin.v2.IDeleteAppProfileRequest, callback: Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteAppProfileRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IDeleteAppProfileRequest
callback Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteAppProfileRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

deleteCluster(request, options)

deleteCluster(request?: protos.google.bigtable.admin.v2.IDeleteClusterRequest, options?: CallOptions): Promise<[
        protos.google.protobuf.IEmpty,
        protos.google.bigtable.admin.v2.IDeleteClusterRequest | undefined,
        {} | undefined
    ]>;

Deletes a cluster from an instance.

Parameters
Name Description
request IDeleteClusterRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteClusterRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing Empty. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the cluster to be deleted. Values are of the
   *  form `projects/{project}/instances/{instance}/clusters/{cluster}`.
   */
  // const name = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callDeleteCluster() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const response = await adminClient.deleteCluster(request);
    console.log(response);
  }

  callDeleteCluster();

deleteCluster(request, options, callback)

deleteCluster(request: protos.google.bigtable.admin.v2.IDeleteClusterRequest, options: CallOptions, callback: Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteClusterRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IDeleteClusterRequest
options CallOptions
callback Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteClusterRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

deleteCluster(request, callback)

deleteCluster(request: protos.google.bigtable.admin.v2.IDeleteClusterRequest, callback: Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteClusterRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IDeleteClusterRequest
callback Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteClusterRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

deleteInstance(request, options)

deleteInstance(request?: protos.google.bigtable.admin.v2.IDeleteInstanceRequest, options?: CallOptions): Promise<[
        protos.google.protobuf.IEmpty,
        protos.google.bigtable.admin.v2.IDeleteInstanceRequest | undefined,
        {} | undefined
    ]>;

Delete an instance from a project.

Parameters
Name Description
request IDeleteInstanceRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteInstanceRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing Empty. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the instance to be deleted.
   *  Values are of the form `projects/{project}/instances/{instance}`.
   */
  // const name = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callDeleteInstance() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const response = await adminClient.deleteInstance(request);
    console.log(response);
  }

  callDeleteInstance();

deleteInstance(request, options, callback)

deleteInstance(request: protos.google.bigtable.admin.v2.IDeleteInstanceRequest, options: CallOptions, callback: Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteInstanceRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IDeleteInstanceRequest
options CallOptions
callback Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteInstanceRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

deleteInstance(request, callback)

deleteInstance(request: protos.google.bigtable.admin.v2.IDeleteInstanceRequest, callback: Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteInstanceRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IDeleteInstanceRequest
callback Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteInstanceRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

deleteLogicalView(request, options)

deleteLogicalView(request?: protos.google.bigtable.admin.v2.IDeleteLogicalViewRequest, options?: CallOptions): Promise<[
        protos.google.protobuf.IEmpty,
        protos.google.bigtable.admin.v2.IDeleteLogicalViewRequest | undefined,
        {} | undefined
    ]>;

Deletes a logical view from an instance.

Parameters
Name Description
request IDeleteLogicalViewRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteLogicalViewRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing Empty. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the logical view to be deleted.
   *  Format:
   *  `projects/{project}/instances/{instance}/logicalViews/{logical_view}`.
   */
  // const name = 'abc123'
  /**
   *  Optional. The current etag of the logical view.
   *  If an etag is provided and does not match the current etag of the
   *  logical view, deletion will be blocked and an ABORTED error will be
   *  returned.
   */
  // const etag = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callDeleteLogicalView() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const response = await adminClient.deleteLogicalView(request);
    console.log(response);
  }

  callDeleteLogicalView();

deleteLogicalView(request, options, callback)

deleteLogicalView(request: protos.google.bigtable.admin.v2.IDeleteLogicalViewRequest, options: CallOptions, callback: Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteLogicalViewRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IDeleteLogicalViewRequest
options CallOptions
callback Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteLogicalViewRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

deleteLogicalView(request, callback)

deleteLogicalView(request: protos.google.bigtable.admin.v2.IDeleteLogicalViewRequest, callback: Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteLogicalViewRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IDeleteLogicalViewRequest
callback Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteLogicalViewRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

deleteMaterializedView(request, options)

deleteMaterializedView(request?: protos.google.bigtable.admin.v2.IDeleteMaterializedViewRequest, options?: CallOptions): Promise<[
        protos.google.protobuf.IEmpty,
        (protos.google.bigtable.admin.v2.IDeleteMaterializedViewRequest | undefined),
        {} | undefined
    ]>;

Deletes a materialized view from an instance.

Parameters
Name Description
request IDeleteMaterializedViewRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.protobuf.IEmpty, (protos.google.bigtable.admin.v2.IDeleteMaterializedViewRequest | undefined), {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing Empty. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the materialized view to be deleted.
   *  Format:
   *  `projects/{project}/instances/{instance}/materializedViews/{materialized_view}`.
   */
  // const name = 'abc123'
  /**
   *  Optional. The current etag of the materialized view.
   *  If an etag is provided and does not match the current etag of the
   *  materialized view, deletion will be blocked and an ABORTED error will be
   *  returned.
   */
  // const etag = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callDeleteMaterializedView() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const response = await adminClient.deleteMaterializedView(request);
    console.log(response);
  }

  callDeleteMaterializedView();

deleteMaterializedView(request, options, callback)

deleteMaterializedView(request: protos.google.bigtable.admin.v2.IDeleteMaterializedViewRequest, options: CallOptions, callback: Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteMaterializedViewRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IDeleteMaterializedViewRequest
options CallOptions
callback Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteMaterializedViewRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

deleteMaterializedView(request, callback)

deleteMaterializedView(request: protos.google.bigtable.admin.v2.IDeleteMaterializedViewRequest, callback: Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteMaterializedViewRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IDeleteMaterializedViewRequest
callback Callback<protos.google.protobuf.IEmpty, protos.google.bigtable.admin.v2.IDeleteMaterializedViewRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getAppProfile(request, options)

getAppProfile(request?: protos.google.bigtable.admin.v2.IGetAppProfileRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.IAppProfile,
        protos.google.bigtable.admin.v2.IGetAppProfileRequest | undefined,
        {} | undefined
    ]>;

Gets information about an app profile.

Parameters
Name Description
request IGetAppProfileRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.IGetAppProfileRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the requested app profile. Values are of the
   *  form `projects/{project}/instances/{instance}/appProfiles/{app_profile}`.
   */
  // const name = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callGetAppProfile() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const response = await adminClient.getAppProfile(request);
    console.log(response);
  }

  callGetAppProfile();

getAppProfile(request, options, callback)

getAppProfile(request: protos.google.bigtable.admin.v2.IGetAppProfileRequest, options: CallOptions, callback: Callback<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.IGetAppProfileRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetAppProfileRequest
options CallOptions
callback Callback<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.IGetAppProfileRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getAppProfile(request, callback)

getAppProfile(request: protos.google.bigtable.admin.v2.IGetAppProfileRequest, callback: Callback<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.IGetAppProfileRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetAppProfileRequest
callback Callback<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.IGetAppProfileRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getCluster(request, options)

getCluster(request?: protos.google.bigtable.admin.v2.IGetClusterRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.ICluster,
        protos.google.bigtable.admin.v2.IGetClusterRequest | undefined,
        {} | undefined
    ]>;

Gets information about a cluster.

Parameters
Name Description
request IGetClusterRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IGetClusterRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the requested cluster. Values are of the form
   *  `projects/{project}/instances/{instance}/clusters/{cluster}`.
   */
  // const name = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callGetCluster() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const response = await adminClient.getCluster(request);
    console.log(response);
  }

  callGetCluster();

getCluster(request, options, callback)

getCluster(request: protos.google.bigtable.admin.v2.IGetClusterRequest, options: CallOptions, callback: Callback<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IGetClusterRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetClusterRequest
options CallOptions
callback Callback<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IGetClusterRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getCluster(request, callback)

getCluster(request: protos.google.bigtable.admin.v2.IGetClusterRequest, callback: Callback<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IGetClusterRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetClusterRequest
callback Callback<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IGetClusterRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getIamPolicy(request, options)

getIamPolicy(request?: protos.google.iam.v1.IGetIamPolicyRequest, options?: CallOptions): Promise<[
        protos.google.iam.v1.IPolicy,
        protos.google.iam.v1.IGetIamPolicyRequest | undefined,
        {} | undefined
    ]>;

Gets the access control policy for an instance resource. Returns an empty policy if an instance exists but does not have a policy set.

Parameters
Name Description
request IGetIamPolicyRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.iam.v1.IPolicy, protos.google.iam.v1.IGetIamPolicyRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing Policy. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  REQUIRED: The resource for which the policy is being requested.
   *  See the operation documentation for the appropriate value for this field.
   */
  // const resource = 'abc123'
  /**
   *  OPTIONAL: A `GetPolicyOptions` object for specifying options to
   *  `GetIamPolicy`.
   */
  // const options = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callGetIamPolicy() {
    // Construct request
    const request = {
      resource,
    };

    // Run request
    const response = await adminClient.getIamPolicy(request);
    console.log(response);
  }

  callGetIamPolicy();

getIamPolicy(request, options, callback)

getIamPolicy(request: protos.google.iam.v1.IGetIamPolicyRequest, options: CallOptions, callback: Callback<protos.google.iam.v1.IPolicy, protos.google.iam.v1.IGetIamPolicyRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetIamPolicyRequest
options CallOptions
callback Callback<protos.google.iam.v1.IPolicy, protos.google.iam.v1.IGetIamPolicyRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getIamPolicy(request, callback)

getIamPolicy(request: protos.google.iam.v1.IGetIamPolicyRequest, callback: Callback<protos.google.iam.v1.IPolicy, protos.google.iam.v1.IGetIamPolicyRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetIamPolicyRequest
callback Callback<protos.google.iam.v1.IPolicy, protos.google.iam.v1.IGetIamPolicyRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getInstance(request, options)

getInstance(request?: protos.google.bigtable.admin.v2.IGetInstanceRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.IInstance,
        protos.google.bigtable.admin.v2.IGetInstanceRequest | undefined,
        {} | undefined
    ]>;

Gets information about an instance.

Parameters
Name Description
request IGetInstanceRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IGetInstanceRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the requested instance. Values are of the form
   *  `projects/{project}/instances/{instance}`.
   */
  // const name = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callGetInstance() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const response = await adminClient.getInstance(request);
    console.log(response);
  }

  callGetInstance();

getInstance(request, options, callback)

getInstance(request: protos.google.bigtable.admin.v2.IGetInstanceRequest, options: CallOptions, callback: Callback<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IGetInstanceRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetInstanceRequest
options CallOptions
callback Callback<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IGetInstanceRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getInstance(request, callback)

getInstance(request: protos.google.bigtable.admin.v2.IGetInstanceRequest, callback: Callback<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IGetInstanceRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetInstanceRequest
callback Callback<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IGetInstanceRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getLogicalView(request, options)

getLogicalView(request?: protos.google.bigtable.admin.v2.IGetLogicalViewRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.ILogicalView,
        protos.google.bigtable.admin.v2.IGetLogicalViewRequest | undefined,
        {} | undefined
    ]>;

Gets information about a logical view.

Parameters
Name Description
request IGetLogicalViewRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.IGetLogicalViewRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing LogicalView. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the requested logical view. Values are of the
   *  form `projects/{project}/instances/{instance}/logicalViews/{logical_view}`.
   */
  // const name = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callGetLogicalView() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const response = await adminClient.getLogicalView(request);
    console.log(response);
  }

  callGetLogicalView();

getLogicalView(request, options, callback)

getLogicalView(request: protos.google.bigtable.admin.v2.IGetLogicalViewRequest, options: CallOptions, callback: Callback<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.IGetLogicalViewRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetLogicalViewRequest
options CallOptions
callback Callback<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.IGetLogicalViewRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getLogicalView(request, callback)

getLogicalView(request: protos.google.bigtable.admin.v2.IGetLogicalViewRequest, callback: Callback<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.IGetLogicalViewRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetLogicalViewRequest
callback Callback<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.IGetLogicalViewRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getMaterializedView(request, options)

getMaterializedView(request?: protos.google.bigtable.admin.v2.IGetMaterializedViewRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.IMaterializedView,
        protos.google.bigtable.admin.v2.IGetMaterializedViewRequest | undefined,
        {} | undefined
    ]>;

Gets information about a materialized view.

Parameters
Name Description
request IGetMaterializedViewRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.IGetMaterializedViewRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing MaterializedView. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the requested materialized view. Values are of
   *  the form
   *  `projects/{project}/instances/{instance}/materializedViews/{materialized_view}`.
   */
  // const name = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callGetMaterializedView() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const response = await adminClient.getMaterializedView(request);
    console.log(response);
  }

  callGetMaterializedView();

getMaterializedView(request, options, callback)

getMaterializedView(request: protos.google.bigtable.admin.v2.IGetMaterializedViewRequest, options: CallOptions, callback: Callback<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.IGetMaterializedViewRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetMaterializedViewRequest
options CallOptions
callback Callback<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.IGetMaterializedViewRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getMaterializedView(request, callback)

getMaterializedView(request: protos.google.bigtable.admin.v2.IGetMaterializedViewRequest, callback: Callback<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.IGetMaterializedViewRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IGetMaterializedViewRequest
callback Callback<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.IGetMaterializedViewRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

getProjectId()

getProjectId(): Promise<string>;
Returns
Type Description
Promise<string>

getProjectId(callback)

getProjectId(callback: Callback<string, undefined, undefined>): void;
Parameter
Name Description
callback Callback<string, undefined, undefined>
Returns
Type Description
void

hotTabletPath(project, instance, cluster, hotTablet)

hotTabletPath(project: string, instance: string, cluster: string, hotTablet: string): string;

Return a fully-qualified hotTablet resource name string.

Parameters
Name Description
project string
instance string
cluster string
hotTablet string
Returns
Type Description
string

{string} Resource name string.

initialize()

initialize(): Promise<{
        [name: string]: Function;
    }>;

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
Type Description
Promise<{ [name: string]: Function; }>

{Promise} A promise that resolves to an authenticated service stub.

instancePath(project, instance)

instancePath(project: string, instance: string): string;

Return a fully-qualified instance resource name string.

Parameters
Name Description
project string
instance string
Returns
Type Description
string

{string} Resource name string.

listAppProfiles(request, options)

listAppProfiles(request?: protos.google.bigtable.admin.v2.IListAppProfilesRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.IAppProfile[],
        protos.google.bigtable.admin.v2.IListAppProfilesRequest | null,
        protos.google.bigtable.admin.v2.IListAppProfilesResponse
    ]>;

Lists information about app profiles in an instance.

Parameters
Name Description
request IListAppProfilesRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.IAppProfile[], protos.google.bigtable.admin.v2.IListAppProfilesRequest | null, protos.google.bigtable.admin.v2.IListAppProfilesResponse ]>

{Promise} - The promise which resolves to an array. The first element of the array is Array of . The client library will perform auto-pagination by default: it will call the API as many times as needed and will merge results from all the pages into this array. Note that it can affect your quota. We recommend using listAppProfilesAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listAppProfiles(request, options, callback)

listAppProfiles(request: protos.google.bigtable.admin.v2.IListAppProfilesRequest, options: CallOptions, callback: PaginationCallback<protos.google.bigtable.admin.v2.IListAppProfilesRequest, protos.google.bigtable.admin.v2.IListAppProfilesResponse | null | undefined, protos.google.bigtable.admin.v2.IAppProfile>): void;
Parameters
Name Description
request IListAppProfilesRequest
options CallOptions
callback PaginationCallback<protos.google.bigtable.admin.v2.IListAppProfilesRequest, protos.google.bigtable.admin.v2.IListAppProfilesResponse | null | undefined, protos.google.bigtable.admin.v2.IAppProfile>
Returns
Type Description
void

listAppProfiles(request, callback)

listAppProfiles(request: protos.google.bigtable.admin.v2.IListAppProfilesRequest, callback: PaginationCallback<protos.google.bigtable.admin.v2.IListAppProfilesRequest, protos.google.bigtable.admin.v2.IListAppProfilesResponse | null | undefined, protos.google.bigtable.admin.v2.IAppProfile>): void;
Parameters
Name Description
request IListAppProfilesRequest
callback PaginationCallback<protos.google.bigtable.admin.v2.IListAppProfilesRequest, protos.google.bigtable.admin.v2.IListAppProfilesResponse | null | undefined, protos.google.bigtable.admin.v2.IAppProfile>
Returns
Type Description
void

listAppProfilesAsync(request, options)

listAppProfilesAsync(request?: protos.google.bigtable.admin.v2.IListAppProfilesRequest, options?: CallOptions): AsyncIterable<protos.google.bigtable.admin.v2.IAppProfile>;

Equivalent to listAppProfiles, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters
Name Description
request IListAppProfilesRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
AsyncIterable<protos.google.bigtable.admin.v2.IAppProfile>

{Object} An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing . The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the instance for which a list of app profiles
   *  is requested. Values are of the form
   *  `projects/{project}/instances/{instance}`.
   *  Use `{instance} = '-'` to list AppProfiles for all Instances in a project,
   *  e.g., `projects/myproject/instances/-`.
   */
  // const parent = 'abc123'
  /**
   *  Maximum number of results per page.
   *  A page_size of zero lets the server choose the number of items to return.
   *  A page_size which is strictly positive will return at most that many items.
   *  A negative page_size will cause an error.
   *  Following the first request, subsequent paginated calls are not required
   *  to pass a page_size. If a page_size is set in subsequent calls, it must
   *  match the page_size given in the first request.
   */
  // const pageSize = 1234
  /**
   *  The value of `next_page_token` returned by a previous call.
   */
  // const pageToken = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callListAppProfiles() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = adminClient.listAppProfilesAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListAppProfiles();

listAppProfilesStream(request, options)

listAppProfilesStream(request?: protos.google.bigtable.admin.v2.IListAppProfilesRequest, options?: CallOptions): Transform;

Equivalent to listAppProfiles, but returns a NodeJS Stream object.

Parameters
Name Description
request IListAppProfilesRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Transform

{Stream} An object stream which emits an object representing on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listAppProfilesAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listClusters(request, options)

listClusters(request?: protos.google.bigtable.admin.v2.IListClustersRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.IListClustersResponse,
        protos.google.bigtable.admin.v2.IListClustersRequest | undefined,
        {} | undefined
    ]>;

Lists information about clusters in an instance.

Parameters
Name Description
request IListClustersRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.IListClustersResponse, protos.google.bigtable.admin.v2.IListClustersRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing ListClustersResponse. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the instance for which a list of clusters is
   *  requested. Values are of the form
   *  `projects/{project}/instances/{instance}`. Use `{instance} = '-'` to list
   *  Clusters for all Instances in a project, e.g.,
   *  `projects/myproject/instances/-`.
   */
  // const parent = 'abc123'
  /**
   *  DEPRECATED: This field is unused and ignored.
   */
  // const pageToken = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callListClusters() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const response = await adminClient.listClusters(request);
    console.log(response);
  }

  callListClusters();

listClusters(request, options, callback)

listClusters(request: protos.google.bigtable.admin.v2.IListClustersRequest, options: CallOptions, callback: Callback<protos.google.bigtable.admin.v2.IListClustersResponse, protos.google.bigtable.admin.v2.IListClustersRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IListClustersRequest
options CallOptions
callback Callback<protos.google.bigtable.admin.v2.IListClustersResponse, protos.google.bigtable.admin.v2.IListClustersRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

listClusters(request, callback)

listClusters(request: protos.google.bigtable.admin.v2.IListClustersRequest, callback: Callback<protos.google.bigtable.admin.v2.IListClustersResponse, protos.google.bigtable.admin.v2.IListClustersRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IListClustersRequest
callback Callback<protos.google.bigtable.admin.v2.IListClustersResponse, protos.google.bigtable.admin.v2.IListClustersRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

listHotTablets(request, options)

listHotTablets(request?: protos.google.bigtable.admin.v2.IListHotTabletsRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.IHotTablet[],
        protos.google.bigtable.admin.v2.IListHotTabletsRequest | null,
        protos.google.bigtable.admin.v2.IListHotTabletsResponse
    ]>;

Lists hot tablets in a cluster, within the time range provided. Hot tablets are ordered based on CPU usage.

Parameters
Name Description
request IListHotTabletsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.IHotTablet[], protos.google.bigtable.admin.v2.IListHotTabletsRequest | null, protos.google.bigtable.admin.v2.IListHotTabletsResponse ]>

{Promise} - The promise which resolves to an array. The first element of the array is Array of HotTablet. The client library will perform auto-pagination by default: it will call the API as many times as needed and will merge results from all the pages into this array. Note that it can affect your quota. We recommend using listHotTabletsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listHotTablets(request, options, callback)

listHotTablets(request: protos.google.bigtable.admin.v2.IListHotTabletsRequest, options: CallOptions, callback: PaginationCallback<protos.google.bigtable.admin.v2.IListHotTabletsRequest, protos.google.bigtable.admin.v2.IListHotTabletsResponse | null | undefined, protos.google.bigtable.admin.v2.IHotTablet>): void;
Parameters
Name Description
request IListHotTabletsRequest
options CallOptions
callback PaginationCallback<protos.google.bigtable.admin.v2.IListHotTabletsRequest, protos.google.bigtable.admin.v2.IListHotTabletsResponse | null | undefined, protos.google.bigtable.admin.v2.IHotTablet>
Returns
Type Description
void

listHotTablets(request, callback)

listHotTablets(request: protos.google.bigtable.admin.v2.IListHotTabletsRequest, callback: PaginationCallback<protos.google.bigtable.admin.v2.IListHotTabletsRequest, protos.google.bigtable.admin.v2.IListHotTabletsResponse | null | undefined, protos.google.bigtable.admin.v2.IHotTablet>): void;
Parameters
Name Description
request IListHotTabletsRequest
callback PaginationCallback<protos.google.bigtable.admin.v2.IListHotTabletsRequest, protos.google.bigtable.admin.v2.IListHotTabletsResponse | null | undefined, protos.google.bigtable.admin.v2.IHotTablet>
Returns
Type Description
void

listHotTabletsAsync(request, options)

listHotTabletsAsync(request?: protos.google.bigtable.admin.v2.IListHotTabletsRequest, options?: CallOptions): AsyncIterable<protos.google.bigtable.admin.v2.IHotTablet>;

Equivalent to listHotTablets, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters
Name Description
request IListHotTabletsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
AsyncIterable<protos.google.bigtable.admin.v2.IHotTablet>

{Object} An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing HotTablet. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The cluster name to list hot tablets.
   *  Value is in the following form:
   *  `projects/{project}/instances/{instance}/clusters/{cluster}`.
   */
  // const parent = 'abc123'
  /**
   *  The start time to list hot tablets. The hot tablets in the response will
   *  have start times between the requested start time and end time. Start time
   *  defaults to Now if it is unset, and end time defaults to Now - 24 hours if
   *  it is unset. The start time should be less than the end time, and the
   *  maximum allowed time range between start time and end time is 48 hours.
   *  Start time and end time should have values between Now and Now - 14 days.
   */
  // const startTime = {}
  /**
   *  The end time to list hot tablets.
   */
  // const endTime = {}
  /**
   *  Maximum number of results per page.
   *  A page_size that is empty or zero lets the server choose the number of
   *  items to return. A page_size which is strictly positive will return at most
   *  that many items. A negative page_size will cause an error.
   *  Following the first request, subsequent paginated calls do not need a
   *  page_size field. If a page_size is set in subsequent calls, it must match
   *  the page_size given in the first request.
   */
  // const pageSize = 1234
  /**
   *  The value of `next_page_token` returned by a previous call.
   */
  // const pageToken = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callListHotTablets() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = adminClient.listHotTabletsAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListHotTablets();

listHotTabletsStream(request, options)

listHotTabletsStream(request?: protos.google.bigtable.admin.v2.IListHotTabletsRequest, options?: CallOptions): Transform;

Equivalent to listHotTablets, but returns a NodeJS Stream object.

Parameters
Name Description
request IListHotTabletsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Transform

{Stream} An object stream which emits an object representing HotTablet on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listHotTabletsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listInstances(request, options)

listInstances(request?: protos.google.bigtable.admin.v2.IListInstancesRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.IListInstancesResponse,
        protos.google.bigtable.admin.v2.IListInstancesRequest | undefined,
        {} | undefined
    ]>;

Lists information about instances in a project.

Parameters
Name Description
request IListInstancesRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.IListInstancesResponse, protos.google.bigtable.admin.v2.IListInstancesRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing ListInstancesResponse. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the project for which a list of instances is
   *  requested. Values are of the form `projects/{project}`.
   */
  // const parent = 'abc123'
  /**
   *  DEPRECATED: This field is unused and ignored.
   */
  // const pageToken = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callListInstances() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const response = await adminClient.listInstances(request);
    console.log(response);
  }

  callListInstances();

listInstances(request, options, callback)

listInstances(request: protos.google.bigtable.admin.v2.IListInstancesRequest, options: CallOptions, callback: Callback<protos.google.bigtable.admin.v2.IListInstancesResponse, protos.google.bigtable.admin.v2.IListInstancesRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IListInstancesRequest
options CallOptions
callback Callback<protos.google.bigtable.admin.v2.IListInstancesResponse, protos.google.bigtable.admin.v2.IListInstancesRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

listInstances(request, callback)

listInstances(request: protos.google.bigtable.admin.v2.IListInstancesRequest, callback: Callback<protos.google.bigtable.admin.v2.IListInstancesResponse, protos.google.bigtable.admin.v2.IListInstancesRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IListInstancesRequest
callback Callback<protos.google.bigtable.admin.v2.IListInstancesResponse, protos.google.bigtable.admin.v2.IListInstancesRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

listLogicalViews(request, options)

listLogicalViews(request?: protos.google.bigtable.admin.v2.IListLogicalViewsRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.ILogicalView[],
        protos.google.bigtable.admin.v2.IListLogicalViewsRequest | null,
        protos.google.bigtable.admin.v2.IListLogicalViewsResponse
    ]>;

Lists information about logical views in an instance.

Parameters
Name Description
request IListLogicalViewsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.ILogicalView[], protos.google.bigtable.admin.v2.IListLogicalViewsRequest | null, protos.google.bigtable.admin.v2.IListLogicalViewsResponse ]>

{Promise} - The promise which resolves to an array. The first element of the array is Array of LogicalView. The client library will perform auto-pagination by default: it will call the API as many times as needed and will merge results from all the pages into this array. Note that it can affect your quota. We recommend using listLogicalViewsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listLogicalViews(request, options, callback)

listLogicalViews(request: protos.google.bigtable.admin.v2.IListLogicalViewsRequest, options: CallOptions, callback: PaginationCallback<protos.google.bigtable.admin.v2.IListLogicalViewsRequest, protos.google.bigtable.admin.v2.IListLogicalViewsResponse | null | undefined, protos.google.bigtable.admin.v2.ILogicalView>): void;
Parameters
Name Description
request IListLogicalViewsRequest
options CallOptions
callback PaginationCallback<protos.google.bigtable.admin.v2.IListLogicalViewsRequest, protos.google.bigtable.admin.v2.IListLogicalViewsResponse | null | undefined, protos.google.bigtable.admin.v2.ILogicalView>
Returns
Type Description
void

listLogicalViews(request, callback)

listLogicalViews(request: protos.google.bigtable.admin.v2.IListLogicalViewsRequest, callback: PaginationCallback<protos.google.bigtable.admin.v2.IListLogicalViewsRequest, protos.google.bigtable.admin.v2.IListLogicalViewsResponse | null | undefined, protos.google.bigtable.admin.v2.ILogicalView>): void;
Parameters
Name Description
request IListLogicalViewsRequest
callback PaginationCallback<protos.google.bigtable.admin.v2.IListLogicalViewsRequest, protos.google.bigtable.admin.v2.IListLogicalViewsResponse | null | undefined, protos.google.bigtable.admin.v2.ILogicalView>
Returns
Type Description
void

listLogicalViewsAsync(request, options)

listLogicalViewsAsync(request?: protos.google.bigtable.admin.v2.IListLogicalViewsRequest, options?: CallOptions): AsyncIterable<protos.google.bigtable.admin.v2.ILogicalView>;

Equivalent to listLogicalViews, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters
Name Description
request IListLogicalViewsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
AsyncIterable<protos.google.bigtable.admin.v2.ILogicalView>

{Object} An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing LogicalView. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the instance for which the list of logical
   *  views is requested. Values are of the form
   *  `projects/{project}/instances/{instance}`.
   */
  // const parent = 'abc123'
  /**
   *  Optional. The maximum number of logical views to return. The service may
   *  return fewer than this value
   */
  // const pageSize = 1234
  /**
   *  Optional. A page token, received from a previous `ListLogicalViews` call.
   *  Provide this to retrieve the subsequent page.
   *  When paginating, all other parameters provided to `ListLogicalViews` must
   *  match the call that provided the page token.
   */
  // const pageToken = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callListLogicalViews() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = adminClient.listLogicalViewsAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListLogicalViews();

listLogicalViewsStream(request, options)

listLogicalViewsStream(request?: protos.google.bigtable.admin.v2.IListLogicalViewsRequest, options?: CallOptions): Transform;

Equivalent to listLogicalViews, but returns a NodeJS Stream object.

Parameters
Name Description
request IListLogicalViewsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Transform

{Stream} An object stream which emits an object representing LogicalView on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listLogicalViewsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listMaterializedViews(request, options)

listMaterializedViews(request?: protos.google.bigtable.admin.v2.IListMaterializedViewsRequest, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.IMaterializedView[],
        protos.google.bigtable.admin.v2.IListMaterializedViewsRequest | null,
        protos.google.bigtable.admin.v2.IListMaterializedViewsResponse
    ]>;

Lists information about materialized views in an instance.

Parameters
Name Description
request IListMaterializedViewsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.IMaterializedView[], protos.google.bigtable.admin.v2.IListMaterializedViewsRequest | null, protos.google.bigtable.admin.v2.IListMaterializedViewsResponse ]>

{Promise} - The promise which resolves to an array. The first element of the array is Array of MaterializedView. The client library will perform auto-pagination by default: it will call the API as many times as needed and will merge results from all the pages into this array. Note that it can affect your quota. We recommend using listMaterializedViewsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listMaterializedViews(request, options, callback)

listMaterializedViews(request: protos.google.bigtable.admin.v2.IListMaterializedViewsRequest, options: CallOptions, callback: PaginationCallback<protos.google.bigtable.admin.v2.IListMaterializedViewsRequest, protos.google.bigtable.admin.v2.IListMaterializedViewsResponse | null | undefined, protos.google.bigtable.admin.v2.IMaterializedView>): void;
Parameters
Name Description
request IListMaterializedViewsRequest
options CallOptions
callback PaginationCallback<protos.google.bigtable.admin.v2.IListMaterializedViewsRequest, protos.google.bigtable.admin.v2.IListMaterializedViewsResponse | null | undefined, protos.google.bigtable.admin.v2.IMaterializedView>
Returns
Type Description
void

listMaterializedViews(request, callback)

listMaterializedViews(request: protos.google.bigtable.admin.v2.IListMaterializedViewsRequest, callback: PaginationCallback<protos.google.bigtable.admin.v2.IListMaterializedViewsRequest, protos.google.bigtable.admin.v2.IListMaterializedViewsResponse | null | undefined, protos.google.bigtable.admin.v2.IMaterializedView>): void;
Parameters
Name Description
request IListMaterializedViewsRequest
callback PaginationCallback<protos.google.bigtable.admin.v2.IListMaterializedViewsRequest, protos.google.bigtable.admin.v2.IListMaterializedViewsResponse | null | undefined, protos.google.bigtable.admin.v2.IMaterializedView>
Returns
Type Description
void

listMaterializedViewsAsync(request, options)

listMaterializedViewsAsync(request?: protos.google.bigtable.admin.v2.IListMaterializedViewsRequest, options?: CallOptions): AsyncIterable<protos.google.bigtable.admin.v2.IMaterializedView>;

Equivalent to listMaterializedViews, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters
Name Description
request IListMaterializedViewsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
AsyncIterable<protos.google.bigtable.admin.v2.IMaterializedView>

{Object} An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing MaterializedView. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The unique name of the instance for which the list of
   *  materialized views is requested. Values are of the form
   *  `projects/{project}/instances/{instance}`.
   */
  // const parent = 'abc123'
  /**
   *  Optional. The maximum number of materialized views to return. The service
   *  may return fewer than this value
   */
  // const pageSize = 1234
  /**
   *  Optional. A page token, received from a previous `ListMaterializedViews`
   *  call. Provide this to retrieve the subsequent page.
   *  When paginating, all other parameters provided to `ListMaterializedViews`
   *  must match the call that provided the page token.
   */
  // const pageToken = 'abc123'

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callListMaterializedViews() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = adminClient.listMaterializedViewsAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListMaterializedViews();

listMaterializedViewsStream(request, options)

listMaterializedViewsStream(request?: protos.google.bigtable.admin.v2.IListMaterializedViewsRequest, options?: CallOptions): Transform;

Equivalent to listMaterializedViews, but returns a NodeJS Stream object.

Parameters
Name Description
request IListMaterializedViewsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Transform

{Stream} An object stream which emits an object representing MaterializedView on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listMaterializedViewsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

logicalViewPath(project, instance, logicalView)

logicalViewPath(project: string, instance: string, logicalView: string): string;

Return a fully-qualified logicalView resource name string.

Parameters
Name Description
project string
instance string
logicalView string
Returns
Type Description
string

{string} Resource name string.

matchAppProfileFromAppProfileName(appProfileName)

matchAppProfileFromAppProfileName(appProfileName: string): string | number;

Parse the app_profile from AppProfile resource.

Parameter
Name Description
appProfileName string

A fully-qualified path representing AppProfile resource.

Returns
Type Description
string | number

{string} A string representing the app_profile.

matchAuthorizedViewFromAuthorizedViewName(authorizedViewName)

matchAuthorizedViewFromAuthorizedViewName(authorizedViewName: string): string | number;

Parse the authorized_view from AuthorizedView resource.

Parameter
Name Description
authorizedViewName string

A fully-qualified path representing AuthorizedView resource.

Returns
Type Description
string | number

{string} A string representing the authorized_view.

matchBackupFromBackupName(backupName)

matchBackupFromBackupName(backupName: string): string | number;

Parse the backup from Backup resource.

Parameter
Name Description
backupName string

A fully-qualified path representing Backup resource.

Returns
Type Description
string | number

{string} A string representing the backup.

matchClusterFromBackupName(backupName)

matchClusterFromBackupName(backupName: string): string | number;

Parse the cluster from Backup resource.

Parameter
Name Description
backupName string

A fully-qualified path representing Backup resource.

Returns
Type Description
string | number

{string} A string representing the cluster.

matchClusterFromClusterName(clusterName)

matchClusterFromClusterName(clusterName: string): string | number;

Parse the cluster from Cluster resource.

Parameter
Name Description
clusterName string

A fully-qualified path representing Cluster resource.

Returns
Type Description
string | number

{string} A string representing the cluster.

matchClusterFromHotTabletName(hotTabletName)

matchClusterFromHotTabletName(hotTabletName: string): string | number;

Parse the cluster from HotTablet resource.

Parameter
Name Description
hotTabletName string

A fully-qualified path representing HotTablet resource.

Returns
Type Description
string | number

{string} A string representing the cluster.

matchClusterFromSnapshotName(snapshotName)

matchClusterFromSnapshotName(snapshotName: string): string | number;

Parse the cluster from Snapshot resource.

Parameter
Name Description
snapshotName string

A fully-qualified path representing Snapshot resource.

Returns
Type Description
string | number

{string} A string representing the cluster.

matchHotTabletFromHotTabletName(hotTabletName)

matchHotTabletFromHotTabletName(hotTabletName: string): string | number;

Parse the hot_tablet from HotTablet resource.

Parameter
Name Description
hotTabletName string

A fully-qualified path representing HotTablet resource.

Returns
Type Description
string | number

{string} A string representing the hot_tablet.

matchInstanceFromAppProfileName(appProfileName)

matchInstanceFromAppProfileName(appProfileName: string): string | number;

Parse the instance from AppProfile resource.

Parameter
Name Description
appProfileName string

A fully-qualified path representing AppProfile resource.

Returns
Type Description
string | number

{string} A string representing the instance.

matchInstanceFromAuthorizedViewName(authorizedViewName)

matchInstanceFromAuthorizedViewName(authorizedViewName: string): string | number;

Parse the instance from AuthorizedView resource.

Parameter
Name Description
authorizedViewName string

A fully-qualified path representing AuthorizedView resource.

Returns
Type Description
string | number

{string} A string representing the instance.

matchInstanceFromBackupName(backupName)

matchInstanceFromBackupName(backupName: string): string | number;

Parse the instance from Backup resource.

Parameter
Name Description
backupName string

A fully-qualified path representing Backup resource.

Returns
Type Description
string | number

{string} A string representing the instance.

matchInstanceFromClusterName(clusterName)

matchInstanceFromClusterName(clusterName: string): string | number;

Parse the instance from Cluster resource.

Parameter
Name Description
clusterName string

A fully-qualified path representing Cluster resource.

Returns
Type Description
string | number

{string} A string representing the instance.

matchInstanceFromHotTabletName(hotTabletName)

matchInstanceFromHotTabletName(hotTabletName: string): string | number;

Parse the instance from HotTablet resource.

Parameter
Name Description
hotTabletName string

A fully-qualified path representing HotTablet resource.

Returns
Type Description
string | number

{string} A string representing the instance.

matchInstanceFromInstanceName(instanceName)

matchInstanceFromInstanceName(instanceName: string): string | number;

Parse the instance from Instance resource.

Parameter
Name Description
instanceName string

A fully-qualified path representing Instance resource.

Returns
Type Description
string | number

{string} A string representing the instance.

matchInstanceFromLogicalViewName(logicalViewName)

matchInstanceFromLogicalViewName(logicalViewName: string): string | number;

Parse the instance from LogicalView resource.

Parameter
Name Description
logicalViewName string

A fully-qualified path representing LogicalView resource.

Returns
Type Description
string | number

{string} A string representing the instance.

matchInstanceFromMaterializedViewName(materializedViewName)

matchInstanceFromMaterializedViewName(materializedViewName: string): string | number;

Parse the instance from MaterializedView resource.

Parameter
Name Description
materializedViewName string

A fully-qualified path representing MaterializedView resource.

Returns
Type Description
string | number

{string} A string representing the instance.

matchInstanceFromSnapshotName(snapshotName)

matchInstanceFromSnapshotName(snapshotName: string): string | number;

Parse the instance from Snapshot resource.

Parameter
Name Description
snapshotName string

A fully-qualified path representing Snapshot resource.

Returns
Type Description
string | number

{string} A string representing the instance.

matchInstanceFromTableName(tableName)

matchInstanceFromTableName(tableName: string): string | number;

Parse the instance from Table resource.

Parameter
Name Description
tableName string

A fully-qualified path representing Table resource.

Returns
Type Description
string | number

{string} A string representing the instance.

matchLogicalViewFromLogicalViewName(logicalViewName)

matchLogicalViewFromLogicalViewName(logicalViewName: string): string | number;

Parse the logical_view from LogicalView resource.

Parameter
Name Description
logicalViewName string

A fully-qualified path representing LogicalView resource.

Returns
Type Description
string | number

{string} A string representing the logical_view.

matchMaterializedViewFromMaterializedViewName(materializedViewName)

matchMaterializedViewFromMaterializedViewName(materializedViewName: string): string | number;

Parse the materialized_view from MaterializedView resource.

Parameter
Name Description
materializedViewName string

A fully-qualified path representing MaterializedView resource.

Returns
Type Description
string | number

{string} A string representing the materialized_view.

matchProjectFromAppProfileName(appProfileName)

matchProjectFromAppProfileName(appProfileName: string): string | number;

Parse the project from AppProfile resource.

Parameter
Name Description
appProfileName string

A fully-qualified path representing AppProfile resource.

Returns
Type Description
string | number

{string} A string representing the project.

matchProjectFromAuthorizedViewName(authorizedViewName)

matchProjectFromAuthorizedViewName(authorizedViewName: string): string | number;

Parse the project from AuthorizedView resource.

Parameter
Name Description
authorizedViewName string

A fully-qualified path representing AuthorizedView resource.

Returns
Type Description
string | number

{string} A string representing the project.

matchProjectFromBackupName(backupName)

matchProjectFromBackupName(backupName: string): string | number;

Parse the project from Backup resource.

Parameter
Name Description
backupName string

A fully-qualified path representing Backup resource.

Returns
Type Description
string | number

{string} A string representing the project.

matchProjectFromClusterName(clusterName)

matchProjectFromClusterName(clusterName: string): string | number;

Parse the project from Cluster resource.

Parameter
Name Description
clusterName string

A fully-qualified path representing Cluster resource.

Returns
Type Description
string | number

{string} A string representing the project.

matchProjectFromHotTabletName(hotTabletName)

matchProjectFromHotTabletName(hotTabletName: string): string | number;

Parse the project from HotTablet resource.

Parameter
Name Description
hotTabletName string

A fully-qualified path representing HotTablet resource.

Returns
Type Description
string | number

{string} A string representing the project.

matchProjectFromInstanceName(instanceName)

matchProjectFromInstanceName(instanceName: string): string | number;

Parse the project from Instance resource.

Parameter
Name Description
instanceName string

A fully-qualified path representing Instance resource.

Returns
Type Description
string | number

{string} A string representing the project.

matchProjectFromLogicalViewName(logicalViewName)

matchProjectFromLogicalViewName(logicalViewName: string): string | number;

Parse the project from LogicalView resource.

Parameter
Name Description
logicalViewName string

A fully-qualified path representing LogicalView resource.

Returns
Type Description
string | number

{string} A string representing the project.

matchProjectFromMaterializedViewName(materializedViewName)

matchProjectFromMaterializedViewName(materializedViewName: string): string | number;

Parse the project from MaterializedView resource.

Parameter
Name Description
materializedViewName string

A fully-qualified path representing MaterializedView resource.

Returns
Type Description
string | number

{string} A string representing the project.

matchProjectFromProjectName(projectName)

matchProjectFromProjectName(projectName: string): string | number;

Parse the project from Project resource.

Parameter
Name Description
projectName string

A fully-qualified path representing Project resource.

Returns
Type Description
string | number

{string} A string representing the project.

matchProjectFromSnapshotName(snapshotName)

matchProjectFromSnapshotName(snapshotName: string): string | number;

Parse the project from Snapshot resource.

Parameter
Name Description
snapshotName string

A fully-qualified path representing Snapshot resource.

Returns
Type Description
string | number

{string} A string representing the project.

matchProjectFromTableName(tableName)

matchProjectFromTableName(tableName: string): string | number;

Parse the project from Table resource.

Parameter
Name Description
tableName string

A fully-qualified path representing Table resource.

Returns
Type Description
string | number

{string} A string representing the project.

matchSnapshotFromSnapshotName(snapshotName)

matchSnapshotFromSnapshotName(snapshotName: string): string | number;

Parse the snapshot from Snapshot resource.

Parameter
Name Description
snapshotName string

A fully-qualified path representing Snapshot resource.

Returns
Type Description
string | number

{string} A string representing the snapshot.

matchTableFromAuthorizedViewName(authorizedViewName)

matchTableFromAuthorizedViewName(authorizedViewName: string): string | number;

Parse the table from AuthorizedView resource.

Parameter
Name Description
authorizedViewName string

A fully-qualified path representing AuthorizedView resource.

Returns
Type Description
string | number

{string} A string representing the table.

matchTableFromTableName(tableName)

matchTableFromTableName(tableName: string): string | number;

Parse the table from Table resource.

Parameter
Name Description
tableName string

A fully-qualified path representing Table resource.

Returns
Type Description
string | number

{string} A string representing the table.

materializedViewPath(project, instance, materializedView)

materializedViewPath(project: string, instance: string, materializedView: string): string;

Return a fully-qualified materializedView resource name string.

Parameters
Name Description
project string
instance string
materializedView string
Returns
Type Description
string

{string} Resource name string.

partialUpdateCluster(request, options)

partialUpdateCluster(request?: protos.google.bigtable.admin.v2.IPartialUpdateClusterRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IPartialUpdateClusterMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Partially updates a cluster within a project. This method is the preferred way to update a Cluster.

To enable and update autoscaling, set cluster_config.cluster_autoscaling_config. When autoscaling is enabled, serve_nodes is treated as an OUTPUT_ONLY field, meaning that updates to it are ignored. Note that an update cannot simultaneously set serve_nodes to non-zero and cluster_config.cluster_autoscaling_config to non-empty, and also specify both in the update_mask.

To disable autoscaling, clear cluster_config.cluster_autoscaling_config, and explicitly set a serve_node count via the update_mask.

Parameters
Name Description
request IPartialUpdateClusterRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IPartialUpdateClusterMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The Cluster which contains the partial updates to be applied,
   *  subject to the update_mask.
   */
  // const cluster = {}
  /**
   *  Required. The subset of Cluster fields which should be replaced.
   */
  // const updateMask = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callPartialUpdateCluster() {
    // Construct request
    const request = {
      cluster,
      updateMask,
    };

    // Run request
    const [operation] = await adminClient.partialUpdateCluster(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callPartialUpdateCluster();

partialUpdateCluster(request, options, callback)

partialUpdateCluster(request: protos.google.bigtable.admin.v2.IPartialUpdateClusterRequest, options: CallOptions, callback: Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IPartialUpdateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IPartialUpdateClusterRequest
options CallOptions
callback Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IPartialUpdateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

partialUpdateCluster(request, callback)

partialUpdateCluster(request: protos.google.bigtable.admin.v2.IPartialUpdateClusterRequest, callback: Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IPartialUpdateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IPartialUpdateClusterRequest
callback Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IPartialUpdateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

partialUpdateInstance(request, options)

partialUpdateInstance(request?: protos.google.bigtable.admin.v2.IPartialUpdateInstanceRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IUpdateInstanceMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Partially updates an instance within a project. This method can modify all fields of an Instance and is the preferred way to update an Instance.

Parameters
Name Description
request IPartialUpdateInstanceRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IUpdateInstanceMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The Instance which will (partially) replace the current value.
   */
  // const instance = {}
  /**
   *  Required. The subset of Instance fields which should be replaced.
   *  Must be explicitly set.
   */
  // const updateMask = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callPartialUpdateInstance() {
    // Construct request
    const request = {
      instance,
      updateMask,
    };

    // Run request
    const [operation] = await adminClient.partialUpdateInstance(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callPartialUpdateInstance();

partialUpdateInstance(request, options, callback)

partialUpdateInstance(request: protos.google.bigtable.admin.v2.IPartialUpdateInstanceRequest, options: CallOptions, callback: Callback<LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IUpdateInstanceMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IPartialUpdateInstanceRequest
options CallOptions
callback Callback<LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IUpdateInstanceMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

partialUpdateInstance(request, callback)

partialUpdateInstance(request: protos.google.bigtable.admin.v2.IPartialUpdateInstanceRequest, callback: Callback<LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IUpdateInstanceMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IPartialUpdateInstanceRequest
callback Callback<LROperation<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IUpdateInstanceMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

projectPath(project)

projectPath(project: string): string;

Return a fully-qualified project resource name string.

Parameter
Name Description
project string
Returns
Type Description
string

{string} Resource name string.

setIamPolicy(request, options)

setIamPolicy(request?: protos.google.iam.v1.ISetIamPolicyRequest, options?: CallOptions): Promise<[
        protos.google.iam.v1.IPolicy,
        protos.google.iam.v1.ISetIamPolicyRequest | undefined,
        {} | undefined
    ]>;

Sets the access control policy on an instance resource. Replaces any existing policy.

Parameters
Name Description
request ISetIamPolicyRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.iam.v1.IPolicy, protos.google.iam.v1.ISetIamPolicyRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing Policy. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  REQUIRED: The resource for which the policy is being specified.
   *  See the operation documentation for the appropriate value for this field.
   */
  // const resource = 'abc123'
  /**
   *  REQUIRED: The complete policy to be applied to the `resource`. The size of
   *  the policy is limited to a few 10s of KB. An empty policy is a
   *  valid policy but certain Cloud Platform services (such as Projects)
   *  might reject them.
   */
  // const policy = {}
  /**
   *  OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only
   *  the fields in the mask will be modified. If no mask is provided, the
   *  following default mask is used:
   *  `paths: "bindings, etag"`
   */
  // const updateMask = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callSetIamPolicy() {
    // Construct request
    const request = {
      resource,
      policy,
    };

    // Run request
    const response = await adminClient.setIamPolicy(request);
    console.log(response);
  }

  callSetIamPolicy();

setIamPolicy(request, options, callback)

setIamPolicy(request: protos.google.iam.v1.ISetIamPolicyRequest, options: CallOptions, callback: Callback<protos.google.iam.v1.IPolicy, protos.google.iam.v1.ISetIamPolicyRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ISetIamPolicyRequest
options CallOptions
callback Callback<protos.google.iam.v1.IPolicy, protos.google.iam.v1.ISetIamPolicyRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

setIamPolicy(request, callback)

setIamPolicy(request: protos.google.iam.v1.ISetIamPolicyRequest, callback: Callback<protos.google.iam.v1.IPolicy, protos.google.iam.v1.ISetIamPolicyRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ISetIamPolicyRequest
callback Callback<protos.google.iam.v1.IPolicy, protos.google.iam.v1.ISetIamPolicyRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

snapshotPath(project, instance, cluster, snapshot)

snapshotPath(project: string, instance: string, cluster: string, snapshot: string): string;

Return a fully-qualified snapshot resource name string.

Parameters
Name Description
project string
instance string
cluster string
snapshot string
Returns
Type Description
string

{string} Resource name string.

tablePath(project, instance, table)

tablePath(project: string, instance: string, table: string): string;

Return a fully-qualified table resource name string.

Parameters
Name Description
project string
instance string
table string
Returns
Type Description
string

{string} Resource name string.

testIamPermissions(request, options)

testIamPermissions(request?: protos.google.iam.v1.ITestIamPermissionsRequest, options?: CallOptions): Promise<[
        protos.google.iam.v1.ITestIamPermissionsResponse,
        protos.google.iam.v1.ITestIamPermissionsRequest | undefined,
        {} | undefined
    ]>;

Returns permissions that the caller has on the specified instance resource.

Parameters
Name Description
request ITestIamPermissionsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.iam.v1.ITestIamPermissionsResponse, protos.google.iam.v1.ITestIamPermissionsRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing TestIamPermissionsResponse. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  REQUIRED: The resource for which the policy detail is being requested.
   *  See the operation documentation for the appropriate value for this field.
   */
  // const resource = 'abc123'
  /**
   *  The set of permissions to check for the `resource`. Permissions with
   *  wildcards (such as '*' or 'storage.*') are not allowed. For more
   *  information see
   *  IAM Overview (https://cloud.google.com/iam/docs/overview#permissions).
   */
  // const permissions = ['abc','def']

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callTestIamPermissions() {
    // Construct request
    const request = {
      resource,
      permissions,
    };

    // Run request
    const response = await adminClient.testIamPermissions(request);
    console.log(response);
  }

  callTestIamPermissions();

testIamPermissions(request, options, callback)

testIamPermissions(request: protos.google.iam.v1.ITestIamPermissionsRequest, options: CallOptions, callback: Callback<protos.google.iam.v1.ITestIamPermissionsResponse, protos.google.iam.v1.ITestIamPermissionsRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ITestIamPermissionsRequest
options CallOptions
callback Callback<protos.google.iam.v1.ITestIamPermissionsResponse, protos.google.iam.v1.ITestIamPermissionsRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

testIamPermissions(request, callback)

testIamPermissions(request: protos.google.iam.v1.ITestIamPermissionsRequest, callback: Callback<protos.google.iam.v1.ITestIamPermissionsResponse, protos.google.iam.v1.ITestIamPermissionsRequest | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ITestIamPermissionsRequest
callback Callback<protos.google.iam.v1.ITestIamPermissionsResponse, protos.google.iam.v1.ITestIamPermissionsRequest | null | undefined, {} | null | undefined>
Returns
Type Description
void

updateAppProfile(request, options)

updateAppProfile(request?: protos.google.bigtable.admin.v2.IUpdateAppProfileRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.IUpdateAppProfileMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Updates an app profile within an instance.

Parameters
Name Description
request IUpdateAppProfileRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ LROperation<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.IUpdateAppProfileMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The app profile which will (partially) replace the current value.
   */
  // const appProfile = {}
  /**
   *  Required. The subset of app profile fields which should be replaced.
   *  If unset, all fields will be replaced.
   */
  // const updateMask = {}
  /**
   *  If true, ignore safety checks when updating the app profile.
   */
  // const ignoreWarnings = true

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callUpdateAppProfile() {
    // Construct request
    const request = {
      appProfile,
      updateMask,
    };

    // Run request
    const [operation] = await adminClient.updateAppProfile(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callUpdateAppProfile();

updateAppProfile(request, options, callback)

updateAppProfile(request: protos.google.bigtable.admin.v2.IUpdateAppProfileRequest, options: CallOptions, callback: Callback<LROperation<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.IUpdateAppProfileMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IUpdateAppProfileRequest
options CallOptions
callback Callback<LROperation<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.IUpdateAppProfileMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

updateAppProfile(request, callback)

updateAppProfile(request: protos.google.bigtable.admin.v2.IUpdateAppProfileRequest, callback: Callback<LROperation<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.IUpdateAppProfileMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IUpdateAppProfileRequest
callback Callback<LROperation<protos.google.bigtable.admin.v2.IAppProfile, protos.google.bigtable.admin.v2.IUpdateAppProfileMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

updateCluster(request, options)

updateCluster(request?: protos.google.bigtable.admin.v2.ICluster, options?: CallOptions): Promise<[
        LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IUpdateClusterMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Updates a cluster within an instance.

Note that UpdateCluster does not support updating cluster_config.cluster_autoscaling_config. In order to update it, you must use PartialUpdateCluster.

Parameters
Name Description
request ICluster

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IUpdateClusterMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  The unique name of the cluster. Values are of the form
   *  `projects/{project}/instances/{instance}/clusters/[a-z][-a-z0-9]*`.
   */
  // const name = 'abc123'
  /**
   *  Immutable. The location where this cluster's nodes and storage reside. For
   *  best performance, clients should be located as close as possible to this
   *  cluster. Currently only zones are supported, so values should be of the
   *  form `projects/{project}/locations/{zone}`.
   */
  // const location = 'abc123'
  /**
   *  Output only. The current state of the cluster.
   */
  // const state = {}
  /**
   *  The number of nodes in the cluster. If no value is set,
   *  Cloud Bigtable automatically allocates nodes based on your data footprint
   *  and optimized for 50% storage utilization.
   */
  // const serveNodes = 1234
  /**
   *  Immutable. The node scaling factor of this cluster.
   */
  // const nodeScalingFactor = {}
  /**
   *  Configuration for this cluster.
   */
  // const clusterConfig = {}
  /**
   *  Immutable. The type of storage used by this cluster to serve its
   *  parent instance's tables, unless explicitly overridden.
   */
  // const defaultStorageType = {}
  /**
   *  Immutable. The encryption configuration for CMEK-protected clusters.
   */
  // const encryptionConfig = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callUpdateCluster() {
    // Construct request
    const request = {
      location,
      state,
      nodeScalingFactor,
      defaultStorageType,
      encryptionConfig,
    };

    // Run request
    const [operation] = await adminClient.updateCluster(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callUpdateCluster();

updateCluster(request, options, callback)

updateCluster(request: protos.google.bigtable.admin.v2.ICluster, options: CallOptions, callback: Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IUpdateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICluster
options CallOptions
callback Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IUpdateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

updateCluster(request, callback)

updateCluster(request: protos.google.bigtable.admin.v2.ICluster, callback: Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IUpdateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request ICluster
callback Callback<LROperation<protos.google.bigtable.admin.v2.ICluster, protos.google.bigtable.admin.v2.IUpdateClusterMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

updateInstance(request, options)

updateInstance(request?: protos.google.bigtable.admin.v2.IInstance, options?: CallOptions): Promise<[
        protos.google.bigtable.admin.v2.IInstance,
        protos.google.bigtable.admin.v2.IInstance | undefined,
        {} | undefined
    ]>;

Updates an instance within a project. This method updates only the display name and type for an Instance. To update other Instance properties, such as labels, use PartialUpdateInstance.

Parameters
Name Description
request IInstance

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IInstance | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  The unique name of the instance. Values are of the form
   *  `projects/{project}/instances/[a-z][a-z0-9\\-]+[a-z0-9]`.
   */
  // const name = 'abc123'
  /**
   *  Required. The descriptive name for this instance as it appears in UIs.
   *  Can be changed at any time, but should be kept globally unique
   *  to avoid confusion.
   */
  // const displayName = 'abc123'
  /**
   *  Output only. The current state of the instance.
   */
  // const state = {}
  /**
   *  The type of the instance. Defaults to `PRODUCTION`.
   */
  // const type = {}
  /**
   *  Labels are a flexible and lightweight mechanism for organizing cloud
   *  resources into groups that reflect a customer's organizational needs and
   *  deployment strategies. They can be used to filter resources and aggregate
   *  metrics.
   *  * Label keys must be between 1 and 63 characters long and must conform to
   *    the regular expression: `[\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}_-]{0,62}`.
   *  * Label values must be between 0 and 63 characters long and must conform to
   *    the regular expression: `[\p{Ll}\p{Lo}\p{N}_-]{0,63}`.
   *  * No more than 64 labels can be associated with a given resource.
   *  * Keys and values must both be under 128 bytes.
   */
  // const labels = [1,2,3,4]
  /**
   *  Output only. A commit timestamp representing when this Instance was
   *  created. For instances created before this field was added (August 2021),
   *  this value is `seconds: 0, nanos: 1`.
   */
  // const createTime = {}
  /**
   *  Output only. Reserved for future use.
   */
  // const satisfiesPzs = true
  /**
   *  Output only. Reserved for future use.
   */
  // const satisfiesPzi = true

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callUpdateInstance() {
    // Construct request
    const request = {
      displayName,
      state,
      createTime,
      satisfiesPzs,
      satisfiesPzi,
    };

    // Run request
    const response = await adminClient.updateInstance(request);
    console.log(response);
  }

  callUpdateInstance();

updateInstance(request, options, callback)

updateInstance(request: protos.google.bigtable.admin.v2.IInstance, options: CallOptions, callback: Callback<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IInstance | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IInstance
options CallOptions
callback Callback<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IInstance | null | undefined, {} | null | undefined>
Returns
Type Description
void

updateInstance(request, callback)

updateInstance(request: protos.google.bigtable.admin.v2.IInstance, callback: Callback<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IInstance | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IInstance
callback Callback<protos.google.bigtable.admin.v2.IInstance, protos.google.bigtable.admin.v2.IInstance | null | undefined, {} | null | undefined>
Returns
Type Description
void

updateLogicalView(request, options)

updateLogicalView(request?: protos.google.bigtable.admin.v2.IUpdateLogicalViewRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.IUpdateLogicalViewMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Updates a logical view within an instance.

Parameters
Name Description
request IUpdateLogicalViewRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.IUpdateLogicalViewMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The logical view to update.
   *  The logical view's `name` field is used to identify the view to update.
   *  Format:
   *  `projects/{project}/instances/{instance}/logicalViews/{logical_view}`.
   */
  // const logicalView = {}
  /**
   *  Optional. The list of fields to update.
   */
  // const updateMask = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callUpdateLogicalView() {
    // Construct request
    const request = {
      logicalView,
    };

    // Run request
    const [operation] = await adminClient.updateLogicalView(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callUpdateLogicalView();

updateLogicalView(request, options, callback)

updateLogicalView(request: protos.google.bigtable.admin.v2.IUpdateLogicalViewRequest, options: CallOptions, callback: Callback<LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.IUpdateLogicalViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IUpdateLogicalViewRequest
options CallOptions
callback Callback<LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.IUpdateLogicalViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

updateLogicalView(request, callback)

updateLogicalView(request: protos.google.bigtable.admin.v2.IUpdateLogicalViewRequest, callback: Callback<LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.IUpdateLogicalViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IUpdateLogicalViewRequest
callback Callback<LROperation<protos.google.bigtable.admin.v2.ILogicalView, protos.google.bigtable.admin.v2.IUpdateLogicalViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

updateMaterializedView(request, options)

updateMaterializedView(request?: protos.google.bigtable.admin.v2.IUpdateMaterializedViewRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.IUpdateMaterializedViewMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Updates a materialized view within an instance.

Parameters
Name Description
request IUpdateMaterializedViewRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
Type Description
Promise<[ LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.IUpdateMaterializedViewMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. Please see the documentation for more details and examples.

Example

  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The materialized view to update.
   *  The materialized view's `name` field is used to identify the view to
   *  update. Format:
   *  `projects/{project}/instances/{instance}/materializedViews/{materialized_view}`.
   */
  // const materializedView = {}
  /**
   *  Optional. The list of fields to update.
   */
  // const updateMask = {}

  // Imports the Admin library
  const {BigtableInstanceAdminClient} = require('@google-cloud/bigtable').v2;

  // Instantiates a client
  const adminClient = new BigtableInstanceAdminClient();

  async function callUpdateMaterializedView() {
    // Construct request
    const request = {
      materializedView,
    };

    // Run request
    const [operation] = await adminClient.updateMaterializedView(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callUpdateMaterializedView();

updateMaterializedView(request, options, callback)

updateMaterializedView(request: protos.google.bigtable.admin.v2.IUpdateMaterializedViewRequest, options: CallOptions, callback: Callback<LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.IUpdateMaterializedViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IUpdateMaterializedViewRequest
options CallOptions
callback Callback<LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.IUpdateMaterializedViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void

updateMaterializedView(request, callback)

updateMaterializedView(request: protos.google.bigtable.admin.v2.IUpdateMaterializedViewRequest, callback: Callback<LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.IUpdateMaterializedViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
Name Description
request IUpdateMaterializedViewRequest
callback Callback<LROperation<protos.google.bigtable.admin.v2.IMaterializedView, protos.google.bigtable.admin.v2.IUpdateMaterializedViewMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
Type Description
void