Uploaded image for project: 'SonarJava'
  1. SonarJava
  2. SONARJAVA-1299

FP on S1172: Parameters annotated with @Observes should be ignored

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.10
    • Component/s: Rules
    • Labels:
      None

      Description

      Annotated method parameters with javax.enterprise.event.Observes should be ignored, as the annotation is used as flag to identify methods.

      Example:

      public void onLoginFailed(@Observes LoginFailedEvent event, DefaultLoginCredentials loginCredentials) throws ServiceException {
       // @Observes will be used to react call the method when the given event is fired
      

      Thread in google groups: https://groups.google.com/d/msgid/sonarqube/d80b3803-8951-4ddd-9935-5aeb9320d845%40googlegroups.com

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                michael.gumowski Michael Gumowski
                Reporter:
                michael.gumowski Michael Gumowski
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Due:
                  Created:
                  Updated:
                  Resolved: