Details
Description
Apache Portals Bridges provides a neat solution (I wrote myself
) to "scope" HttpSession attributes for a specific Portlet window when it dispatches to a servlet.
This solution is needed for transparent "bridging" of existing web development frameworks like Struts, or Wicket (which I'm currently working on) to portlets.
So far, this proxy solution works like a charm and I've tested it successfully on Tomcat, Websphere, WebLogic and GlassFish.
Only with Jetty it fails ![]()
The reason is simple: AbstractSessionManager uses direct type casting of a provided HttpSession parameter to its inner Session class, so when a proxied version is passed in a ClassCastException is the result.
But the solution is also very simple, small and completely non-intrusive and I've attached a patch for it.
It adds a new interface JettySession with one method: JettySession getJettySession() and applies it to AbstractSessionManager.Session.
That interface allows Jetty to always get back to its own/underlying Session class.
With this patch applied, I can now run Jetspeed-2.1.1 (trunk) fully on Jetty 6.1.4 and we're planning to provide a Jetty based Jetspeed-2 demo installer with the imminent 2.1.1 release including neat hot deployment of war support.. But we will need to provide our own patched version of Jetty until this issue can be resolved.
(NB: I'm also a Jetspeed-2 committer)
So I would very much appreciate if you can review and consider this patch for inclusion in the next version of Jetty so we won't need to use a patched version of Jetty for running Jetspeed-2.
Regards,
Ate
Activity
| Field | Original Value | New Value |
|---|---|---|
| Attachment | patch2.txt [ 28107 ] |
| Assignee | Greg Wilkins [ gregw ] |
| Resolution | Fixed [ 1 ] | |
| Status | Open [ 1 ] | Resolved [ 5 ] |
| Resolution | Fixed [ 1 ] | |
| Status | Resolved [ 5 ] | Reopened [ 4 ] |
| Status | Reopened [ 4 ] | Resolved [ 5 ] |
| Resolution | Fixed [ 1 ] | |
| Fix Version/s | 6.1.5rc0 [ 13601 ] |
The Jetspeed-2 - Jetty support I'm working on can be tracked here: http://issues.apache.org/jira/browse/JS2-736