From user-java-return-15447-apmail-ibatis-user-java-archive=ibatis.apache.org@ibatis.apache.org Tue Oct 21 15:19:29 2008 Return-Path: Delivered-To: apmail-ibatis-user-java-archive@www.apache.org Received: (qmail 45613 invoked from network); 21 Oct 2008 15:19:29 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 21 Oct 2008 15:19:29 -0000 Received: (qmail 42773 invoked by uid 500); 21 Oct 2008 15:19:30 -0000 Delivered-To: apmail-ibatis-user-java-archive@ibatis.apache.org Received: (qmail 42348 invoked by uid 500); 21 Oct 2008 15:19:28 -0000 Mailing-List: contact user-java-help@ibatis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user-java@ibatis.apache.org Delivered-To: mailing list user-java@ibatis.apache.org Received: (qmail 42337 invoked by uid 99); 21 Oct 2008 15:19:28 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 21 Oct 2008 08:19:28 -0700 X-ASF-Spam-Status: No, hits=2.0 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of jimingliu@gmail.com designates 209.85.198.243 as permitted sender) Received: from [209.85.198.243] (HELO rv-out-0708.google.com) (209.85.198.243) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 21 Oct 2008 15:18:18 +0000 Received: by rv-out-0708.google.com with SMTP id b17so2205986rvf.36 for ; Tue, 21 Oct 2008 08:18:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:in-reply-to:mime-version:content-type:references; bh=4YzLH2hQbANBw4+vLtmmNGy2iKMQ+D6UxYvQLJQMcjQ=; b=Q/emFEusgLBOOB+bzdx/l+RnecCXvEz+m/EHl/JweO1nDyjm8bWMdqKmDXdMDinRRf CL6QoP4ZKRkG4GJXILn8A3uQnK15Bd4qc4gyc/d8PUizH6QFYMLVJnycEA2zEIcAxjnX YnlUc6IaVZ2RIZiY19EtYeQV2rSEyz04pohVQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version :content-type:references; b=jb0aLaFN1qZZOyydKlKvrqTnEk0UfTrkdo9BbFfdD2Y7qacUWb1cZdSTEzpqzvmSgc POwYMOeSulAGVaz6QasGcW2FoRFIYwKAqWEgLXSciWBAg/thua8u/huH7R7SlcQnkHUV /zCrbh4hFeFaWdkTXgNmTQ5GIApiD6iqkIiGU= Received: by 10.141.152.8 with SMTP id e8mr5753447rvo.19.1224602326759; Tue, 21 Oct 2008 08:18:46 -0700 (PDT) Received: by 10.141.98.17 with HTTP; Tue, 21 Oct 2008 08:18:46 -0700 (PDT) Message-ID: Date: Tue, 21 Oct 2008 23:18:46 +0800 From: "Jiming Liu" To: user-java@ibatis.apache.org Subject: Re: Avoid java heap space while using iBatis In-Reply-To: <3BB210BC76AFA24C92269E5BE8C71E68070FAF39@PNE-HJN-MBX01.wipro.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_9434_25266128.1224602326740" References: <3BB210BC76AFA24C92269E5BE8C71E68070FAF39@PNE-HJN-MBX01.wipro.com> X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_9434_25266128.1224602326740 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline I suggest you can write/dump the records to a temp file and then implement an Iterator to read the record one after another. from the file. Best regards, Jiming Liu On Tue, Oct 21, 2008 at 10:30 PM, wrote: > Hi, > > Our project is facing a java heap space issue while fetching the record set > of around 200,000. > Using a row handler is not helpful as the same record set is being used to > plot a slider and three graphs on UI (Flex). > > increasing the heap space size is not allowed in our application as it is a > standard set by user. > > The sqlMapConfiguration has cacheModeEnabled set to true. > > Is there any way to optimize the record usage in iBatis? Can we use > multiple queryForList in a loop ? If yes, how this can be achieved? > > Thanks & Regards > Ankit > > * Please do not print this email unless it is absolutely necessary. * > > The information contained in this electronic message and any attachments to > this message are intended for the exclusive use of the addressee(s) and may > contain proprietary, confidential or privileged information. If you are not > the intended recipient, you should not disseminate, distribute or copy this > e-mail. Please notify the sender immediately and destroy all copies of this > message and any attachments. > > WARNING: Computer viruses can be transmitted via email. The recipient > should check this email and any attachments for the presence of viruses. The > company accepts no liability for any damage caused by any virus transmitted > by this email. > > www.wipro.com > ------=_Part_9434_25266128.1224602326740 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline I suggest you can write/dump the records to a temp file and then implement an Iterator to read the record one after another. from the file.

Best regards,

Jiming Liu

On Tue, Oct 21, 2008 at 10:30 PM, <ankit.khujneri@wipro.com> wrote:
Hi,
 
Our project is facing a java heap space issue while fetching the record set of around 200,000.
Using a row handler is not helpful as the same record set is being used to plot a slider and three graphs on UI (Flex).
 
increasing the heap space size is not allowed in our application as it is a standard set by user.
 
The sqlMapConfiguration has cacheModeEnabled set to true.
 
Is there any way to optimize the record usage in iBatis?  Can we use multiple queryForList in a loop ? If yes, how this can be achieved?
 
Thanks & Regards
Ankit

Please do not print this email unless it is absolutely necessary.

The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s) and may contain proprietary, confidential or privileged information. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments.

WARNING: Computer viruses can be transmitted via email. The recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email.

www.wipro.com


------=_Part_9434_25266128.1224602326740--