Function mhost::lookup::multiple_lookup
[−]
[src]
pub fn multiple_lookup<T: Into<SocketAddr>>(
loop_handle: &Handle,
query: Query,
servers: Vec<T>
) -> Box<Future<Item = Vec<Result<Response>>, Error = ()>>
Lookup a domain name against a set of DNS servers
The return type is special here. Future<Item=Vec<Result<DnsResponse>>, Error=()
. This Future is not supposed to fail
in future::futures::Err
way, but rather propagate errors as part of the Future's successful execution.
In this way, this function does not abort when single lookups fail, but wait for all queries / Futures to finish.
The library user than can distinguish between successful and failed lookups.