EncryptionFailedToEstablish best practices

tvhnettvhnet
edited May 2015 in DotNet
Hi,

I have several questions about StatusCode.EncryptionFailedToEstablish:

1. Which cases will client receive this status? Is it hardware-dependent or network-dependent?
2. What is the best practice to deal with it? Should I disconnect then connect and establishEncryption again?

Thanks & regards,

Comments

  • It should not happen at all. If so, it's likely an issue between client and server. Maybe platform dependent.
    You can try to disconnect and connect again but should make sure this causes no endless loop if it fails again.
    Do you run into this?
  • Thanks Tobias,

    I just consider it for design.

    And how is about StatusCode.SendError? When does it come and how to deal with it?

    Regards,
  • Afaik, you should not be able to produce a SendError anymore.
    If you do, you should track how it happened and give the user the option to try again (do a fresh connect).
  • I'll get SendError status if I send operation without sequential channel number. For example, the first operation is sent at channel 0 and the next one is sent at channel 10.

    Photon debug [ERROR]: Cannot send op: Selected channel (10)>= channelCount (2)
    OnPhotonStatusChanged: SendError
  • The channel 10 is simply not available in default case. You need to set the available channels before connecting. Set PhotonPeer.ChannelCount = 10 and you could use it.
Sign In or Register to comment.