This repository has been archived by the owner on Feb 24, 2021. It is now read-only.
Fenrir
Pre-release
Pre-release
Fenrir - 2020-12-18
Support for on-chain progression of app channels.
Added
- On-chain progression: The channel watcher is now interactive and informs the
client when a channel has been registered on-chain. If the channel has a
defined app logic with a valid state transition logic, clients can
individually progress the app state on-chain according to the defined state
transition logic by callingProgressBy
on the channel object. - Settle with sub-channel disputes: Ledger channels can now be settled with
funds locked in disputed sub-channels if the corresponding sub-channels have
been registered and the disputes have been resolved on-chain.
Changed
- The channel watcher logic changed. The channel watcher now takes as input an
event handler which gets notified about on-chain channel events. Before, the
watcher automatically settled a channel in case of a dispute. Now, the watcher
will automatically detect if an old state has been registered, refute with the
most recent one, and notify the user. If the channel has a defined application
logic, the user can further progress the channel on-chain. It is within the
responsibility of the framework user to finally settle the channel and
withdraw the funds. - The channel settling logic changed. Before, a call to
Settle
on a channel
object automatically registered the channel, concluded it, and withdrew the
funds. Now, to accomodate on-chain progression functionality, the user must
callRegister
independetly before being able to settle the channel.
Afterwards, for app channels, the user has the opportunity to progress the
channel state on-chain by callingProgressBy
. Finally, the user can settle
the channel by callingSettle
. ContractBackend.NewTransactor
now sets the context onTransactOpts
.
Furthermore, parametervalue
has been removed.
Fixed
- Persistence: Sub-channels are now persisted and restored properly.