struts-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Martin Cooper" <martin.coo...@tumbleweed.com>
Subject RE: Path-mapped action and Struts 1.1 beta
Date Mon, 01 Jul 2002 23:51:38 GMT


> -----Original Message-----
> From: Ted Husted [mailto:husted@apache.org]
> Sent: Monday, July 01, 2002 3:46 PM
> To: Struts Developers List
> Subject: Re: Path-mapped action and Struts 1.1 beta
> 
> 
> "Craig R. McClanahan" wrote:
> > No ... and (this time at least) not because of lack of 
> time.  It is not at
> > all obvious how to rig path mapping to the controller to 
> work together
> > with the basic assumption of sub-applications that there is 
> a prefix for
> > that subapp.  All I can think of is requiring you to map 
> the controller
> > once per subapp, which is both ugly and will require a 
> bunch of changes to
> > the existing code that assumes there is only one mapping to 
> the controller
> > servlet.
> > 
> > Ideas, anyone?
> 
> Underlying problem with modules and prefix mapping: 
> 
> Controller is inserting module name before "module-relative" 
> path. This
> happens for all URIs, not just actions. So with 
> prefix-mapping, we'd not
> only have /do/module1/action but /do/module/page.jsp. 
> 
> Killer kludge of the week: 
> 
> Use unknown action feature to trim servlet prefix from page requests.
> When controller can't find the "page.jsp" action, it forward to a
> standard unknown action that removes the servlet-mapping 
> prefix ("/do"),
> and forwards again, this time to /module/page.jsp.

Well, this suggests an interesting alternative to using a prefix for the
default sub-app, knowing that the fact that no such sub-app is defined will
cause the request to be sent to the default sub-app anyway... ;-)

--
Martin Cooper

> 
> =:0) Just kidding =:0)
> 
> -- Ted Husted, Husted dot Com, Fairport NY US
> -- Java Web Development with Struts
> -- Tel: +1 585 737-3463
> -- Web: http://husted.com/about/services
> 
> --
> To unsubscribe, e-mail:   
<mailto:struts-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-dev-help@jakarta.apache.org>



--
To unsubscribe, e-mail:   <mailto:struts-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-dev-help@jakarta.apache.org>


Mime
View raw message