channeldb+graphdb: init graph DB outside of channel db

We also now use the graph DB's own optional functions. An instance of
the graph is currently still passed to the channeldb's
`CreateWithBackend` function. This will be removed in a later commit
once the two have been completely disjoint.
This commit is contained in:
Elle Mouton committed 2024-11-28 13:36:15 +02:00
1 parent 74a4b1922b
commit 1859993734
11 files changed
+98 -203

No files matched your search

+7
View File
@@ -63,6 +63,13 @@ func DefaultOptions() *Options {
// OptionModifier is a function signature for modifying the default Options.
type OptionModifier func(*Options)
// WithRejectCacheSize sets the RejectCacheSize to n.
func WithRejectCacheSize(n int) OptionModifier {
return func(o *Options) {
o.RejectCacheSize = n
}
}
// WithChannelCacheSize sets the ChannelCacheSize to n.
func WithChannelCacheSize(n int) OptionModifier {
return func(o *Options) {