eson-core 0.7.0 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/Rakefile +2 -2
- data/eson-core.gemspec +2 -1
- data/lib/eson-core.rb +5 -0
- data/lib/eson/api.rb +61 -12
- data/lib/eson/chainable.rb +3 -3
- data/lib/eson/client.rb +699 -180
- data/lib/eson/error.rb +10 -2
- data/lib/eson/request.rb +57 -16
- data/lib/eson/shared/cluster/health.rb +9 -2
- data/lib/eson/shared/cluster/nodes.rb +9 -1
- data/lib/eson/shared/cluster/shutdown.rb +9 -1
- data/lib/eson/shared/cluster/state.rb +9 -1
- data/lib/eson/shared/cluster/stats.rb +9 -1
- data/lib/eson/shared/core/bulk.rb +9 -1
- data/lib/eson/shared/core/count.rb +10 -1
- data/lib/eson/shared/core/delete.rb +10 -1
- data/lib/eson/shared/core/delete_by_query.rb +10 -1
- data/lib/eson/shared/core/explain.rb +44 -0
- data/lib/eson/shared/core/get.rb +9 -1
- data/lib/eson/shared/core/index.rb +13 -2
- data/lib/eson/shared/core/mget.rb +12 -3
- data/lib/eson/shared/core/more_like_this.rb +10 -1
- data/lib/eson/shared/core/msearch.rb +10 -1
- data/lib/eson/shared/core/percolate.rb +10 -1
- data/lib/eson/shared/core/scroll.rb +17 -0
- data/lib/eson/shared/core/search.rb +15 -3
- data/lib/eson/shared/core/simple_search.rb +9 -1
- data/lib/eson/shared/core/update.rb +33 -0
- data/lib/eson/shared/core/validate.rb +50 -0
- data/lib/eson/shared/indices/aliases.rb +37 -9
- data/lib/eson/shared/indices/analyze.rb +9 -2
- data/lib/eson/shared/indices/clear_cache.rb +9 -1
- data/lib/eson/shared/indices/close_index.rb +8 -1
- data/lib/eson/shared/indices/create_index.rb +10 -1
- data/lib/eson/shared/indices/delete_index.rb +8 -1
- data/lib/eson/shared/indices/delete_mapping.rb +9 -1
- data/lib/eson/shared/indices/delete_template.rb +8 -1
- data/lib/eson/shared/indices/exists.rb +8 -1
- data/lib/eson/shared/indices/flush.rb +9 -1
- data/lib/eson/shared/indices/get_aliases.rb +16 -0
- data/lib/eson/shared/indices/get_mapping.rb +9 -1
- data/lib/eson/shared/indices/get_settings.rb +8 -1
- data/lib/eson/shared/indices/get_template.rb +8 -1
- data/lib/eson/shared/indices/open_index.rb +8 -1
- data/lib/eson/shared/indices/optimize.rb +9 -1
- data/lib/eson/shared/indices/put_mapping.rb +10 -1
- data/lib/eson/shared/indices/put_template.rb +9 -1
- data/lib/eson/shared/indices/refresh.rb +9 -1
- data/lib/eson/shared/indices/segments.rb +8 -1
- data/lib/eson/shared/indices/snapshot.rb +8 -1
- data/lib/eson/shared/indices/stats.rb +9 -1
- data/lib/eson/shared/indices/status.rb +8 -1
- data/lib/eson/shared/indices/update_settings.rb +10 -1
- metadata +7 -8
@@ -1,9 +1,16 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:CloseIndex#parameters}
|
6
|
+
# {include:CloseIndex#source_param}
|
7
|
+
# {include:CloseIndex#multi_index}
|
8
|
+
# {include:CloseIndex#multi_types}
|
3
9
|
module CloseIndex
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro multi_index
|
6
13
|
multi_index true
|
7
14
|
end
|
8
15
|
end
|
9
|
-
end
|
16
|
+
end
|
@@ -1,13 +1,22 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:CreateIndex#parameters}
|
6
|
+
# {include:CreateIndex#source_param}
|
7
|
+
# {include:CreateIndex#multi_index}
|
8
|
+
# {include:CreateIndex#multi_types}
|
3
9
|
module CreateIndex
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro no_multi_index
|
6
13
|
multi_index false
|
7
14
|
|
15
|
+
# @!macro parameters
|
8
16
|
parameters :settings, :mappings
|
9
17
|
|
18
|
+
# @!macro source_param
|
10
19
|
source_param :settings, :mappings
|
11
20
|
end
|
12
21
|
end
|
13
|
-
end
|
22
|
+
end
|
@@ -1,9 +1,16 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:DeleteIndex#parameters}
|
6
|
+
# {include:DeleteIndex#source_param}
|
7
|
+
# {include:DeleteIndex#multi_index}
|
8
|
+
# {include:DeleteIndex#multi_types}
|
3
9
|
module DeleteIndex
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro multi_index
|
6
13
|
multi_index true
|
7
14
|
end
|
8
15
|
end
|
9
|
-
end
|
16
|
+
end
|
@@ -1,11 +1,19 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:DeleteMapping#parameters}
|
6
|
+
# {include:DeleteMapping#source_param}
|
7
|
+
# {include:DeleteMapping#multi_index}
|
8
|
+
# {include:DeleteMapping#multi_types}
|
3
9
|
module DeleteMapping
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro parameters
|
6
13
|
parameters :type
|
7
14
|
|
15
|
+
# @!macro multi_index
|
8
16
|
multi_index true
|
9
17
|
end
|
10
18
|
end
|
11
|
-
end
|
19
|
+
end
|
@@ -1,9 +1,16 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:DeleteTemplate#parameters}
|
6
|
+
# {include:DeleteTemplate#source_param}
|
7
|
+
# {include:DeleteTemplate#multi_index}
|
8
|
+
# {include:DeleteTemplate#multi_types}
|
3
9
|
module DeleteTemplate
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro parameters
|
6
13
|
parameters :name
|
7
14
|
end
|
8
15
|
end
|
9
|
-
end
|
16
|
+
end
|
@@ -1,9 +1,16 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:IndexExists#parameters}
|
6
|
+
# {include:IndexExists#source_param}
|
7
|
+
# {include:IndexExists#multi_index}
|
8
|
+
# {include:IndexExists#multi_types}
|
3
9
|
module IndexExists
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro multi_index
|
6
13
|
multi_index true
|
7
14
|
end
|
8
15
|
end
|
9
|
-
end
|
16
|
+
end
|
@@ -1,11 +1,19 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:Flush#parameters}
|
6
|
+
# {include:Flush#source_param}
|
7
|
+
# {include:Flush#multi_index}
|
8
|
+
# {include:Flush#multi_types}
|
3
9
|
module Flush
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro parameters
|
6
13
|
parameters :refresh
|
7
14
|
|
15
|
+
# @!macro multi_index
|
8
16
|
multi_index true
|
9
17
|
end
|
10
18
|
end
|
11
|
-
end
|
19
|
+
end
|
@@ -0,0 +1,16 @@
|
|
1
|
+
module Eson
|
2
|
+
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:GetAliases#parameters}
|
6
|
+
# {include:GetAliases#source_param}
|
7
|
+
# {include:GetAliases#multi_index}
|
8
|
+
# {include:GetAliases#multi_types}
|
9
|
+
module GetAliases
|
10
|
+
extend API
|
11
|
+
|
12
|
+
# @!macro multi_index
|
13
|
+
multi_index true
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
@@ -1,11 +1,19 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:GetMapping#parameters}
|
6
|
+
# {include:GetMapping#source_param}
|
7
|
+
# {include:GetMapping#multi_index}
|
8
|
+
# {include:GetMapping#multi_types}
|
3
9
|
module GetMapping
|
4
10
|
extend API
|
5
11
|
|
6
12
|
attr_accessor :type
|
13
|
+
# @!macro parameters
|
7
14
|
parameters :types
|
8
15
|
|
16
|
+
# @!macro multi_index
|
9
17
|
multi_index true
|
10
18
|
|
11
19
|
def types
|
@@ -13,4 +21,4 @@ module Eson
|
|
13
21
|
end
|
14
22
|
end
|
15
23
|
end
|
16
|
-
end
|
24
|
+
end
|
@@ -1,9 +1,16 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:GetSettings#parameters}
|
6
|
+
# {include:GetSettings#source_param}
|
7
|
+
# {include:GetSettings#multi_index}
|
8
|
+
# {include:GetSettings#multi_types}
|
3
9
|
module GetSettings
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro multi_index
|
6
13
|
multi_index true
|
7
14
|
end
|
8
15
|
end
|
9
|
-
end
|
16
|
+
end
|
@@ -1,9 +1,16 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:GetTemplate#parameters}
|
6
|
+
# {include:GetTemplate#source_param}
|
7
|
+
# {include:GetTemplate#multi_index}
|
8
|
+
# {include:GetTemplate#multi_types}
|
3
9
|
module GetTemplate
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro parameters
|
6
13
|
parameters :name
|
7
14
|
end
|
8
15
|
end
|
9
|
-
end
|
16
|
+
end
|
@@ -1,9 +1,16 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:OpenIndex#parameters}
|
6
|
+
# {include:OpenIndex#source_param}
|
7
|
+
# {include:OpenIndex#multi_index}
|
8
|
+
# {include:OpenIndex#multi_types}
|
3
9
|
module OpenIndex
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro multi_index
|
6
13
|
multi_index true
|
7
14
|
end
|
8
15
|
end
|
9
|
-
end
|
16
|
+
end
|
@@ -1,10 +1,18 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# @note {include:Optimize#parameters}
|
6
|
+
# @note {include:Optimize#source_param}
|
7
|
+
# @note {include:Optimize#multi_index}
|
8
|
+
# @note {include:Optimize#multi_types}
|
3
9
|
module Optimize
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro multi_index
|
6
13
|
multi_index true
|
7
14
|
|
15
|
+
# @!macro parameters
|
8
16
|
parameters :max_num_segments,
|
9
17
|
:only_expunge_deletes,
|
10
18
|
:refresh,
|
@@ -12,4 +20,4 @@ module Eson
|
|
12
20
|
:wait_for_merge
|
13
21
|
end
|
14
22
|
end
|
15
|
-
end
|
23
|
+
end
|
@@ -1,15 +1,24 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:PutMapping#parameters}
|
6
|
+
# {include:PutMapping#source_param}
|
7
|
+
# {include:PutMapping#multi_index}
|
8
|
+
# {include:PutMapping#multi_types}
|
3
9
|
module PutMapping
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro multi_index
|
6
13
|
multi_index true
|
7
14
|
|
15
|
+
# @!macro parameters
|
8
16
|
parameters :type,
|
9
17
|
:ignore_conflicts,
|
10
18
|
:mapping
|
11
19
|
|
20
|
+
# @!macro source_param
|
12
21
|
source_param :mapping
|
13
22
|
end
|
14
23
|
end
|
15
|
-
end
|
24
|
+
end
|
@@ -1,10 +1,18 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# @note {include:PutTemplate#parameters}
|
6
|
+
# @note {include:PutTemplate#source_param}
|
7
|
+
# @note {include:PutTemplate#multi_index}
|
8
|
+
# @note {include:PutTemplate#multi_types}
|
3
9
|
module PutTemplate
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro parameters
|
6
13
|
parameters :template, :settings, :mappings, :name
|
14
|
+
# @!macro source_param
|
7
15
|
source_param :template, :settings, :mappings
|
8
16
|
end
|
9
17
|
end
|
10
|
-
end
|
18
|
+
end
|
@@ -1,10 +1,18 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# @note {include:Refresh#parameters}
|
6
|
+
# @note {include:Refresh#source_param}
|
7
|
+
# @note {include:Refresh#multi_index}
|
8
|
+
# @note {include:Refresh#multi_types}
|
3
9
|
module Refresh
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro multi_index
|
6
13
|
multi_index true
|
7
14
|
|
15
|
+
# @!macro parameters
|
8
16
|
parameters :max_num_segments,
|
9
17
|
:only_expunge_deletes,
|
10
18
|
:refresh,
|
@@ -13,4 +21,4 @@ module Eson
|
|
13
21
|
|
14
22
|
end
|
15
23
|
end
|
16
|
-
end
|
24
|
+
end
|
@@ -1,8 +1,15 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:Segments#parameters}
|
6
|
+
# {include:Segments#source_param}
|
7
|
+
# {include:Segments#multi_index}
|
8
|
+
# {include:Segments#multi_types}
|
3
9
|
module Segments
|
4
10
|
extend API
|
11
|
+
# @!macro multi_index
|
5
12
|
multi_index true
|
6
13
|
end
|
7
14
|
end
|
8
|
-
end
|
15
|
+
end
|
@@ -1,9 +1,16 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:Snapshot#parameters}
|
6
|
+
# {include:Snapshot#source_param}
|
7
|
+
# {include:Snapshot#multi_index}
|
8
|
+
# {include:Snapshot#multi_types}
|
3
9
|
module Snapshot
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro multi_index
|
6
13
|
multi_index true
|
7
14
|
end
|
8
15
|
end
|
9
|
-
end
|
16
|
+
end
|
@@ -1,9 +1,17 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:IndexStats#parameters}
|
6
|
+
# {include:IndexStats#source_param}
|
7
|
+
# {include:IndexStats#multi_index}
|
8
|
+
# {include:IndexStats#multi_types}
|
3
9
|
module IndexStats
|
4
10
|
extend API
|
11
|
+
# @!macro multi_index
|
5
12
|
multi_index true
|
6
13
|
|
14
|
+
# @!macro parameters
|
7
15
|
parameters :docs,
|
8
16
|
:store,
|
9
17
|
:indexing,
|
@@ -16,4 +24,4 @@ module Eson
|
|
16
24
|
:types
|
17
25
|
end
|
18
26
|
end
|
19
|
-
end
|
27
|
+
end
|
@@ -1,9 +1,16 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# @note {include:Status#parameters}
|
6
|
+
# @note {include:Status#source_param}
|
7
|
+
# @note {include:Status#multi_index}
|
8
|
+
# @note {include:Status#multi_types}
|
3
9
|
module Status
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro multi_index
|
6
13
|
multi_index true
|
7
14
|
end
|
8
15
|
end
|
9
|
-
end
|
16
|
+
end
|
@@ -1,12 +1,21 @@
|
|
1
1
|
module Eson
|
2
2
|
module Shared
|
3
|
+
# Requests using this API have the following properties:
|
4
|
+
#
|
5
|
+
# {include:UpdateSettings#parameters}
|
6
|
+
# {include:UpdateSettings#source_param}
|
7
|
+
# {include:UpdateSettings#multi_index}
|
8
|
+
# {include:UpdateSettings#multi_types}
|
3
9
|
module UpdateSettings
|
4
10
|
extend API
|
5
11
|
|
12
|
+
# @!macro parameters
|
6
13
|
parameters :settings
|
14
|
+
# @!macro source_param
|
7
15
|
source_param :settings
|
8
16
|
|
17
|
+
# @!macro multi_index
|
9
18
|
multi_index true
|
10
19
|
end
|
11
20
|
end
|
12
|
-
end
|
21
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: eson-core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2013-01-22 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: multi_json
|
@@ -71,14 +71,18 @@ files:
|
|
71
71
|
- lib/eson/shared/core/count.rb
|
72
72
|
- lib/eson/shared/core/delete.rb
|
73
73
|
- lib/eson/shared/core/delete_by_query.rb
|
74
|
+
- lib/eson/shared/core/explain.rb
|
74
75
|
- lib/eson/shared/core/get.rb
|
75
76
|
- lib/eson/shared/core/index.rb
|
76
77
|
- lib/eson/shared/core/mget.rb
|
77
78
|
- lib/eson/shared/core/more_like_this.rb
|
78
79
|
- lib/eson/shared/core/msearch.rb
|
79
80
|
- lib/eson/shared/core/percolate.rb
|
81
|
+
- lib/eson/shared/core/scroll.rb
|
80
82
|
- lib/eson/shared/core/search.rb
|
81
83
|
- lib/eson/shared/core/simple_search.rb
|
84
|
+
- lib/eson/shared/core/update.rb
|
85
|
+
- lib/eson/shared/core/validate.rb
|
82
86
|
- lib/eson/shared/indices/aliases.rb
|
83
87
|
- lib/eson/shared/indices/analyze.rb
|
84
88
|
- lib/eson/shared/indices/clear_cache.rb
|
@@ -89,6 +93,7 @@ files:
|
|
89
93
|
- lib/eson/shared/indices/delete_template.rb
|
90
94
|
- lib/eson/shared/indices/exists.rb
|
91
95
|
- lib/eson/shared/indices/flush.rb
|
96
|
+
- lib/eson/shared/indices/get_aliases.rb
|
92
97
|
- lib/eson/shared/indices/get_mapping.rb
|
93
98
|
- lib/eson/shared/indices/get_settings.rb
|
94
99
|
- lib/eson/shared/indices/get_template.rb
|
@@ -114,18 +119,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
114
119
|
- - ! '>='
|
115
120
|
- !ruby/object:Gem::Version
|
116
121
|
version: '0'
|
117
|
-
segments:
|
118
|
-
- 0
|
119
|
-
hash: -2900552333141040798
|
120
122
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
121
123
|
none: false
|
122
124
|
requirements:
|
123
125
|
- - ! '>='
|
124
126
|
- !ruby/object:Gem::Version
|
125
127
|
version: '0'
|
126
|
-
segments:
|
127
|
-
- 0
|
128
|
-
hash: -2900552333141040798
|
129
128
|
requirements: []
|
130
129
|
rubyforge_project:
|
131
130
|
rubygems_version: 1.8.21
|