codeclimate / codeclimate-sonar-java

Maintainability and reliability checks for Java
GNU Affero General Public License v3.0
3 stars 6 forks source link

Restrict analysis to .java files in order to save resources #49

Closed filipesperandio closed 6 years ago

dblandin commented 6 years ago

@filipesperandio Does sonar-java try to analyze every file in the include paths, regardless of file extension?

filipesperandio commented 6 years ago

@dblandin It does. Sonar can also analyze other languages, not only Java. We simplified this Finder class - there was a previous version of this logic we thought wasn't necessary, but looking at the sonar's output here and considering it is already consuming too much memory I thought it was worth bringing this filter back.

On a second thought, this needs more testing to figure if it actually helps performance. What just crossed my mind is that the java-plugin does not analyze only .java files, it takes .xml in too, and maybe other kinds of files =\

filipesperandio commented 6 years ago

Seeing some drawback adding this. If a project really needs to filter .java files it can be done in the include_paths with better patterns. Closing.