Skip to content
This repository has been archived by the owner on Dec 12, 2021. It is now read-only.

Blockables/Certs/Votes API batching #29

Closed
thehesiod opened this issue Oct 25, 2018 · 4 comments
Closed

Blockables/Certs/Votes API batching #29

thehesiod opened this issue Oct 25, 2018 · 4 comments

Comments

@thehesiod
Copy link

thehesiod commented Oct 25, 2018

For two different reasons:
We added a "state" column to the events admin page to keep track of the current state of each event's blockable state. To do this we needed to do a page-size of requests to get the blockables, and then get any certs which were available. This is a lot of API calls and ends up making our instance count often peak

Similarly on the blockables page we grab any certs which are available for blockables to get a better state result.

I can see this being solved in one of two ways:

  1. On the events query API call, a parameter which controls if you want it to return the associated blockables/certs...and similarly on the blockables query call to return any certs/votes associated with the results

  2. Having batch get support for certs/blockables.

thoughts? It would be good to handle #28 as well with the design.

@msuozzo
Copy link
Member

msuozzo commented Oct 25, 2018

It sounds like you might be describing withContext (link) by which we support association of blockable+cert+vote entities (via this function).

@thehesiod
Copy link
Author

fascinating, will explore this area and share my findings, thanks so much!!

@thehesiod
Copy link
Author

sweet, that helped a lot (farmersbusinessnetwork@8921958) ! thanks so much!

@thehesiod
Copy link
Author

also sped up my blockables page with: farmersbusinessnetwork@d5f0731, where I implement _GetBlockableContext

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

No branches or pull requests

2 participants