Closed winter3angle closed 1 year ago
I added a configurator that you can call and change serializer:
BinaryConverterConfigurator.SetSerializer(JsonSerializer.Create(new JsonSerializerSettings
{
Converters = new List<JsonConverter>(new[] { new StringEnumConverter() }),
NullValueHandling = NullValueHandling.Ignore,
ContractResolver = new DefaultContractResolver
{
NamingStrategy = new SnakeCaseNamingStrategy()
}
}));
BinaryConverter's serializer options are statically initialized and it may not be desired in some cases. For example, MultiStore will throw if data to be cached is some sort of recursive structure. Configurable serializer would allow to workaround such corner cases.