Module: Elasticsearch::XPack::API::Graph::Actions
- Included in:
- GraphClient
- Defined in:
- lib/elasticsearch/xpack/api/namespace/graph.rb,
lib/elasticsearch/xpack/api/namespace/data_frame.rb,
lib/elasticsearch/xpack/api/actions/graph/explore.rb,
lib/elasticsearch/xpack/api/actions/graph/params_registry.rb
Defined Under Namespace
Modules: ParamsRegistry
Instance Method Summary collapse
-
#explore(arguments = {}) ⇒ Object
Explore extracted and summarized information about the documents and terms in an index.
Instance Method Details
#explore(arguments = {}) ⇒ Object
Explore extracted and summarized information about the documents and terms in an index.
*Deprecation notice*: Specifying types in urls has been deprecated Deprecated since version 7.0.0
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 |
# File 'lib/elasticsearch/xpack/api/actions/graph/explore.rb', line 39 def explore(arguments = {}) raise ArgumentError, "Required argument 'index' missing" unless arguments[:index] headers = arguments.delete(:headers) || {} arguments = arguments.clone _index = arguments.delete(:index) _type = arguments.delete(:type) method = if arguments[:body] Elasticsearch::API::HTTP_POST else Elasticsearch::API::HTTP_GET end path = if _index && _type "#{Elasticsearch::API::Utils.__listify(_index)}/#{Elasticsearch::API::Utils.__listify(_type)}/_graph/explore" else "#{Elasticsearch::API::Utils.__listify(_index)}/_graph/explore" end params = Elasticsearch::API::Utils.__validate_and_extract_params arguments, ParamsRegistry.get(__method__) body = arguments[:body] perform_request(method, path, params, body, headers).body end |