Commit graph

3 commits

Author SHA1 Message Date
Elle Mouton
01ba2661db
watchtower/wtdb: start populating channel max commitment
In this commit, a new key, cChanMaxCommitmentHeight, is added to the
channel details bucket. This key will hold the highest commitment number
that the tower has been handed for this channel. In this commit, we
start writing to it in the two places where a backup is first persisted
in the tower client db: 1) CommitUpdate and 2) in the Queue's `addItem`
method. The logic for both 1 & 2 is tested in the next commit which adds
a DB helper that allows us to read the new field.

A follow up commit will do a migration to back-fill the new field.
2023-11-27 20:01:17 +02:00
Elle Mouton
5cc7438d33
watchtower/wtdb: add bolt db impl of Queue
This commit adds a new generic DiskQueueDB type which is an
bbolt implementation of the Queue interface.
2023-05-16 10:57:49 +02:00
Elle Mouton
a946715b7e
watchtower/wtdb: add a generic Queue interface 2023-05-16 10:57:49 +02:00