536 Commits

Author SHA1 Message Date
Honza Král
13e6f1933b [SPEC] removing deprecated include/exclude for get_source
_source_include/_source_exclude should be used instead
2014-01-17 15:38:25 +01:00
Luca Cavanna
1fba68a634 [SPEC] Added missing body object in snapshot apis 2014-01-17 15:34:42 +01:00
Clinton Gormley
53359c0d3d [SPEC] Created snapshot.* and nodes.* namespaces
Moved node_info, node_stats, shutdown and hot_threads into nodes.*
Moved snapshot and repository APIs into snapshot.*
2014-01-17 11:58:44 +01:00
Clinton Gormley
612044b386 [SPEC] Added missing cat endpoints. count and recovery
And added missing qs params to health and indices.
2014-01-16 22:09:48 +01:00
Luca Cavanna
06057c6c39 [TEST] Added check: test section names must be unique in the same REST test suite
Fixed also three duplicates found
2014-01-16 21:09:55 +01:00
Clinton Gormley
258c49ea23 [SPEC] Fixed bad name in ping.json 2014-01-16 19:54:25 +01:00
Clinton Gormley
1ca11b11e4 [SPEC] Fixed cluster.get_repository spec
Badly named endpoint
2014-01-16 19:43:58 +01:00
Clinton Gormley
fa6e8abf48 [SPEC] Fixed cat.* spec files - were missing the endpoints 2014-01-16 19:43:58 +01:00
Clinton Gormley
c5942a4ff8 [TEST] Fixed mget test which used deprecated refresh flag 2014-01-16 19:43:58 +01:00
Clinton Gormley
64f0361f5e [SPEC] Fixed file name, missing .json 2014-01-16 17:12:39 +01:00
Clinton Gormley
e9b14ff636 [SPEC] Separated info.json into info and ping.json (GET vs HEAD) 2014-01-16 17:07:47 +01:00
Clinton Gormley
04b6dd9d0c [SPEC] Moved the cat API into its own namespace and added missing qs params 2014-01-16 17:06:03 +01:00
Clinton Gormley
84e2e1c177 [SPEC] Renamed snapshot/restore apis 2014-01-16 16:32:39 +01:00
Clinton Gormley
23a1fd795b [SPEC] Fixed bad JSON in indices.open 2014-01-16 15:33:09 +01:00
Clinton Gormley
b7d4b30ad7 [SPEC] Added indices.exists_template.json 2014-01-16 15:29:50 +01:00
Clinton Gormley
5856378866 [SPEC] Added local to indices.get_mapping and indices.get_field_mapping 2014-01-16 15:29:50 +01:00
Clinton Gormley
555dbfd4b3 [SPEC] Added force to indices.refresh 2014-01-16 15:29:50 +01:00
Clinton Gormley
ec3b19a866 [SPEC] Removed refresh from indices.flush and indices.optimize 2014-01-16 15:29:50 +01:00
Clinton Gormley
c3813ceb71 [SPEC] Added empty path to indices.open and indices.close 2014-01-16 15:29:50 +01:00
Clinton Gormley
d24994e4b4 [SPEC] Removed percolate from update 2014-01-16 15:29:50 +01:00
Clinton Gormley
056609b46c [SPEC] Added timeout, master_timeout to cluster.get_settings and cluster.reroute 2014-01-16 15:29:50 +01:00
Clinton Gormley
e86bfdae46 [SPEC] Removed percolate from index.json 2014-01-16 15:29:49 +01:00
Clinton Gormley
93cd53b8cf [SPEC] Added _source, _source_include, _source_exclude to get_source 2014-01-16 15:29:49 +01:00
Clinton Gormley
8d3eba3035 [SPEC] Added version, version_type to get and get_source 2014-01-16 15:29:49 +01:00
Clinton Gormley
c66c9ff379 [SPEC] Added cluster.pending_tasks.json 2014-01-16 15:29:49 +01:00
Clinton Gormley
3bbab4c106 [SPEC] Added cluster.stats.json 2014-01-16 15:29:49 +01:00
Clinton Gormley
00ed78f3d6 [SPEC] Added cluster.repositories.* and cluster.snapshots.* 2014-01-16 15:29:49 +01:00
Clinton Gormley
500d6f7098 [SPEC] Added cat.json 2014-01-16 15:29:49 +01:00
Clinton Gormley
e613ecf9b4 [SPEC] Added the routing and timeout params to bulk 2014-01-16 15:29:49 +01:00
Clinton Gormley
c4713b1022 [SPEC] Added human flag to:
* cluster.node_info
* cluster.node_stats
* indices.segments
* indices.stats
* indices.status
2014-01-16 12:42:02 +01:00
Alexander Reelsen
4d68d722a1 Added waiting for yellow cluster state in rest test
In order to prevent rare timing issue, where the creation
of an index happens in the cluster state too late and thus
results in empty mappings.
2014-01-15 17:03:30 +01:00
Britta Weber
2f115b8103 update rest spec to be consistent with recent changes
see issue #4071
2014-01-15 00:56:52 +01:00
Alexander Reelsen
a3abcdc93a Consistent APIs: Get field mapping API includes 'mappings'
The get field mapping API now includes a mappings element after the index in its JSON

