The video streaming is starting after WebRTC clients exchanged messages with each other. The messages operation is coninued on node server which uses 1337 port and web socket. Video streaming is continued after i closed the server on 1337 port. Why ? Which ports are used by webrtc clients. The node server uses one port(1337). How can i learn or control or change these ports which are used by web rtc server and clients?
The Node.js server is only used for session start up and tear down. So, once a session is started(unless media or networking is changed) it will continue until one of the peers end it. Remember, WebRTC is a peer to peer connection.
Once the needed Ice Candidates and SDP information is exchanged for the Peer connection then there is no longer a need for the signalling server(barring any unforeseen network/media changes). One of the peers in the session(the peerconnection itself) would have to end the session and stop streaming.
Edit:
I foresee two ways of controlling the media ports in the current javascript APIs:
Here is a deeper discussion about port allocation for the media