dk.netarkivet.archive.arcrepositoryadmin
Class DerbyServerSpecifics

java.lang.Object
  extended by dk.netarkivet.common.utils.SettingsFactory<DBSpecifics>
      extended by dk.netarkivet.archive.arcrepositoryadmin.DBSpecifics
          extended by dk.netarkivet.archive.arcrepositoryadmin.DerbySpecifics
              extended by dk.netarkivet.archive.arcrepositoryadmin.DerbyServerSpecifics

public class DerbyServerSpecifics
extends DerbySpecifics

Implementation of DB-specific functions for the server-based Derby.


Field Summary
 
Fields inherited from class dk.netarkivet.archive.arcrepositoryadmin.DerbySpecifics
log
 
Constructor Summary
DerbyServerSpecifics()
           
 
Method Summary
 void backupDatabase(java.sql.Connection c, java.io.File backupDir)
          Backup the database.
 java.lang.String getDriverClassName()
          Get the name of the JDBC driver class that handles interfacing to this server.
static DBSpecifics getInstance()
          Get an instance of the Server Derby specifics.
 void shutdownDatabase()
          Inherited function.
 
Methods inherited from class dk.netarkivet.common.utils.SettingsFactory
getInstance
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DerbyServerSpecifics

public DerbyServerSpecifics()
Method Detail

getInstance

public static DBSpecifics getInstance()
Get an instance of the Server Derby specifics.

Returns:
Instance of the Derby specifics implementation

shutdownDatabase

public void shutdownDatabase()
Inherited function. We do not shut down external derby databases, only the embedded ones.

Specified by:
shutdownDatabase in class DBSpecifics

backupDatabase

public void backupDatabase(java.sql.Connection c,
                           java.io.File backupDir)
                    throws ArgumentNotValid
Backup the database. For server-based databases, where the administrator is expected to perform the backups, this method should do nothing. This method gets called within one hour of the hour-of-day indicated by the DB_BACKUP_INIT_HOUR settings.

Specified by:
backupDatabase in class DBSpecifics
Parameters:
backupDir - Directory to which the database should be backed up
c - The connection to the database to backup.
Throws:
ArgumentNotValid - If the connection or the backup directory is null.

getDriverClassName

public java.lang.String getDriverClassName()
Get the name of the JDBC driver class that handles interfacing to this server.

Specified by:
getDriverClassName in class DBSpecifics
Returns:
The name of a JDBC driver class