Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrUninitializedDB signals that top-level buckets for the database // have not been initialized. ErrUninitializedDB = errors.New("db not initialized") // ErrCorruptChanDetails signals that the clients channel detail's // on-disk structure deviates from what is expected. ErrCorruptChanDetails = errors.New("channel details corrupted") )
Functions ¶
func MigrateChannelIDIndex ¶
MigrateChannelIDIndex adds a new channel ID index to the tower client db. This index is a mapping from db-assigned ID (a uint64 encoded using BigSize encoding) to real channel ID (32 bytes). This mapping will allow us to persist channel pointers with fewer bytes in the future.
Types ¶
type ChannelID ¶
type ChannelID [32]byte
ChannelID is a series of 32-bytes that uniquely identifies all channels within the network. The ChannelID is computed using the outpoint of the funding transaction (the txid, and output index). Given a funding output the ChannelID can be calculated by XOR'ing the big-endian serialization of the txid and the big-endian serialization of the output index, truncated to 2 bytes.
Click to show internal directories.
Click to hide internal directories.