App design advise

J

John

Hi

I am making a simple contacts app involving clients, suppliers etc. Mostly
it involves data entered by the user being saved in the db and then user
able to search/browse the data. My question is; is it still advantageous to
bind ui elements to clients, suppliers "business" objects which in turn deal
with the db or can I bind ui elements directly to db? In other words is it
useful to have a three-tier app instead of a two-tier one even in this
simple case? Reasons?

Thanks

Regards
 
M

Michael C#

A well-developed three-tier is better, but it might be overkill. It depends
on a lot of factors like how many people are going to be using the system
simultaneously? Number and complexity of business rules? Network bandwidth
(thin client/fat client)? How much data is being stored? Etc.

For a simple, basic app that only one or two people at a time will use,
two-tier would probably be sufficient; especially if you're on a tight
deadline. For a scalable app that has more complex busines logic and needs
to handle many simultaneous users, three-tier/n-tier is the way to go.
 
M

Michael C#

Three tier is more scalable than two tier. In three-tier, or n-tier, your
middle tiers can take on the responsibility of "traffic cops", cache data if
you require, and cut down on the number of database connections required for
hundreds or thousands of users.
 
R

Rockford Lhotka

There's an important difference between physical tiers and logical tiers
(often called layers).

Physical tiers are a tradeoff between things like performance, scalability,
fault-tolerance, security and so forth.

Logical layers are all about improving maintainability of code, decreasing
cost of development, promoting reuse and so forth.

In general terms, software should be built using an organized set of logical
layers - often Presentation/Business/Data.

Sometimes, typically due to scalability or security requirements those
layers may be deployed to separate physical tiers - thus resulting in an
n-tier system. This invariably increases the cost and complexity of a
system, and so should only be done if the scalability or security benefits
outweigh the costs.

Rocky
 
M

Michael C#

Logical layers, if designed well, can also improve scalability. As you
mention, it's a lot easier to move the business logic logical layer off of
the physical server box and onto its own box in the future when you hire
10,000 new data entry operators.

The 'decrease in the cost of development' is not necessarily true for a
small project. Building out multiple layers requires a lot more planning
and a lot more complex testing plans. Code reuse is always a plus, but also
requires a lot more planning.

I think the major factors to decide whether to go 2-tier, 3-tier, n-tier are
probably: 1) budget and resources, 2) system requirements/complexity, 3)
schedule, 4) number of users.

If you are writing a simple database app for an office of 2 people, with a
budget of $500, 2 workstations and a server, very little business logic
involved and it has to be done in a week, is a 3-tier or n-tier solution
necessary or even feasible? Or would it make more sense to give them a
simple 2-tier solution to suit their needs, and when they hire 100 new
employees and can afford a $50,000 budget you can submit a proposal on a new
3-tier/n-tier solution?
 
C

Chad Z. Hower aka Kudzu

J

John

How do we implement communication between the layers? Assuming that we want
to scale in future and add more hardware. Remoting? Webservices? Anything
else?

Thanks

Regards
 
C

Chad Z. Hower aka Kudzu

John said:
How do we implement communication between the layers? Assuming that we
want to scale in future and add more hardware. Remoting? Webservices?
Anything else?

It depends on your needs. Generally I would avoid remoting and favor webserivces until Indigo is
avialable. But again it depends on yoru needs.


--
Chad Z. Hower (a.k.a. Kudzu) - http://www.hower.org/Kudzu/
"Programming is an art form that fights back"

Empower ASP.NET with IntraWeb
http://www.atozed.com/IntraWeb/
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top