Fauna .NET Driver 0.1.0-beta
 
Loading...
Searching...
No Matches
Configuration.cs
Go to the documentation of this file.
1namespace Fauna;
2
7public record Configuration
8{
12 public bool DisposeHttpClient { get; }
13
17 public HttpClient HttpClient { get; }
18
22 public string Secret { get; init; }
23
27 public Uri Endpoint { get; init; } = Constants.Endpoints.Default;
28
32 public QueryOptions? DefaultQueryOptions { get; init; } = null;
33
37 public RetryConfiguration RetryConfiguration { get; init; } = new(3, TimeSpan.FromSeconds(20));
38
44 public Configuration(string secret, HttpClient? httpClient = null)
45 {
46 if (httpClient is null)
47 {
48 HttpClient = new HttpClient
49 {
50 Timeout = TimeSpan.FromSeconds(5)
51 };
52 DisposeHttpClient = true;
53 }
54 else
55 {
56 HttpClient = httpClient;
57 }
58
59 Secret = secret;
60 }
61}
Represents the options for customizing Fauna queries.
Definition Client.cs:9
record Configuration
Configuration is a class used to configure a Fauna client. It encapsulates various settings such as t...