Added more consistent endpoint /{index}/_mapping/{type}/field/{fields}
and added endpoint /_mapping/{type}/field/{fields}
which are also used in tests

Added rest spec tests for wildcards and _all

Relates #4071

NOTE: This is not yet complete for 1.0. We need to return an empty JSON document instead
of a 404 if the field of an existing index and type is not found. However this is not
possible with the current data structure being returned. Needs to be finished for 1.0.
2014-01-14 22:42:27 +01:00
Alexander Reelsen
349a8be4fd Consistent REST API changes for GETting data
* Made GET mappings consistent, supporting
  * /{index}/_mappings/{type}
  * /{index}/_mapping/{type}
  * /_mapping/{type}
  * Added "mappings" in the JSON response to align it with other responses
* Made GET warmers consistent, support /{index}/_warmers/{type} and /_warmer, /_warner/{name}
  as well as wildcards and _all notation
* Made GET aliases consistent, support /{index}/_aliases/{name} and /_alias, /_aliases/{name}
  as well as wildcards and _all notation
* Made GET settings consistent, added /{index}/_setting/{name}, /_settings/{name}
  as well as supportings wildcards in settings name
* Returning empty JSON instead of a 404, if a specific warmer/
  setting/alias/type is missing
* Added a ton of spec tests for all of the above
* Added a couple of more integration tests for several features

Relates #4071
2014-01-14 22:33:52 +01:00
Britta Weber
411739fe3b Make PUT and DELETE consistent for _mapping, _alias and _warmer
See issue #4071

PUT options for _mapping:

Single type can now be added with

`[PUT|POST] {index|_all|*|regex|blank}/[_mapping|_mappings]/type`

and

`[PUT|POST] {index|_all|*|regex|blank}/type/[_mapping|_mappings]`

PUT options for _warmer:

PUT with a single warmer can now be done with

`[PUT|POST] {index|_all|*|prefix*|blank}/{type|_all|*|prefix*|blank}/[_warmer|_warmers]/warmer_name`

PUT options for _alias:

Single alias can now be PUT with

`[PUT|POST] {index|_all|*|prefix*|blank}/[_alias|_aliases]/alias`

DELETE options _mapping:

Several mappings can be deleted at once by defining several indices and types with

`[DELETE] /{index}/{type}`

`[DELETE] /{index}/{type}/_mapping`

`[DELETE] /{index}/_mapping/{type}`

where

`index= * | _all | glob pattern | name1, name2, …`

`type= * | _all | glob pattern | name1, name2, …`

Alternatively, the keyword `_mapings` can be used.

DELETE options for  _warmer:

Several warmers can be deleted at once by defining several indices and names with

`[DELETE] /{index}/_warmer/{type}`

