I'm still new to the whole twisted way of doing things, but it sounds very sensible. :)
Could you suggest a class to start studying from ?
/tax
>I guess my focus is right when it comes to redirecting clients.Depends what "OK" is supposed to mean.
>
>Im hooking into
>
>DNSDatagramProtocol.writeMessage(self, message, address):
>
>And I guess thats OK?
>I don't know why you should have to do that.
>But when it comes to bogus domains, I guess i could use:
>
>DNSServerFactory.gotResolverError(self, failure, protocol, message,
>address):
>My problem is now how I construct a redirect package and channel itIt would probably be a lot easier and more robust to implement a
>back to
>the client.
>
>Do you think that is a sensible approach? -and do you hava a pointer on
>how
>to find the associated client.
completely new custom resolver that *wraps* an existing resolver, rather
than trying to extend an existing resolver via a subclass. This removes
many irrelevant implementation details from consideration (such as
writeMessage and gotResolverError) and gives you an obvious place to put
your redirect logic - in an errback on the Deferred returned by one of
the wrapped resolver's lookup/query methods.
Jean-Paul
_______________________________________________
Twisted-Python mailing list
Twisted-Python@twistedmatrix.com
http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python