-
Notifications
You must be signed in to change notification settings - Fork 25.6k
Description
Whilst going through #29635, I've noticed that the REST API spec for node stats contains "suggest" as an index_metric value
elasticsearch/rest-api-spec/src/main/resources/rest-api-spec/api/nodes.stats.json
Line 23 in 0a16e41
| "options" : ["_all", "completion", "docs", "fielddata", "query_cache", "flush", "get", "indexing", "merge", "request_cache", "refresh", "search", "segments", "store", "warmer", "suggest"], |
and indices stats contains "suggest" for a metric value
elasticsearch/rest-api-spec/src/main/resources/rest-api-spec/api/indices.stats.json
Line 20 in 7674de9
| "options" : ["_all", "completion", "docs", "fielddata", "query_cache", "flush", "get", "indexing", "merge", "request_cache", "refresh", "search", "segments", "store", "warmer", "suggest"], |
I believe both should no longer be there. I don't think that it'll be possible to delete these in 7.x however, because @elastic/es-clients use the specs to generate code, so removing may be a backwards breaking change.
Based on
Lines 61 to 76 in 58516fa
| metrics.put("docs", r -> r.docs(true)); | |
| metrics.put("store", r -> r.store(true)); | |
| metrics.put("indexing", r -> r.indexing(true)); | |
| metrics.put("search", r -> r.search(true)); | |
| metrics.put("get", r -> r.get(true)); | |
| metrics.put("merge", r -> r.merge(true)); | |
| metrics.put("refresh", r -> r.refresh(true)); | |
| metrics.put("flush", r -> r.flush(true)); | |
| metrics.put("warmer", r -> r.warmer(true)); | |
| metrics.put("query_cache", r -> r.queryCache(true)); | |
| metrics.put("segments", r -> r.segments(true)); | |
| metrics.put("fielddata", r -> r.fieldData(true)); | |
| metrics.put("completion", r -> r.completion(true)); | |
| metrics.put("request_cache", r -> r.requestCache(true)); | |
| metrics.put("recovery", r -> r.recovery(true)); | |
| metrics.put("translog", r -> r.translog(true)); |
and
Lines 228 to 245 in 0a16e41
| public enum Flag { | |
| Store("store", 0), | |
| Indexing("indexing", 1), | |
| Get("get", 2), | |
| Search("search", 3), | |
| Merge("merge", 4), | |
| Flush("flush", 5), | |
| Refresh("refresh", 6), | |
| QueryCache("query_cache", 7), | |
| FieldData("fielddata", 8), | |
| Docs("docs", 9), | |
| Warmer("warmer", 10), | |
| Completion("completion", 11), | |
| Segments("segments", 12), | |
| Translog("translog", 13), | |
| // 14 was previously used for Suggest | |
| RequestCache("request_cache", 15), | |
| Recovery("recovery", 16); |
It also looks like the REST specs are missing "recovery" and "translog", which can be safely added to the specs.