Splunk Dev

HTTP Exception: 401 -- call not properly authenticated after a while using Java api with threads

Aweave15
New Member

Hi everyone,

I am working on an application that routinely monitors splunk logs via the splunk Java api, and collects metrics.

Essentially, multiple threads are created, each that makes a call to the Service using oneshotsearch method. The program works fine for a while, but eventually they all get bombarded with the Http 401 response.

I did some research, it I've seen posts that say the current session could be expired and the user needs to re-login to Splunk. TO try and combat this, I have the service "re-login" using my splunk credentials, whenever it gets this response back. However, it doesn't look like this has fixed the issue...

Does anyone have any experience with this exception/ could provide me with some info to help troubleshoot?

Tags (1)
0 Karma
Get Updates on the Splunk Community!

Dashboards: Hiding charts while search is being executed and other uses for tokens

There are a couple of features of SimpleXML / Classic dashboards that can be used to enhance the user ...

Splunk Observability Cloud's AI Assistant in Action Series: Explaining Metrics and ...

This is the fourth post in the Splunk Observability Cloud’s AI Assistant in Action series that digs into how ...

Brains, Bytes, and Boston: Learn from the Best at .conf25

When you think of Boston, you might picture colonial charm, world-class universities, or even the crack of a ...