Skip to content

Commit 04ca72f

Browse files
committed
[codegen] Update to latest API spec
1 parent abf372a commit 04ca72f

11 files changed

+907
-30
lines changed

java-client/src/main/java/co/elastic/clients/elasticsearch/doc-files/api-spec.html

Lines changed: 18 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1478,7 +1478,7 @@
14781478
'ml._types.CalendarEvent': 'ml/_types/CalendarEvent.ts#L23-L33',
14791479
'ml._types.CategorizationAnalyzer': 'ml/_types/Analysis.ts#L123-L124',
14801480
'ml._types.CategorizationAnalyzerDefinition': 'ml/_types/Analysis.ts#L126-L139',
1481-
'ml._types.CategorizationStatus': 'ml/_types/Model.ts#L71-L74',
1481+
'ml._types.CategorizationStatus': 'ml/_types/Model.ts#L80-L83',
14821482
'ml._types.Category': 'ml/_types/Category.ts#L23-L49',
14831483
'ml._types.ChunkingConfig': 'ml/_types/Datafeed.ts#L156-L166',
14841484
'ml._types.ChunkingMode': 'ml/_types/Datafeed.ts#L150-L154',
@@ -1550,17 +1550,19 @@
15501550
'ml._types.JobStatistics': 'ml/_types/Job.ts#L39-L44',
15511551
'ml._types.JobStats': 'ml/_types/Job.ts#L91-L102',
15521552
'ml._types.JobTimingStats': 'ml/_types/Job.ts#L104-L113',
1553-
'ml._types.MemoryStatus': 'ml/_types/Model.ts#L76-L80',
1553+
'ml._types.MemoryStatus': 'ml/_types/Model.ts#L85-L89',
15541554
'ml._types.ModelPlotConfig': 'ml/_types/ModelPlot.ts#L23-L44',
1555-
'ml._types.ModelSizeStats': 'ml/_types/Model.ts#L47-L69',
1556-
'ml._types.ModelSnapshot': 'ml/_types/Model.ts#L24-L45',
1555+
'ml._types.ModelSizeStats': 'ml/_types/Model.ts#L56-L78',
1556+
'ml._types.ModelSnapshot': 'ml/_types/Model.ts#L25-L46',
1557+
'ml._types.ModelSnapshotUpgrade': 'ml/_types/Model.ts#L48-L54',
15571558
'ml._types.OutlierDetectionParameters': 'ml/_types/DataframeAnalytics.ts#L407-L414',
15581559
'ml._types.OverallBucket': 'ml/_types/Bucket.ts#L114-L127',
15591560
'ml._types.OverallBucketJob': 'ml/_types/Bucket.ts#L128-L131',
15601561
'ml._types.Page': 'ml/_types/Page.ts#L22-L33',
15611562
'ml._types.PerPartitionCategorization': 'ml/_types/Analysis.ts#L92-L101',
15621563
'ml._types.RuleAction': 'ml/_types/Rule.ts#L41-L50',
15631564
'ml._types.RuleCondition': 'ml/_types/Rule.ts#L52-L65',
1565+
'ml._types.SnapshotUpgradeState': 'ml/_types/Model.ts#L91-L96',
15641566
'ml._types.TimingStats': 'ml/_types/DataframeAnalytics.ts#L416-L421',
15651567
'ml._types.TotalFeatureImportance': 'ml/_types/TrainedModel.ts#L118-L125',
15661568
'ml._types.TotalFeatureImportanceClass': 'ml/_types/TrainedModel.ts#L127-L132',
@@ -1646,6 +1648,8 @@
16461648
'ml.get_job_stats.Response': 'ml/get_job_stats/MlGetJobStatsResponse.ts#L23-L28',
16471649
'ml.get_jobs.Request': 'ml/get_jobs/MlGetJobsRequest.ts#L23-L70',
16481650
'ml.get_jobs.Response': 'ml/get_jobs/MlGetJobsResponse.ts#L23-L28',
1651+
'ml.get_model_snapshot_upgrade_stats.Request': 'ml/get_model_snapshot_upgrade_stats/MlGetModelSnapshotUpgradeStatsRequest.ts#L23-L57',
1652+
'ml.get_model_snapshot_upgrade_stats.Response': 'ml/get_model_snapshot_upgrade_stats/MlGetModelSnapshotUpgradeStatsResponse.ts#L23-L28',
16491653
'ml.get_model_snapshots.Request': 'ml/get_model_snapshots/MlGetModelSnapshotsRequest.ts#L26-L96',
16501654
'ml.get_model_snapshots.Response': 'ml/get_model_snapshots/MlGetModelSnapshotsResponse.ts#L23-L28',
16511655
'ml.get_overall_buckets.Request': 'ml/get_overall_buckets/MlGetOverallBucketsRequest.ts#L25-L147',
@@ -1901,17 +1905,17 @@
19011905
'searchable_snapshots.mount.Response': 'searchable_snapshots/mount/SearchableSnapshotsMountResponse.ts#L22-L26',
19021906
'searchable_snapshots.stats.Request': 'searchable_snapshots/stats/SearchableSnapshotsStatsRequest.ts#L24-L36',
19031907
'searchable_snapshots.stats.Response': 'searchable_snapshots/stats/SearchableSnapshotsStatsResponse.ts#L22-L27',
1904-
'security._types.ApplicationGlobalUserPrivileges': 'security/_types/Privileges.ts#L127-L129',
1905-
'security._types.ApplicationPrivileges': 'security/_types/Privileges.ts#L24-L37',
1908+
'security._types.ApplicationGlobalUserPrivileges': 'security/_types/Privileges.ts#L163-L165',
1909+
'security._types.ApplicationPrivileges': 'security/_types/Privileges.ts#L26-L39',
19061910
'security._types.ClusterNode': 'security/_types/ClusterNode.ts#L22-L24',
1907-
'security._types.ClusterPrivilege': 'security/_types/Privileges.ts#L39-L75',
1911+
'security._types.ClusterPrivilege': 'security/_types/Privileges.ts#L41-L78',
19081912
'security._types.CreatedStatus': 'security/_types/CreatedStatus.ts#L20-L22',
19091913
'security._types.FieldRule': 'security/_types/RoleMappingRule.ts#L33-L42',
19101914
'security._types.FieldSecurity': 'security/_types/FieldSecurity.ts#L22-L25',
1911-
'security._types.GlobalPrivilege': 'security/_types/Privileges.ts#L123-L125',
1912-
'security._types.IndexPrivilege': 'security/_types/Privileges.ts#L102-L121',
1913-
'security._types.IndicesPrivileges': 'security/_types/Privileges.ts#L77-L100',
1914-
'security._types.ManageUserPrivileges': 'security/_types/Privileges.ts#L131-L133',
1915+
'security._types.GlobalPrivilege': 'security/_types/Privileges.ts#L159-L161',
1916+
'security._types.IndexPrivilege': 'security/_types/Privileges.ts#L137-L157',
1917+
'security._types.IndicesPrivileges': 'security/_types/Privileges.ts#L80-L103',
1918+
'security._types.ManageUserPrivileges': 'security/_types/Privileges.ts#L167-L169',
19151919
'security._types.Realm': 'security/_types/RoleMappingRule.ts#L44-L46',
19161920
'security._types.RealmInfo': 'security/_types/RealmInfo.ts#L22-L25',
19171921
'security._types.RoleMapping': 'security/_types/RoleMapping.ts#L25-L31',
@@ -1985,7 +1989,7 @@
19851989
'security.get_user.Request': 'security/get_user/SecurityGetUserRequest.ts#L23-L33',
19861990
'security.get_user.Response': 'security/get_user/SecurityGetUserResponse.ts#L23-L23',
19871991
'security.get_user_privileges.Request': 'security/get_user_privileges/SecurityGetUserPrivilegesRequest.ts#L23-L35',
1988-
'security.get_user_privileges.Response': 'security/get_user_privileges/SecurityGetUserPrivilegesResponse.ts#L26-L34',
1992+
'security.get_user_privileges.Response': 'security/get_user_privileges/SecurityGetUserPrivilegesResponse.ts#L26-L37',
19891993
'security.grant_api_key.ApiKey': 'security/grant_api_key/types.ts#L25-L29',
19901994
'security.grant_api_key.ApiKeyGrantType': 'security/grant_api_key/types.ts#L31-L34',
19911995
'security.grant_api_key.Request': 'security/grant_api_key/SecurityGrantApiKeyRequest.ts#L24-L37',
@@ -2320,10 +2324,10 @@
23202324
if (hash.length > 1) {
23212325
hash = hash.substring(1);
23222326
}
2323-
window.location = "https://github.com/elastic/elasticsearch-specification/tree/d57a08796e1b844c6361ae90cf50fb4956d473d6/specification/" + (paths[hash] || "");
2327+
window.location = "https://github.com/elastic/elasticsearch-specification/tree/d4e6f15987391750eafc747b997b776e70bc85a7/specification/" + (paths[hash] || "");
23242328
</script>
23252329
</head>
23262330
<body>
2327-
Please see the <a href="https://github.com/elastic/elasticsearch-specification/tree/d57a08796e1b844c6361ae90cf50fb4956d473d6/specification/">Elasticsearch API specification</a>.
2331+
Please see the <a href="https://github.com/elastic/elasticsearch-specification/tree/d4e6f15987391750eafc747b997b776e70bc85a7/specification/">Elasticsearch API specification</a>.
23282332
</body>
23292333
</html>

