1 Reply Latest reply on Dec 5, 2014 2:16 PM by Kevin Conner

    FTP message not sent/received due to connection timeout after firewall interrupt

    Mihir Shah Newbie

      The FTP connection gets timed out, when there is firewall interrupt. But this FTP connection doesn’t recover even after solving the firewall issue. Due to this, the FTP messages are not sent/received, even after it retries.

      Can anyone please help on this issue?

       

      Following are the steps to reproduce it:

      1. Place FTP messages on FTP server
      2. Observe the messages are received
      3. Simulate FTP connection time out by the command : iptables –A OUTPUT –d ip.of.FTP.server –j DROP
      4. Place FTP messages on FTP server
      5. Observe the messages are not received
      6. Solve the firewall issue by disabling it : service iptables stop
      7. Issue: the message is still not received. It keeps throwing connection timed out exception as below:
      8. The same issue also happens while FTP messages being sent.

       

       

      Error log:

      2014-08-06 10:49:43,018 ERROR [org.jboss.soa.esb.listeners.gateway.AbstractFileGateway] Can't retrieve file list

      1. org.jboss.soa.esb.listeners.gateway.GatewayException: org.jboss.soa.esb.util.RemoteFileSystemException: org.jboss.soa.esb.util.RemoteFileSystemException: java.net.ConnectException: Connection timed out

      at org.jboss.soa.esb.listeners.gateway.RemoteGatewayListener.getFileList(RemoteGatewayListener.java:176)

      at org.jboss.soa.esb.listeners.gateway.AbstractFileGateway.onSchedule(AbstractFileGateway.java:109)

      at org.jboss.soa.esb.listeners.lifecycle.AbstractScheduledManagedLifecycle$1.onSchedule(AbstractScheduledManagedLifecycle.java:68)

              at org.jboss.soa.esb.schedule.SchedulerJob$ESBScheduledJob.execute(SchedulerJob.java:289)

      at org.quartz.core.JobRunShell.run(JobRunShell.java:203)

      at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)

      Caused by: org.jboss.soa.esb.util.RemoteFileSystemException: org.jboss.soa.esb.util.RemoteFileSystemException: java.net.ConnectException: Connection timed out

      at org.jboss.soa.esb.util.RemoteFileSystemFactory.getRemoteFileSystem(RemoteFileSystemFactory.java:70)

      at org.jboss.soa.esb.listeners.gateway.RemoteGatewayListener.getFileList(RemoteGatewayListener.java:164)

      ... 5 more

      Caused by: org.jboss.soa.esb.util.RemoteFileSystemException: java.net.ConnectException: Connection timed out

      at org.jboss.internal.soa.esb.util.FtpImpl.initialize(FtpImpl.java:450)

      at org.jboss.internal.soa.esb.util.FtpImpl.<init>(FtpImpl.java:98)

      at org.jboss.soa.esb.util.RemoteFileSystemFactory.getRemoteFileSystem(RemoteFileSystemFactory.java:62)

              ... 6 more

      Caused by: java.net.ConnectException: Connection timed out

      at java.net.PlainSocketImpl.socketConnect(Native Method)

      at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:327)

      at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:193)

      at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:180)

      at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:385)

      at java.net.Socket.connect(Socket.java:546)

      at org.apache.commons.net.SocketClient.connect(SocketClient.java:176)

      at org.jboss.internal.soa.esb.util.FtpImpl.connect(FtpImpl.java:466)

      at org.jboss.internal.soa.esb.util.FtpImpl.initialize(FtpImpl.java:415)

              ... 8 more

       

       

      The global configuration at esb.deployer/jbossesb-properties.xml has timeout as 0(=infinite) and its not overridden in ESB service.

        <property name="org.jboss.soa.esb.ftp.timeout" value="0"/>