aspose file tools
The moose likes Java in General and the fly likes java heap memory usage Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Java in General
Reply Bookmark "java heap memory usage" Watch "java heap memory usage" New topic
Author

java heap memory usage

vijay kumar
Ranch Hand

Joined: Nov 05, 2005
Posts: 58
I'm trying to create xml file with large size .
but the size is exceeding the heap size.

how to write it directly to the file
vijay kumar
Ranch Hand

Joined: Nov 05, 2005
Posts: 58
i'm using DOM and transforming to the .xml file
Tony Morris
Ranch Hand

Joined: Sep 24, 2003
Posts: 1608
This is a known limitation of DOM.
Use SAX, or increase your heap size.


Tony Morris
Java Q&A (FAQ, Trivia)
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12271
    
    1
In many cases the simplest thing to do is just write the XML document text without ever creating a Document or a SAX event. Just make sure the structure of your program reflects the hierarchy you are trying to build in the document.
Bill


Java Resources at www.wbrogden.com
Roseanne Zhang
Ranch Hand

Joined: Nov 14, 2000
Posts: 1953
Originally posted by William Brogden:
In many cases the simplest thing to do is just write the XML document text without ever creating a Document or a SAX event. Just make sure the structure of your program reflects the hierarchy you are trying to build in the document.
Bill


Yes, that would be exact my suggestion too.
Do NOT forget xml is just a text file which follow certain rules. As long as you know what you are doing, then you can do it!!!
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: java heap memory usage
 
Similar Threads
Hibernate DB2
Eclipse 3.2 Increase Heap?
JBOSS DROOLS - java heap space
Tomcat and Optimizeit throwing Out of memory error
Analyse large heap dump file