Traffic Management Load Feedback API Resources

The Traffic Management Load Feedback API is an upcoming offering. It is not available for use yet, but this document describes the API and how to use it. We encourage prospective users to review these documents and submit feedback via our Community page.

The Akamai Global Traffic Management (GTM) has an optional feature called load feedback. With load feedback, load balancing is controlled by measurements of entities, which you define, called resources. GTM names are grouped by domain (for example, example.akadns.net). Within a domain, you may have any number of properties, or fully qualified names (e.g., images.example.akadns.net). Network traffic is balanced between data centers, also known as regions or traffic targets.

A resource is anything that is consumed by load on a data center, and is measured and reported to improve load balancing. As an example, for a database application, you might decide that the most important measurement of load is queries per second. For a static web server, you might choose to measure HTTP GET requests per second. A resource is simply a name for something you measure that reflects how you want to balance load across your datacenters. You report the load in whatever units make sense to you; to GTM, loads are just relative unit-less quantities. A resource may constrain a single property, or all properties in a domain.

An instance of a resource represents the current, target, and maximum load configured for a particular data center.

For a full description of GTM, our DNS-based load balancing, and all the terms used here, please see the GTM integration guide, and for documentation of all aspects of GTM’s API, please see the GTM API guide.

API Summary

Operation Method Endpoint
Submit and Fetch Load Data
Submit Load Data POST /gtm-load-data/v1/{domain}/{resource}/{datacenterId}
Fetch Load Data GET /gtm-load-data/v1/{domain}/{resource}/{datacenterId}

Submit Load Data

Use this action to submit load data. The URI specifies the domain, resource, and datacenterId of the instance to which the load data pertains. The data may be submitted in either XML or JSON format. To support legacy clients, we allow region as an alias for datacenterId. The timestamp string should be in XSD format.

In the examples that follow, we’ll assume you have a GTM domain called example.akadns.net. Within this domain, you have a resource called connections, which reports the number of HTTP connections in a datacenter. In these examples, we will update and check the load data for the connections resource datacenter number 100.

POST /gtm-load-data/v1/{domain}/{resource}/{datacenterId}

Example: /gtm-load-data/v1/example.akadns.net/connections/100

Content-Type: application/json

Request:

{
    "domain": "example.akadns.net",
    "datacenterId": 100,
    "resource": "connections",
    "timestamp": "2015-05-01T19:38:53.188Z",
    "current-load": 20,
    "target-load": 25,
    "max-load": 30
}

POST /gtm-load-data/v1/{domain}/{resource}/{datacenterId}

Example: /gtm-load-data/v1/example.akadns.net/connections/100

Content-Type: application/xml

Request:

<load-object domain="example.akadns.net" timestamp="2015-05-01T19:38:53.188Z" version="1" xmlns="http://www.akamai.com/FirstPoint/load-balancing">
    <datacenter datacenterId="100">
        <resource name="connections">
            <current-load>20</current-load>
            <target-load>25</target-load>
            <max-load>30</max-load>
        </resource>
    </datacenter>
</load-object>

Parameter Type Sample Description
Required
datacenterId Number 100 The ID number for the datacenter (traffic target), from the “Akamai code” field in the Luna Control Center.
domain String example.akadns.net The name of the GTM domain
resource String connections The name of the resource

Status 204

Fetch Load Data

Use this action to fetch the load data for a resource instance. The URI format is the same as the POST action. The API will return either XML or JSON, depending on your Accept header (if both are specified, or there is no Accept header, we default to JSON). In this sample data, we’re fetching load for a resource called connections in datacenter 100, in the domain example.akadns.net.

GET /gtm-load-data/v1/{domain}/{resource}/{datacenterId}

Example: /gtm-load-data/v1/example.akadns.net/connections/100

Parameter Type Sample Description
Required
datacenterId Number 100 The ID number for the datacenter (traffic target), from the “Akamai code” field in the Luna Control Center.
domain String example.akadns.net The name of the GTM domain
resource String connections The name of the resource

Status 200 application/json

Headers:

  • Accept: application/json

Response:

{
    "domain": "example.akadns.net",
    "datacenterId": 100,
    "resource": "connections",
    "timestamp": "2015-05-01T19:38:53.188Z",
    "current-load": 20,
    "target-load": 25,
    "max-load": 30
}

Status 200 application/xml

Headers:

  • Accept: application/xml

Response:

<load-object domain="example.akadns.net" timestamp="2015-05-01T19:38:53.188Z" version="1" xmlns="http://www.akamai.com/FirstPoint/load-balancing">
    <datacenter datacenterId="100">
        <resource name="connections">
            <current-load>20</current-load>
            <target-load>25</target-load>
            <max-load>30</max-load>
        </resource>
    </datacenter>
</load-object>


Last modified: 12/12/2016