users@glassfish.java.net

location/use of configuration files

From: <glassfish_at_javadesktop.org>
Date: Sat, 10 Jul 2010 21:30:43 PDT

Hi there,
I am very new to java ee and glassfish. I have an existing webstart app that accesses a mysql database directly - I know this is bad, but it was all I knew at the time. I am trying to port the direct database connection to java ee calls and am making some progress. I have a couple of questions, however:

1) I want the database connectivity info in a configuration file on the server side: where do I put this file? I tried to locate it in the same directory as the manifest, but that didn't work.

2) In general, is this a good idea? Every time a client makes a call to the server, the server needs to open this file to get the database info. Is there a way to persist this on the server? If you do this, what if you change the credentials of the database user you are logging in as? How do you tell the server the user is is using has changed his password?


thanks for any help you may have!

Jordan
[Message sent by forum member 'jordanthompson']

http://forums.java.net/jive/thread.jspa?messageID=477270