hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oleg Kalnichevski (JIRA)" <j...@apache.org>
Subject [jira] [Moved] (HTTPCORE-456) BasicFuture get() implementation doesn't handle cancellation
Date Mon, 24 Apr 2017 09:50:04 GMT

     [ https://issues.apache.org/jira/browse/HTTPCORE-456?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel

Oleg Kalnichevski moved HTTPCLIENT-1839 to HTTPCORE-456:

    Affects Version/s:     (was: 4.5.3)
             Workflow: classic default workflow  (was: Default workflow, editable Closed status)
                  Key: HTTPCORE-456  (was: HTTPCLIENT-1839)
              Project: HttpComponents HttpCore  (was: HttpComponents HttpClient)

> BasicFuture get() implementation doesn't handle cancellation
> ------------------------------------------------------------
>                 Key: HTTPCORE-456
>                 URL: https://issues.apache.org/jira/browse/HTTPCORE-456
>             Project: HttpComponents HttpCore
>          Issue Type: Bug
>    Affects Versions: 5.0-alpha2, 4.4.6
>            Reporter: Rob Griffin
> The Javadoc for Future.get() states:
> 	V get() throws InterruptedException, ExecutionException, TimeoutException
> 	Waits if necessary for the computation to complete, and then retrieves its result.
> 	Returns: 
> 		the computed result 
> 	Throws: 
> 		CancellationException - if the computation was cancelled 
> 		ExecutionException - if the computation threw an exception 
> 		InterruptedException - if the current thread was interrupted while waiting 
> But when I look at the implementation of the get method in org.apache.http.concurrent.BasicFuture
it doesn't throw a CancellationException which seems wrong to me. Sure I can call isCancelled()
after get() returns but I shouldn't need to. 

This message was sent by Atlassian JIRA

To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org

View raw message