Three tiers in different projectshttp://forums.asp.net/t/1803763.aspx/1?Three+tiers+in+different+projectsThu, 17 May 2012 10:08:12 -040018037634980988http://forums.asp.net/p/1803763/4980988.aspx/1?Three+tiers+in+different+projectsThree tiers in different projects <p>Hi all,</p> <p>I see in some projects tree tiers classes in single project (in app_code) and access them. But in some other projects there are different projects for all lears in one solution. Which is the better approch and why??? Thanks in advace.</p> <p>Atiq</p> 2012-05-15T06:28:25-04:004981768http://forums.asp.net/p/1803763/4981768.aspx/1?Re+Three+tiers+in+different+projectsRe: Three tiers in different projects <p>layered in different project is Best. SInce we can seperate the logics and its get independent.</p> <p>More over the work get easier for modifications at layered level.</p> <p>Basically 3-tier is for presentation changes, what ever controls get mapped.</p> <p>So its should be in different project.for better development</p> <p></p> 2012-05-15T12:48:17-04:004982832http://forums.asp.net/p/1803763/4982832.aspx/1?Re+Three+tiers+in+different+projectsRe: Three tiers in different projects <p>Thanks Shree! great reply but little short. Can anyone explain in detail or provide some links for detail.</p> <p>Atiq</p> 2012-05-16T05:56:10-04:004982912http://forums.asp.net/p/1803763/4982912.aspx/1?Re+Three+tiers+in+different+projectsRe: Three tiers in different projects <p>http://channukambalyal.tripod.com/NTierArchitecture.pdf</p> <p>http://msdn.microsoft.com/en-us/library/ms973829.aspx</p> <p>Have a look on above links. You get the idea of 3-tier arch...</p> <p></p> 2012-05-16T06:49:43-04:004983396http://forums.asp.net/p/1803763/4983396.aspx/1?Re+Three+tiers+in+different+projectsRe: Three tiers in different projects <p>Hi,</p> <p>check here for 3 tier architecture</p> <p><a href="http://www.dotnetfunda.com/articles/article71.aspx">http://www.dotnetfunda.com/articles/article71.aspx</a></p> <p>The layers reside on the same machine where the tiers can reside on different machines.</p> <p>Layer communicates with each other either by Value or by Reference. However the Tiers could be on different machines, so they communicate by Value only as serialized objects.</p> <p>Layer is l<strong>ogical separation of code</strong> and Tier <strong>is physical separation of code</strong>, In other words we can say Tiers are the physical deployment of layers. Or a Tier becomes a&nbsp; Layer if it could be physically separated from the Layers it consumes.</p> <p><strong>N-Tier Architecture</strong> is a physical structuring, while <strong> a N-Layer Architecture</strong> is a logical structuring.</p> <p>Now coming to <strong><span style="text-decoration:underline">3 Layer Architecture</span></strong> and <strong><span style="text-decoration:underline">3 Tier Architecture</span></strong> after getting an idea about Layer and Tier.</p> <p>In 3 layer architecture, the <strong>Database Access Layer (DAL)</strong>, <strong> Business Logic Layer (BLL)</strong> and <strong>User Interface Layer (UIL)</strong> resides as 3 different project and the output of these 3 projects (.dll file) must be together in the <strong>same server</strong> or on <strong>same machine</strong> in order for the system to run.However in 3 tier architecture, the <strong>Database Access Layer (DAL)</strong>, <strong>Business Logic Layer (BLL)</strong> <strong>and User Interface Layer (UIL)</strong> reside as 3 different projects. But each of the projects can be deployed at the <strong>different server</strong> or at <strong>the different machines</strong> and distributed functionality is explored.</p> <p>In 3 layer architecture <strong>DAL, BLL and UIL</strong> can work on same machine where as in a 3 Tier architecture a client in on one machine, the application Server is hosted in another machine and the database server resides in another machine i.e.<strong> Three-tier</strong> is a <a title="Clientserver architecture" href="http://en.wikipedia.org/wiki/Client%E2%80%93server_architecture"> clientserver architecture</a> in which the <a title="User interface" href="http://en.wikipedia.org/wiki/User_interface"> User Interface</a>, <a title="Business logic layer" href="http://en.wikipedia.org/wiki/Business_logic_layer"> Business Logic </a>,<a title="Computer data storage" href="http://en.wikipedia.org/wiki/Computer_data_storage"> Data Storage</a> and <a title="Data access" href="http://en.wikipedia.org/wiki/Data_access">Data Access</a> are developed and maintained as independent <a title="Module (computing)" href="http://en.wikipedia.org/wiki/Module_(computing)"> modules</a> on separate <a title="Platform (computing)" href="http://en.wikipedia.org/wiki/Platform_(computing)"> platforms</a>.</p> <p>In 3 Layer we have distinct namespaces and classes for the various layes i.e. were only talking about <strong>logical organization of code</strong> and <strong>passing objects</strong> between layers is easy as all assemblies will run under same application in single machine.But 3 tier applications are not straight as 3 layers, because each layer will be deployed in different machines. So here, we need a mechanism to send the objects between different machines over the network hence we use technologies called <strong>Web Services</strong>, <strong>Remoting</strong> or <strong>WCF, </strong> etc.<strong> </strong>in order to implement 3 tier applications</p> <p>3&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Layer Architecture will improve <strong>readability</strong> and <strong> reusability, </strong>Minimizes&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; the application changes due to impact of the changes in other layers. While 3 Tier Architecture has all advantages of 3 layer &#43; <strong>scalability a</strong>s application will be deployed in different machines so load will be shared among the tiers and scalability will increase.</p> 2012-05-16T10:49:34-04:004985034http://forums.asp.net/p/1803763/4985034.aspx/1?Re+Three+tiers+in+different+projectsRe: Three tiers in different projects <p>Thanks P_IT, very informative.</p> <p>Atiq</p> 2012-05-17T10:08:12-04:00