List clusters

Stay organized with collections Save and categorize content based on your preferences.

Lists the clusters in the instance.

Code sample


To learn how to install and use the client library for Bigtable, see Bigtable client libraries.

// Lists clusters in the instance.
// Initialize request argument(s)
ListClustersRequest listClustersRequest = new ListClustersRequest
    ParentAsInstanceName = new InstanceName(projectId, instanceId)

    // Make a request.
    Console.WriteLine("Waiting for operation to complete...");
    ListClustersResponse response = bigtableInstanceAdminClient.ListClusters(listClustersRequest);
catch (Exception ex)
    Console.WriteLine($"Exception while requesting information about clusters in {instanceId} instance");

What's next

To search and filter code samples for other Google Cloud products, see the Google Cloud sample browser.