OpticalTone / PeerCC-Browser

PeerCC application for browser based WebRTC
3 stars 2 forks source link

Skipping httpRequests while polling #8

Open wieczorekmichal1 opened 5 years ago

wieczorekmichal1 commented 5 years ago

Requests like sign_in, sign_out, offer, answer, candidate are skipped while running application. The reason could be long polling which initializes new requests each 20 seconds and blocks other. Also long polling adds new requests while new messagees appears, this way there are a lot of waiting polling requests after one call.

wieczorekmichal1 commented 5 years ago

The source of the problem could be in the php script. Responses from server are delivered with a lot of latency. This is not happening without the script

jamescadd commented 5 years ago

@nikolamand Is this something you have seen? cc @robin-raymond

robin-raymond commented 5 years ago

I'm not surprised. Really this should be a websocket but the issue with webrtc is that it requires https to run and there's certificate issues and the peercc server was not designed to run that way. This is another reason I think a nodejs replacement for the server would work best giving us that option. This server might run better though in the meantime as I'm not sure when we'd be able to do a nodejs websocket based version given we'd have to modify a bunch of clients and servers and it breaks compatibility with the official peercc win32/ios/android samples (although maybe those could be proxied).: https://github.com/anastasiia-zolochevska/signaling-server/blob/master/server.js