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

Prefetch state claims to change O(n) calls to Lotus State to O(1) #1855

Conversation

RobQuistNL
Copy link
Contributor

In my case (140.000 updates) shaves off 1.5 seconds per call (+ the load on the daemon) -> turns a 39 hour job into seconds

In my case (140.000 updates) shaves off 1.5 seconds per call (+ the load on the daemon) -> turns a 39 hour job into seconds
@LexLuthr
Copy link
Collaborator

@RobQuistNL Thank you for the PR. Looks good.

Copy link
Collaborator

@LexLuthr LexLuthr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One nit about the actor version. Rest is good.

@@ -17,6 +17,7 @@ import (
"github.com/filecoin-project/lotus/chain/types"
"github.com/ipfs/go-cid"
logging "github.com/ipfs/go-log/v2"
verifregtypes "github.com/filecoin-project/go-state-types/builtin/v9/verifreg"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please check with v12 verifreg? We are trying to use latest actors as much as possible.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you sure that will work? The v9 one is the one used in the return type of the API call

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ahhh! Looks like a Lotus side dependency. Merging.

@LexLuthr LexLuthr merged commit 13faaa8 into filecoin-project:main Dec 21, 2023
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants