watchtower/wtdb: create embedded ClientSessionBody

This commit splits out the portions of the ClientSession into an
embedded ClientSessionBody, since these fields will be serialized
together on-disk.
This commit is contained in:
Conner Fromknecht committed 2019-05-23 20:47:49 -07:00
1 parent 5ad9530502
commit 1db9bf2fd4
6 files changed
+59 -37

No files matched your search

+1 -2
View File
@@ -126,8 +126,7 @@ func (t *backupTask) inputs() map[wire.OutPoint]input.Input {
// SessionInfo's policy. If no error is returned, the task has been bound to the
// session and can be queued to upload to the tower. Otherwise, the bind failed
// and should be rescheduled with a different session.
func (t *backupTask) bindSession(session *wtdb.ClientSession) error {
func (t *backupTask) bindSession(session *wtdb.ClientSessionBody) error {
// First we'll begin by deriving a weight estimate for the justice
// transaction. The final weight can be different depending on whether
// the watchtower is taking a reward.