[OFBiz] Dev - Never Cache on Views
David E. Jones
jonesde at ofbiz.org
Tue Apr 12 20:43:01 EDT 2005
Ryan,
Thanks for looking into that and fixing it, it was certainly missing
wasn't it...
I walked up and down the object graph in there and I agree this looks
like the best place for it. The change is in SVN.
-David
On Apr 8, 2005, at 7:47 PM, Ryan Warnick wrote:
> It looks like the never-cache entity setting isn't being used for the
> findByCondition family of cache functions. Here is one way that we
> think this could be resolved (code additions to
> AbstractEntityConditionCache.java are shown in red).
>
> protected Object put(String entityName, EntityCondition condition,
> Object key, Object value) {
> GenericDelegator delegator =
> GenericDelegator.getGenericDelegator(delegatorName);
> ModelEntity entity = delegator.getModelEntity(entityName);
> if (entity.getNeverCache()) {
> Debug.logWarning("Tried to put a value of the " +
> entityName + " entity in the cache but this entity has never-cache set
> to true, not caching.", module);
>
> return null;
> }
>
> Map conditionCache = getOrCreateConditionCache(entityName,
> condition);
> synchronized (conditionCache) {
> return conditionCache.put(key, value);
> }
> }
>
> public void remove(String entityName
>
> Ryan
>
>
> _______________________________________________
> Dev mailing list
> Dev at lists.ofbiz.org
> http://lists.ofbiz.org/mailman/listinfo/dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2363 bytes
Desc: not available
Url : http://lists.ofbiz.org/pipermail/dev/attachments/20050412/a6f908b1/smime.bin
More information about the Dev
mailing list