Summary of setup:
A mixture of Parallel and Serial elements composing stitched together media. example: 20 images followed a mixture of videos and images all in one timeline. The videos are RTMP mbr streams. All videos are preloaded (via loadTrait.load()) in order to allow seeking to any point in the timeline.
The problem seems to be when it takes too long to get to the videos or even if a video is played but currently paused for a long time. The time seems to change but eventually I'll get this error:
Tue Sep 13 2011 05:32:03 PM [INFO] [org.osmf.net.NetStreamLoadTrait] NetStream.Failed
Tue Sep 13 2011 05:32:03 PM [DEBUG] [org.osmf.net.NetStreamSwitchManager] onNetStatus() - event.info.code=NetStream.Failed
Tue Sep 13 2011 05:32:03 PM [INFO] [org.osmf.net.NetLoader] Stream reconnect: onNetStatus: NetStream.Failed
The media player then unloads all media and gets an error event - Error: Playback failed - time and duration are reset to 0 and the player is basically broken.
Is there any way to prevent this? I know I can listen for these errors happen but what can be done to reconnect the stream and play as normal?
Also, sometimes the streams will successfully reconnect before they're ever played but upon reconnecting, they'll play even though they're not supposed to be playing (they're further down in the timeline).
Ok I've found that this is actually due to cloudfront links expiring. Is there way to dynamically catch this and change the dynamic stream URLs if I can detect they've expired?