Skip to content

Commit

Permalink
Add missing changes from a0678c379b18afb04df8145fbba465b86fe308d9
Browse files Browse the repository at this point in the history
  • Loading branch information
RussKie committed Jun 13, 2023
1 parent c7908d7 commit b60486e
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -82,12 +82,24 @@ public class DatabaseOptions
/// Gets or sets json serializer options.
/// </summary>
/// <remarks>
/// This will be used only if <see cref="OverrideSerialization"/> is enabled.
/// Default is the default <see cref="JsonSerializerOptions" />.
/// Those options will be used by compatible APIs to serialize input before sending to server and deserialize output.
/// This includes sent/received documents.
/// </remarks>
public JsonSerializerOptions JsonSerializerOptions { get; set; } = new();

/// <summary>
/// Gets or sets a value indicating whether serialization overridden.
/// </summary>
/// <remarks>
/// Default is <see langword="true"/>.
/// When enabled, System.Text.Json based serialization will be configured with
/// settings defined in <see cref="JsonSerializerOptions"/>.
/// </remarks>
[Experimental("New feature.")]
public bool OverrideSerialization { get; set; } = true;

/// <summary>
/// Gets or sets a list of preferred regions used for SDK to define failover order for global database.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ public void TestDefaults()

Assert.Equal(string.Empty, config.DatabaseName);
Throughput.Unlimited.Should().Be(config.Throughput);
Assert.True(config.OverrideSerialization);
}

[Fact]
Expand Down

0 comments on commit b60486e

Please sign in to comment.