Skip to content

Solve the computation throttling attribute #135

@dangershony

Description

@dangershony

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.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions