DataNucleus JIRA is now in read-only mode. Raise any new issues in GitHub against the plugin that it applies to. DataNucleus JIRA will remain for the foreseeable future but will eventually be discontinued
Issue Details (XML | Word | Printable)

Type: New Feature New Feature
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Unassigned
Reporter: Andy Jefferson
Votes: 0
Watchers: 0

If you were logged in you would be able to see more operations.
DataNucleus Core

Support L2 caching of embedded/serialised PC objects

Created: 24/Jun/08 07:56 PM   Updated: 05/Oct/12 05:09 PM   Resolved: 02/Oct/12 03:55 PM
Component/s: Cache
Affects Version/s: None
Fix Version/s: 3.1.3

 Description  « Hide
The L2 caching now supports PC fields, reference fields, collection<PC>, map<PC, PC>, map<nonPC, PC>, map<PC, nonPC>. Needs also to support embedded/serialised PC objects for any of these (objects have no OID, so need copying and storing with the object itself)

Sort Order: Ascending order - Click to sort in descending order
Andy Jefferson added a comment - 01/Oct/12 10:32 AM
This can be implemented by having the "value" for such a field as a CachedPC of its own. So the populate and retrieve field managers need to cater for nested CachedPC objects.

Andy Jefferson added a comment - 02/Oct/12 03:55 PM
SVN trunk has support for L2 caching of serialised/embedded fields, enabled by persistence property "datanucleus.cache.level2.cacheEmbedded". Currently defaults to false until we move to 3.1 at which point it is turned on, so people can try it out in 3.1.x lifecycle and give feedback

Chris Colman added a comment - 02/Oct/12 07:25 PM
I haven't checked out the source code in this area but in my ignorance: If these objects are embedded wouldn't they already be cached within the first class object they are embedded in when it is cached?

Andy Jefferson added a comment - 02/Oct/12 08:08 PM
perhaps look at the source code for the *L2 cache*. These are not normal objects and no, those fields were not previously cached