3 ms·
If you tell your Java application server "here you have 4GB, use it as you wish" it will happily comply and trade memory for performance. In most of the cases
by levosmetalo 8y ago
If you tell your Java application server "here you have 4GB, use it as you wish" it will happily comply and trade memory for performance.
In most of the cases it's just a matter of setting a few Java runtime startup parameters.
- sirk390 8y agoIt's disrespectful to take 4GB if you don't need it. This should never be the default...
- boobsbr 8y agoRead the comment again: > If you tell your Java application server "here you have 4GB, use it as you wish"
- bloomthrowaway 8y agoIt's the default because in any garbage collected language you can delay taking out the trash as long as you want... as long as you have memory. The most efficient thing to do is never run the collector at all. JS does frequent GC cycles because its unacceptable to let a webpage eat all the ram. Not sure why Go collects so frequently. Java's default IMO is the most reasonable of the three. If you have a server with 4gb the best choice is to let the garbage collector use all of it