Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

java.lang.OutOfMemoryError

 
Jason Marshall
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Partners,

If I run Roberto Perillo Test case more than say 70 times as shown below.



I get the below error message.. Is this normal, I am doing calls to System.gc() and I know we cannot control this, I have tried to null all variables inside of my functions. Is this happening due to the share number of threads being created? I am working on a Dell Inspiron, XP3, 1GB Memory.

Exception in thread "Thread-264" java.lang.OutOfMemoryError: Java heap space
at suncertify.db.RoomFileAccess.updateRoomList(RoomFileAccess.java:140)
at suncertify.db.RoomFileAccess.deleteRecord(RoomFileAccess.java:461)
at suncertify.db.Data.deleteRecord(Data.java:91)
at suncertify.db.DataClassTest$DeletingRecord1Thread.run(DataClassTest.java:253)
BUILD STOPPED (total time: 1 minute 2 seconds)


Thanks Jason
 
Roel De Nijs
Sheriff
Posts: 9928
112
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jason,

If your program throws such an exception, is it always originating in the same method (updateRoomList) or is it just randomly.

Regards,
Roel
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic