Open GoogleCodeExporter opened 8 years ago
Jaime sez:
Well... we actually know why its running out of memory :). We didn't have time
to implement garbage collection of file edit sessions.
I also suspect a leak in vertx itself (or our usage of the event bus).
I would actually posit that the proper fix should be to plug the memory leaks.
It has enough memory by default.
Original comment by dragonsinth
on 5 Jul 2012 at 5:16
When I received OOM errors in amazon, it was using a free tier app when there
were many users hitting the site across many open files.
I've had it running in the background now all day, with only one user editing
at a time.
It's been up for ~24 hours, and currently has 860M virtual memory, 97m
reserved, and 13M shared. Wherever the leak, it only seems to crash the app
under heavy load.
Perhaps a LinkedHashMap used as an LRU cache could be a good option for caching
file edit sessions? That way, a global maximum of say, 64 sessions could be
left open.
It might be wise to have a config file, so users can specify the amount of
memory to use in the jvm, and the number of edit sessions to cache?
Original comment by Ja...@wetheinter.net
on 6 Jul 2012 at 9:45
A smart cache could even use a combination of SoftReferences and heuristics
to manage the set of open sessions without configuration.
Original comment by dragonsinth
on 6 Jul 2012 at 11:15
Original issue reported on code.google.com by
dragonsinth
on 5 Jul 2012 at 5:00