This repository has been archived by the owner on Oct 30, 2018. It is now read-only.
queueing publishContract and ping on worker queue close to nodeID #91
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I would expect alloc and ping message comming from renterIDs close to my nodeID. At the moment all renterIDs try to comunicate with me. In return I as farmer will have to spam the bridge with PUBLISH messages because sooner or later my contact list is full with to many renterIDs.
This pull request will fix it.
Mirror has this problem as well but I don't want to change to much at the same time. Mirror will use the shard hash to queue the job. That was fine the early days because the shard hash was close to all mirror farmer. We removed that relationship and would have to use the first destination now. However I would need a test environment to try this. I don't want to risk it on the main net. Thats why I havent included it in this pull request.
I noticed that contractRenewal has duplicate code blocks. It has a serializer and desiralizer but is bypassing them by sending a RAW message itself. If we are going to keep complex for a few more days I could try to clean up the unused code. Would still look ugly but not as confusing as the current situation.