Skip to content

Commit e46f6c2

Browse files
author
Frederick Ross
committed
Merge commit 'f533dad6b42ee5a5eb07cda26604a99f44241949' into develop
Conflicts: splunklib/client.py
2 parents b76ba8a + f533dad commit e46f6c2

File tree

1 file changed

+14
-3
lines changed

1 file changed

+14
-3
lines changed

splunklib/client.py

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -301,8 +301,19 @@ def connect(**kwargs):
301301
"""
302302
return Service(**kwargs).login()
303303

304-
class Service(Context):
305-
"""This class represents a binding to a Splunk instance on an
304+
# In preparation for adding Storm support, we added an
305+
# intermediary class between Service and Context. Storm's
306+
# API is not going to be the same as enterprise Splunk's
307+
# API, so we will derive both Service (for enterprise Splunk)
308+
# and StormService for (Splunk Storm) from _BaseService, and
309+
# put any shared behavior on it.
310+
class _BaseService(Context):
311+
pass
312+
313+
class Service(_BaseService):
314+
"""A Pythonic binding to Splunk instances.
315+
316+
A :class:`Service` represents a binding to a Splunk instane on an
306317
HTTP or HTTPS port. It handles the details of authentication, wire
307318
formats, and wraps the REST API endpoints into something more
308319
Pythonic. All of the low-level operations on the instance from
@@ -348,7 +359,7 @@ class Service(Context):
348359
s = client.Service(token="atg232342aa34324a")
349360
"""
350361
def __init__(self, **kwargs):
351-
Context.__init__(self, **kwargs)
362+
super(Service, self).__init__(self, **kwargs)
352363
self._splunk_version = None
353364

354365
@property

0 commit comments

Comments
 (0)