Phoenix allows you to execute SQL statements to query data that is stored in ApsaraDB for HBase. Phoenix transforms SQL statements into one or more HBase API operations and runs queries along with coprocessors and custom filters. Phoenix can complete simple queries in milliseconds.
For more information, see the official website of Apache Phoenix.
- Ali-Phoenix is compatible with open source clients (open source 4.12).
- Ali-Phoenix can be accessed over the Internet.
- Ali-Phoenix fixes multiple bugs of Apache Phoenix.
- New features are added to Ali-Phoenix and the performance of Ali-Phoenix is optimized.
- Create an Elastic Compute Service (ECS) instance that is in the same network as your ApsaraDB for HBase cluster.
- Download the Phoenix client. Download the corresponding version of the Phoenix client on the ECS instance. In this example, the 4.12.0-AliHBase-1.1-0.9 version is used.
- Run the following command to decompress the downloaded package:
tar zxvf ali-phoenix-4.12.0-AliHBase-1.1-0.9.tar.gz
- Add the client IP address to the whitelist of the ApsaraDB for HBase cluster to which you want to connect. Run the following command to view the private IP address of the ECS instance:
Then, add the returned private IP address of the ECS instance to the whitelist of the ApsaraDB for HBase cluster. For more information, see Configure IP address allowlists and security groups.
- Start SQLLine. Obtain the endpoints of ZooKeeper on the cluster details page in the ApsaraDB for HBase console. Then, run the following command in
If the command output is similar to
jdbc:xxxx>, SQLLine is started.
- Run the following command to check whether the configuration is successful:
If a list of tables is returned, the configuration is successful. You can then get started with the HBase SQL service.
- Run the following command to exit Phoenix: