1 Reply Latest reply on May 27, 2012 12:59 PM by Michael Thornburgh

    Multicast for local p2p


      For what need multycast address in local p2p?

      What kind of problems should be expected when using local p2p on scaling?

        • 1. Re: Multicast for local p2p
          Michael Thornburgh Adobe Employee

          by "local p2p" i assume you mean "serverless mode" (where you connect your NetConnection to "rtmfp:"), and using P2P multicast and the other P2P modes via NetGroup.


          under normal circumstances, a server is required for Flash peers to find each other. specifically, a server translates a peer ID to the IP addresses and UDP ports being used by that peer, and performs UDP hole punching for NAT and firewall traversal. the server can also bootstrap new members into a P2P group and repair group partitions.


          when operating without a server, group members need some other way of discovering each other. IP multicast is used for that purpose. think of it as a rendezvous point.


          this mode of peer discovery is limited to group communication; that is, NetGroup and multicast NetStreams. the IP multicast peer discovery mechanism can't be used directly for 1:1 P2P, although it can be used indirectly.


          this mode is naturally limited to a single LAN because the IP TTL/hop-limit is set to 1.


          for more information, please view my session from MAX 2011, "Advanced P2P with RTMFP: Tips and Tricks":




          regarding "scaling problems" with serverless P2P mode: the P2P discovery multicast traffic is smart and should produce a nearly constant (and small) amount of IP multicast chatter in the steady state no matter how big the group gets. in addition, each peer will generate about 2kbps of P2P traffic to O(log N) other peers for topology maintenance (meaning N * 2kbps of bandwidth and O(N log N) total P2P sessions for the whole group), plus each peer will be participating (sending and receiving) whatever actual P2P media, such as multicast and posting, is flowing through the group, which is O(N). so the scale will be limited by your LAN's switching and forwarding capacity.

          1 person found this helpful