All Products
Search
Document Center

ApsaraMQ for RocketMQ:SDK for C++

Last Updated:Dec 13, 2024

This topic describes how to use the rocketmq-client-cpp binary package released by Apache RocketMQ to deploy and connect to Alibaba Cloud ApsaraMQ for RocketMQ. If you want to compile the source code, go to Apache Software Foundation to download the package.

Usage notes

SDKs of the Community Edition are used only in scenarios in which you want to migrate business in Apache RocketMQ clusters to ApsaraMQ for RocketMQ instances without code modification. For other scenarios, we recommend that you use SDKs of the Commercial Edition to connect to ApsaraMQ for RocketMQ. Compared with SDKs of the Community Edition, SDKs of the Commercial Edition provide more features and higher stability. For more information, see Release notes.

Install the C++ dynamic library

For more information, see Install the C++ dynamic library.

(Optional) Parameters

Before you use the SDK for C++ to connect to ApsaraMQ for RocketMQ to send and receive messages, you must configure the required parameters. For more information, see Parameters.

You can also refer to the comments in the SDK for C++ to get the details of the parameters.

Use the SDK for C++ to send and receive messages

You can use the SDK for C++ to send and receive the following types of messages: