lnd/lnrpc/invoicesrpc
yyforyongyu df2ecd6bc5
invoices: refactor invoice subscriptions to avoid blocking
This commit fixes a potential blocking when notifying invoice updates.
When a new subscription client is created followed by an immediate
cancel, it's likely the client will be removed from the registry's
map(noop) and then added to its map again. This subscription will then
be kept in registry until lnd is restarted. Another more serious issue
is when multiple subscriptions are made for the same invoice, when the
above case happens, other subscriptions may never send invoice updates
because a previous client has a stopped notification queue that blocks
following notifications.
2021-12-15 02:38:51 +08:00
..
addinvoice.go multi: refactor SignDigestCompact into SignMessageCompact 2021-10-08 12:06:52 +02:00
config_active.go Merge pull request #5642 from guggero/in-memory-graph 2021-10-04 11:20:23 +02:00
config_default.go multi: add golang 1.17 compatible build tags 2021-09-29 17:31:37 -07:00
driver.go multi: add golang 1.17 compatible build tags 2021-09-29 17:31:37 -07:00
invoices_grpc.pb.go lnrpc/invoicesrpc: add new invoice ref LookupInvoiceV2 method 2021-10-28 15:49:25 -07:00
invoices_server.go invoices: refactor invoice subscriptions to avoid blocking 2021-12-15 02:38:51 +08:00
invoices.pb.go lnrpc/invoicesrpc: expose new lookup modifier to LookupInvoiceV2 2021-10-28 15:50:17 -07:00
invoices.pb.gw.go lnrpc/invoicesrpc: add new invoice ref LookupInvoiceV2 method 2021-10-28 15:49:25 -07:00
invoices.pb.json.go lnrpc/invoicesrpc: add new invoice ref LookupInvoiceV2 method 2021-10-28 15:49:25 -07:00
invoices.proto lnrpc/invoicesrpc: expose new lookup modifier to LookupInvoiceV2 2021-10-28 15:50:17 -07:00
invoices.swagger.json lnrpc: populate new AmpInvoiceState field in CreateRPCInvoice 2021-10-28 15:50:20 -07:00
invoices.yaml lnrpc/invoicesrpc: add new invoice ref LookupInvoiceV2 method 2021-10-28 15:49:25 -07:00
log.go invoicesrpc: create sub server 2019-02-01 09:42:35 +01:00
utils.go lnrpc: populate new AmpInvoiceState field in CreateRPCInvoice 2021-10-28 15:50:20 -07:00