Hi Damien and Others,
I'm using the REST API Modular Input to pull data from Twitter's streaming APIs, and other REST sources using a Heavy Forwarder, and then pushing that data into indexes that are shared. For various reasons sometimes these REST services fail, and don't send an error, they just stop sending data. For example, the timeouts, and backoffs on the REST API Modular Input don't have an effect.
I have a scheduled search tied to an alert that checks on the receiving index to see, if data has stopped flowing. When I get an alert, I have to reset the input using the REST API Modular Input to get it re-set contact with Twitter, or whatever service I am using. When this kind of error condition happens most of the time a quick "disable and enable" gets the data flowing again.
I would like to automate this process. I'm thinking a Custom Response Handler attached via the REST API Modular Input configuration would do the trick.
I'm just wondering if there are examples of how to write the python, or if this is even the right approach.
Your thoughts are appreciated.
↧