-
Notifications
You must be signed in to change notification settings - Fork 76
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
Relay request timeout #897
Conversation
First step as part of the refactoring this contract as immutable back-end for the random beacon. Removing getters for the constants since these are now auto-generated from public variables.
Backend contract should not track beacon entries and only needs to hold the last entry used as a selection seed for the next group selection run.
This is useful in case of using specific stub contracts in tests.
Use 'before' instead of 'beforeEach' where possible.
This contract is not used by the Keep client, CLI for relay requests has been implemented with truffle scripts and located in `contract/scripts`.
- Set relayRequestTimeout to 17 - Modified sign(..) function by adding require(..) to handle timeout - Added tests
TODO: Need to merge master after upgradable contract components is merged. |
Testing for `relayRequestTimeout` blocks calculation: 47579 - 47562 = 17New relay entry requested [&{RequestID:+2 Payment:+0 PreviousEntry:+10920102476789591414949377782104707130412218726336356788412941355500907533021 Seed:+53067088278316309045121968048462724729152109215234493179134844471987707841858 GroupPublicKey:[148 201 102 80 168 175 134 22 57 88 174 102 140 6 86 157 161 253 198 211 221 66 2 185 54 173 121 213 147 68 47 34 3 106 162 84 138 240 215 67 22 146 199 110 198 201 30 30 165 163 237 77 177 130 240 136 9 94 34 95 134 202 253 107] BlockNumber:47562}] [member:2, state:*entry.signatureCompleteState] Transitioned to new state |
We have decided to query operator contracts instead to avoid duplicated storage.
Setting new group size should only be possible in the event of contract upgrade.
Using <noun><action> naming for consistency.
…ents Upgradeable contract components implementation Implements RFC5 upgradeable contract components scheme. Adds minor refactoring to reduce the amount of repeated code. Further additions required to fully match RFC5, saving these for a separate PR: createGroup() method on Operator contract Service contract to select operator on requestRelayEntry()
- Set relayRequestTimeout to 17 - Modified sign(..) function by adding require(..) to handle timeout - Added tests
…core into relay-request-timeout
…core into relay-request-timeout
👋 would be useful to capture why we closed this PR :) |
The relay request timeout is a relatively small change. Because of Nik's changes, my code was sort of dependent on his work and I created this branch out of his. However, looking now at the history and trying to navigate to my actual changes is a bit confusing. I created a new branch from master (when Nik's changes were merged) for the timeout relay request, it's here. Way easier to look at and review. |
Couldn't we rebase to |
I tried.. but along the way had also some conflicts and just more headache. It was easier to create a new branch. |
Refs: #884
In this PR we need to block upcoming requests from processing if there is one in progress. After a node generates a relay entry, then it can again start processing a new request. These are the rules when we block a new relay request from processing: