You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Recently started using this TA. Thanks for building it!
Today I upgraded my Splunk instance to 8.1 and after that the modular input failed (I guess due to switch to python 3?). I ran it through the Splunk Platform Upgrade Readiness app (https://splunkbase.splunk.com/app/4698/), which recommended below changes.
After applying those and additionally also removing the import md5 (since that also threw an error and didn't seem to be used), the modular input is now working again.
@@ -107,7 +109,7 @@
response.raise_for_status()
data = response.json()["body"]["devices"][0]
except requests.exceptions.HTTPError as error:
- print(error.response.status_code, error.response.text)
+ print((error.response.status_code, error.response.text))
print(json.dumps(data, sort_keys=True))
@@ -148,7 +150,7 @@
config["checkpoint_dir"] = checkpnt_node.firstChild.data
if not config:
- raise Exception, "Invalid configuration received from Splunk."
+ raise Exception("Invalid configuration received from Splunk.")
# just some validation: make sure these keys are present (required)
validate_conf(config, "client_id")
PS: I also found a fairly neat way of working with the json data that this TA ingests (which contains datapoints from multiple sensors in 1 event). I created a saved search that takes the json data, extracts the datapoints of the various modules to separate rows and stores it in a metrics index using mcollect. If you're interested I'm happy to share that, but not sure how I can best do that here?
The text was updated successfully, but these errors were encountered:
Recently started using this TA. Thanks for building it!
Today I upgraded my Splunk instance to 8.1 and after that the modular input failed (I guess due to switch to python 3?). I ran it through the Splunk Platform Upgrade Readiness app (https://splunkbase.splunk.com/app/4698/), which recommended below changes.
After applying those and additionally also removing the
import md5
(since that also threw an error and didn't seem to be used), the modular input is now working again.PS: I also found a fairly neat way of working with the json data that this TA ingests (which contains datapoints from multiple sensors in 1 event). I created a saved search that takes the json data, extracts the datapoints of the various modules to separate rows and stores it in a metrics index using mcollect. If you're interested I'm happy to share that, but not sure how I can best do that here?
The text was updated successfully, but these errors were encountered: