class Async::HTTP::Client
def connect(connection_limit: nil)
def connect(connection_limit: nil) Pool.new(connection_limit) do Async.logger.debug(self) {"Making connection to #{@endpoint.inspect}"} @endpoint.each do |endpoint| peer = endpoint.connect peer.setsockopt(Socket::IPPROTO_TCP, Socket::TCP_NODELAY, 1) stream = IO::Stream.new(peer) break @protocol.client(stream) end end end