Return-Path: Delivered-To: apmail-jakarta-httpcomponents-dev-archive@www.apache.org Received: (qmail 95020 invoked from network); 25 Jan 2007 19:48:12 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 25 Jan 2007 19:48:12 -0000 Received: (qmail 85897 invoked by uid 500); 25 Jan 2007 19:48:18 -0000 Delivered-To: apmail-jakarta-httpcomponents-dev-archive@jakarta.apache.org Received: (qmail 85780 invoked by uid 500); 25 Jan 2007 19:48:17 -0000 Mailing-List: contact httpcomponents-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "HttpComponents Project" Delivered-To: mailing list httpcomponents-dev@jakarta.apache.org Received: (qmail 85718 invoked by uid 99); 25 Jan 2007 19:48:17 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 25 Jan 2007 11:48:17 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 25 Jan 2007 11:48:09 -0800 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 5C67E7142D4 for ; Thu, 25 Jan 2007 11:47:49 -0800 (PST) Message-ID: <33535655.1169754469375.JavaMail.jira@brutus> Date: Thu, 25 Jan 2007 11:47:49 -0800 (PST) From: "Oleg Kalnichevski (JIRA)" To: httpcomponents-dev@jakarta.apache.org Subject: [jira] Commented: (HTTPCORE-29) DefaultConnectingIOReactor.execute propagates IOException, but isn't really re-callable In-Reply-To: <33066242.1169600809506.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HTTPCORE-29?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12467512 ] Oleg Kalnichevski commented on HTTPCORE-29: ------------------------------------------- Anders, I tend to see all IOExceptions thrown within the execute method as fatal. So, are you suggesting that the I/O reactor should re-start itself automatically if an I/O exception is thrown? In my opinion the recovery mechanism should not be part of the reactor itself. I just have to review the code and make sure all connections are cleanly shutdown in case of an I/O failure. What is your take? Oleg > DefaultConnectingIOReactor.execute propagates IOException, but isn't really re-callable > --------------------------------------------------------------------------------------- > > Key: HTTPCORE-29 > URL: https://issues.apache.org/jira/browse/HTTPCORE-29 > Project: HttpComponents Core > Issue Type: Bug > Components: HttpCore NIO > Affects Versions: 4.0-alpha3 > Reporter: Anders Wallgren > Assigned To: Oleg Kalnichevski > Fix For: 4.0-alpha4 > > > I'm trying to figure out what to do when DefaultConnectingIOReactor.execute throws an exception. It doesn't seem like I can just call execute() again after handling the exception, since that will recreate all the state in DCIOR. > Seems to me that there needs to be a different way to handle exceptions, or the execute method should be callable more than once. > For reference, here's the stack trace of an exception: > {code} > 2007-01-23T16:23:19.800 | ERROR | urceInvoker | | NewResourceInvoker | Invalid argument: sun.nio.ch.Net.setIntOption > java.net.SocketException: Invalid argument: sun.nio.ch.Net.setIntOption > at sun.nio.ch.Net.setIntOption0(Native Method) > at sun.nio.ch.Net.setIntOption(Net.java:154) > at sun.nio.ch.SocketChannelImpl$1.setInt(SocketChannelImpl.java:406) > at sun.nio.ch.SocketOptsImpl.setBoolean(SocketOptsImpl.java:38) > at sun.nio.ch.SocketOptsImpl$IP$TCP.noDelay(SocketOptsImpl.java:284) > at sun.nio.ch.OptionAdaptor.setTcpNoDelay(OptionAdaptor.java:48) > at sun.nio.ch.SocketAdaptor.setTcpNoDelay(SocketAdaptor.java:268) > at org.apache.http.nio.impl.reactor.DefaultConnectingIOReactor.prepareSocket(DefaultConnectingIOReactor.java:171) > at org.apache.http.nio.impl.reactor.DefaultConnectingIOReactor.processEvent(DefaultConnectingIOReactor.java:158) > at org.apache.http.nio.impl.reactor.DefaultConnectingIOReactor.processEvents(DefaultConnectingIOReactor.java:134) > at org.apache.http.nio.impl.reactor.DefaultConnectingIOReactor.execute(DefaultConnectingIOReactor.java:94) > at com.electriccloud.commander.domain.NewResourceInvoker.innerRun(NewResourceInvoker.java:304) > at com.electriccloud.util.FailsafeRunnable.run(FailsafeRunnable.java:105) > at java.lang.Thread.run(Thread.java:619) > {code} -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: httpcomponents-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: httpcomponents-dev-help@jakarta.apache.org