Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit f23fdf9

Browse files
stevejgordongithub-actions[bot]
authored andcommittedDec 5, 2022
Fix to ensure dynamic HTTP methods are used when available (#7058)
1 parent a737194 commit f23fdf9

File tree

116 files changed

+342
-279
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

116 files changed

+342
-279
lines changed
 

‎src/Elastic.Clients.Elasticsearch/Api/IndexRequest.cs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@ public partial class IndexRequest<TDocument> : ICustomJsonWriter
1414
{
1515
public IndexRequest() : this(typeof(TDocument)) { }
1616

17-
//public IndexRequest(TDocument document) : this(typeof(TDocument)) => Document = document;
18-
1917
public IndexRequest(TDocument document, Id id) : this(typeof(TDocument), id) => Document = document;
2018

2119
protected override HttpMethod? DynamicHttpMethod => GetHttpMethod(this);
@@ -34,7 +32,6 @@ internal static HttpMethod GetHttpMethod(IndexRequest<TDocument> request) =>
3432

3533
public sealed partial class IndexRequestDescriptor<TDocument> : ICustomJsonWriter
3634
{
37-
// TODO: Codegen
3835
public IndexRequestDescriptor<TDocument> Document(TDocument document)
3936
{
4037
DocumentValue = document;

‎src/Elastic.Clients.Elasticsearch/Core/Fluent/Descriptor.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ namespace Elastic.Clients.Elasticsearch.Fluent;
1414

1515
public abstract class Descriptor
1616
{
17-
// This internal ctor ensures that only types defined within the client assembly can derive from this base class.
17+
// This internal ctor ensures that only types defined within the Elastic.Clients.Elasticsearch assembly can derive from this base class.
1818
// We don't expect consumers to derive from this public base class.
1919
internal Descriptor() { }
2020

@@ -49,7 +49,7 @@ public abstract class Descriptor<TDescriptor> : Descriptor
4949
{
5050
private readonly TDescriptor _self;
5151

52-
// This internal ctor ensures that only types defined within the client assembly can derive from this base class.
52+
// This internal ctor ensures that only types defined within the Elastic.Clients.Elasticsearch assembly can derive from this base class.
5353
// We don't expect consumers to derive from this public base class.
5454
internal Descriptor() : base() => _self = (TDescriptor)this;
5555

@@ -64,7 +64,7 @@ public abstract class Descriptor<TDescriptor> : Descriptor
6464
public abstract class SerializableDescriptor<TDescriptor> : Descriptor<TDescriptor>, ISelfSerializable
6565
where TDescriptor : SerializableDescriptor<TDescriptor>
6666
{
67-
// This internal ctor ensures that only types defined within the client assembly can derive from this base class.
67+
// This internal ctor ensures that only types defined within the Elastic.Clients.Elasticsearch assembly can derive from this base class.
6868
// We don't expect consumers to derive from this public base class.
6969
internal SerializableDescriptor(): base() { }
7070

0 commit comments

Comments
 (0)
Please sign in to comment.