registry icon indicating copy to clipboard operation
registry copied to clipboard

added cache aproach to registrant api response for domains

Open OlegPhenomenon opened this issue 3 years ago • 3 comments

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?

OlegPhenomenon avatar Aug 03 '22 09:08 OlegPhenomenon

Changes preview:

Legend:

👀 Review pull request on Viezly

viezly[bot] avatar Aug 03 '22 09:08 viezly[bot]

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.

ratM1n avatar Dec 06 '22 13:12 ratM1n

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.

OlegPhenomenon avatar Dec 06 '22 13:12 OlegPhenomenon