|
|||||||||
| Home >> All >> org >> apache >> derby >> iapi >> store >> [ access overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.apache.derby.iapi.store.access
Interface AccessFactory

- public interface AccessFactory
Module interface for an access manager. An access manager provides transactional access via access methods to data in a single storage manager.
An AccessFactory is typically obtained from the Monitor:
// Get the current transaction controller.
AccessFactory af;
af = (AccessFactory) Monitor.findServiceModule(this, AccessFactory.MODULE);
| Field Summary | |
static java.lang.String |
MODULE
Used to identify this interface when finding it with the Monitor. |
| Method Summary | |
void |
backup(java.io.File backupDir)
Backup the database to backupDir. |
void |
backup(java.lang.String backupDir)
Backup the database to backupDir. |
void |
backupAndEnableLogArchiveMode(java.io.File backupDir,
boolean deleteOnlineArchivedLogFiles)
Backup the database to a backup directory and enable the log archive mode that will keep the archived log files required for roll-forward from this version backup. |
void |
backupAndEnableLogArchiveMode(java.lang.String backupDir,
boolean deleteOnlineArchivedLogFiles)
Backup the database to a backup directory and enable the log archive mode that will keep the archived log files required for roll-forward from this version backup. |
void |
checkpoint()
Checkpoints the database, that is, flushes all dirty data to disk. |
void |
createFinished()
Database creation has finished. |
void |
disableLogArchiveMode(boolean deleteOnlineArchivedLogFiles)
disables the log archival process, i.e No old log files will be kept around for a roll-forward recovery. |
org.apache.derby.iapi.store.access.conglomerate.MethodFactory |
findMethodFactoryByFormat(org.apache.derby.catalog.UUID format)
Find an access method that implements a format type. |
org.apache.derby.iapi.store.access.conglomerate.MethodFactory |
findMethodFactoryByImpl(java.lang.String impltype)
Find an access method that implements an implementation type. |
void |
freeze()
Freeze the database temporarily so a backup can be taken. |
TransactionController |
getAndNameTransaction(org.apache.derby.iapi.services.context.ContextManager cm,
java.lang.String transName)
Get a transaction. |
org.apache.derby.iapi.services.locks.LockFactory |
getLockFactory()
Get the LockFactory to use with this store. |
TransactionController |
getTransaction(org.apache.derby.iapi.services.context.ContextManager cm)
Get a transaction controller with which to manipulate data within the access manager. |
TransactionInfo[] |
getTransactionInfo()
Return a snap shot of all transactions in the db. |
java.lang.Object |
getXAResourceManager()
Return the XAResourceManager associated with this AccessFactory. |
boolean |
isReadOnly()
Is the store read-only. |
void |
registerAccessMethod(org.apache.derby.iapi.store.access.conglomerate.MethodFactory factory)
Register an access method that this access manager can use. |
java.lang.Object |
startXATransaction(org.apache.derby.iapi.services.context.ContextManager cm,
int format_id,
byte[] global_id,
byte[] branch_id)
Start a global transaction. |
void |
unfreeze()
Unfreeze the database after a backup has been taken. |
void |
waitForPostCommitToFinishWork()
|
| Field Detail |
MODULE
public static final java.lang.String MODULE
- Used to identify this interface when finding it with the Monitor.
- See Also:
- Constant Field Values
| Method Detail |
registerAccessMethod
public void registerAccessMethod(org.apache.derby.iapi.store.access.conglomerate.MethodFactory factory)
- Register an access method that this access manager can use.
createFinished
public void createFinished()
throws org.apache.derby.iapi.error.StandardException
- Database creation has finished.
findMethodFactoryByImpl
public org.apache.derby.iapi.store.access.conglomerate.MethodFactory findMethodFactoryByImpl(java.lang.String impltype) throws org.apache.derby.iapi.error.StandardException
- Find an access method that implements an implementation type.
findMethodFactoryByFormat
public org.apache.derby.iapi.store.access.conglomerate.MethodFactory findMethodFactoryByFormat(org.apache.derby.catalog.UUID format)
- Find an access method that implements a format type.
getLockFactory
public org.apache.derby.iapi.services.locks.LockFactory getLockFactory()
- Get the LockFactory to use with this store.
getXAResourceManager
public java.lang.Object getXAResourceManager() throws org.apache.derby.iapi.error.StandardException
- Return the XAResourceManager associated with this AccessFactory.
Returns an object which can be used to implement the "offline" 2 phase commit interaction between the accessfactory and outstanding transaction managers taking care of in-doubt transactions.
isReadOnly
public boolean isReadOnly()
- Is the store read-only.
getTransaction
public TransactionController getTransaction(org.apache.derby.iapi.services.context.ContextManager cm) throws org.apache.derby.iapi.error.StandardException
- Get a transaction controller with which to manipulate data within
the access manager. Implicitly creates an access context if one
does not already exist.
getAndNameTransaction
public TransactionController getAndNameTransaction(org.apache.derby.iapi.services.context.ContextManager cm, java.lang.String transName) throws org.apache.derby.iapi.error.StandardException
- Get a transaction. If a new transaction is
implicitly created, give it name transName.
getTransactionInfo
public TransactionInfo[] getTransactionInfo()
- Return a snap shot of all transactions in the db.
Take a snap shot of all transactions currently in the database and make a record of their information.
startXATransaction
public java.lang.Object startXATransaction(org.apache.derby.iapi.services.context.ContextManager cm, int format_id, byte[] global_id, byte[] branch_id) throws org.apache.derby.iapi.error.StandardException
- Start a global transaction.
Get a transaction controller with which to manipulate data within the access manager. Implicitly creates an access context.
Must only be called if no other transaction context exists in the current context manager. If another transaction exists in the context an exception will be thrown.
The (format_id, global_id, branch_id) triplet is meant to come exactly from a javax.transaction.xa.Xid. We don't use Xid so that the system can be delivered on a non-1.2 vm system and not require the javax classes in the path.
If the global transaction id given matches an existing in-doubt global transaction in the current system, then a StandardException will be thrown with a state of SQLState.STORE_XA_XAER_DUPID.
freeze
public void freeze()
throws org.apache.derby.iapi.error.StandardException
- Freeze the database temporarily so a backup can be taken.
Please see cloudscape on line documentation on backup and restore.
unfreeze
public void unfreeze()
throws org.apache.derby.iapi.error.StandardException
- Unfreeze the database after a backup has been taken.
Please see cloudscape on line documentation on backup and restore.
backup
public void backup(java.lang.String backupDir) throws org.apache.derby.iapi.error.StandardException
- Backup the database to backupDir.
Please see cloudscape on line documentation on backup and restore.
backup
public void backup(java.io.File backupDir) throws org.apache.derby.iapi.error.StandardException
- Backup the database to backupDir.
Please see cloudscape on line documentation on backup and restore.
backupAndEnableLogArchiveMode
public void backupAndEnableLogArchiveMode(java.lang.String backupDir, boolean deleteOnlineArchivedLogFiles) throws org.apache.derby.iapi.error.StandardException
- Backup the database to a backup directory and enable the log archive
mode that will keep the archived log files required for roll-forward
from this version backup.
backupAndEnableLogArchiveMode
public void backupAndEnableLogArchiveMode(java.io.File backupDir, boolean deleteOnlineArchivedLogFiles) throws org.apache.derby.iapi.error.StandardException
- Backup the database to a backup directory and enable the log archive
mode that will keep the archived log files required for roll-forward
from this version backup.
disableLogArchiveMode
public void disableLogArchiveMode(boolean deleteOnlineArchivedLogFiles)
throws org.apache.derby.iapi.error.StandardException
- disables the log archival process, i.e No old log files
will be kept around for a roll-forward recovery.
checkpoint
public void checkpoint()
throws org.apache.derby.iapi.error.StandardException
- Checkpoints the database, that is, flushes all dirty data to disk.
Records a checkpoint in the transaction log, if there is a log.
waitForPostCommitToFinishWork
public void waitForPostCommitToFinishWork()
|
|||||||||
| Home >> All >> org >> apache >> derby >> iapi >> store >> [ access overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC