sonar-puppet icon indicating copy to clipboard operation
sonar-puppet copied to clipboard

Resource defaults should be used in a very controlled manner

Open racodond opened this issue 10 years ago • 2 comments

Try to understand https://docs.puppetlabs.com/guides/style_guide.html#resource-defaults

racodond avatar Aug 15 '15 14:08 racodond

@racodond this is why i originally had the info level rule to mark these for manual review, checking to see if its top level scope i.e site.pp should enough however this point:

In a class which is guaranteed to never declare or be inherited by a class or define from another module.

We could only cover if we can identify the inheritance.

iwarapter avatar Aug 15 '15 16:08 iwarapter

@iwarapter Yep. I reopened the issue because I was wondering if each Puppet module should be analyzed as a dedicated project in SonarQube or if they should be analyzed all together in a single project. In this case, we could implement such a rule. Also I want to try and understand this rule because the company I work with kind of extensively use those resource default statements.

racodond avatar Aug 15 '15 18:08 racodond