Splunk Search

How to develop custom python scripts ?

sunrise
Contributor

Hi Splunkers,

I wanna develop custom python scripts as a search command whose input data is search fields,
output data is processed data by itself.

Now I have a question that what is the best way of developing custom python scripts.
I know that logger.info() method can write to python.log, but not do how to debug and so on.
Is there anything way ?

Thank you for your help.

Tags (3)
0 Karma
1 Solution

chris
Motivator

If you want to debug the running script you could use PyDev PyDev (& Eclipse ).

View solution in original post

0 Karma

chris
Motivator

If you want to debug the running script you could use PyDev PyDev (& Eclipse ).

0 Karma

sunrise
Contributor

I'm sure Pydev and eclipse environment is pretty good for remote debug.
Thank you, chris.

0 Karma

nmistry_splunk
Splunk Employee
Splunk Employee

This is a broad question. Can you elaborate on what you wan to debug? Look at other scripts under SPLUNK_HOME/etc/apps/search/bin as examples on how to.

0 Karma
Get Updates on the Splunk Community!

New Splunk Observability innovations: Deeper visibility and smarter alerting to ...

You asked, we delivered. Splunk Observability Cloud has several new innovations giving you deeper visibility ...

Synthetic Monitoring: Not your Grandma’s Polyester! Tech Talk: DevOps Edition

Register today and join TekStream on Tuesday, February 28 at 11am PT/2pm ET for a demonstration of Splunk ...

Instrumenting Java Websocket Messaging

Instrumenting Java Websocket MessagingThis article is a code-based discussion of passing OpenTelemetry trace ...