Commit graph

14427 commits

Author SHA1 Message Date
Slyghtning
b47cf7e871 funding: code style cleanup for the funding package 2023-01-12 22:40:51 +10:30
Oliver Gugger
b1645ec46d
Merge pull request #6783 from ErikEk/itest-neutrino-sub-server
itest: neutrino sub-server
2023-01-12 12:20:58 +01:00
Oliver Gugger
3dd9e04b8b
Merge pull request #7306 from YusukeShimizu/docs-invoice-default-expiry
Docs invoice default expiry
2023-01-12 10:29:07 +01:00
Oliver Gugger
79d5a01a81
Merge pull request #7310 from bitromortac/2301-queryprob-docs
routerrpc: update QueryProbability documentation
2023-01-12 10:23:09 +01:00
ErikEk
520c633938 docs: update release note 2023-01-12 13:43:55 +07:00
ErikEk
20fd630465 itest: test neutrino sub server 2023-01-12 13:43:41 +07:00
ErikEk
cc08271c5f itest: add neutrinoclient to harnessnode 2023-01-12 13:24:44 +07:00
bruwbird
71a5dab1a9
docs: add release notes 2023-01-12 09:17:47 +09:00
bruwbird
71f2615190
lnrpc: update invoice request expiry comment 2023-01-12 09:17:34 +09:00
bruwbird
380eb4af83
lncli: fix addinvoice expiry flag comment 2023-01-12 09:17:12 +09:00
bitromortac
045e5cf307
routerrpc: update QueryProbability documentation
Changes the docstring of QueryProbability to reflect changes that were
introduced in #6857.
2023-01-11 16:47:54 +01:00
Elle Mouton
e52461bddb
docs: add release notes for 7055 2023-01-11 13:59:03 +02:00
Elle Mouton
c3a2368f46
multi: migrate towers to use RangeIndex for AckedUpdates
In this commit, a migration is done that takes all the AckedUpdates of
all sessions and stores them in the RangeIndex pattern instead and
deletes the session's old AckedUpdates bucket. All the logic in the code
is also updates in order to write and read from this new structure.
2023-01-11 13:59:03 +02:00
Elle Mouton
50ad10666c
watchtower/wtdb: add migration code for AckedUpdates
In this commit, the code for migration 4 is added. This migration takes
all the existing session acked updates and migrates them to be stored in
the RangeIndex form instead. Note that this migration is not activated
in this commit. This is done in a follow up commit in order to keep this
one smaller.
2023-01-11 13:59:03 +02:00
Elle Mouton
870a91a1e8
watchtower/wtdb: add ability for a multi-tx db migration
In this commit, we add the ability to add a wtdb version migration that
does not get given a transaction but rather a whole db object. This will
be useful for migrations that are best done in multiple transaction in
order to use less RAM.
2023-01-11 13:59:03 +02:00
Elle Mouton
af076d8ff4
channeldb: add shouldFail param to ApplyMigrationWithDB
Add a shouldFail boolean parameter to the migtest ApplyMigrationWithDB
in order to make it easier to test migration failures.
2023-01-11 13:59:03 +02:00
Elle Mouton
0f6229d9e6
watchtower: convert helpers to methods
In preparation for an upcoming commit where some helper functions will
need access to the ClientDB's ackedRangeIndex member, this commit
converts those helper functions into methods on the ClientDB struct.
2023-01-11 13:59:02 +02:00
Elle Mouton
e2ae563304
watchtower: add in-mem acked range index to ClientDB
In this commit, an RangeIndex set is added to the ClientDB along with
getter methods that can be used to populate this in-memory set from the
DB.
2023-01-11 13:59:02 +02:00
Elle Mouton
4ea6c7d2ae
watchtower: refactor putClientSessionBody
Refactor the putClientSessionBody to take in a session sub-bucket rather
than the top-level session bucket. This is mainly to make an upcoming
commit diff easier to parse.
2023-01-11 13:59:02 +02:00
Elle Mouton
25afc8ad90
watchtower: add RangeIndex and tests
In this commit, a new concept called a RangeIndex is introduced. It
provides an efficient way to keep track of numbers added to a set by
keeping track of various ranges instead of individual numbers.

