So if you are developing a Flash Media Server (FMS) based application that by chance uses the new Dynamic Streaming capabilities of the FMS 3.5 server then it is very important that you know that the version of your server that you are connecting to is correct. This can come into play for instance if you are using a CDN provider like Level(3) or Akamai. Some servers may not be updated to the new FMS version (at the time of this post most are not). One of the less known facts about the new FMS Server 3.5 and thus in place for any additional versions in the future is it actually now provides the dot release information of the FMS server on connection. It is available on the NetStatus event object when the info.code is equal to “NetConnection.Connect.Success” and is on the event.info.data.version property – where event is the NetStatusEvent Object instance.
Some code samples for you:
//within the switch case of the NetStatus event handler:
case “NetConnection.Connect.Success”:
{
trace( “VERSION: ” + p_evt.info.data.version );
_verifyServerVersion( p_evt.info.data.version );
_initStream();
break;
}
//Method that parses out the FMS major version
function _verifyServerVersion( p_version:String ):void
{
var fmsVersion:Number = Number( p_version.split(“,”, 2).join(“.”) );
trace(“fmsVersion: ” + fmsVersion);
}
//////////////////////////////
Another valuable test is checking the Flash Player version since Dynamic Streaming requires Flash Player 10 or greater. Just because I am a nice guy here is a code snippet for that:
import flash.system.Capabilities;
public function getFlashPlayerMajorVersion():Number
{
var fpVersionStr:String = Capabilities.version;
return Number( fpVersionStr.split(” “)[1].split(“,”, 1) );
}
For more infor and goodies check out this article I wrote for Adobe Devnet: http://www.adobe.com/devnet/flashmediaserver/articles/dynstream_advanced_pt3.html
I actually do not know where the FMS version info is documented anywhere if it is so I cant provide a link to it. If someone else finds it let me know and I will update this.




