I am currently using a doctrine result cache, so I installed
result_cache_driver: apc
into my configuration.
Then I got the request cache working inside the repository correctly using, for example,
->setResultCacheId(sprintf('posts_for_user_%d', $userId))
The first problem arises when I used these things in the doctrine:
$repository->findOneBy(array) $repository->findBy(array)
which can be easily overridden in the repository.
The problem that I cannot get around is using ParamConverter to use doctrine caching, as well as to combine objects.
For example, if I have a Team object with a OneToMany relation to Player, I usually do
$team->getPlayers()
I have no control over the caching of this request. Is this possible in some way?
source share