Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
f5b7866
htlcswitch: define state machine for quiescence
ProofOfKeags Dec 8, 2023
2ece1fd
htlcswitch: implement stfu response
ProofOfKeags Dec 12, 2023
c9debea
lnwire: add IsChannelUpdate function to distinguish channel updates
ProofOfKeags Aug 9, 2024
44c87ef
htlcswitch: bounce packets when quiescent
ProofOfKeags Dec 12, 2023
6d30ab6
htlcswitch: drop connection if link updates after stfu
ProofOfKeags Dec 12, 2023
7a5b55a
lnwire: signal that we support quiescence
ProofOfKeags Dec 12, 2023
99f5ca4
lnrpc add new RPC 'Quiesce' to protobuf definitions
ProofOfKeags Mar 12, 2024
a085b59
lnd: implement new Quiesce RPC with link operation stub
ProofOfKeags Mar 12, 2024
70e3804
htlcswitch: add link operation for initiating quiescence
ProofOfKeags Mar 12, 2024
bca1516
lnd: finish Quiesce implementation using new link op
ProofOfKeags Mar 12, 2024
7255b73
htlcswitch: implement InitStfu link operation
ProofOfKeags Mar 12, 2024
77fd8c6
itest+lntest: add itest for Quiesce RPC method
ProofOfKeags Mar 12, 2024
4fbab45
htlcswitch: defer processRemoteAdds when quiescent
ProofOfKeags Apr 9, 2024
5906ca2
htlcswitch: add test for deferred processing remote adds when quiescent
ProofOfKeags Apr 10, 2024
48ee643
htlcswitch: implement noop quiescer
ProofOfKeags Aug 10, 2024
111c9b0
htlcswitch+peer: allow the disabling of quiescence
ProofOfKeags Aug 10, 2024
a4c49a8
htlcswitch: add quiescence timeout that is aborted by Resume
ProofOfKeags Nov 11, 2024
ac0c24a
htlcswitch: don't pass pending update counts into quiescer
ProofOfKeags Nov 12, 2024
127e4ff
htlcswitch: add logging to quiescer
ProofOfKeags Nov 12, 2024
debc43d
docs: add quiescence to release notes
ProofOfKeags Nov 18, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions docs/release-notes/release-notes-0.19.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@
signal relay was added. This signal has *no impact* on routing, and
is deployed experimentally to assist ongoing channel jamming research.

