struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Wes Wannemacher <>
Subject Re: Update to Struts 2.1.7
Date Wed, 24 Jun 2009 13:13:46 GMT
On Wed, Jun 24, 2009 at 4:53 AM, Pro1712<> wrote:
> But that's not my problem!
> What I forgot to mention in my first post is that I use dynamic method
> invocation and pass the param e.g. "method:input" to the action.
> Sorry for this...

No problem, but I was wondering how you knew which method you were calling.

> struts.enable.DynamicMethodInvocation = false
> is set in but worked for me in Struts 2.1.6.
> In 2.1.7 DefaultActionMapper was changed and a check for
> "allowDynamicMethodCalls" was added in line 187.
> So as a result the behavour changed and the method "input" was not mapped
> and so the default method "execute" is called
> setting
> struts.enable.DynamicMethodInvocation = true
> solves the problem.
> Is there a reason that this was changed? Or was this a bug in 2.1.6?

Yeah, sort of. We had created a setting a while back,
struts.enable.DynamicMethodInvocation to turn off the various ways of
invoking methods by name in the URL. It is a setting because some
people want it, other people view it as a security concern. To leave
it as a matter of preference, we created the setting. By default we
leave it turned off, but even with it turned off, the
DefaultActionMapper wasn't honoring the setting. I was in there to fix
another bug (making it understand redirectAction instead of
redirect-action) and fixed it up to honor the setting. It is in the
release notes for 2.1.7, in the section called - "Backward
compatibility issues with prior development release"


Wes Wannemacher
Author - Struts 2 In Practice
Includes coverage of Struts 2.1, Spring, JPA, JQuery, Sitemesh and more

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message