Liking cljdoc? Tell your friends :D

asami.durable.store

The implements the Block storage version of a Graph/Database/Connection

The implements the Block storage version of a Graph/Database/Connection
raw docstring

as-of*clj/s

(as-of* {{:keys [tx-manager] :as connection} :connection
         bgraph :bgraph
         timestamp :timestamp
         t :t
         :as database}
        t-val)

Inputs: [{{:keys [tx-manager], :as connection} :connection, bgraph :bgraph, timestamp :timestamp, t :t, :as database} :- DatabaseType t-val] Returns: DatabaseType

Returns a database value for a provided t-value. If t-val is the transaction number for an older database, then returns that database. Otherwise, will return this database If t-val is a timestamp then returns the most recent database that was valid at that time.

Inputs: [{{:keys [tx-manager], :as connection} :connection, bgraph :bgraph, timestamp :timestamp, t :t, :as database} :- DatabaseType t-val]
Returns: DatabaseType

Returns a database value for a provided t-value.
If t-val is the transaction number for an older database, then returns that database. Otherwise, will return this database
If t-val is a timestamp then returns the most recent database that was valid at that time.
raw docstring

create-databaseclj/s

(create-database name)

Inputs: [name :- s/Str] Returns: ConnectionType

This opens a connection to an existing database by the name of the location for resources. If the database does not exist then it is created.

Inputs: [name :- s/Str]
Returns: ConnectionType

This opens a connection to an existing database by the name of the location for resources.
If the database does not exist then it is created.
raw docstring

db*clj/s

(db* {:keys [name tx-manager grapha] :as connection})

Inputs: [{:keys [name tx-manager grapha], :as connection} :- ConnectionType] Returns: DatabaseType

Returns the most recent database value from the connection.

Inputs: [{:keys [name tx-manager grapha], :as connection} :- ConnectionType]
Returns: DatabaseType

Returns the most recent database value from the connection.
raw docstring

db-exists?clj/s

(db-exists? store-name)

Inputs: [store-name :- s/Str] Returns: s/Bool

Tests if this database exists by looking for the transaction file

Inputs: [store-name :- s/Str]
Returns: s/Bool

Tests if this database exists by looking for the transaction file
raw docstring

DBsBeforeAfterclj/s


delete-database*clj/s

(delete-database* {:keys [name grapha tx-manager] :as connection})

Inputs: [{:keys [name grapha tx-manager], :as connection} :- ConnectionType]

Delete the graph, which will recursively delete all resources

Inputs: [{:keys [name grapha tx-manager], :as connection} :- ConnectionType]

Delete the graph, which will recursively delete all resources
raw docstring

DurableConnectionclj/s


DurableDatabaseclj/s


entity*clj/s

(entity* {bgraph :bgraph :as database} id nested?)

