db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike Matrigali <mikem_...@sbcglobal.net>
Subject Re: Database creation slow using create=true - any advice?
Date Mon, 14 Feb 2005 19:06:35 GMT
Just as background, when cloudscape was created little work was done
to optimize creating the database.  The design assumption was that
create database was done once, ahead of time before performance was
critical and then most of application access would be accessing an
already existing database.

So is there anyway to change your application such that new nodes
create new tables in an existing database, rather than a whole new

Even if we turn off all synchronous I/O as dan is looking for input 
into, there is still a lot of work that goes on creating from scratch
all of the system catalogs.

A workaround that some users have done is to have a "empty" database 
stored in a known location and then just do a OS/JVM copy of the 
database to create a new instance of a database.  This is really a good
choice for applications which actually have a significant amount of user 
data template set up also.  I have seen datbase systems
which use this methodology for internal implementation of create 
database (in those systems it was a pain to the developers to make
changes to the "template" database - which is why I believe that 
approach was not chosen in cloudscape).

Darryl Pentz wrote:
> I have a tree structure in a GUI that results in a new database being created
> and loaded with records when the user clicks on certain nodes.
> Currently however, when the user clicks on the node, the bottleneck is when the
> 'create=true' call is made. This creation seems to be taking ~20secs on my
> machine, whereas if the database already exists, it takes <1sec to load and
> query the database.
> Anybody got any ideas how I can optimize this? I haven't found anything as yet.
> - Darryl

View raw message