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

Slow search #13

Open
jmiguelv opened this issue Nov 5, 2012 · 7 comments
Open

Slow search #13

jmiguelv opened this issue Nov 5, 2012 · 7 comments

Comments

@jmiguelv
Copy link
Collaborator

jmiguelv commented Nov 5, 2012

The EATS search becomes very slow when searching for entities that have multiple relationships.

@philgooch
Copy link

We have an EATS instance containing towns and counties from the National Archives. Derbyshire has around 400 'county_for' relationships that point to the towns that it encompasses. Searching for 'Derby' takes a long time ... selecting Derbyshire to edit, it takes around 60 seconds to bring up the Edit screen.

@ajenhl
Copy link
Owner

ajenhl commented Nov 5, 2012

Sounds like there's a real need for maintaining shortcuts of the relationships in the database for fast querying, in the same way as there is for names (the NameCache model). This would be a fairly straightforward piece of work for someone to learn how the internals of EATS works.

@jmiguelv
Copy link
Collaborator Author

jmiguelv commented Nov 5, 2012

Happy to do it, but might need some guidance.

On 5 Nov 2012, at 20:07, "Jamie Norrish" <[email protected]mailto:[email protected]> wrote:

Sounds like there's a real need for maintaining shortcuts of the relationships in the database for fast querying, in the same way as there is for names (the NameCache model). This would be a fairly straightforward piece of work for someone to learn how the internals of EATS works.


Reply to this email directly or view it on GitHubhttps://github.com//issues/13#issuecomment-10085668.

@ajenhl
Copy link
Owner

ajenhl commented Jan 19, 2013

Did the commits in November 2012 fix this issue for you?

@philgooch
Copy link

The November 2012 commits did make a difference, although the search (and
display) is still slow for entities with many entity relations, it is about
30-50% faster than it was.

Thanks

Phil

On Sat, Jan 19, 2013 at 3:49 AM, Jamie Norrish [email protected]:

Did the commits in November 2012 fix this issue for you?


Reply to this email directly or view it on GitHubhttps://github.com//issues/13#issuecomment-12450000.

@ajenhl
Copy link
Owner

ajenhl commented Jan 20, 2013

I've just added a little more internal caching; I doubt it will have a significant effect on your queries, but hopefully every little helps.

@ajenhl
Copy link
Owner

ajenhl commented Nov 21, 2015

I have had very good results using django-cache-manager (https://github.com/vijaykatam/django-cache-manager), such that it will be used automatically if it is listed in INSTALLED_APPS. I'd appreciate any feedback about whether this helps in other installations.

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

3 participants