DB connection problems when deploying ServiceBuilder

Marc-Andre Gauthier, modified 3 Years ago. New Member Posts: 21 Join Date: 7/30/15 Recent Posts

I have a scheduled task which uses a service builder module connected to a external database. 

Each time we deploy the service builder module, we get a bunch of exceptions in the scheduled task. 

e.g. 

com.liferay.portal.kernel.messaging.MessageListenerException: com.liferay.portal.kernel.exception.SystemException: com.liferay.portal.kernel.dao.orm.ORMException: org.hibernate.exception.GenericJDBCException: Cannot open connection

Caused by: java.sql.SQLException: com.mchange.v2.c3p0.ComboPooledDataSource[ identityToken -> fXTwF6h3, dataSourceName -> fXTwF6h3 ] has been closed() -- you can no longer use it.

 

After a while, the task recovers from this but during the time we get the exceptions, the scheduled task can't perform successfully. 

 

Anyone with a way to avoid this.

Liferay CE 7.4