Skip to content

Commit 3933b24

Browse files
committed
[API] Add remote/info back
1 parent ca0d712 commit 3933b24

File tree

2 files changed

+39
-0
lines changed
  • elasticsearch-api

2 files changed

+39
-0
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
module Elasticsearch
2+
module API
3+
module Remote
4+
module Actions
5+
6+
# Returns all of the configured remote cluster information
7+
#
8+
# @see http://www.elastic.co/guide/en/elasticsearch/reference/master/remote-info.html
9+
#
10+
def info(arguments={})
11+
method = HTTP_GET
12+
path = "_remote/info"
13+
params = {}
14+
body = nil
15+
16+
perform_request(method, path, params, body).body
17+
end
18+
end
19+
end
20+
end
21+
end
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
require 'spec_helper'
2+
3+
describe 'client.remote#info' do
4+
5+
let(:expected_args) do
6+
[
7+
'GET',
8+
'_remote/info',
9+
{},
10+
nil,
11+
nil
12+
]
13+
end
14+
15+
it 'performs the request' do
16+
expect(client_double.remote.info).to eq({})
17+
end
18+
end

0 commit comments

Comments
 (0)