| java.lang.Object org.apache.derby.impl.store.raw.data.ContainerBasicOperation org.apache.derby.impl.store.raw.data.ContainerOperation
ContainerOperation | public class ContainerOperation extends ContainerBasicOperation implements Undoable(Code) | | Log operation to create, drop or remove a container.
Both the doMe or the undoMe of a create actually caused the container
header to be modified and flushed before the log record is flushed. This
is necessary for 2 reasons, one is that of ensuring enough disk space, and
the other is because unlike any other operation, the log record create
container is in the log stream before the container is in the container
cache. What this mean is that if a checkpoint started after the container
operation but before the container is kept or is dirtied in the container
cache, then checkpoint will not know to wait for the container to be kept
or cleaned. The checkpoint will erroneous assume that the operation does
not need to be redone since its log instant is before the checkpoint but in
fact the change has not been flushed to disk.
A drop or remove container does not have this problem. The container exist
and is in kept state when the operation is logged so the checkpoint will
not overlook it and it doesn't need to flush the container header. In the
case of remove, the stub is flushed for a different reason - that of
ensuring disk space.
|
CREATE | final protected static byte CREATE(Code) | | |
DROP | final protected static byte DROP(Code) | | |
REMOVE | final protected static byte REMOVE(Code) | | |
hasCreateByteArray | protected transient boolean hasCreateByteArray(Code) | | |
operation | protected byte operation(Code) | | |
ContainerOperation | public ContainerOperation()(Code) | | |
getTypeFormatId | public int getTypeFormatId()(Code) | | Return my format identifier.
|
undoMe | public void undoMe(Transaction tran, RawContainerHandle hdl, LogInstant CLRInstant, LimitObjectInput in) throws StandardException(Code) | | Undo of create, drop or remove
Parameters: tran - the transaction that is undoing this operation Parameters: hdl - the container handle. This is found here during runtimeundo - in which case we made the CLR and passed in the containerHdlfound in generateUndo and it is passed back to this; or it is found inthe CLR's needsRedo and is passed in and this operation never found thecontainer. Either case, release resource at the end is safe Parameters: CLRInstant - the log instant of the CLR Parameters: in - optional data exception: StandardException - Standard Cloudscape error policy |
|
|