private void Events_ConnectionClosed(RemotingDbConnection connection) { var id = GetOrThrowConnectionId(connection); ConnectionIds.TryRemove(connection, out _); CloseConnection(id); }