lib/elasticsearch/api/actions/cat/plugins.rb in elasticsearch-api-6.1.0 vs lib/elasticsearch/api/actions/cat/plugins.rb in elasticsearch-api-6.2.0
- old
+ new
@@ -14,23 +14,27 @@
# @option arguments [Boolean] :v Verbose mode. Display column headers
#
# @see http://www.elastic.co/guide/en/elasticsearch/reference/master/cat-plugins.html
#
def plugins(arguments={})
- valid_params = [
- :local,
- :master_timeout,
- :h,
- :help,
- :v,
- :s ]
method = 'GET'
path = "_cat/plugins"
- params = Utils.__validate_and_extract_params arguments, valid_params
+ params = Utils.__validate_and_extract_params arguments, ParamsRegistry.get(__method__)
body = nil
perform_request(method, path, params, body).body
end
+
+ # Register this action with its valid params when the module is loaded.
+ #
+ # @since 6.2.0
+ ParamsRegistry.register(:plugins, [
+ :local,
+ :master_timeout,
+ :h,
+ :help,
+ :v,
+ :s ].freeze)
end
end
end
end