val listen : ?max_connections:int -> ?backlog:int -> ?buffer_age_limit:Async.Writer.buffer_age_limit -> ?advance_clock_before_tls_negotiation: (Core.read_write Async.Time_source.T1.t * Core.Time_ns.Span.t) -> Config.Server.t -> ( 'socket, 'addr ) Async.Tcp.Where_to_listen.t -> on_handler_error:[ `Call of 'socket -> exn -> unit | `Ignore | `Raise ] -> f: ( 'socket -> Connection.t -> Async.Reader.t -> Async.Writer.t -> unit Async.Deferred.t ) -> ( 'socket, 'addr ) Async.Tcp.Server.t Async.Deferred.t
val with_connection : ?interrupt:unit Async.Deferred.t -> ?timeout:Core.Time_ns.Span.t -> Config.Client.t -> 'socket Async.Tcp.Where_to_connect.t -> f: ( ( [ `Active ], 'socket ) Async.Socket.t -> Connection.t -> Async.Reader.t -> Async.Writer.t -> 'res Async.Deferred.t ) -> time_source:Async.Time_source.t -> 'res Async.Deferred.t