package conduit-lwt-unix

  1. Overview
  2. Docs
A network connection establishment library for Lwt_unix

Install

dune-project
 Dependency

Authors

Maintainers

Sources

conduit-8.0.0.tbz
sha256=0a63d910865b5473893a170cda51f61388f488ecf4c4b2ed7fe9ec4e2cf66f61
sha512=63c73616c5a4a6436aa9a1c8d2771d70e15789c639aaec6b9a95622aee0b364f18278e88ed769fbae84fefb817bef1c9c81fe41e969f03db99612295a159b536

doc/conduit-lwt-unix/Resolver_lwt_unix/index.html

Module Resolver_lwt_unixSource

Resolve URIs to endpoints using Unix system calls

Prebuilt resolvers

Use the Unix system name resolver via getaddrinfo and getservbyname

Sourceval static : (string, Conduit.endp) Hashtbl.t -> Resolver_lwt.t

static hosts constructs a resolver that looks up any resolution requests from the static hosts hashtable instead of using the system resolver.

Rewrite and service functions

These can be used to assemble your own resolvers if the prebuilt ones are not quite what you need.

Sourceval system_service : string -> Resolver_lwt.svc option Lwt.t

Perform service lookup using getservbyname

Sourceval static_service : string -> Resolver_lwt.svc option Lwt.t

Perform service lookup using the builtin Uri_services module

Sourceval system_resolver : Resolver_lwt.rewrite_fn

Rewrite function that uses the system_service and static_service to resolve hosts

Debugging Hooks

Sourceval debug : bool ref

If debug is true, the builtin resolvers will output their resolution responses via the debug_print function. The default value of debug is true if the CONDUIT_DEBUG environment variable is set, and false otherwise.

Sourceval debug_print : ((string -> string -> string -> string -> unit, out_channel, unit) format -> string -> string -> string -> string -> unit) ref

debug_print is called by the debug functions to output the results of resolution. Defaults to Printf.eprintf to go to the standard error.