Exception handling....
Reply
![]() |
|
|
From:
Anand Kumar
|
Hi, Exception is a expensive operation , you should consider it in exceptional condition and do not use exception to control application flow .The empty catch statement should use for some specific purpose lets say you are displaying business data and a image by pulling from DB and the prime job is to display the business data and displaying of image is not important for the application ,I mean regard less of rendering of image but the business data should display and if any exception has occur while display the business data then you should raise exception, as in case of image it is optional so you can implement empty catch block here in case of any exception occur it does not has any impact on displaying the business data .Regarding exception security I can say exception is one of the important source for the hacker to know about data source(database or table name ) or file path for which the exception has generated to avoid do not return the contents of a system exception to the user and only exposing information to the client that is required. Its one of the good practices to maintain exception wrapping or replace one exception with another in order to display the custom exception to the user by hiding the system exception
Cheers Anand http://spaces.msn.com/members/anandkumar |
|
View other groups in this category.
![]() |
To stop getting this e-mail, or change how often it arrives, go to your E-mail Settings.
Need help? If you've forgotten your password, please go to Passport Member Services.
For other questions or feedback, go to our Contact Us page.
If you do not want to receive future e-mail from this MSN group, or if you received this message by mistake, please click the "Remove" link below. On the pre-addressed e-mail message that opens, simply click "Send". Your e-mail address will be deleted from this group's mailing list.
Remove my e-mail address from dotNET User Group Hyd.
|
|