Professional Cloud Developer free question 4 / 10 · Domain 2: Building and testing applications
A developer starts the Bigtable emulator for a local test and wants to create a table. The developer has no Bigtable instance in any project. What is the correct way to proceed?
- Use the project and instance of a real Bigtable deployment, as the emulator accepts only names that exist in a project
- Open a TLS connection with a service account key, as the emulator accepts authenticated secure connections
- Create an instance and a cluster through the emulator's administrative API first, and then create the table inside that instance
- Connect to the running emulator with any project and instance name, then create the table and read or write data directly
Show the answer and explanation
Answer: D
Why this is correct
The Bigtable emulator is local and in-memory, intended for development and testing. It does not provide administrative APIs to create or manage instances and clusters. After the emulator starts, you connect to it using any project and instance name, create tables, and read or write data. It also does not support a secure connection. The page also notes that the emulator cannot be used in the HBase shell, and that it supports all filters except the Sink limiting filter.
Why the other options are wrong
"Create an instance and a cluster through the emulator's administrative API first, and then create the table inside that instance" … The page says the emulator does not provide administrative APIs to create or manage instances and clusters. You connect with any project and instance name instead.
"Use the project and instance of a real Bigtable deployment, as the emulator accepts only names that exist in a project" … The emulator accepts any project and instance name. It runs locally and does not look up resources in a project.
"Open a TLS connection with a service account key, as the emulator accepts authenticated secure connections" … The page states that the emulator does not support a secure connection. It is intended for local development and testing, not for production deployments.
Key point
Skip instance and cluster setup with the emulator. Pick any names, and create the tables your test needs.