Hi Nick, Thank you,
What kind of thing is the stream you're passing? > I am passing BufferedInputStream Does your stream support marking? And does it support marking that much? > Yes it is mark supported and marking the stream is not problem. Also, you could consider wrapping it with a TikaInputStream, which handles marking / buffering to files / etc if needed > By default Tika parser uses AutoDetectParser which internally wraps the > stream passed as TikaInputStream. As TikaInputStream not resetting the pos of the stream to zero for not all > the document types, so I need to do stream reset. For eg: Stream is not reset for files types txt, xml, htm, sh , etc,. Thanks, Praneesh On Mon, Jun 30, 2014 at 1:27 PM, Nick Burch <[email protected]> wrote: > On Mon, 30 Jun 2014, PRANEESH KUMAR wrote: > >> Using Tika 1.5 getting java.io.IOException: Resetting to invalid mark >> while >> reseting the stream passed. >> > > What kind of thing is the stream you're passing? > > stream.mark(Integer.MAX_VALUE); >> > > Does your stream support marking? And does it support marking that much? > > Also, you could consider wrapping it with a TikaInputStream, which handles > marking / buffering to files / etc if needed > > Nick >
