Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shared ownership of NetworkGraph #1149

Merged
merged 2 commits into from Nov 1, 2021

Conversation

jkczyz
Copy link
Contributor

@jkczyz jkczyz commented Nov 1, 2021

NetworkGraph is owned by NetGraphMsgHandler, but DefaultRouter requires a reference to it. Introduce shared ownership to NetGraphMsgHandler so that both can use the same NetworkGraph. Remove pub visibility of NetGraphMsgHandler's reference now that it doesn't have to be accessed in this manner.

NetworkGraph is owned by NetGraphMsgHandler, but DefaultRouter requires
a reference to it. Introduce shared ownership to NetGraphMsgHandler so
that both can use the same NetworkGraph.
Since NetworkGraph has shared ownership, NetGraphMsgHandler does not
need to expose its field.
@codecov
Copy link

codecov bot commented Nov 1, 2021

Codecov Report

Merging #1149 (c4d7b9d) into main (c53048a) will increase coverage by 0.24%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1149      +/-   ##
==========================================
+ Coverage   90.21%   90.46%   +0.24%     
==========================================
  Files          70       70              
  Lines       36201    37946    +1745     
==========================================
+ Hits        32660    34327    +1667     
- Misses       3541     3619      +78     
Impacted Files Coverage Δ
lightning/src/ln/peer_handler.rs 49.66% <ø> (ø)
lightning-background-processor/src/lib.rs 94.95% <100.00%> (-0.03%) ⬇️
lightning-invoice/src/utils.rs 83.48% <100.00%> (+8.95%) ⬆️
lightning/src/ln/channelmanager.rs 87.06% <100.00%> (+3.24%) ⬆️
lightning/src/ln/functional_test_utils.rs 95.13% <100.00%> (-0.01%) ⬇️
lightning/src/ln/functional_tests.rs 97.29% <100.00%> (-0.02%) ⬇️
lightning/src/ln/shutdown_tests.rs 95.87% <100.00%> (-0.02%) ⬇️
lightning/src/routing/network_graph.rs 91.35% <100.00%> (+0.04%) ⬆️
lightning/src/routing/router.rs 91.98% <100.00%> (ø)
... and 3 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c53048a...c4d7b9d. Read the comment docs.

@TheBlueMatt TheBlueMatt added this to the 0.0.103 milestone Nov 1, 2021
@TheBlueMatt TheBlueMatt merged commit 6e86776 into lightningdevkit:main Nov 1, 2021
Sign up for free to 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.

None yet

3 participants