module documentation

Block device abstraction - base class and utility functions

Class BlockDev Block device abstract class.
Function IgnoreError Executes the given function, ignoring BlockDeviceErrors.
Function ThrowError Log an error to the node daemon and the raise an exception.
def IgnoreError(fn, *args, **kwargs):

Executes the given function, ignoring BlockDeviceErrors.

This is used in order to simplify the execution of cleanup or rollback functions.

Returns
booleanTrue when fn didn't raise an exception, False otherwise
def ThrowError(msg, *args):

Log an error to the node daemon and the raise an exception.

Parameters
msg:stringthe text of the exception @raise errors.BlockDeviceError
*argsUndocumented