-
Notifications
You must be signed in to change notification settings - Fork 37
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
Invocatons of alphabet vote method #170
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Codecov Report
@@ Coverage Diff @@
## master #170 +/- ##
=======================================
Coverage 46.91% 46.91%
=======================================
Files 60 60
Lines 2675 2675
=======================================
Hits 1255 1255
Misses 1290 1290
Partials 130 130
Continue to review full report at Codecov.
|
cthulhu-rider
approved these changes
Nov 13, 2020
Closed accidentally |
Update as nspcc-dev/neofs-contract#19 will be merged |
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
This function calculates validator key based on inner ring index and invokes `Vote` method of corresponding alphabet contract. Signed-off-by: Alex Vanin <alexey@nspcc.ru>
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
With this argument neofs-ir will be run as an CLI application that initialize inner ring server, invokes `vote` method on corresponding alphabet contract and exits. User can provide a comma-separated list of validator public keys. Signed-off-by: Alex Vanin <alexey@nspcc.ru>
Now alphabet contracts use signature collection to make a vote. All inner ring nodes votes for some list of validators the same way as they vote fore new epoch or new container. As soon as list is accepted by alphabet contracts, each of them votes for one candidate from the list. Signed-off-by: Alex Vanin <alexey@nspcc.ru>
JSON-RPC method takes reversed hash as an input so it is better to output reveresed hash in logs. Signed-off-by: Alex Vanin <alexey@nspcc.ru>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
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.
Inner ring can invoke
Vote
method on corresponding alphabet contracts. This way it controls side chain. Now inner ring node invokes voting on startup if it is presented in config. This way alphabet contracts are able to produce more GAS for inner ring and storage nodes.You can setup list of predefined validators in
config.yml
or with environment variable (whitespace separated list)
NEOFS_IR_MORPH_VALIDATORS="02b3622bf4017bdfe317c58aed5f4c753f206b7db896046fa7d774bbc4bf7f8dc2 0228b3b86d632a755da1e1f226bd782038acbe48e1f14e256b0afa58e32a45695e"
If list is empty, then
vote
won't be invoked on startup.In runtime node also can vote for validator from the comma-separated list.