1. Home
  2. API Catalog
  3. Refinitiv Real-Time C++ SDK

Refinitiv Real-Time SDK - C/C++

RTSDK (EMA/ETA) Quick Start

Last update Feb 2022
Environment Windows, Linux

Visual Studio (Windows), GCC (Linux)

Refer to RTSDK Readme for a complete list.

Prerequisites (Desktop access)

The steps outlined within this guide depend on details outlined within the RTSDK C/C++ Installation Guide available within GitHub. Ensure this document is at your disposal.

Access to an existing Refinitiv Real-Time Distribution System to retrieve content

Prerequisites (Amazon EC2 access) Set Up an Amazon EC2 instance based on the Refinitiv AMI.


The goal of this Getting Started tutorial is to provide the developer with the steps required to confirm access to either a deployed Refinitv Real-Time Distributed Server (RTDS) or the cloud-based Refinitiv Real-Time - Optimized (RTO) service by executing one of the packaged RTSDK examples.  EMA and ETA are sub-components of the RTSDK (Refinitiv Real-Time SDK) package that includes a number of examples available to test specific functionality.  For our purposes, the goal is to walk through the procedure to specify the connection details to access the preferred streaming platform, retrieving market data content.

This guide is applicable to both Linux and Windows environments.

Additional Details on the prerequisites

When you register to access Refinitiv Real-Time -- Optimized, you should have received a Welcome email containing the following details:

  • Machine ID
    • In the form: XX-Y-12345678-9-0000
  • A link to set your password

In addition, the RTO examples require a client ID or App Key that can be generated by using the AppKey Generator.

Alternatively, if you want to test access to a deployed RTDS environment, your market data administrator can grant you permission and provide you with a user ID.

If accessing services via Refinitiv Real-Time -- Optimized, this requires an encrypted connection.  The C/C++ libraries utilize OpenSSL for encryption.  Refer to the C/C++ readme for details related to OpenSSL.

Note: For Linux developers using WSL on Windows, I would recommend you refer to the Coding & Testing Linux Applications on Windows using WSL and VS Code article.  While the article focuses on the installation and setup of a development environment, it also provides instructions to download, install, build a simple RTSDK consumer application.  

Download the RTSDK (Desktop access only)

The Enterprise Message API (EMA) and Enterprise Transport API (ETA) are included in the RTSDK package.  Within the RTSDK C/C++ Installation Guide, you can refer to the sections to obtain the download package.

Once the package has been downloaded and installed, we need to generate the project files necessary to build our desired examples.  The C/C++ package depends on the CMake utility and the bundled configuration files to configure a built Tree.  Refer to the CMake section outlined within the installation guide to configure a build tree for either a Windows or Linux environment.


# Example cmake command on Windows using Visual Studio 2019

C:\tmp\RTSDK-2.0.4.L1.win.rrg> cmake -H. -Bbuild -G "Visual Studio 16 2019" -A x64

Once completed, we can move to the Build and Run an example section below.

Build and run an example

To demonstrate the basic operation of streaming data, you can choose to build and run any of the following relevant examples available within the RTSDK package:

  • For EMA, the following are available:
    • Cons113 [113_MP_SessionMgmt] - example to test connectivity into RTO
    • Cons100 [100_MP_SessionMgmt] - example to test connectivity into a deployed RTDS

  • For ETA, the following is available:
    • VAConsumer - example tests connectivity into both RTO and RTDS

Depending on your target OS (Windows or Linux), refer to the installation guide for details of the location of the generated project files.  Once you've determined the main project file as outlined within the guide, choose the desired example (EMA or ETA) and build. 

For example:

Windows:  Within the main project file (rtsdk), simply locate and build your desired example.



# From your build directory, eg: rtbuild


# EMA - RTO (cloud)
make Cons113

# EMA - RTDS (deployed)
make Cons100

# ETA - Both RTO and RTDS
make VAConsumer

*Important*: Prior to running some of the examples, we must ensure the required external libraries are properly referenced.  For a list of external dependencies, refer to the C/C++ readme.

Within the RTSDK download package, the installdb directory includes external libraries (including libcurl).  Some of the examples may require the need to reference the external dependencies within your setup.  For example, use LD_LIBRARY_PATH for Linux or make sure that the libraries are otherwise accessible for Windows (e.g., include the directory in %PATH%). 


# Example (Windows)
setx PATH "%PATH%;sourcdir\installdb\WIN_64_VS142\lib

# Example (Linux)
export LD_LIBRARY_PATH=builddir/install/lib64

Once configured, you are ready to run an example.

When running any of the following examples, the goal is to generate output showing market data.  For example:


The EMA examples will require additional steps prior to running:

Cons100 (deployed test against RTDS):
Within your sourceDir/Cpp-C/Ema/Examples/Training/Consumer/100_Series/100_MP_Streaming directory, edit the Consumer.cpp file:

