Hi, On Thu, Mar 26, 2015 at 11:19 PM, John Gardiner Myers <[email protected]> wrote: > On 3/26/2015 3:03 PM, John Gardiner Myers wrote: >> >> InputStreamContentProviderIterator.next() wraps failures in a >> NoSuchElementException, presumably because it can't throw an IOException. >> Unfortunately, this tends to obscure the real failure. >> >> Would it make sense for ContentCallback.process() to unwrap the >> NoSuchElementException when it has a cause? > > > Or perhaps the problem is that Jetty let the exception propagate out of > HttpRequest.send() instead of swallowing it somewhere. When it propagates > out of HttpRequest.send(), the caller is likely to act on (or propagate) > that an not even look at the Listener.
Jetty client does swallow the exception and fails the callback, resulting in the complete event being triggered, see HttpSender.send[Headers|Content]() catch-all block. The unwrapped exception actually tells me that it happened while you were reading the request content of a request to a server, so you're actually using Jetty's HttpClient as a kind of proxy. I would not have known that by just reading the unwrapped exception, so seems even useful to me... -- Simone Bordet ---- http://cometd.org http://webtide.com http://intalio.com Developer advice, training, services and support from the Jetty & CometD experts. Intalio, the modern way to build business applications. _______________________________________________ jetty-users mailing list [email protected] To change your delivery options, retrieve your password, or unsubscribe from this list, visit https://dev.eclipse.org/mailman/listinfo/jetty-users
