Question
FMS3 from FMS2 Problems
We just made an upgrade from FMS2 to FMS3 and the videos have
stopped streaming. The connection to the FMS server is good, but
I'm getting an error now that I can't find the video stream?
Nothing has changed but the FMS server upgrade. Is there a common
issue when upgrading that I don't know about? I have a test video
sitting in the _definist_ folder for testing and my as3 code looks
like this:
connection = new NetConnection();
connection.client = this;
connection.addEventListener(NetStatusEvent.NET_STATUS, netStatusHandler);
connection.addEventListener(SecurityErrorEvent.SECURITY_ERROR, securityErrorHandler);
connection.addEventListener(AsyncErrorEvent.ASYNC_ERROR, asyncErrorHandler);
connection.connect(targetURI);
function netStatusHandler(event:NetStatusEvent):void){
switch (event.info.code) {
case "NetConnection.Connect.Success" : streamVideo();
break;
}
function streamVideo(){
ns = new NetStream(connection);
ns.client = myClient;
ns.addEventListener(NetStatusEvent.NET_STATUS, netStatusHandler);
ns.addEventListener(AsyncErrorEvent.ASYNC_ERROR, asyncErrorHandler);
vid.attachNetStream(ns);
ns.play(String(playerData.videoName),0,-1);
ns.bufferTime = _startBufferTime;
myClient.onMetaData = metaDataHandler;
}
public function onBWDone():void{} <----- I was getting a can't find onBWDone error when I switched to FMS3 so I added this line: connection.client = this; and this onBWDone method you see here,.. and removed this line: NetConnection.defaultObjectEncoding = flash.net.ObjectEncoding.AMF0;. I don't know if this has anything to do with it?
Thanks
Drew Text
connection = new NetConnection();
connection.client = this;
connection.addEventListener(NetStatusEvent.NET_STATUS, netStatusHandler);
connection.addEventListener(SecurityErrorEvent.SECURITY_ERROR, securityErrorHandler);
connection.addEventListener(AsyncErrorEvent.ASYNC_ERROR, asyncErrorHandler);
connection.connect(targetURI);
function netStatusHandler(event:NetStatusEvent):void){
switch (event.info.code) {
case "NetConnection.Connect.Success" : streamVideo();
break;
}
function streamVideo(){
ns = new NetStream(connection);
ns.client = myClient;
ns.addEventListener(NetStatusEvent.NET_STATUS, netStatusHandler);
ns.addEventListener(AsyncErrorEvent.ASYNC_ERROR, asyncErrorHandler);
vid.attachNetStream(ns);
ns.play(String(playerData.videoName),0,-1);
ns.bufferTime = _startBufferTime;
myClient.onMetaData = metaDataHandler;
}
public function onBWDone():void{} <----- I was getting a can't find onBWDone error when I switched to FMS3 so I added this line: connection.client = this; and this onBWDone method you see here,.. and removed this line: NetConnection.defaultObjectEncoding = flash.net.ObjectEncoding.AMF0;. I don't know if this has anything to do with it?
Thanks
Drew Text
