I typically inject a logging service into any component that needs it,
and log the errors where they occur... then throw/rethrow/return as
neccessary.

-Dave Ross


>>> [EMAIL PROTECTED] 04/15/05 3:06 AM >>>
one problem ive found with #3 is with error logging.

say ive got this scenario

page.cfm -> a.doSomthing() -> b.doSomething() -> c.doSomething()

sometimes you dont get the correct line number thats causing the error. 
if the error is logged in b then i points to the line of 
c.doSomething(), but thats not very helpfull if c.doSomething() is 
massive! (it shouldnt be i know, but sometimes it is) or even if the 
chain acutally extends beyond c.

Just wondering how everyone using method #3 treats error Logging ? If 
you dont do error logging, if their was a requirement for developers to 
be notifed of the exact line causing exceptions in your code, how would 
you handle it ?

Pat



Sean Corfield wrote:

>On 4/14/05, Adrocknaphobia <[EMAIL PROTECTED]> wrote:
>  
>
>>1) Defined return.
>>2) Error handling methods on all components.
>>3) cfthrow.
>>    
>>
>
>#3 gets my vote.
>  
>



----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email to
[email protected] with the words 'unsubscribe cfcdev' as the subject of
the email.

CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting
(www.cfxhosting.com).

An archive of the CFCDev list is available at
www.mail-archive.com/[email protected]



----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email to 
[email protected] with the words 'unsubscribe cfcdev' as the subject of the 
email.

CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting 
(www.cfxhosting.com).

An archive of the CFCDev list is available at
www.mail-archive.com/[email protected]


Reply via email to