Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Current »

When user information is loaded from database ("UsersEventHandler::OnAfterItemLoad" method), then the states, that match user selected country are populated to user object as well ("kCountryStatesHelper::PopulateStates" method). It turns out, that later method isn't very effective at what he does:

  • it resolves country ISO code to it's ID in database via "getCountryStateId" method (does SQL each time it's called)
  • it doesn't cache states for countries that have states (does SQL each time when user has country without states)

This adds 2 more SQL queries per each user load.

I propose that we solve that by caching these SQL results into Memcache.

country_states_helper_memcache_addon.patch

Related Tasks

INP-1362 - Getting issue details... STATUS

  • No labels