Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Memory Leak Issues

 
Viswas majrekar
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Eveyone,

Can you please give me solution for this issue,

In my application i used Tomcat, JSF framework, Hibernate, MySQL.

We are getting memory leak issues in the application, because of this application also very slow.

So please any one guide me how can i solve this issue.

Waiting for reply.
 
Rob Spoor
Sheriff
Pie
Posts: 20667
65
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you closing all of your resources (input streams, output streams, readers, writers, result sets, statements, connections) when you're finished with them?
 
vikram Kesav
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check also for any recursive call in your application if any.
Nullify object after its uses.
 
Tanzy Akhtar
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Viswas,

You may also cache some data which are same in different calls.
Simply use hash map to cache data.


Thanks,
Tanzy.
 
Anirvan Majumdar
Ranch Hand
Posts: 261
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For starters - run a profiler to accurately figure out where and what exactly is causing the memory leak[s]. There are many freely available memory profilers, written in Java. Pick one and then post the results back, so that you can be suggested some appropriate solution, instead of turning this post into a general discussion about memory leaks in Java!
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic