FAQ
This may be kind of a stupid question, so please be gentle.
I've only ever used most programming in the past when shell scripting
couldn't handle what I needed done. So, I rarely dabble with things
like API's, or even python-isms. I just program to get things done.

Well, that's about to change :)
I am in charge of deploying a platform to allow people across my
company to access a variety of crunched metrics using splunk. I need
to allow access into the data using Splunk's RESTful API, which is
implemented in both java and python. The thing is, I have no idea how
to do that. I've looked through some of the documentation, and it has
me start a pydoc server on the system but when i navigate to the page
it just shows listings of functions. The descriptions would be great,
except they don't really tell me a lot. For instance, nothing really
seems to say "fetchRecord(user_name) fetches all records matching a
particular user name". Further, how do I actually use the API?

I appreciate any of the pointers you can offer. Its a big part of this
project, but my minor knowledge in programming isn't helping me much
here.
-Matty

Search Discussions

  • Andrea crotti at Feb 17, 2011 at 3:17 pm
    2011/2/17 Matty Sarro <msarro at gmail.com>
    This may be kind of a stupid question, so please be gentle.
    I've only ever used most programming in the past when shell scripting
    couldn't handle what I needed done. So, I rarely dabble with things
    like API's, or even python-isms. I just program to get things done.

    Well, that's about to change :)
    I am in charge of deploying a platform to allow people across my
    company to access a variety of crunched metrics using splunk. I need
    to allow access into the data using Splunk's RESTful API, which is
    implemented in both java and python. The thing is, I have no idea how
    to do that. I've looked through some of the documentation, and it has
    me start a pydoc server on the system but when i navigate to the page
    it just shows listings of functions. The descriptions would be great,
    except they don't really tell me a lot. For instance, nothing really
    seems to say "fetchRecord(user_name) fetches all records matching a
    particular user name". Further, how do I actually use the API?

    I appreciate any of the pointers you can offer. Its a big part of this
    project, but my minor knowledge in programming isn't helping me much
    here.
    -Matty
    --
    http://mail.python.org/mailman/listinfo/python-list

    Well things are not always (almost never) documented as you would like.
    A suggestion I can give is to use ipython and play with the modules.
    Pass something in and see what you get.

    And better yet write some unit tests to see if the functions do what you
    expect they do.
    If the API is not completely dumb you should understand quickly how to use
    it.

    Also some other code that uses that library might be useful.
    -------------- next part --------------
    An HTML attachment was scrubbed...
    URL: <http://mail.python.org/pipermail/python-list/attachments/20110217/463a1446/attachment.html>
  • Terry Reedy at Feb 17, 2011 at 5:53 pm

    On 2/17/2011 10:17 AM, andrea crotti wrote:

    2011/2/17 Matty Sarro <msarro at gmail.com <mailto:msarro at gmail.com>>

    This may be kind of a stupid question, so please be gentle.
    I've only ever used most programming in the past when shell scripting
    couldn't handle what I needed done. So, I rarely dabble with things
    like API's, or even python-isms. I just program to get things done.

    Well, that's about to change :)
    I am in charge of deploying a platform to allow people across my
    company to access a variety of crunched metrics using splunk. I need
    to allow access into the data using Splunk's RESTful API, which is
    implemented in both java and python. The thing is, I have no idea how
    to do that. I've looked through some of the documentation, and it has
    me start a pydoc server on the system but when i navigate to the page
    it just shows listings of functions. The descriptions would be great,
    except they don't really tell me a lot. For instance, nothing really
    seems to say "fetchRecord(user_name) fetches all records matching a
    particular user name". Further, how do I actually use the API?

    I appreciate any of the pointers you can offer. Its a big part of this
    project, but my minor knowledge in programming isn't helping me much
    here.
    -Matty
    --
    http://mail.python.org/mailman/listinfo/python-list

    Well things are not always (almost never) documented as you would like.
    A suggestion I can give is to use ipython and play with the modules.
    Pass something in and see what you get.

    And better yet write some unit tests to see if the functions do what you
    expect they do.
    If the API is not completely dumb you should understand quickly how to
    use it.

    Also some other code that uses that library might be useful.
    What would also help is a toy database small enough so you can calculate
    by hand what answers you expect to get.


    --
    Terry Jan Reedy
  • Cousin Stanley at Feb 17, 2011 at 6:19 pm

    Matty Sarro wrote:

    ....
    I am in charge of deploying a platform to allow people
    across my company to access a variety of crunched metrics
    using splunk.
    ....
    For the convenience of others
    that may not be familar with splunk ....

    http://en.wikipedia.org/wiki/Splunk

    http://www.splunk.com/


    --
    Stanley C. Kitching
    Human Being
    Phoenix, Arizona
  • Matty Sarro at Feb 17, 2011 at 6:33 pm
    Good point, pardon the assumption :)
    I'm reading more about RESTful and it looks like its a web based API.
    Oh well, I'll figure it out, I mean, my job depends on it, lol.
    On Thu, Feb 17, 2011 at 1:19 PM, Cousin Stanley wrote:

    Matty Sarro wrote:
    ....
    I am in charge of deploying a platform to allow people
    across my company to access a variety of crunched metrics
    using splunk.
    ....
    ?For the convenience of others
    ?that may not be familar with splunk ....

    ? ?http://en.wikipedia.org/wiki/Splunk

    ? ?http://www.splunk.com/


    --
    Stanley C. Kitching
    Human Being
    Phoenix, Arizona

    --
    http://mail.python.org/mailman/listinfo/python-list

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppython-list @
categoriespython
postedFeb 17, '11 at 2:23p
activeFeb 17, '11 at 6:33p
posts5
users4
websitepython.org

People

Translate

site design / logo © 2022 Grokbase