1 write to _availableHttp2Connections
System.Net.Http (1)
System\Net\Http\SocketsHttpHandler\ConnectionPool\HttpConnectionPool.Http2.cs (1)
430_availableHttp2Connections ??= new List<Http2Connection>();
31 references to _availableHttp2Connections
System.Net.Http (31)
System\Net\Http\SocketsHttpHandler\ConnectionPool\HttpConnectionPool.cs (9)
900if (_availableHttp2Connections is not null) 902toDispose = [.. _availableHttp2Connections]; 903_associatedHttp2ConnectionCount -= _availableHttp2Connections.Count; 904_availableHttp2Connections.Clear(); 928Debug.Assert((_availableHttp2Connections?.Count ?? 0) == 0, $"Expected {nameof(_availableHttp2Connections)}.{nameof(_availableHttp2Connections.Count)} == 0"); 975if (_availableHttp2Connections is not null) 977int removed = ScavengeHttp2ConnectionList(_availableHttp2Connections, ref toDispose, nowTicks, pooledConnectionLifetime, pooledConnectionIdleTimeout);
System\Net\Http\SocketsHttpHandler\ConnectionPool\HttpConnectionPool.Http2.cs (22)
80int availableConnectionCount = _availableHttp2Connections?.Count ?? 0; 85connection = _availableHttp2Connections![availableConnectionCount - 1]; 116int index = _availableHttp2Connections.IndexOf(connection); 120_availableHttp2Connections.RemoveAt(index); 145int availableHttp2ConnectionCount = _availableHttp2Connections?.Count ?? 0; 375Debug.Assert(_availableHttp2Connections is null || !_availableHttp2Connections.Contains(connection)); 376Debug.Assert(_associatedHttp2ConnectionCount > (_availableHttp2Connections?.Count ?? 0)); 394Debug.Assert(_availableHttp2Connections is null || !_availableHttp2Connections.Contains(connection), $"HTTP2 connection already in available list"); 395Debug.Assert(_associatedHttp2ConnectionCount > (_availableHttp2Connections?.Count ?? 0), 396$"Expected _associatedHttp2ConnectionCount={_associatedHttp2ConnectionCount} > _availableHttp2Connections.Count={(_availableHttp2Connections?.Count ?? 0)}"); 418Debug.Assert((_availableHttp2Connections?.Count ?? 0) == 0, $"With {(_availableHttp2Connections?.Count ?? 0)} available HTTP2 connections, we shouldn't have a waiter."); 431_availableHttp2Connections.Add(connection); 519Debug.Assert(_availableHttp2Connections is null || !_availableHttp2Connections.Contains(connection)); 543if (_availableHttp2Connections is not null) 545Debug.Assert(_associatedHttp2ConnectionCount >= _availableHttp2Connections.Count); 547int index = _availableHttp2Connections.IndexOf(connection); 551_availableHttp2Connections.RemoveAt(index); 572localHttp2Connections = _availableHttp2Connections?.ToArray();