Uploaded image for project: 'Struts 2'
  1. Struts 2
  2. WW-4421

Duplicate @Action value annotation check skipped

    Details

      Description

      PackageBasedActionConfigBuilder#buildConfiguration checks if there are duplicate action names on method annotations. If ActionSupport#execute is overridden and annotated with @Action, the duplicate action name check is skipped.

      The check is disabled due to

      PackageBasedActionConfigBuilder.java:674
      if (!map.containsKey(DEFAULT_METHOD)

      Having duplicate action names leads to different behavior with Java 7 or Java 8 environment (due to reflection method order).

        Attachments

        1. MethodCheckSkippedOnStartup.java
          0.5 kB
          Sebastian Haas
        2. MethodCheckFailsOnStartup.java
          0.4 kB
          Sebastian Haas

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              sha/silbergrau Sebastian Haas
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: