From 093bbf40ad6c171f89b3061a43a75e951202ea2c Mon Sep 17 00:00:00 2001 From: Olaoluwa Osuntokun Date: Sun, 20 Dec 2015 15:17:13 -0600 Subject: [PATCH] lnwallet: track some more stats in channel state --- lnwallet/channel.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lnwallet/channel.go b/lnwallet/channel.go index b16d77281..007dfb6aa 100644 --- a/lnwallet/channel.go +++ b/lnwallet/channel.go @@ -3,6 +3,7 @@ package lnwallet import ( "bytes" "sync" + "time" "li.lan/labs/plasma/chainntfs" "li.lan/labs/plasma/revocation" @@ -60,7 +61,11 @@ type OpenChannelState struct { htlcTimeout uint32 csvDelay uint32 - numUpdates uint64 + numUpdates uint64 + totalSatoshisSent uint64 + totalSatoshisReceived uint64 + // TODO(roasbeef): track fees? + creationTime time.Time } func (o *OpenChannelState) Encode(b bytes.Buffer) error {