darosior
4640d18ef0
Plugins: allow to specify plugin option type in libplugin.c, then specify it to autoclean options
6 years ago
darosior
9d34121ec5
libplugin.c: Handle command categories then set them in pay and autoclean
6 years ago
Rusty Russell
44196e7d82
libplugin: logging support.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
6 years ago
Rusty Russell
6a8cd9a016
libplugin: allow freeing in timer callback, clarify docs, allow nested timers.
1. Allow timers to be freed in their callback.
2. Clarify in header that we have to terminate our timer with timer_finished()
eventually.
3. We don't currently have plugins with more than one outstanding timer, but
it certainly would be possible, so fix in_timer to be a counter.
Suggested-by: @ZmnSCPxj
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
6 years ago
Rusty Russell
9b61c19a20
libplugin: simple timer support.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
6 years ago
Rusty Russell
c83066f8ed
libplugin: make rpc_conn a global, so we can access it from timers.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
6 years ago
Rusty Russell
688574b89c
libplugin: support options.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
6 years ago
Rusty Russell
26f60f83d5
libplugin: add deprecated_apis flag for plugins to access.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
6 years ago
Rusty Russell
a8d1588154
libplugin: provide usage in getmanifest.
Same method as lightningd: call the handlers up-front to get their param()
usage.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
6 years ago
Rusty Russell
c58a4b9b42
libplugin: put method name into command struct.
We'll need this for the usage map coming in the next patch.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
6 years ago
Rusty Russell
02436a8e6d
libplugin: mention error field in error message.
Reported-by: @cdecker
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
6 years ago
Rusty Russell
de4043a32a
plugin/libplugin: API for C plugins.
Doesn't do logging yet.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
6 years ago