Jump to content
Changes to the Jaspersoft community edition download ×

Jasper Server Hangs when running many reports at a same time


dlcathukorala
Go to solution Solved by hozawa,

Recommended Posts

Hi,

I use Jaspersoft 5.6.1 Community Edition for reporting on jboss eap 6 . I recently encountered a problem that my report server hangs when running many reports at a time. Server shows me as Loading but it never get finished. I have to manually restart the server and continue.. It seems there is a problem with the database connection pool which it does not get released after invoking a report. 

Here are my connection pool configuration

In jasperserver.warWEB-INFapplicationContext.xml

 

<bean id="dataSourceObjectPoolFactory" class="org.apache.commons.pool.impl.GenericObjectPoolFactory">  <constructor-arg type="org.apache.commons.pool.PoolableObjectFactory">    <null/>  </constructor-arg>  <constructor-arg type="int" value="20" /></bean>[/code]

In jasperserver.warMETA-INFcontext.xml

<Resource name="jdbc/jasperserver"          auth="Container"          type="javax.sql.DataSource"          maxActive="100" maxIdle="30" maxWait="10000"          username="root"          password="root"          driverClassName="org.mariadb.jdbc.Driver"          accessToUnderlyingConnectionAllowed="true"          testOnBorrow="true"          url="jdbc:mysql://127.0.0.1:3306/jasperserver"          factory="${tomcatBasicDatasourceFactory}" />[/code]

and also I noticed that my jvm heap usage goes to 100 % when the report server hangs. Is there any solution regarding this?

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

  • Solution

This often happens when you're low on memory. Try allocating more memory to your application server jvm.

The better solution, however, is to schedule your report generation instead of generating them on the fly. I recommend creating a front end portal which generates reports using JasperReports Server APIs in the background via async.

Link to comment
Share on other sites

@hozawa Thank you for your immediate answer. But that was not the issue. I recently found the reason for this hanging. It is because of a bean datasource which I use to switch between schemas of my database. I created a new Question please refer to it if you can. 

http://community.jaspersoft.com/questions/893841/connection-pool-issue-bean-datasource

Thank you.

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...