mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-10-11 11:03:18 +02:00
sqldb: define schemas for all graph node tables
In this commit, the various SQL schemas required to store graph node related data is defined. Specifically, the following tables are defined: - nodes - node_extra_types - node_features - node_addresses
This commit is contained in:
@@ -102,3 +102,31 @@ type MigrationTracker struct {
|
||||
Version int32
|
||||
MigrationTime time.Time
|
||||
}
|
||||
|
||||
type Node struct {
|
||||
ID int64
|
||||
Version int16
|
||||
PubKey []byte
|
||||
Alias sql.NullString
|
||||
LastUpdate sql.NullInt64
|
||||
Color sql.NullString
|
||||
Signature []byte
|
||||
}
|
||||
|
||||
type NodeAddress struct {
|
||||
NodeID int64
|
||||
Type int16
|
||||
Position int32
|
||||
Address string
|
||||
}
|
||||
|
||||
type NodeExtraType struct {
|
||||
NodeID int64
|
||||
Type int64
|
||||
Value []byte
|
||||
}
|
||||
|
||||
type NodeFeature struct {
|
||||
NodeID int64
|
||||
FeatureBit int32
|
||||
}
|
||||
|
Reference in New Issue
Block a user