This got no response on struts-user so I went digging into the code... It looks to me on first examination that it wouldn't be hard at all to support modules with URL prefix mapping; all it needs is a check to see if getServletPath() returns a string that begins with the servlet mapping URL and, if so, match module names against the remaining request URL path instead of the servlet path.

It looks like changes may be limitted to ModuleUtils, which would make it a pretty low impact change. Does anyone know if that's actually the case? Is there anywhere else obvious I should check?

Are there any other reasons for not supporting this configuration? If there's not some issue that I'm overlooking I'll try creating and testing a patch. I just don't want to be wasting my time if someone can say, "no, you can't do that because of X' ;-)

Thanks,

L.

Laurie Harper wrote:

Argh, I just wasted an hour trying to figure out how to access the new module I just defined in my Struts application before finally finding a note in the docs [1] that only extension mapping is supported with modules :-(

Has anybody ever looked at lifting that restriction? I have everything set up with prefix mapping and I really don't want to switch... I'd rather forego modules if it comes to it.

If nobody's looked at making prefix mapping work with modules, does anyone have any idea what would be involved and/or how feasible it is? (based on the 1.2 code base if possible, I'd rather not move to an unreleased build.)

L.

[1] http://struts.apache.org/userGuide/configuration.html#dd_config_modules
    (section 5.4.2, right at the end)


--
Laurie, Open Source advocate, Java geek and novice blogger:
http://www.holoweb.net/~laurie/


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to