Skip to content

Commit 14d50c7

Browse files
authored
[codegen] master synchronization
1 parent 63bba67 commit 14d50c7

File tree

6 files changed

+176
-4
lines changed

6 files changed

+176
-4
lines changed

src/ApiGenerator/RestSpecification/Core/security.enroll_node.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"security.enroll_node":{
33
"documentation":{
4-
"url":"https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-enroll-node.html",
4+
"url":"https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-node-enrollment.html",
55
"description":"Allows a new node to enroll to an existing cluster with security enabled."
66
},
77
"stability":"stable",
Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
{
2+
"snapshot.repository_analyze":{
3+
"documentation":{
4+
"url":"https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html",
5+
"description":"Analyzes a repository for correctness and performance"
6+
},
7+
"stability":"stable",
8+
"visibility":"public",
9+
"headers": {
10+
"accept": [
11+
"application/json"
12+
]
13+
},
14+
"url":{
15+
"paths":[
16+
{
17+
"path":"/_snapshot/{repository}/_analyze",
18+
"methods":[
19+
"POST"
20+
],
21+
"parts":{
22+
"repository":{
23+
"type":"string",
24+
"description":"A repository name"
25+
}
26+
}
27+
}
28+
]
29+
},
30+
"params":{
31+
"blob_count":{
32+
"type":"number",
33+
"description":"Number of blobs to create during the test. Defaults to 100."
34+
},
35+
"concurrency":{
36+
"type":"number",
37+
"description":"Number of operations to run concurrently during the test. Defaults to 10."
38+
},
39+
"read_node_count":{
40+
"type":"number",
41+
"description":"Number of nodes on which to read a blob after writing. Defaults to 10."
42+
},
43+
"early_read_node_count":{
44+
"type":"number",
45+
"description":"Number of nodes on which to perform an early read on a blob, i.e. before writing has completed. Early reads are rare actions so the 'rare_action_probability' parameter is also relevant. Defaults to 2."
46+
},
47+
"seed":{
48+
"type":"number",
49+
"description":"Seed for the random number generator used to create the test workload. Defaults to a random value."
50+
},
51+
"rare_action_probability":{
52+
"type":"number",
53+
"description":"Probability of taking a rare action such as an early read or an overwrite. Defaults to 0.02."
54+
},
55+
"max_blob_size":{
56+
"type":"string",
57+
"description":"Maximum size of a blob to create during the test, e.g '1gb' or '100mb'. Defaults to '10mb'."
58+
},
59+
"max_total_data_size":{
60+
"type":"string",
61+
"description":"Maximum total size of all blobs to create during the test, e.g '1tb' or '100gb'. Defaults to '1gb'."
62+
},
63+
"timeout":{
64+
"type":"time",
65+
"description":"Explicit operation timeout. Defaults to '30s'."
66+
},
67+
"detailed":{
68+
"type":"boolean",
69+
"description":"Whether to return detailed results or a summary. Defaults to 'false' so that only the summary is returned."
70+
},
71+
"rarely_abort_writes":{
72+
"type":"boolean",
73+
"description":"Whether to rarely abort writes before they complete. Defaults to 'true'."
74+
}
75+
}
76+
}
77+
}

src/Elasticsearch.Net/Api/RequestParameters/RequestParameters.Security.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ public Refresh? Refresh
204204
}
205205
}
206206

207-
///<summary>Request options for EnrollNode <para>https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-enroll-node.html</para></summary>
207+
///<summary>Request options for EnrollNode <para>https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-node-enrollment.html</para></summary>
208208
public class EnrollNodeRequestParameters : RequestParameters<EnrollNodeRequestParameters>
209209
{
210210
}

src/Elasticsearch.Net/Api/RequestParameters/RequestParameters.Snapshot.cs

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,90 @@ public TimeSpan MasterTimeout
179179
}
180180
}
181181