Notably, it also provides a way to map the contents & diffs applied to
the in memory RangeIndex (which uses a sorted array structure) to a
persisted KV structure.
2023-01-11 13:46:55 +02:00
Elle Mouton
fdba28ab7d
watchtower: add channelID index
In this commit, a new channel-ID index is added to the tower client db
with the help of a migration. This index holds a mapping from a
db-assigned-ID (a uint64 encoded using BigSize encoding) to real channel
ID (32 bytes). This mapping will help us save space in future when
persisting references to channels.
2023-01-11 13:46:55 +02:00
Elle Mouton
d03047f313
watchtower: migrate channel summaries
In this commit a migration of the tower client db is done. The migration
creates a new top-level cChanDetailsBkt bucket and for each channel
found in the old cChanSummaryBkt bucket, it creates a new sub-bucket. In
the subbucket, the ClientChanSummary is then stored under the
cChannelSummary key. The reason for this migration is that it will be
useful in future when we want to store more easily accessible data under
a specific client ID.
2023-01-11 13:46:55 +02:00
Elle Mouton
4ab8c57eae
watchtower: make better use of getChanSummary
Small refactor just to make the upcoming commit easier to parse. In
this commit, we make better use of the getChanSummary helper function.
2023-01-11 13:46:54 +02:00
Oliver Gugger
b1d6991b27
Merge pull request #7153 from carlaKC/7093-custommessage
multi: Add ability to handle protocol-range messages in Custom Message APIs
2023-01-11 09:52:40 +01:00
Oliver Gugger
ef8cf73d4c
Merge pull request #7295 from guggero/build-cache
GitHub: fix Golang build cache in actions
2023-01-06 14:11:34 +01:00
Oliver Gugger
f16a2f11df
docs: add release notes 2023-01-06 09:18:28 +01:00
Oliver Gugger
a074c801d1
GitHub: add job ID to cache key
To avoid the problem where multiple jobs try to create the same cache
entry, we add the GitHub job ID to the cache key.
The two restore keys make it possible that a job can also restore a
cache entry from another job if none for the current job exist yet.
2023-01-06 09:18:28 +01:00
Oliver Gugger
984fc3a2ec
GitHub: make setup-go action more versatile
With this commit we allow the Go version that is set up to be
configurable and not dependent on a specific environment variable. This
will allow us to eventually extract the action into a tooling
repository.
2023-01-06 09:18:26 +01:00
Oliver Gugger
c4ca7b99e2
GitHub: remove Go env variable override
For some reason we used to override the GOCACHE and GOPATH variables
earlier. This now causes the updated cache action not to pick up any
caches. As the overrides shouldn't be needed anymore, we remove them.
2023-01-06 09:18:16 +01:00
Carla Kirk-Cohen
19f013b5c4
release-notes: add send custom message override functionality 2023-01-05 12:06:25 -05:00
Carla Kirk-Cohen
1b1bc642bc
lntest/itest: add custom messaging itest including new override feature 2023-01-05 12:06:24 -05:00
Carla Kirk-Cohen
1cb08e42ef
lnrpc: update custom message API to explain ability to override 2023-01-05 12:05:06 -05:00
Carla Kirk-Cohen
c2ce8635e7
multi: add custom message overrides to protocol config options 2023-01-05 12:05:05 -05:00
Carla Kirk-Cohen
93dcbd7ea3
lnwire: allow overriding of protocol messages outside of custom range
Add the ability to specify messages < CustomRangeStart that will still
be treated like custom messages by lnd (rather than unknown ones). This
allows code external to lnd to handle protocol messages that are *not
yet known to lnd*.
2023-01-05 12:05:04 -05:00
Carla Kirk-Cohen
610f5d2140
lnwire: make custom type start a constant 2023-01-05 12:05:03 -05:00
Oliver Gugger
cfc48bd81c
Merge pull request #7272 from positiveblue/fix-7270
rpc: check that closing address matches the current network for open channel requests
2023-01-05 17:15:55 +01:00
Oliver Gugger
272ed415c2
Merge pull request #7289 from guggero/disable-thelper-linter
lint: disable `thelper` linter
2023-01-05 15:40:39 +01:00
Oliver Gugger
6585d5997a
docs: add release notes 2023-01-05 08:53:59 +01:00
Oliver Gugger
04dc37e463
lnwire: remove nolint comment 2023-01-05 08:49:31 +01:00
Oliver Gugger
99ebb67972
lint: disable thelper linter 2023-01-05 08:49:17 +01:00
Olaoluwa Osuntokun
e29a5a59ad
Merge pull request #7262 from bottlepay/fix-failure-tlv
lnwire: limit channel update reader
2023-01-04 18:41:44 -08:00
positiveblue
292ee1b123
docs: add release notes 2023-01-04 04:42:40 -08:00
positiveblue
2204cbfd30
rpc: validate closing channel address in open channel requests
Our OpenChannelRPC was accepting invalid values for the closing address
field. If we were able to decode the address we would use it in the
script even if the address is for another bitcoin net.
2023-01-04 04:42:39 -08:00
Joost Jager
3835b903a9
lnwire: limit channel update reader
Fixes a bug where channel update data is read until the end of the stream
rather than stopping after the specified length. This is problematic
when failure message tlv data is present, because this data is interpreted
as channel update tlv data.
2023-01-04 13:32:52 +01:00
Oliver Gugger
c03de26dcc
Merge pull request #7268 from ellemouton/avoidPanicInFundingTest
funding: check error to avoid panic during test
2023-01-03 16:32:32 +01:00
Oliver Gugger
3ffd3b2018
Merge pull request #7176 from b-ryan/fix-bumpfee-doc
Fix bumpfee command doc, incorrect reference to pendingsweeps
2023-01-03 11:22:52 +01:00
Oliver Gugger
73328bd449
Merge pull request #7271 from hieblmi/patch-4
docs: Fix lnd.conf typo
2023-01-03 11:08:48 +01:00
Slyghtning
c5fa9ef45f docs: Fix lnd.conf typo
Remove repeated word error [skip ci]
2022-12-28 20:37:03 +10:30
Elle Mouton
d4a49b08f5
funding: check error to avoid panic during test
This commit, the error returned from `getInitialFwdingPolicy` is checked
in order to avoid a nil pointer dereference panic during the
TestFundingManagerCustomChannelParameters test.
2022-12-22 10:06:42 +02:00
Olaoluwa Osuntokun
de3e0d7875
Merge pull request #7239 from Roasbeef/gossip-scoping-issues
discovery: ensure we prioritize sending out our own local announcements
2022-12-16 13:51:17 -08:00