I've been testing 4.0.4 for the past 2 weeks with transcoder on live streams from FMS. I've noticed that from time to time, the different bitrates in the abr (160p and 360p) sometimes develop slight discrepancies in segment durations.
For example, here's a diff of the output m3u8 |grep EXTINF for 2 transcodings of the same stream running for 20 hrs:
The target duration in this case was reported as 6 but the segments appear to be a bit under 4. So this means the difference occurred after approx 5.7 hrs.
I've been running 24 hr tests. I've never seen a difference totally more than 90ms overall in ~10 x 24 hr runs.... but similarly, the majority of the time, I don't see a 0ms difference, which would be what I would expect -- with all key frames starting each segment aligned exactly. 40-80 ms is typical and it's always been only 1 segment that differs. Sometimes it's even the first segment (which seems to suggest it isn't always long running streams).
The cause may be that one or more of the renditions has b frames which may cause the timestamps to be different to the other renditions. Each packet has two timestamp values, PTS (Presentation Time Stamp) and DTS (Decode Time Stamp), and these may vary if b frames are used.
You may need to tell the Wowza server to packetized based on the DTS value by adding the following property to your application and setting it to false.
The other cause may be if the encoder is not sending streams with synchronized timestamps or the video and audio packets are out of sequence for one or more of the streams.
If the encoding profile is main or higher then there could be B frames in one or more of the streams that could affect the PTS values. It there are no B frames then the PTS and DTS values for each frame should be identical.
The main thing to look at is to see if encoder is sending matching timecodes at the same time for each rendition. If each rendition has completely different timecodes then you will have problems with switching. If they have identical timecodes but one or more renditions is behind the others then you may have problems if it gets too far behind. This would show up in the chunklist requests where each rendition would return chunklists with different segment numbers.