storj/satellite/overlay
paul cannon 0e2fef977f satellite/overlay: add SetAllContainedNodes method to overlay.DB
We will be needing an infrequent chore to check which nodes are in the
reverify queue and synchronize that set with the 'contained' field in
the nodes db, since it is easily possible for them to get out of sync.
(We can't require that the reverification queue table be in the same
database as the nodes table, so maintaining consistency with SQL
transactions is out. Plus, even if they were in the same database, using
such SQL transactions to maintain consistency would be slow and
unwieldy.)

This commit adds a method to the overlay allowing the caller to set the
contained status of all nodes in the nodes table at once. This is valid
because our definition of "contained" now depends solely on whether a
node appears at least once in the reverification queue. Only rows whose
contained field does not match the expectation will be updated; the
contained timestamp will not be updated for a node which is supposed to
be contained and was already contained.

Change-Id: I8cabe56ad897b6027e11aa5b17175295391aa3ac
2023-02-06 10:18:54 +00:00
..
offlinenodes satellite/overlay/offlinenodes: insert offline nodes into node events 2022-11-18 12:10:06 -05:00
straynodes satellite/overlay: insert DQ node events for stray nodes 2022-11-04 15:48:17 +00:00
benchmark_test.go satellite/overlay: insert DQ event into node events in overlay.DisqualifyNode 2022-11-04 15:18:31 +00:00
checkin_test.go mod: bump common to fetch latest placement type changes 2021-11-16 12:42:25 +00:00
config.go satellite/overlay: node software update email cooldown config 2022-11-11 20:14:25 +00:00
db_test.go storj: upgrade to use latest storj/common NodeAddress 2023-01-25 01:37:26 +00:00
downloadselection_test.go satellite/overlay: insert DQ event into node events in overlay.DisqualifyNode 2022-11-04 15:18:31 +00:00
downloadselection.go satellite/{orders,overlay}: use cache for downloads 2022-07-12 11:04:34 +00:00
peeridentities_test.go satellite/satellitedb/satellitedbtest: pass ctx as an argument 2020-01-20 16:35:42 +02:00
peeridentities.go all: golangci-lint v1.33.0 fixes (#3985) 2020-12-05 17:01:42 +01:00
piececount_test.go storj: upgrade to use latest storj/common NodeAddress 2023-01-25 01:37:26 +00:00
selection_test.go satellite/reputation: reconfigure lambda and alpha 2022-08-17 18:52:53 +00:00
service_test.go satellite/overlay: return noise info with selected nodes 2023-02-02 15:46:27 +00:00
service.go satellite/overlay: add SetAllContainedNodes method to overlay.DB 2023-02-06 10:18:54 +00:00
statdb_test.go storj: upgrade to use latest storj/common NodeAddress 2023-01-25 01:37:26 +00:00
uploadselection_test.go storj: upgrade to use latest storj/common NodeAddress 2023-01-25 01:37:26 +00:00
uploadselection.go satellite/overlay: return noise info with selected nodes 2023-02-02 15:46:27 +00:00