In Equinox V4, stores now accept/provide events in two primary formats (previously everything was byte[]):
ReadOnlyMemory<byte>: Replaces byte[] as the default event body type, in order to facilitate pooling etc (EventStoreDB uses it directly, Equinox.DynamoStore maps internally to what the AWS SDK demands at present (MemoryStream))
JsonElement: Equinox.CosmosStore now natively uses System.Text.Json so event bodies can be emitted cleanly and directly using that format
The key change is that SystemTextJson now has two static type roots;
CodecJsonElement, which is for use with Equinox.CosmosStore V4 and later
Codec (which previously produced a JsonElement codec) that needed to be adapted for use with Equinox.CosmosStore is now equivalent in signature to Newtonsoft.Codec, and works directly with all other stores
In Equinox V4, stores now accept/provide events in two primary formats (previously everything was
byte[]
):ReadOnlyMemory<byte>
: Replacesbyte[]
as the default event body type, in order to facilitate pooling etc (EventStoreDB uses it directly, Equinox.DynamoStore maps internally to what the AWS SDK demands at present (MemoryStream
))JsonElement
:Equinox.CosmosStore
now natively usesSystem.Text.Json
so event bodies can be emitted cleanly and directly using that formatThe key change is that
SystemTextJson
now has twostatic type
roots;CodecJsonElement
, which is for use withEquinox.CosmosStore
V4 and laterCodec
(which previously produced aJsonElement
codec) that needed to be adapted for use withEquinox.CosmosStore
is now equivalent in signature toNewtonsoft.Codec
, and works directly with all other stores