Package pyxmpp2 :: Module resolver
[hide private]

Module resolver

DNS resolever with SRV record support.

Normative reference:
Classes [hide private]
  ThreadedResolverBase
Base class for threaded resolvers.
  DumbBlockingResolver
Simple blocking resolver using only the standard Python library.
  BlockingResolver
Blocking resolver using the DNSPython package.
  ThreadedResolver
Threaded resolver implementation using the DNSPython dns.resolver module.
  _DEFAULT_RESOLVER
Blocking resolver using the DNSPython package.
Functions [hide private]
 
is_ipv6_available()
Check if IPv6 is available.
 
is_ipv4_available()
Check if IPv4 is available.
list of dns.rdtypes.IN.SRV
shuffle_srv(records)
Randomly reorder SRV records using their weights.
list of dns.rdtypes.IN.SRV
reorder_srv(records)
Reorder SRV records using their priorities and weights.
Variables [hide private]
  logger = logging.getLogger("pyxmpp2.resolver")
  HAVE_DNSPYTHON = True
Function Details [hide private]

is_ipv6_available()

 
Check if IPv6 is available.
Returns:
True when an IPv6 socket can be created.

is_ipv4_available()

 
Check if IPv4 is available.
Returns:
True when an IPv4 socket can be created.

shuffle_srv(records)

 
Randomly reorder SRV records using their weights.
Parameters:
Returns: list of dns.rdtypes.IN.SRV
reordered records.

reorder_srv(records)

 
Reorder SRV records using their priorities and weights.
Parameters:
Returns: list of dns.rdtypes.IN.SRV
reordered records.