Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 70417 invoked from network); 8 Oct 2008 12:57:06 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 8 Oct 2008 12:57:06 -0000 Received: (qmail 59225 invoked by uid 500); 8 Oct 2008 12:57:04 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 59197 invoked by uid 500); 8 Oct 2008 12:57:04 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 59186 invoked by uid 99); 8 Oct 2008 12:57:04 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 08 Oct 2008 05:57:04 -0700 X-ASF-Spam-Status: No, hits=-1999.9 required=10.0 tests=ALL_TRUSTED,DNS_FROM_SECURITYSAGE 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; Wed, 08 Oct 2008 12:56:09 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 3504D234C211 for ; Wed, 8 Oct 2008 05:56:45 -0700 (PDT) Message-ID: <1997574139.1223470605215.JavaMail.jira@brutus> Date: Wed, 8 Oct 2008 05:56:45 -0700 (PDT) From: "Kristian Waagan (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Commented: (DERBY-2822) Add caching of store stream length in StoreStreamClob, if appropriate In-Reply-To: <17284473.1181859686124.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-2822?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12637907#action_12637907 ] Kristian Waagan commented on DERBY-2822: ---------------------------------------- It should be noted that the client driver already caches the LOB lengths (for both Clobs and Blobs). I planning to go ahead with the patch for StoreStreamClob in the embedded driver. > Add caching of store stream length in StoreStreamClob, if appropriate > --------------------------------------------------------------------- > > Key: DERBY-2822 > URL: https://issues.apache.org/jira/browse/DERBY-2822 > Project: Derby > Issue Type: Improvement > Components: JDBC > Affects Versions: 10.3.1.4 > Reporter: Kristian Waagan > Attachments: derby-2822-1a-cacheCharLength.diff > > > Currently StoreStreamClob reads the whole Clob stream, including decoding it, to find the length of it. It also does this the second time the length is asked for. > StoreStreamClob is the internal Clob representation for Clobs that are read-only. As soon as the user updates the Clob, it is transferred to a modifiable Clob representation. > It should be determined if it is safe to cache the length (both in bytes and in characters) of the store stream to improve the performance and reduce the load on Derby for certain Clob operations. > To do this, the locking mechanism used for Clobs must be analyzed. > If you have obtained a Clob object, is there a lock in place that stops others from changing the content? > For all isolation levels? > What about scrollable result sets? > Can the streamed content from store be changed under us, and thus invalidate a cached length? -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.