浏览代码

[API] renaming search-template to search_template.

Name of the API should be a valid identifier.
Honza Král 11 年之前
父节点
当前提交
ed842a88da
共有 2 个文件被更改,包括 3 次插入3 次删除
  1. 1 1
      rest-api-spec/api/search.template.json
  2. 2 2
      rest-api-spec/test/search/40_search_request_template.yaml

+ 1 - 1
rest-api-spec/api/search.template.json

@@ -1,5 +1,5 @@
 {
 {
-  "search-template": {
+  "search_template": {
     "documentation": "http://www.elasticsearch.org/guide/en/elasticsearch/reference/master/search-search.html",
     "documentation": "http://www.elasticsearch.org/guide/en/elasticsearch/reference/master/search-search.html",
     "methods": ["GET", "POST"],
     "methods": ["GET", "POST"],
     "url": {
     "url": {

+ 2 - 2
rest-api-spec/test/search/40_search_request_template.yaml

@@ -17,13 +17,13 @@
       indices.refresh: {}
       indices.refresh: {}
 
 
   - do:
   - do:
-      search-template:
+      search_template:
         body: { "template" : { "query": { "term": { "text": { "value": "{{template}}" } } } }, "params": { "template": "value1" } }
         body: { "template" : { "query": { "term": { "text": { "value": "{{template}}" } } } }, "params": { "template": "value1" } }
 
 
   - match: { hits.total: 1 }
   - match: { hits.total: 1 }
 
 
   - do:
   - do:
-      search-template:
+      search_template:
         body: { "template" : { "query": { "match_{{template}}": {} } }, "params" : { "template" : "all" } }
         body: { "template" : { "query": { "match_{{template}}": {} } }, "params" : { "template" : "all" } }
 
 
   - match: { hits.total: 2 }
   - match: { hits.total: 2 }