Skip to content

nooschain v0.1.0


nooschain / chain/smt-state-store / createPersistentSmtStateStore

Function: createPersistentSmtStateStore()

createPersistentSmtStateStore(database, options?): Promise<SmtStateStore>

Defined in: chain/smt-state-store.ts:511

Creates the persistent SMT store used by normal block execution. Buffered writes keep large blocks faster while preserving transaction-level rollback because flush happens inside the caller's DB transaction.

Parameters

database

ChainDatabase

options?

blockHeight?

string | number | bigint

bufferedWrites?

boolean

engineVersion?

"iden3-v1" | "nervos-smt-v2"

maxCacheEntries?

number

onCacheLimitExceeded?

(details) => void

treeId?

string

useContinuousSidecar?

boolean

Returns

Promise<SmtStateStore>

Audience-first NOOSChain documentation.