Three-tier与MVC的不同
来源:互联网 发布:软件测试培训班靠谱吗 编辑:程序博客网 时间:2024/05/14 16:11
先说Three-tier。简单点说,
客户机---应用服务器-----数据服务器
典型的情况下有多个db服务器和多个客户端。应用服务器也可以有多个。应用服务器指 对客户端的请求进行分析,平衡,再将其分配给db服务器。对db服务器返回的结果集分析,平衡,发送至不同的客户端。
一个最简单的例子:
client1,client2发出两个相同的select语句到应用服务器。应用服务器发现两个请求相同,向数据库服务器select一次,得到结果集,发给两个客户端。
在没有应用服务器的情况下,数据库须被执行两次select。
对网络应用而言,可以说成下面的结构:
database 服务器----
|
-----Web服务器——--
|
-------客户端浏览器
好处:
1、减轻database 服务负担;
2、瘦客户;
......
再说MVC。
MVC是遵循了关注点分离的原则,C和V对M是松耦合的。
Today, MVC and similar MVP are Separation of Concerns design patterns that apply exclusively to the presentation layer of a larger system. In simple scenarios MVC may represent the primary design of a system, reaching directly into the database; however, in most scenarios the C (Controller) and M (Model) in MVC have a loose dependency on either a Service or Data layer/tier.
最后说说两者的不同。
Three-tier的各方是线性连接的。
A fundamental rule in a three tier architecture is the client tier never communicates directly with the data tier; in a three-tier model all communication must pass through the middle tier. Conceptually the three-tier architecture is linear.
但是MVC的各方的连接方式是三角型的。
However, the MVC architecture is triangular: the view sends updates to the controller, the controller updates the model, and the view gets updated directly from the model.
两者如何联系起来呢?
- Three-tier与MVC的不同
- Architectural Pattern(3)-N-Tier与MVC架构的区别与联系
- three-tier architectur 三层模型
- 三层架构(3-tier application) 与MVC对比
- Software Engineering Best Practices - Three Tier Architecture
- Explain the three services model (three-tier application)
- 计算机软件领域中Layer 与 Tier(不是tire) 的区别
- 不同的MVC
- mvc中cshtml与aspx页面的不同
- mvc中cshtml与aspx页面的不同
- mvc中cshtml与aspx页面的不同
- 设计模式之-3-tier&MVC
- aspx页面与MVC的View页面cshtml调用ajax的不同
- aspx页面与MVC的View页面cshtml调用ajax的不同
- aspx页面与MVC的View页面cshtml调用ajax的不同
- aspx页面与MVC的View页面cshtml调用ajax的不同
- 在各级供应商的表达中,OEM,Tier One (Tier 1),Tier Two (Tier 2)的概念和区别
- spring mvc 针对不同请求头返回不同的视图
- 使用ingress qdisc和ifb进行qos
- Mac使用git/github小结
- javascript 中的function当做对象模型的时候怎样理解
- nerd实验室(一)
- 编译IMQ过程
- Three-tier与MVC的不同
- sicily 1014
- 新手学习.NET教程 别忘了Using
- Android开发实现HttpClient工具类
- MyEclipse 快捷键
- 归并排序 一个简单的java实现
- Problem 3 琪露诺(iceroad.cpp/c/pas)
- Java中的ASCII、Unicode和UTF-8字符编码集
- (7)巩固一下C语言基础知识,谁动手,谁收获。