struts-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <>
Subject [jira] [Commented] (WW-4912) Allowed methods inheritance
Date Fri, 26 Jan 2018 10:50:00 GMT


ASF GitHub Bot commented on WW-4912:

lukaszlenart opened a new pull request #206: WW-4912: scan package-info and class at the same
   This change allows to define `AllowedMethods` in `` and all class level
and all those annations will be examined to build set of allowed methods.
   Fixes [WW-4912](

This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:

> Allowed methods inheritance
> ---------------------------
>                 Key: WW-4912
>                 URL:
>             Project: Struts 2
>          Issue Type: Improvement
>    Affects Versions:
>            Reporter: Britta Katzenbach
>            Assignee: Lukasz Lenart
>            Priority: Minor
>             Fix For: 2.5.15
> As we use a lot of inheritance on action classes we would appreciate, if the allowed
methods would be inherited as well.
> For example:
> We do not declare actions in struts.xml and just use the Convention.
> struts.xml:
> {code:xml}
> <package name="default" extends="tiles-default"  namespace="/„ >
>     ...
>     <global-allowed-methods> abort,execute,search,reset,download,refresh,delegate,forward,release,saveComments
> </package>
> {code}
> Java:
> {code:java}
> @AllowedMethods(value = \{"changeLanguage", "deleteAttachment", "uploadMailAttachment"})
> public class SpecifyMailTask extends AbstractTask {
> @AllowedMethods(value = \{"saveInputAndSuccess"})
> public abstract class AbstractTask extends AbstractBasicJbpmTask implements ModelDriven<TaskModel>,
Preparable \{...}
> @AllowedMethods(value = { "abort", "cancel", "claim", "claimAndStart", "claimAndSkip",
"complete", "delegate", "forward",
>         "incomplete", "release", "skipAndComplete", "start", "suspend", "uploadTaskAttachment"})
> public abstract class AbstractBasicJbpmTask extends AbstractCrmAction implements ModelDriven<TaskModel>,
Preparable \{...}
> {code}
> I tried to add the allowed methods in the It worked as long as I did
not add an additional method to a certain action, i.e. SpecifyMailTask. If I add here the
annotation to allow the methods "changeLanguage", "deleteAttachment", "uploadMailAttachment"
additionally, the other methods, which are allowed via the, are not allowed

This message was sent by Atlassian JIRA

View raw message