<br>I
 am testing simple application in jboss 7.1.1 final and servlet 3.0 
feature. inside doGet/doPost I am starting AsynContext and adding the 
AsyncListener().<br><br>now when I am closing the browser, I am expecting it will hit the onError method, but it never.<br>
<br>Let me know if this is valid case. <br><br>--------code abstract----------------------<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">-<br><br><br>@WebServlet(urlPatterns = &quot;/myPage&quot;, asyncSupported=true)<br>
public class MyActionServlet extends HttpServlet { <br>
    <br><br>    public MyActionServlet(){<br>        <br>    }<br>    @Override<br>    protected void doGet(HttpServletRequest req, HttpServletResponse resp)<br>            throws ServletException, IOException {<br>    <br>

        process(req, resp);<br>    }<br><br>    @Override<br>    protected void doPost(HttpServletRequest req, HttpServletResponse resp)<br>            throws ServletException, IOException {<br>        <br>        <br>        process(req,resp);<br>

    }<br>    <br>    private void process(HttpServletRequest req, HttpServletResponse resp) {<br>        System.out.println(&quot;Hello world&quot;);<br>        req.getSession();<br>        AsyncContext async = req.startAsync();        <br>

        async.addListener(new AsyncListener() {<br>            <br>            @Override<br>            public void onTimeout(AsyncEvent event) throws IOException {<br>                System.out.println(&quot;onTimeout:event::&quot;+event);<br>

                <br>                <br>                <br>            }<br>            <br>            @Override<br>            public void onStartAsync(AsyncEvent arg0) throws IOException {<br>                System.out.println(&quot;onstart::&quot;);<br>

                <br>            }<br>            <br>            @Override<br>            public void onError(AsyncEvent event) throws IOException {<br>            System.out.println(&quot;onError..&quot;+event);<br>                <br>

            }<br>            <br>            @Override<br>            public void onComplete(AsyncEvent event) throws IOException {<br>                System.out.println(&quot;onComplete::&quot;+event);<br>                <br>

            }<br>        });<br>    <br>        <br>    }<br>}<br><br>
</blockquote>