-
Notifications
You must be signed in to change notification settings - Fork 1k
Open
Labels
BugUsed to tag confirmed bugsUsed to tag confirmed bugsUnder InvestigationThe problem mentioned, or possible improvement, is under investigationThe problem mentioned, or possible improvement, is under investigation
Description
Describe the bug
In my opinion, the issue that #4244 tried to fix wasn’t actually resolved — it was just hidden. As @Jim8y mentioned:
- Peer.OnTcpConnected always assumed both the Akka Tcp.Connected envelope and
the actor’s Config field were ready. In practice that’s not guaranteed:- Akka can deliver a Tcp.Connected message whose RemoteAddress is null when
the socket aborts during the OS handshake. The old code immediately cast
that to IPEndPoint and called .UnMap(), so the very first dereference blew
up with a NullReferenceException.- There’s also a race between wiring up ChannelsConfig (handled in OnStart)
and the inflight connect that triggers Tcp.Connected. When the connect
arrived before OnStart ran, Config was still null, and the subsequent
Config.MaxConnections… lookup faulted.
We should try to find the root cause of the problem instead of hiding it.
Metadata
Metadata
Assignees
Labels
BugUsed to tag confirmed bugsUsed to tag confirmed bugsUnder InvestigationThe problem mentioned, or possible improvement, is under investigationThe problem mentioned, or possible improvement, is under investigation