From dev-return-13613-apmail-openjpa-dev-archive=openjpa.apache.org@openjpa.apache.org Mon Sep 14 19:53:19 2009 Return-Path: Delivered-To: apmail-openjpa-dev-archive@www.apache.org Received: (qmail 54988 invoked from network); 14 Sep 2009 19:53:19 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 14 Sep 2009 19:53:19 -0000 Received: (qmail 71601 invoked by uid 500); 14 Sep 2009 19:53:19 -0000 Delivered-To: apmail-openjpa-dev-archive@openjpa.apache.org Received: (qmail 71557 invoked by uid 500); 14 Sep 2009 19:53:19 -0000 Mailing-List: contact dev-help@openjpa.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@openjpa.apache.org Delivered-To: mailing list dev@openjpa.apache.org Received: (qmail 71537 invoked by uid 99); 14 Sep 2009 19:53:19 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 14 Sep 2009 19:53:19 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 14 Sep 2009 19:53:17 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id A9614234C4B0 for ; Mon, 14 Sep 2009 12:52:57 -0700 (PDT) Message-ID: <1642534513.1252957977693.JavaMail.jira@brutus> Date: Mon, 14 Sep 2009 12:52:57 -0700 (PDT) From: "Donald Woods (JIRA)" To: dev@openjpa.apache.org Subject: [jira] Resolved: (OPENJPA-1151) Cache the current-time timestamp in AbstractQueryCache.onTypesChanged() In-Reply-To: <1259919906.1246396727245.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/OPENJPA-1151?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Donald Woods resolved OPENJPA-1151. ----------------------------------- Resolution: Fixed Trunk tests applied as r814807. > Cache the current-time timestamp in AbstractQueryCache.onTypesChanged() > ----------------------------------------------------------------------- > > Key: OPENJPA-1151 > URL: https://issues.apache.org/jira/browse/OPENJPA-1151 > Project: OpenJPA > Issue Type: Improvement > Components: jdbc > Affects Versions: 1.3.0, 2.0.0 > Reporter: Jody Grassel > Assignee: Donald Woods > Priority: Trivial > Fix For: 1.3.0, 2.0.0-M3 > > Attachments: OpenJPA-trunk-JIRA1151-tests.patch, OpenJPA-trunk-JIRA1151.patch > > > AbstractQueryCache.java contains the following block: > for (Object o: changedTypes) { > String name = ((Class) o).getName(); > if(!changedClasses.containsKey(name)) > changedClasses.put(name, > new Long(System.currentTimeMillis())); > } > Suggesting caching the Long containing the entity type's last-modification timestamp outside of the for-loop to improve performance and reduce memory usage. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.