Activation error handling

To reduce property or include activation errors, use the acknowledgeAllWarnings=true flag and wait for the activation status=ACTIVE before submitting additional activation requests.

Revert a property activation

PAPI offers an option to quickly revert a property activation:

  • If you detect a problem with the rule tree within an hour of its activation, To build the request object, go to the activationLink from the activation's response and note down the fallbackVersion value. Within an hour of activating, POST another activation with propertyVersion set to the version you noted down and useFastFallback set to true. Within a few seconds, it disables the current activation and falls back to the specified version. Fallback may also occur automatically if the activated metadata fails various execution tests on edge servers. The fallback option isn't available if you've changed the set of property hostnames, or if this is the property's first activation. When polling the activation's status, the canFastFallback flag indicates whether fallback is possible.

  • If the fast fallback option isn't available as indicated by "canFastFallback":false, you need to separately activate the previous version of the rule tree known not to cause problems.

🚧

Contact your Akamai representative for guidance on expected latency, both to validate your property's rule tree and to activate it worldwide.

400 error when activating a property or include

When activating your property or include, you might get a 400 error response if you don't acknowledge all rule tree warnings. By default, PAPI requires an acknowledgment of any warnings before activating a property or include. This is resource intensive and can lead to submitting multiple requests. To avoid unnecessary retries, set the acknowledgeAllWarnings flag to true when you activate or deactivate a property or activate or deactivate an include.

{
    "propertyVersion": 1,
    "network": "PRODUCTION",
    "note": "A better activation",
    "useFastFallback": false,
    "notifyEmails": [
        "you@example.com"
    ],
    "acknowledgeAllWarnings": true
}

If the response contains any errors, you need to resolve them as they block activation.

409 error when activating a property or include

Multiple simultaneous activations on a single property or include within the same network result with a 409 error response. This also applies to property hostname changes.

Check for any activations with "status": PENDING for the same network by listing property's activations or listing include's activations before creating a new version and activating it:

{
    "accountId": "act_1111",
    "contractId": "ctr_2222",
    "groupId": "grp_3333",
    "activations": {
        "items": [
            {
                "activationId": "atv_9876",
                "propertyName": "example.com",
                "propertyId": "prp_12345",
                "propertyVersion": 1,
                "network": "PRODUCTION",
                "activationType": "ACTIVATE",
                "status": "PENDING",
                "submitDate": "2021-03-02T02:22:12Z",
                "updateDate": "2021-03-01T21:12:57Z",
                "note": "Sample activation",
                "fmaActivationState": "steady",
                "notifyEmails": [
                    "you@example.com"
                ],
                "fallbackInfo": {
                    "fastFallbackAttempted": false,
                    "fallbackVersion": 10,
                    "canFastFallback": true,
                    "steadyStateTime": 1506448172,
                    "fastFallbackExpirationTime": 1506451772,
                    "fastFallbackRecoveryState": null
                }
            }
        ]
    }
}

If there already is a PENDING activation, try another property/include or wait for the previous activation to complete, using a reasonable back-off algorithm. You can poll one specific PENDING property or include activation instead of listing all activations. The Retry-After header provides an estimate when you should check status again. Typically activations take around 10 minutes on PRODUCTION, but they can take much longer in certain circumstances. See best practices for more information on the exponential backoff algorithm to avoid overwhelming the system with retries.

Response: 200
Response Headers: 	Retry-After: 600  
{
    "accountId": "act_0000",
    "contractId": "ctr_1111",
    "groupId": "grp_2222",
    "activations": {
        "items": [
            {
                "activationId": "atv_6789",
                "propertyName": "example property",
                "propertyId": "prp_12345",
                "propertyVersion": 1,
                "network": "PRODUCTION",
                "activationType": "ACTIVATE",
                "status": "ACTIVE",
                "submitDate": "2021-03-02T02:22:12Z",
                "updateDate": "2021-03-01T21:12:57Z",
                "note": "A better activation",
                "fmaActivationState": "received",
                "notifyEmails": [
                    "you@example.com"
                ]
            }
        ]
    }
}

429 error when activating a property or include

429 error indicates you have exceeded the 24-hour activation limit for your account account.

The response contains the X-RateLimit-Activations-* headers that inform you about the currently imposed rate limits and time you need to wait for the remaining limit to reset to the original value.

Activation best practices

  • If you have multiple machines trying to activate properties at the same time, you may run into race conditions. Race conditions can result in unexpected or inconsistent behaviors. Ideally, you should set up a single process that runs update and activation PAPI operations.
  • For all the error conditions that require a retry, you should implement an exponential backoff algorithm to avoid excessive load on the system. An exponential backoff algorithm retries requests exponentially, meaning the clients wait progressively longer between retries up to a maximum backoff time. You can start with a few seconds delay and then increase the waiting time on subsequent retries.