Re: [PROPOSAL] lifecycle release

Nicola Ken Barozzi <[email protected]> Wed, 19 Mar 2003 10:02:19 +0100
Newsgroups gmane.comp.jakarta.avalon.phoenix.devel,gmane.comp.jakarta.turbine.maven.devel
Organization Apache Software Foundation
Message-ID <[email protected]>

Peter Donald wrote, On 19/03/2003 9.39:
> On Mon, 17 Mar 2003 18:32, Nicola Ken Barozzi wrote:
> 
>>If I have logging in many places in my app, it means that I *need* it
>>there, like asserts... ever tried moving asserts outside of the code?
> 
> yep. We did in Avalon actually. Theres quite a few Design-By-Constraints 
> toolkits out there and I actually have a written a DBC interceptor that 
> performs validation as appropriate.

Hmmm, I agree that doing that for pre+post conditions is possible 
outside of the code, although I don't really lkie it that much, as I 
would not like to have javadocs in a separate file.

But as for assertions that are inside the code? That is what I to 
address: not doing it before and after a method, but inside.

Although one could argue that any method can be split up in smaller ones 
that have their own pre+post assertions...

>>For me logging, asserts, etc I call them "concerns" rather than
>>"aspects". They are not part of the application architecture, but are a
>>common concern for all classes.
> 
> Depends on the logging. System level logging, entrance to methods, or resource 
> usage I would consider something controllable by AOP but domain level logging 
> is different kettle of fish.

Yup.

-- 
Nicola Ken Barozzi                   [email protected]
             - verba volant, scripta manent -
    (discussions get forgotten, just code remains)
---------------------------------------------------------------------