[jboss-user] [JBoss Portal] - JBoss Portal 2.6.4 - can't get HttpServletRequest from Rende

mcs02 do-not-reply at jboss.com
Sun Aug 17 12:14:52 EDT 2008


I am trying to get the HttpServletRequest from a RenderRequest (javax.portlet.RenderRequest). This is some existing code (running on Websphere Portal 5.1)  that orginally was doing this:

HttpServletRequest request = (HttpServletRequest) renderRequest;

However, on Jboss Portal, This throws a ClassCastException:
java.lang.ClassCastException: org.jboss.portlet.JBossRenderRequest

So I tried this approach after a few Google searches:

HttpServletRequest request = (HttpServletRequest) renderRequest.getAttribute("javax.servlet.request");

No ClassCastException but...The resulting request object is returned but is NULL.

Any ideas as to what might work?

Thanks in advance.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4170946#4170946

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4170946

More information about the jboss-user mailing list