Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove -c option from udp endpoints in C# #3218

Merged
merged 2 commits into from
Dec 3, 2024

Conversation

bernardnormier
Copy link
Member

This PR from the undocumented "-c" option from udp endpoints in C#.

This was a server-endpoint option. For client option, the behavior is always "connect".

{
_endpoint = endpoint;
_instance = instance;
_state = connect ? StateNeedConnect : StateNotConnected;
_state = StateNotConnected;
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A server transceiver (incoming = true) starts in the StateNotConnected state and remains in that state.
A client transceiver (incoming = false) starts in the StateNeedConnect state and goes up to StateConnected. It never reaches StateNotConnected.

{
Debug.Assert(incoming);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Question: do we create a new Connection and potentially ConnectionInfo for each incoming UDP request?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at the IncomingConnectionFactory I believe there is a single udp Connection created by the factory constructor. But then caching the info object wouldn't be correct.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe we create a new connection for each request. And udp bi-dir relies on these per-request connections:

Console.Out.Write("testing udp bi-dir connection... ");

@bernardnormier bernardnormier merged commit 71b8054 into zeroc-ice:main Dec 3, 2024
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants