[jboss-jira] [JBoss JIRA] (AS7-4232) AsyncContext.complete and AsyncContext.dispatch have no effect while invoking AsyncListener.onError(AsyncEvent)

Remy Maucherat (JIRA) jira-events at lists.jboss.org
Wed Mar 21 07:59:47 EDT 2012


    [ https://issues.jboss.org/browse/AS7-4232?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678298#comment-12678298 ] 

Remy Maucherat commented on AS7-4232:
-------------------------------------

So the claim is that errors during a dispatch should be handled differently, in particular about the possibility to dispatch again the already dispatched async context. I was not really aware of the difference and will eventually need to verify that, in particular the behavior of other implementations.
                
> AsyncContext.complete and AsyncContext.dispatch have no effect while invoking AsyncListener.onError(AsyncEvent)
> ---------------------------------------------------------------------------------------------------------------
>
>                 Key: AS7-4232
>                 URL: https://issues.jboss.org/browse/AS7-4232
>             Project: Application Server 7
>          Issue Type: Bug
>          Components: Web
>    Affects Versions: 7.1.1.Final
>            Reporter: Martin Kouba
>            Assignee: Remy Maucherat
>
> The Servlet 3.0 spec "2.3.3.3 Asynchronous processing" states: 
> "Any errors or exceptions that may occur during the execution of the dispatch methods MUST be caught and handled by the container as follows:
> ...
> ii. If none of the listeners called AsyncContext.complete or any of the AsyncContext.dispatch methods, then perform an error dispatch with a status code equal to HttpServletResponse.SC_INTERNAL_SERVER_ERROR and make the Throwable available as the value of the RequestDispatcher.ERROR_EXCEPTION request attribute.
> ...
> "
> However calling complete() or dispatch() method has no effect and container always returns SC_INTERNAL_SERVER_ERROR.
> See CDI TCK 1.1 test:
> https://github.com/jboss/cdi-tck/blob/a8228d9dbe6191488186cf6d20078632c0f43115/impl/src/main/java/org/jboss/cdi/tck/tests/context/application/async/ApplicationContextAsyncListenerTest.java

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jboss-jira mailing list