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!

Get the T-shirt to Prove You Survived Splunk University Bootcamp

As if Splunk University, in Las Vegas, in-person, with three days of bootcamps and labs weren’t enough, now ...

Introducing the Splunk Community Dashboard Challenge!

Welcome to Splunk Community Dashboard Challenge! This is your chance to showcase your skills in creating ...

Wondering How to Build Resiliency in the Cloud?

IT leaders are choosing Splunk Cloud as an ideal cloud transformation platform to drive business resilience,  ...