-
Notifications
You must be signed in to change notification settings - Fork 44
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
feat: storenode cycle #1223
feat: storenode cycle #1223
Conversation
d9361e5
to
3988fc6
Compare
b2d0226
to
b852a92
Compare
b852a92
to
f29ce5f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code functionality looks good to me! hence approving it. Few comments that might be good to address now.
Some code architectural comments i have noted here, maybe these are planned as part of a subsequent refactor but wanted to indicate anyways :)
- Interface between status-go and waku api should be simple i.e status-go specifies list of storenodes to be used and waku internally manages connectivity to them and picks a storenode and manages active store. There can be one event emitter than status-go can register with to get all updates such as what is active-store-node, in case connectivity is lost etc.
- All 3 components i.e history-query, missing-messages and message-check should end up using same set of store nodes instead of their own selection criteria and logic.
- selection of storenode can be done using peer-selection and RTT. logic seems duplicated here
- store node failed requests should also consider requests made from
missing_messages
andmessage_check
so that active storenode can be switched.
I agree with the suggestions, and will work on these on a separate PR! thank you. Indeed there's a lot of duplication of code between the missing message logic, message check and the store node cycle that will need to be refactored away |
Jenkins BuildsClick to see older builds (6)
|
397b4b5
to
f40a23c
Compare
This PR contains the storenode cycle code from status-go.
I tried to simplify it a bit but most of the heavy refactoring should be done on a separate PR since this one is already complex enough.
@plopezlpz, @kaichaosun @igor-sirotin @chaitanyaprem:
I'm still working on the unit tests, but so far, while testing status-im/status-go#5857 with Desktop, it looks promising. Reviews are appreciated!