Skip to content

Commit 7912298

Browse files
authored
[8.19] Regenerate client (#8770)
1 parent ec2ddc3 commit 7912298

File tree

7 files changed

+40
-38
lines changed

7 files changed

+40
-38
lines changed

src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/PutDataLifecycleRequest.Converters.g.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ public override Elastic.Clients.Elasticsearch.IndexManagement.PutDataLifecycleRe
3333
{
3434
reader.ValidateToken(System.Text.Json.JsonTokenType.StartObject);
3535
LocalJsonValue<Elastic.Clients.Elasticsearch.Duration?> propDataRetention = default;
36-
LocalJsonValue<Elastic.Clients.Elasticsearch.IndexManagement.DataStreamLifecycleDownsampling?> propDownsampling = default;
36+
LocalJsonValue<System.Collections.Generic.ICollection<Elastic.Clients.Elasticsearch.IndexManagement.DownsamplingRound>?> propDownsampling = default;
3737
LocalJsonValue<bool?> propEnabled = default;
3838
while (reader.Read() && reader.TokenType is System.Text.Json.JsonTokenType.PropertyName)
3939
{
@@ -42,7 +42,7 @@ public override Elastic.Clients.Elasticsearch.IndexManagement.PutDataLifecycleRe
4242
continue;
4343
}
4444

45-
if (propDownsampling.TryReadProperty(ref reader, options, PropDownsampling, null))
45+
if (propDownsampling.TryReadProperty(ref reader, options, PropDownsampling, static System.Collections.Generic.ICollection<Elastic.Clients.Elasticsearch.IndexManagement.DownsamplingRound>? (ref System.Text.Json.Utf8JsonReader r, System.Text.Json.JsonSerializerOptions o) => r.ReadCollectionValue<Elastic.Clients.Elasticsearch.IndexManagement.DownsamplingRound>(o, null)))
4646
{
4747
continue;
4848
}
@@ -74,7 +74,7 @@ public override void Write(System.Text.Json.Utf8JsonWriter writer, Elastic.Clien
7474
{
7575
writer.WriteStartObject();
7676
writer.WriteProperty(options, PropDataRetention, value.DataRetention, null, null);
77-
writer.WriteProperty(options, PropDownsampling, value.Downsampling, null, null);
77+
writer.WriteProperty(options, PropDownsampling, value.Downsampling, null, static (System.Text.Json.Utf8JsonWriter w, System.Text.Json.JsonSerializerOptions o, System.Collections.Generic.ICollection<Elastic.Clients.Elasticsearch.IndexManagement.DownsamplingRound>? v) => w.WriteCollectionValue<Elastic.Clients.Elasticsearch.IndexManagement.DownsamplingRound>(o, v, null));
7878
writer.WriteProperty(options, PropEnabled, value.Enabled, null, static (System.Text.Json.Utf8JsonWriter w, System.Text.Json.JsonSerializerOptions o, bool? v) => w.WriteNullableValue<bool>(o, v));
7979
writer.WriteEndObject();
8080
}

src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/PutDataLifecycleRequest.g.cs

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ internal PutDataLifecycleRequest(Elastic.Clients.Elasticsearch.Serialization.Jso
135135
/// The downsampling configuration to execute for the managed backing index after rollover.
136136
/// </para>
137137
/// </summary>
138-
public Elastic.Clients.Elasticsearch.IndexManagement.DataStreamLifecycleDownsampling? Downsampling { get; set; }
138+
public System.Collections.Generic.ICollection<Elastic.Clients.Elasticsearch.IndexManagement.DownsamplingRound>? Downsampling { get; set; }
139139

140140
/// <summary>
141141
/// <para>
@@ -256,7 +256,7 @@ public Elastic.Clients.Elasticsearch.IndexManagement.PutDataLifecycleRequestDesc
256256
/// The downsampling configuration to execute for the managed backing index after rollover.
257257
/// </para>
258258
/// </summary>
259-
public Elastic.Clients.Elasticsearch.IndexManagement.PutDataLifecycleRequestDescriptor Downsampling(Elastic.Clients.Elasticsearch.IndexManagement.DataStreamLifecycleDownsampling? value)
259+
public Elastic.Clients.Elasticsearch.IndexManagement.PutDataLifecycleRequestDescriptor Downsampling(System.Collections.Generic.ICollection<Elastic.Clients.Elasticsearch.IndexManagement.DownsamplingRound>? value)
260260
{
261261
Instance.Downsampling = value;
262262
return this;
@@ -267,9 +267,26 @@ public Elastic.Clients.Elasticsearch.IndexManagement.PutDataLifecycleRequestDesc
267267
/// The downsampling configuration to execute for the managed backing index after rollover.
268268
/// </para>
269269
/// </summary>
270-
public Elastic.Clients.Elasticsearch.IndexManagement.PutDataLifecycleRequestDescriptor Downsampling(System.Action<Elastic.Clients.Elasticsearch.IndexManagement.DataStreamLifecycleDownsamplingDescriptor> action)
270+
public Elastic.Clients.Elasticsearch.IndexManagement.PutDataLifecycleRequestDescriptor Downsampling(params Elastic.Clients.Elasticsearch.IndexManagement.DownsamplingRound[] values)
271271
{
272-
Instance.Downsampling = Elastic.Clients.Elasticsearch.IndexManagement.DataStreamLifecycleDownsamplingDescriptor.Build(action);
272+
Instance.Downsampling = [.. values];
273+
return this;
274+
}
275+
276+
/// <summary>
277+
/// <para>
278+
/// The downsampling configuration to execute for the managed backing index after rollover.
279+
/// </para>
280+
/// </summary>
281+
public Elastic.Clients.Elasticsearch.IndexManagement.PutDataLifecycleRequestDescriptor Downsampling(params System.Action<Elastic.Clients.Elasticsearch.IndexManagement.DownsamplingRoundDescriptor>[] actions)
282+
{
283+
var items = new System.Collections.Generic.List<Elastic.Clients.Elasticsearch.IndexManagement.DownsamplingRound>();
284+
foreach (var action in actions)
285+
{
286+
items.Add(Elastic.Clients.Elasticsearch.IndexManagement.DownsamplingRoundDescriptor.Build(action));
287+
}
288+
289+
Instance.Downsampling = items;
273290
return this;
274291
}
275292

src/Elastic.Clients.Elasticsearch/_Generated/Types/Aggregations/GeoLineAggregation.Converters.g.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public override Elastic.Clients.Elasticsearch.Aggregations.GeoLineAggregation Re
3737
LocalJsonValue<bool?> propIncludeSort = default;
3838
LocalJsonValue<Elastic.Clients.Elasticsearch.Aggregations.GeoLinePoint> propPoint = default;
3939
LocalJsonValue<int?> propSize = default;
40-
LocalJsonValue<Elastic.Clients.Elasticsearch.Aggregations.GeoLineSort> propSort = default;
40+
LocalJsonValue<Elastic.Clients.Elasticsearch.Aggregations.GeoLineSort?> propSort = default;
4141
LocalJsonValue<Elastic.Clients.Elasticsearch.SortOrder?> propSortOrder = default;
4242
while (reader.Read() && reader.TokenType is System.Text.Json.JsonTokenType.PropertyName)
4343
{

src/Elastic.Clients.Elasticsearch/_Generated/Types/Aggregations/GeoLineAggregation.g.cs

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,9 @@ namespace Elastic.Clients.Elasticsearch.Aggregations;
2727
public sealed partial class GeoLineAggregation
2828
{
2929
[System.Diagnostics.CodeAnalysis.SetsRequiredMembers]
30-
public GeoLineAggregation(Elastic.Clients.Elasticsearch.Aggregations.GeoLinePoint point, Elastic.Clients.Elasticsearch.Aggregations.GeoLineSort sort)
30+
public GeoLineAggregation(Elastic.Clients.Elasticsearch.Aggregations.GeoLinePoint point)
3131
{
3232
Point = point;
33-
Sort = sort;
3433
}
3534
#if NET7_0_OR_GREATER
3635
public GeoLineAggregation()
@@ -81,11 +80,7 @@ internal GeoLineAggregation(Elastic.Clients.Elasticsearch.Serialization.JsonCons
8180
/// When the <c>geo_line</c> aggregation is nested inside a <c>time_series</c> aggregation, this field defaults to <c>@timestamp</c>, and any other value will result in error.
8281
/// </para>
8382
/// </summary>
84-
public
85-
#if NET7_0_OR_GREATER
86-
required
87-
#endif
88-
Elastic.Clients.Elasticsearch.Aggregations.GeoLineSort Sort { get; set; }
83+
public Elastic.Clients.Elasticsearch.Aggregations.GeoLineSort? Sort { get; set; }
8984

9085
/// <summary>
9186
/// <para>
@@ -165,7 +160,7 @@ public Elastic.Clients.Elasticsearch.Aggregations.GeoLineAggregationDescriptor<T
165160
/// When the <c>geo_line</c> aggregation is nested inside a <c>time_series</c> aggregation, this field defaults to <c>@timestamp</c>, and any other value will result in error.
166161
/// </para>
167162
/// </summary>
168-
public Elastic.Clients.Elasticsearch.Aggregations.GeoLineAggregationDescriptor<TDocument> Sort(Elastic.Clients.Elasticsearch.Aggregations.GeoLineSort value)
163+
public Elastic.Clients.Elasticsearch.Aggregations.GeoLineAggregationDescriptor<TDocument> Sort(Elastic.Clients.Elasticsearch.Aggregations.GeoLineSort? value)
169164
{
170165
Instance.Sort = value;
171166
return this;
@@ -284,7 +279,7 @@ public Elastic.Clients.Elasticsearch.Aggregations.GeoLineAggregationDescriptor S
284279
/// When the <c>geo_line</c> aggregation is nested inside a <c>time_series</c> aggregation, this field defaults to <c>@timestamp</c>, and any other value will result in error.
285280
/// </para>
286281
/// </summary>
287-
public Elastic.Clients.Elasticsearch.Aggregations.GeoLineAggregationDescriptor Sort(Elastic.Clients.Elasticsearch.Aggregations.GeoLineSort value)
282+
public Elastic.Clients.Elasticsearch.Aggregations.GeoLineAggregationDescriptor Sort(Elastic.Clients.Elasticsearch.Aggregations.GeoLineSort? value)
288283
{
289284
Instance.Sort = value;
290285
return this;

src/Elastic.Clients.Elasticsearch/_Generated/Types/Aggregations/PercentilesAggregation.Converters.g.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ public override Elastic.Clients.Elasticsearch.Aggregations.PercentilesAggregatio
7272
continue;
7373
}
7474

75-
if (propPercents.TryReadProperty(ref reader, options, PropPercents, static System.Collections.Generic.ICollection<double>? (ref System.Text.Json.Utf8JsonReader r, System.Text.Json.JsonSerializerOptions o) => r.ReadCollectionValue<double>(o, null)))
75+
if (propPercents.TryReadProperty(ref reader, options, PropPercents, static System.Collections.Generic.ICollection<double>? (ref System.Text.Json.Utf8JsonReader r, System.Text.Json.JsonSerializerOptions o) => r.ReadSingleOrManyCollectionValue<double>(o, null)))
7676
{
7777
continue;
7878
}
@@ -117,7 +117,7 @@ public override void Write(System.Text.Json.Utf8JsonWriter writer, Elastic.Clien
117117
writer.WriteProperty(options, PropHdr, value.Hdr, null, null);
118118
writer.WriteProperty(options, PropKeyed, value.Keyed, null, static (System.Text.Json.Utf8JsonWriter w, System.Text.Json.JsonSerializerOptions o, bool? v) => w.WriteNullableValue<bool>(o, v));
119119
writer.WriteProperty(options, PropMissing, value.Missing, null, null);
120-
writer.WriteProperty(options, PropPercents, value.Percents, null, static (System.Text.Json.Utf8JsonWriter w, System.Text.Json.JsonSerializerOptions o, System.Collections.Generic.ICollection<double>? v) => w.WriteCollectionValue<double>(o, v, null));
120+
writer.WriteProperty(options, PropPercents, value.Percents, null, static (System.Text.Json.Utf8JsonWriter w, System.Text.Json.JsonSerializerOptions o, System.Collections.Generic.ICollection<double>? v) => w.WriteSingleOrManyCollectionValue<double>(o, v, null));
121121
writer.WriteProperty(options, PropScript, value.Script, null, null);
122122
writer.WriteProperty(options, PropTDigest, value.TDigest, null, null);
123123
writer.WriteEndObject();

src/Elastic.Clients.Elasticsearch/_Generated/Types/Cluster/NodeAllocationExplanation.Converters.g.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,18 +38,18 @@ public sealed partial class NodeAllocationExplanationConverter : System.Text.Jso
3838
public override Elastic.Clients.Elasticsearch.Cluster.NodeAllocationExplanation Read(ref System.Text.Json.Utf8JsonReader reader, System.Type typeToConvert, System.Text.Json.JsonSerializerOptions options)
3939
{
4040
reader.ValidateToken(System.Text.Json.JsonTokenType.StartObject);
41-
LocalJsonValue<System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision>> propDeciders = default;
41+
LocalJsonValue<System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision>?> propDeciders = default;
4242
LocalJsonValue<System.Collections.Generic.IReadOnlyDictionary<string, string>> propNodeAttributes = default;
4343
LocalJsonValue<Elastic.Clients.Elasticsearch.Cluster.Decision> propNodeDecision = default;
4444
LocalJsonValue<string> propNodeId = default;
4545
LocalJsonValue<string> propNodeName = default;
4646
LocalJsonValue<System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.NodeRole>> propRoles = default;
4747
LocalJsonValue<Elastic.Clients.Elasticsearch.Cluster.AllocationStore?> propStore = default;
4848
LocalJsonValue<string> propTransportAddress = default;
49-
LocalJsonValue<int> propWeightRanking = default;
49+
LocalJsonValue<int?> propWeightRanking = default;
5050
while (reader.Read() && reader.TokenType is System.Text.Json.JsonTokenType.PropertyName)
5151
{
52-
if (propDeciders.TryReadProperty(ref reader, options, PropDeciders, static System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision> (ref System.Text.Json.Utf8JsonReader r, System.Text.Json.JsonSerializerOptions o) => r.ReadCollectionValue<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision>(o, null)!))
52+
if (propDeciders.TryReadProperty(ref reader, options, PropDeciders, static System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision>? (ref System.Text.Json.Utf8JsonReader r, System.Text.Json.JsonSerializerOptions o) => r.ReadCollectionValue<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision>(o, null)))
5353
{
5454
continue;
5555
}
@@ -89,7 +89,7 @@ public override Elastic.Clients.Elasticsearch.Cluster.NodeAllocationExplanation
8989
continue;
9090
}
9191

92-
if (propWeightRanking.TryReadProperty(ref reader, options, PropWeightRanking, null))
92+
if (propWeightRanking.TryReadProperty(ref reader, options, PropWeightRanking, static int? (ref System.Text.Json.Utf8JsonReader r, System.Text.Json.JsonSerializerOptions o) => r.ReadNullableValue<int>(o)))
9393
{
9494
continue;
9595
}
@@ -121,15 +121,15 @@ public override Elastic.Clients.Elasticsearch.Cluster.NodeAllocationExplanation
121121
public override void Write(System.Text.Json.Utf8JsonWriter writer, Elastic.Clients.Elasticsearch.Cluster.NodeAllocationExplanation value, System.Text.Json.JsonSerializerOptions options)
122122
{
123123
writer.WriteStartObject();
124-
writer.WriteProperty(options, PropDeciders, value.Deciders, null, static (System.Text.Json.Utf8JsonWriter w, System.Text.Json.JsonSerializerOptions o, System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision> v) => w.WriteCollectionValue<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision>(o, v, null));
124+
writer.WriteProperty(options, PropDeciders, value.Deciders, null, static (System.Text.Json.Utf8JsonWriter w, System.Text.Json.JsonSerializerOptions o, System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision>? v) => w.WriteCollectionValue<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision>(o, v, null));
125125
writer.WriteProperty(options, PropNodeAttributes, value.NodeAttributes, null, static (System.Text.Json.Utf8JsonWriter w, System.Text.Json.JsonSerializerOptions o, System.Collections.Generic.IReadOnlyDictionary<string, string> v) => w.WriteDictionaryValue<string, string>(o, v, null, null));
126126
writer.WriteProperty(options, PropNodeDecision, value.NodeDecision, null, null);
127127
writer.WriteProperty(options, PropNodeId, value.NodeId, null, null);
128128
writer.WriteProperty(options, PropNodeName, value.NodeName, null, null);
129129
writer.WriteProperty(options, PropRoles, value.Roles, null, static (System.Text.Json.Utf8JsonWriter w, System.Text.Json.JsonSerializerOptions o, System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.NodeRole> v) => w.WriteCollectionValue<Elastic.Clients.Elasticsearch.NodeRole>(o, v, null));
130130
writer.WriteProperty(options, PropStore, value.Store, null, null);
131131
writer.WriteProperty(options, PropTransportAddress, value.TransportAddress, null, null);
132-
writer.WriteProperty(options, PropWeightRanking, value.WeightRanking, null, null);
132+
writer.WriteProperty(options, PropWeightRanking, value.WeightRanking, null, static (System.Text.Json.Utf8JsonWriter w, System.Text.Json.JsonSerializerOptions o, int? v) => w.WriteNullableValue<int>(o, v));
133133
writer.WriteEndObject();
134134
}
135135
}

src/Elastic.Clients.Elasticsearch/_Generated/Types/Cluster/NodeAllocationExplanation.g.cs

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -27,16 +27,14 @@ namespace Elastic.Clients.Elasticsearch.Cluster;
2727
public sealed partial class NodeAllocationExplanation
2828
{
2929
[System.Diagnostics.CodeAnalysis.SetsRequiredMembers]
30-
public NodeAllocationExplanation(System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision> deciders, System.Collections.Generic.IReadOnlyDictionary<string, string> nodeAttributes, Elastic.Clients.Elasticsearch.Cluster.Decision nodeDecision, string nodeId, string nodeName, System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.NodeRole> roles, string transportAddress, int weightRanking)
30+
public NodeAllocationExplanation(System.Collections.Generic.IReadOnlyDictionary<string, string> nodeAttributes, Elastic.Clients.Elasticsearch.Cluster.Decision nodeDecision, string nodeId, string nodeName, System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.NodeRole> roles, string transportAddress)
3131
{
32-
Deciders = deciders;
3332
NodeAttributes = nodeAttributes;
3433
NodeDecision = nodeDecision;
3534
NodeId = nodeId;
3635
NodeName = nodeName;
3736
Roles = roles;
3837
TransportAddress = transportAddress;
39-
WeightRanking = weightRanking;
4038
}
4139
#if NET7_0_OR_GREATER
4240
public NodeAllocationExplanation()
@@ -55,11 +53,7 @@ internal NodeAllocationExplanation(Elastic.Clients.Elasticsearch.Serialization.J
5553
_ = sentinel;
5654
}
5755

58-
public
59-
#if NET7_0_OR_GREATER
60-
required
61-
#endif
62-
System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision> Deciders { get; set; }
56+
public System.Collections.Generic.IReadOnlyCollection<Elastic.Clients.Elasticsearch.Cluster.AllocationDecision>? Deciders { get; set; }
6357
public
6458
#if NET7_0_OR_GREATER
6559
required
@@ -91,9 +85,5 @@ internal NodeAllocationExplanation(Elastic.Clients.Elasticsearch.Serialization.J
9185
required
9286
#endif
9387
string TransportAddress { get; set; }
94-
public
95-
#if NET7_0_OR_GREATER
96-
required
97-
#endif
98-
int WeightRanking { get; set; }
88+
public int? WeightRanking { get; set; }
9989
}

0 commit comments

Comments
 (0)