Re: [Dev] java.net.SocketException: Broken pipe -Error while running ESB scheduled task

2015-08-03 Thread Lakshman Udayakantha
Hi Nashry,

did you enable the autoReconnect to true by defining connection string in
master datasource xml in following way?

jdbc:mysql://10.3.24.96:3306/master?autoReconnect=true

Thanks

On Tue, Aug 4, 2015 at 11:26 AM, Aaquibah Nashry  wrote:

> Hi,
>
> i get the following error logs when I am trying to run a scheduled task in
> the ESB.
> What could be the reason? What can i do to overcome this?
>
> TID: [0] [ESB] [2015-08-04 00:00:36,958]  INFO
> {org.apache.synapse.mediators.builtin.LogMediator} -  To:
> http://www.w3.org/2005/08/addressing/anonymous, WSAction: , SOAPAction: ,
> MessageID: urn:uuid:6cba9ade-1456-42bf-bca9-e0c2110fed2c, Direction:
> request, STATE = LEADQ {org.apache.synapse.mediators.builtin.LogMediator}
> TID: [0] [ESB] [2015-08-04 00:00:38,318] ERROR
> {org.apache.synapse.mediators.db.DBReportMediator} -  Error execuring
> insert statement :
> INSERT INTO quarterlyleads
> (Region, count, RecordDate) VALUES (?, ?, ?) against DataSource :
> jdbc:mysql://localhost:3306/sf
> {org.apache.synapse.mediators.db.DBReportMediator}
> com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: The last packet
> successfully received from the server was 62,995,899 milliseconds ago.  The
> last packet sent successfully to the server was 62,995,908 milliseconds
> ago. is longer than the server configured value of 'wait_timeout'. You
> should consider either expiring and/or testing connection validity before
> use in your application, increasing the server configured values for client
> timeouts, or using the Connector/J connection property 'autoReconnect=true'
> to avoid this problem.
> at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
> at
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
> at
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
> at java.lang.reflect.Constructor.newInstance(Constructor.java:534)
> at com.mysql.jdbc.Util.handleNewInstance(Util.java:408)
> at
> com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1137)
> at com.mysql.jdbc.MysqlIO.send(MysqlIO.java:3965)
> at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2578)
> at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2758)
> at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2826)
> at
> com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:2082)
> at
> com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2334)
> at
> com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2262)
> at
> com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2246)
> at
> org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
> at
> org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
> at
> org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
> at
> org.apache.synapse.mediators.db.DBReportMediator.processStatement(DBReportMediator.java:55)
> at
> org.apache.synapse.mediators.db.AbstractDBMediator.mediate(AbstractDBMediator.java:143)
> at
> org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:77)
> at
> org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:47)
> at
> org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:131)
> at org.apache.synapse.mediators.eip.Target.mediate(Target.java:106)
> at
> org.apache.synapse.mediators.eip.splitter.IterateMediator.mediate(IterateMediator.java:146)
> at
> org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:77)
> at
> org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:255)
> at
> org.apache.synapse.core.axis2.Axis2SynapseEnvironment.mediateFromContinuationStateStack(Axis2SynapseEnvironment.java:556)
> at
> org.apache.synapse.core.axis2.Axis2SynapseEnvironment.injectMessage(Axis2SynapseEnvironment.java:198)
> at
> org.apache.synapse.core.axis2.SynapseCallbackReceiver.handleMessage(SynapseCallbackReceiver.java:488)
> at
> org.apache.synapse.core.axis2.SynapseCallbackReceiver.receive(SynapseCallbackReceiver.java:170)
> at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:180)
> at
> org.apache.synapse.transport.passthru.ClientWorker.run(ClientWorker.java:225)
> at
> org.apache.axis2.transport.base.threads.NativeWorkerPool$1.run(NativeWorkerPool.java:172)
> at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1146)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
> at java.lang.Thread.run(Thread.java:701)
> Caused by: java.net.SocketException: Broken pipe
> at java.net.SocketOutputStream.socketWrite0(Native Method)
> at java.net.SocketOutputStream.socketWrite(SocketOutputStream.ja

[Dev] java.net.SocketException: Broken pipe -Error while running ESB scheduled task

2015-08-03 Thread Aaquibah Nashry
Hi,

i get the following error logs when I am trying to run a scheduled task in
the ESB.
What could be the reason? What can i do to overcome this?

TID: [0] [ESB] [2015-08-04 00:00:36,958]  INFO
{org.apache.synapse.mediators.builtin.LogMediator} -  To:
http://www.w3.org/2005/08/addressing/anonymous, WSAction: , SOAPAction: ,
MessageID: urn:uuid:6cba9ade-1456-42bf-bca9-e0c2110fed2c, Direction:
request, STATE = LEADQ {org.apache.synapse.mediators.builtin.LogMediator}
TID: [0] [ESB] [2015-08-04 00:00:38,318] ERROR
{org.apache.synapse.mediators.db.DBReportMediator} -  Error execuring
insert statement :
INSERT INTO quarterlyleads
(Region, count, RecordDate) VALUES (?, ?, ?) against DataSource :
jdbc:mysql://localhost:3306/sf
{org.apache.synapse.mediators.db.DBReportMediator}
com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: The last packet
successfully received from the server was 62,995,899 milliseconds ago.  The
last packet sent successfully to the server was 62,995,908 milliseconds
ago. is longer than the server configured value of 'wait_timeout'. You
should consider either expiring and/or testing connection validity before
use in your application, increasing the server configured values for client
timeouts, or using the Connector/J connection property 'autoReconnect=true'
to avoid this problem.
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:534)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:408)
at com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1137)
at com.mysql.jdbc.MysqlIO.send(MysqlIO.java:3965)
at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2578)
at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2758)
at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2826)
at
com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:2082)
at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2334)
at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2262)
at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2246)
at
org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
at
org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
at
org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
at
org.apache.synapse.mediators.db.DBReportMediator.processStatement(DBReportMediator.java:55)
at
org.apache.synapse.mediators.db.AbstractDBMediator.mediate(AbstractDBMediator.java:143)
at
org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:77)
at
org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:47)
at
org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:131)
at org.apache.synapse.mediators.eip.Target.mediate(Target.java:106)
at
org.apache.synapse.mediators.eip.splitter.IterateMediator.mediate(IterateMediator.java:146)
at
org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:77)
at
org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:255)
at
org.apache.synapse.core.axis2.Axis2SynapseEnvironment.mediateFromContinuationStateStack(Axis2SynapseEnvironment.java:556)
at
org.apache.synapse.core.axis2.Axis2SynapseEnvironment.injectMessage(Axis2SynapseEnvironment.java:198)
at
org.apache.synapse.core.axis2.SynapseCallbackReceiver.handleMessage(SynapseCallbackReceiver.java:488)
at
org.apache.synapse.core.axis2.SynapseCallbackReceiver.receive(SynapseCallbackReceiver.java:170)
at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:180)
at
org.apache.synapse.transport.passthru.ClientWorker.run(ClientWorker.java:225)
at
org.apache.axis2.transport.base.threads.NativeWorkerPool$1.run(NativeWorkerPool.java:172)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1146)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:701)
Caused by: java.net.SocketException: Broken pipe
at java.net.SocketOutputStream.socketWrite0(Native Method)
at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:109)
at java.net.SocketOutputStream.write(SocketOutputStream.java:153)
at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)
at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140)
at com.mysql.jdbc.MysqlIO.send(MysqlIO.java:3946)
... 29 more
TID: [0] [ESB] [2015-08-04 00:00:38,331] ERROR
{org.apache.synapse.core.axis2.SynapseCallbackReceiver} -  Synapse
encountered an exception, No error h