mirror of
https://github.com/ElementsProject/lightning.git
synced 2024-11-19 18:11:28 +01:00
9b9e830780
This will let us unify the startup and runtime-started infrastructure. Note that there are two kinds of notifications: 1. Starting a single plugin (i.e. `plugin start`) 2. Starting multiple plugins (i.e. `plugin rescan` or `plugin startdir`). In the latter case, we want the command to complete only once *all* the plugins are dead/finished. We also call plugin_kill() in all cases, and correctly return afterwards (it matters once we use the same paths for dynamic plugins, which don't cause a fatal error if they don't startup). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
19 lines
605 B
C
19 lines
605 B
C
#ifndef LIGHTNING_LIGHTNINGD_PLUGIN_CONTROL_H
|
|
#define LIGHTNING_LIGHTNINGD_PLUGIN_CONTROL_H
|
|
#include "config.h"
|
|
#include <lightningd/plugin.h>
|
|
|
|
/* Plugin startup failed */
|
|
struct command_result *plugin_cmd_killed(struct command *cmd,
|
|
struct plugin *plugin, const char *msg);
|
|
|
|
/* Plugin startup succeeded */
|
|
struct command_result *plugin_cmd_succeeded(struct command *cmd,
|
|
struct plugin *plugin);
|
|
|
|
/* All plugins succeeded/failed */
|
|
struct command_result *plugin_cmd_all_complete(struct plugins *plugins,
|
|
struct command *cmd);
|
|
|
|
#endif /* LIGHTNING_LIGHTNINGD_PLUGIN_CONTROL_H */
|