182+
///<summary>Request options for RepositoryAnalyze <para>https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html</para></summary>
183+
public class RepositoryAnalyzeRequestParameters : RequestParameters<RepositoryAnalyzeRequestParameters>
184+
{
185+
///<summary>Number of blobs to create during the test. Defaults to 100.</summary>
186+
public long? BlobCount
187+
{
188+
get => Q<long? >("blob_count");
189+
set => Q("blob_count", value);
190+
}
191+
192+
///<summary>Number of operations to run concurrently during the test. Defaults to 10.</summary>
193+
public long? Concurrency
194+
{
195+
get => Q<long? >("concurrency");
196+
set => Q("concurrency", value);
197+
}
198+
199+
///<summary>Whether to return detailed results or a summary. Defaults to 'false' so that only the summary is returned.</summary>
200+
public bool? Detailed
201+
{
202+
get => Q<bool? >("detailed");
203+
set => Q("detailed", value);
204+
}
205+
206+
///<summary>
207+
/// Number of nodes on which to perform an early read on a blob, i.e. before writing has completed. Early reads are rare actions so the
208+
/// 'rare_action_probability' parameter is also relevant. Defaults to 2.
209+
///</summary>
210+
public long? EarlyReadNodeCount
211+
{
212+
get => Q<long? >("early_read_node_count");
213+
set => Q("early_read_node_count", value);
214+
}
215+
216+
///<summary>Maximum size of a blob to create during the test, e.g '1gb' or '100mb'. Defaults to '10mb'.</summary>
217+
public string MaxBlobSize
218+
{
219+
get => Q<string>("max_blob_size");
220+
set => Q("max_blob_size", value);
221+
}
222+
223+
///<summary>Maximum total size of all blobs to create during the test, e.g '1tb' or '100gb'. Defaults to '1gb'.</summary>
224+
public string MaxTotalDataSize
225+
{
226+
get => Q<string>("max_total_data_size");
227+
set => Q("max_total_data_size", value);
228+
}
229+
230+
///<summary>Probability of taking a rare action such as an early read or an overwrite. Defaults to 0.02.</summary>
231+
public long? RareActionProbability
232+
{
233+
get => Q<long? >("rare_action_probability");
234+
set => Q("rare_action_probability", value);
235+
}
236+
237+
///<summary>Whether to rarely abort writes before they complete. Defaults to 'true'.</summary>
238+
public bool? RarelyAbortWrites
239+
{
240+
get => Q<bool? >("rarely_abort_writes");
241+
set => Q("rarely_abort_writes", value);
242+
}
243+
244+
///<summary>Number of nodes on which to read a blob after writing. Defaults to 10.</summary>
245+
public long? ReadNodeCount
246+
{
247+
get => Q<long? >("read_node_count");
248+
set => Q("read_node_count", value);
249+
}
250+
251+
///<summary>Seed for the random number generator used to create the test workload. Defaults to a random value.</summary>
252+
public long? Seed
253+
{
254+
get => Q<long? >("seed");
255+
set => Q("seed", value);
256+
}
257+
258+
///<summary>Explicit operation timeout. Defaults to '30s'.</summary>
259+
public TimeSpan Timeout
260+
{
261+
get => Q<TimeSpan>("timeout");
262+
set => Q("timeout", value);
263+
}
264+
}
265+
182266
///<summary>Request options for Restore <para>https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html</para></summary>
183267
public class RestoreRequestParameters : RequestParameters<RestoreRequestParameters>
184268
{

src/Elasticsearch.Net/ElasticLowLevelClient.Security.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -278,11 +278,11 @@ public TResponse EnableUser<TResponse>(string username, EnableUserRequestParamet
278278
[MapsApi("security.enable_user", "username")]
279279
public Task<TResponse> EnableUserAsync<TResponse>(string username, EnableUserRequestParameters requestParameters = null, CancellationToken ctx = default)
280280
where TResponse : class, ITransportResponse, new() => DoRequestAsync<TResponse>(PUT, Url($"_security/user/{username:username}/_enable"), ctx, null, RequestParams(requestParameters));
281-
///<summary>GET on /_security/enroll_node <para>https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-enroll-node.html</para></summary>
281+
///<summary>GET on /_security/enroll_node <para>https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-node-enrollment.html</para></summary>
282282
///<param name = "requestParameters">Request specific configuration such as querystring parameters &amp; request specific connection settings.</param>
283283
public TResponse EnrollNode<TResponse>(EnrollNodeRequestParameters requestParameters = null)
284284
where TResponse : class, ITransportResponse, new() => DoRequest<TResponse>(GET, "_security/enroll_node", null, RequestParams(requestParameters));
285-
///<summary>GET on /_security/enroll_node <para>https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-enroll-node.html</para></summary>
285+
///<summary>GET on /_security/enroll_node <para>https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-node-enrollment.html</para></summary>
286286
///<param name = "requestParameters">Request specific configuration such as querystring parameters &amp; request specific connection settings.</param>
287287
[MapsApi("security.enroll_node", "")]
288288
public Task<TResponse> EnrollNodeAsync<TResponse>(EnrollNodeRequestParameters requestParameters = null, CancellationToken ctx = default)

src/Elasticsearch.Net/ElasticLowLevelClient.Snapshot.cs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,17 @@ public TResponse GetRepository<TResponse>(string repository, GetRepositoryReques
160160
[MapsApi("snapshot.get_repository", "repository")]
161161
public Task<TResponse> GetRepositoryAsync<TResponse>(string repository, GetRepositoryRequestParameters requestParameters = null, CancellationToken ctx = default)
162162
where TResponse : class, ITransportResponse, new() => DoRequestAsync<TResponse>(GET, Url($"_snapshot/{repository:repository}"), ctx, null, RequestParams(requestParameters));
163+
///<summary>POST on /_snapshot/{repository}/_analyze <para>https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html</para></summary>
164+
///<param name = "repository">A repository name</param>
165+
///<param name = "requestParameters">Request specific configuration such as querystring parameters &amp; request specific connection settings.</param>
166+
public TResponse RepositoryAnalyze<TResponse>(string repository, RepositoryAnalyzeRequestParameters requestParameters = null)
167+
where TResponse : class, ITransportResponse, new() => DoRequest<TResponse>(POST, Url($"_snapshot/{repository:repository}/_analyze"), null, RequestParams(requestParameters));
168+
///<summary>POST on /_snapshot/{repository}/_analyze <para>https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html</para></summary>
169+
///<param name = "repository">A repository name</param>
170+
///<param name = "requestParameters">Request specific configuration such as querystring parameters &amp; request specific connection settings.</param>
171+
[MapsApi("snapshot.repository_analyze", "repository")]
172+
public Task<TResponse> RepositoryAnalyzeAsync<TResponse>(string repository, RepositoryAnalyzeRequestParameters requestParameters = null, CancellationToken ctx = default)
173+
where TResponse : class, ITransportResponse, new() => DoRequestAsync<TResponse>(POST, Url($"_snapshot/{repository:repository}/_analyze"), ctx, null, RequestParams(requestParameters));
163174
///<summary>POST on /_snapshot/{repository}/{snapshot}/_restore <para>https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html</para></summary>
164175
///<param name = "repository">A repository name</param>
165176
///<param name = "snapshot">A snapshot name</param>

0 commit comments

Comments
 (0)