Inputs: [{bgraph :bgraph, :as database} id nested? :- s/Bool] Returns: (s/maybe #:s{Keyword s/Any})

Inputs: [{bgraph :bgraph, :as database} id nested? :- s/Bool]
Returns: (s/maybe #:s{Keyword s/Any})
raw docstring

get-url*clj/s

(get-url* {:keys [name]})

Inputs: [{:keys [name]} :- ConnectionType] Returns: s/Str

Inputs: [{:keys [name]} :- ConnectionType]
Returns: s/Str
raw docstring

new-dbclj/s

(new-db)

Inputs: [] Returns: TxRecordPacked

Inputs: []
Returns: TxRecordPacked
raw docstring

pack-txclj/s

(pack-tx {:keys [r-spot r-post r-ospt r-pool nr-index-node nr-index-block
                 nr-pool-node nodes timestamp]})

Inputs: [{:keys [r-spot r-post r-ospt r-pool nr-index-node nr-index-block nr-pool-node nodes timestamp]} :- TxRecord] Returns: TxRecordPacked

Packs a transaction into a vector for serialization

Inputs: [{:keys [r-spot r-post r-ospt r-pool nr-index-node nr-index-block nr-pool-node nodes timestamp]} :- TxRecord]
Returns: TxRecordPacked

Packs a transaction into a vector for serialization
raw docstring

release*clj/s

(release* {:keys [name grapha tx-manager] :as connection})

Inputs: [{:keys [name grapha tx-manager], :as connection} :- ConnectionType]

Closes the transaction manager, and the graph, which will recursively close all resources

Inputs: [{:keys [name grapha tx-manager], :as connection} :- ConnectionType]

Closes the transaction manager, and the graph, which will recursively close all resources
raw docstring

since*clj/s

(since* {{tx-manager :tx-manager :as connection} :connection
         timestamp :timestamp
         bgraph :bgraph
         t :t
         :as database}
        t-val)

Inputs: [{{tx-manager :tx-manager, :as connection} :connection, timestamp :timestamp, bgraph :bgraph, t :t, :as database} :- DatabaseType t-val] Returns: (s/maybe DatabaseType)

Returns the next database value after the provided t-value. If t-val is a transaction number for an older databse, then it returns the next database. If it refers to the current database or later, then returns nil (even if more recent databases exist, since this database is stateless. If t-val is a timestamp, then it returns the next database after that time, unless the timestamp is at or after the timestamp on the current database.

Inputs: [{{tx-manager :tx-manager, :as connection} :connection, timestamp :timestamp, bgraph :bgraph, t :t, :as database} :- DatabaseType t-val]
Returns: (s/maybe DatabaseType)

Returns the next database value after the provided t-value.
If t-val is a transaction number for an older databse, then it returns the next database. If it refers to the current
database or later, then returns nil (even if more recent databases exist, since this database is stateless.
If t-val is a timestamp, then it returns the next database after that time, unless the timestamp is at or after
the timestamp on the current database.
raw docstring

transact-data*clj/s≠

clj
(transact-data* conn updates! generator-fn)
(transact-data* conn updates! asserts retracts)
cljs
(transact-data* G__20904 G__20905 G__20906)
(transact-data* G__20897 G__20898 G__20899 G__20900)

Inputs: ([conn :- ConnectionType updates! :- UpdateData asserts :- [Triple] retracts :- [Triple]] [conn :- ConnectionType updates! :- UpdateData generator-fn]) Returns: DBsBeforeAfter

Removes a series of tuples from the latest graph, and asserts new tuples into the graph. Updates the connection to the new graph.

Inputs: ([conn :- ConnectionType updates! :- UpdateData asserts :- [Triple] retracts :- [Triple]] [conn :- ConnectionType updates! :- UpdateData generator-fn])
Returns: DBsBeforeAfter

Removes a series of tuples from the latest graph, and asserts new tuples into the graph.
 Updates the connection to the new graph.
raw docstring

transact-update*clj/s

(transact-update* {:keys [tx-manager grapha nodea] :as connection} update-fn)

Inputs: [{:keys [tx-manager grapha nodea], :as connection} :- ConnectionType update-fn :- UpdateFunction] Returns: DBsBeforeAfter

Updates a graph according to a provided function. This will be done in a new, single transaction.

Inputs: [{:keys [tx-manager grapha nodea], :as connection} :- ConnectionType update-fn :- UpdateFunction]
Returns: DBsBeforeAfter

Updates a graph according to a provided function. This will be done in a new, single transaction.
raw docstring

tx-nameclj/s


tx-record-sizeclj/s


TxRecordclj/s


TxRecordPackedclj/s


unpack-txclj/s

(unpack-tx {[r-spot r-post r-ospt r-pool nr-index-node nr-index-block
             nr-pool-node nodes]
              :tx-data
            timestamp :timestamp})

Inputs: [{[r-spot r-post r-ospt r-pool nr-index-node nr-index-block nr-pool-node nodes] :tx-data, timestamp :timestamp} :- TxRecordPacked] Returns: TxRecord

Unpacks a transaction vector into a structure when deserializing

Inputs: [{[r-spot r-post r-ospt r-pool nr-index-node nr-index-block nr-pool-node nodes] :tx-data, timestamp :timestamp} :- TxRecordPacked]
Returns: TxRecord

Unpacks a transaction vector into a structure when deserializing
raw docstring

UpdateFunctionclj/s

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

× close