References
| count/1 | Count the number of records from backend-db. |
| delete/2 | Delete an object from backend-db. |
| fetch/3 | Fetch objects from backend-db by key with function. |
| fetch/4 | |
| finish_compaction/2 | End the data-compaction. |
| first/1 | Retrieve a first record from backend-db. |
| first_n/2 | Fetch first N records from backend-db. |
| first_n/3 | |
| get/2 | Retrieve an object from backend-db. |
| get_db_raw_filepath/1 | get the database filepath for calculating disk size. |
| has_instance/1 | has the instance into the db. |
| new/4 | create storage-processes. |
| new/5 | |
| put/3 | Insert an object into backend-db. |
| put_value_to_new_db/3 | Put a record to a new db. |
| run_compaction/1 | Start the data-compaction. |
| status/1 | Retrieve status from backend-db. |
| status_compaction/1 | Retrieve compaction status from backend-db. |
| stop/1 | Stop the instance. |
count(InstanceName) -> Count
Count = non_neg_integer()InstanceName = atom()
Count the number of records from backend-db.
delete(InstanceName, KeyBin) -> ok | {error, any()}
InstanceName = atom()KeyBin = binary()
Delete an object from backend-db.
fetch(InstanceName, KeyBin, Fun) -> {ok, list()} | not_found | {error, any()}
InstanceName = atom()KeyBin = binary()Fun = function()
Fetch objects from backend-db by key with function.
fetch(InstanceName, KeyBin, Fun, MaxKeys) -> {ok, list()} | not_found | {error, any()}
InstanceName = atom()KeyBin = binary()Fun = function()MaxKeys = pos_integer()
finish_compaction(InstanceName, Commit) -> ok | {error, any()}
InstanceName = atom()Commit = boolean()
End the data-compaction
first(InstanceName) -> {ok, list()} | {error, any()}
InstanceName = atom()
Retrieve a first record from backend-db.
first_n(InstanceName, N) -> {ok, list()} | not_found | {error, any()}
InstanceName = atom()N = pos_integer()
Fetch first N records from backend-db.
first_n(InstanceName, N, Condition) -> {ok, list()} | not_found | {error, any()}
InstanceName = atom()N = pos_integer()Condition = function()
get(InstanceName, KeyBin) -> {ok, binary()} | not_found | {error, any()}
InstanceName = atom()KeyBin = binary()
Retrieve an object from backend-db.
get_db_raw_filepath(InstanceName) -> {ok, string()} | {error, any()}
InstanceName = atom()
get the database filepath for calculating disk size
has_instance(InstanceName) -> boolean()
InstanceName = atom()
has the instance into the db
new(InstanceName, NumOfDBProcs, BackendDB, DBRootPath) -> ok | {error, any()}
InstanceName = atom()NumOfDBProcs = pos_integer()BackendDB = backend_db()DBRootPath = string()
create storage-processes.
new(InstanceName, NumOfDBProcs, BackendDB, DBRootPath, IsStrictCheck) -> ok | {error, any()}
InstanceName = atom()NumOfDBProcs = pos_integer()BackendDB = backend_db()DBRootPath = string()IsStrictCheck = boolean()
put(InstanceName, KeyBin, ValueBin) -> ok | {error, any()}
InstanceName = atom()KeyBin = binary()ValueBin = binary()
Insert an object into backend-db.
put_value_to_new_db(InstanceName, KeyBin, ValueBin) -> ok | {error, any()}
InstanceName = atom()KeyBin = binary()ValueBin = binary()
Put a record to a new db
run_compaction(InstanceName) -> ok | {error, any()}
InstanceName = atom()
Start the data-compaction
status(InstanceName) -> [{atom(), term()}]
InstanceName = atom()
Retrieve status from backend-db.
status_compaction(InstanceName) -> [{atom(), term()}]
InstanceName = atom()
Retrieve compaction status from backend-db.
stop(InstanceName) -> ok | {error, any()}
InstanceName = atom()
Stop the instance
Generated by EDoc