Cache on a H2 Server with multiple Databases

59 views
Skip to first unread message

Wolfgang Pedot

unread,
Jun 26, 2012, 4:19:52 AM6/26/12
to h2-da...@googlegroups.com
Hi,

since the cache-size is set per database in H2 I am wondering what happens if there are multiple databases on a single TCP-Server.
Does each database have its own cache or do they share a cache-pool and if there is a pool how can I configure its size?

Spezifically I need to know if consolidating several embedded databases with separate caches into a single server will change anything in the caching.
I have not found any documentation about this so far, if there is just point me in the right direction.

regards
Wolfgang



Thomas Mueller

unread,
Jun 28, 2012, 4:23:36 PM6/28/12
to h2-da...@googlegroups.com
Hi,

Does each database have its own cache

Yes.
 
or do they share a cache-pool

No.

Spezifically I need to know if consolidating several embedded databases with separate caches into a single server will change anything in the caching.

You could combine the databases, or manage the cache yourself (but that's not so easy I guess).

Regards,
Thomas

Wolfgang Pedot

unread,
Jul 1, 2012, 10:10:23 AM7/1/12
to h2-da...@googlegroups.com
Thanks for clarifying, so by moving the databases to a server I basically get identical heap-usage for cache as the embedded version (xxMB per database).
Combining the databases is not an option, they need to stay separate.
Currently the databases have rather small caches (8MB each) but there are several Gigabytes of RAM used as Filesystem-Cache, I thought there might be a way to get a combined cache
when I move the DBs to a H2 server but I will continue using this configuration then.

thanks again
Wolfgang



Reply all
Reply to author
Forward
0 new messages