Modify the required values:

  1. Choose the location of your deployed RTDS.  Eg:'elektron:14002'
  2. Change the name of the service providing market data.  Eg: 'ELEKTRON_DD'.  Note: Reach out to the market data team for this setting.
  3. If applicable, choose your ID provided by your market data team.

# Navigate to the binary directory and execute the example

# Windows Eg: sourceDir/Cpp-C/Ema/Executables/WIN_64_VS142/Debug_MDd

# Linux: Eg: sourceDir/Cpp-C/Ema/Executables/RHEL8_64_GCC831/Optimized


Cons113 (RTO test):
This example requires the EMA configuration file: EmaConfig.xml to be copied within the runtime directory.


# Navigate to the binary directory and copy the config file

# Windows Eg: sourceDir/Cpp-C/Ema/Executables/WIN_64_VS142/Debug_MDd
copy ..\..\..\EmaConfig.xml .

# Linux: Eg: sourceDir/Cpp-C/Ema/Executables/RHEL8_64_GCC831/Optimized

cp ../../../EmaConfig.xml .


# Run the example - connecting into RTO
# Note: Ensure you have the credentials as outlined within the Pre-requisite section above

# Windows example
Cons113 -username GE-X-01234567-8-9999 -password my_password -clientId f6698eeeeexxxxx8888811111eeee12345

# Linux example
./Cons113 -username GE-X-01234567-8-9999 -password my_password -clientId f6698eeeeexxxxx8888811111eeee12345


The following ETA example does not require additional configuration.  In addition, the same example can be used to connect to both a deployed RTDS and a cloud-based RTO environment.


# Ensure you are running from the runtime directory

# Windows: Eg: sourceDir/Cpp-C/Eta/Executables/WIN_64_VS142/Debug_MDd
# Linux: Eg: sourceDir/Cpp-C/Eta/Executables/RHEL8_64_GCC831/Optimized

# Run the example - connecting into a deployed RTDS
VAConsumer -tcp localhost:14002 ELEKTRON_DD mp:AAPL.O

# Run the example - connecting into RTO
# Note: Ensure you have the credentials as outlined within the Pre-requisite section above
VAConsumer -encryptedSocket us-east-2-aws-3-med.optimized-pricing-api.refinitiv.net:14002 ELEKTRON_DD mp:IBM.N -uname GE-X-01234567-8-9999 -passwd my_password -clientId f6698eeeeexxxxx8888811111eeee12345 -sessionMgnt


Error: Exception Type='OmmInvalidConfigurationException', Text='OmmConsumerConfigImpl::consumerName parameter [Consumer_4] is a non-existent consumer name'
Reason: No EMA config file.  The EMA example 'Con113' depends on the config file: EmaConfig.xml to be available within the working directory.


Error: Error Text Failed to initialize RsslRestClient. Text: <..../Real-Time-SDK/Cpp-C/Eta/Impl/Util/rsslCurlJIT.c:77> Error: 0012 Libcurl intialization failed.  Curl library: libcurl.so not found.
Reason: Not referencing external libraries.  The example you are using must reference the external libraries by either updating your PATH (Windows) or LD_LIBRARY_PATH (Linux).  Refer to the "Build and Run an example" section defined above.


Error: 0012 Unable to load openSSL Libraries
Reason: OpenSSL not installed.  Refer to the Pre-requisite section defined above.


Error: Error Text <..../Real-Time-SDK/Cpp-C/Eta/Impl/Transport/rsslSocketTransportImpl.c:6074> Error: 1002 ipcConnecting() client connect() failed.  System errno: (107) loggerMsgEnd
Reason: The RTDS server you are connecting to may be invalid or incorrectly specified.  Reach out to your market data team to confirm the server IP address.


Error: Connection down, reconnecting.  Channel fd=18446744073709551615
                 Error text: <D:\Jenkins\workspace\ESDKCore_RCDEV\OS\VS142-64\rcdev\source\rtsdk\Cpp-C\Eta\Impl\Transport\ripcsslutils.c:1748> Error: 1002 ripcSSLInit client connect() failed. System errno: 10057
Reason: Cannot reach the endpoint or server specified.  For example, when connecting to:

  • RTO (cloud)
    The specified -encryptedSocket is either invalid or you may not have access to the specified tier.  To retrieve a valid list of RTO endpoints based on your assigned tier, refer to the DNS Names within the Current Endpoints section outlined in the Refinitiv Real-Time - Optimized Installation and configuration for client use documentation.

  • RTDS (deployed)
    The specified deployed server -tcp is unavailable or incorrect.  You will need to confirm with your market data team the correct address and ensure you have access.


Next Steps

Once you have successfully completed the steps above, you can further your learning by following the series of tutorials.