db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matt Sanford <mzsanf...@aol.com>
Subject Re: Running 2 Derby instances on 1 JVM, do system properties cut it??
Date Wed, 22 Mar 2006 19:11:58 GMT
Hello,

    I currently use two separate databases from within the same JVM by 
specifying absolute database names (rather than derby.system.home and a 
relative path). This keeps my files separated and seems to work very 
well. Is there some monitor locking within Derby that is essentially 
synchronizing these under the covers ? I have seen a performance 
improvement so I suspect that if there is it is minimal.
    In my case I found much of my time was spent waiting on my static DB 
class. To fix it I open multiple databases and choose them using a hash 
of one of my key fields. works like a charm.

Cheers;
  -- Matt Sanford

David.Vancouvering@Sun.COM wrote:
> Hi, Hiram.  You have hit on an issue that prevents multiple databases 
> from being run within the same VM.  This is something we want to fix 
> in Derby, but it's a fairly big effort.
>
> As it stands the only way to configure the Derby database home is with 
> system properties.  So all uses of Derby within a given VM must access 
> the same database home and use the same system-wide configuration.
>
> David
>
> Hiram Chirino wrote:
>> Hi Everybody,
>>
>> ActiveMQ makes extensive use of Derby for storage of it's persistent
>> messages.  You have have done a great job with Derby!  Thanks for the
>> hard work!
>>
>> One of the things that ActiveMQ supports is running multiple brokers
>> on 1 JVM.  In that case we would actually like to run 2 derby
>> instances with different data directories.  It seems that currently we
>> have to set the "derby.system.home" to configure where the data files
>> should go.  This does not seem to lend itself to supporting multiple
>> derby instances with each with it's own data directory.  Is it
>> possible to fully configure derby without using System properties??
>>
>> -- 
>> Regards,
>> Hiram

-- 


We love flattery, even though we are not deceived by it, 
because it shows that we are of importance enough 
to be courted.

    -Ralph Waldo Emerson, writer and philosopher (1803-1882)


Mime
View raw message