where

`index= * | _all | glob pattern | name1, name2, …`

`type= * | _all | glob pattern | name1, name2, …`

Alternatively, the keyword `_warmers` can be used.

DELETE options for _alias:

Several aliases can be deleted at once by defining several indices and names with

`[DELETE] /{index}/_alias/{type}`

where

`index= * | _all | glob pattern | name1, name2, …`

`type= * | _all | glob pattern | name1, name2, …`

Alternatively, the keyword `_aliases` can be used.
2014-01-14 20:02:43 +01:00
Clinton Gormley
2c647b3a82 Revert "[SPEC] Added level param to cluster.state"
This reverts commit 06e5f3dd6ff3db5c30b67e1d4eb80ff759533f93.
2014-01-13 18:07:12 +01:00
Clinton Gormley
06e5f3dd6f [SPEC] Added level param to cluster.state 2014-01-13 18:05:38 +01:00
Clinton Gormley
7779196c8a [SPEC] Updated cluster.state spec 2014-01-13 18:02:15 +01:00
Clinton Gormley
b7cddea495 [SPEC] Added level param to cluster.node_stats and indices.stats 2014-01-13 17:40:27 +01:00
Simon Willnauer
f2f4b72a12 Add missing closing '}' to indices.stats.json 2014-01-13 17:19:13 +01:00
Clinton Gormley
b866c381d5 [TEST] Updated cluster.node_stats test 2014-01-13 17:06:29 +01:00
markharwood
2795f4e55d Standardized use of “*_length” for parameter names rather than “*_len”.
Java Builder apis drop old “len” methods in favour of new “length”
Rest APIs support both old “len: and new “length” forms using new ParseField class to a) provide compiler-checked consistency between Builder and Parser classes and
b) a common means of handling deprecated syntax in the DSL.
Documentation and rest specs only document the new “*length” forms
Closes #4083
2014-01-13 15:59:15 +00:00
Clinton Gormley
ed254b56e0 [SPEC] Updated cluster.node_stats and indices.stats 2014-01-13 16:54:51 +01:00
Clinton Gormley
0916372520 Fix YAML in test/indices.open/20_multiple_indices.yaml 2014-01-13 13:17:30 +01:00
Martijn van Groningen
943b62634c Replaced the multi-field type in favour for the multi fields option that can be set on any core field.
When upgrading to ES 1.0 the existing mappings with a multi-field type automatically get replaced to a core field with the new `fields` option.

If a `multi_field` type-ed field doesn't have a main / default field, a default field will be chosen for the multi fields syntax. The new main field type
will be equal to the first `multi_field` fields' field or type string if no fields have been configured for the `multi_field` field and in both cases
the default index will not be indexed (`index=no` is set on the default field).

If a `multi_field` typed field has a default field, that field will replace the `multi_field` typed field.

Closes to #4521
2014-01-13 09:21:53 +01:00
Spencer Alger
71d77d17e1 Updated the documentation urls in the rest api spec. 2014-01-09 14:44:14 -07:00
Martijn van Groningen
eb63bb259d Added action.destructive_requires_name that controls whether wildcard expressions and _all is allowed to be used for destructive operat Also the delete index api requires always an index to be specified (either concrete index, alias or wildcard expression)
Closes #4549 #4481
2014-01-09 11:36:50 +01:00
Britta Weber
216c814a7f remove default _all for type and index if these are missing in REST tests
If a type or path is missing in the REST test yaml file, it is
automatically replaced with _all. This makes it hard to test changes
in the api, for example adding the possibility to leave the index
blank in addition to _all and * in the uri.

closes #4657
2014-01-09 10:17:42 +01:00
Martijn van Groningen
0973b2863c Added extra rest endpoint for get settings api.
Added rest test to also test the get settings' prefix option.
2014-01-09 09:44:40 +01:00
Luca Cavanna
cb3b653a55 [SPEC] added nmissing comma in cluster.node_stats api spec 2014-01-08 21:24:23 +01:00