[Kea-users] kea-hooks question
Francis Dupont
fdupont at isc.org
Thu Sep 15 22:44:03 UTC 2016
Yusef Shaban writes:
> I am curious how the hooks lib works in kea, specifically are the user
> built hooks called asynchronously, in that, if a user hook failed it is
> non-blocking and will allow the request to be fulfilled?
=> hooks are synchronous. BTW it is a bit hard to make DHCP processing
asynchronous, e.g., you need to keep the context without creating state
and possibly memory leaks, but it is not impossible, e.g., DHCPv4 over
DHCPv6 is asynchronous on the DHCPv6 side (this is why the ISC DHCP
implementation of this (Kea follows the same model) is incompatible
with delayed ACKs). Another point is Kea is currently not multi-threaded
(again DHCPv4 over DHCPv6 is an exception because it uses 2 processes,
one managing the DHCPv6 part, the other the DHCPv4 part).
Regards
Francis Dupont <fdupont at isc.org>
PS: about your example you have a trade-off between reliable and blocking
vs not reliable and not blocking. Note DHCP itself is not reliable,
this means if you drop a request the client will retransmit, and on
the other side the reply can be lost too.
More information about the Kea-users
mailing list