![]() |
CQRS.NET
2.2
A lightweight enterprise framework to write CQRS, event-sourced and micro-service applications in hybrid multi-datacentre, on-premise and Azure environments.
|
Stores the most recent snapshots for replay and IAggregateRoot<TAuthenticationToken> rehydration on a SnapshotAggregateRoot<TAuthenticationToken,TSnapshot> in SqlServer that uses LinqToSql and follows a rigid schema. More...
Public Member Functions | |
SqlSnapshotStore (IConfigurationManager configurationManager, ISnapshotDeserialiser eventDeserialiser, ILogger logger, ICorrelationIdHelper correlationIdHelper, ISnapshotBuilder snapshotBuilder) | |
Instantiate a new instance of the SqlSnapshotStore class. More... | |
override void | Save (Snapshot snapshot) |
Saves the provided snapshot into storage. More... | |
![]() | |
virtual Snapshot | Get< TAggregateRoot > (Guid id) |
Get the latest Snapshot from storage. More... | |
Protected Member Functions | |
override Snapshot | Get (Type aggregateRootType, string streamName) |
Get the latest Snapshot from storage. More... | |
virtual DataContext | CreateDbDataContext (string aggregateRootTypeName=null) |
Creates a new DataContext using connection string settings from ConfigurationManager. More... | |
virtual Table< EventData > | GetEventStoreSnapshotTable (DataContext dbDataContext) |
Gets the Table<TEntity> of Snapshot. More... | |
virtual void | Add (DataContext dbDataContext, Snapshot snapshot) |
Persist the provided snapshot into SQL Server using the provided dbDataContext . More... | |
![]() | |
SnapshotStore (IConfigurationManager configurationManager, ISnapshotDeserialiser eventDeserialiser, ISnapshotBuilder snapshotBuilder, ILogger logger, ICorrelationIdHelper correlationIdHelper) | |
Instantiate a new instance of the SnapshotStore class. More... | |
virtual string | GenerateStreamName (Type aggregateRootType, Guid aggregateId) |
Generate a unique stream name based on the provided aggregateRootType and the aggregateId . More... | |
virtual EventData | BuildEventData (Snapshot snapshot) |
Builds the EventData from the snapshot . More... | |
Additional Inherited Members | |
![]() | |
const string | CqrsSnapshotStoreStreamNamePattern = "{0}/{1}" |
The pattern used to generate the stream name. More... | |
![]() | |
IConfigurationManager | ConfigurationManager [get] |
Gets or sets the IConfigurationManager More... | |
ISnapshotDeserialiser | EventDeserialiser [get] |
The ISnapshotDeserialiser used to deserialise snapshots. More... | |
ISnapshotBuilder | SnapshotBuilder [get] |
The ISnapshotBuilder used to build snapshots. More... | |
ILogger | Logger [get] |
The ILogger to use. More... | |
ICorrelationIdHelper | CorrelationIdHelper [get] |
The ICorrelationIdHelper to use. More... | |
Stores the most recent snapshots for replay and IAggregateRoot<TAuthenticationToken> rehydration on a SnapshotAggregateRoot<TAuthenticationToken,TSnapshot> in SqlServer that uses LinqToSql and follows a rigid schema.