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

LIMS-42: Minor speedup of _get_all_containers #885

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ndg63276
Copy link
Collaborator

JIRA ticket: LIMS-42

Summary:

Getting a list of all containers for a proposal can be slow as there is a large number of joins needed. We have previously sped up the counting query, but there are still minor improvements that can be done to the main query.

Changes:

  • Only do the second join to ContainerInspection if looking at a specific container, not for the list of all containers
  • Don't get lastqueuedwell as it is not used anywhere and does take a little time
  • Clean up the list of fields that can be used to sort
  • Tidy up the columns queried, grouping them by table as much as possible

To test:

  • Go to a proposal with both plates and pucks, eg nr29467, and go to /containers
  • Check the table loads, and clicking on each column header sorts by that column
  • Check each filter at the top works (some of them might give no results)
  • Click on a particular plate, check the page loads ok, including the button saying "Request Plate Imaging" (this might not appear if someone has recently requested imaging, but that is unlikely)
  • Go back to /containers and then click on a particular puck, check the page loads ok
  • Go to /admin/imaging and check the Containers table works there as well

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

Successfully merging this pull request may close these issues.

2 participants