1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XenForo DataRegistry & memcached

Discussion in 'XenForo Development Discussions' started by Jake B., Apr 23, 2015.

  1. Jake B.

    Jake B. Well-Known Member

    Was just curious if all data loaded from the XenForo DataRegistry is cached using memcached, if not how would I go about making sure it is loaded from memcached? It is essential that there are no queries for this data as there are nearly 200 sites being run using this off the same servers using load balancers and they are constantly getting thousands of requests. Just want to make sure this goes off without a hitch :)
  2. Daniel Hood

    Daniel Hood Well-Known Member

    The DataRegistry is stored in the database. If you're looking to store it outside of the database, you may want to look at Zend_Cache_Core (XenForo_Application::getCache()).
  3. Jake B.

    Jake B. Well-Known Member

    I know the DataRegistry is stored in the database, and I know part of it at least is cached with memcached, was just curious if the whole thing was.
  4. Xon

    Xon Well-Known Member

    My Redis Cache addon uses some class loader tricks to allow XenForo_DataRegistry to be re-implemented/extended to implement a better MultiGet which is called when the hardcoded resources are loaded.

    XenForo directly loads XenForo_DataRegistry and then loads some limited data sets, which includes a cached copy of the list of active Code Event Listeners. After this stage, XenForo_DataRegistry will be loadable using Code Event Listeners.
  5. Jake B.

    Jake B. Well-Known Member

    I ended up getting it working, installing more Add-ons wasn't an option. It does turn out though, that entries in the data registry are cached with memcached also, so it worked out perfectly.

Share This Page