Re: [Codenarc-user] GrailsStatelessService - bean properties and dependencies
Brought to you by:
chrismair
From: <chr...@we...> - 2011-12-15 18:54:04
|
>> ignoring fields with "no initialized value" seems like a good idea to me. It should help with fields that are tied to Spring - injected or pulled in afterPropertiesSet(), etc. I am just concerned about casting too wide a net (and missing true violations of statelessness). So, I would be inclined to only ignore "properties" declared with "def". So, public/private/protected fields, or fields with specific types (e.g., String, int, MyClass) would still cause violations. Is that ok? >> Spring 3.x also has this annotation called @Inject. We could consider supporting that. We only check the name of the annotation ("Inject"), not the type, so in that case there would be no runtime dependency. Chris |