Tencent Cloud TDMQ for Apache Pulsar is fully compatible with open-source Apache Pulsar, with higher versions maintaining complete backward compatibility with lower versions. This document describes how to collect connection information for TDMQ for Apache Pulsar clusters, such as obtaining cluster access points, usernames, and passwords for cluster access, and provides demo examples and usage instructions for SDKs in various programming languages.
Note:
To better align with the Pulsar open-source community, Tencent Cloud SDK discontinued feature updates starting from April 30, 2021. For TDMQ for Apache Pulsar, it is recommended to use the Apache Pulsar SDK.
|
TCP Protocol (Apache Pulsar) | Spring Boot Starter | | |
| Java | | |
| Go | | |
| C++ | | |
| Python | | |
| Node.js | / | |
Client Network Environment Description
Clients can connect to and access a Pulsar cluster through the following three network methods:
1. Direct access within the same Virtual Private Cloud (VPC)
Clients and the Pulsar cluster are deployed within the same VPC, and the network is interconnected by default. You can directly use the VPC access point for network access.
2. Cross-VPC communication through Cloud Connect Network (CCN)
Clients and the Pulsar cluster are deployed in different VPCs. Since VPCs are logically isolated from each other, they cannot communicate directly. To enable cross-network communication, you can use CCN to achieve VPC interconnection across different regions under the same account.
3. Public network access
Clients deployed in other network environments or in different regions from the Pulsar cluster can establish a public network route to access the cluster through the public network access point.
Obtaining Connection Information
1. Cluster access point address and port information.
On the Cluster page, obtain the information by clicking Access Address in the operation column. Select different access points based on the network type.
2. The role token for accessing the cluster. Make sure that the role has already been granted the corresponding access permissions.
On the Role Management page, copy the role token. Role token leakage may lead to data leakage. Keep your role token securely.
3. Topic name.
On the Topic page in the console, copy the topic name. The format is clusterid/namespace/topic.
4. Subscription relationship name.
On the Consumer tab of the topic details page, copy the subscription relationship name.