update all apis and docs

This commit is contained in:
Spencer Alger
2015-03-23 12:53:31 -07:00
parent ac25a699d7
commit 16938e806f
7 changed files with 256 additions and 213 deletions

View File

@ -5,24 +5,6 @@ var api = module.exports = {};
api._namespaces = ['cat', 'cluster', 'indices', 'nodes', 'snapshot'];
/**
* Perform a [abortBenchmark](http://www.elasticsearch.org/guide/en/elasticsearch/reference/master/search-benchmark.html) request
*
* @param {Object} params - An object with parameters used to carry out this action
* @param {String} params.name - A benchmark name
*/
api.abortBenchmark = ca({
url: {
fmt: '/_bench/abort/<%=name%>',
req: {
name: {
type: 'string'
}
}
},
method: 'POST'
});
/**
* Perform a [bulk](http://www.elasticsearch.org/guide/en/elasticsearch/reference/1.3/docs-bulk.html) request
*
@ -628,6 +610,44 @@ api.cat.prototype.recovery = ca({
]
});
/**
* Perform a [cat.segments](http://www.elasticsearch.org/guide/en/elasticsearch/reference/master/cat-segments.html) request
*
* @param {Object} params - An object with parameters used to carry out this action
* @param {String, String[], Boolean} params.h - Comma-separated list of column names to display
* @param {Boolean} params.help - Return help information
* @param {Boolean} [params.v=true] - Verbose mode. Display column headers
* @param {String, String[], Boolean} params.index - A comma-separated list of index names to limit the returned information
*/
api.cat.prototype.segments = ca({
params: {
h: {
type: 'list'
},
help: {
type: 'boolean',
'default': false
},
v: {
type: 'boolean',
'default': true
}
},
urls: [
{
fmt: '/_cat/segments/<%=index%>',
req: {
index: {
type: 'list'
}
}
},
{
fmt: '/_cat/segments'
}
]
});
/**
* Perform a [cat.shards](http://www.elasticsearch.org/guide/en/elasticsearch/reference/1.3/cat-shards.html) request
*
@ -3801,40 +3821,6 @@ api.info = ca({
}
});
/**
* Perform a [listBenchmarks](http://www.elasticsearch.org/guide/en/elasticsearch/reference/master/search-benchmark.html) request
*
* @param {Object} params - An object with parameters used to carry out this action
* @param {String, String[], Boolean} params.index - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices
* @param {String} params.type - The name of the document type
*/
api.listBenchmarks = ca({
urls: [
{
fmt: '/<%=index%>/<%=type%>/_bench',
req: {
index: {
type: 'list'
},
type: {
type: 'string'
}
}
},
{
fmt: '/<%=index%>/_bench',
req: {
index: {
type: 'list'
}
}
},
{
fmt: '/_bench'
}
]
});
/**
* Perform a [mget](http://www.elasticsearch.org/guide/en/elasticsearch/reference/1.3/docs-multi-get.html) request
*