|
| 1 | +//! Utilities that take care of tasks that (1) need to happen periodically to keep Rust-Lightning |
| 2 | +//! running properly, and (2) either can or should be run in the background. See docs for |
| 3 | +//! [`BackgroundProcessor`] for more details on the nitty-gritty. |
| 4 | +
|
| 5 | +#![deny(broken_intra_doc_links)] |
| 6 | +#![deny(missing_docs)] |
| 7 | +#![deny(unsafe_code)] |
| 8 | + |
1 | 9 | #[macro_use] extern crate lightning;
|
2 | 10 |
|
3 | 11 | use lightning::chain;
|
@@ -40,18 +48,21 @@ impl BackgroundProcessor {
|
40 | 48 | /// Start a background thread that takes care of responsibilities enumerated in the top-level
|
41 | 49 | /// documentation.
|
42 | 50 | ///
|
43 |
| - /// If `persist_manager` returns an error, then this thread will return said error (and `start()` |
44 |
| - /// will need to be called again to restart the `BackgroundProcessor`). Users should wait on |
45 |
| - /// [`thread_handle`]'s `join()` method to be able to tell if and when an error is returned, or |
46 |
| - /// implement `persist_manager` such that an error is never returned to the `BackgroundProcessor` |
| 51 | + /// If `persist_manager` returns an error, then this thread will return said error (and |
| 52 | + /// `start()` will need to be called again to restart the `BackgroundProcessor`). Users should |
| 53 | + /// wait on [`thread_handle`]'s `join()` method to be able to tell if and when an error is |
| 54 | + /// returned, or implement `persist_manager` such that an error is never returned to the |
| 55 | + /// `BackgroundProcessor` |
47 | 56 | ///
|
48 |
| - /// `persist_manager` is responsible for writing out the `ChannelManager` to disk, and/or uploading |
49 |
| - /// to one or more backup services. See [`ChannelManager::write`] for writing out a `ChannelManager`. |
50 |
| - /// See [`FilesystemPersister::persist_manager`] for Rust-Lightning's provided implementation. |
| 57 | + /// `persist_manager` is responsible for writing out the [`ChannelManager`] to disk, and/or |
| 58 | + /// uploading to one or more backup services. See [`ChannelManager::write`] for writing out a |
| 59 | + /// [`ChannelManager`]. See [`FilesystemPersister::persist_manager`] for Rust-Lightning's |
| 60 | + /// provided implementation. |
51 | 61 | ///
|
52 |
| - /// [`thread_handle`]: struct.BackgroundProcessor.html#structfield.thread_handle |
53 |
| - /// [`ChannelManager::write`]: ../lightning/ln/channelmanager/struct.ChannelManager.html#method.write |
54 |
| - /// [`FilesystemPersister::persist_manager`]: ../lightning_persister/struct.FilesystemPersister.html#impl |
| 62 | + /// [`thread_handle`]: BackgroundProcessor::thread_handle |
| 63 | + /// [`ChannelManager`]: lightning::ln::channelmanager::ChannelManager |
| 64 | + /// [`ChannelManager::write`]: lightning::ln::channelmanager::ChannelManager#impl-Writeable |
| 65 | + /// [`FilesystemPersister::persist_manager`]: lightning_persister::FilesystemPersister::persist_manager |
55 | 66 | pub fn start<PM, Signer, M, T, K, F, L>(persist_manager: PM, manager: Arc<ChannelManager<Signer, Arc<M>, Arc<T>, Arc<K>, Arc<F>, Arc<L>>>, logger: Arc<L>) -> Self
|
56 | 67 | where Signer: 'static + Sign,
|
57 | 68 | M: 'static + chain::Watch<Signer>,
|
|
0 commit comments