Skip to content

Commit

Permalink
Added get_settings method to ES class.
Browse files Browse the repository at this point in the history
  • Loading branch information
Alberto Paro committed Feb 15, 2012
1 parent e6a78c1 commit 57a9b5b
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion pyes/es.py
Original file line number Diff line number Diff line change
Expand Up @@ -1365,6 +1365,14 @@ def delete_river(self, river, river_name=None):
return self._send_request('DELETE', '/_river/%s/' % river_name)

#--- settings management

def get_settings(self, index=None):
"""
Returns the current settings for an index.
"""
path = self._make_path([index, "_settings"])
return self._send_request('GET', path)

def update_settings(self, index, newvalues):
"""
Update Settings of an index.
Expand Down Expand Up @@ -1668,7 +1676,7 @@ def next(self):
def __iter__(self):
self.iterpos = 0
if self._current_item != 0:
self._results = None
self._results = None
self._current_item = 0

self.start = 0
Expand Down

0 comments on commit 57a9b5b

Please sign in to comment.