Return-Path: Delivered-To: apmail-ws-axis-user-archive@www.apache.org Received: (qmail 63740 invoked from network); 25 Oct 2007 08:33:18 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 25 Oct 2007 08:33:18 -0000 Received: (qmail 62928 invoked by uid 500); 25 Oct 2007 08:32:58 -0000 Delivered-To: apmail-ws-axis-user-archive@ws.apache.org Received: (qmail 62907 invoked by uid 500); 25 Oct 2007 08:32:58 -0000 Mailing-List: contact axis-user-help@ws.apache.org; run by ezmlm Precedence: bulk Reply-To: axis-user@ws.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list axis-user@ws.apache.org Received: (qmail 62896 invoked by uid 99); 25 Oct 2007 08:32:58 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 25 Oct 2007 01:32:58 -0700 X-ASF-Spam-Status: No, hits=0.2 required=10.0 tests=RCVD_IN_DNSWL_LOW,SPF_HELO_PASS,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: local policy) Received: from [195.184.96.12] (HELO smtp.webpartner.dk) (195.184.96.12) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 25 Oct 2007 08:33:01 +0000 Received: from alpha-srv200.as1.alphasolutions.dk (unknown [213.150.61.205]) by smtp.webpartner.dk (Postfix) with ESMTP id 12A2593AB69 for ; Thu, 25 Oct 2007 10:32:28 +0200 (CEST) X-MimeOLE: Produced By Microsoft Exchange V6.5.7226.0 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: [Axis2] out of memory Date: Thu, 25 Oct 2007 10:32:29 +0200 Message-ID: <5C243BD898DAAF45813B837ADC5B866B82470B@alpha-srv200.as1.alphasolutions.dk> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: [Axis2] out of memory Thread-Index: AcgW4ZSFE5qGQqdQTyyIFzMBUgZhZQ== From: "Peter A. Kirk" To: X-Virus-Checked: Checked by ClamAV on apache.org Hi I am trying to track down a "java.lang.OutOfMemoryError: Java heap space" exception in my application. I am not sure exactly where the problem lies, but possibly something to do with CodeGenerationEngine. My program generates web-services on the fly, and I use Axis2 to help me along. The out of memory problem occurs if I am generating lots of web-services in a loop. For example, if I write a large loop like the following, I get an error. (Note this is a boiled down version of my actual code which does a lot more stuff - and usually I get the exception after 20 iterations or so). Am I doing something wrong here, or is there a limitation with the CodeGenerationEngine? String[] parms =3D new String[] {"-o", "c:/temp", "-sd", "-ss", "-S", = ".", "-R", ".", "--noMessageReceiver", "--noBuildXML", "--noWSDL", "-uri", "c:/temp/exmployee.wsdl" }; CommandLineOptionParser parser =3D new CommandLineOptionParser(parms); try { for (int i=3D0;i<400;i++) { CodeGenerationEngine engine =3D new = CodeGenerationEngine(parser); engine.generate(); } } catch (Exception e) { System.out.println("Error " + e.getMessage()); } Thanks, Peter --------------------------------------------------------------------- To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org For additional commands, e-mail: axis-user-help@ws.apache.org