[
https://issues.apache.org/jira/browse/WW-3927?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13510510#comment-13510510
]
Greg Huber commented on WW-3927:
--------------------------------
Lukasz,
There is another spurious "Unexpected Exception caught setting" message that
comes from the use of the checkboxlist tag as it renders a hidden field with an
id beginning with "__multiselect_". There will never be a method with on the
action for this.
com.opensymphony.xwork2.interceptor.ParametersInterceptor line starting 314
{code:java}
for (Map.Entry<String, Object> entry : acceptableParameters.entrySet()) {
String name = entry.getKey();
Object value = entry.getValue();
try {
newStack.setParameter(name, value);
} catch (RuntimeException e) {
if (devMode) {
String developerNotification =
LocalizedTextUtil.findText(ParametersInterceptor.class, "devmode.notification",
ActionContext.getContext().getLocale(), "Developer Notification:\n{0}", new
Object[]{
"Unexpected Exception caught setting '" + name +
"' on '" + action.getClass() + ": " + e.getMessage()
});
LOG.error(developerNotification);
if (action instanceof ValidationAware) {
((ValidationAware)
action).addActionMessage(developerNotification);
}
}
}
}
{code}
btw what is the purpose of the hidden field as it does not seem to be used
anyhow? When I do my list handler I have save the original id's in a separate
hidden field which will be a string.
Cheers Greg
> com.opensymphony.xwork2.interceptor.ParametersInterceptor incorrect message
> in log
> ----------------------------------------------------------------------------------
>
> Key: WW-3927
> URL: https://issues.apache.org/jira/browse/WW-3927
> Project: Struts 2
> Issue Type: Bug
> Components: Core Interceptors
> Affects Versions: 2.3.7
> Environment: centos/tomcat
> Reporter: Greg Huber
> Assignee: Lukasz Lenart
> Priority: Minor
> Fix For: 2.3.8
>
>
> Hello,
> Think the notifyDeveloper(..) message should be before the return true;
> statement!
> {code:java}
> protected boolean isExcluded(String paramName) {
> if (!this.excludeParams.isEmpty()) {
> for (Pattern pattern : excludeParams) {
> Matcher matcher = pattern.matcher(paramName);
> if (matcher.matches()) {
> // messsage here?
> return true;
> }
> }
> }
> notifyDeveloper("Parameter [#0] is on the excludeParams list of
> patterns!", paramName);
> return false;
> }
> {code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira