7/04/2009

High Performance Web Sites: The Importance of Front-End Performance

In 2004, I started the Exceptional Performance group at Yahoo!. We're a small team chartered to measure and improve the performance of Yahoo!'s products. Having worked as a back-end engineer most of my career, I approached this as I would a code optimization project - I profiled web performance to identify where there was the greatest opportunity for improvement. Since our goal is to improve the end-user experience, I measured response times in a browser over various bandwidth speeds. What I saw is illustrated in the following chart showing HTTP traffic for http://www.yahoo.com.

In the figure above, the first bar, labeled "html", is the initial request for the HTML document. In this case, only 5% of the end-user response time is spent fetching the HTML document. This result holds true for almost all web sites. In sampling the top ten U.S. websites, all but one spend less than 20% of the total response time getting the HTML document. The other 80+% of the time is spent dealing with what's in the HTML document, namely, the front-end. That's why the key to faster web sites is to focus on improving front-end performance.
There are three main reasons why front-end performance is the place to start.
  1. There is more potential for improvement by focusing on the front-end. Cutting it in half reduces response times by 40% or more, whereas cutting back-end performance in half results in less than a 10% reduction.
  2. Front-end improvements typically require less time and resources than back-end projects (redesigning application architecture and code, finding and optimizing critical code paths, adding or modifying hardware, distributing databases, etc.).
  3. Front-end performance tuning has been proven to work. Over fifty teams at Yahoo! have reduced their end-user response times by following our performance best practices, often by 25% or more.
Our performance golden rule is: optimize front-end performance first, that's where 80% or more of the end-user response time is spent.
Steve Souders
[Steve Souders is Yahoo!'s Chief Performance Yahoo!. This is one in a series of Best Practices for Speeding Up Your Web Site. This article is based on Steve's book High Performance Web Sites, published by O'Reilly.]
Posted at March 20, 2007 9:16 AM

7/02/2009

Google Hosts文件

研究了一晚上google的域名,自己从位于加利福尼亚的谷歌总部DNS服务器上扒出来的。
把下面的内容添加到C:\Windows\System32\drivers\etc\hosts文件中就行了

#Search
64.233.189.147 www.google.com
64.233.189.104 www.google.com
64.233.189.99 www.google.com
64.233.189.147 www.l.google.com

#Mail(POP3/SMTP)
209.85.147.109 pop.gmail.com
209.85.147.109 smtp.gmail.com

#WebMail
64.233.189.18 mail.google.com
64.233.189.19 mail.google.com
64.233.189.83 mail.google.com
64.233.189.18 www.gmail.com
64.233.189.19 www.gmail.com
64.233.189.83 www.gmail.com
64.233.189.19 googlemail.l.google.com

#Docs
64.233.189.101 writely-china.l.google.com
64.233.189.101 writely.l.google.com
64.233.189.102 docs.google.com
64.233.189.101 docs.google.com
64.233.189.100 docs.google.com

#Map
64.233.189.104 map.google.com
64.233.189.99 map.google.com
64.233.189.147 map.google.com
64.233.189.104 maps.google.com
64.233.189.99 maps.google.com
64.233.189.147 maps.google.com
64.233.189.99 maps.gstatic.com
203.208.39.93 khm.google.com
203.208.39.91 mt0.google.com
203.208.39.93 mt1.google.com
203.208.39.91 mt2.google.com
203.208.39.91 mt.l.google.com
64.233.189.99 maps.l.google.com

#Scholar
64.233.189.99 scholar.google.com
64.233.189.104 scholar.google.com
64.233.189.147 scholar.google.com
64.233.189.104 scholar.l.google.com

#Group
64.233.189.102 groups.google.com
64.233.189.100 groups.google.com
64.233.189.101 groups.google.com
64.233.189.101 groups.l.google.com

#Misc
64.233.189.101 id.google.com
64.233.189.102 id.google.com
64.233.189.100 id.google.com
64.233.189.100 id.l.google.com

免责声明

1、本人是文盲,以上内容文字均不认识,也看不懂是什么意思(包括但不限于对所以上之内容的识别、阅读、理解、分析、记忆等);

2、本人过去、现在以及将来都不认识本文中提及当事人,且自古以来与该相对人无利益关系;

3、本人昨天、今天以及明天都没有或者不准备去本文所述地点。本文表述之事与本人无关。

4、本人在此发文(包括但不限于汉字、拼音、拉丁字母、斯拉夫字母、日语假名、阿拉伯字母、单词、句子、图片、影像、录音、以及前述之各种任意组合等等)均为随意敲击键盘所出,用于检验本人电脑键盘录入、屏幕显示的机械、光电性能,并不代表本人局部或全部同意、支持或者反对文中观点。如需要详查请直接与键盘发明者及生产厂商法人代表联系;

5、人生有风险,上网需谨慎。本文不暗示、鼓励、支持或映射读者作出生活方式、工作态度、婚姻交友、股票债券买卖、子女教育的积极或消极判断。未成年人请在监护人陪同下阅读本文。无完全民事行为能力者,请立即关闭网页,并用20%高锰酸钾+75%乙醇对键盘、硬盘、电压插座、显示器、鼠标、cpu进行灌溉消毒;

6、如本人留言违反国家有关法律,请网络管理员及时删除本文,本人保留继续发文的权利;

7、因删贴不及时所产生的任何法律(包括宪法、加法、减法、乘法、除法、剑法、拳法、脚法、指法、民法、刑法、书法、公检法、基本法、劳动法、婚姻法、输入法、没办法、国际法、今日说法、吸星大法及文中涉及或可能涉及以及未涉及之法,各地治安管理条例)纠纷或责任本人概不负责;

8、本人谢绝任何跨省(包括但不限于跨国、跨洲、跨星球、跨星系)追捕行为。确因不抓不足以平民愤,或不抓就领不到薪水养家户口的公职人员,建议携带工作证、身份证、结婚证/离婚证、独生子女证、健康证、暂住证、毕业证、边防证、县以上政府机关出具的介绍信温情操作。抓捕按照以下排序倒序:作者、原作者以及网络管理员以及网络运行商、电信运营商、电力供应商、电脑生产销售商.