Hi
I'm facing a strange problem.
I designed a report contains various nested subreports within it. After designing in ireport it is working propely in iReport, when I publish the same report to jasper server its working fine there too.
But when after publishing the report when I'm trying to run it in iReport again its giving error.
Error filling print... net.sf.jasperreports.engine.JRException: Error loading object from InputStream
Setting up the file resolver...
Added file resolver...
net.sf.jasperreports.engine.JRRuntimeException: net.sf.jasperreports.engine.JRException: Error loading object from InputStream
at net.sf.jasperreports.repo.SerializedObjectPersistenceService.load(SerializedObjectPersistenceService.java:65)
at net.sf.jasperreports.repo.SerializedReportPersistenceService.load(SerializedReportPersistenceService.java:46)
at net.sf.jasperreports.repo.DefaultRepositoryService.getResource(DefaultRepositoryService.java:187)
at net.sf.jasperreports.repo.RepositoryUtil.getResourceFromLocation(RepositoryUtil.java:246)
at net.sf.jasperreports.repo.RepositoryUtil.getReport(RepositoryUtil.java:208)
at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluateReport(JRFillSubreport.java:336)
at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluateSubreport(JRFillSubreport.java:369)
at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluate(JRFillSubreport.java:294)
at net.sf.jasperreports.engine.fill.JRFillElementContainer.evaluate(JRFillElementContainer.java:259)
at net.sf.jasperreports.engine.fill.JRFillBand.evaluate(JRFillBand.java:455)
at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillColumnBand(JRVerticalFiller.java:2044)
at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillDetail(JRVerticalFiller.java:778)
at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportStart(JRVerticalFiller.java:288)
at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:151)
at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:909)
at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:822)
at net.sf.jasperreports.engine.fill.JRFillSubreport.fillSubreport(JRFillSubreport.java:651)
at net.sf.jasperreports.engine.fill.JRSubreportRunnable.run(JRSubreportRunnable.java:59)
at net.sf.jasperreports.engine.fill.AbstractThreadSubreportRunner.run(AbstractThreadSubreportRunner.java:203)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Caused by: net.sf.jasperreports.engine.JRException: Error loading object from InputStream
at net.sf.jasperreports.engine.util.JRLoader.loadObject(JRLoader.java:249)
at net.sf.jasperreports.engine.util.JRLoader.loadObject(JRLoader.java:229)
at net.sf.jasperreports.repo.SerializedObjectPersistenceService.load(SerializedObjectPersistenceService.java:61)
... 21 more
Caused by: java.io.StreamCorruptedException: invalid stream header: 3C3F786D
at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:783)
at java.io.ObjectInputStream.<init>(ObjectInputStream.java:280)
at net.sf.jasperreports.engine.util.ContextClassLoaderObjectInputStream.<init>(ContextClassLoaderObjectInputStream.java:58)
at net.sf.jasperreports.engine.util.JRLoader.loadObject(JRLoader.java:244)
... 23 more
I modified the subrepot expression from "repo:subreport.jrxml" to "subreport.jrxml" in iReport but still its giving the same issue. I,m unable to figure it out why its giving this error.The report is same as privious.
Can anyone help me regarding this issue.
Thanks
Anand
Hi I am also having the same problem.If you know the solution please post here.
I am new to Jasper Reports, thanks
Hi
I am also facing same problem if you know the solution let me know please
Thanks
Hi,
I solve that changing the extension of the file to jasper. Not just modifying the subrepot expression from "repo:subreport.jrxml" to "subreport.jrxml". Because when you upload the report, previously is compiled. So, you need to change to.. "subreport.jasper"
Now, it is working again!
Good luck!
Yeap chaning jrxml to jasper wiork for SUBREPORT.
YOu can build project so that SUBreport get compiled