Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / April 2007

Tip: Looking for answers? Try searching our database.

RDBMS selection

Thread view: 
Martin Gregorie - 24 Apr 2007 12:10 GMT
I'm about to write a database app using Java/JDBC The DB requirements
are pretty straight: transactions, foreign keys, RI, soft DBK
generation, cursors but no need for stored procedures or triggers.

The app will consist of a scheduled update that runs every day for
minutes rather than hours and an ad-hoc query that will be used rather
less often with little or no overlap with the update task.  IOW, the
database will be idle much longer than  it will be busy.

I'm intending to use either Postgresql or Derby and I'm interested in
the resource consumption of these two when they are idle:
- Postgresql runs as a permanent daemon, so does it absorb RAM or cycles
  when its idle or does it swap out entirely?
- Derby can run as a permanent daemon but it can also be used as part of
  the app, which would not use any resource when idle but startup and
  shutdown time becomes an issue

Any feedback of experience round this area would be helpful.

BTW, this is posted to both c.l.j.p and u.c.o.l because both NGs have
knowledgeable members on this topic but, I suspect, little overlap
amongst their regulars.

Signature

martin@   | Martin Gregorie
gregorie. | Essex, UK
org       |

Simon Brooke - 24 Apr 2007 19:27 GMT
> I'm about to write a database app using Java/JDBC The DB requirements
> are pretty straight: transactions, foreign keys, RI, soft DBK
[quoted text clipped - 4 lines]
> less often with little or no overlap with the update task.  IOW, the
> database will be idle much longer than  it will be busy.

The answer is write your application for as near as possible ANSI 92 SQL,
and use JDBC. Then you can try both Postgres and Derby solutions and
choose which one seems better to you.

My preference is Postgres (and has been for twelve years now) - but I write
all my SQL source files using a set of text macros which cover all the
main areas where databases typically diverge from ANSI 92, so that it's
exceedingly easy to switch to a different backend.

http://pres.cvs.sourceforge.net/pres/pres/src/sql/babelql.pp?revision=1.5&view=markup

Doing anything which hardwires your dependence on a particular database
engine is a bad idea, in my opinion.

Signature

simon@jasmine.org.uk (Simon Brooke) http://www.jasmine.org.uk/~simon/

       ;; I can't work yanks out......
       ;; Why do they frown upon sex yet relish violence?
                                       ;; Deep Fried Lettuce

Martin Gregorie - 25 Apr 2007 12:32 GMT
> Doing anything which hardwires your dependence on a particular database
> engine is a bad idea, in my opinion.

Thanks for your comments. I know ODBC tolerably well, but this will be
my first JDBC project.

I've been intending to do the typical ODBC trick of using a common SQL
subset from within the Java programs and accepting that DBMS management
scripts and the schema definition would probably not be particularly
portable.

I'll start off using Postgres (it was installed when I installed FC6).
I've been reading its manuals and I'm impressed with what I've seen so far.

Signature

martin@   | Martin Gregorie
gregorie. | Essex, UK
org       |

Tim Southerwood - 25 Apr 2007 13:05 GMT
>  >
>> Doing anything which hardwires your dependence on a particular database
[quoted text clipped - 11 lines]
> I've been reading its manuals and I'm impressed with what I've seen so
> far.

Postgres over JDBC seems to work reliably IME so it's a fairly safe bet.

Read up on pg_dump so you can get your database back when you trask it :)

Cheers

Tim


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.