Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

Using the Streaming API

General

The streaming API fetches both test and monitor data. It is not possible to single out one of these categories.

The streaming API does not fetch data from script-based tests (those represented by a rectangle instead of a jigsaw piece in the Control Center GUI).

Protobuf Schemas

Protocol buffers, or protobufs for short, are Google's language-neutral, platform-neutral, and extensible mechanism for serializing structured data. Code and documentation are found here.

The streaming API uses protobufs …

TODO include protobuf schema in docs; need to explain schema structure

Kafka Topic Names

The Kafka topic names for the streaming API are as follows, where %s is the short name of the Control Center account (indicated when creating the account):

Examples of Using the Streaming API

The examples that follow are found in the directory TODO .

Setup

Build the Docker image from the directory client-examples:

Client Usage

To read all messages from the metrics topic using the Docker image just built, run the following:

To read all messages from the metadata topic using the Docker image, run:

Running Against Localhost

If Kafka runs on the local server, and you would like to fetch data from it, you need to use the --network host switch in the docker command: