Skip to content

Commit 959202b

Browse files
authored
Add indices.disk_usage Enpoint (#700)
1 parent c2c424e commit 959202b

File tree

5 files changed

+311
-3
lines changed

5 files changed

+311
-3
lines changed

output/schema/schema.json

Lines changed: 190 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

output/schema/validation-errors.json

Lines changed: 4 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

output/typescript/types.ts

Lines changed: 16 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
/*
2+
* Licensed to Elasticsearch B.V. under one or more contributor
3+
* license agreements. See the NOTICE file distributed with
4+
* this work for additional information regarding copyright
5+
* ownership. Elasticsearch B.V. licenses this file to you under
6+
* the Apache License, Version 2.0 (the "License"); you may
7+
* not use this file except in compliance with the License.
8+
* You may obtain a copy of the License at
9+
*
10+
* http://www.apache.org/licenses/LICENSE-2.0
11+
*
12+
* Unless required by applicable law or agreed to in writing,
13+
* software distributed under the License is distributed on an
14+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15+
* KIND, either express or implied. See the License for the
16+
* specific language governing permissions and limitations
17+
* under the License.
18+
*/
19+
20+
import { RequestBase } from '@_types/Base'
21+
import { ExpandWildcards, IndexName, Indices } from '@_types/common'
22+
import { TimeUnit } from '@_types/Time'
23+
24+
/**
25+
* @rest_spec_name indices.disk_usage
26+
* @since 7.15.0
27+
* @stability experimental
28+
*/
29+
export interface Request extends RequestBase {
30+
path_parts: {
31+
/**
32+
* Comma-separated list of data streams, indices, and aliases used to limit the request. It’s recommended to execute this API with a single index (or the latest backing index of a data stream) as the API consumes resources significantly.
33+
*/
34+
index: IndexName
35+
}
36+
query_parameters?: {
37+
/**
38+
* If false, the request returns an error if any wildcard expression, index alias, or _all value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting foo*,bar* returns an error if an index starts with foo but no index starts with bar.
39+
* @server_default true
40+
*/
41+
allow_no_indices?: boolean
42+
/**
43+
* Type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports comma-separated values, such as open,hidden.
44+
* @server_default open
45+
*/
46+
expand_wildcards?: ExpandWildcards
47+
/**
48+
* If true, the API performs a flush before analysis. If false, the response may not include uncommitted data.
49+
* @server_default true
50+
*/
51+
flush?: boolean
52+
/**
53+
* If true, missing or closed indices are not included in the response.
54+
* @server_default false
55+
*/
56+
ignore_unavailable?: boolean
57+
/**
58+
* Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error.
59+
* @server_default 30s
60+
*/
61+
master_timeout?: TimeUnit
62+
/**
63+
* Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error.
64+
* @server_default 30s
65+
*/
66+
timeout?: TimeUnit
67+
/**
68+
* Analyzing field disk usage is resource-intensive. To use the API, this parameter must be set to true.
69+
* @server_default false
70+
*/
71+
run_expensive_tasks?: boolean
72+
/**
73+
* The number of shard copies that must be active before proceeding with the operation. Set to all or any positive integer up to the total number of shards in the index (number_of_replicas+1). Default: 1, the primary shard.
74+
*/
75+
wait_for_active_shards?: string
76+
}
77+
}
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
/*
2+
* Licensed to Elasticsearch B.V. under one or more contributor
3+
* license agreements. See the NOTICE file distributed with
4+
* this work for additional information regarding copyright
5+
* ownership. Elasticsearch B.V. licenses this file to you under
6+
* the Apache License, Version 2.0 (the "License"); you may
7+
* not use this file except in compliance with the License.
8+
* You may obtain a copy of the License at
9+
*
10+
* http://www.apache.org/licenses/LICENSE-2.0
11+
*
12+
* Unless required by applicable law or agreed to in writing,
13+
* software distributed under the License is distributed on an
14+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15+
* KIND, either express or implied. See the License for the
16+
* specific language governing permissions and limitations
17+
* under the License.
18+
*/
19+
20+
import { UserDefinedValue } from '@spec_utils/UserDefinedValue'
21+
22+
export class Response {
23+
body: UserDefinedValue
24+
}

0 commit comments

Comments
 (0)