Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to use storethehash with multi-file primary with GC #816

Merged
merged 12 commits into from
Sep 25, 2022
Merged

Conversation

gammazero
Copy link
Collaborator

Newer storethehash splits primary storage across multiple files, and has garbage collections for the primary storage.

Conversion from the old to the new primary is done automatically when the new indexer starts up. This process will take significant time as the entire index needs to be updated with the new locations of primary data. Progress is logged.

@codecov-commenter
Copy link

codecov-commenter commented Sep 15, 2022

Codecov Report

Merging #816 (fa97730) into main (f60e4be) will increase coverage by 0.89%.
The diff coverage is 100.00%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #816      +/-   ##
==========================================
+ Coverage   46.05%   46.94%   +0.89%     
==========================================
  Files          92       92              
  Lines        7780     7854      +74     
==========================================
+ Hits         3583     3687     +104     
+ Misses       3734     3711      -23     
+ Partials      463      456       -7     
Impacted Files Coverage Δ
config/indexer.go 40.00% <100.00%> (ø)
internal/ingest/linksystem.go 64.80% <0.00%> (+0.64%) ⬆️
internal/ingest/ingest.go 78.43% <0.00%> (+6.09%) ⬆️

@masih masih marked this pull request as draft September 15, 2022 08:58
@masih
Copy link
Member

masih commented Sep 15, 2022

Do not Merge: being tested in dev first

masih added a commit that referenced this pull request Sep 15, 2022
masih added a commit that referenced this pull request Sep 15, 2022
gammazero and others added 9 commits September 20, 2022 07:03
Since the change in GC will rescan the entire index, deploy it onto
`dev` first to help de-risk the rollout in case there is some edge case
we have missed when it comes to potentially corrupt records.
@gammazero gammazero marked this pull request as ready for review September 23, 2022 11:02
@github-actions
Copy link
Contributor

Suggested version: v0.4.24
Comparing to: v0.4.23 (diff)

Changes in go.mod file(s):

diff --git a/go.mod b/go.mod
index c6144c8..70af59a 100644
--- a/go.mod
+++ b/go.mod
@@ -7,8 +7,8 @@ require (
 	github.com/cockroachdb/pebble v0.0.0-20220726144858-a78491c0086f
 	github.com/filecoin-project/go-address v0.0.5
 	github.com/filecoin-project/go-dagaggregator-unixfs v0.2.0
-	github.com/filecoin-project/go-indexer-core v0.6.2
-	github.com/filecoin-project/go-legs v0.4.12
+	github.com/filecoin-project/go-indexer-core v0.6.6
+	github.com/filecoin-project/go-legs v0.4.14
 	github.com/frankban/quicktest v1.14.3
 	github.com/gammazero/deque v0.2.0
 	github.com/gogo/protobuf v1.3.2
@@ -17,13 +17,13 @@ require (
 	github.com/hashicorp/go-retryablehttp v0.7.1
 	github.com/ipfs/go-cid v0.2.0
 	github.com/ipfs/go-datastore v0.5.1
-	github.com/ipfs/go-delegated-routing v0.3.0
+	github.com/ipfs/go-delegated-routing v0.5.1
 	github.com/ipfs/go-ds-leveldb v0.5.0
 	github.com/ipfs/go-log/v2 v2.5.1
 	github.com/ipfs/kubo v0.14.0
 	github.com/ipld/go-ipld-adl-hamt v0.0.0-20220616142416-9004dbd839e0
-	github.com/ipld/go-ipld-prime v0.17.0
-	github.com/ipld/go-storethehash v0.2.8
+	github.com/ipld/go-ipld-prime v0.18.0
+	github.com/ipld/go-storethehash v0.3.4
 	github.com/libp2p/go-libp2p v0.21.0
 	github.com/libp2p/go-libp2p-core v0.19.1
 	github.com/libp2p/go-msgio v0.2.0
@@ -118,7 +118,7 @@ require (
 	github.com/ipfs/go-peertaskqueue v0.7.1 // indirect
 	github.com/ipfs/go-unixfs v0.4.0 // indirect
 	github.com/ipfs/go-verifcid v0.0.1 // indirect
-	github.com/ipld/edelweiss v0.1.4 // indirect
+	github.com/ipld/edelweiss v0.2.0 // indirect
 	github.com/ipld/go-codec-dagpb v1.4.0 // indirect
 	github.com/jackpal/go-nat-pmp v1.0.2 // indirect
 	github.com/jbenet/go-temp-err-catcher v0.1.0 // indirect

gorelease says:

# github.com/filecoin-project/storetheindex/config
## compatible changes
Indexer.PebbleDisableWAL: added

# github.com/filecoin-project/storetheindex/server/reframe
## compatible changes
(*ReframeService).Provide: added

# diagnostics
required module github.com/microcosm-cc/bluemonday@v1.0.2 retracted by module author: Retract older versions as only latest is to be depended upon

# summary
Suggested version: v0.5.0

gocompat says:

(empty)

@gammazero
Copy link
Collaborator Author

I am going to merge this PR as it has become clear that it is necessary if we are going to use STH.

@gammazero gammazero merged commit 8936ca9 into main Sep 25, 2022
@gammazero gammazero deleted the primary-gc branch September 25, 2022 01:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants