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

API read/write perf is poor for Artworks #6

Closed
markfinger opened this issue May 25, 2017 · 4 comments
Closed

API read/write perf is poor for Artworks #6

markfinger opened this issue May 25, 2017 · 4 comments
Assignees

Comments

@markfinger
Copy link
Member

Read timing

person 422 records: 0.912145853043 seconds
artwork 983 records: 48.3299021721 seconds

The results are paginated, so there's no extra overhead from json handling a massive payload. Given the extra pages for the artwork records, there may be a negligible overhead associated with the network requests.

Write perf seems to be about the same as reads.

@jmurty jmurty self-assigned this May 25, 2017
@jmurty
Copy link
Contributor

jmurty commented May 29, 2017

@markfinger @cogat the poor performance for Artworks, or any work in collections, is caused by the new EDTF field which uses naive and slow parsing of text values when reading EDTF date values back from the DB into model instances.

Fixing this will require either rethinking and updating the EDTFField implementation in python-edtf or removing the field from API results (with defer on the queryset) which would only solve the problem for API operations.

See ixc/python-edtf/issues/14

@jmurty
Copy link
Contributor

jmurty commented May 29, 2017

As noted in ixc/python-edtf/issues/14 it can take a quarter-second or longer to load each non-empty EDTF date field from the DB into a model instance, whether or not that field is subsequently referred to. This explains why it is slow not just to list items, but even to delete a set of populated model instances with Artwork.objects.all().delete()

@jmurty
Copy link
Contributor

jmurty commented Jun 6, 2017

This should be substantially resolved by changes for ixc/python-edtf#11

@jmurty
Copy link
Contributor

jmurty commented Jun 7, 2017

This should be resolved enough for now by changes upstream in ixc/python-edtf#11 etc

@jmurty jmurty closed this as completed Jun 7, 2017
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

2 participants