[DDC-1563] Result cache for repository queries Created: 25/Dec/11  Updated: 20/Dec/13  Resolved: 20/Dec/13

Status: Resolved
Project: Doctrine 2 - ORM
Component/s: None
Affects Version/s: None
Fix Version/s: 2.5
Security Level: All

Type: New Feature Priority: Major
Reporter: Benjamin Eberlei Assignee: Fabio B. Silva
Resolution: Fixed Votes: 0
Labels: None


Many related "standing data" tables are very static and seldom change. There should be a metadata config to enable result cache for ALL repository operations.


Comment by Benjamin Eberlei [ 25/Dec/11 ]

This should directly support cache invalidation through a tag. Each repository gets a key with the current version. The version is one part ofthe actual cache datas key.

A new cache key version is generated:

1. When none is found during find operation
2. When any write operation is done.

For transaction consisteny the rollback operation in UoW needs to reset cache keys and only after a succesful commit operation the new cache key version should be set.

We may need begin, commit, rollback events in UoW for this.

Comment by Fabio B. Silva [ 20/Dec/13 ]

Fixed by : https://github.com/doctrine/doctrine2/commit/b081e5681d9dc75ea2ab4a609e1aff5f4b7f2b87

Generated at Wed Nov 25 05:25:44 EST 2015 using JIRA 6.4.10#64025-sha1:5b8b74079161cd76a20ab66dda52747ee6701bd6.