resolve-storage-base
v0.23.2
Published
A base for reSolve storage adapters
Downloads
176
Readme
resolve-storage-base
This base package is a resolve-es
adapter for storing events.
Usage
import createAdapter from 'resolve-storage-xxx';
const adapter = createAdapter({/* options */});
await adapter.init()
await loadEvents({
eventTypes: ['TYPE_1', 'TYPE_2'],
aggregateIds: ['aggregate_1', 'aggregate_2'],
startTime: 0,
finishTime: Date.now()
}, callback)
await saveEvent(event)
await dispose({ dropEvents: false })