AAMP & FOG Retry / Failover / Timeouts
AAMP DASH DRM License request :
AAMP DASH Manifest Download Retry logic (without TSB) :
AAMP Fragment Download Retry logic (without TSB) :
AAMP HLS Main Manifest Download Retry logic (without TSB) :
AAMP-FOG_tune_request_retrylogic_uml :
http 4xx (and 502 Bad Gateway) are considered fatal errors for a given download attempt. No retry of the same URL will be performed. For other 5xx failures, single retry will be attempted after configurable delay (default 1s).
AAMP Video Engine Timeouts for fragment, manifest, and license requests are all configurable – defaults as follows:
- #define CURL_FRAGMENT_DL_TIMEOUT 10L /**< Curl timeout for fragment download */
- #define DEFAULT_PLAYLIST_DL_TIMEOUT 10L /**< Curl timeout for playlist download */
- #define DEFAULT_CURL_TIMEOUT 5L /**< Default timeout for other (i.e. license) Curl downloads */
- #define DEFAULT_CURL_CONNECTTIMEOUT 3L /**< Curl socket connection timeout */
FOG is a separate service involved with Client-Side IP Linear Time Shift Buffer (TSB) support, caching fragments and generating virtual playlists that grow and eventually cull. As such, it shares many of the same responsibilities and behaviors as AAMP running in AAMP-only playback scenarios. FOG configuration includes:
-
waitTimeBeforeRetryHttp5xxMS – 1s
-
downloadTimeoutMS – 5s
-
expirationTimeMS – 30s
-
minFragmentDownloadDelayMS – 10ms; behind ENABLE_ABR_TESTING for randomized simulated download latency
-
maxFragmentDownloadDelayMS – 100ms; behind ENABLE_ABR_TESTING for randomized simulated download latency
-
tsbPreemptiveDownloadDelay – 5
-
vfsContextDumpDuration – 10000 – periodic virtual file system state logging
-
bitrateCheating – false
-
maxConcurrentDownloads – 1
-
sleepFraction – 1.5
-
manifestUpdate – 60s
-
defaultFetchTimeout – 60s
-
writeFailThreshold – 3 (write failure threshold before disabling TSB)
-
bitrateInit – initial bitrate while tuning normal content
-
bitrateInit4K – initial bitrate while tuning 4k content
-
fragmentFailThreshold – 5
-
cullLength – 1500 / 3600 (25 minutes or 1 hour)