Homec4science

Introduce a request cache mechanism

Authored by epriestley <git@epriestley.com> on Jun 5 2015, 02:27.

Description

Introduce a request cache mechanism

Summary:
Ref T8424. This adds a standard KeyValueCache to serve as a request cache.

In particular, I need to cache Spaces (they are frequently accessed, sometimes by multiple viewers) but not have them survive longer than the scope of one request.

This request cache is explicitly destroyed by each web request and each daemon request.

In the very long term, building this kind of construct supports reusing PHP interpreters to run web requests (see some discussion in T2312).

Test Plan:

  • Added and executed unit tests.
  • Ran every daemon.

Reviewers: btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T8424

Differential Revision: https://secure.phabricator.com/D13153

Details

Committed
epriestley <git@epriestley.com>Jun 5 2015, 02:27
Pushed
aubortJan 31 2017, 17:16
Parents
rPHa15444aa7919: Remove PhabricatorStartup::getGlobal/setGlobal mechanism
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPH52a29be70d5d: Introduce a request cache mechanism (authored by epriestley <git@epriestley.com>).Jun 5 2015, 02:27