views:

114

answers:

4

Multi-tier and/or ditstributed apps, do they have the same meaning ?

When we talk about layers in these apps, is it physical layers (database, browser, web server,...) or logical layers (data access layer, business layer,...) ?

A: 

Multi-tier means that your application will be based on multiple machines with different tasks (Database, Web application, ...). Distributed means that your application will run in multiple machines a the same time, for example your website could be hosted on 3 different servers.

For multi-tier applications we speak generally about physical layer. But in every application you can/should have different logical layers.

Colin Hebert
But you can have all your application in the same one machine, then here we talk about logical layer and not physical. And your definition of distributed application isin't the same as "duplication" because you said tha the same app is runnig on different machines ?
mohamida
To be more precise the distributed application will be only one application launched on several machines. Every machine will work with each other to have a balanced application. Whenever a machine is down other take relay. Or for example with a website, if a million of requests come, each server will handle a part of theses requests to avoid the overloading of only one machine.
Colin Hebert
I think you're are talking here about "load-balancing", and not distributed apps. I think that distributed is that One application is divided into many small apps, and those apps are spread in different machines, and each small app is doing some specific work.
mohamida
I think that load-balancing is one of the perks of distributed apps, but there is more, better performances, shared memory, ...
Colin Hebert
@Colin: better performance isn't a feature of distributed apps. A distributed app might handle larger amounts of traffic but still perform worse on a per transaction basis than a non-distributed application.
Chris Lively
@Chris Lively, when you try to solve a problem distributed computing will help you to solve it faster if the task takes a lot of time, this same task will take less time if it's distributed, it's also called grid computing.
Colin Hebert
A: 

Historically "multi-tier" meant several layers with different functionality (file server / DB server, then application server or web server, then the thin client). This has grown up from client/server architecture by splitting app server / web server and backend data storage server.

Distributed doesn't have such separation and can mean both "grid application" or some kind of split application, where different parts run on different computers and perform different (not necessarily client or server) functions.

Eugene Mayevski 'EldoS Corp
Doesn't client/server architecture mean that the application is in the server, and that the user access that application from another computer ?Isin't splitting app server / web server and backend data storage server what's called multi-tier ?
mohamida
No. I don't know where you've taken that but for years it was the way I described. These articles are a good place to start:http://en.wikipedia.org/wiki/Client-server_architecturehttp://en.wikipedia.org/wiki/Distributed_application
Eugene Mayevski 'EldoS Corp
+4  A: 

Maybe these two sentences do convey intuitively the distinction between distributed and multi-tier:

  • Distributed: You replicate the processing amongst nodes
  • Multi-tier: You split the processing amongst tiers

In one case, the same processing is replicated over several nodes. In the other case, each tier has a distinct responsibility and the processing running on each tier differ.

Both notions are not exclusive: you can have non-distributed multi-tier apps (if there is no form of redundancy/replication), distributed apps which are not multi-tier, but also multi-tier apps which are distributed (if they have some form of redundancy).

There would be a lot more to say about the distinction, but the difference (to me) is essentially there.

ewernli
So distributed is like load-balancing ?
mohamida
Isin't like what said Eugene Mayevski 'Eldos and what's said in wiki that "a program is divided into multiple tasks, and each of them is run on different machine ?
mohamida
@mohamida I'm not sure I get your comment. What is not clear? Also, there won't be a hard line between the two concepts. But tiers is used more frequently to speak of enterprise apps, while distributed systems is more related to things like search engine, distributed database, fault-tolerance.
ewernli
I think the definition you gave about distributed sounds like the definition of load-balancing ? isin't ? Because the definition given in wiki says something like "distributed app is divided into multiple tasks, and each of them is run on different machine" but you said that "distributed app is replicated on different machine"
mohamida
@mohamida Ok, so I would say that horizontal scalability with replication and load balancing (usually in a stateless architecture) is one type of distributed system. But the term distributed system is more general than that. A bit more clear?
ewernli
So, having the same app in different machines, or having the different tasks of an app in different machines is called distributerd app ? (and sorry, can u plz answer the other question (physical/logical layers..))
mohamida
+1  A: 

ewernli has the mostly correct answer here. The only missing piece from the original question concerns physical and logical layers.

From a distributed and/or multi-tier perspective whether the layers are physically separate or just logically so is immaterial. Meaning, it doesn't matter. You can create multi-tier and even distributed applications which resides entirely on the same machine instance.

That said, it is more common to separate the tiers into different machines built specifically for that type of load. For example, a web server and a database server. Or even a web server, several web services machines, and one or more database servers.

All of these features, distributed, multi-tier, and/or load balanced with logical and/or physical layers are just features of the application design.

Further, in today's world of virtual machines, it's entirely possible (and even likely) to set up a multi-tier, distributed, and load balanced application within the confines of a single real machine. Although, I'd never recommend that course of action because the point of load balancing and distributed services is usually to increase availability or throughput.

Chris Lively
And if many tasks are run by different processors in the same machine, do we talk here about Distributed app ?
mohamida
@mohamida: only if it is actually separate identical processes running. If a single process is using multiple threads to process the data then it's simply a multi-threaded app.
Chris Lively