This topic describes the instructions for using HTTP SDKs provided by Message Queue for Apache RocketMQ. The normal use of the HTTP SDKs may be affected if you do not follow relevant instructions.

Multi-language support

Message Queue for Apache RocketMQ supports RESTful HTTP communication and provides SDKs in the following seven languages:

Notes

  • Make sure that the resource you want to access is in the same region as the HTTP endpoint.

    For example, if your Message Queue for Apache RocketMQ instance is deployed in China (Hangzhou), you can only access the instance by using an endpoint of the China (Hangzhou) region. You can access the resource in the following scenarios:

    • If your client is located in the China (Hangzhou) region, we recommend that you access the instance resource by using the internal HTTP endpoint of the instance.
    • If your client is located in a region other than China (Hangzhou), make sure that your client can connect to the Internet and can access the instance resource by using the Internet HTTP endpoint of the instance.
  • Messages can be exchanged between TCP and HTTP clients. However, HTTP uses Extensive Markup Language (XML) serialization. Therefore, the message attributes, content, tags, and keys must comply with XML specifications.

    If they contain characters that do not comply with XML specifications, the following errors may occur:

    • Failed to send messages over HTTP.
    • Failed to consume messages over HTTP when messages are sent over TCP.

    You can encode or decode messages in Base64 mode for the scenarios where messages are not sent or received based on XML specifications.

The features supported by HTTP after continuous iteration are gradually consistent with the features supported by TCP. For information about the comparison between the features supported by HTTP versions and those supported by the latest TCP version, see Release notes.