[Kea-users] Bug in the leases4_committed hook ?

Hreiðar Jóelsson hreidar.joelsson at gagnaveita.is
Fri Sep 21 12:55:17 UTC 2018


Hi, I'm any of you had problems with the leases4_committed hook? I'm getting strange errors using it. If I simply try to log some message from it I'm getting the following error.

2018-09-21 10:57:04.843 ERROR [kea-dhcp4.callouts/1442] HOOKS_CALLOUT_EXCEPTION exception thrown by callout on hook 1 registered by library with index leases4_committed (callout address 0x7f8803d131c3): boost::bad_any_cast: failed conversion using boost::any_cast (callout duration: 0.063 ms)

Here is the hook code I'm currently using:

int leases4_committed(CalloutHandle& handle) {
    Pkt4Ptr query;
    Lease4Ptr leases, deleted_leases;
    handle.getArgument("query4", query);
    handle.getArgument("leases4", leases);
    handle.getArgument("deleted_leases4", deleted_leases);

    LOG_DEBUG(my_logger,50, "I'm at leases4_committed hook");

    return 0;
}

p.s I'm using this logger in other hooks in the same file without any problems.


Regards, Hreiðar.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.isc.org/pipermail/kea-users/attachments/20180921/e6a9412a/attachment.htm>


More information about the Kea-users mailing list