1.1 Plan the application layers

提到了repository pattern,SoC(Separation of Concern),

进而提及MVC,Action/Action results,Route/Routing (IHttpHandler, MvcHandler, IControllerFactory),Asynchronous Controllers,Views (Strongly-typed views, View-specific model, partial view, Master page),Razor/WebForms view Engine

1.2 Design a distributed application

REST service vs ASP.NET Web Services (ASMX) vs WCF Web API

通过HttpService调用REST API,(为什么不是HttpClient?)

Hybrid application - Azure server + local app server/local db server via Azure AppFabric

3种Session管理模式:InProc(default)/OutProc(StateServer or SQLServer)

1.3 Deign and implement the Windows Azure role life cycle

startup tasks management by AppCmd

1.4 Configure state management

asp.net使用ViewState来管理state信息。

asp.net mvc使用以下方式保存state信息:

  • Cache - memory pool on server, shared across users
  • Session - stored on server, unique for each user
  • Cookie - stored on client, passed with each HTTP request to the server
  • QueryString - passed as part of the URL string
  • Context.Items - part of HttpContext and lasts only the lifetime of that request
  • Profile - stored in db and maintains information across sessions

cookie

  • 4k限制
  • support feature such as Remember Me.

Html5 Web Storage

  • browser compatible

1.5 Design a cache strategy

使用OutputCache属性来控制cache的范围,Location的值:Any(default)/Client/Downstream/Server/ServerAndClient/None。

Donut caching support via Substitution api of asp.net

Donut hole caching:

  1. 在一个返回action的方法(ChildAction)上使用OutputCache属性
  2. 在父View中使用@Html.Action("ChildAction")

如果在Controller上使用OutputCache属性,那么所有支持GET request的方法都具有这个属性,其他的方法不受影响。

分布式Caching要用到AppFabric,(.net版的redis应该也支持吧!)

使用System.Runtime.Caching.dll的默认实现ObjectCache/MemoryCache,来实现data caching。

Html5支持Application Cache API(AppCache),

  1. 生成cache manifest,
  2. 在Layout.cshtml中reference manifest, 如<html manifest="site.manifest">
  3. 设置正确的MIME-type,Response.ContentType="text/cache-manifest"。

Http caching。

1.6 Design and implement a WebSocket strategy

通过hand shake建立WebSocket连接,server端通过HttpContext.Current.AcceptWebSocketRequests(Func<AspNetWebSocketContext, Task>)完成GET到WebSocket的upgrade。

由于WebSocket不含http头信息,因此可能无法穿过firewall。

1.7 Design HTTP modules and handlers

http module和http handler的区别

熟悉asp.net mvc的default modules和handlers。

Chapter 1: Design the application architecture的更多相关文章

  1. JavaScript Application Architecture On The Road To 2015

    JavaScript Application Architecture On The Road To 2015 I once told someone I was an architect. It’s ...

  2. What is Web Application Architecture? How It Works, Trends, Best Practices and More

    At Stackify, we understand the amount of effort that goes into creating great applications. That’s w ...

  3. Cloud Design Patterns: Prescriptive Architecture Guidance for Cloud Applications 云设计模式:云应用的规范架构指导

    1.Cache-aside Pattern 缓存模式 Load data on demand into a cache from a data store. This pattern can impr ...

  4. Catalog of Patterns of Enterprise Application Architecture

    Catalog of Patterns of Enterprise Application Architecture Last Significant Update: January 2003 A s ...

  5. Application Architecture Determines Application Performance

     Application Architecture Determines Application Performance Randy Stafford AppliCATion ARCHiTECTuR ...

  6. Cloud Design Patterns: Prescriptive Architecture Guidance for Cloud Applications

    January 2014 Containing twenty-four design patterns and ten related guidance topics, this guide arti ...

  7. Understanding Spring Web Application Architecture: The Classic Way--转载

    原文地址:http://www.petrikainulainen.net/software-development/design/understanding-spring-web-applicatio ...

  8. Chapter 5: Design and implement security

    Configure authentication Authenticating users IIS authentication Anonymous ASP.net impersonation Bas ...

  9. Chapter 2: Design the user experience

    Apply the user interface design for a web application 介绍了Css的常用属性和html5的新element,以及Htmlhelper的简单方法,如 ...

随机推荐

  1. could not build module 'XXXXXXXX'或者error: expected identifier or '(' 。一堆奇怪的错误————错误根源

    一堆奇怪的错误:1⃣️could not build module 'XXXXXXXX' 2⃣️error: expected identifier or '(' 3⃣️EDIT Setting Pr ...

  2. View通用

    1.计算view尺寸 ViewTreeObserver vto = view.getViewTreeObserver(); vto.addOnPreDrawListener(new ViewTreeO ...

  3. .NET/android/java/iOS AES通用加密解密(修正安卓)

    移动端越来越火了,我们在开发过程中,总会碰到要和移动端打交道的场景,比如.NET和android或者iOS的打交道.为了让数据交互更安全,我们需要对数据进行加密传输.今天研究了一下,把几种语言的加密都 ...

  4. HighChart报表之饼图

    个人认为HighChart做报表还是很不错的,从报表的样式还是性能都是很不错的选择. 1.新建一个html页面,命名为:ReportTest.html <script type="te ...

  5. Consistent hashing —— 一致性哈希

    原文地址:http://www.codeproject.com/Articles/56138/Consistent-hashing 基于BSD License What is libconhash l ...

  6. EntityFrameWork使用过程问题总结

    1.记录上次遇到个一个问题. (1).vs2013中的EntityFramework不能识别odp11,所以在用ef的时候 ,要换vs2012 (2).opd12不能识别Oracle  9i(所以这个 ...

  7. cocos2d-x WebSocket

    WebSocket是HTML5开始提供的一种浏览器与服务器间进行全双工通讯的网络技术.在WebSocket API中,浏览器和服务器只需要做一个握手的动作,然后,浏览器和服务器之间就形成了一条快速通道 ...

  8. Mysql 根据时间戳、时间按年月日分组统计

    create_time时间格式 SELECT DATE_FORMAT(create_time,'%Y%u') weeks,COUNT(id) COUNT FROM role GROUP BY week ...

  9. 基础小功能之(1)震动,(2)检测app是否在前台运行

    //开启震动 //添加权限<uses-permission android:name="android.permission.VIBRATE" /> private v ...

  10. typedef关键字

    1. typedef的作用 在计算机编程语言中用来为复杂的声明定义简单的别名,与宏定义有些差异.它本身是一种存储类的关键字,与auto.extern.static.register等关键字不能出现在同 ...