watchtower: add ListClosableSessions method
This commit adds a new ListClosableSessions method to the tower client DB. This method will return a map of sessionIDs to block heights. The IDs belong to sessions that are considered closable and the block heights are the block height at which the last associated channel for the session was closed in.
This commit is contained in:
4 files changed
+75
-1
No files matched your search
@@ -95,6 +95,10 @@ type DB interface {
|
||||
MarkChannelClosed(chanID lnwire.ChannelID, blockHeight uint32) (
|
||||
[]wtdb.SessionID, error)
|
||||
|
||||
// ListClosableSessions fetches and returns the IDs for all sessions
|
||||
// marked as closable.
|
||||
ListClosableSessions() (map[wtdb.SessionID]uint32, error)
|
||||
|
||||
// RegisterChannel registers a channel for use within the client
|
||||
// database. For now, all that is stored in the channel summary is the
|
||||
// sweep pkscript that we'd like any tower sweeps to pay into. In the
|
||||
|
||||
Reference in new issue
Block a user