java-client/src/main/java/co/elastic/clients/elasticsearch/ml/ElasticsearchMlAsyncClient.java

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1198,6 +1198,42 @@ public CompletableFuture<GetJobsResponse> getJobs() {
11981198
this.transportOptions);
11991199
}
12001200

1201+
// ----- Endpoint: ml.get_model_snapshot_upgrade_stats
1202+
1203+
/**
1204+
* Gets stats for anomaly detection job model snapshot upgrades that are in
1205+
* progress.
1206+
*
1207+
* @see <a href=
1208+
* "https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-job-model-snapshot-upgrade-stats.html">Documentation
1209+
* on elastic.co</a>
1210+
*/
1211+
1212+
public CompletableFuture<GetModelSnapshotUpgradeStatsResponse> getModelSnapshotUpgradeStats(
1213+
GetModelSnapshotUpgradeStatsRequest request) {
1214+
@SuppressWarnings("unchecked")
1215+
JsonEndpoint<GetModelSnapshotUpgradeStatsRequest, GetModelSnapshotUpgradeStatsResponse, ErrorResponse> endpoint = (JsonEndpoint<GetModelSnapshotUpgradeStatsRequest, GetModelSnapshotUpgradeStatsResponse, ErrorResponse>) GetModelSnapshotUpgradeStatsRequest._ENDPOINT;
1216+
1217+
return this.transport.performRequestAsync(request, endpoint, this.transportOptions);
1218+
}
1219+
1220+
/**
1221+
* Gets stats for anomaly detection job model snapshot upgrades that are in
1222+
* progress.
1223+
*
1224+
* @param fn
1225+
* a function that initializes a builder to create the
1226+
* {@link GetModelSnapshotUpgradeStatsRequest}
1227+
* @see <a href=
1228+
* "https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-job-model-snapshot-upgrade-stats.html">Documentation
1229+
* on elastic.co</a>
1230+
*/
1231+
1232+
public final CompletableFuture<GetModelSnapshotUpgradeStatsResponse> getModelSnapshotUpgradeStats(
1233+
Function<GetModelSnapshotUpgradeStatsRequest.Builder, ObjectBuilder<GetModelSnapshotUpgradeStatsRequest>> fn) {
1234+
return getModelSnapshotUpgradeStats(fn.apply(new GetModelSnapshotUpgradeStatsRequest.Builder()).build());
1235+
}
1236+
12011237
// ----- Endpoint: ml.get_model_snapshots
12021238

