The Photon Forum
is Closed Permanently.

After many dedicated years of service, we have made the decision to retire our Forum and switch to read-only: we´ve saved the best to last! Your search result can be found below. Plus, we offer support via these channels:

Try Our
Documentation

Please check if you can find an answer in our extensive documentation on PUN.

Join Us
on Discord

Meet and talk to our staff and the entire Photon-Community via Discord.

Read More on
Stack Overflow

Find more information on Stack Overflow (for Circle members only).

Write Us
an E-Mail

Feel free to send your question directly to our developers.

Does the server or the client initiate connections?

blackdeng
2019-02-12 11:49:57

In our institute, UDP is not allowed, only outgoing TCP connections are allowed. That is to say, if we are a client, we can initiate a connection to the server, and from then return traffic is allowed, but the server cannot initiate a connection to our client. I have set the protocol to TCP in PhotonServerSettings, but because it's an inter-institutional application, we want to make sure theoretically it will work before we bother the other side to have a test.

So just to confirm, who initiates the connections? From the ports list I see a few ports are used for different server:
843 Flash/Unity Policy (TCP)
4530 Client to Master Server (TCP)
4531 Client to Game Server (TCP)
4533 Client to Name server (TCP)

Are they all initiated by the client?
Besides, are the events sent using TCP once I set the PhotonServerSettings to TCP? I'm asking because in the RaiseEvent callback it seems we can only set reliable UDP or unreliable UDP.

Thanks.

Comments

JohnTube
2019-02-12 13:09:49

Hi @blackdeng,

Thank you for choosing Photon!

The client always initiates connections to all servers yes.
If TCP is used then everything will be sent using TCP including RaiseEvent commands.
With TCP everything is reliable, you can ignore the reliable setting as it's for UDP only.
You don't need 843 port.

blackdeng
2019-02-12 13:53:18

@JohnTube wrote:

Hi @blackdeng,

Thank you for choosing Photon!

The client always initiates connections to all servers yes.
If TCP is used then everything will be sent using TCP including RaiseEvent commands.
With TCP everything is reliable, you can ignore the reliable setting as it's for UDP only.
You don't need 843 port.

Thanks @JohnTube , very helpful!

Back to top