-
Notifications
You must be signed in to change notification settings - Fork 19
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
#3275: Slowness on Domain, Domain Info and Domain Requests - [Backup] #3340
base: main
Are you sure you want to change the base?
Conversation
…so we don't all end up with 100000
🥳 Successfully deployed to developer sandbox nl. |
🥳 Successfully deployed to developer sandbox nl. |
🥳 Successfully deployed to developer sandbox nl. |
@@ -779,7 +779,8 @@ def test_short_org_name_in_domains_list(self): | |||
response = self.client.get("/admin/registrar/domain/") | |||
# There are 4 template references to Federal (4) plus four references in the table | |||
# for our actual domain_request | |||
self.assertContains(response, "Federal", count=57) | |||
self.assertContains(response, "Federal", count=54) | |||
self.assertContains(response, "federal", count=225) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The updates to the filters means we no longer grab display values for Federal Type or Generic org type. It's a small sacrifice that needs to be reflected in the unit tests, which check for camel case.
🥳 Successfully deployed to developer sandbox nl. |
🥳 Successfully deployed to developer sandbox nl. |
🥳 Successfully deployed to developer sandbox nl. |
🥳 Successfully deployed to developer sandbox nl. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this looks good overall. Just had a couple questions.
On the sandbox, I got a 500 error when I hit federal type on the domain admin table, but generic org type works.
I don't see the federal type filter on the right on the Domain Request table on the sandbox.
🥳 Successfully deployed to developer sandbox nl. |
🥳 Successfully deployed to developer sandbox nl. |
🥳 Successfully deployed to developer sandbox nl. |
🥳 Successfully deployed to developer sandbox nl. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
More will come soon! Just need to run the code
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work, seems a lot faster.
My two blocks are just regarding the usage of def lookup
but they are relatively minor things. Lookups is returning the value of each org choice option, but the fix for that is easy and should not impact performance at all. After those are fixed - I am happy to approve!
🥳 Successfully deployed to developer sandbox nl. |
Ticket 3275
Resolves #3275
Changes
Context for reviewers
The admin tables for Domain Requests, Domains, and Domain Information were given a thorough check-up to tease out any remaining opportunities for optimization and to diagnose causes of slow load times.
Findings for root cause of slowness
We already have taken measures to optimize performance of the admin tables, so the cause of slowness this time around was determined to be two filters that were recently added and not optimized for performance -- GenericOrgfilter and FederalTypeFilter. These were added during the course of updating our model structure to use converted fields. However, they were making expensive database calls. They have been revised to be avoid making such calls.
Areas that were verified to be optimized
It is worth noting that the following structures/subroutines were examined and determined to NOT cause slowness. (Code was commented out down to a bare-bones load, then different areas where systematically added back in to see performance impact. Performance was tested for 100000 records. We might want to re-examine some of these areas if we see performance issues with larger data sets)
Setup
Code Review Verification Steps
Do the following for DomainRequest, Domain, and DomainInformation tables
As the original developer, I have
Satisfied acceptance criteria and met development standards
Ensured code standards are met (Original Developer)
Validated user-facing changes (if applicable)
As a code reviewer, I have
Reviewed, tested, and left feedback about the changes
Validated user-facing changes as a developer
Note: Multiple code reviewers can share the checklists above, a second reviewer should not make a duplicate checklist. All checks should be checked before approving, even those labeled N/A.
As a designer reviewer, I have
Verified that the changes match the design intention
Validated user-facing changes as a designer
References
Screenshots