Append several records under a single commit. The batch is atomic: a tear anywhere inside it discards the whole block.
Append a group preamble (GS + name) as a committed block.
Optionalheaders: string[] | nullAppend an SOH header as a committed block.
Append one record as a committed block.
Append one record from an array of fields.
Appends ETB-committed blocks to an append-only log.
const log = new StreamWriter(sink) log.record('create', nonce, ts) log.batch(b => { // atomic multi-record commit b.record('name', label, ts) b.record('tag', tag, ts) })
Each block and its ETB are issued as a single write. When appending to an existing log, repair the tail first (see
openLog) — blind appends after a torn tail are unsafe (a tail ending in a bare DLE would escape the next append's RS and fuse two records).