473,796 Members | 2,482 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Error handling in a 3 Tier architecture??? ?

hello guys,

I have a GUI, Business Object layer and data layer.

What is the best way to handle errors in these layers?

Do I need to catch errors in all these layers? Or simply as all the errors
will fall to the GUI layer ultimately I
just need to handle the errors in the GUI layer and that is it?

any example or online resource in a simple base will be appreciated.

Ta
Nov 19 '05 #1
3 2525
There is a exception managment guide from Microsoft:
http://msdn.microsoft.com/library/de...ceptdotnet.asp

You may want to check out the Enterprise Library's Exception Handling
Block yet? It allows you to define and change your exception handling
strategies in the config file, hence giving your flexibility in
adapting to your real usage (ie, should you log an exception? where?
when?..etc).

HTH,
Alex

Nov 19 '05 #2
Thanks Alex,

I have already seen Microsoft guidelines for error handling as the links
bellow however that is in very general form
I specifically want it in a tiered application and how to manage and handle
the errors.

I haven't checked Enterprise Library's Exception Handling
Block. Thanks for your help and response
TA

"Alex" <li*****@gmail. com> wrote in message
news:11******** *************@g 44g2000cwa.goog legroups.com...
There is a exception managment guide from Microsoft:
http://msdn.microsoft.com/library/de...ceptdotnet.asp

You may want to check out the Enterprise Library's Exception Handling
Block yet? It allows you to define and change your exception handling
strategies in the config file, hence giving your flexibility in
adapting to your real usage (ie, should you log an exception? where?
when?..etc).

HTH,
Alex

Nov 19 '05 #3
Annie,

The guide talks about handling errors in between layer boundaries too.
It may sounds general since exception handling is typically specific to
the application.
I would say if all your layers will be hosted on the same machine, then
handling all the recoverable exceptions when they arise, and let the UI
layer handles the rest of the nonrecoverable / unexpected exceptions is
a sound and simple way.
How should you handle them? That again depends on your application and
situation, but the Enterprise Library provides you the flexibility to
change your handling strategies (log, wrap, substitute, rethrow, a
combination..et c) for any types of exception. It may seems there are
many choices, but it is usually best to do the simplest thing that
could possibly work ;)

HTH,
Alex

Nov 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

77
5696
by: nospam | last post by:
Reasons for a 3-tier achitecture for the WEB? (NOTE: I said, WEB, NOT WINDOWS. DON'T shoot your mouth off if you don't understand the difference.) I hear only one reason and that's to switch a database from SQL Server to Oracle or DB2 or vice versa... and that's it.... And a lot of these enterprises don't need it as they already know what database they are going to use and they don't plan on switching in and out database in the first...
25
5629
by: David Noble | last post by:
We've been developing a web site using 3-tier architecture for 18 months now. There is a common layer that defines the classes - using XML schemas. The data layer acts as a wrapper to 3 databases - SQL Server, Oracle and AS400. The business layer exposes web services which communicate with the front end, ASP.Net. All 3 tiers are on different boxes. This works well. Now I am leading a team to build a winforms app. I need some advice as
51
4076
by: nospam | last post by:
THIS IS the DOTNETJUNKIES MESSAGE ------------------------- We're Sorry As many of you know we have recently launched SqlJunkies.com. We have overhauled our runtime and will be using it on DotNetJunkies.com also. -------------------------------------------------------------------------- YEP, DOTNET JUNKIES REDESIGN....
4
7023
by: Patrick | last post by:
I'm writing a winforms database application in C#. I've come across a lot of stuff lately about "N-Tier" architecture. Can anyone give me a simple explanation of N-Tier? The descriptions that I've found online are chock full of lingo that I simply don't know. I need the "N-Tier" for Dummies description. Talk to me like I'm in kindergarten. Of course, I'm particularly interested in how N-Tier relates to creating a winforms database...
3
14520
by: RAJESH | last post by:
I am working with c# and asp.net in developing web applications, iam using ..netframework 1.1 ,i want to know what is the need of 3-tier or 4-tier architecture in our application development.what is its part when some body is using our application.plese give links where i can find the answer.
0
9528
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10455
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10173
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10006
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9052
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6788
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5441
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4116
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3731
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.