HTTP and Listener improvements and bugfixes (#17)

* listener revamp

* improvements to conn lifetimes
This commit is contained in:
Pat Whittingslow
2026-01-11 10:29:16 -03:00
committed by GitHub
parent be194ad7ea
commit 151133dfb4
8 changed files with 145 additions and 77 deletions
+3 -2
View File
@@ -41,7 +41,8 @@ func TestTCPListener_ConcurrentEcho(t *testing.T) {
tcpPool, err := NewTCPPool(TCPPoolConfig{
PoolSize: numClients,
QueueSize: 4,
BufferSize: 512,
TxBufSize: 512,
RxBufSize: 512,
EstablishedTimeout: 5 * time.Second,
ClosingTimeout: 5 * time.Second,
})
@@ -198,7 +199,7 @@ func echoServer(ctx context.Context, listener *tcp.Listener) {
continue
}
conn, err := listener.TryAccept()
conn, _, err := listener.TryAccept()
if err != nil || conn == nil {
continue
}