openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pinaki Poddar (JIRA)" <j...@apache.org>
Subject [jira] Commented: (OPENJPA-611) The findBy behaves differently when DataCache is on in some situations.
Date Tue, 27 May 2008 23:51:45 GMT

    [ https://issues.apache.org/jira/browse/OPENJPA-611?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12600317#action_12600317
] 

Pinaki Poddar commented on OPENJPA-611:
---------------------------------------

This patch seems to tag class-level meta data whether an instance of a class is cacheable
or not. However, this decision is not really a class-level decision. Instances of Class A
can appear in many different contexts. One such context is considered here where there is
a possibility of user application to populate the values inconsistently. But if based on those
conditions it is decided that the class itself is not cacheable then other contexts where
instances of the class is used properly will not be cached either. 


> The findBy behaves differently when DataCache is on in some situations.
> -----------------------------------------------------------------------
>
>                 Key: OPENJPA-611
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-611
>             Project: OpenJPA
>          Issue Type: Bug
>            Reporter: Fay Wang
>         Attachments: openjpa.patch, openjpa0526.patch
>
>
> In the following two situations, the behavior of  findBy with DataCache on is different
from the same findBy with DataCache off:
> (1) When there is @PrimaryKeyJoinColumn annotation on the relation fields:
> Even though no relation is explicitly set in the application,  when retrieving from the
database, the relation field will be populated. However, if DataCache is on, the relation
fields will not be populated via findBy from data cache.
> (2) When more than one fields are mapped to the same column with insertable=false or
updateable=false: Setting different values to these fields will be saved in and restored from
the datacache, but the the database will return only one value for these fields. 
> The attached patch detects the above two situations and set the flag to instruct DataCacheStoreManager
not to cache the instances of these kinds of entities so that the findBy operation for these
two kinds of entities will always go to the database.  

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message