From e6b87084455acb79e0be902e127f295dea8d4436 Mon Sep 17 00:00:00 2001 From: mdb Date: Sun, 3 Mar 2002 16:03:14 +0000 Subject: [PATCH] Check that we can get our database connection before starting to do anything. git-svn-id: https://samskivert.googlecode.com/svn/trunk@629 6335cc39-0255-0410-8fd6-9bcaacd3b74c --- projects/robodj/src/java/robodj/repository/Repository.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/projects/robodj/src/java/robodj/repository/Repository.java b/projects/robodj/src/java/robodj/repository/Repository.java index 2b51f241..1c4b9565 100644 --- a/projects/robodj/src/java/robodj/repository/Repository.java +++ b/projects/robodj/src/java/robodj/repository/Repository.java @@ -1,5 +1,5 @@ // -// $Id: Repository.java,v 1.10 2002/02/22 07:28:29 mdb Exp $ +// $Id: Repository.java,v 1.11 2002/03/03 16:03:14 mdb Exp $ package robodj.repository; @@ -47,6 +47,10 @@ public class Repository extends JORARepository throws PersistenceException { super(provider, REPOSITORY_DB_IDENT); + + // make sure we can get our database connection + Connection conn = provider.getConnection(REPOSITORY_DB_IDENT); + provider.releaseConnection(REPOSITORY_DB_IDENT, conn); } protected void createTables (Session session)