12031239
/**

java-client/src/main/java/co/elastic/clients/elasticsearch/ml/ElasticsearchMlClient.java

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1236,6 +1236,43 @@ public GetJobsResponse getJobs() throws IOException, ElasticsearchException {
12361236
this.transportOptions);
12371237
}
12381238

1239+
// ----- Endpoint: ml.get_model_snapshot_upgrade_stats
1240+
1241+
/**
1242+
* Gets stats for anomaly detection job model snapshot upgrades that are in
1243+
* progress.
1244+
*
1245+
* @see <a href=
1246+
* "https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-job-model-snapshot-upgrade-stats.html">Documentation
1247+
* on elastic.co</a>
1248+
*/
1249+
1250+
public GetModelSnapshotUpgradeStatsResponse getModelSnapshotUpgradeStats(
1251+
GetModelSnapshotUpgradeStatsRequest request) throws IOException, ElasticsearchException {
1252+
@SuppressWarnings("unchecked")
1253+
JsonEndpoint<GetModelSnapshotUpgradeStatsRequest, GetModelSnapshotUpgradeStatsResponse, ErrorResponse> endpoint = (JsonEndpoint<GetModelSnapshotUpgradeStatsRequest, GetModelSnapshotUpgradeStatsResponse, ErrorResponse>) GetModelSnapshotUpgradeStatsRequest._ENDPOINT;
1254+
1255+
return this.transport.performRequest(request, endpoint, this.transportOptions);
1256+
}
1257+
1258+
/**
1259+
* Gets stats for anomaly detection job model snapshot upgrades that are in
1260+
* progress.
1261+
*
1262+
* @param fn
1263+
* a function that initializes a builder to create the
1264+
* {@link GetModelSnapshotUpgradeStatsRequest}
1265+
* @see <a href=
1266+
* "https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-job-model-snapshot-upgrade-stats.html">Documentation
1267+
* on elastic.co</a>
1268+
*/
1269+
1270+
public final GetModelSnapshotUpgradeStatsResponse getModelSnapshotUpgradeStats(
1271+
Function<GetModelSnapshotUpgradeStatsRequest.Builder, ObjectBuilder<GetModelSnapshotUpgradeStatsRequest>> fn)
1272+
throws IOException, ElasticsearchException {
1273+
return getModelSnapshotUpgradeStats(fn.apply(new GetModelSnapshotUpgradeStatsRequest.Builder()).build());
1274+
}
1275+
12391276
// ----- Endpoint: ml.get_model_snapshots
12401277

12411278
/**

0 commit comments

Comments
 (0)