Azure / azure-sdk-for-java

This repository is for active development of the Azure SDK for Java. For consumers of the SDK we recommend visiting our public developer docs at https://docs.microsoft.com/java/azure/ or our versioned developer docs at https://azure.github.io/azure-sdk-for-java.
MIT License
2.35k stars 1.99k forks source link

Enable Spotbugs check on All Track 2 SDK Samples and test code files. #9360

Closed g2vinay closed 8 months ago

g2vinay commented 4 years ago

Spotbugs check does not run on Track 2 Samples and Test code files currently. Enable it in sdk/parents/azure-client-sdk-parent/pom.xml, set this flag to true. : ClickHere Fix the spotgubs issues in all the track 2 SDKs samples and test code files.

conniey commented 4 years ago

That would be nice. :) Where do I enable it when pom.client.xml does not exist?

g2vinay commented 4 years ago

That would be nice. :) Where do I enable it when pom.client.xml does not exist?

That's a good point. :) We need to update the sdk/parents/azure-client-sdk-parent/pom.xml Specifically, set this flag to true. : Click Here

alzimmermsft commented 4 years ago

To make this more of a rolling change specific to each library you should add this configuration into its pom.xml.

<build>
  <plugins>
    <plugin>
      <groupId>com.github.spotbugs</groupId>
      <artifactId>spotbugs-maven-plugin</artifactId>
      <version>3.1.12.2</version> <!-- {x-version-update;com.github.spotbugs:spotbugs-maven-plugin;external_dependency} -->
      <configuration>
        <includeTests>true</includeTests>
       </configuration>
    </plugin>
  </plugins>
</build>

If your POM already includes a plugins section for build you only need to add in the plugin configuration. This will merge with what is linked in @g2vinay's comment but change it to include tests.

@vcolin7 @hemanttanwar @conniey @samvaity @sima-zhu @mssfang

joshfree commented 4 years ago

@g2vinay could you complete this enhancement for azure-identity ahead of its August GA?

ki1729 commented 2 years ago

Unassigning myself form the issue, ServiceBus has spotbugs enabled, and no open issues reported from spotbugs

github-actions[bot] commented 8 months ago

Hi @g2vinay, we deeply appreciate your input into this project. Regrettably, this issue has remained inactive for over 2 years, leading us to the decision to close it. We've implemented this policy to maintain the relevance of our issue queue and facilitate easier navigation for new contributors. If you still believe this topic requires attention, please feel free to create a new issue, referencing this one. Thank you for your understanding and ongoing support.