You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Romain Manni-Bucau <rm...@gmail.com> on 2014/06/10 20:28:47 UTC

async error message if not supported

Hi

in /org/apache/catalina/connector/Request.java it would be nice if error
message if there is a filter/servlet not supporting async would be more
explicit. Here is the code:

1654     @Override
1655     public AsyncContext startAsync(ServletRequest request,
1656             ServletResponse response) {
1657         if (!isAsyncSupported()) {
1658             throw new IllegalStateException("Not supported.");
1659         }

I propose to change it to:

throw new IllegalStateException("A filter or servlet of the current chain
doesn't support asynchronism.");

Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau

Re: async error message if not supported

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Thanks!
Le 11 juin 2014 02:58, "Violeta Georgieva" <mi...@gmail.com> a écrit :

> Hi,
>
> 2014-06-10 21:28 GMT+03:00 Romain Manni-Bucau <rm...@gmail.com>:
> >
> > Hi
> >
> > in /org/apache/catalina/connector/Request.java it would be nice if error
> > message if there is a filter/servlet not supporting async would be more
> > explicit. Here is the code:
> >
> > 1654     @Override
> > 1655     public AsyncContext startAsync(ServletRequest request,
> > 1656             ServletResponse response) {
> > 1657         if (!isAsyncSupported()) {
> > 1658             throw new IllegalStateException("Not supported.");
> > 1659         }
> >
> > I propose to change it to:
> >
> > throw new IllegalStateException("A filter or servlet of the current chain
> > doesn't support asynchronism.");
>
> Thanks for the report.
> This has been fixed in trunk for 8.0.9 and in 7.0.x for 7.0.55 onwards.
>
> Regards,
> Violeta
>
>
> >
> > Romain Manni-Bucau
> > Twitter: @rmannibucau
> > Blog: http://rmannibucau.wordpress.com/
> > LinkedIn: http://fr.linkedin.com/in/rmannibucau
> > Github: https://github.com/rmannibucau
>

Re: async error message if not supported

Posted by Violeta Georgieva <mi...@gmail.com>.
Hi,

2014-06-10 21:28 GMT+03:00 Romain Manni-Bucau <rm...@gmail.com>:
>
> Hi
>
> in /org/apache/catalina/connector/Request.java it would be nice if error
> message if there is a filter/servlet not supporting async would be more
> explicit. Here is the code:
>
> 1654     @Override
> 1655     public AsyncContext startAsync(ServletRequest request,
> 1656             ServletResponse response) {
> 1657         if (!isAsyncSupported()) {
> 1658             throw new IllegalStateException("Not supported.");
> 1659         }
>
> I propose to change it to:
>
> throw new IllegalStateException("A filter or servlet of the current chain
> doesn't support asynchronism.");

Thanks for the report.
This has been fixed in trunk for 8.0.9 and in 7.0.x for 7.0.55 onwards.

Regards,
Violeta


>
> Romain Manni-Bucau
> Twitter: @rmannibucau
> Blog: http://rmannibucau.wordpress.com/
> LinkedIn: http://fr.linkedin.com/in/rmannibucau
> Github: https://github.com/rmannibucau