• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Servlet 3.0 support on WAS 8.0

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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
Posts: 2
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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
 
Could you hold this puppy for a sec? I need to adjust this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic