Return-Path: X-Original-To: apmail-cayenne-user-archive@www.apache.org Delivered-To: apmail-cayenne-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 308188FFD for ; Thu, 18 Aug 2011 11:06:52 +0000 (UTC) Received: (qmail 95581 invoked by uid 500); 18 Aug 2011 11:06:50 -0000 Delivered-To: apmail-cayenne-user-archive@cayenne.apache.org Received: (qmail 95264 invoked by uid 500); 18 Aug 2011 11:06:39 -0000 Mailing-List: contact user-help@cayenne.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@cayenne.apache.org Delivered-To: mailing list user@cayenne.apache.org Received: (qmail 95221 invoked by uid 99); 18 Aug 2011 11:06:38 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 18 Aug 2011 11:06:37 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [208.78.103.231] (HELO vorsha.objectstyle.org) (208.78.103.231) by apache.org (qpsmtpd/0.29) with SMTP; Thu, 18 Aug 2011 11:06:29 +0000 Received: (qmail 17994 invoked from network); 18 Aug 2011 11:06:08 -0000 Received: from unknown (HELO ?192.168.1.94?) (194.158.197.10) by vorsha.objectstyle.org with SMTP; 18 Aug 2011 11:06:08 -0000 Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Apple Message framework v1084) Subject: Re: Two caches - what are the issues? From: Andrus Adamchik In-Reply-To: Date: Thu, 18 Aug 2011 14:06:07 +0300 Content-Transfer-Encoding: quoted-printable Message-Id: References: To: user@cayenne.apache.org X-Mailer: Apple Mail (2.1084) On Aug 18, 2011, at 1:58 PM, Durchholz, Joachim wrote: > This leaves me wondering. Does this mean I can have two objects that = map to the same database record, one in the individual object cache and = one in the query result cache? No. The DataObject uniquing is guaranteed per ObjectContext by Cayenne = regardless of the caching.=20 > Am I misinterpreting something? > If not: how do peple deal with it? What are the best practices here? Usually there's nothing to deal with really. The main drawback here is = that object cache is not pluggable and not managed (you can't set = expiration policies, it is just an LRU). But other than that it is = transparent. Andrus