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

added cache aproach to registrant api response for domains #2411

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

OlegPhenomenon
Copy link
Contributor

@OlegPhenomenon OlegPhenomenon commented Aug 3, 2022

So what am I doing here?
Here I actually cached the response from the registrant api to speed up the response in case of a large number of domains. I do not have the opportunity to test this on staging, I can only be based on the experience of the dev environment

So, before that, 3000 domains were rendered in the registrant center for about 43 seconds, after the changes, now this number of domains is rendered for 7 seconds.
Also in the development environment, I created a tmp/cache.txt file with the rails dev:cache command. Also in development.rb I made the following value config.cache_store = :redis_cache_store

if on staging the result is also good for a large number of domains, then this approach can be sent to production.

Do you have any opinions, additions, criticism?

@viezly
Copy link

viezly bot commented Aug 3, 2022

Changes preview:

Legend:

👀 Review pull request on Viezly

@ratM1n
Copy link

ratM1n commented Dec 6, 2022

First time loading took looong time, but eventually completed. Count shows that i have 40847 of 40847 domains (tech contact filter is off). But it will show me only 6 pages from this 40847 domains (24 domains per page), after that, "next" button goes inactive.

@OlegPhenomenon
Copy link
Contributor Author

First time loading took looong time, but eventually completed. Count shows that i have 40847 of 40847 domains (tech contact filter is off). But it will show me only 6 pages from this 40847 domains (24 domains per page), after that, "next" button goes inactive.

it is quite expected that the first run will be very long, while the next runs should be fast. the goal was exactly that the NEXT runs should be fast. in any case, if not all domains are loaded into memory, then something is wrong.

@vohmar vohmar assigned ratM1n and unassigned vohmar Dec 9, 2022
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

Successfully merging this pull request may close these issues.

3 participants