diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/AsyncSearch/SubmitAsyncSearchRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/AsyncSearch/SubmitAsyncSearchRequest.g.cs
index adcf4a7a557..a9b2ed28aae 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/AsyncSearch/SubmitAsyncSearchRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/AsyncSearch/SubmitAsyncSearchRequest.g.cs
@@ -958,7 +958,7 @@ public SubmitAsyncSearchRequestDescriptor(Elastic.Clients.Elasticsearch.Serverle
{
}
- public SubmitAsyncSearchRequestDescriptor() : this(typeof(TDocument))
+ public SubmitAsyncSearchRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/Cluster/HealthRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/Cluster/HealthRequest.g.cs
index 32eed5a76b0..9d9bd0502bb 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/Cluster/HealthRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/Cluster/HealthRequest.g.cs
@@ -186,7 +186,7 @@ public HealthRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indices?
{
}
- public HealthRequestDescriptor() : this(typeof(TDocument))
+ public HealthRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/CountRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/CountRequest.g.cs
index 926ac7b7da8..d6fc6a99e76 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/CountRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/CountRequest.g.cs
@@ -225,7 +225,7 @@ public CountRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indices?
{
}
- public CountRequestDescriptor() : this(typeof(TDocument))
+ public CountRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/FieldCapsRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/FieldCapsRequest.g.cs
index 673e8b9ce8b..3e095a8a945 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/FieldCapsRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/FieldCapsRequest.g.cs
@@ -161,7 +161,7 @@ public FieldCapsRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indic
{
}
- public FieldCapsRequestDescriptor() : this(typeof(TDocument))
+ public FieldCapsRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ClearCacheRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ClearCacheRequest.g.cs
index 075aaecb5d5..b4bbee1e867 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ClearCacheRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ClearCacheRequest.g.cs
@@ -142,7 +142,7 @@ public ClearCacheRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indi
{
}
- public ClearCacheRequestDescriptor() : this(typeof(TDocument))
+ public ClearCacheRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ExistsAliasRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ExistsAliasRequest.g.cs
index ba204309856..180db2d707b 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ExistsAliasRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ExistsAliasRequest.g.cs
@@ -109,7 +109,7 @@ public ExistsAliasRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Ind
{
}
- public ExistsAliasRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Names name) : this(typeof(TDocument), name)
+ public ExistsAliasRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Names name) : base(r => r.Required("name", name))
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/FlushRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/FlushRequest.g.cs
index 7375b7b5004..fd5bad0326b 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/FlushRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/FlushRequest.g.cs
@@ -120,7 +120,7 @@ public FlushRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indices?
{
}
- public FlushRequestDescriptor() : this(typeof(TDocument))
+ public FlushRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ForcemergeRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ForcemergeRequest.g.cs
index c50e5dcf251..8a03b2d3300 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ForcemergeRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ForcemergeRequest.g.cs
@@ -142,7 +142,7 @@ public ForcemergeRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indi
{
}
- public ForcemergeRequestDescriptor() : this(typeof(TDocument))
+ public ForcemergeRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetAliasRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetAliasRequest.g.cs
index f64d879c8c1..8dcc0896981 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetAliasRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetAliasRequest.g.cs
@@ -117,10 +117,6 @@ public GetAliasRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indice
{
}
- public GetAliasRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Names? name) : this(typeof(TDocument), name)
- {
- }
-
public GetAliasRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetIndicesSettingsRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetIndicesSettingsRequest.g.cs
index f4cde5cbf1d..3bcda543735 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetIndicesSettingsRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetIndicesSettingsRequest.g.cs
@@ -150,10 +150,6 @@ public GetIndicesSettingsRequestDescriptor(Elastic.Clients.Elasticsearch.Serverl
{
}
- public GetIndicesSettingsRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Names? name) : this(typeof(TDocument), name)
- {
- }
-
public GetIndicesSettingsRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetMappingRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetMappingRequest.g.cs
index b935e8891ac..5d2e51857e4 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetMappingRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/GetMappingRequest.g.cs
@@ -120,7 +120,7 @@ public GetMappingRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indi
{
}
- public GetMappingRequestDescriptor() : this(typeof(TDocument))
+ public GetMappingRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/IndicesStatsRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/IndicesStatsRequest.g.cs
index a43c2b1141a..1f5b8b33c89 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/IndicesStatsRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/IndicesStatsRequest.g.cs
@@ -172,10 +172,6 @@ public IndicesStatsRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.In
{
}
- public IndicesStatsRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Metrics? metric) : this(typeof(TDocument), metric)
- {
- }
-
public IndicesStatsRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/RecoveryRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/RecoveryRequest.g.cs
index 5861fd5b365..cb122588f09 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/RecoveryRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/RecoveryRequest.g.cs
@@ -87,7 +87,7 @@ public RecoveryRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indice
{
}
- public RecoveryRequestDescriptor() : this(typeof(TDocument))
+ public RecoveryRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/RefreshRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/RefreshRequest.g.cs
index 382010296ec..cc7834ac5a2 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/RefreshRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/RefreshRequest.g.cs
@@ -98,7 +98,7 @@ public RefreshRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indices
{
}
- public RefreshRequestDescriptor() : this(typeof(TDocument))
+ public RefreshRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/SegmentsRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/SegmentsRequest.g.cs
index dc97126de2c..08d029c66c8 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/SegmentsRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/SegmentsRequest.g.cs
@@ -109,7 +109,7 @@ public SegmentsRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indice
{
}
- public SegmentsRequestDescriptor() : this(typeof(TDocument))
+ public SegmentsRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ValidateQueryRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ValidateQueryRequest.g.cs
index c6a6895d0db..4fe608ca493 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ValidateQueryRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/IndexManagement/ValidateQueryRequest.g.cs
@@ -203,7 +203,7 @@ public ValidateQueryRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.I
{
}
- public ValidateQueryRequestDescriptor() : this(typeof(TDocument))
+ public ValidateQueryRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/MultiSearchRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/MultiSearchRequest.g.cs
index b065574411f..429eeb794e0 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/MultiSearchRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/MultiSearchRequest.g.cs
@@ -214,7 +214,7 @@ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClien
///
/// Allows to execute several search operations in one request.
///
-public sealed partial class MultiSearchRequestDescriptor : RequestDescriptor, MultiSearchRequestParameters>
+public sealed partial class MultiSearchRequestDescriptor : RequestDescriptor, MultiSearchRequestParameters>, IStreamSerializable
{
internal MultiSearchRequestDescriptor(Action> configure) => configure.Invoke(this);
@@ -222,7 +222,7 @@ public MultiSearchRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Ind
{
}
- public MultiSearchRequestDescriptor() : this(typeof(TDocument))
+ public MultiSearchRequestDescriptor()
{
}
@@ -259,6 +259,28 @@ protected override void Serialize(Utf8JsonWriter writer, JsonSerializerOptions o
List _items = new();
+ void IStreamSerializable.Serialize(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ serializable.Serialize(stream, settings, formatting);
+ }
+ }
+
+ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ await serializable.SerializeAsync(stream, settings, formatting).ConfigureAwait(false);
+ }
+ }
+
public MultiSearchRequestDescriptor AddSearches(Elastic.Clients.Elasticsearch.Serverless.Core.MSearch.SearchRequestItem searches)
{
_items.Add(searches);
@@ -269,7 +291,7 @@ public MultiSearchRequestDescriptor AddSearches(Elastic.Clients.Elast
///
/// Allows to execute several search operations in one request.
///
-public sealed partial class MultiSearchRequestDescriptor : RequestDescriptor
+public sealed partial class MultiSearchRequestDescriptor : RequestDescriptor, IStreamSerializable
{
internal MultiSearchRequestDescriptor(Action configure) => configure.Invoke(this);
@@ -314,6 +336,28 @@ protected override void Serialize(Utf8JsonWriter writer, JsonSerializerOptions o
List _items = new();
+ void IStreamSerializable.Serialize(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ serializable.Serialize(stream, settings, formatting);
+ }
+ }
+
+ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ await serializable.SerializeAsync(stream, settings, formatting).ConfigureAwait(false);
+ }
+ }
+
public MultiSearchRequestDescriptor AddSearches(Elastic.Clients.Elasticsearch.Serverless.Core.MSearch.SearchRequestItem searches)
{
_items.Add(searches);
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/MultiSearchTemplateRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/MultiSearchTemplateRequest.g.cs
index 004948d20aa..58e4cea5a43 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/MultiSearchTemplateRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/MultiSearchTemplateRequest.g.cs
@@ -137,7 +137,7 @@ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClien
///
/// Runs multiple templated searches with a single request.
///
-public sealed partial class MultiSearchTemplateRequestDescriptor : RequestDescriptor, MultiSearchTemplateRequestParameters>
+public sealed partial class MultiSearchTemplateRequestDescriptor : RequestDescriptor, MultiSearchTemplateRequestParameters>, IStreamSerializable
{
internal MultiSearchTemplateRequestDescriptor(Action> configure) => configure.Invoke(this);
@@ -145,7 +145,7 @@ public MultiSearchTemplateRequestDescriptor(Elastic.Clients.Elasticsearch.Server
{
}
- public MultiSearchTemplateRequestDescriptor() : this(typeof(TDocument))
+ public MultiSearchTemplateRequestDescriptor()
{
}
@@ -175,6 +175,28 @@ protected override void Serialize(Utf8JsonWriter writer, JsonSerializerOptions o
List _items = new();
+ void IStreamSerializable.Serialize(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ serializable.Serialize(stream, settings, formatting);
+ }
+ }
+
+ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ await serializable.SerializeAsync(stream, settings, formatting).ConfigureAwait(false);
+ }
+ }
+
public MultiSearchTemplateRequestDescriptor AddSearchTemplates(Elastic.Clients.Elasticsearch.Serverless.Core.MSearchTemplate.SearchTemplateRequestItem searchTemplates)
{
_items.Add(searchTemplates);
@@ -185,7 +207,7 @@ public MultiSearchTemplateRequestDescriptor AddSearchTemplates(Elasti
///
/// Runs multiple templated searches with a single request.
///
-public sealed partial class MultiSearchTemplateRequestDescriptor : RequestDescriptor
+public sealed partial class MultiSearchTemplateRequestDescriptor : RequestDescriptor, IStreamSerializable
{
internal MultiSearchTemplateRequestDescriptor(Action configure) => configure.Invoke(this);
@@ -223,6 +245,28 @@ protected override void Serialize(Utf8JsonWriter writer, JsonSerializerOptions o
List _items = new();
+ void IStreamSerializable.Serialize(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ serializable.Serialize(stream, settings, formatting);
+ }
+ }
+
+ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ await serializable.SerializeAsync(stream, settings, formatting).ConfigureAwait(false);
+ }
+ }
+
public MultiSearchTemplateRequestDescriptor AddSearchTemplates(Elastic.Clients.Elasticsearch.Serverless.Core.MSearchTemplate.SearchTemplateRequestItem searchTemplates)
{
_items.Add(searchTemplates);
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/RankEvalRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/RankEvalRequest.g.cs
index c70a657e66c..ee1f94c4a7a 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/RankEvalRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/RankEvalRequest.g.cs
@@ -121,7 +121,7 @@ public RankEvalRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indice
{
}
- public RankEvalRequestDescriptor() : this(typeof(TDocument))
+ public RankEvalRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/SearchRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/SearchRequest.g.cs
index f3bfdc322c8..c21b70a97ed 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/SearchRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/SearchRequest.g.cs
@@ -1007,7 +1007,7 @@ public SearchRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.Indices?
{
}
- public SearchRequestDescriptor() : this(typeof(TDocument))
+ public SearchRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/SearchTemplateRequest.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/SearchTemplateRequest.g.cs
index 79f0bcfb3f1..e8ea4bcab4e 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/SearchTemplateRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Api/SearchTemplateRequest.g.cs
@@ -216,7 +216,7 @@ public SearchTemplateRequestDescriptor(Elastic.Clients.Elasticsearch.Serverless.
{
}
- public SearchTemplateRequestDescriptor() : this(typeof(TDocument))
+ public SearchTemplateRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Client/ElasticsearchClient.Indices.g.cs b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Client/ElasticsearchClient.Indices.g.cs
index 2da23396afb..2f4d720b91a 100644
--- a/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Client/ElasticsearchClient.Indices.g.cs
+++ b/src/Elastic.Clients.Elasticsearch.Serverless/_Generated/Client/ElasticsearchClient.Indices.g.cs
@@ -1664,29 +1664,6 @@ public virtual Task GetAliasAsync(Elastic.Clients.E
return DoRequestAsync, GetAliasResponse, GetAliasRequestParameters>(descriptor, cancellationToken);
}
- ///
- /// Returns an alias.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task GetAliasAsync(Elastic.Clients.Elasticsearch.Serverless.Names? name, CancellationToken cancellationToken = default)
- {
- var descriptor = new GetAliasRequestDescriptor(name);
- descriptor.BeforeRequest();
- return DoRequestAsync, GetAliasResponse, GetAliasRequestParameters>(descriptor, cancellationToken);
- }
-
- ///
- /// Returns an alias.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task GetAliasAsync(Elastic.Clients.Elasticsearch.Serverless.Names? name, Action> configureRequest, CancellationToken cancellationToken = default)
- {
- var descriptor = new GetAliasRequestDescriptor(name);
- configureRequest?.Invoke(descriptor);
- descriptor.BeforeRequest();
- return DoRequestAsync, GetAliasResponse, GetAliasRequestParameters>(descriptor, cancellationToken);
- }
-
///
/// Returns an alias.
/// Learn more about this API in the Elasticsearch documentation.
@@ -2106,29 +2083,6 @@ public virtual Task GetSettingsAsync(Elas
return DoRequestAsync, GetIndicesSettingsResponse, GetIndicesSettingsRequestParameters>(descriptor, cancellationToken);
}
- ///
- /// Returns settings for one or more indices.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task GetSettingsAsync(Elastic.Clients.Elasticsearch.Serverless.Names? name, CancellationToken cancellationToken = default)
- {
- var descriptor = new GetIndicesSettingsRequestDescriptor(name);
- descriptor.BeforeRequest();
- return DoRequestAsync, GetIndicesSettingsResponse, GetIndicesSettingsRequestParameters>(descriptor, cancellationToken);
- }
-
- ///
- /// Returns settings for one or more indices.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task GetSettingsAsync(Elastic.Clients.Elasticsearch.Serverless.Names? name, Action> configureRequest, CancellationToken cancellationToken = default)
- {
- var descriptor = new GetIndicesSettingsRequestDescriptor(name);
- configureRequest?.Invoke(descriptor);
- descriptor.BeforeRequest();
- return DoRequestAsync, GetIndicesSettingsResponse, GetIndicesSettingsRequestParameters>(descriptor, cancellationToken);
- }
-
///
/// Returns settings for one or more indices.
/// Learn more about this API in the Elasticsearch documentation.
@@ -3647,29 +3601,6 @@ public virtual Task StatsAsync(Elastic.Clients.
return DoRequestAsync, IndicesStatsResponse, IndicesStatsRequestParameters>(descriptor, cancellationToken);
}
- ///
- /// Provides statistics on operations happening in an index.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task StatsAsync(Elastic.Clients.Elasticsearch.Serverless.Metrics? metric, CancellationToken cancellationToken = default)
- {
- var descriptor = new IndicesStatsRequestDescriptor(metric);
- descriptor.BeforeRequest();
- return DoRequestAsync, IndicesStatsResponse, IndicesStatsRequestParameters>(descriptor, cancellationToken);
- }
-
- ///
- /// Provides statistics on operations happening in an index.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task StatsAsync(Elastic.Clients.Elasticsearch.Serverless.Metrics? metric, Action> configureRequest, CancellationToken cancellationToken = default)
- {
- var descriptor = new IndicesStatsRequestDescriptor(metric);
- configureRequest?.Invoke(descriptor);
- descriptor.BeforeRequest();
- return DoRequestAsync, IndicesStatsResponse, IndicesStatsRequestParameters>(descriptor, cancellationToken);
- }
-
///
/// Provides statistics on operations happening in an index.
/// Learn more about this API in the Elasticsearch documentation.
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/AsyncSearch/SubmitAsyncSearchRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/AsyncSearch/SubmitAsyncSearchRequest.g.cs
index 3ad595ff86b..14e1340f92d 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/AsyncSearch/SubmitAsyncSearchRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/AsyncSearch/SubmitAsyncSearchRequest.g.cs
@@ -958,7 +958,7 @@ public SubmitAsyncSearchRequestDescriptor(Elastic.Clients.Elasticsearch.Indices?
{
}
- public SubmitAsyncSearchRequestDescriptor() : this(typeof(TDocument))
+ public SubmitAsyncSearchRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/Cluster/HealthRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/Cluster/HealthRequest.g.cs
index b192ce99239..342cb4a4b33 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/Cluster/HealthRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/Cluster/HealthRequest.g.cs
@@ -186,7 +186,7 @@ public HealthRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indices) :
{
}
- public HealthRequestDescriptor() : this(typeof(TDocument))
+ public HealthRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/CountRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/CountRequest.g.cs
index 1a74c5f04d6..310e99a5814 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/CountRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/CountRequest.g.cs
@@ -225,7 +225,7 @@ public CountRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indices) :
{
}
- public CountRequestDescriptor() : this(typeof(TDocument))
+ public CountRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/FieldCapsRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/FieldCapsRequest.g.cs
index 79f73124cbe..a28c466e09c 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/FieldCapsRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/FieldCapsRequest.g.cs
@@ -161,7 +161,7 @@ public FieldCapsRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indices
{
}
- public FieldCapsRequestDescriptor() : this(typeof(TDocument))
+ public FieldCapsRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ClearCacheRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ClearCacheRequest.g.cs
index 83d0246c427..d56c1df76d3 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ClearCacheRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ClearCacheRequest.g.cs
@@ -142,7 +142,7 @@ public ClearCacheRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indice
{
}
- public ClearCacheRequestDescriptor() : this(typeof(TDocument))
+ public ClearCacheRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ExistsAliasRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ExistsAliasRequest.g.cs
index 0033bdbc442..6defcc04931 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ExistsAliasRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ExistsAliasRequest.g.cs
@@ -109,7 +109,7 @@ public ExistsAliasRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indic
{
}
- public ExistsAliasRequestDescriptor(Elastic.Clients.Elasticsearch.Names name) : this(typeof(TDocument), name)
+ public ExistsAliasRequestDescriptor(Elastic.Clients.Elasticsearch.Names name) : base(r => r.Required("name", name))
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/FlushRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/FlushRequest.g.cs
index b75011934d5..2194f089487 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/FlushRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/FlushRequest.g.cs
@@ -120,7 +120,7 @@ public FlushRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indices) :
{
}
- public FlushRequestDescriptor() : this(typeof(TDocument))
+ public FlushRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ForcemergeRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ForcemergeRequest.g.cs
index b1e7646144e..4245584ec42 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ForcemergeRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ForcemergeRequest.g.cs
@@ -142,7 +142,7 @@ public ForcemergeRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indice
{
}
- public ForcemergeRequestDescriptor() : this(typeof(TDocument))
+ public ForcemergeRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetAliasRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetAliasRequest.g.cs
index 54776696103..70c3452e508 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetAliasRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetAliasRequest.g.cs
@@ -117,10 +117,6 @@ public GetAliasRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indices,
{
}
- public GetAliasRequestDescriptor(Elastic.Clients.Elasticsearch.Names? name) : this(typeof(TDocument), name)
- {
- }
-
public GetAliasRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetFieldMappingRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetFieldMappingRequest.g.cs
index 63c72197399..b5899de3820 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetFieldMappingRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetFieldMappingRequest.g.cs
@@ -120,7 +120,7 @@ public GetFieldMappingRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? i
{
}
- public GetFieldMappingRequestDescriptor(Elastic.Clients.Elasticsearch.Fields fields) : this(typeof(TDocument), fields)
+ public GetFieldMappingRequestDescriptor(Elastic.Clients.Elasticsearch.Fields fields) : base(r => r.Required("fields", fields))
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetIndicesSettingsRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetIndicesSettingsRequest.g.cs
index 2f058fd1d3f..02070aa4e22 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetIndicesSettingsRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetIndicesSettingsRequest.g.cs
@@ -150,10 +150,6 @@ public GetIndicesSettingsRequestDescriptor(Elastic.Clients.Elasticsearch.Indices
{
}
- public GetIndicesSettingsRequestDescriptor(Elastic.Clients.Elasticsearch.Names? name) : this(typeof(TDocument), name)
- {
- }
-
public GetIndicesSettingsRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetMappingRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetMappingRequest.g.cs
index f7ee70e766f..0fd72ff5efb 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetMappingRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/GetMappingRequest.g.cs
@@ -120,7 +120,7 @@ public GetMappingRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indice
{
}
- public GetMappingRequestDescriptor() : this(typeof(TDocument))
+ public GetMappingRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/IndicesStatsRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/IndicesStatsRequest.g.cs
index 5035f094f10..6e21bd21446 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/IndicesStatsRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/IndicesStatsRequest.g.cs
@@ -172,10 +172,6 @@ public IndicesStatsRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indi
{
}
- public IndicesStatsRequestDescriptor(Elastic.Clients.Elasticsearch.Metrics? metric) : this(typeof(TDocument), metric)
- {
- }
-
public IndicesStatsRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/RecoveryRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/RecoveryRequest.g.cs
index ca40be5914d..839eb4c1ce4 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/RecoveryRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/RecoveryRequest.g.cs
@@ -87,7 +87,7 @@ public RecoveryRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indices)
{
}
- public RecoveryRequestDescriptor() : this(typeof(TDocument))
+ public RecoveryRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/RefreshRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/RefreshRequest.g.cs
index 2872ca3dd3e..41eff24cccd 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/RefreshRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/RefreshRequest.g.cs
@@ -98,7 +98,7 @@ public RefreshRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indices)
{
}
- public RefreshRequestDescriptor() : this(typeof(TDocument))
+ public RefreshRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/SegmentsRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/SegmentsRequest.g.cs
index 0114bfb2f80..0040eb05b5a 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/SegmentsRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/SegmentsRequest.g.cs
@@ -109,7 +109,7 @@ public SegmentsRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indices)
{
}
- public SegmentsRequestDescriptor() : this(typeof(TDocument))
+ public SegmentsRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ShardStoresRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ShardStoresRequest.g.cs
index 321cb2f2f79..56fa019cda4 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ShardStoresRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ShardStoresRequest.g.cs
@@ -109,7 +109,7 @@ public ShardStoresRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indic
{
}
- public ShardStoresRequestDescriptor() : this(typeof(TDocument))
+ public ShardStoresRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ValidateQueryRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ValidateQueryRequest.g.cs
index 7c71662bf89..fd9b53415bc 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ValidateQueryRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/IndexManagement/ValidateQueryRequest.g.cs
@@ -203,7 +203,7 @@ public ValidateQueryRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? ind
{
}
- public ValidateQueryRequestDescriptor() : this(typeof(TDocument))
+ public ValidateQueryRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/MultiSearchRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/MultiSearchRequest.g.cs
index b49f91c40f6..d1359e9ced0 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/MultiSearchRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/MultiSearchRequest.g.cs
@@ -214,7 +214,7 @@ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClien
///
/// Allows to execute several search operations in one request.
///
-public sealed partial class MultiSearchRequestDescriptor : RequestDescriptor, MultiSearchRequestParameters>
+public sealed partial class MultiSearchRequestDescriptor : RequestDescriptor, MultiSearchRequestParameters>, IStreamSerializable
{
internal MultiSearchRequestDescriptor(Action> configure) => configure.Invoke(this);
@@ -222,7 +222,7 @@ public MultiSearchRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indic
{
}
- public MultiSearchRequestDescriptor() : this(typeof(TDocument))
+ public MultiSearchRequestDescriptor()
{
}
@@ -259,6 +259,28 @@ protected override void Serialize(Utf8JsonWriter writer, JsonSerializerOptions o
List _items = new();
+ void IStreamSerializable.Serialize(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ serializable.Serialize(stream, settings, formatting);
+ }
+ }
+
+ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ await serializable.SerializeAsync(stream, settings, formatting).ConfigureAwait(false);
+ }
+ }
+
public MultiSearchRequestDescriptor AddSearches(Elastic.Clients.Elasticsearch.Core.MSearch.SearchRequestItem searches)
{
_items.Add(searches);
@@ -269,7 +291,7 @@ public MultiSearchRequestDescriptor AddSearches(Elastic.Clients.Elast
///
/// Allows to execute several search operations in one request.
///
-public sealed partial class MultiSearchRequestDescriptor : RequestDescriptor
+public sealed partial class MultiSearchRequestDescriptor : RequestDescriptor, IStreamSerializable
{
internal MultiSearchRequestDescriptor(Action configure) => configure.Invoke(this);
@@ -314,6 +336,28 @@ protected override void Serialize(Utf8JsonWriter writer, JsonSerializerOptions o
List _items = new();
+ void IStreamSerializable.Serialize(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ serializable.Serialize(stream, settings, formatting);
+ }
+ }
+
+ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ await serializable.SerializeAsync(stream, settings, formatting).ConfigureAwait(false);
+ }
+ }
+
public MultiSearchRequestDescriptor AddSearches(Elastic.Clients.Elasticsearch.Core.MSearch.SearchRequestItem searches)
{
_items.Add(searches);
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/MultiSearchTemplateRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/MultiSearchTemplateRequest.g.cs
index 843ee08f8f2..3de2b9c4abf 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/MultiSearchTemplateRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/MultiSearchTemplateRequest.g.cs
@@ -137,7 +137,7 @@ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClien
///
/// Runs multiple templated searches with a single request.
///
-public sealed partial class MultiSearchTemplateRequestDescriptor : RequestDescriptor, MultiSearchTemplateRequestParameters>
+public sealed partial class MultiSearchTemplateRequestDescriptor : RequestDescriptor, MultiSearchTemplateRequestParameters>, IStreamSerializable
{
internal MultiSearchTemplateRequestDescriptor(Action> configure) => configure.Invoke(this);
@@ -145,7 +145,7 @@ public MultiSearchTemplateRequestDescriptor(Elastic.Clients.Elasticsearch.Indice
{
}
- public MultiSearchTemplateRequestDescriptor() : this(typeof(TDocument))
+ public MultiSearchTemplateRequestDescriptor()
{
}
@@ -175,6 +175,28 @@ protected override void Serialize(Utf8JsonWriter writer, JsonSerializerOptions o
List _items = new();
+ void IStreamSerializable.Serialize(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ serializable.Serialize(stream, settings, formatting);
+ }
+ }
+
+ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ await serializable.SerializeAsync(stream, settings, formatting).ConfigureAwait(false);
+ }
+ }
+
public MultiSearchTemplateRequestDescriptor AddSearchTemplates(Elastic.Clients.Elasticsearch.Core.MSearchTemplate.SearchTemplateRequestItem searchTemplates)
{
_items.Add(searchTemplates);
@@ -185,7 +207,7 @@ public MultiSearchTemplateRequestDescriptor AddSearchTemplates(Elasti
///
/// Runs multiple templated searches with a single request.
///
-public sealed partial class MultiSearchTemplateRequestDescriptor : RequestDescriptor
+public sealed partial class MultiSearchTemplateRequestDescriptor : RequestDescriptor, IStreamSerializable
{
internal MultiSearchTemplateRequestDescriptor(Action configure) => configure.Invoke(this);
@@ -223,6 +245,28 @@ protected override void Serialize(Utf8JsonWriter writer, JsonSerializerOptions o
List _items = new();
+ void IStreamSerializable.Serialize(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ serializable.Serialize(stream, settings, formatting);
+ }
+ }
+
+ async Task IStreamSerializable.SerializeAsync(Stream stream, IElasticsearchClientSettings settings, SerializationFormatting formatting)
+ {
+ if (_items is null)
+ return;
+ foreach (var item in _items)
+ {
+ if (item is IStreamSerializable serializable)
+ await serializable.SerializeAsync(stream, settings, formatting).ConfigureAwait(false);
+ }
+ }
+
public MultiSearchTemplateRequestDescriptor AddSearchTemplates(Elastic.Clients.Elasticsearch.Core.MSearchTemplate.SearchTemplateRequestItem searchTemplates)
{
_items.Add(searchTemplates);
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/RankEvalRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/RankEvalRequest.g.cs
index 4b104540d71..c5a343c35d4 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/RankEvalRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/RankEvalRequest.g.cs
@@ -121,7 +121,7 @@ public RankEvalRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indices)
{
}
- public RankEvalRequestDescriptor() : this(typeof(TDocument))
+ public RankEvalRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchRequest.g.cs
index 2684f4d1362..130cc7920b5 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchRequest.g.cs
@@ -1018,7 +1018,7 @@ public SearchRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indices) :
{
}
- public SearchRequestDescriptor() : this(typeof(TDocument))
+ public SearchRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchShardsRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchShardsRequest.g.cs
index e21e36c2867..409256a844f 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchShardsRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchShardsRequest.g.cs
@@ -131,7 +131,7 @@ public SearchShardsRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indi
{
}
- public SearchShardsRequestDescriptor() : this(typeof(TDocument))
+ public SearchShardsRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchTemplateRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchTemplateRequest.g.cs
index df8516eba1d..c75a96a6bb2 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchTemplateRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchTemplateRequest.g.cs
@@ -216,7 +216,7 @@ public SearchTemplateRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? in
{
}
- public SearchTemplateRequestDescriptor() : this(typeof(TDocument))
+ public SearchTemplateRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchableSnapshots/ClearCacheRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchableSnapshots/ClearCacheRequest.g.cs
index 00e28e9acb3..1fc04bdccae 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchableSnapshots/ClearCacheRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchableSnapshots/ClearCacheRequest.g.cs
@@ -98,7 +98,7 @@ public ClearCacheRequestDescriptor(Elastic.Clients.Elasticsearch.Indices? indice
{
}
- public ClearCacheRequestDescriptor() : this(typeof(TDocument))
+ public ClearCacheRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchableSnapshots/SearchableSnapshotsStatsRequest.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchableSnapshots/SearchableSnapshotsStatsRequest.g.cs
index 9abc5b9de4f..d7306d64eca 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchableSnapshots/SearchableSnapshotsStatsRequest.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Api/SearchableSnapshots/SearchableSnapshotsStatsRequest.g.cs
@@ -76,7 +76,7 @@ public SearchableSnapshotsStatsRequestDescriptor(Elastic.Clients.Elasticsearch.I
{
}
- public SearchableSnapshotsStatsRequestDescriptor() : this(typeof(TDocument))
+ public SearchableSnapshotsStatsRequestDescriptor()
{
}
diff --git a/src/Elastic.Clients.Elasticsearch/_Generated/Client/ElasticsearchClient.Indices.g.cs b/src/Elastic.Clients.Elasticsearch/_Generated/Client/ElasticsearchClient.Indices.g.cs
index c9a9a509283..899909bbc15 100644
--- a/src/Elastic.Clients.Elasticsearch/_Generated/Client/ElasticsearchClient.Indices.g.cs
+++ b/src/Elastic.Clients.Elasticsearch/_Generated/Client/ElasticsearchClient.Indices.g.cs
@@ -4366,31 +4366,6 @@ public virtual GetAliasResponse GetAlias(Elastic.Clients.Elasticsearc
return DoRequest, GetAliasResponse, GetAliasRequestParameters>(descriptor);
}
- ///
- /// Returns an alias.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- [Obsolete("Synchronous methods are deprecated and could be removed in the future.")]
- public virtual GetAliasResponse GetAlias(Elastic.Clients.Elasticsearch.Names? name)
- {
- var descriptor = new GetAliasRequestDescriptor(name);
- descriptor.BeforeRequest();
- return DoRequest, GetAliasResponse, GetAliasRequestParameters>(descriptor);
- }
-
- ///
- /// Returns an alias.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- [Obsolete("Synchronous methods are deprecated and could be removed in the future.")]
- public virtual GetAliasResponse GetAlias(Elastic.Clients.Elasticsearch.Names? name, Action> configureRequest)
- {
- var descriptor = new GetAliasRequestDescriptor(name);
- configureRequest?.Invoke(descriptor);
- descriptor.BeforeRequest();
- return DoRequest, GetAliasResponse, GetAliasRequestParameters>(descriptor);
- }
-
///
/// Returns an alias.
/// Learn more about this API in the Elasticsearch documentation.
@@ -4510,29 +4485,6 @@ public virtual Task GetAliasAsync(Elastic.Clients.E
return DoRequestAsync, GetAliasResponse, GetAliasRequestParameters>(descriptor, cancellationToken);
}
- ///
- /// Returns an alias.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task GetAliasAsync(Elastic.Clients.Elasticsearch.Names? name, CancellationToken cancellationToken = default)
- {
- var descriptor = new GetAliasRequestDescriptor(name);
- descriptor.BeforeRequest();
- return DoRequestAsync, GetAliasResponse, GetAliasRequestParameters>(descriptor, cancellationToken);
- }
-
- ///
- /// Returns an alias.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task GetAliasAsync(Elastic.Clients.Elasticsearch.Names? name, Action> configureRequest, CancellationToken cancellationToken = default)
- {
- var descriptor = new GetAliasRequestDescriptor(name);
- configureRequest?.Invoke(descriptor);
- descriptor.BeforeRequest();
- return DoRequestAsync, GetAliasResponse, GetAliasRequestParameters>(descriptor, cancellationToken);
- }
-
///
/// Returns an alias.
/// Learn more about this API in the Elasticsearch documentation.
@@ -5545,31 +5497,6 @@ public virtual GetIndicesSettingsResponse GetSettings(Elastic.Clients
return DoRequest, GetIndicesSettingsResponse, GetIndicesSettingsRequestParameters>(descriptor);
}
- ///
- /// Returns settings for one or more indices.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- [Obsolete("Synchronous methods are deprecated and could be removed in the future.")]
- public virtual GetIndicesSettingsResponse GetSettings(Elastic.Clients.Elasticsearch.Names? name)
- {
- var descriptor = new GetIndicesSettingsRequestDescriptor(name);
- descriptor.BeforeRequest();
- return DoRequest, GetIndicesSettingsResponse, GetIndicesSettingsRequestParameters>(descriptor);
- }
-
- ///
- /// Returns settings for one or more indices.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- [Obsolete("Synchronous methods are deprecated and could be removed in the future.")]
- public virtual GetIndicesSettingsResponse GetSettings(Elastic.Clients.Elasticsearch.Names? name, Action> configureRequest)
- {
- var descriptor = new GetIndicesSettingsRequestDescriptor(name);
- configureRequest?.Invoke(descriptor);
- descriptor.BeforeRequest();
- return DoRequest, GetIndicesSettingsResponse, GetIndicesSettingsRequestParameters>(descriptor);
- }
-
///
/// Returns settings for one or more indices.
/// Learn more about this API in the Elasticsearch documentation.
@@ -5689,29 +5616,6 @@ public virtual Task GetSettingsAsync(Elas
return DoRequestAsync, GetIndicesSettingsResponse, GetIndicesSettingsRequestParameters>(descriptor, cancellationToken);
}
- ///
- /// Returns settings for one or more indices.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task GetSettingsAsync(Elastic.Clients.Elasticsearch.Names? name, CancellationToken cancellationToken = default)
- {
- var descriptor = new GetIndicesSettingsRequestDescriptor(name);
- descriptor.BeforeRequest();
- return DoRequestAsync, GetIndicesSettingsResponse, GetIndicesSettingsRequestParameters>(descriptor, cancellationToken);
- }
-
- ///
- /// Returns settings for one or more indices.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task GetSettingsAsync(Elastic.Clients.Elasticsearch.Names? name, Action> configureRequest, CancellationToken cancellationToken = default)
- {
- var descriptor = new GetIndicesSettingsRequestDescriptor(name);
- configureRequest?.Invoke(descriptor);
- descriptor.BeforeRequest();
- return DoRequestAsync, GetIndicesSettingsResponse, GetIndicesSettingsRequestParameters>(descriptor, cancellationToken);
- }
-
///
/// Returns settings for one or more indices.
/// Learn more about this API in the Elasticsearch documentation.
@@ -9865,31 +9769,6 @@ public virtual IndicesStatsResponse Stats(Elastic.Clients.Elasticsear
return DoRequest, IndicesStatsResponse, IndicesStatsRequestParameters>(descriptor);
}
- ///
- /// Provides statistics on operations happening in an index.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- [Obsolete("Synchronous methods are deprecated and could be removed in the future.")]
- public virtual IndicesStatsResponse Stats(Elastic.Clients.Elasticsearch.Metrics? metric)
- {
- var descriptor = new IndicesStatsRequestDescriptor(metric);
- descriptor.BeforeRequest();
- return DoRequest, IndicesStatsResponse, IndicesStatsRequestParameters>(descriptor);
- }
-
- ///
- /// Provides statistics on operations happening in an index.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- [Obsolete("Synchronous methods are deprecated and could be removed in the future.")]
- public virtual IndicesStatsResponse Stats(Elastic.Clients.Elasticsearch.Metrics? metric, Action> configureRequest)
- {
- var descriptor = new IndicesStatsRequestDescriptor(metric);
- configureRequest?.Invoke(descriptor);
- descriptor.BeforeRequest();
- return DoRequest, IndicesStatsResponse, IndicesStatsRequestParameters>(descriptor);
- }
-
///
/// Provides statistics on operations happening in an index.
/// Learn more about this API in the Elasticsearch documentation.
@@ -10009,29 +9888,6 @@ public virtual Task StatsAsync(Elastic.Clients.
return DoRequestAsync, IndicesStatsResponse, IndicesStatsRequestParameters>(descriptor, cancellationToken);
}
- ///
- /// Provides statistics on operations happening in an index.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task StatsAsync(Elastic.Clients.Elasticsearch.Metrics? metric, CancellationToken cancellationToken = default)
- {
- var descriptor = new IndicesStatsRequestDescriptor(metric);
- descriptor.BeforeRequest();
- return DoRequestAsync, IndicesStatsResponse, IndicesStatsRequestParameters>(descriptor, cancellationToken);
- }
-
- ///
- /// Provides statistics on operations happening in an index.
- /// Learn more about this API in the Elasticsearch documentation.
- ///
- public virtual Task StatsAsync(Elastic.Clients.Elasticsearch.Metrics? metric, Action> configureRequest, CancellationToken cancellationToken = default)
- {
- var descriptor = new IndicesStatsRequestDescriptor(metric);
- configureRequest?.Invoke(descriptor);
- descriptor.BeforeRequest();
- return DoRequestAsync, IndicesStatsResponse, IndicesStatsRequestParameters>(descriptor, cancellationToken);
- }
-
///
/// Provides statistics on operations happening in an index.
/// Learn more about this API in the Elasticsearch documentation.