Performance issues using H2 DB in embedded mode with heavy load of data in database

匆匆过客 提交于 2019-12-03 00:31:52

In most cases, performance problems are not actually related to the cache size or page size. To analyze performance problems, see the H2 documentation, specially:

If you set the cache size manually to 1024 * 1024, then H2 will use 1 GB heap memory. This setting should only be use if you have a lot more than 1 GB of physical memory available to the JVM (using java -Xmx2048m or similar). Otherwise, I suggest to use the default settings (16 MB cache size) instead.

Using a smaller page size than the default might decrease performance. This depends on the hard disk, and possibly on the access pattern. However, there is no list of rules when to use a non-default page size - the only way to find out is to try different settings.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!