multiple calls to server

Options
Sergiy
Sergiy
edited June 2012 in Photon Server
Hi

Please, consider following scenario:
1. client connects to Photon server.
2. client calls JoinLobby
3. after server response client is calling some operations, etc... that does not matter.

Now, the situation:
1. client connects to Photon and gets ConnectionId = 1
2. during 5 seconds nothing is happenning, so server disconnects client
3. same client connects to server and gets ConnectionId = 2
4. again, nothing arrives during 5 seconds, so client gets disconnected.

so far, it indicates only that client has very poor internet connection. everything is OK.
now....
5. same client connects to Photon and gets ConnectionId = 3
6. client calls JoinLobby
7. client calls JoinLobby
8. client calls JoinLobby
exactly, client calls JoinLobby 3 times at once. I was guessing that maybe 2 extra JoinLobby calls are from old connections, but all calls have ConnectionID=3. How this can be? can it be that older calls were cached somehow and, as soon as internet connection started working, all 3 of them were sent at once? with the same ConnectionId?
client is Flash application and using AS RC4 protocol. We've looked through its code and there is only one call to JoinLobby. It cannot be called more then once. I'm stuck... :(

Comments

  • Tobias
    Options
    This might be a problem with the Flash SDK. Internally, clients queue outgoing operations and send them when possible.
    This queue maybe isn't cleared on disconnect, which would explain the number of joinlobby operations called.
    We will have to take a look.

    Aside from that:
    The 3 joinlobby calls should not be a problem for either server or client. The operation doesn't do much, so the state should be ok despite this.
    Am I missing a breaking issue?
  • Sergiy
    Options
    You are right, that's not a big issue. That might even be a plus, as now all of us can recall client-side code line-by-line in the middle of the night :) However, we are looking forward to Flash SDK RC5 release. please please build it ASAP :)
  • Tobias
    Options
    I posted an intermediate library without update of the loadbalancing part (which we are working on once more).
    This might help in your case:
    viewtopic.php?f=9&t=1705