Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

10
  • Its very memory intensive scenario and on top of that you are using a vm for running the application, wow. Anyways, did you explore memcached for storing the packets. Basically you can run memcached on a separate machine and the application can keep running on the vm itself. Commented Mar 14, 2012 at 7:07
  • As you've tried both MySQL and MongoDB already, it would seem that maybe the requirements of your application (if you want to do it right) dictate that you simply need more horsepower. If your application is important to you, beef up the server. You also might want to revisit your "purging" code. I'm sure you could find a more optimized way of handling that, insofar that it doesn't make your app unusable. Commented Mar 14, 2012 at 7:13
  • 4
    What does your profiler tell you? Commented Mar 15, 2012 at 13:08
  • You won't get anything faster than local heap. My suggestion would be to manually invoke garbage collection after purging. Commented Mar 15, 2012 at 13:20
  • @vartec - as a matter of fact, contrary to the popular belief, manually invoking garbage collector does not actually guarantee immediate, well...garbage collection. The GC might defer the action to a later period according to own gc algorithm. Invoking it every 5 minutes might even add to the strain, instead of relieving it. Just saying ;) Commented Mar 15, 2012 at 21:57