Skip to content

Switch to async background processing and cleanup runtime handling. - #68

Merged
tnull merged 2 commits into
lightningdevkit:mainfrom
tnull:2023-03-async-background-processing
Apr 26, 2023
Merged

Switch to async background processing and cleanup runtime handling.#68
tnull merged 2 commits into
lightningdevkit:mainfrom
tnull:2023-03-async-background-processing

Conversation

@tnull

@tnulltnull commented Apr 21, 2023

Copy link
Copy Markdown
Collaborator

Fixes#37~~, currently based on lightningdevkit/rust-lightning#2199.~~
We switch to an async BP as upstream now allows us to.

We furthermore cleanup our runtime handling:
So far we instantiated a dedicated Runtime object which also held the BP. This was clunky and somewhat error-prone under different circumstances. As we now got rid of the BP object, we here remove the dedicated Runtime object and just pass around an Arc<RwLock<Option<Runtime>>> upon init, which allows us to get rid of the set/drop methods on Wallet as an added benefit.

@tnull
tnullforce-pushed the 2023-03-async-background-processing branch from a84efca to ac7dffaCompareApril 21, 2023 12:42
@tnulltnull added this to the 0.1 milestone Apr 25, 2023
Comment threadCargo.toml Outdated
Comment threadsrc/lib.rs
@tnull
tnullforce-pushed the 2023-03-async-background-processing branch from ac7dffa to f175e79CompareApril 26, 2023 08:44
@tnull

Copy link
Copy Markdown
CollaboratorAuthor

Rebased on #71.

Comment threadCargo.toml
tnulland others added 2 commits April 26, 2023 17:35
We switch to an async BP as upstream now allows us to.
So far we instantiated a dedicated `Runtime` object which also held the
BP. This was clunky and somewhat error-prone under different
circumstances. As we now got rid of the BP object, we here remove the
dedicated `Runtime` object and just pass around an
`Arc<RwLock<Option<Runtime>>>` upon init, which allows us to get rid of
the `set`/`drop` methods on `Wallet` as an added benefit.
@tnull
tnullforce-pushed the 2023-03-async-background-processing branch from f175e79 to 944a8e2CompareApril 26, 2023 15:35
@tnull

Copy link
Copy Markdown
CollaboratorAuthor

Rebased on main now that 0.0.115 is in.

@tnull
tnull merged commit 0a299f4 into lightningdevkit:mainApr 26, 2023
@tnulltnull mentioned this pull request Apr 26, 2023
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Use async event handler and background processor

2 participants

@tnull@jkczyz