Derby database directory on Tomcat ?

View: New views
3 Messages — Rating Filter:   Alert me  

Derby database directory on Tomcat ?

by Albert Kam :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hello,

I'm currently engaged with using embedded Derby on Tomcat.
Fortunately i found out about this helpful web :
http://db.apache.org/derby/integrate/DerbyTomcat5512JPetStor.html
And it just makes things easier.

Anyway, i just want to ask whether there's a clean place to specify the location of
the derby database directory ?
In the tutorial link above, it says copy the database directory in the Tomcat_Home directory.
But in my experience, the directory which i use to start tomcat is used for the base directory for the
derby database.

Do i have to start tomcat with the -Dderby.system.home in the catalina.sh or is there any other way ?

Thank you,
Albert Kam

--
Do not pursue the past. Do not lose yourself in the future.
The past no longer is. The future has not yet come.
Looking deeply at life as it is in the very here and now,
the practitioner dwells in stability and freedom.
(Thich Nhat Hanh)

Re: Derby database directory on Tomcat ?

by Donald McLean-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Thu, Jun 26, 2008 at 12:52 AM, Albert Kam <moonblade.wolf@...> wrote:
>
> Anyway, i just want to ask whether there's a clean place to specify the
> location of
> the derby database directory ?

In the URL. See, for example, the source code for DatabaseManager:

http://wiki.apache.org/db-derby/DatabaseManagerSource

In the function createURL, the database location is specified by a File.

Donald

Parent Message unknown Re: Derby database directory on Tomcat ?

by Albert Kam :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thanks !

--
Do not pursue the past. Do not lose yourself in the future.
The past no longer is. The future has not yet come.
Looking deeply at life as it is in the very here and now,
the practitioner dwells in stability and freedom.
(Thich Nhat Hanh)
LightInTheBox - Buy quality products at wholesale price