mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-23 00:54:20 +01:00
plugin: Add a list of notification topics registered by plugin
We will eventually start emitting and dispatching custom notifications from plugins just like we dispatch internal notifications. In order to get reasonable error messages we need to make sure that the topics plugins are asking for were correctly registered. When doing this we don't really care about whether the plugin that registered the notification is still alive or not (it might have died, but subscribers should stay up and running), so we keep a list of all topics attached to the `struct plugins` which gathers global plugin information.
This commit is contained in:
committed by
Rusty Russell
parent
29155c2fe8
commit
083b41f090
@@ -128,6 +128,10 @@ struct plugins {
|
||||
/* Whether builtin plugins should be overridden as unimportant. */
|
||||
bool dev_builtin_plugins_unimportant;
|
||||
#endif /* DEVELOPER */
|
||||
|
||||
/* Notification topics that plugins have registered with us
|
||||
* and that other plugins may subscribe to. */
|
||||
const char **notification_topics;
|
||||
};
|
||||
|
||||
/* The value of a plugin option, which can have different types.
|
||||
|
||||
Reference in New Issue
Block a user