Search in sources :

Example 1 with LogFactory

use of org.apache.derby.iapi.store.raw.log.LogFactory in project derby by apache.

the class RAMAccessManager method createReadMeFiles.

/**
 * DERBY-5996(Create readme files (cautioning users against modifying
 *  database files) at database hard upgrade time)
 * This gets called during hard upgrade. It will create 3 readme files
 *  one in database directory, one in "seg0" directory and one in log
 *  directory. These readme files warn users against touching any of
 *  files associated with derby database
 */
public void createReadMeFiles() throws StandardException {
    // creating readme in "seg0" directory
    rawstore.createDataWarningFile();
    // creating readme in log directory
    LogFactory logFactory = (LogFactory) findServiceModule(this, rawstore.getLogFactoryModule());
    logFactory.createDataWarningFile();
    // creating readme in root database directory
    DataFactory dataFactory = (DataFactory) findServiceModule(this, rawstore.getDataFactoryModule());
    PersistentService ps = getMonitor().getServiceType(rawstore);
    ps.createDataWarningFile(dataFactory.getStorageFactory());
}
Also used : LogFactory(org.apache.derby.iapi.store.raw.log.LogFactory) PersistentService(org.apache.derby.iapi.services.monitor.PersistentService) DataFactory(org.apache.derby.iapi.store.raw.data.DataFactory)

Aggregations

PersistentService (org.apache.derby.iapi.services.monitor.PersistentService)1 DataFactory (org.apache.derby.iapi.store.raw.data.DataFactory)1 LogFactory (org.apache.derby.iapi.store.raw.log.LogFactory)1