Class: JayAPI::Elasticsearch::Stats
- Inherits:
-
Object
- Object
- JayAPI::Elasticsearch::Stats
- Defined in:
- lib/jay_api/elasticsearch/stats.rb,
lib/jay_api/elasticsearch/stats/node.rb,
lib/jay_api/elasticsearch/stats/index.rb,
lib/jay_api/elasticsearch/stats/nodes.rb,
lib/jay_api/elasticsearch/stats/indices.rb,
lib/jay_api/elasticsearch/stats/node/storage.rb,
lib/jay_api/elasticsearch/stats/errors/stats_data_not_available.rb
Overview
This class provides access to Elasticsearch’s Cluster Statistic API.
Defined Under Namespace
Modules: Errors Classes: Index, Indices, Node, Nodes
Instance Attribute Summary collapse
-
#logger ⇒ Object
readonly
Returns the value of attribute logger.
-
#transport_client ⇒ Object
readonly
Returns the value of attribute transport_client.
Instance Method Summary collapse
-
#indices ⇒ JayAPI::Elasticsearch::Stats::Indices
Information about the indices that exist in the Elasticsearch cluster.
-
#initialize(transport_client) ⇒ Stats
constructor
A new instance of Stats.
-
#nodes ⇒ JayAPI::Elasticsearch::Stats::Nodes
Information about the nodes that make up the Elasticsearch cluster.
Constructor Details
#initialize(transport_client) ⇒ Stats
Returns a new instance of Stats.
16 17 18 |
# File 'lib/jay_api/elasticsearch/stats.rb', line 16 def initialize(transport_client) @transport_client = transport_client end |
Instance Attribute Details
#logger ⇒ Object (readonly)
Returns the value of attribute logger.
12 13 14 |
# File 'lib/jay_api/elasticsearch/stats.rb', line 12 def logger @logger end |
#transport_client ⇒ Object (readonly)
Returns the value of attribute transport_client.
12 13 14 |
# File 'lib/jay_api/elasticsearch/stats.rb', line 12 def transport_client @transport_client end |
Instance Method Details
#indices ⇒ JayAPI::Elasticsearch::Stats::Indices
Returns Information about the indices that exist in the Elasticsearch cluster.
24 25 26 27 |
# File 'lib/jay_api/elasticsearch/stats.rb', line 24 def indices # DO NOT MEMOIZE! Leave it to the caller. ::JayAPI::Elasticsearch::Stats::Indices.new(indices_stats['indices']) end |
#nodes ⇒ JayAPI::Elasticsearch::Stats::Nodes
Returns Information about the nodes that make up the Elasticsearch cluster.
33 34 35 36 |
# File 'lib/jay_api/elasticsearch/stats.rb', line 33 def nodes # DO NOT MEMOIZE! Leave it to the caller. ::JayAPI::Elasticsearch::Stats::Nodes.new(nodes_stats['nodes']) end |