Return-Path: X-Original-To: apmail-camel-users-archive@www.apache.org Delivered-To: apmail-camel-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id BD20B101E4 for ; Tue, 1 Oct 2013 19:00:44 +0000 (UTC) Received: (qmail 4842 invoked by uid 500); 1 Oct 2013 19:00:44 -0000 Delivered-To: apmail-camel-users-archive@camel.apache.org Received: (qmail 4692 invoked by uid 500); 1 Oct 2013 19:00:43 -0000 Mailing-List: contact users-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@camel.apache.org Delivered-To: mailing list users@camel.apache.org Received: (qmail 4684 invoked by uid 99); 1 Oct 2013 19:00:43 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 01 Oct 2013 19:00:43 +0000 X-ASF-Spam-Status: No, hits=2.8 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS,URI_HEX X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of bengt.rodehav@gmail.com designates 209.85.160.45 as permitted sender) Received: from [209.85.160.45] (HELO mail-pb0-f45.google.com) (209.85.160.45) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 01 Oct 2013 19:00:37 +0000 Received: by mail-pb0-f45.google.com with SMTP id mc17so7535705pbc.18 for ; Tue, 01 Oct 2013 12:00:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:content-type; bh=cDG0DuxYx+wmUIvDw7zJGwQZdjcjRggcPOHTdHMcwqQ=; b=pS8Z11MbFTcVzPVe4SdoqkVxKX2ClPGsF+Wqq8szONwXq8dBx/fciMtRfNLhJ4YgTb vRIA7LcSZh385bClMHkEViszfigss6+clwJicXbHjCsQ9YczvcZpSIv4JyFHR5wiQvb8 cm906CezAhsyXcXYdMHEdkxXOWTHAf1XVFkK1aIgUTLiViT3MPS7yFqoYvA09/U/Czig 9v1MiMsMVofGbuJ2eifVjreNVARhWtDR1iYjNRrUUNN6JCvl5kNwzKKZJm2m6kA4gxBD dYnaINS5E8BmMYAFtklEnu6Ys1/B/BCFXzNq6g+KWHZ2t31lPfjRUhW9T/LrGYSRebax UOdg== MIME-Version: 1.0 X-Received: by 10.68.234.130 with SMTP id ue2mr10444343pbc.159.1380654015823; Tue, 01 Oct 2013 12:00:15 -0700 (PDT) Sender: bengt.rodehav@gmail.com Received: by 10.70.87.204 with HTTP; Tue, 1 Oct 2013 12:00:15 -0700 (PDT) In-Reply-To: <1380639324281-5740700.post@n5.nabble.com> References: <1380602772071-5740623.post@n5.nabble.com> <1380639324281-5740700.post@n5.nabble.com> Date: Tue, 1 Oct 2013 21:00:15 +0200 X-Google-Sender-Auth: 1oG9QqphF6zcsE6twYF4R_cm2g4 Message-ID: Subject: Re: Camel's use of jsch/java.io From: Bengt Rodehav To: users@camel.apache.org Content-Type: multipart/alternative; boundary=047d7b33cf642bc68204e7b290a4 X-Virus-Checked: Checked by ClamAV on apache.org --047d7b33cf642bc68204e7b290a4 Content-Type: text/plain; charset=ISO-8859-1 Hello Neil, I use the sftp component quite a lot. Now and then (perhaps once in a month) it stops polling. I think the problem to that lies in the Jsch itself and not in Camel. I'm not sure if it is the same problem you have though. I also took stack traces and found that Jsch was stuck in a read operation but I think that was a socket read operation. It seems like Jsch does not use TCP keepalive. This means that if the other end disconnects (or someone in between), Jsch will never be notified and hangs forever in a read. Instead Jsch relies on a timeout higher up in the protocol level (it might be part of SSH I'm not sure). This timeout can be set by specifying the "serverAliveInterval" parameter in the sftp component. Using a polling delay of 60000 ms, we now set the serverAliveInterval to 10000ms. We haven't had any problems since (no proof though since we've only been doing it for less than three months). Although it isn't necessarily the same problem, it might still be worth trying the serverAliveInterval parameter. /Bengt 2013/10/1 neil > The code that pointed out is in java.io.PipedInputStream.read(). > > I believe Camel's thread management is triggering an infinite loop in it, > although I am not certain. > > Is there a graceful way to have a Camel polling route completely reset > itself periodically? Or is bouncing the container a better option? > > Thanks, > -neil > > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/Camel-s-use-of-jsch-java-io-tp5740623p5740700.html > Sent from the Camel - Users mailing list archive at Nabble.com. > --047d7b33cf642bc68204e7b290a4--