Merge pull request #8390 from carlaKC/7883-experimental-endorsement

Add Experimental Endorsement Signalling
This commit is contained in:
Elle authored and GitHub committed 2024-11-26 09:43:22 +02:00
commit fbeab726e1
20 files changed
+380 -40

No files matched your search

+10
View File
@@ -44,6 +44,7 @@ import (
"github.com/lightningnetwork/lnd/channeldb/graphsession"
"github.com/lightningnetwork/lnd/channeldb/models"
"github.com/lightningnetwork/lnd/channelnotifier"
"github.com/lightningnetwork/lnd/clock"
"github.com/lightningnetwork/lnd/contractcourt"
"github.com/lightningnetwork/lnd/discovery"
"github.com/lightningnetwork/lnd/feature"
@@ -758,6 +759,15 @@ func (r *rpcServer) addDeps(s *server, macService *macaroons.Service,
return nil
},
ShouldSetExpEndorsement: func() bool {
if s.cfg.ProtocolOptions.NoExperimentalEndorsement() {
return false
}
return clock.NewDefaultClock().Now().Before(
EndorsementExperimentEnd,
)
},
}
genInvoiceFeatures := func() *lnwire.FeatureVector {