5 Replies Latest reply on Feb 2, 2011 10:00 AM by nimigeanu





      you cannot get more than maxPeerConnections connected stream at a time.


      I would like to know what NetStatusEvent (if there is one) you get when you try to establish a connection when the maximum is already reached?


      If there is no NetStatusEvent for that, is there anyway to know from the connecting side that your attrempt failed because there is alreayd too many simultaneous connection?


      Thank you.

        • 1. Re: maxPeerConnections
          oohazard7 Level 1

          Hi again, to bump the question and clarify it :


          for my application I will leave the default NetConnection.maxPeerConnections to 8.

          And I want to know how can a suscriber can know if the publisher has already reached the maxPeerConnections ?


          Imagine, the suscriber create a recvStream and connect it to the publisher. Do the suscriber get some special NetStatusEvent code to know that it has been rejected because of the maxPeerConnections limit, or do the publisher has  to check the maxPeerConnectiosn and do somethign to let the potential suscriber know about ?


          Thanks for your help

          • 2. Re: maxPeerConnections
            oohazard7 Level 1

            any ideas?

            • 3. Re: maxPeerConnections
              nimigeanu Level 2


              Just noticed, NetConnection.maxPeerConnections does not seem to make any difference.

              Set it to 2, 10 and default(should be 8) and each time been able to connect about 18 peers, as read by NetGroup.neighborCount.

              Could this be a bug or am I misunderstanding the purpose of maxPeerConnections ?



              • 4. Re: maxPeerConnections
                Michael Thornburgh Adobe Employee

                maxPeerConnections is only for 1:1 NetStreams (a NetStream created with new NetStream(netConnection, NetStream.DIRECT_CONNECTIONS)).  it's a safety limit so that a large number of peers can't connect to you to play a stream you're publishing for DIRECT_CONNECTIONS, since you'd send a separate copy to each subscriber in that mode.


                maxPeerConnections isn't used for RTMFP Groups.

                • 5. Re: maxPeerConnections
                  nimigeanu Level 2

                  Thank you Michael, this makes more sense now.