Plasma GitLab Archive
Projects Blog Knowledge

Class type Nn_state.bm_view_t


class type bm_view_t = object .. end
View on blockmap state:
Inherits
method blockmap_get_e : identity:string -> Nn_blockmap.blockmap_t Uq_engines.engine
Get the contents of the blockalloc table for this datastore identity, wrapped into a blockmap_t object
method blockmap_alloc_e : inode:int64 ->
rpolicy:Nn_alloc_types.rpolicy ->
index:int64 ->
number:int ->
pref:string list ->
Nn_alloc_types.transacted_datastores ->
Nn_blockmap.reserve_info -> Nn_blocklist.blocklist Uq_engines.engine
Reserve blocks and allocate at commit time. index is the first index number to use in the returned list of blocks, index+number-1 is the last index number. For each index blocks are allocated on the datanodes according to rpolicy (usually with replicas). At reservation time, only the blockmap is updated; at commit time the blockalloc database table. The blocks are not associated with inodes yet.

pref: list of preferred datanodes, given as identity strings.

reserve_info: gives hints where to allocate blocks

method blockmap_allocsize : int
Returns the allocation size
method blockmap_dealloc_e : inode:int64 -> (string * int64 * int64) list -> unit Uq_engines.engine
Mark blocks and deallocate at commit time. The passed list consists of pairs (identity,block,number).
method blockmap_load_e : unit -> unit Uq_engines.engine
Ensures that all known blockmaps are loaded
method blockmap_keep : inode:int64 -> (string * int64 * int64) list -> unit
Marks these blocks as "to keep" until commit/rollback. It is required that the maps were loaded first (blockmap_load_e).
This web site is published by Informatikbüro Gerd Stolpmann
Powered by Caml