Merge pull request #5642 from guggero/in-memory-graph

In-memory graph cache for faster pathfinding
This commit is contained in:
Oliver Gugger authored and GitHub committed 2021-10-04 11:20:23 +02:00
commit 692ea25295
65 files changed
+2595 -1171

No files matched your search

+1 -1
View File
@@ -56,7 +56,7 @@ type AddInvoiceConfig struct {
// ChanDB is a global boltdb instance which is needed to access the
// channel graph.
ChanDB *channeldb.DB
ChanDB *channeldb.ChannelStateDB
// Graph holds a reference to the ChannelGraph database.
Graph *channeldb.ChannelGraph
+1 -1
View File
@@ -51,7 +51,7 @@ type Config struct {
// ChanStateDB is a possibly replicated db instance which contains the
// channel state
ChanStateDB *channeldb.DB
ChanStateDB *channeldb.ChannelStateDB
// GenInvoiceFeatures returns a feature containing feature bits that
// should be advertised on freshly generated invoices.
+1 -1
View File
@@ -55,7 +55,7 @@ type RouterBackend struct {
FindRoute func(source, target route.Vertex,
amt lnwire.MilliSatoshi, restrictions *routing.RestrictParams,
destCustomRecords record.CustomSet,
routeHints map[route.Vertex][]*channeldb.ChannelEdgePolicy,
routeHints map[route.Vertex][]*channeldb.CachedEdgePolicy,
finalExpiry uint16) (*route.Route, error)
MissionControl MissionControl
+1 -1
View File
@@ -126,7 +126,7 @@ func testQueryRoutes(t *testing.T, useMissionControl bool, useMsat bool,
findRoute := func(source, target route.Vertex,
amt lnwire.MilliSatoshi, restrictions *routing.RestrictParams,
_ record.CustomSet,
routeHints map[route.Vertex][]*channeldb.ChannelEdgePolicy,
routeHints map[route.Vertex][]*channeldb.CachedEdgePolicy,
finalExpiry uint16) (*route.Route, error) {
if int64(amt) != amtSat*1000 {