Richard,
Thanks for getting back quickly. Yes it is a very low failure rate to debug. It has been a challenge to even create it. But if you keep at it, it does occur. Do you know what the “send: size:##### ltc:0 atc:0” comment means in the log?
The recordings in my testing are fairly short. A few seconds. So they are around 100 kB. I was guessing that we are running into a race condition because playback does not work, but the FLV is properly created on the server. I have downloaded it and it plays fine in Adobe Media Player.
I just did a test and discovered that even though the FLV is created, if I try to play it back via RTMP I see the entry in the log with ltc:0 and atc:0 and I just see the first frame in the player.
A quick rundown of the code.
-
There are two NetStreams one for recording and one for playback connected to the same server.
-
On stopping the recording process I wait to make sure the recording netstream’s buffer is empty and then I close it.
-
Upon receiving “NetStream.Unpublish.Success” I initialize a new recording netstream and begin playback on the newly created video.