Splunk Dev

error when run java sdk -next() may not be called when XMLStreamReader is at END_DOCUMENT

kobieini
Engager

what can create this error?
java.lang.RuntimeException: java.lang.RuntimeException: next() may not be called when XMLStreamReader is at END_DOCUMENT
at com.splunk.Entity.refresh(Entity.java:373)
at com.splunk.Entity.refresh(Entity.java:1)
at com.splunk.Resource.validate(Resource.java:183)
at com.splunk.Entity.validate(Entity.java:449)
at com.splunk.Entity.getContent(Entity.java:159)
at com.splunk.Entity.getString(Entity.java:277)
at com.splunk.ServiceInfo.getVersion(ServiceInfo.java:151)
at com.splunk.Service.login(Service.java:956)
at com.splunk.Service.connect(Service.java:150)
at com.splunk.sdk.search.Program.run(Program.java:120)
at com.splunk.sdk.search.Program.main(Program.java:57)
Caused by: java.lang.RuntimeException: next() may not be called when XMLStreamReader is at END_DOCUMENT
at com.splunk.AtomObject.scan(AtomObject.java:198)
at com.splunk.AtomObject.load(AtomObject.java:127)
at com.splunk.AtomFeed.parse(AtomFeed.java:80)
at com.splunk.AtomFeed.parseStream(AtomFeed.java:59)
at com.splunk.Entity.refresh(Entity.java:371)
... 10 more

Tags (3)

wcolgate_splunk
Splunk Employee
Splunk Employee

Can you also tell us what you were doing when this error occurred? Can you post any of your code that tickles this issue?

0 Karma

davidfstr
Explorer

What version of the Java SDK are you using?

0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...