-
Notifications
You must be signed in to change notification settings - Fork 33
Description
#11 already mentioned this, however, a large part of the issue is more of static EIDs management. I'm creating this one for the Get Routing Table implementation.
I would like to discuss some of the side effects that we want this method to do, other than returning the routing table to D-Bus:
- Add the routes to kernel: The received table should be added to the kernel routing table (
RTM_NEWROUTE). - Add to D-Bus:
mctpdshould create the D-Bus objects for the peers, set.DegradedtoTrueand request recovery to query the peers' properties.
Those effect might not be desirable for some applications that just want to know the routing table, like the one to only print the whole topology of the network. We might want to add a Publish argument to the method, to toggle the behaviour.
When Publish is true, I think we might only want to wait for the routing table response itself and the result of adding the endpoint to D-Bus. If adding to the kernel routing table or querying the properties fails, the D-Bus object will be removed and the application interested should listen to the remove signal, similar to how the health polling system works.
mctpd will also need to track the origin of the added objects, so as to remove the peers when the origin is removed.
I would like to know what everyone thinks on this, and also if I missed any considerations for the implementation.