[jboss-user] [JBoss Seam] - Re: GWT Remoting Example is not working
sohil.shah@jboss.com
do-not-reply at jboss.com
Tue Oct 16 23:07:15 EDT 2007
Shane-
This may very well be a hack job based on my novice understanding of Seam contexts. But after debugging here is what I did and it seems to have fixed the remote GWT example. Like I said, I am not sure what the side effects of this change could be.
Inside class org.jboss.seam.servlet.ContextualHttpServletRequest made the following change
| public void run() throws ServletException, IOException
| {
| log.debug("beginning request");
| ServletLifecycle.beginRequest(request);
| ServletContexts.instance().setRequest(request);
| restoreConversationId();
| Manager.instance().restoreConversation();
| ServletLifecycle.resumeConversation(request);
| handleConversationPropagation();
| try
| {
| //This code was added, because apparently it kept throwing
| //IllegalStateException if the response has been committed
| if(request.getSession(false) == null)
| {
| request.getSession(true);
| }
|
| process();
| //TODO: conversation timeout
| Manager.instance().endRequest( new ServletRequestSessionMap(request) );
| ServletLifecycle.endRequest(request);
| }
| catch (IOException ioe)
| {
| Lifecycle.endRequest();
| log.error("ended request due to exception", ioe);
| throw ioe;
| }
| catch (ServletException se)
| {
| Lifecycle.endRequest();
| log.error("ended request due to exception", se);
| throw se;
| }
| catch (Exception e)
| {
| Lifecycle.endRequest();
| log.error("ended request due to exception", e);
| throw new ServletException(e);
| }
| finally
| {
| log.debug("ended request");
| }
| }
|
and inside the examples/remoting/gwt/resources/WEB-INF/web.xml I had to modify the filter mapping as follows:
| <filter-mapping>
| <filter-name>Context Filter</filter-name>
| <url-pattern>*.html</url-pattern>
| <exclude-pattern>/seam/resource/*</exclude-pattern>
| </filter-mapping>
|
Thanks
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4095866#4095866
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4095866
More information about the jboss-user
mailing list