]> git.bitcoin.ninja Git - rust-lightning/commit
Allow events processing without holding `total_consistency_lock`
authorElias Rohrer <ero@tnull.de>
Fri, 21 Apr 2023 16:02:54 +0000 (18:02 +0200)
committerElias Rohrer <ero@tnull.de>
Fri, 21 Apr 2023 16:02:54 +0000 (18:02 +0200)
commitf2453b7fffd3ca79cac92803c8c6c99cea970e51
tree099d702030ecaef3c04479cff1556689f2001daf
parentb5468226cce7bfb2e754b7b46d3bf7137e79562e
Allow events processing without holding `total_consistency_lock`

Unfortunately, the RAII types used by `RwLock` are not `Send`, which is
why they can't be held over `await` boundaries. In order to allow
asynchronous events processing in multi-threaded environments, we here
allow to process events without holding the `total_consistency_lock`.
lightning-background-processor/src/lib.rs
lightning/src/ln/channelmanager.rs