Skip to content
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

Solve the computation throttling attribute #135

Open
dangershony opened this issue Mar 29, 2022 · 0 comments
Open

Solve the computation throttling attribute #135

dangershony opened this issue Mar 29, 2022 · 0 comments
Assignees

Comments

@dangershony
Copy link
Member

Right now we use SlowRequestsFilteerAttribute to avoid many calls to tables that do potentially long running computations to avoid multiple updates of the same computation processes.
This will correctly return a status code 202 to any caller.

https://github.com/block-core/blockcore-indexer/blob/master/src/Blockcore.Indexer.Core/Operations/SlowRequestsFilteerAttribute.cs

Two issues:

  • this decouples the logic form the computation service
  • it limits the calls to the endpoint to be 1 call per contract address (assuming its called form one endpoint.

We should be able to allow multiple calls to a certain endpoint and only if any computation is needed or in progress throttle additional calls (for example once computation was done from a given block height it wont happen again until a contract address is effected.
The current assumption is that such operations will be fast and wont disrupt calls however that removes the ability to make parallel calls to the same contract address.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants