Throttling

Use throttling to slow the rate of messages sent from your project to reduce load on your backend systems.

View as Markdown

How throttling works

Throttling sets a target send rate in messages per second, spreading sends over time to help prevent traffic spikes. It works best for audiences larger than 1,000,000 users.

For example, if you send a flash sale notification to 5,000,000 users, many of them may open your app within minutes. That surge can overwhelm your servers or APIs. Throttling spreads the send over several hours, so the opens are spread out too.

Throttling has the following behaviors:

  • Batching — Airship sends messages in batches of up to 1,000 and calculates the send rate for each batch. At lower rates, the pause between batches is longer, so messages can arrive in bursts instead of a steady stream.
  • Best effort — Over short periods, the actual send rate can be lower or higher than the rate you set. Over longer periods, it averages out close to that rate.
  • Queuing — Airship holds messages you send while a throttled message is still sending, then sends them in order of their send or scheduled times. A scheduled message can send later than its scheduled time if it’s waiting behind a throttled message.

You can apply throttling to all messages in your project or to individual messages sent from the dashboard.

Throttling is not supported for Message Center, Scenes, or In-App Automation.

Determining an appropriate rate

Work with your backend development teams to choose a rate based on the maximum sustained activity your systems can handle. The load depends on what your messages trigger, such as API calls or video streaming, and not only on how many you send.

Ideally, the rate is fast enough to deliver a broadcast to your entire audience in less than 8 hours. To find this, divide the audience size by 28,800, the number of seconds in 8 hours. For example, an audience of 10,000,000 needs at least about 347 messages per second.

Also consider these factors:

  • Delivery speed — Messages pass through other systems and networks before reaching a device, so delivery can be slower than the send rate.
  • Open rate — Typically 5-30% of delivered messages are opened when they arrive. Opens are what create load on your systems.
  • Background pushes — These are an exception to the open rate and can create more traffic per message sent.

If you need help choosing a rate, contact Support .

Per-message throttling

In the dashboard, you can set a throttle rate for individual messages in the Message composer and for A/B test variants. If you have project-level throttling enabled, this setting takes priority.

For procedure and behavior details, see Throttle delivery in Delivery options.

Project-level throttling

Project-level throttling applies a throttle rate to all supported message types sent from your project. It is available on certain contracted plans. To enable it, contact your Airship account manager.

Disabling throttling for API messages

If your project has throttling enabled, you can disable it for urgent or time-sensitive messages sent using the API by adding the no_throttle push option to the Push object.

Disable throttling for a message
{
  "options": {
    "no_throttle": true
  },
  "audience": "all",
  "device_types": [
    "ios"
  ],
  "notification": {
    "alert": "This message is not throttled."
  }
}

Best practice: Set expiration for push notifications

Throttling can spread a large send over several hours, so some recipients may receive a message long after it was sent. An expiration stops delivery after a time you choose, but iOS and Android apply it differently:

  • iOS — The expiration is a “do not deliver after” time. APNs drops any message it receives after that time. For more information, see Sending Notification Requests to APNs  in Apple’s developer documentation.
  • Android — Android gives each message a countdown, called time to live, measured in seconds. The countdown starts when Google’s delivery service, FCM, gets the message from Airship. Throttling holds messages back before that point, so the countdown can start well after the send begins.

Set an expiration for your push notifications so recipients don’t receive a message after the time it was meant for:

  • In the dashboard, use the delivery options for your message. See Expiration in Delivery options.
  • In the API, add the expiry option to the Push object.