Liking cljdoc? Tell your friends :D

fluree.db.storage.core


blockclj/s

(block conn network dbid block)

Reads a single block from storage

Reads a single block from storage
raw docstring

block-rangeclj/s

(block-range conn network dbid start)
(block-range conn network dbid start end)

Returns a channel that will contains blocks in specified range.

Returns a channel that will contains blocks in specified range.
raw docstring

block-storage-pathclj

(block-storage-path network dbid)

For a ledger server, will return the relative storage path it is using for blocks for a given ledger.

For a ledger server, will return the relative storage path it is using for blocks for a given ledger.
raw docstring

child-dataclj/s

(child-data child)

Given a child, unresolved node, extracts just the data that will go into storage.

Given a child, unresolved node, extracts just the data that will go into storage.
raw docstring

ledger-block-file-pathclj/s

(ledger-block-file-path network ledger-id block)

ledger-block-keyclj/s

(ledger-block-key network ledger-id block)

ledger-garbage-keyclj/s

(ledger-garbage-key network ledger-key block)

ledger-node-keyclj/s

(ledger-node-key network ledger-id idx-type base-id node-type)

ledger-root-keyclj/s

(ledger-root-key network ledger-id block)

read-blockclj/s

(read-block conn network ledger-id block)

Returns a core async channel with the requested block.

Returns a core async channel with the requested block.
raw docstring

read-block-versionclj/s

(read-block-version conn network ledger-id block version)

Returns a core async channel with the requested block.

Returns a core async channel with the requested block.
raw docstring

read-branchclj/s

(read-branch conn key)

Reads and deserializes branch node.

Reads and deserializes branch node.
raw docstring

read-db-rootclj/s

(read-db-root conn network dbid block)

Returns all data for a db index root of a given block.

Returns all data for a db index root of a given block.
raw docstring

read-garbageclj/s

(read-garbage conn network dbid block)

Returns a all data for a db index root of a given block.

Returns a all data for a db index root of a given block.
raw docstring

read-leafclj/s

(read-leaf conn key)

Reads and deserializes a leaf node

Reads and deserializes a leaf node
raw docstring

reify-branchclj/s

(reify-branch conn
              config
              network
              dbid
              key
              block
              t
              tt-id
              leftmost?
              tempid
              error-fn)

Should throw if no result... should never be the case.

Should throw if no result... should never be the case.
raw docstring

reify-dbclj/s

(reify-db conn network dbid blank-db index)

Reifies db at specified index point. If unable to read db-root at index, throws.

Reifies db at specified index point. If unable to read db-root at index, throws.
raw docstring

reify-db-rootclj/s

(reify-db-root conn blank-db root-data)

Constructs db from blank-db, and ensure index roots have proper config as unresolved nodes.

Constructs db from blank-db, and ensure index roots have proper config as unresolved nodes.
raw docstring

reify-historyclj/s

(reify-history conn key error-fn)

reify-index-rootclj/s

(reify-index-root conn index-configs network dbid index index-data block t)

Turns each index root node into an unresolved node.

Turns each index root node into an unresolved node.
raw docstring

reify-leafclj/s

(reify-leaf conn config key block t rhs error-fn)

Should throw if no result... should never be the case.

Should throw if no result... should never be the case.
raw docstring

resolve-history-rangeclj/s

(resolve-history-range node from-t to-t idx-novelty leftmost?)

Gets a history slice of a node with the oldest 't' from-t, to the most recent 't', to-t.

Returns sorted set in novelty's sort order (spot, psot, post, or opst)

Gets a history slice of a node with the oldest 't' from-t, to the
most recent 't', to-t.

Returns sorted set in novelty's sort order (spot, psot, post, or opst)
raw docstring

resolve-tclj/s

(resolve-t node t idx-novelty rhs leftmost? remove-preds error-fn)

resolve-to-tclj/s

(resolve-to-t node
              id
              tempid
              rhs
              leftmost?
              t
              tt-id
              idx-novelty
              conn
              fast-foward-db?
              remove-preds)

serdeclj/s

(serde conn)

Returns serializer from connection.

Returns serializer from connection.
raw docstring

source-novelty-tclj/s

(source-novelty-t novelty first-flake rhs leftmost?)
(source-novelty-t novelty first-flake rhs leftmost? through-t)

Given a novelty set, a first-flake and rhs flake boundary, returns novelty subrange as a collection.

If through-t is specified, will return novelty only through the specified t.

Given a novelty set, a first-flake and rhs flake boundary,
returns novelty subrange as a collection.

If through-t is specified, will return novelty only through the
specified t.
raw docstring

storage-exists?clj/s

(storage-exists? conn key)

Returns truthy if the provided key exists in storage.

Returns truthy if the provided key exists in storage.
raw docstring

storage-readclj/s

(storage-read conn key)

Reads raw bytes from storage based on provided key. Returns core async channel with eventual response

Reads raw bytes from storage based on provided key.
Returns core async channel with eventual response
raw docstring

storage-writeclj/s

(storage-write conn key val)

Writes raw bytes to storage based with provided key.

Writes raw bytes to storage based with provided key.
raw docstring

UnresolvedNodeclj/s


write-blockclj/s

(write-block conn network dbid block-data)

Block data should look like:

{:block block (long) :flakes flakes :hash hash :sigs sigs :txns {tid (tx-id, string) {:cmd command (JSON string) :sig signature (string}]}

Block data should look like:

{:block  block (long)
 :flakes flakes
 :hash hash
 :sigs sigs
 :txns   {tid (tx-id, string)  {:cmd    command (JSON string)
                                :sig    signature (string}]}
raw docstring

write-block-versionclj/s

(write-block-version conn network dbid block-data version)

Block data should look like:

{:block block (long) :flakes flakes :hash hash :sigs sigs :txns {tid (tx-id, string) {:cmd command (JSON string) :sig signature (string}]}

Block data should look like:

{:block  block (long)
 :flakes flakes
 :hash hash
 :sigs sigs
 :txns   {tid (tx-id, string)  {:cmd    command (JSON string)
                                :sig    signature (string}]}
raw docstring

write-branchclj/s

(write-branch conn network dbid idx-type id children)

Returns core async channel with index key

Returns core async channel with index key
raw docstring

write-branch-dataclj/s

(write-branch-data conn key data)

Serializes final data for branch and writes it to provided key

Serializes final data for branch and writes it to provided key
raw docstring

write-db-rootclj/s

(write-db-root db)
(write-db-root db custom-ecount)

write-garbageclj/s

(write-garbage db {:keys [garbage] :as progress})

Writes garbage record out for latest index.

Writes garbage record out for latest index.
raw docstring

write-historyclj/s

(write-history conn history his-key next-his-key)

write-leafclj/s

(write-leaf conn network dbid idx-type id flakes history)

Writes a leaf plus its history.

Writes history first, and only on successful history write then writes leaf.

Returns leaf's key

Writes a leaf plus its history.

Writes history first, and only on successful history write then writes leaf.

Returns leaf's key
raw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close