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

investigate caching for assets/ call #347

Open
hburgund opened this issue Sep 15, 2017 · 1 comment
Open

investigate caching for assets/ call #347

hburgund opened this issue Sep 15, 2017 · 1 comment

Comments

@hburgund
Copy link
Member

The assets/ endpoint works fine for small number of assets, but when there are thousands of assets, it starts to take a long time to return the result which in turn causes major slow-downs on the client-side.

Ideally, all calls to assets/ would have an optional parameter to take the cached response or not and the cached response would automatically be updated server-side every time a new asset is added.

It is crucial that clients are able to grab the most recent data because when a client adds a new asset, they will want it to show up on the map, for example, right away.

It is likely that the assets/ code can be optimized to improve efficiency, but this may not be enough to really fix the current problem, hence the caching research.

Resources

@hburgund
Copy link
Member Author

significant optimization work done using prefetch_related and select_related that speeds up call in some cases by order of magnitude: 1ecb0f2

caching is likely still a good idea, but this is a major improvement.

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

No branches or pull requests

1 participant