Component Instance: dnsrv
The dnsrv component, described by the configuration
XML shown in Example 4-16 and shown in diagram form
in Figure 4-12, provides routing logic and
name resolution for
packets that are destined for a nonlocal component, in other words,
for a component that is running on another Jabber server.[7]
![]() |
<service id="dnsrv">
<host/>
<load>
<dnsrv>./dnsrv/dnsrv.so</dnsrv>
</load>
<dnsrv xmlns="jabber:config:dnsrv">
<resend service="_jabber._tcp">s2s</resend>
<resend>s2s</resend>
</dnsrv>
</service>
Once started, the component forks to spawn a child process that services the actual name resolution requests and the route determination. The component and its child communicate with a simple XML stream within which hostnames are passed to the child process in a “query” tag:
<host>update.jabber.org</host>
and answers are passed back in the form of attribute additions to the original query tag:
<host ip='208.245.212.100' to='s2s'>update.jabber.org</host>
[7] Or, for example, on a server offering another IM service (this is planned for the future).
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access
