5 Replies Latest reply on Jul 10, 2007 3:06 PM by Newsgroup_User

    When to use AMF and when to use RTMP??

    dimival Level 1
      Hello can someone explain the difference??

      I am using all the defaults for the configurations files (remoting and datamanagement) and my app works perfectly on development mode where everything is on localhost, but when we try it on pre-production it keeps throwing an error saying that it couldn't connect to the RTMP channel. The only thing that changes between these two modes is that on development i access everything on localhost and on pre-production we point to another server.

      I am totally clueless why this is happening, i am bit confused why data-management uses RTMP and why remoting uses AMF, so if anyone could explain it to me it would be great.

      Thanks
        • 1. Re: When to use AMF and when to use RTMP??
          Mete Atamel Level 1
          There's no special reason why one uses RTMP vs. AMF. Data management service can also use AMF and Remoting can also use RTMP. The only real requiement is that Data management service needs to be able to receive updates from the FDS/LCDS server. This can be achieved by using a channel that is capable of receiving pushed updates from the server (eg. RTMP) or a channel that is capable of polling for updates on the server (i.e. AMF-polling). Therefore, when you use AMF with Data management service, you need to have polling enabled with a polling interval.

          In terms of why AMF works but RTMP doesn't is that AMF channel uses AMF format over the HTTP protocol whereas RTMP channel uses simple TCP socket (and not HTTP). Therefore in some environments, RTMP will be blocked by the firewalls but AMF won't since it's like regular HTTP traffic. In this case, you can use AMF polling instead or use RTMPT which is new in LCDS 2.5.
          • 2. Re: When to use AMF and when to use RTMP??
            dimival Level 1
            Thanks for the explanation.

            We checked the firewall and the default RTMP port 2038 isn't blocked, so is there any other reason that will make the channel error appear???

            We are using Christopher Coenraets' Spring Factory, could that be causing the error?
            http://coenraets.org/flex-spring

            • 3. Re: When to use AMF and when to use RTMP??
              Mete Atamel Level 1
              I can't think of anything else with the limited information provided here. I'd turn debug logging on and see if there are any RTMP related errors as the LCDS (more specifically RTMP server) starts. I don't think Spring factory might be causing this but to eliminate that possibility, you can write a very simple messaging example with one Consumer and one Producer that talks to a messaging destination that uses an RTMP channel and see if you can send/receive message using RTMP.
              • 4. Re: When to use AMF and when to use RTMP??
                dimival Level 1
                So we fixed, not very sure what it was, maybe someone screwed up some config file, anyways thanks a lot for the explanation :)

                • 5. Re: When to use AMF and when to use RTMP??
                  Level 7
                  Be sure that the port configured for each RTMP channel is unique for the
                  entire server to avoid collisions. It's not uncommon for people to
                  deploy two flex.war files on a server and forget that they've used the
                  same port in both applications.