[Olsr-dev] new callback API in the master branch (<- heads up plugin developers)

L. Aaron Kaplan (spam-protected)
Sat Feb 12 23:43:21 CET 2011

Hash: SHA1


Henning was working on a new callback API for use within OLSR (in the master branch!).
The idea behind it is, that often plugins and the core of olsrd have little way of informing each other about changes to central data structures. The same situation applies to plugins communicating between each other: up until now there was no formal way for that.

Here is an example (maybe it is a bit constructed, but I hope you get the idea):
let's assume a neighbor link disappeared, maybe there could be a plugin which counts how many neighbors are active and if the last one disappears, it will send out some ATA commands on the serial link which in turn send an SMS and puts the router into a sleep state for 5 minutes in order to save battery power. No point in running when you don't have any neighbors anymore. In this case, the nhdp neighbor discovery code (in OLSR core) informed this plugin (and all other callbacks listening on these types of events) about the deletion of a neighbor link.

I documented the API a little bit (it is a mere start).
Please take a look at README-callbacks in the master branch. Feedback welcome. In case something is not clear, post it here please and I will try to clarify the documentation.

Big cudos as always go to Henning for putting so much time and energy into coding such nice APIs.


Version: GnuPG v2.0.9 (Darwin)


More information about the Olsr-dev mailing list