raffimd Posted May 30, 2007 Share Posted May 30, 2007 Hi, I have 2 subreports in a report.Jasper Engine creates seperate threads for each subreport. Because of the thread, I face some problem in Hibernate session. I am implementing the JRDatasource interface for the subreport and making many calls to spring service layer which calls the DB through Hibernate. Looks like the Hibernate session is gettign closed between the service layer calls.Based on the analysis, I beleive that the spawned thread will cause this kind of Hibernate session issue. Is there a way to control the spawning of threading and instruct the JasperEngine to run the subreports in the same thread of the main report? Your help is really appreciated,Thanks in Advance,Raffi Link to comment Share on other sites More sharing options...
lucianc Posted May 31, 2007 Share Posted May 31, 2007 You can switch to using Javaflow Continuations instead of threads for subreports. See this discussion for more details. HTH,Lucian Link to comment Share on other sites More sharing options...
raffimd Posted May 31, 2007 Author Share Posted May 31, 2007 Hi Lucian, You saved me this time too :)Let me try that. Link to comment Share on other sites More sharing options...
raffimd Posted June 1, 2007 Author Share Posted June 1, 2007 It worked perfectly!!!Thanks again, I increased your karma count yesterday itself :) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now