[Merged by Bors] - Implement feerecipient API for keymanager#3213
[Merged by Bors] - Implement feerecipient API for keymanager#3213ethDreamer wants to merge 13 commits intosigp:unstablefrom
Conversation
e62a28d to
72a38e1
Compare
d6e65e2 to
fb0c84a
Compare
realbigsean
left a comment
There was a problem hiding this comment.
Nice! Couple of small things. Moving the fee recipient file management to the validator store makes sense to me as well.
michaelsproul
left a comment
There was a problem hiding this comment.
Looks good
I think it would be good to add a test or two in validator_client/src/http_api/tests/keystores.rs. The rest of the API is quite well tested and I think it would be straight forward to incorporate some feerecipient tests
|
I added some tests which test the API endpoint as well as the It seems like it's redundant and less desirable now. On top of that, if we are to remove this, we should do it before the merge when people might start using it in their workflows.. what do you guys think @paulhauner @michaelsproul ? |
michaelsproul
left a comment
There was a problem hiding this comment.
I'm on the fence about deleting the fee-recipient file. I think seeing as we already have it we might as well keep it. I think it might also be easier for some users to work with than the HTTP API. E.g. you can can update the default without knowing the pubkey of the validator you want to update the fee recipient for (which could be useful for some kinds of round-robin).
Other than that, there's also the matter of the recently added delete API: ethereum/keymanager-APIs#30. We could add it to this PR before merging, or bring it in separately seeing as this PR is already nicely self-contained and has been sitting in the merge queue so long. What's your preference @ethDreamer?
53312f7 to
d7857c1
Compare
|
Keeping the fee recipient file and storing fee recipients in the Would it be better to create a |
d1b4fd9 to
b8642ea
Compare
michaelsproul
left a comment
There was a problem hiding this comment.
Let's merge this now and come back for future enhancements:
- If the fee recipient setting API proves too slow with large number of validators, optimise it (possibly by batching disk writes), or if that isn't possible, add an alternative mechanism for loading fee recipients in bulk (possibly from a URL a la Teku).
- Add a
defaultfield for the fee recipient in thevalidator_definitions.yml. For now this can be worked around by using the process-level default (i.e. the value of the--suggested-fee-recipientflag).
|
bors r+ |
## Issue Addressed * #3173 ## Proposed Changes Moved all `fee_recipient_file` related logic inside the `ValidatorStore` as it makes more sense to have this all together there. I tested this with the validators I have on `mainnet-shadow-fork-5` and everything appeared to work well. Only technicality is that I can't get the method to return `401` when the authorization header is not specified (it returns `400` instead). Fixing this is probably quite difficult given that none of `warp`'s rejections have code `401`.. I don't really think this matters too much though as long as it fails.
|
Build failed (retrying...): |
## Issue Addressed * #3173 ## Proposed Changes Moved all `fee_recipient_file` related logic inside the `ValidatorStore` as it makes more sense to have this all together there. I tested this with the validators I have on `mainnet-shadow-fork-5` and everything appeared to work well. Only technicality is that I can't get the method to return `401` when the authorization header is not specified (it returns `400` instead). Fixing this is probably quite difficult given that none of `warp`'s rejections have code `401`.. I don't really think this matters too much though as long as it fails.
|
CI failure looks spurious, I'll restart the batch bors r- |
|
Canceled. |
|
bors r+ |
## Issue Addressed * #3173 ## Proposed Changes Moved all `fee_recipient_file` related logic inside the `ValidatorStore` as it makes more sense to have this all together there. I tested this with the validators I have on `mainnet-shadow-fork-5` and everything appeared to work well. Only technicality is that I can't get the method to return `401` when the authorization header is not specified (it returns `400` instead). Fixing this is probably quite difficult given that none of `warp`'s rejections have code `401`.. I don't really think this matters too much though as long as it fails.
|
Build failed (retrying...): |
## Issue Addressed * #3173 ## Proposed Changes Moved all `fee_recipient_file` related logic inside the `ValidatorStore` as it makes more sense to have this all together there. I tested this with the validators I have on `mainnet-shadow-fork-5` and everything appeared to work well. Only technicality is that I can't get the method to return `401` when the authorization header is not specified (it returns `400` instead). Fixing this is probably quite difficult given that none of `warp`'s rejections have code `401`.. I don't really think this matters too much though as long as it fails.

Issue Addressed
feerecipientAPI for keymanager (VC) #3173Proposed Changes
Moved all
fee_recipient_filerelated logic inside theValidatorStoreas it makes more sense to have this all together there. I tested this with the validators I have onmainnet-shadow-fork-5and everything appeared to work well. Only technicality is that I can't get the method to return401when the authorization header is not specified (it returns400instead). Fixing this is probably quite difficult given that none ofwarp's rejections have code401.. I don't really think this matters too much though as long as it fails.