Meaningless Drivel is fun!*
The moose likes Websphere and the fly likes Servlet 3.0 support on WAS 8.0 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Products » Websphere
Bookmark "Servlet 3.0 support on WAS 8.0 " Watch "Servlet 3.0 support on WAS 8.0 " New topic
Author

Servlet 3.0 support on WAS 8.0

Irfan Nagoo
Greenhorn

Joined: Oct 12, 2010
Posts: 2
Hi,

I deployed an Asynchronous servlet (using Servlet3.0 Async API) on my WAS 8.0. I have also set the property asyncSupported = true using annotation in the servlet and also I put an entry in the web.xml of the war. However, when I try to hit this servlet I get this exception:


3/30/11 3:41:23:781 IST 00000022 servlet E com.ibm.ws.webcontainer.servlet.ServletWrapper service SRVE0068E: An exception was thrown by one of the service methods of the servlet ASyncServlet in application ASyncDemo_war. Exception created : [com.ibm.ws.webcontainer.async.AsyncIllegalStateException: SRVE8010E: The current request does not support asynchronous servlet processing.
at com.ibm.ws.webcontainer.srt.SRTServletRequest.startAsync(SRTServletRequest.java:3332)
at com.ibm.ws.webcontainer.srt.SRTServletRequest.startAsync(SRTServletRequest.java:3310)
at com.demo.servlet.ASyncServlet.service(ASyncServlet.java:63)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:668)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1147)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:722)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:449)
at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.invokeFilters(WebAppFilterManager.java:1020)
at com.ibm.ws.webcontainer.servlet.CacheServletWrapper.handleRequest(CacheServletWrapper.java:87)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:883)
at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1659)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:195)
at com.ibm.ws.ard.channel.ARDChannelConnLink.handleDiscrimination(ARDChannelConnLink.java:188)
at com.ibm.ws.ard.channel.ARDChannelConnLink.ready(ARDChannelConnLink.java:93)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:452)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewRequest(HttpInboundLink.java:511)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.processRequest(HttpInboundLink.java:305)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.ready(HttpInboundLink.java:276)
at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.sendToDiscriminators(NewConnectionInitialReadCallback.java:214)
at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.complete(NewConnectionInitialReadCallback.java:113)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at com.ibm.io.async.AsyncChannelFuture$1.run(AsyncChannelFuture.java:205)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648)
]
3/30/11 3:41:23:782 IST 00000022 LocalTranCoor E WLTC0017E: Resources rolled back due to setRollbackOnly() being called.

I searched on internet about this and I found nothing related to it. Please let me in case anyone has any idea or suggestion about this error?

Irfan
Irfan Nagoo
Greenhorn

Joined: Oct 12, 2010
Posts: 2
Guys,

I got it fixed. Actually, the problem was with the web.xml entry for aSynch support. The entry that I was trying was specific to tomcat7 and the WAS 8.0 specific entry looks like this:

<servlet>
<description>
</description>
<display-name>ASyncServlet</display-name>
<servlet-name>ASyncServlet</servlet-name>
<servlet-class>com.demo.servlet.ASyncServlet</servlet-class>
<init-param>
<param-name>com.ibm.ws.webcontainer.async-supported</param-name>
<param-value>true</param-value>
</init-param>
</servlet>


Using the above mentioned entry in the web.xml I was able to get rid of the exception that I was getting.


Thanks, Irfan
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Servlet 3.0 support on WAS 8.0
 
Similar Threads
HttpClient Exception
ant build
Configuring WAS 6.1 data source
Null pointer exception in jsp
websphere 6.1 does not support distributed map