22 public TimeSpan
QueryTimeout {
get;
set; } = TimeSpan.FromSeconds(5);
28 public Dictionary<string, string>?
QueryTags {
get;
set; } =
null;
43 if (overrides ==
null)
48 var finalQueryOptions =
new QueryOptions()
57 var properties = typeof(QueryOptions).GetProperties();
59 foreach (var prop
in properties)
66 var propertyOverride = prop.GetValue(overrides);
68 if (propertyOverride !=
null)
70 prop.SetValue(finalQueryOptions, propertyOverride);
76 if (finalQueryOptions.QueryTags ==
null)
78 finalQueryOptions.QueryTags = overrides.
QueryTags;
84 if (finalQueryOptions.QueryTags.ContainsKey(kv.Key))
86 finalQueryOptions.QueryTags[kv.Key] = kv.Value;
90 finalQueryOptions.QueryTags.Add(kv.Key, kv.Value);
96 return finalQueryOptions;