* Add initial support for [quiescence](https://github.com/lightningnetwork/lnd/pull/8270).
This is a protocol gadget required for Dynamic Commitments and Splicing that
will be added later.

## Functional Enhancements
* [Add ability](https://github.com/lightningnetwork/lnd/pull/8998) to paginate
wallet transactions.
Expand Down Expand Up @@ -216,6 +220,7 @@ The underlying functionality between those two options remain the same.
* Elle Mouton
* George Tsagkarelis
* hieblmi
* Keagan McClelland
* Oliver Gugger
* Pins
* Viktor Tigerström
Expand Down
4 changes: 4 additions & 0 deletions feature/default_sets.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@ var defaultSetDesc = setDesc{
SetNodeAnn: {}, // N
SetInvoice: {}, // 9
},
lnwire.QuiescenceOptional: {
SetInit: {}, // I
SetNodeAnn: {}, // N
},
lnwire.ShutdownAnySegwitOptional: {
SetInit: {}, // I
SetNodeAnn: {}, // N
Expand Down
6 changes: 6 additions & 0 deletions feature/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,9 @@ type Config struct {
// NoRouteBlinding unsets route blinding feature bits.
NoRouteBlinding bool

// NoQuiescence unsets quiescence feature bits.
NoQuiescence bool

// NoTaprootOverlay unsets the taproot overlay channel feature bits.
NoTaprootOverlay bool

Expand Down Expand Up @@ -199,6 +202,9 @@ func newManager(cfg Config, desc setDesc) (*Manager, error) {
raw.Unset(lnwire.Bolt11BlindedPathsOptional)
raw.Unset(lnwire.Bolt11BlindedPathsRequired)
}
if cfg.NoQuiescence {
raw.Unset(lnwire.QuiescenceOptional)
}
if cfg.NoTaprootOverlay {
raw.Unset(lnwire.SimpleTaprootOverlayChansOptional)
raw.Unset(lnwire.SimpleTaprootOverlayChansRequired)
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ require (
github.com/lightningnetwork/lightning-onion v1.2.1-0.20240712235311-98bd56499dfb
github.com/lightningnetwork/lnd/cert v1.2.2
github.com/lightningnetwork/lnd/clock v1.1.1
github.com/lightningnetwork/lnd/fn v1.2.3
github.com/lightningnetwork/lnd/fn v1.2.5
github.com/lightningnetwork/lnd/healthcheck v1.2.6
github.com/lightningnetwork/lnd/kvdb v1.4.11
github.com/lightningnetwork/lnd/queue v1.1.1
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -456,8 +456,8 @@ github.com/lightningnetwork/lnd/cert v1.2.2 h1:71YK6hogeJtxSxw2teq3eGeuy4rHGKcFf
github.com/lightningnetwork/lnd/cert v1.2.2/go.mod h1:jQmFn/Ez4zhDgq2hnYSw8r35bqGVxViXhX6Cd7HXM6U=
github.com/lightningnetwork/lnd/clock v1.1.1 h1:OfR3/zcJd2RhH0RU+zX/77c0ZiOnIMsDIBjgjWdZgA0=
github.com/lightningnetwork/lnd/clock v1.1.1/go.mod h1:mGnAhPyjYZQJmebS7aevElXKTFDuO+uNFFfMXK1W8xQ=
github.com/lightningnetwork/lnd/fn v1.2.3 h1:Q1OrgNSgQynVheBNa16CsKVov1JI5N2AR6G07x9Mles=
github.com/lightningnetwork/lnd/fn v1.2.3/go.mod h1:SyFohpVrARPKH3XVAJZlXdVe+IwMYc4OMAvrDY32kw0=
github.com/lightningnetwork/lnd/fn v1.2.5 h1:pGMz0BDUxrhvOtShD4FIysdVy+ulfFAnFvTKjZO5Pp8=
github.com/lightningnetwork/lnd/fn v1.2.5/go.mod h1:SyFohpVrARPKH3XVAJZlXdVe+IwMYc4OMAvrDY32kw0=
github.com/lightningnetwork/lnd/healthcheck v1.2.6 h1:1sWhqr93GdkWy4+6U7JxBfcyZIE78MhIHTJZfPx7qqI=
github.com/lightningnetwork/lnd/healthcheck v1.2.6/go.mod h1:Mu02um4CWY/zdTOvFje7WJgJcHyX2zq/FG3MhOAiGaQ=
github.com/lightningnetwork/lnd/kvdb v1.4.11 h1:fk1HMVFrsVK3xqU7q+JWHRgBltw/a2qIg1E3zazMb/8=
Expand Down
12 changes: 12 additions & 0 deletions htlcswitch/interfaces.go
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,18 @@ type ChannelUpdateHandler interface {
// will only ever be called once. If no CommitSig is owed in the
// argument's LinkDirection, then we will call this hook immediately.
OnCommitOnce(LinkDirection, func())

// InitStfu allows us to initiate quiescence on this link. It returns
// a receive only channel that will block until quiescence has been
// achieved, or definitively fails. The return value is the
// ChannelParty who holds the role of initiator or Err if the operation
// fails.
//
// This operation has been added to allow channels to be quiesced via
// RPC. It may be removed or reworked in the future as RPC initiated
// quiescence is a holdover until we have downstream protocols that use
// it.
InitStfu() <-chan fn.Result[lntypes.ChannelParty]
}

// CommitHookID is a value that is used to uniquely identify hooks in the
Expand Down
Loading