@@ -50,14 +50,31 @@ public string Encoded(object o)
5050 return Uri . EscapeDataString ( this . Serializer . Stringify ( o ) ) ;
5151 }
5252
53-
54- protected ElasticsearchResponse < T > DoRequest < T > ( string method , string path , object data = null , IRequestParameters requestParameters = null )
53+
54+ /// <summary>
55+ /// Perform any request you want over the configured IConnection synchronously while taking advantage of the cluster failover.
56+ /// </summary>
57+ /// <typeparam name="T">The type representing the response JSON</typeparam>
58+ /// <param name="method">the HTTP Method to use</param>
59+ /// <param name="path">The path of the the url that you would like to hit</param>
60+ /// <param name="data">The body of the request, string and byte[] are posted as is other types will be serialized to JSON</param>
61+ /// <param name="requestParameters">Optionally configure request specific timeouts, headers</param>
62+ /// <returns>An ElasticsearchResponse of T where T represents the JSON response body</returns>
63+ public ElasticsearchResponse < T > DoRequest < T > ( string method , string path , object data = null , IRequestParameters requestParameters = null )
5564 {
5665 return this . Transport . DoRequest < T > ( method , path , data , requestParameters ) ;
5766 }
5867
59-
60- protected Task < ElasticsearchResponse < T > > DoRequestAsync < T > ( string method , string path , object data = null , IRequestParameters requestParameters = null )
68+ /// <summary>
69+ /// Perform any request you want over the configured IConnection asynchronously while taking advantage of the cluster failover.
70+ /// </summary>
71+ /// <typeparam name="T">The type representing the response JSON</typeparam>
72+ /// <param name="method">the HTTP Method to use</param>
73+ /// <param name="path">The path of the the url that you would like to hit</param>
74+ /// <param name="data">The body of the request, string and byte[] are posted as is other types will be serialized to JSON</param>
75+ /// <param name="requestParameters">Optionally configure request specific timeouts, headers</param>
76+ /// <returns>A task of ElasticsearchResponse of T where T represents the JSON response body</returns>
77+ public Task < ElasticsearchResponse < T > > DoRequestAsync < T > ( string method , string path , object data = null , IRequestParameters requestParameters = null )
6178 {
6279 return this . Transport . DoRequestAsync < T > ( method , path , data , requestParameters ) ;
6380 }
0 commit comments