mirror of
https://github.com/lightningnetwork/lnd.git
synced 2024-11-19 01:43:16 +01:00
1a8f094503
This commits adds the devrpc package which implements a subserver that adds clean separation for RPC calls useful for development and debugging. This subserver is only compiled in if the dev tag is set. Furthermore the commit adds the devrpc.ImportGraph call which can import a graph dump obtained from another node by calling DescribeGraph. Since the graph dump does not include the auth proofs, the imported channels will be considered private.
20 lines
556 B
Go
20 lines
556 B
Go
//go:build dev
|
|
// +build dev
|
|
|
|
package devrpc
|
|
|
|
import (
|
|
"github.com/btcsuite/btcd/chaincfg"
|
|
"github.com/lightningnetwork/lnd/channeldb"
|
|
)
|
|
|
|
// Config is the primary configuration struct for the DEV RPC server. It
|
|
// contains all the items required for the rpc server to carry out its
|
|
// duties. Any fields with struct tags are meant to be parsed as normal
|
|
// configuration options, while if able to be populated, the latter fields MUST
|
|
// also be specified.
|
|
type Config struct {
|
|
ActiveNetParams *chaincfg.Params
|
|
GraphDB *channeldb.ChannelGraph
|
|
}
|