java.io.Externalizable
, java.io.Serializable
, Formatable
, TypedFormat
, Loggable
ContainerOperation
, ContainerUndoOperation
public abstract class ContainerBasicOperation extends java.lang.Object implements Loggable
Modifier and Type | Field | Description |
---|---|---|
protected RawContainerHandle |
containerHdl |
|
protected ContainerKey |
containerId |
|
private long |
containerVersion |
|
private boolean |
foundHere |
ABORT, BI_LOG, CHECKSUM, COMMIT, COMPENSATION, FILE_RESOURCE, FIRST, LAST, PREPARE, RAWSTORE, XA_NEEDLOCK
Modifier | Constructor | Description |
---|---|---|
|
ContainerBasicOperation() |
|
protected |
ContainerBasicOperation(RawContainerHandle hdl) |
Modifier and Type | Method | Description |
---|---|---|
protected RawContainerHandle |
findContainer(Transaction tran) |
Open the container with this segmentId and containerId.
|
protected RawContainerHandle |
findContainerForRedoRecovery(RawTransaction tran) |
Subclass (e.g., ContainerOperation) that wishes to do something abou
missing container in load tran should override this method to return
the recreated container
|
ByteArray |
getPreparedLog() |
the default for prepared log is always null for all the operations
that don't have optionalData.
|
int |
group() |
A space operation is a RAWSTORE log record
|
boolean |
needsRedo(Transaction xact) |
Determine if the operation should be reapplied in recovery redo.
|
void |
readExternal(java.io.ObjectInput in) |
|
void |
releaseResource(Transaction tran) |
Release any resource that was acquired for doMe for rollback or
recovery redo.
|
java.lang.String |
toString() |
|
void |
writeExternal(java.io.ObjectOutput out) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getTypeFormatId
private long containerVersion
protected ContainerKey containerId
protected transient RawContainerHandle containerHdl
private transient boolean foundHere
protected ContainerBasicOperation(RawContainerHandle hdl) throws StandardException
StandardException
public ContainerBasicOperation()
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
writeExternal
in interface java.io.Externalizable
java.io.IOException
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException
readExternal
in interface java.io.Externalizable
java.io.IOException
java.lang.ClassNotFoundException
public ByteArray getPreparedLog()
getPreparedLog
in interface Loggable
public void releaseResource(Transaction tran)
Loggable
releaseResource
in interface Loggable
public int group()
protected RawContainerHandle findContainer(Transaction tran) throws StandardException
StandardException
- the container cannot be found or cannot be
opened.protected RawContainerHandle findContainerForRedoRecovery(RawTransaction tran) throws StandardException
StandardException
- Standard Derby error policypublic boolean needsRedo(Transaction xact) throws StandardException
Loggable
The sequence of events in recovery redo of a Loggable operation is:
needsRedo
in interface Loggable
xact
- The transaction trying to redo this operationStandardException
- Standard Derby error policyLoggable.releaseResource(org.apache.derby.iapi.store.raw.Transaction)
public java.lang.String toString()
toString
in class java.lang.Object
Apache Derby V10.14 Internals - Copyright © 2004,2018 The Apache Software Foundation. All Rights Reserved.