Skip to content

Commit fd1e079

Browse files
committed
feat(bigtable): pass default app profile ID in quickstart
Update the quickstart example to explicitly configure the Table instance with the "default" application profile ID using AppProfileIdOption.
1 parent 3852865 commit fd1e079

2 files changed

Lines changed: 8 additions & 4 deletions

File tree

google/cloud/bigtable/README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,10 @@ int main(int argc, char* argv[]) try {
3636
// Create a namespace alias to make the code easier to read.
3737
namespace cbt = ::google::cloud::bigtable;
3838

39-
cbt::Table table(cbt::MakeDataConnection(),
40-
cbt::TableResource(project_id, instance_id, table_id));
39+
cbt::Table table(
40+
cbt::MakeDataConnection(),
41+
cbt::TableResource(project_id, instance_id, table_id),
42+
google::cloud::Options{}.set<cbt::AppProfileIdOption>("default"));
4143

4244
std::string row_key = "r1";
4345
std::string column_family = "cf1";

google/cloud/bigtable/quickstart/quickstart.cc

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,10 @@ int main(int argc, char* argv[]) try {
3131
// Create a namespace alias to make the code easier to read.
3232
namespace cbt = ::google::cloud::bigtable;
3333

34-
cbt::Table table(cbt::MakeDataConnection(),
35-
cbt::TableResource(project_id, instance_id, table_id));
34+
cbt::Table table(
35+
cbt::MakeDataConnection(),
36+
cbt::TableResource(project_id, instance_id, table_id),
37+
google::cloud::Options{}.set<cbt::AppProfileIdOption>("default"));
3638

3739
std::string row_key = "r1";
3840
std::string column_family = "cf1";

0 commit comments

Comments
 (0)